/* ==========================================================================
   CycleETH — neon aurora, mobile-first app theme
   --------------------------------------------------------------------------
   1. Tokens            5. Cards & stats        9. Lists & tables
   2. Base              6. Buttons & chips     10. Sheets, toasts
   3. App shell         7. Forms               11. Public (landing) pages
   4. Navigation        8. Progress & rings    12. Utilities
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
  color-scheme: dark;
  --bg: #0b0a1f;
  --surface: rgba(255, 255, 255, .065);
  --surface-2: rgba(255, 255, 255, .045);
  --surface-solid: #191541;
  --ink: #f6f4ff;
  --ink-2: #cdc7ef;
  --ink-3: #9590c4;
  --line: rgba(255, 255, 255, .12);

  --lavender: rgba(139, 92, 246, .24);  --lavender-ink: #c9b8ff;
  --mint: rgba(16, 185, 129, .2);       --mint-ink: #5eead4;
  --peach: rgba(249, 115, 22, .22);     --peach-ink: #fdba74;
  --sky: rgba(14, 165, 233, .22);       --sky-ink: #7dd3fc;
  --butter: rgba(234, 179, 8, .2);      --butter-ink: #fde047;
  --rose: rgba(236, 72, 153, .24);      --rose-ink: #f9a8d4;

  --gold: #fbbf24;
  --gold-soft: rgba(251, 191, 36, .18);
  --primary: #a855f7;
  --primary-hover: #9333ea;
  --accent: #22d3ee;
  --danger: #fb7185;
  --grad: linear-gradient(135deg, #7c3aed 0%, #db2777 55%, #f97316 100%);
  --grad-cool: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #22d3ee 100%);

  --radius: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --shadow: 0 1px 0 rgba(255, 255, 255, .06) inset, 0 14px 34px -18px rgba(0, 0, 0, .7);
  --shadow-lg: 0 24px 60px -18px rgba(0, 0, 0, .75);
  --glass: saturate(150%) blur(14px);

  --topbar-h: 60px;
  --tabbar-h: 66px;
  --sidebar-w: 264px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);

  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Poppins", var(--font);
  --ease: cubic-bezier(.2, .8, .2, 1);
}

/* 2. Base ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
body::before, body::after {
  content: ""; position: fixed; inset: -20vmax; z-index: -1; pointer-events: none;
}
body::before {
  background:
    radial-gradient(38vmax 38vmax at 12% 8%, rgba(124, 58, 237, .55), transparent 70%),
    radial-gradient(34vmax 34vmax at 88% 18%, rgba(219, 39, 119, .42), transparent 70%),
    radial-gradient(40vmax 40vmax at 78% 92%, rgba(34, 211, 238, .30), transparent 70%),
    radial-gradient(30vmax 30vmax at 18% 88%, rgba(249, 115, 22, .30), transparent 70%),
    linear-gradient(160deg, #0b0a1f 0%, #150f3a 50%, #0a1430 100%);
  animation: aurora 26s ease-in-out infinite alternate;
}
body::after {
  background-image: radial-gradient(rgba(255, 255, 255, .5) 1px, transparent 1.4px);
  background-size: 46px 46px;
  opacity: .08;
}
@keyframes aurora {
  0%   { transform: translate3d(0, 0, 0) rotate(0deg) scale(1); }
  50%  { transform: translate3d(3vmax, -2vmax, 0) rotate(8deg) scale(1.06); }
  100% { transform: translate3d(-3vmax, 2vmax, 0) rotate(-6deg) scale(1.02); }
}
@media (prefers-reduced-motion: reduce) { body::before { animation: none; } }
::selection { background: rgba(168, 85, 247, .45); color: #fff; }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--ink); margin: 0 0 .4em; line-height: 1.2; letter-spacing: -.01em; }
h1 { font-size: 1.6rem; font-weight: 700; }
h2 { font-size: 1.25rem; font-weight: 700; }
h3 { font-size: 1.05rem; font-weight: 600; }
p { margin: 0 0 .8em; color: var(--ink-2); }
a { color: var(--lavender-ink); text-decoration: none; }
img, svg { max-width: 100%; }
code, .mono { font-family: "JetBrains Mono", ui-monospace, Consolas, monospace; font-size: .86em; }
hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }

.ms {
  font-family: "Material Symbols Rounded";
  font-weight: normal; font-style: normal;
  font-size: 22px; line-height: 1;
  letter-spacing: normal; text-transform: none;
  display: inline-block; white-space: nowrap; direction: ltr;
  font-variation-settings: "FILL" 0, "wght" 450, "GRAD" 0, "opsz" 24;
  -webkit-font-smoothing: antialiased;
  vertical-align: middle;
  flex-shrink: 0;
}
.ms.fill { font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24; }

/* 3. App shell ------------------------------------------------------------- */
.main {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  padding: 16px 16px calc(var(--tabbar-h) + var(--safe-b) + 28px);
  animation: rise .35s var(--ease) both;
}
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 4px 0 16px; }
.page-head h1 { margin: 0; }
.page-head p { margin: 2px 0 0; font-size: .9rem; }

