/* ==========================================================================
   Zuni Rewards — simple light theme
   ========================================================================== */

:root{
  --bg:#f5f6f8;
  --card:#ffffff;
  --text:#111827;
  --muted:#6b7280;
  --muted-2:#9ca3af;
  --line:#e5e7eb;
  --line-2:#f1f3f5;
  --green:#16a34a;
  --green-dark:#15803d;
  --green-soft:#ecfdf3;
  --red:#dc2626;
  --red-soft:#fef2f2;
  --gold:#d97706;
  --violet:#7c3aed;
  --blue:#2563eb;
  --r-sm:8px;
  --r-md:12px;
  --r-lg:16px;
  --shadow:0 1px 2px rgba(16,24,40,.06);
  --shadow-md:0 10px 30px -12px rgba(16,24,40,.18);
  --font:"Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

*,*::before,*::after{ box-sizing:border-box; }

body{
  margin:0;
  min-height:100vh;
  background:radial-gradient(760px 420px at 88% -8%, rgba(22,163,74,.06), transparent 62%), var(--bg);
  background-attachment:fixed;
  color:var(--text);
  font-family:var(--font);
  font-size:15px;
  line-height:1.5;
  -webkit-font-smoothing:antialiased;
}

h1,h2,h3,h4,p{ margin:0; }
a{ color:inherit; text-decoration:none; }
button{ font-family:inherit; color:inherit; cursor:pointer; }
input,select,textarea{ font-family:inherit; }
img{ max-width:100%; }
::selection{ background:#bbf7d0; }

.sprite{ position:absolute; width:0; height:0; overflow:hidden; }
svg{ width:20px; height:20px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.nav-ico, .mnav-icon svg, .mnav-fab svg,
.coin-glyph svg, .topbar .icon-btn svg, .avatar svg{ stroke:none; }
.hidden{ display:none !important; }
.muted{ color:var(--muted); }

/* Boot splash — covers the screen while the session restores */
.boot-splash{
  position:fixed; inset:0; z-index:60;
  background:#f5f6f8;
  display:flex; flex-direction:column; align-items:center; justify-content:center; gap:16px;
}
.boot-splash img{ width:46px; height:46px; }
.boot-spin{
  width:26px; height:26px; border-radius:50%;
  border:3px solid #e2e5ea; border-top-color:#16a34a;
  animation:bootspin .7s linear infinite;
}
@keyframes bootspin{ to{ transform:rotate(360deg); } }

/* --------------------------------------------------------------------------
   Buttons / chips
   -------------------------------------------------------------------------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:7px;
  border:1px solid transparent; border-radius:10px;
  padding:10px 16px; font-size:14px; font-weight:600;
  background:#f3f4f6; color:var(--text);
  transition:background .15s, border-color .15s, opacity .15s;
  white-space:nowrap; user-select:none;
}
.btn svg{ width:17px; height:17px; }
.btn:hover{ background:#e9ebee; }
.btn:disabled{ opacity:.45; cursor:not-allowed; }
.btn-primary{ background:var(--green); color:#fff; box-shadow:0 6px 14px -10px rgba(22,163,74,.85); }
.btn-primary:hover{ background:var(--green-dark); }
.btn:active{ transform:translateY(1px); }
.btn-ghost{ background:#fff; border-color:var(--line); color:var(--text); }
.btn-ghost:hover{ background:#f9fafb; }
.btn-block{ width:100%; }
.btn-sm{ padding:8px 12px; font-size:13px; border-radius:8px; }

.chip{
  display:inline-flex; align-items:center; gap:5px;
  padding:4px 9px; border-radius:6px; font-size:11.5px; font-weight:600;
  border:1px solid var(--line); background:#f9fafb; color:var(--muted);
}
.chip svg{ width:12px; height:12px; }
.chip.green{ color:var(--green-dark); border-color:#bbf7d0; background:var(--green-soft); }
.chip.gold{ color:#92400e; border-color:#fde68a; background:#fffbeb; }
.chip.red{ color:#991b1b; border-color:#fecaca; background:var(--red-soft); }

.badge{
  display:inline-flex; align-items:center;
  padding:3px 8px; border-radius:6px; font-size:10.5px; font-weight:700;
  text-transform:capitalize;
}
.badge.pending{ background:#fffbeb; color:#92400e; }
.badge.paid{ background:var(--green-soft); color:var(--green-dark); }
.badge.processing{ background:#eff6ff; color:#1d4ed8; }
.badge.failed{ background:var(--red-soft); color:#991b1b; }

/* --------------------------------------------------------------------------
   Forms
   -------------------------------------------------------------------------- */
.field{ display:flex; flex-direction:column; gap:6px; font-size:13px; font-weight:600; color:#374151; }
.field > span{ display:flex; align-items:center; justify-content:space-between; gap:6px; }
.field em{ font-style:normal; font-weight:500; color:var(--muted-2); font-size:11.5px; }
.field-hint{ font-size:11px; font-weight:400; color:var(--muted-2); }
.field input, .field select{
  width:100%; padding:10px 12px; border-radius:9px;
  background:#fff; border:1px solid var(--line);
  color:var(--text); font-size:14px; outline:none;
  transition:border-color .15s, box-shadow .15s;
}
.field input::placeholder{ color:#b3b9c4; }
.field input:focus, .field select:focus{
  border-color:var(--green);
  box-shadow:0 0 0 3px rgba(22,163,74,.12);
}
.field select{ cursor:pointer; }
.field-row{ display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.form-grid{ display:grid; gap:14px; }
.form-error{ min-height:18px; font-size:12.5px; font-weight:500; color:var(--red); }
.form-note{ font-size:12px; color:var(--muted); line-height:1.5; }

/* --------------------------------------------------------------------------
   Auth
   -------------------------------------------------------------------------- */
.auth{
  min-height:100vh; display:flex; align-items:center; justify-content:center;
  padding:32px 20px;
}
.auth-wrap{
  width:100%; max-width:960px;
  display:grid; grid-template-columns:1fr 400px; gap:64px; align-items:center;
}
.brand{ display:inline-flex; align-items:center; gap:10px; }
.brand-logo{
  width:38px; height:38px; display:block; flex:0 0 auto;
  border-radius:11px; box-shadow:0 3px 8px -3px rgba(4,120,87,.45);
}
.side-brand .brand-logo{ width:34px; height:34px; border-radius:10px; }
.brand-text{ font-size:22px; font-weight:800; letter-spacing:-.4px; }
.auth-brand{ display:none; margin-bottom:16px; }
.auth-brand .brand-logo{ width:34px; height:34px; border-radius:10px; }
.auth-brand .brand-text{ font-size:19px; }

.auth-intro{ display:flex; flex-direction:column; gap:14px; margin-top:40px; }
.auth-intro h1{ font-size:38px; line-height:1.15; letter-spacing:-1.2px; font-weight:800; }
.auth-intro p{ font-size:15px; color:var(--muted); max-width:400px; line-height:1.6; }
.auth-points{ list-style:none; margin:8px 0 0; padding:0; display:flex; flex-direction:column; gap:10px; }
.auth-points li{ display:flex; align-items:center; gap:9px; font-size:14px; color:#374151; }
.auth-points svg{ width:16px; height:16px; color:var(--green); flex:0 0 auto; }
.auth-note{ display:flex; gap:7px; margin-top:18px; font-size:12px; line-height:1.5; color:var(--muted); }
.auth-note svg{ width:14px; height:14px; flex:0 0 auto; margin-top:1px; color:var(--green); }

.auth-card{
  background:var(--card); border:1px solid var(--line); border-radius:var(--r-lg);
  padding:26px;
  box-shadow:0 1px 2px rgba(16,24,40,.04), 0 28px 60px -42px rgba(16,24,40,.55);
}
.auth-card-head{ margin-bottom:18px; }
.auth-card-head h2{ font-size:20px; font-weight:800; letter-spacing:-.3px; }
.auth-card-head p{ font-size:13px; color:var(--muted); margin-top:2px; }
.auth-tabs{ display:flex; gap:4px; padding:4px; background:#f3f4f6; border-radius:9px; margin-bottom:18px; }
.auth-tab{
  flex:1; padding:8px; border:0; border-radius:7px; background:transparent;
  font-size:13px; font-weight:600; color:var(--muted);
}
.auth-tab.active{ background:#fff; color:var(--text); box-shadow:var(--shadow); }
.auth-form{ display:flex; flex-direction:column; gap:13px; }
.auth-form .btn{ margin-top:4px; padding:12px; }
.auth-divider{ display:flex; align-items:center; gap:10px; margin:16px 0 12px; color:var(--muted-2); font-size:11px; font-weight:600; text-transform:uppercase; }
.auth-divider::before,.auth-divider::after{ content:""; flex:1; height:1px; background:var(--line); }

/* --------------------------------------------------------------------------
   App shell
   -------------------------------------------------------------------------- */
.app{ display:flex; min-height:100vh; }
.sidebar{
  position:fixed; inset:0 auto 0 0; z-index:60;
  width:240px; padding:20px 14px 16px;
  display:flex; flex-direction:column; gap:16px;
  background:var(--card); border-right:1px solid var(--line);
  overflow-y:auto;
}
.side-brand{ padding:2px 8px; }
.side-user{
  display:flex; align-items:center; gap:10px; padding:10px;
  border-radius:11px; background:#f9fafb; border:1px solid var(--line-2);
}
.side-user-info{ min-width:0; }
.side-user-info b{ display:block; font-size:13px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.side-user-info span{ font-size:11.5px; color:var(--muted); }

.side-nav{ display:flex; flex-direction:column; gap:3px; }
.nav-label{ font-size:10.5px; font-weight:700; letter-spacing:.6px; text-transform:uppercase; color:var(--muted-2); padding:4px 10px 6px; }
.nav-item{
  display:flex; align-items:center; gap:10px; width:100%;
  padding:10px 11px; border:0; border-radius:9px; background:transparent;
  color:#4b5563; font-size:13.5px; font-weight:500; text-align:left;
  transition:background .15s, color .15s, box-shadow .15s;
}
.nav-item svg{ width:18px; height:18px; color:var(--muted); flex:0 0 auto; transition:color .15s; }
.nav-item:hover{ background:#f3f4f6; color:var(--text); }
.nav-item:hover svg{ color:var(--text); }
.nav-item.active{ background:var(--green-soft); color:var(--green-dark); font-weight:600; box-shadow:inset 0 0 0 1px #bbf7d0; }
.nav-item.active svg{ color:var(--green); }
.nav-item .nav-ico{ width:21px; height:21px; flex:0 0 auto; filter:saturate(.5) opacity(.72); transition:filter .15s, transform .15s; }
.nav-item:hover .nav-ico, .nav-item.active .nav-ico{ filter:none; }
.nav-item.active .nav-ico{ transform:scale(1.06); }
.logout{ margin-top:auto; color:var(--muted); box-shadow:0 -1px 0 var(--line-2); padding-top:14px; border-radius:0; }
.logout:hover{ background:var(--red-soft); color:var(--red); }
.logout:hover svg{ color:var(--red); }

.main{ flex:1; min-width:0; margin-left:240px; display:flex; flex-direction:column; }
.topbar{
  position:sticky; top:0; z-index:40;
  display:flex; align-items:center; gap:12px;
  min-height:66px; padding:11px 28px;
  background:rgba(255,255,255,.9);
  border-bottom:1px solid var(--line);
  box-shadow:0 1px 2px rgba(16,24,40,.04);
  backdrop-filter:blur(10px);
}
.topbar-title{ min-width:0; }
.topbar-title h2{ font-size:17px; font-weight:700; letter-spacing:-.3px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.topbar-title p{ font-size:12px; color:var(--muted); margin-top:1px; }
.topbar-actions{ margin-left:auto; display:flex; align-items:center; gap:8px; }
.coin-pill{
  display:flex; align-items:center; gap:8px;
  padding:6px 12px 6px 6px; border-radius:11px;
  background:#fff; border:1px solid var(--line);
  box-shadow:var(--shadow);
}
.coin-pill .coin-glyph{ width:26px; height:26px; display:grid; place-items:center; background:transparent; }
.coin-pill .coin-glyph svg{ width:22px; height:22px; }
.coin-pill b{ font-size:14px; letter-spacing:-.2px; }
.coin-pill small{ font-size:11px; color:var(--muted); padding-left:8px; border-left:1px solid var(--line); }
.icon-btn{
  position:relative; width:38px; height:38px; display:grid; place-items:center;
  border:1px solid var(--line); border-radius:11px; background:#fff; color:var(--muted);
  transition:background .15s, color .15s, border-color .15s;
}
.icon-btn:hover{ background:#f9fafb; color:var(--text); border-color:#d1d5db; }
.icon-btn svg{ width:18px; height:18px; }
.notif-btn .dot{ position:absolute; top:8px; right:9px; width:6px; height:6px; border-radius:50%; background:var(--red); border:2px solid #fff; }
.mobile-menu{ display:none; }
.mobile-menu:hover{ background:var(--green-soft); border-color:#bbf7d0; color:var(--green-dark); }
.avatar{
  width:36px; height:36px; border-radius:10px; display:block; overflow:hidden;
  background:#f3f4f6; flex:0 0 auto; box-shadow:inset 0 0 0 1px rgba(16,24,40,.06);
}
.avatar svg{ width:100%; height:100%; display:block; }
.topbar-actions .avatar{ width:38px; height:38px; border-radius:11px; }
.avatar-btn{ padding:0; border:0; }

.view-root{ padding:24px 28px 36px; flex:1; width:100%; max-width:960px; margin:0 auto; }
.app-footer{
  display:flex; align-items:center; justify-content:space-between; gap:12px;
  padding:0 28px 24px; font-size:11.5px; color:var(--muted-2);
  max-width:960px; width:100%; margin:0 auto;
}
.mobile-nav{ display:none; }
.noscript{ position:fixed; inset:0; display:grid; place-items:center; background:#fff; font-weight:600; z-index:999; }

/* --------------------------------------------------------------------------
   Page / panels
   -------------------------------------------------------------------------- */
.view{ display:flex; flex-direction:column; gap:16px; }

.panel{
  background:var(--card); border:1px solid var(--line);
  border-radius:14px; padding:20px;
  box-shadow:0 1px 2px rgba(16,24,40,.04);
}
.panel-head{ display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:16px; }
.panel-head h3{ font-size:15px; font-weight:700; letter-spacing:-.2px; }
.panel-head p{ font-size:12.5px; color:var(--muted); margin-top:2px; }
.panel-head .btn{ flex:0 0 auto; }

.section-title{ font-size:15px; font-weight:700; margin-bottom:12px; }

/* Balance panel */
.balance-panel{
  display:flex; align-items:flex-end; justify-content:space-between;
  gap:20px; flex-wrap:wrap;
}
.balance-main{ min-width:0; }
.balance-label{
  display:block; font-size:10px; font-weight:600; letter-spacing:1.4px;
  text-transform:uppercase; color:var(--muted);
}
.balance-amount{
  font-size:36px; font-weight:800; letter-spacing:-1.2px; margin-top:4px;
  color:var(--text); font-variant-numeric:tabular-nums; line-height:1.05;
}
.balance-amount small{
  font-size:13px; font-weight:500; letter-spacing:0;
  color:var(--muted); margin-left:4px;
}
.balance-sub{ font-size:12px; color:var(--muted); margin-top:5px; }
.balance-actions{ display:flex; gap:8px; flex-wrap:wrap; }

/* Action grid */
.action-grid{ display:grid; grid-template-columns:repeat(4,1fr); gap:12px; }
.action-card{
  position:relative; overflow:hidden;
  background:linear-gradient(180deg,#fff,#fcfdfc); border:1px solid var(--line); border-radius:var(--r-md);
  padding:14px; display:flex; flex-direction:column; gap:9px;
  transition:transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.action-card::before{
  content:""; position:absolute; inset:0 0 auto 0; height:3px;
  background:var(--accent,var(--green)); opacity:.55;
}
.action-card:nth-child(2){ --accent:var(--violet); }
.action-card:nth-child(3){ --accent:var(--gold); }
.action-card:nth-child(4){ --accent:var(--blue); }
.action-card:hover{
  transform:translateY(-2px);
  border-color:#d7dce2;
  box-shadow:0 14px 26px -18px rgba(16,24,40,.45);
}
.ac-top{ display:flex; align-items:center; justify-content:space-between; }
.ac-icon{
  width:34px; height:34px; border-radius:9px; display:grid; place-items:center;
  background:var(--green-soft); color:var(--green-dark);
}
.ac-icon.gold{ background:#fffbeb; color:var(--gold); }
.ac-icon.violet{ background:#f5f3ff; color:var(--violet); }
.ac-icon.blue{ background:#eff6ff; color:var(--blue); }
.ac-icon svg{ width:17px; height:17px; }
.ac-title{ font-size:13.5px; font-weight:600; }
.ac-meta{ font-size:11.5px; color:var(--muted); }
.action-card .btn{ width:100%; margin-top:2px; }

/* Missions */
.mission-list{ display:flex; flex-direction:column; gap:8px; }
.mission{
  display:flex; align-items:center; gap:12px; padding:12px;
  border-radius:10px; border:1px solid var(--line-2); background:#fafbfc;
}
.mission-icon{ width:34px; height:34px; border-radius:8px; display:grid; place-items:center; flex:0 0 auto; background:var(--green-soft); color:var(--green-dark); }
.mission-icon.violet{ background:#f5f3ff; color:var(--violet); }
.mission-icon.gold{ background:#fffbeb; color:var(--gold); }
.mission-icon.wa{ background:#dcfce7; color:#15803d; }
.mission-icon svg{ width:16px; height:16px; }
.mission-body{ flex:1; min-width:0; }
.mission-body b{ display:block; font-size:13px; font-weight:600; }
.mission-body span{ font-size:11.5px; color:var(--muted); }
.mission-progress{ display:flex; align-items:center; gap:8px; margin-top:5px; }
.mission-progress .bar{ flex:1; height:5px; border-radius:99px; background:#e5e7eb; overflow:hidden; }
.mission-progress .bar i{ display:block; height:100%; border-radius:inherit; background:var(--green); }
.mission-progress em{ font-style:normal; font-size:10.5px; color:var(--muted); }
.mission .btn, .mission .chip{ flex:0 0 auto; }
.mission.done{ opacity:.65; }

/* Lists / activity */
.list{ display:flex; flex-direction:column; }
.list-row{ display:flex; align-items:center; gap:11px; padding:10px 0; border-bottom:1px solid var(--line-2); }
.list-row:last-child{ border-bottom:0; padding-bottom:0; }
.tx-icon{
  width:34px; height:34px; border-radius:8px; flex:0 0 auto; display:grid; place-items:center;
  background:var(--green-soft); color:var(--green-dark);
}
.tx-icon.out{ background:var(--red-soft); color:var(--red); }
.tx-icon svg{ width:16px; height:16px; }
.tx-body{ flex:1; min-width:0; }
.tx-body b{ display:block; font-size:13px; font-weight:500; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.tx-body span{ font-size:11.5px; color:var(--muted); }
.tx-amt{ text-align:right; font-size:13px; font-weight:700; color:var(--green-dark); white-space:nowrap; }
.tx-amt.out{ color:var(--red); }
.tx-amt span{ display:block; font-size:10.5px; color:var(--muted-2); font-weight:400; }
.empty{ padding:28px 16px; text-align:center; color:var(--muted); display:flex; flex-direction:column; align-items:center; gap:8px; }
.empty > span{ width:46px; height:46px; border-radius:14px; display:grid; place-items:center; background:var(--green-soft); color:var(--green-dark); }
.empty > span svg{ width:21px; height:21px; }
.empty b{ font-size:13px; color:var(--text); font-weight:600; }
.empty p{ font-size:12px; max-width:260px; }

/* Referral */
.invite-panel{ display:grid; grid-template-columns:minmax(0,1fr) auto; gap:24px; align-items:center; }
.invite-info h3{ font-size:16px; font-weight:700; margin-top:5px; }
.invite-info .form-note{ margin-top:4px; max-width:330px; }
.invite-code{ display:flex; flex-direction:column; gap:8px; min-width:230px; }
.invite-code .ref-code{ justify-content:center; }
.invite-code .ref-actions .btn{ flex:1; justify-content:center; }
.ref-label{ font-size:11px; font-weight:600; letter-spacing:1.1px; text-transform:uppercase; color:var(--muted); }
.ref-hero{ display:flex; flex-direction:column; align-items:stretch; gap:14px; }
.ref-hero-foot{ display:flex; align-items:center; justify-content:space-between; gap:16px; flex-wrap:wrap; padding-top:14px; border-top:1px solid var(--line-2); }
.ref-code-box{ display:flex; flex-direction:column; gap:8px; }
.ref-code{
  display:flex; align-items:center; gap:10px;
  padding:10px 14px; border-radius:9px; border:1px dashed #86efac; background:var(--green-soft);
}
.ref-code b{ font-size:20px; font-weight:800; letter-spacing:1.5px; color:var(--green-dark); }
.ref-link{ font-size:11.5px; color:var(--muted); background:#f9fafb; padding:7px 10px; border-radius:7px; border:1px solid var(--line-2); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; max-width:260px; }
.ref-actions{ display:flex; gap:8px; flex-wrap:wrap; }
.ref-stats{ display:flex; gap:28px; }
.ref-stats div{ display:flex; flex-direction:column; }
.ref-stats b{ font-size:20px; font-weight:800; letter-spacing:-.5px; }
.ref-stats span{ font-size:11px; color:var(--muted); }
.ref-network{ display:flex; align-items:center; gap:10px; padding:10px 0; border-bottom:1px solid var(--line-2); }
.ref-network:last-child{ border-bottom:0; padding-bottom:0; }
.ref-network .avatar{ width:32px; height:32px; font-size:12px; }
.rn-body{ flex:1; min-width:0; }
.rn-body b{ font-size:13px; display:block; }
.rn-body span{ font-size:11.5px; color:var(--muted); }
.rn-earn{ font-size:12.5px; font-weight:700; color:var(--green-dark); }
.steps{ display:grid; grid-template-columns:repeat(3,1fr); gap:12px; }
.step{ padding:14px; border-radius:10px; border:1px solid var(--line-2); background:#fafbfc; }
.step-num{ width:24px; height:24px; border-radius:7px; display:grid; place-items:center; background:var(--green-soft); color:var(--green-dark); font-weight:700; font-size:12px; margin-bottom:8px; }
.step b{ font-size:12.5px; display:block; margin-bottom:2px; }
.step p{ font-size:11.5px; color:var(--muted); line-height:1.5; }

/* Check-in */
.checkin-days{ display:grid; grid-template-columns:repeat(7,1fr); gap:7px; }
.ci-day{
  border-radius:10px; border:1px solid var(--line); background:#fafbfc;
  padding:9px 3px; display:flex; flex-direction:column; align-items:center; gap:3px; text-align:center;
  transition:transform .15s ease, box-shadow .15s ease;
}
.ci-day:hover{ transform:translateY(-1px); box-shadow:0 8px 16px -14px rgba(16,24,40,.5); }
.ci-day span{ font-size:9.5px; color:var(--muted); font-weight:600; }
.ci-day i{ width:20px; height:20px; border-radius:50%; display:grid; place-items:center; background:#f3f4f6; color:var(--muted); font-style:normal; }
.ci-day i svg{ width:11px; height:11px; }
.ci-day b{ font-size:11px; font-weight:600; }
.ci-day.done{ background:var(--green-soft); border-color:#bbf7d0; }
.ci-day.done i{ background:#dcfce7; color:var(--green-dark); }
.ci-day.today{ background:#fffbeb; border-color:#fde68a; }
.ci-day.today i{ background:#fef3c7; color:var(--gold); }
.ci-foot{ display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; margin-top:14px; }
.ci-foot p{ font-size:12px; color:var(--muted); }

/* Earn cards */
.earn-grid{ display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.earn-card{
  padding:18px; border-radius:14px; border:1px solid var(--line); background:var(--card);
  display:flex; flex-direction:column; gap:12px;
  transition:transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.earn-card:hover{ transform:translateY(-2px); border-color:#d7dce2; box-shadow:0 14px 26px -18px rgba(16,24,40,.4); }
.ec-head{ display:flex; align-items:center; gap:10px; }
.ec-icon{ width:38px; height:38px; border-radius:11px; display:grid; place-items:center; flex:0 0 auto; background:var(--green-soft); color:var(--green-dark); box-shadow:0 7px 14px -10px rgba(22,163,74,.85); }
.ec-icon.violet{ background:#f5f3ff; color:var(--violet); box-shadow:0 7px 14px -10px rgba(124,58,237,.85); }
.ec-icon svg{ width:19px; height:19px; }
.ec-head h3{ font-size:14.5px; font-weight:700; }
.ec-head p{ font-size:11.5px; color:var(--muted); }
.ec-meta{ display:flex; gap:20px; }
.ec-meta div{ display:flex; flex-direction:column; }
.ec-meta span{ font-size:10.5px; color:var(--muted); }
.ec-meta b{ font-size:13px; }
.bar{ height:6px; border-radius:99px; background:#e5e7eb; overflow:hidden; }
.bar i{ display:block; height:100%; border-radius:inherit; background:var(--green); }
.bar i.violet{ background:var(--violet); }

/* Spin */
.spin-box{ display:flex; align-items:center; gap:16px; flex-wrap:wrap; }
.spin-badge{ width:54px; height:54px; border-radius:50%; display:grid; place-items:center; background:#fffbeb; color:var(--gold); flex:0 0 auto; }
.spin-badge svg{ width:24px; height:24px; }
.spin-info{ flex:1; min-width:160px; }
.spin-info b{ font-size:13.5px; display:block; }
.spin-info span{ font-size:11.5px; color:var(--muted); }

/* Wallet */
.withdraw-methods{ display:flex; gap:4px; padding:4px; border-radius:11px; background:#f3f4f6; border:1px solid var(--line-2); max-width:420px; }
.method{
  flex:1; display:flex; align-items:center; justify-content:center; gap:6px;
  padding:9px 8px; border:1px solid transparent; border-radius:8px;
  background:transparent; font-size:12.5px; font-weight:600; color:var(--muted);
  transition:background .15s, color .15s, box-shadow .15s;
}
.method:hover{ color:var(--text); }
.method.active{ background:#fff; border-color:var(--line); color:var(--green-dark); box-shadow:0 1px 3px rgba(16,24,40,.1); }
.method.active::before{ content:""; width:6px; height:6px; border-radius:50%; background:var(--green); flex:0 0 auto; }

/* Transactions table */
.filter-row{ display:flex; gap:6px; flex-wrap:wrap; }
.filter-row .chip{ cursor:pointer; background:#fff; }
.filter-row .chip.active{ background:var(--green-soft); border-color:#86efac; color:var(--green-dark); }
.table-wrap{ overflow-x:auto; }
table.data{ width:100%; border-collapse:collapse; font-size:12.5px; min-width:520px; }
table.data th{ text-align:left; padding:8px 10px; font-size:10.5px; text-transform:uppercase; letter-spacing:.5px; color:var(--muted); font-weight:600; border-bottom:1px solid var(--line); background:#fafbfc; white-space:nowrap; }
table.data td{ padding:11px 10px; border-bottom:1px solid var(--line-2); vertical-align:middle; }
table.data tr:last-child td{ border-bottom:0; }
table.data .t-type{ display:flex; align-items:center; gap:8px; font-weight:500; }
table.data .t-type .tx-icon{ width:28px; height:28px; border-radius:7px; }
table.data .t-amt{ font-weight:700; color:var(--green-dark); white-space:nowrap; text-align:right; }
table.data .t-amt.out{ color:var(--red); }
table.data .t-date{ color:var(--muted); font-size:11.5px; white-space:nowrap; }
table.data tbody tr:hover{ background:#fafbfc; }
.tx-more{ display:flex; justify-content:center; padding-top:12px; }
.tx-more .btn{ min-width:200px; }
.tx-more .btn span{ color:var(--muted); font-weight:500; }
.tx-status{ margin-left:6px; padding:1px 7px; font-size:10px; vertical-align:middle; }

/* Withdrawal requests */
.wd-list{ display:flex; flex-direction:column; }
.wd-row{
  display:flex; align-items:center; gap:11px;
  padding:12px 2px; border-bottom:1px solid var(--line-2);
}
.wd-row:last-child{ border-bottom:0; }
.wd-row .tx-icon{ width:32px; height:32px; border-radius:8px; flex-shrink:0; }
.wd-body{ display:flex; flex-direction:column; gap:2px; min-width:0; flex:1; }
.wd-body b{ font-size:12.5px; font-weight:600; color:var(--ink); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.wd-body span{ font-size:11px; color:var(--muted); }
.wd-side{ display:flex; align-items:center; gap:8px; flex-shrink:0; }
.wd-side b{ font-size:12.5px; font-weight:700; color:var(--red); white-space:nowrap; }

/* Leaderboard gap */
.lb-gap{ display:flex; justify-content:center; align-items:center; padding:2px 0 6px; color:var(--muted); font-weight:700; letter-spacing:4px; }

/* Leaderboard */
.lb-hero{
  position:relative; overflow:hidden;
  display:flex; align-items:center; justify-content:space-between; gap:18px;
  padding:20px; border-radius:16px;
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(22,163,74,.09), transparent 55%),
    linear-gradient(180deg,#ffffff 0%, #fbfdfc 100%);
  border:1px solid var(--line);
  box-shadow:0 1px 2px rgba(16,24,40,.04), 0 16px 36px -30px rgba(16,24,40,.4);
}
.lb-hero::after{
  content:""; position:absolute; top:0; left:0; width:100%; height:3px; pointer-events:none;
  background:linear-gradient(90deg,var(--green),#4ade80 55%,transparent 92%);
  opacity:.75;
}
.lb-hero-rank{ display:flex; align-items:baseline; gap:6px; margin-top:2px; font-size:36px; font-weight:800; letter-spacing:-1.4px; font-variant-numeric:tabular-nums; }
.lb-hero-rank small{ font-size:13px; font-weight:500; letter-spacing:0; color:var(--muted); }
.lb-hero p{ font-size:12px; color:var(--muted); margin-top:2px; }
.lb-hero-badge{ width:54px; height:54px; border-radius:16px; flex:0 0 auto; display:grid; place-items:center; background:var(--green-soft); color:var(--green-dark); }
.lb-hero-badge svg{ width:26px; height:26px; }
.lb-list{ display:flex; flex-direction:column; }
.lb-row{ display:flex; align-items:center; gap:11px; padding:10px 8px; border-bottom:1px solid var(--line-2); border-radius:8px; transition:background .15s; }
.lb-row:last-child{ border-bottom:0; }
.lb-row:hover{ background:#f9fafb; }
.lb-row.me{ background:var(--green-soft); border-bottom-color:transparent; }
.lb-row.me:hover{ background:var(--green-soft); }
.lb-list .lb-row:nth-child(1):not(.me){ background:linear-gradient(90deg,rgba(251,191,36,.14),transparent 72%); }
.lb-list .lb-row:nth-child(2):not(.me){ background:linear-gradient(90deg,rgba(148,163,184,.16),transparent 72%); }
.lb-list .lb-row:nth-child(3):not(.me){ background:linear-gradient(90deg,rgba(251,146,60,.12),transparent 72%); }
.lb-rank{ width:26px; text-align:center; font-size:12px; font-weight:700; color:var(--muted); }
.lb-list .lb-row:nth-child(1) .lb-rank{ background:#fffbeb; color:#b45309; }
.lb-list .lb-row:nth-child(2) .lb-rank{ background:#f1f5f9; color:#475569; }
.lb-list .lb-row:nth-child(3) .lb-rank{ background:#fff7ed; color:#9a3412; }
.lb-list .lb-row:nth-child(-n+3) .lb-rank{ width:24px; height:24px; display:grid; place-items:center; border-radius:8px; }
.lb-row.me .lb-rank{ color:var(--green-dark); }
.lb-row .avatar{ width:32px; height:32px; font-size:12px; }
.lb-name{ flex:1; min-width:0; font-size:13px; font-weight:500; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.lb-name span{ display:block; font-size:10.5px; color:var(--muted); font-weight:400; }
.lb-coins{ font-size:13px; font-weight:700; white-space:nowrap; }

/* Profile */
.profile-grid{ display:grid; grid-template-columns:280px minmax(0,1fr); gap:16px; align-items:start; }
.profile-card{ padding:22px; border-radius:14px; border:1px solid var(--line); background:linear-gradient(180deg,#f8fdfa,#ffffff 45%); text-align:center; box-shadow:0 1px 2px rgba(16,24,40,.04); }
.profile-card .avatar{ width:64px; height:64px; font-size:24px; border-radius:16px; margin:0 auto 12px; box-shadow:0 0 0 4px #fff, 0 0 0 5px #d1fae5; }
.profile-card h3{ font-size:16px; font-weight:700; }
.profile-card p{ font-size:12px; color:var(--muted); margin-top:2px; }
.profile-meta{ display:flex; justify-content:center; gap:6px; flex-wrap:wrap; margin-top:10px; }
.profile-stats{ display:grid; grid-template-columns:1fr 1fr; gap:8px; margin-top:18px; }
.profile-stat{ padding:10px; border-radius:8px; background:#f9fafb; border:1px solid var(--line-2); }
.profile-stat b{ display:block; font-size:14px; }
.profile-stat span{ font-size:10px; color:var(--muted); }
.profile-actions{ display:flex; gap:8px; margin-top:14px; }
.profile-actions .btn{ flex:1; }
.settings-stack{ display:flex; flex-direction:column; gap:16px; }
.settings-panel{ padding:20px; border-radius:14px; border:1px solid var(--line); background:var(--card); box-shadow:0 1px 2px rgba(16,24,40,.04); }
.settings-panel h3{ font-size:14px; font-weight:700; margin-bottom:2px; }
.settings-panel > p{ font-size:12px; color:var(--muted); margin-bottom:14px; }
.settings-panel .form-grid{ grid-template-columns:1fr 1fr; }
.settings-panel .form-grid .full{ grid-column:1/-1; }
.settings-actions{ display:flex; gap:8px; margin-top:14px; flex-wrap:wrap; }

/* Help & support */
.help-hero{
  display:flex; align-items:center; gap:14px; padding:20px; border-radius:14px;
  border:1px solid var(--line); background:linear-gradient(180deg,#f8fdfa,#ffffff 55%);
  box-shadow:0 1px 2px rgba(16,24,40,.04);
}
.help-hero-icon{ width:52px; height:52px; border-radius:15px; flex:0 0 auto; display:grid; place-items:center; background:var(--green-soft); color:var(--green-dark); }
.help-hero-icon svg{ width:25px; height:25px; }
.help-hero h3{ font-size:17px; font-weight:700; letter-spacing:-.3px; }
.help-hero p{ font-size:12.5px; color:var(--muted); margin-top:2px; }
.help-grid{ display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.support-card{
  display:flex; align-items:center; gap:12px; padding:14px;
  border-radius:12px; border:1px solid var(--line); background:#fff;
  transition:border-color .15s, box-shadow .15s, transform .15s;
}
.support-card:hover{ border-color:#d7dce2; box-shadow:0 12px 24px -18px rgba(16,24,40,.4); transform:translateY(-1px); }
.support-icon{ width:40px; height:40px; border-radius:11px; flex:0 0 auto; display:grid; place-items:center; background:var(--green-soft); color:var(--green-dark); }
.support-icon.wa{ background:#dcfce7; color:#15803d; }
.support-icon svg{ width:19px; height:19px; }
.support-body{ flex:1; min-width:0; }
.support-body b{ display:block; font-size:13px; font-weight:600; }
.support-body span{ display:block; font-size:11.5px; color:var(--muted); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.support-link{ display:inline-flex; align-items:center; gap:4px; flex:0 0 auto; font-size:11.5px; font-weight:600; color:var(--green-dark); }
.support-link svg{ width:13px; height:13px; }
.faq-list{ display:flex; flex-direction:column; gap:8px; }
.faq{ border:1px solid var(--line-2); border-radius:10px; background:#fafbfc; }
.faq summary{
  list-style:none; cursor:pointer; padding:12px 14px; font-size:13px; font-weight:600;
  display:flex; align-items:center; justify-content:space-between; gap:12px;
}
.faq summary::-webkit-details-marker{ display:none; }
.faq summary::after{ content:"+"; font-size:16px; font-weight:600; color:var(--muted); line-height:1; }
.faq[open] summary::after{ content:"–"; }
.faq p{ padding:0 14px 12px; font-size:12.5px; color:var(--muted); line-height:1.6; }

/* --------------------------------------------------------------------------
   Modal
   -------------------------------------------------------------------------- */
.modal-scrim{
  position:fixed; inset:0; z-index:200;
  background:rgba(17,24,39,.5);
  display:flex; align-items:center; justify-content:center;
  padding:20px; animation:fadeIn .18s ease both;
}
@keyframes fadeIn{ from{ opacity:0 } to{ opacity:1 } }
.modal{
  width:100%; max-width:440px; max-height:92vh; overflow-y:auto;
  background:var(--card); border-radius:var(--r-lg);
  box-shadow:var(--shadow-md);
  animation:modalIn .22s ease both;
}
@keyframes modalIn{ from{ opacity:0; transform:translateY(10px); } to{ opacity:1; transform:none; } }
.modal.modal-wide{ max-width:500px; }
.modal.modal-ad{ max-width:480px; overflow:hidden; }
.modal-head{ display:flex; align-items:flex-start; justify-content:space-between; gap:12px; padding:18px 20px 0; }
.modal-head h3{ font-size:16px; font-weight:700; }
.modal-head p{ font-size:12px; color:var(--muted); margin-top:2px; }
.modal-close{ width:30px; height:30px; border-radius:7px; border:1px solid var(--line); background:#fff; display:grid; place-items:center; color:var(--muted); flex:0 0 auto; }
.modal-close:hover{ background:#f3f4f6; }
.modal-close svg{ width:15px; height:15px; }
.modal-body{ padding:16px 20px 20px; }
.modal-foot{ display:flex; gap:8px; padding:0 20px 20px; }
.modal-foot .btn{ flex:1; }

/* Ad player */
.ad-wrap{ padding:0; }
.ad-creative{
  position:relative; aspect-ratio:16/9; overflow:hidden;
  display:flex; flex-direction:column; justify-content:space-between;
  padding:18px; color:#fff; background:var(--ad-bg);
}
.ad-top{ display:flex; align-items:center; justify-content:space-between; }
.ad-brand{ display:flex; align-items:center; gap:8px; font-weight:700; font-size:13px; }
.ad-logo{ width:30px; height:30px; border-radius:8px; display:grid; place-items:center; background:rgba(255,255,255,.22); font-size:15px; font-weight:800; }
.ad-badge{ font-size:9.5px; font-weight:700; letter-spacing:.6px; text-transform:uppercase; background:rgba(0,0,0,.25); padding:4px 8px; border-radius:5px; }
.ad-center{ display:flex; flex-direction:column; align-items:center; text-align:center; gap:5px; }
.ad-headline{ font-size:24px; font-weight:800; letter-spacing:-.6px; }
.ad-tagline{ font-size:12.5px; opacity:.92; }
.ad-cta{ display:flex; align-items:center; justify-content:space-between; }
.fake-btn{ background:#fff; color:#111827; padding:7px 14px; border-radius:7px; font-size:11px; font-weight:700; }
.ad-sponsored{ font-size:9.5px; opacity:.85; text-transform:uppercase; letter-spacing:.5px; }
.ad-progress-wrap{ padding:14px 18px; border-bottom:1px solid var(--line); }
.ad-timer-row{ display:flex; align-items:center; justify-content:space-between; gap:10px; font-size:12px; color:var(--muted); margin-bottom:8px; }
.ad-timer-row b{ color:var(--text); font-weight:600; }
.ad-progress{ height:6px; border-radius:99px; background:#e5e7eb; overflow:hidden; }
.ad-progress i{ display:block; height:100%; width:0%; border-radius:inherit; background:var(--green); transition:width .2s linear; }
.ad-foot{ display:flex; align-items:center; justify-content:space-between; gap:10px; padding:12px 18px 16px; }
.ad-foot p{ font-size:11px; color:var(--muted); }
.ad-reward{ text-align:center; padding:28px 22px 22px; }
.reward-icon{ width:60px; height:60px; margin:0 auto 12px; border-radius:50%; display:grid; place-items:center; background:var(--green-soft); color:var(--green-dark); }
.reward-icon svg{ width:28px; height:28px; }
.ad-reward h3{ font-size:18px; font-weight:700; }
.ad-reward p{ font-size:12.5px; color:var(--muted); margin-top:3px; }
.reward-amount{ display:inline-flex; align-items:center; gap:6px; margin:16px 0 18px; font-size:30px; font-weight:800; letter-spacing:-.8px; color:var(--green-dark); }
.reward-amount svg{ width:22px; height:22px; }
.reward-amount small{ font-size:12px; color:var(--muted); font-weight:500; letter-spacing:0; }
.ad-reward .btn{ width:100%; }

/* Spin wheel */
.wheel-modal-body{ display:flex; flex-direction:column; align-items:center; padding:6px 20px 20px; }
.wheel-stage{ position:relative; width:min(280px,72vw); aspect-ratio:1; margin:6px auto 12px; }
.wheel-pointer{ position:absolute; top:-5px; left:50%; transform:translateX(-50%); z-index:3; width:0; height:0; border-left:10px solid transparent; border-right:10px solid transparent; border-top:18px solid #111827; }
.wheel{
  width:100%; height:100%; border-radius:50%; position:relative;
  background:conic-gradient(#fbbf24 0deg 60deg,#f472b6 60deg 120deg,#a78bfa 120deg 180deg,#67e8f9 180deg 240deg,#4ade80 240deg 300deg,#fdba74 300deg 360deg);
  border:6px solid #fff;
  box-shadow:0 0 0 1px var(--line), 0 12px 30px -12px rgba(16,24,40,.25);
  transition:transform 4s cubic-bezier(.12,.72,.08,1);
}
.wheel-labels{ position:absolute; inset:0; pointer-events:none; }
.wheel-labels span{
  position:absolute; top:50%; left:50%;
  font-size:10.5px; font-weight:700; color:#111827; white-space:nowrap;
}
.wheel-hub{
  position:absolute; inset:50% auto auto 50%; transform:translate(-50%,-50%);
  width:58px; height:58px; border-radius:50%; background:#fff;
  border:1px solid var(--line); display:grid; place-items:center; z-index:2;
  color:var(--green-dark);
}
.wheel-hub svg{ width:22px; height:22px; }

/* Notifications */
.notif-head{ align-items:center; }
.notif-head-side{ display:flex; align-items:center; gap:8px; flex:0 0 auto; }
.notif-body{ padding-top:14px; }
.notif-day{ display:flex; align-items:center; justify-content:space-between; padding:0 2px 8px; }
.notif-day span{ font-size:11px; font-weight:700; letter-spacing:.8px; text-transform:uppercase; color:var(--muted); }
.notif-day em{ font-style:normal; font-size:11px; color:var(--muted-2); }
.notif-list{ display:flex; flex-direction:column; gap:8px; }
.notif-item{
  width:100%; display:flex; align-items:flex-start; gap:11px; text-align:left;
  padding:12px; border-radius:11px; border:1px solid var(--line-2); background:#fff;
  transition:border-color .15s, background .15s, transform .15s;
}
.notif-item:hover{ background:#fafbfc; border-color:#d7dce2; }
.notif-item:active{ transform:translateY(1px); }
.notif-icon{ width:34px; height:34px; border-radius:9px; flex:0 0 auto; display:grid; place-items:center; background:var(--green-soft); color:var(--green-dark); }
.notif-icon.gold{ background:#fffbeb; color:var(--gold); }
.notif-icon.violet{ background:#f5f3ff; color:var(--violet); }
.notif-icon svg{ width:16px; height:16px; }
.notif-content{ flex:1; min-width:0; }
.notif-cat{ display:block; font-size:9.5px; font-weight:700; letter-spacing:.9px; text-transform:uppercase; color:var(--muted-2); margin-bottom:1px; }
.notif-content b{ display:block; font-size:13px; font-weight:600; line-height:1.35; }
.notif-content p{ font-size:11.5px; color:var(--muted); margin-top:2px; line-height:1.45; }
.notif-arrow{ color:var(--muted-2); align-self:center; flex:0 0 auto; }
.notif-arrow svg{ width:15px; height:15px; }

/* Toast */
.toast-root{ position:fixed; right:18px; bottom:18px; z-index:300; display:flex; flex-direction:column; gap:8px; pointer-events:none; }
.toast{
  display:flex; align-items:center; gap:9px; min-width:230px; max-width:340px;
  padding:11px 14px; border-radius:10px;
  background:#111827; color:#fff;
  box-shadow:0 12px 30px -10px rgba(16,24,40,.5);
  font-size:12.5px; font-weight:500;
  animation:toastIn .22s ease both;
}
.toast.out{ animation:toastOut .2s ease forwards; }
@keyframes toastIn{ from{ opacity:0; transform:translateY(8px); } to{ opacity:1; transform:none; } }
@keyframes toastOut{ to{ opacity:0; } }
.toast-icon{ width:24px; height:24px; border-radius:6px; flex:0 0 auto; display:grid; place-items:center; background:rgba(255,255,255,.14); }
.toast-icon svg{ width:14px; height:14px; }
.toast.error .toast-icon{ background:rgba(220,38,38,.3); }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width:1080px){
  .auth-wrap{ grid-template-columns:1fr; max-width:420px; gap:0; }
  .auth-intro{ display:none; }
  .auth-brand{ display:inline-flex; }
  .sidebar{ transform:translateX(-100%); transition:transform .25s ease; }
  .app.menu-open .sidebar{ transform:none; }
  .main{ margin-left:0; }
  .mobile-menu{ display:grid; }
  .topbar{ padding:10px 18px; }
  .view-root{ padding:18px 18px 104px; }
  .app-footer{ display:none; }
  .mobile-nav{
    position:fixed; z-index:80;
    left:50%; transform:translateX(-50%);
    bottom:calc(10px + env(safe-area-inset-bottom));
    width:calc(100% - 24px); max-width:540px;
    display:grid; grid-template-columns:repeat(5,1fr); align-items:end;
    padding:9px 8px 8px; background:#fff;
    border:1px solid var(--line); border-radius:20px;
    box-shadow:0 16px 36px -18px rgba(16,24,40,.4), 0 3px 8px rgba(16,24,40,.05);
  }
  .mnav-item{
    position:relative; display:flex; flex-direction:column; align-items:center; gap:4px;
    border:0; background:transparent; color:var(--muted-2);
    font-size:10.5px; font-weight:600; padding:0; line-height:1;
    transition:color .16s; -webkit-tap-highlight-color:transparent;
  }
  .mnav-icon{
    width:44px; height:30px; border-radius:9px; display:grid; place-items:center;
    transition:background .16s, color .16s;
  }
  .mnav-icon svg{ width:22px; height:22px; filter:saturate(.5) opacity(.72); transition:filter .15s; }
  .mnav-item:hover .mnav-icon svg, .mnav-item.active .mnav-icon svg{ filter:none; }
  .mnav-item:hover{ color:var(--muted); }
  .mnav-item:active .mnav-icon{ background:#f3f4f6; }
  .mnav-item.active{ color:var(--green-dark); font-weight:700; }
  .mnav-item.active .mnav-icon{ background:var(--green-soft); color:var(--green-dark); }
  .mnav-center .mnav-fab{
    width:50px; height:50px; margin-top:-28px; border-radius:16px;
    display:grid; place-items:center;
    background:var(--green); color:#fff;
    box-shadow:0 10px 20px -8px rgba(22,163,74,.65), 0 0 0 4px #fff;
    transform:translateY(-10px);
    transition:background .16s, transform .16s, box-shadow .16s;
  }
  .mnav-center .mnav-fab svg{ width:24px; height:24px; filter:none; }
  .mnav-center:active .mnav-fab{ transform:translateY(-10px) scale(.95); }
  .mnav-center.active .mnav-fab{ background:var(--green-dark); box-shadow:0 10px 20px -8px rgba(21,128,61,.7), 0 0 0 4px #fff; }
  .mnav-center .mnav-label{ margin-top:1px; }
  .toast-root{ bottom:100px; right:12px; left:12px; align-items:stretch; }
  .toast{ max-width:none; width:100%; }
}

@media (max-width:860px){
  .action-grid{ grid-template-columns:1fr 1fr; }
  .earn-grid{ grid-template-columns:1fr; }
  .profile-grid{ grid-template-columns:1fr; }
  .profile-card{ max-width:380px; margin:0 auto; width:100%; }
  .settings-panel .form-grid{ grid-template-columns:1fr; }
}

@media (max-width:640px){
  body{ font-size:14px; }
  .auth{ padding:20px 14px; }
  .auth-card{ padding:22px 18px; }
  .topbar{ gap:8px; padding:9px 12px; min-height:60px; }
  .topbar-title p{ display:none; }
  .topbar-title h2{ font-size:16px; }
  .topbar-actions{ gap:6px; }
  .coin-pill{ padding:5px 9px 5px 5px; gap:6px; border-radius:10px; }
  .coin-pill .coin-glyph{ width:24px; height:24px; }
  .coin-pill .coin-glyph svg{ width:20px; height:20px; }
  .coin-pill b{ font-size:13px; }
  .coin-pill small{ display:none; }
  .topbar-actions .icon-btn{ width:36px; height:36px; border-radius:10px; }
  .topbar-actions .avatar{ width:36px; height:36px; border-radius:10px; }
  .view-root{ padding:14px 14px 100px; }
  .view{ gap:14px; }
  .panel, .settings-panel{ padding:16px; }
  .balance-panel{ gap:14px; }
  .balance-amount{ font-size:30px; }
  .balance-actions{ width:100%; }
  .balance-actions .btn{ flex:1; justify-content:center; }
  .action-grid{ gap:10px; }
  .action-card{ padding:12px; }
  .ac-title{ font-size:12.5px; }
  .ac-meta{ font-size:11px; }
  .field-row{ grid-template-columns:1fr; }
  .checkin-days{ gap:5px; }
  .ci-day{ padding:7px 2px; }
  .ci-day span{ font-size:8.5px; }
  .ci-day b{ font-size:9.5px; }
  .earn-grid{ grid-template-columns:1fr 1fr; gap:10px; }
  .earn-card{ padding:12px; gap:9px; border-radius:12px; }
  .ec-head{ gap:8px; }
  .ec-icon{ width:32px; height:32px; border-radius:9px; }
  .ec-icon svg{ width:16px; height:16px; }
  .ec-head h3{ font-size:12.5px; line-height:1.25; }
  .ec-head p{ display:none; }
  .ec-meta{ gap:0; justify-content:space-between; }
  .ec-meta span{ font-size:9.5px; }
  .ec-meta b{ font-size:12px; }
  .bar{ height:5px; }
  .earn-card .btn{ padding:8px 6px; font-size:11.5px; border-radius:8px; }
  .invite-panel{ grid-template-columns:1fr; gap:14px; }
  .invite-info .form-note{ max-width:none; }
  .invite-code{ min-width:0; }
  .ref-hero-foot{ align-items:flex-start; }
  .ref-link{ max-width:100%; width:100%; }
  .ref-stats{ gap:22px; }
  .steps{ grid-template-columns:1fr; gap:8px; }
  .step{
    display:grid; grid-template-columns:24px 1fr; grid-template-rows:auto auto;
    column-gap:10px; row-gap:1px; align-items:center; padding:10px 12px;
  }
  .step-num{ grid-row:1 / span 2; width:22px; height:22px; margin:0; font-size:11px; }
  .step b{ grid-column:2; margin:0; }
  .step p{ grid-column:2; font-size:11px; }
  .settings-panel .form-grid{ grid-template-columns:1fr; }
  .help-hero{ padding:16px; }
  .help-grid{ grid-template-columns:1fr; gap:10px; }
  .support-link{ display:none; }
  .modal-scrim{ padding:12px; align-items:flex-end; }
  .modal{ max-width:none; border-radius:14px 14px 10px 10px; }
  .ad-headline{ font-size:20px; }
  .lb-row{ padding:9px 6px; }
}

@media (max-width:520px){
  .panel-head{ flex-wrap:wrap; }
  .panel-head .filter-row{ width:100%; }
  table.data{ min-width:0; }
  table.data th, table.data td{ padding:9px 6px; }
  table.data .t-date{ white-space:normal; width:74px; font-size:10.5px; }
  .wa-task{ flex-wrap:wrap; }
  .wa-task .mission-body{ flex:1 1 calc(100% - 46px); }
  .wa-task .btn, .wa-task .chip{ flex:0 0 auto; margin-left:46px; }
}

@media (max-width:380px){
  .topbar{ gap:6px; padding:9px 10px; }
  .topbar-title h2{ font-size:15px; }
  .topbar-actions{ gap:4px; }
  .coin-pill{ gap:5px; padding:4px 8px 4px 4px; }
  .coin-pill .coin-glyph{ width:22px; height:22px; }
  .coin-pill .coin-glyph svg{ width:18px; height:18px; }
  .topbar-actions .icon-btn, .topbar-actions .avatar{ width:34px; height:34px; border-radius:10px; }
}