.stack > * + * { margin-top: 14px; }
.grid { display: grid; gap: 12px; }
.grid-2 { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.lg-grid-2 > * + *, .lg-grid-3 > * + * { margin-top: 14px; }
.grid-3 { display: grid; gap: 12px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.section-title { display: flex; align-items: center; justify-content: space-between; margin: 22px 2px 10px; }
.section-title h2, .section-title h3 { margin: 0; }
.section-title a { font-size: .85rem; font-weight: 600; }

@media (min-width: 1024px) {
  .main { max-width: 1080px; margin-left: var(--sidebar-w); padding: 28px 40px 48px; }
  .app-anon .main { margin-left: auto; }
  .lg-grid-2 { display: grid; gap: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .lg-grid-3 { display: grid; gap: 16px; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; }
  .lg-span-2 { grid-column: span 2; }
  .lg-grid-2 > * + *, .lg-grid-3 > * + * { margin-top: 0; }
}

/* 4. Navigation ------------------------------------------------------------ */
.topbar {
  position: sticky; top: 0; z-index: 40;
  height: calc(var(--topbar-h) + var(--safe-t));
  padding: var(--safe-t) 12px 0;
  display: flex; align-items: center; gap: 8px;
  background: rgba(11, 10, 31, .5);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.topbar.scrolled { border-bottom-color: var(--line); }
.topbar .brand { display: flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 800; font-size: 1.1rem; color: var(--ink); }
.topbar .brand img { width: 30px; height: 30px; }
.brand img { background: #fff; border-radius: 10px; padding: 3px; box-shadow: 0 0 0 2px rgba(168, 85, 247, .5), 0 6px 18px -6px rgba(219, 39, 119, .8); }
.topbar .brand b { color: var(--gold); font-weight: 800; }
.topbar .title { flex: 1; min-width: 0; font-family: var(--font-display); font-weight: 600; font-size: 1.02rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar .actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.icon-btn {
  position: relative;
  width: 42px; height: 42px; border-radius: 14px;
  display: inline-grid; place-items: center;
  background: var(--surface); color: var(--ink);
  border: 1px solid var(--line);
  cursor: pointer;
  transition: transform .15s var(--ease), background .15s;
}
.icon-btn:active { transform: scale(.94); }
.icon-btn .dot { position: absolute; top: 9px; right: 10px; width: 8px; height: 8px; border-radius: 50%; background: var(--rose-ink); box-shadow: 0 0 0 2px var(--surface); }
.wallet-pill {
  display: inline-flex; align-items: center; gap: 6px;
  height: 42px; padding: 0 12px; border-radius: 14px;
  background: var(--surface); border: 1px solid var(--line);
  font-size: .82rem; font-weight: 600; color: var(--ink-2);
}
.wallet-pill .status { width: 8px; height: 8px; border-radius: 50%; background: var(--mint-ink); }

.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  height: calc(var(--tabbar-h) + var(--safe-b));
  padding: 6px 8px var(--safe-b);
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: rgba(16, 13, 42, .82);
  backdrop-filter: saturate(160%) blur(16px);
  -webkit-backdrop-filter: saturate(160%) blur(16px);
  border-top: 1px solid var(--line);
}
.tabbar a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  color: var(--ink-3); font-size: .7rem; font-weight: 600;
  border-radius: 16px;
  transition: color .15s;
}
.tabbar a .pill { width: 54px; height: 30px; border-radius: 15px; display: grid; place-items: center; transition: background .2s var(--ease); }
.tabbar a.active { color: var(--lavender-ink); }
.tabbar a.active .pill { background: var(--grad); color: #fff; box-shadow: 0 8px 18px -8px rgba(219, 39, 119, .9); }
.tabbar a.active .ms { font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24; }

.sidebar { display: none; }
@media (min-width: 1024px) {
  .tabbar { display: none; }
  .topbar { margin-left: var(--sidebar-w); padding: 0 40px; }
  .topbar .brand { display: none; }
  .app-anon .topbar { margin-left: 0; }
  .app-anon .topbar .brand { display: flex; }
  .sidebar {
    display: flex; flex-direction: column;
    position: fixed; top: 0; left: 0; bottom: 0; width: var(--sidebar-w); z-index: 45;
    padding: 22px 16px;
    background: rgba(14, 11, 38, .72);
    backdrop-filter: var(--glass); -webkit-backdrop-filter: var(--glass);
    border-right: 1px solid var(--line);
    overflow-y: auto;
  }
  .sidebar .brand { display: flex; align-items: center; gap: 10px; padding: 0 10px 22px; font-family: var(--font-display); font-weight: 800; font-size: 1.2rem; color: var(--ink); }
  .sidebar .brand img { width: 34px; }
  .sidebar .brand b { color: var(--gold); }
  .sidebar nav { display: flex; flex-direction: column; gap: 2px; }
  .sidebar .group { margin: 16px 12px 6px; font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
  .sidebar nav a {
    display: flex; align-items: center; gap: 12px;
    padding: 10px 12px; border-radius: 14px;
    color: var(--ink-2); font-weight: 600; font-size: .92rem;
    transition: background .15s, color .15s;
  }
  .sidebar nav a:hover { background: var(--surface-2); color: var(--ink); }
  .sidebar nav a.active { background: var(--grad); color: #fff; box-shadow: 0 10px 22px -12px rgba(219, 39, 119, .9); }
  .sidebar .side-foot { margin-top: auto; padding-top: 16px; }
}

/* 5. Cards & stats --------------------------------------------------------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
  backdrop-filter: var(--glass); -webkit-backdrop-filter: var(--glass);
}
.card.flat { box-shadow: none; }
.card.pad-lg { padding: 22px; }
.card h3 { margin-bottom: 4px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.card-head h3 { margin: 0; }

.tint-lavender { background: var(--lavender); border-color: transparent; }
.tint-mint     { background: var(--mint);     border-color: transparent; }
.tint-peach    { background: var(--peach);    border-color: transparent; }
.tint-sky      { background: var(--sky);      border-color: transparent; }
.tint-butter   { background: var(--butter);   border-color: transparent; }
.tint-rose     { background: var(--rose);     border-color: transparent; }

.hero-card {
  position: relative; overflow: hidden;
  background: var(--grad);
  border: 0;
  padding: 20px;
  color: #fff;
  --ink: #fff; --ink-2: rgba(255, 255, 255, .85); --ink-3: rgba(255, 255, 255, .72);
  --line: rgba(255, 255, 255, .25); --surface: rgba(255, 255, 255, .14); --surface-2: rgba(255, 255, 255, .1);
  box-shadow: 0 24px 50px -22px rgba(219, 39, 119, .85);
}
.hero-card p, .hero-card h1, .hero-card h2, .hero-card h3 { color: inherit; }
.hero-card::after {
  content: ""; position: absolute; right: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, .28), rgba(255, 255, 255, 0) 70%);
}
.hero-card > * { position: relative; z-index: 1; }
.balance-label { font-size: .8rem; font-weight: 600; color: var(--ink-2); display: flex; align-items: center; gap: 6px; }
.balance-value { font-family: var(--font-display); font-size: 2.1rem; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; margin: 4px 0 2px; word-break: break-all; }
.balance-value small { font-size: .95rem; font-weight: 600; color: var(--ink-2); margin-left: 4px; }

.stat {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md);
  padding: 14px; min-width: 0;
  backdrop-filter: var(--glass); -webkit-backdrop-filter: var(--glass);
}
.stat .icon { width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 10px; }
.stat .label { font-size: .76rem; font-weight: 600; color: var(--ink-3); text-transform: uppercase; letter-spacing: .04em; }
.stat .value { font-family: var(--font-display); font-size: 1.15rem; font-weight: 700; margin-top: 2px; overflow-wrap: anywhere; }
.stat .value small { font-size: .75rem; color: var(--ink-3); font-weight: 600; }
.stat .sub { font-size: .76rem; color: var(--ink-3); margin-top: 2px; }

.icon.lavender { background: var(--lavender); color: var(--lavender-ink); }
.icon.mint { background: var(--mint); color: var(--mint-ink); }
.icon.peach { background: var(--peach); color: var(--peach-ink); }
.icon.sky { background: var(--sky); color: var(--sky-ink); }
.icon.butter { background: var(--butter); color: var(--butter-ink); }
.icon.rose { background: var(--rose); color: var(--rose-ink); }

.quick-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.quick-actions a, .quick-actions button {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 12px 4px; border-radius: var(--radius-md);
  background: var(--surface); border: 1px solid var(--line);
  color: var(--ink); font: 600 .74rem var(--font);
  cursor: pointer; transition: transform .15s var(--ease);
}
.quick-actions a:hover, .quick-actions button:hover { border-color: rgba(168, 85, 247, .6); background: rgba(168, 85, 247, .14); }
.quick-actions a:active, .quick-actions button:active { transform: scale(.96); }
.quick-actions .icon { width: 40px; height: 40px; border-radius: 14px; display: grid; place-items: center; }

.cta-card { display: flex; gap: 14px; align-items: center; }
.cta-card .icon { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; flex-shrink: 0; background: rgba(255, 255, 255, .12); }
.cta-card .body { flex: 1; min-width: 0; }
.cta-card h3 { margin: 0 0 2px; }
.cta-card p { margin: 0; font-size: .85rem; }

/* 6. Buttons & chips ------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 20px;
  border-radius: 16px; border: 1px solid transparent;
  font: 600 .95rem var(--font); cursor: pointer; text-align: center;
  transition: transform .15s var(--ease), background .15s, box-shadow .15s, opacity .15s;
  user-select: none;
}
.btn:active { transform: scale(.97); }
.btn[disabled], .btn.disabled { opacity: .5; pointer-events: none; }
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 12px 26px -10px rgba(219, 39, 119, .8); }
.btn-primary:hover { filter: brightness(1.1); }
.btn-gold { background: linear-gradient(135deg, #fde047, #f59e0b); color: #1c1238; box-shadow: 0 12px 26px -10px rgba(245, 158, 11, .8); }
.btn-gold:hover { filter: brightness(1.06); }
.btn-soft { background: var(--lavender); color: var(--lavender-ink); }
.btn-mint { background: var(--mint); color: var(--mint-ink); }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: rgba(255, 255, 255, .12); }
.btn-dark { background: #fff; color: #1c1238; }
.btn-sm { min-height: 38px; padding: 0 14px; border-radius: 12px; font-size: .85rem; }
.btn-block { display: flex; width: 100%; }
.btn .spinner { width: 18px; height: 18px; border: 2.5px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-row .btn { flex: 1; }

.chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 10px; border-radius: 999px;
  font-size: .74rem; font-weight: 700;
  background: var(--surface-2); color: var(--ink-2);
  white-space: nowrap;
}
.chip.lavender { background: var(--lavender); color: var(--lavender-ink); }
.chip.mint { background: var(--mint); color: var(--mint-ink); }
.chip.peach { background: var(--peach); color: var(--peach-ink); }
.chip.sky { background: var(--sky); color: var(--sky-ink); }
.chip.butter { background: var(--butter); color: var(--butter-ink); }
.chip.rose { background: var(--rose); color: var(--rose-ink); }
.chip.gold { background: var(--gold-soft); color: #fde68a; }

.rank-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px 6px 8px; border-radius: 999px;
  background: var(--gold-soft); color: #fde68a;
  font-weight: 700; font-size: .82rem;
}
.rank-badge .stars { letter-spacing: 1px; color: var(--gold); }
.rank-badge.none { background: var(--surface-2); color: var(--ink-3); }

.tabs {
  display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 8px; margin: 0 -2px 6px;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs a {
  flex-shrink: 0; padding: 9px 16px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line);
  color: var(--ink-2); font-weight: 600; font-size: .85rem;
}
.tabs a.active { background: var(--grad); border-color: transparent; color: #fff; }

/* 7. Forms ----------------------------------------------------------------- */
.field { display: block; margin-bottom: 14px; }
.field > label, .field .label { display: block; font-size: .8rem; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.input, .field input[type=text], .field input[type=email], .field input[type=number], .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px;
  border-radius: 14px; border: 1.5px solid var(--line);
  background: var(--surface-2); color: var(--ink);
  font: 500 1rem var(--font);
  transition: border-color .15s, background .15s;
  -webkit-appearance: none; appearance: none;
}
.field textarea { min-height: 110px; resize: vertical; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--primary); background: rgba(255, 255, 255, .1); box-shadow: 0 0 0 4px rgba(168, 85, 247, .2); }
.field select option { background: var(--surface-solid); color: var(--ink); }
.field .help { font-size: .76rem; color: var(--ink-3); margin-top: 6px; }
.field .errorlist { list-style: none; margin: 6px 0 0; padding: 0; color: var(--danger); font-size: .8rem; }

.amount-input {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: 18px;
  background: var(--surface-2); border: 1.5px solid var(--line);
}
.amount-input:focus-within { border-color: var(--primary); background: rgba(255, 255, 255, .1); box-shadow: 0 0 0 4px rgba(168, 85, 247, .2); }
.field .amount-input input, .amount-input input {
  flex: 1; min-width: 0; border: 0; background: transparent; outline: none;
  font: 700 2rem var(--font-display); color: var(--ink); padding: 0;
  min-height: 0; border-radius: 0;
}
.amount-input .unit { font: 700 1rem var(--font-display); color: var(--ink-3); }
.presets { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.presets button {
  flex: 1 1 0; min-width: 0; height: 36px; border-radius: 12px; cursor: pointer;
  background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); font: 600 .82rem var(--font);
}
.presets button.active { background: var(--grad); color: #fff; border-color: transparent; }

input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 8px; border-radius: 4px; background: var(--line); outline: none; margin: 10px 0; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); box-shadow: var(--shadow); cursor: pointer; }
input[type=range]::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); cursor: pointer; }

/* 8. Progress & rings ------------------------------------------------------ */
.progress { height: 10px; border-radius: 999px; background: var(--surface-2); overflow: hidden; border: 1px solid var(--line); }
.progress > span { display: block; height: 100%; border-radius: inherit; background: var(--grad); transition: width .8s var(--ease); }
.progress.mint > span { background: linear-gradient(90deg, #10b981, #5eead4); }
.progress.gold > span { background: linear-gradient(90deg, #f59e0b, #fde047); }
.progress-row { margin-bottom: 12px; }
.progress-row .top { display: flex; justify-content: space-between; gap: 8px; font-size: .82rem; margin-bottom: 6px; }
.progress-row .top b { font-weight: 600; color: var(--ink); }
.progress-row .top span { color: var(--ink-3); white-space: nowrap; }

.cycle-ring { display: flex; align-items: center; gap: 18px; }
.ring { position: relative; width: 116px; height: 116px; flex-shrink: 0; }
.ring svg { transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 11; stroke-linecap: round; }
.ring .track { stroke: rgba(255, 255, 255, .16); }
.ring .bar { stroke: var(--accent); filter: drop-shadow(0 0 6px rgba(34, 211, 238, .7)); transition: stroke-dashoffset 1s var(--ease); }
.ring .center { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ring .center b { font-family: var(--font-display); font-size: 1.5rem; line-height: 1; }
.ring .center span { font-size: .7rem; color: var(--ink-2); font-weight: 600; }
.countdown { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; }

.kv { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: .9rem; }
.kv:last-child { border-bottom: 0; }
.kv span { color: var(--ink-2); }
.kv b { font-weight: 600; text-align: right; overflow-wrap: anywhere; }
.kv.total b { font-family: var(--font-display); font-size: 1.05rem; }

.split-bar { display: flex; height: 14px; border-radius: 8px; overflow: hidden; margin: 10px 0 6px; }
.split-bar .a { background: var(--mint-ink); }
.split-bar .b { background: var(--butter-ink); }

/* 9. Lists & tables -------------------------------------------------------- */
.list { backdrop-filter: var(--glass); -webkit-backdrop-filter: var(--glass); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); color: var(--ink); min-width: 0; }
.list-item:last-child { border-bottom: 0; }
a.list-item:active { background: var(--surface-2); }
.list-item .icon { width: 40px; height: 40px; border-radius: 14px; display: grid; place-items: center; flex-shrink: 0; }
.list-item .body { flex: 1; min-width: 0; }
.list-item .t { font-weight: 600; font-size: .92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-item .s { font-size: .78rem; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-item .end { text-align: right; flex-shrink: 0; }
.list-item .amt { font-weight: 700; font-family: var(--font-display); font-size: .95rem; }
.amt.plus { color: var(--mint-ink); }
.amt.minus { color: var(--rose-ink); }
.amt.muted { color: var(--ink-3); text-decoration: line-through; }

.table-wrap { backdrop-filter: var(--glass); -webkit-backdrop-filter: var(--glass); overflow-x: auto; border-radius: var(--radius-md); border: 1px solid var(--line); background: var(--surface); }
table.table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.table th, .table td { padding: 11px 14px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table th { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); background: var(--surface-2); font-weight: 700; }
.table tr:last-child td { border-bottom: 0; }
.table td.num, .table th.num { text-align: right; }
.table tr.highlight td { background: var(--lavender); }

.empty { text-align: center; padding: 30px 16px; color: var(--ink-3); }
.empty .ms { font-size: 40px; color: var(--ink-3); margin-bottom: 6px; }
.empty p { margin: 0; }

.pagination { display: flex; justify-content: center; align-items: center; gap: 10px; margin-top: 14px; font-size: .85rem; color: var(--ink-2); }

.alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius-md); font-size: .88rem; margin-bottom: 12px; }
.alert .ms { font-size: 20px; }
.alert.info { background: var(--sky); color: var(--sky-ink); }
.alert.success { background: var(--mint); color: var(--mint-ink); }
.alert.warning { background: var(--butter); color: var(--butter-ink); }
.alert.error { background: var(--rose); color: var(--rose-ink); }
.alert p { color: inherit; margin: 0; }

.messages { margin-bottom: 12px; }

/* Rank ladder */
.ladder { display: flex; flex-direction: column; gap: 10px; }
.ladder .step { display: flex; gap: 14px; align-items: center; padding: 14px; border-radius: var(--radius-md); background: var(--surface); border: 1px solid var(--line); }
.ladder .step.current { border: 2px solid var(--gold); background: rgba(251, 191, 36, .12); box-shadow: 0 0 24px -8px rgba(251, 191, 36, .6); }
.ladder .step.done { opacity: .75; }
.ladder .badge { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; flex-shrink: 0; }
.ladder .step .body { flex: 1; min-width: 0; }
.ladder .step .t { font-weight: 700; }
.ladder .step .s { font-size: .8rem; color: var(--ink-2); }

/* Ticket thread */
.thread { display: flex; flex-direction: column; gap: 10px; }
.bubble { max-width: 86%; padding: 12px 14px; border-radius: 18px; font-size: .9rem; white-space: pre-wrap; }
.bubble.me { align-self: flex-end; background: var(--lavender); border-bottom-right-radius: 6px; }
.bubble.staff { align-self: flex-start; background: var(--surface); border: 1px solid var(--line); border-bottom-left-radius: 6px; }
.bubble .meta { display: block; font-size: .7rem; color: var(--ink-3); margin-top: 4px; }

/* 10. Sheets, toasts ------------------------------------------------------- */
.sheet-backdrop {
  position: fixed; inset: 0; z-index: 80;
  background: rgba(5, 4, 20, .62);
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
  opacity: 0; pointer-events: none; transition: opacity .25s;
}
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
  max-height: 88dvh; overflow-y: auto;
  background: var(--surface-solid);
  border: 1px solid var(--line);
  border-radius: 26px 26px 0 0;
  padding: 10px 20px calc(20px + var(--safe-b));
  transform: translateY(105%); visibility: hidden;
  transition: transform .32s var(--ease), visibility 0s linear .32s;
  box-shadow: var(--shadow-lg);
}
.sheet::before { content: ""; display: block; width: 44px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 14px; }
.sheet.open { transform: none; visibility: visible; transition: transform .32s var(--ease), visibility 0s; }
.sheet-backdrop.open { opacity: 1; pointer-events: auto; }
.sheet h2 { margin-bottom: 6px; }
@media (min-width: 768px) {
  .sheet { left: 50%; right: auto; bottom: 50%; width: 460px; border-radius: 26px; transform: translate(-50%, 60%) scale(.96); opacity: 0; transition: transform .25s var(--ease), opacity .25s; }
  .sheet.open { transform: translate(-50%, 50%); opacity: 1; }
  .sheet::before { display: none; }
}

.tx-steps { list-style: none; padding: 0; margin: 14px 0; }
.tx-steps li { display: flex; align-items: center; gap: 10px; padding: 10px 0; color: var(--ink-3); font-weight: 600; font-size: .9rem; }
.tx-steps li .ms { font-size: 22px; }
.tx-steps li.active { color: var(--ink); }
.tx-steps li.done { color: var(--mint-ink); }

.toasts {
  position: fixed; z-index: 100;
  left: 12px; right: 12px; top: calc(var(--safe-t) + 10px);
  display: flex; flex-direction: column; gap: 8px; pointer-events: none;
}
@media (min-width: 768px) { .toasts { left: auto; width: 380px; right: 20px; } }
.toast {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 14px; border-radius: 16px;
  background: #2a2163; color: #fff; font-size: .88rem; font-weight: 500;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
  pointer-events: auto;
  animation: toastIn .3s var(--ease) both;
}
.toast.success { background: #0f766e; }
.toast.error { background: #be185d; }
.toast.leaving { animation: toastOut .25s ease both; }
.toast a { color: #fff; text-decoration: underline; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-10px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(-8px); } }

/* 11. Public (landing) pages ------------------------------------------------ */
.public-nav {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; gap: 12px;
  padding: calc(var(--safe-t) + 12px) 16px 12px;
  background: rgba(11, 10, 31, .5);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.public-nav .brand { display: flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; color: var(--ink); }
.public-nav .brand img { width: 32px; }
.public-nav .brand b { color: var(--gold); }
.public-nav .links { display: none; gap: 22px; margin-left: 28px; }
.public-nav .links a { color: var(--ink-2); font-weight: 600; font-size: .9rem; }
.public-nav .btn { margin-left: auto; }
@media (min-width: 900px) { .public-nav { padding: 16px 40px; } .public-nav .links { display: flex; } }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 900px) { .wrap { padding: 0 40px; } }
.section { padding: 44px 0; }
.section-head { text-align: center; max-width: 620px; margin: 0 auto 26px; }
.eyebrow { display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--lavender-ink); background: var(--lavender); padding: 5px 12px; border-radius: 999px; margin-bottom: 12px; }

.landing-hero { padding: 24px 0 36px; }
.landing-hero .grid-hero { display: grid; gap: 28px; align-items: center; }
.landing-hero h1 { font-size: 2.2rem; font-weight: 800; letter-spacing: -.03em; }
.landing-hero h1 em { font-style: normal; background: linear-gradient(90deg, #fde047, #f472b6 50%, #22d3ee); -webkit-background-clip: text; background-clip: text; color: transparent; }
.landing-hero .lead { font-size: 1.05rem; }
.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 22px; }
.hero-stats .stat { text-align: center; padding: 12px 6px; }
.hero-visual { position: relative; border-radius: 30px; padding: 22px; background: var(--grad-cool); box-shadow: 0 30px 70px -28px rgba(168, 85, 247, .9); }
.hero-visual .phone { background: var(--surface-solid); border-radius: 26px; padding: 16px; box-shadow: var(--shadow-lg); max-width: 330px; margin: 0 auto; }
@media (min-width: 900px) {
  .landing-hero { padding: 48px 0 60px; }
  .landing-hero .grid-hero { grid-template-columns: 1.1fr .9fr; gap: 48px; }
  .landing-hero h1 { font-size: 3.2rem; }
}

.steps { display: grid; gap: 12px; counter-reset: step; }
.steps .card { position: relative; padding-left: 64px; }
.steps .card::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 16px; top: 18px; width: 34px; height: 34px; border-radius: 12px;
  display: grid; place-items: center; font: 800 1rem var(--font-display);
  background: var(--grad); color: #fff;
}
@media (min-width: 900px) { .steps { grid-template-columns: repeat(5, 1fr); } .steps .card { padding: 64px 16px 18px; } .steps .card::before { top: 18px; } }

.streams { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.streams .card .icon { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 12px; }

.faq details { backdrop-filter: var(--glass); -webkit-backdrop-filter: var(--glass); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 0 16px; margin-bottom: 10px; }
.faq summary { cursor: pointer; list-style: none; padding: 16px 0; font-weight: 600; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.3rem; color: var(--ink-3); line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding-bottom: 16px; margin: 0; }

.cta-band { border-radius: 30px; padding: 32px 22px; text-align: center; background: var(--grad); color: #fff; box-shadow: 0 30px 70px -30px rgba(219, 39, 119, .9);
  --ink: #fff; --ink-2: rgba(255, 255, 255, .88); --ink-3: rgba(255, 255, 255, .72); }
.footer { padding: 30px 0 calc(30px + var(--safe-b)); color: var(--ink-3); font-size: .82rem; text-align: center; }
.dev-card { display: inline-flex; align-items: center; gap: 12px; margin: 6px 0 12px; padding: 8px 16px 8px 8px; border: 1px solid var(--line); border-radius: 999px; text-align: left; }
.dev-card img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.dev-card b { display: block; color: var(--ink); font-size: .9rem; }
.dev-card small { color: var(--ink-3); font-size: .78rem; }

.connect-card { max-width: 440px; margin: 0 auto; text-align: center; }
.connect-card .logo { width: 84px; margin: 6px auto 12px; }
.wallet-option { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 16px; border-radius: 18px; border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; font: 600 1rem var(--font); color: var(--ink); text-align: left; transition: border-color .15s, transform .15s; }
.wallet-option:hover { border-color: var(--primary); background: rgba(168, 85, 247, .14); }
.wallet-option:active { transform: scale(.98); }
.wallet-option .icon { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; }
.wallet-option .chev { margin-left: auto; color: var(--ink-3); }

/* Launch: announcement ticker, countdown, attention band, verify, popups ---- */
.ticker {
  overflow: hidden; font-size: .84rem; font-weight: 600; line-height: 1;
  color: #fde68a; background: rgba(251, 191, 36, .12);
  border-block: 1px solid rgba(251, 191, 36, .28);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.ticker .track { display: flex; width: max-content; animation: ticker 34s linear infinite; }
.ticker:hover .track, .ticker:focus-within .track { animation-play-state: paused; }
.ticker .item { display: flex; align-items: center; gap: 10px; padding: 10px 28px; white-space: nowrap; }
.ticker .item b { color: #fff; }
.ticker .item .ms { font-size: 18px; color: var(--mint-ink); }
.ticker .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--gold); flex: none; }
.ticker a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.eyebrow.gold { color: #fde68a; background: var(--gold-soft); }

.launch { padding: 44px 0 40px; text-align: center; border-bottom: 1px solid rgba(251, 191, 36, .25);
  background: linear-gradient(180deg, rgba(11, 10, 31, .55), rgba(11, 10, 31, .15)); }
.launch h2 { font-size: clamp(1.9rem, 5.4vw, 3.4rem); font-weight: 800; letter-spacing: -.02em; margin-bottom: 6px; }
.launch-when { font-family: "JetBrains Mono", monospace; font-weight: 500; color: var(--gold); font-size: clamp(.92rem, 2.2vw, 1.15rem); margin: 0 0 26px; }
.timer { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; max-width: 860px; margin: 0 auto; }
.timer div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 4px 14px;
  backdrop-filter: var(--glass); -webkit-backdrop-filter: var(--glass); box-shadow: var(--shadow); }
.timer b { display: block; font-family: "JetBrains Mono", monospace; font-size: clamp(2rem, 9vw, 5.4rem); font-weight: 500; line-height: 1;
  color: #fff; font-variant-numeric: tabular-nums; }
.timer small { display: block; margin-top: 10px; font-size: .68rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-3); }
.launch-live { display: none; font: 800 clamp(1.8rem, 6vw, 3.6rem) var(--font-display); color: var(--gold); margin: 0; }
.launch.is-live .timer { display: none; }
.launch.is-live .launch-live { display: block; }
.launch-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 26px; }
@media (min-width: 768px) { .launch { padding: 72px 0 64px; } .timer { gap: 18px; } .timer div { padding: 28px 8px 20px; } }

.status-pill { display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 10px; margin-bottom: 14px; border-radius: 999px;
  background: var(--gold-soft); color: #fde68a; font-size: .8rem; font-weight: 600; }
.status-pill b { color: var(--gold); }
.status-pill i { width: 9px; height: 9px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 0 rgba(251, 191, 36, .7); animation: pulse 1.8s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 9px rgba(251, 191, 36, 0); } 100% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0); } }

.trust { list-style: none; padding: 0; margin: 0 0 22px; display: flex; flex-wrap: wrap; gap: 8px 16px; }
.trust li { display: flex; align-items: center; gap: 6px; font-size: .86rem; font-weight: 600; color: var(--ink-2); }
.trust .ms { font-size: 18px; color: var(--mint-ink); }
.hero-actions { max-width: 460px; }

.attn { padding: 40px 0; text-align: center; background: rgba(0, 0, 0, .28); border-block: 1px solid var(--line); }
.attn h2 { font-size: clamp(2.4rem, 8vw, 4.6rem); font-weight: 800; letter-spacing: .04em; margin-bottom: 10px; }
.attn h2 span { color: var(--gold); }
.attn-head { font: 700 clamp(1.05rem, 2.6vw, 1.6rem)/1.35 var(--font-display); text-transform: uppercase; color: var(--ink); max-width: 940px; margin: 0 auto 18px; }
.attn-head mark { background: var(--gold); color: #1c1238; padding: 0 8px; border-radius: 6px; }
.attn-body { max-width: 860px; margin: 0 auto; font-size: 1rem; }
.attn-body b { color: var(--ink); }
.attn-body a { color: var(--gold); font-weight: 700; text-decoration: underline; }
@media (min-width: 768px) { .attn { padding: 60px 0; } }

.journey { padding: 26px 0 0; }
.journey .wrap { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.journey a { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: var(--radius-md); background: var(--surface); border: 1px solid var(--line); color: var(--ink); transition: border-color .15s; }
.journey a:hover { border-color: rgba(168, 85, 247, .6); }
.journey .n { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; font: 800 1rem var(--font-display); flex: none; }
.journey .n.lavender { background: var(--lavender); color: var(--lavender-ink); }
.journey .n.mint { background: var(--mint); color: var(--mint-ink); }
.journey .n.butter { background: var(--butter); color: var(--butter-ink); }
.journey .n.rose { background: var(--rose); color: var(--rose-ink); }
.journey b { display: block; font-size: .92rem; }
.journey small { color: var(--ink-3); font-size: .78rem; }

.verify { border-radius: 30px; padding: 30px 18px; background: rgba(0, 0, 0, .3); border: 1px solid rgba(251, 191, 36, .25); }
.vgrid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.vcard { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 18px; min-width: 0; }
.vcard small { display: block; font-size: .7rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 8px; }
.vcard p { font-size: .88rem; margin-bottom: 0; }
.vval { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 12px; }
@media (min-width: 900px) { .verify { padding: 40px; } }

.plan-band { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.plan-band > .icon { width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; }
.plan-band > .icon .ms { font-size: 28px; }
.plan-band .body { flex: 1 1 260px; min-width: 0; }
.plan-band .btn-row { flex: 1 1 280px; }

.sheet.notice { text-align: center; }
.notice-x { position: absolute; top: 12px; right: 12px; }
.notice-badge { width: 60px; height: 60px; border-radius: 50%; display: grid; place-items: center; margin: 6px auto 14px; }
.notice-badge .ms { font-size: 30px; }
.notice-badge.mint { background: var(--mint); color: var(--mint-ink); }
.notice-badge.butter { background: var(--butter); color: var(--butter-ink); }
.notice-badge.sky { background: var(--sky); color: var(--sky-ink); }
.notice-badge.rose { background: var(--rose); color: var(--rose-ink); }
.notice-body p { margin-bottom: .5em; }
.notice-checks { list-style: none; display: inline-grid; gap: 8px; margin: 6px 0 14px; padding: 0; text-align: left; }
.notice-checks li { display: flex; align-items: center; gap: 8px; }
.notice-checks .ms { color: var(--mint-ink); font-size: 20px; }
.notice-when { font-family: "JetBrains Mono", monospace; font-weight: 500; color: var(--gold); margin: 14px 0 18px; }

@media (prefers-reduced-motion: reduce) {
  .ticker .track { animation: none; width: auto; justify-content: center; }
  .ticker .item[aria-hidden] { display: none; }
  .ticker .item { white-space: normal; flex-wrap: wrap; justify-content: center; text-align: center; }
  .status-pill i { animation: none; }
}

/* 12. Utilities -------------------------------------------------------------- */
.muted { color: var(--ink-3) !important; }
.small { font-size: .82rem; }
.tiny { font-size: .72rem; }
.center { text-align: center; }
.right { text-align: right; }
.mt-0 { margin-top: 0 !important; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.flex { display: flex; align-items: center; gap: 8px; }
.between { justify-content: space-between; }
.wrap-any { overflow-wrap: anywhere; word-break: break-word; }
.gold { color: var(--gold); }
.positive { color: var(--mint-ink); }
.hidden { display: none !important; }
@media (max-width: 1023px) { .desktop-only { display: none !important; } }
@media (min-width: 1024px) { .mobile-only { display: none !important; } }
