/* ============================================================
   bitexasia — design tokens & layout
   ============================================================ */
:root,
:root[data-theme="dark"] {
  --bg: #010705;
  --bg-2: #050d0a;
  --surface: #051410;
  --surface-2: #0b2c21;
  --surface-3: #163a2c;
  --border: #143328;
  --border-2: #1f4a3a;
  --primary: #438c73;
  --primary-2: #2f6754;
  --primary-3: #1c5541;
  --primary-soft: rgba(32, 67, 56, 0.2);
  --primary-glow: rgba(67, 140, 115, 0.5);
  --primary-shadow: rgba(139, 200, 179, 0.2);
  --text: #ecf3f0;
  --text-2: #c7dcd3;
  --text-3: #a2c5b7;
  --text-4: #6b8a7e;
  --accent: #26e03c;
  --positive: #26e03c;
  --negative: #ff5b6b;
  --chip-bg: rgba(32, 67, 56, 0.2);
  --hero-glow: radial-gradient(60% 80% at 70% 35%, rgba(67, 140, 115, 0.18), transparent 70%);
  --star: rgba(199, 220, 211, 0.6);
}
:root[data-theme="light"] {
  --bg: #f3f7f4;
  --bg-2: #e9efeb;
  --surface: #ffffff;
  --surface-2: #e9efeb;
  --surface-3: #d8e6df;
  --border: #c5d6cd;
  --border-2: #a6c2b4;
  --primary: #2f6754;
  --primary-2: #438c73;
  --primary-3: #143328;
  --primary-soft: rgba(67, 140, 115, 0.12);
  --primary-glow: rgba(67, 140, 115, 0.32);
  --primary-shadow: rgba(67, 140, 115, 0.16);
  --text: #0b2c21;
  --text-2: #224d3d;
  --text-3: #4f6b5e;
  --text-4: #7a8c83;
  --accent: #1c8a3a;
  --positive: #1c8a3a;
  --negative: #c43545;
  --chip-bg: rgba(67, 140, 115, 0.1);
  --star: rgba(67, 140, 115, 0.45);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
img, svg { display: block; max-width: 100%; }

.container {
  width: 100%;
  max-width: 1344px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ===== Header ===== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: color-mix(in oklab, var(--bg) 80%, transparent);
  border-bottom: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 112px; gap: 24px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 18px; letter-spacing: -0.01em;
  color: var(--text);
}
.brand-mark {
  width: 48px; height: 48px; flex: 0 0 48px;
  display: grid; place-items: center;
  color: var(--primary);
}
.brand-mark svg,
.brand-mark img { width: 100%; height: 100%; object-fit: contain; }
/* Full-logo variant: single <img class="brand-logo"> directly inside .brand,
   replacing the icon+text pair. Aspect of logo-full.jpg is ~16:9. */
.brand-logo {
  height: 90px;
  width: auto;
  display: block;
}
@media (max-width: 720px) {
  .brand-logo { height: 58px; }
}
.nav-links {
  display: flex; gap: 4px;
  background: var(--chip-bg);
  border-radius: 999px; padding: 6px;
  box-shadow: inset 1px 1px 12px var(--primary-glow);
}
.nav-links a {
  padding: 8px 18px; border-radius: 999px;
  font-size: 14px; color: var(--text-2);
  transition: all .2s; display: inline-flex; align-items: center; gap: 6px;
}
.nav-links a.active,
.nav-links a:hover { background: var(--primary); color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: 12px; }

/* ===== Hamburger button (mobile only) ===== */
.nav-toggle {
  display: none;
  width: 40px; height: 40px; border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  place-items: center;
  flex-direction: column;
  gap: 4px;
  padding: 0;
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.nav-toggle:hover { border-color: var(--primary); }
.nav-toggle span {
  display: block;
  width: 18px; height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform .25s, opacity .2s;
}
body.nav-open .nav-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
body.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
body.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ===== Services dropdown ===== */
.nav-services { position: relative; }
.nav-services .nav-services-trigger {
  padding: 8px 18px; border-radius: 999px;
  font-size: 14px; color: var(--text-2);
  display: inline-flex; align-items: center; gap: 6px;
  cursor: pointer;
  transition: all .2s;
  font-family: inherit;
}
.nav-services.active .nav-services-trigger,
.nav-services .nav-services-trigger:hover,
.nav-services.open .nav-services-trigger { background: var(--primary); color: var(--text); }
.nav-services .nav-services-trigger svg { transition: transform .2s; }
.nav-services.open .nav-services-trigger svg { transform: rotate(180deg); }

.nav-dropdown {
  position: absolute; top: calc(100% + 12px); right: 0;
  width: 320px;
  background: var(--surface); border: 1px solid var(--border-2);
  border-radius: 16px; padding: 12px;
  box-shadow: 0 24px 48px -16px rgba(0,0,0,.6), 0 0 60px var(--primary-glow);
  display: flex; flex-direction: column; gap: 4px;
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity .2s, transform .2s, visibility .2s;
  z-index: 60;
}
@media (hover: hover) {
  .nav-services:hover .nav-dropdown {
    opacity: 1; visibility: visible; transform: none;
  }
}
.nav-services.open .nav-dropdown {
  opacity: 1; visibility: visible; transform: none;
}
.nav-dropdown-item {
  display: grid; grid-template-columns: 36px 1fr;
  gap: 12px; padding: 12px;
  border-radius: 12px;
  align-items: center;
  transition: background .15s;
}
.nav-dropdown-item:hover { background: var(--chip-bg); }
.nav-dropdown-item.active {
  background: color-mix(in oklab, var(--primary) 18%, transparent);
  outline: 1px solid color-mix(in oklab, var(--primary) 40%, transparent);
}
.nav-dropdown-item.active b { color: var(--primary); }
.nav-dropdown-item .dd-ico {
  width: 36px; height: 36px; border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  display: grid; place-items: center; color: var(--text);
}
.nav-dropdown-item b { display: block; font-size: 13px; color: var(--text); font-weight: 600; }
.nav-dropdown-item small { display: block; font-size: 11px; color: var(--text-3); margin-top: 2px; line-height: 1.4; }
.nav-dropdown-divider { height: 1px; background: var(--border); margin: 6px 4px; }
.nav-dropdown-foot {
  padding: 10px 12px; font-size: 12px; color: var(--primary);
  display: inline-flex; align-items: center; gap: 6px;
  font-weight: 600;
  transition: gap .15s;
}
.nav-dropdown-foot:hover { gap: 10px; }
.lang {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text-2); font-size: 14px;
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 24px; border-radius: 12px;
  font-weight: 500; font-size: 15px;
  transition: transform .15s ease, box-shadow .2s, background .2s;
  white-space: nowrap;
  cursor: pointer;
}
.btn-primary {
  background: var(--primary); color: var(--text);
  box-shadow: 0 10px 24px -10px var(--primary-glow);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 16px 30px -10px var(--primary-glow); }
.btn-ghost {
  background: transparent; color: var(--text-2);
  border: 1px solid var(--border);
}
.btn-ghost:hover { color: var(--text); border-color: var(--primary); }
.btn-sm { padding: 8px 18px; font-size: 14px; border-radius: 10px; }

/* ===== Chips ===== */
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px;
  background: var(--chip-bg);
  box-shadow: inset 1px 1px 12px var(--primary-glow);
  font-size: 12px; color: var(--text-3); font-weight: 500;
  align-self: flex-start; width: max-content; max-width: 100%;
}
.section-head:not(.split) > .chip { align-self: center; }
.chip svg { color: var(--primary); }

/* ===== Section header ===== */
.section { padding: 96px 0; position: relative; }
.section-head { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.section-head.split {
  flex-direction: row; align-items: flex-end; text-align: left;
  gap: 48px; flex-wrap: wrap;
}
.section-head.split > .head-l { flex: 1 1 360px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.section-head.split > .head-r { flex: 1 1 420px; min-width: 0; max-width: 720px; }

h1, h2, h3, h4 { margin: 0; color: var(--text); font-family: "Montserrat", sans-serif; line-height: 1.15; letter-spacing: -0.01em; }
h1 { font-size: clamp(40px, 5.4vw, 80px); font-weight: 700; }
h2 { font-size: clamp(32px, 4vw, 52px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 700; }
.lead { font-size: clamp(15px, 1.2vw, 18px); color: var(--text-2); margin: 0; max-width: 60ch; }
.muted { color: var(--text-2); }

/* ===== Reveal animations ===== */
[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .7s ease, transform .7s cubic-bezier(.2, .8, .2, 1);
  will-change: opacity, transform;
}
[data-reveal].revealed { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
}

/* ===== Hero ===== */
.hero { position: relative; padding: 48px 0 96px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: -10% -10% auto -10%;
  height: 80%;
  background: var(--hero-glow);
  pointer-events: none; z-index: 0;
}
.hero-glow-column {
  position: absolute; top: -10%; bottom: -10%; left: 50%;
  width: clamp(220px, 32vw, 460px);
  transform: translateX(-50%);
  background:
    radial-gradient(50% 50% at 50% 50%, color-mix(in oklab, var(--primary) 80%, white 10%) 0%, color-mix(in oklab, var(--primary) 50%, transparent) 40%, transparent 70%);
  filter: blur(40px);
  opacity: .55;
  pointer-events: none;
  z-index: 0;
  animation: glow-breathe 6s ease-in-out infinite;
}
@keyframes glow-breathe {
  0%, 100% { opacity: .45; transform: translateX(-50%) scale(1); }
  50%      { opacity: .65; transform: translateX(-50%) scale(1.03); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-glow-column { animation: none; }
  .marquee, .marquee.reverse { animation: none; }
}

/* Touch-only devices: cancel decorative :hover transforms so iOS Safari
   doesn't leave cards stuck in their lifted state after a tap (the user's
   first tap fires :hover, then they navigate away leaving the transform
   applied to the previously-tapped card). */
@media (hover: none) {
  .feature-card:hover,
  .feature-card:hover .feat-arrow,
  .features-grid .feature-tile:hover,
  .exchange-card:hover,
  .bento-card:hover,
  .stats-grid .stat-card:hover,
  .team-card:hover,
  .yield-card:hover,
  .resource-card:hover,
  .resource-card:hover .res-arrow,
  .status-subscribe:hover,
  .status-subscribe:hover .status-subscribe-arrow,
  .coin-pill:hover,
  .trade-swap:hover,
  .hero-chip-tilt:hover {
    transform: none;
  }
}
.hero-grid {
  position: relative;
  display: grid; grid-template-columns: 1fr 1.1fr 1fr;
  gap: 32px; align-items: center;
  z-index: 1;
}
.hero-copy { display: flex; flex-direction: column; gap: 24px; max-width: 520px; }
.hero-copy h1 { line-height: 1.02; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }

.hero-center {
  display: flex; flex-direction: column; align-items: center;
  gap: 28px; position: relative;
}

/* ===== Trade widget ===== */
.trade-widget {
  position: relative; z-index: 2;
  width: min(360px, 100%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 24px;
  box-shadow: 0 30px 60px -30px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.04), 0 0 80px var(--primary-glow);
  display: flex; flex-direction: column; gap: 18px;
}
.trade-tabs {
  display: grid; grid-template-columns: repeat(3, 1fr);
  background: var(--bg-2); border-radius: 12px;
  padding: 4px; gap: 4px;
}
.trade-tabs button {
  padding: 12px 0; border-radius: 9px;
  font-size: 14px; color: var(--text-3); font-weight: 500;
  transition: background .2s, color .2s, box-shadow .2s;
}
.trade-tabs button.active {
  background: var(--primary); color: var(--text);
  box-shadow: 0 8px 20px -8px var(--primary-glow);
}
/* ===== Live rate strip under tabs ===== */
.trade-rate {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 12px;
  color: var(--text-3);
}
.trade-rate b { color: var(--text); font-weight: 600; }
.trade-rate-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--positive);
  flex: 0 0 7px;
  animation: trade-rate-pulse 2.4s ease-out infinite;
}
@keyframes trade-rate-pulse {
  0%   { box-shadow: 0 0 0 0 color-mix(in oklab, var(--positive) 65%, transparent); }
  70%  { box-shadow: 0 0 0 5px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.trade-rate-fresh {
  margin-left: auto;
  font-size: 10px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .06em;
  color: var(--positive);
  transition: color .2s;
}
/* Cached state — pill switches to "Cached" when worker is unreachable */
.trade-rate-fresh.cached { color: var(--text-3); }
.trade-rate-dot.cached {
  background: var(--text-3);
  animation: none;
  box-shadow: none;
}
@media (prefers-reduced-motion: reduce) {
  .trade-rate-dot { animation: none; }
}

/* ===== Rows wrapper with swap button between ===== */
.trade-rows {
  display: flex; flex-direction: column;
  gap: 6px;
  position: relative;
}
.trade-widget[data-mode="buy"] .trade-rows { flex-direction: column-reverse; }

.trade-row {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 4px 12px;
  padding: 10px 16px 12px;
  border: 1px solid var(--border); border-radius: 12px;
  background: var(--bg-2);
  position: relative;
}
.trade-row::before {
  grid-column: 1 / -1;
  font-size: 10.5px;
  color: var(--text-3);
  letter-spacing: .06em;
  text-transform: uppercase;
  font-weight: 700;
}
.row-crypto::before { content: "From"; }
.row-usd::before    { content: "To"; }
.trade-widget[data-mode="buy"] .row-crypto::before  { content: "You receive"; color: var(--positive); }
.trade-widget[data-mode="buy"] .row-usd::before     { content: "You pay"; }
.trade-widget[data-mode="sell"] .row-crypto::before { content: "You sell"; color: var(--negative); }
.trade-widget[data-mode="sell"] .row-usd::before    { content: "You receive"; color: var(--positive); }
.trade-row > .coin-trigger { grid-column: 1; grid-row: 2; }
.trade-row > input         { grid-column: 2; grid-row: 2; }
.trade-row.row-crypto { z-index: 3; } /* dropdown stack above row-usd */

/* ===== Swap button between rows ===== */
.trade-swap {
  align-self: center;
  /* 40×40 = WCAG AA-friendly tap target; sits between two input rows where
     a smaller button used to invite mistaps on touch */
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border-2);
  color: var(--text-2);
  display: grid; place-items: center;
  cursor: pointer;
  margin: -10px auto;
  z-index: 4;
  position: relative;
  box-shadow: 0 8px 16px -8px rgba(0,0,0,.6);
  transition: transform .35s cubic-bezier(.25,.8,.25,1), border-color .2s, color .2s, background .2s;
}
.trade-swap:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--bg-2);
  transform: rotate(180deg);
}
.trade-swap.flipped { transform: rotate(180deg); }
.trade-swap.flipped:hover { transform: rotate(360deg); }
@media (prefers-reduced-motion: reduce) {
  .trade-swap, .trade-swap.flipped { transition: none; transform: none; }
}

/* ===== Fee strip ===== */
.trade-fees {
  display: flex; flex-direction: column; gap: 6px;
  padding: 10px 14px;
  font-size: 11.5px; color: var(--text-3);
  border-top: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
}
.trade-fees > div {
  display: flex; justify-content: space-between; align-items: center;
}
.trade-fees b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }

/* ===== Sell-mode CTA: red gradient (darker tones — WCAG AA contrast) ===== */
.trade-widget[data-mode="sell"] .trade-cta {
  background: linear-gradient(135deg, #d63b4b 0%, #7a1d28 100%);
  color: #ffffff;
  box-shadow: 0 10px 24px -10px #d63b4b;
}
.trade-widget[data-mode="sell"] .trade-cta:hover {
  box-shadow: 0 16px 30px -10px #d63b4b;
}
.coin-trigger {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; color: var(--text); font-weight: 500;
  cursor: pointer;
  padding: 4px 8px; margin: -4px -8px;
  border-radius: 8px;
  transition: background .2s;
}
.coin-trigger:hover { background: color-mix(in oklab, var(--primary) 15%, transparent); }
.coin-trigger-sym { font-weight: 600; }

.coin-dropdown {
  position: absolute; top: calc(100% + 6px); left: 12px;
  width: 200px; max-height: 280px; overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border-2);
  border-radius: 12px;
  box-shadow: 0 24px 48px -16px rgba(0,0,0,.6);
  display: none; flex-direction: column;
  z-index: 10;
}
.coin-dropdown.open { display: flex; }
.coin-dropdown button {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; text-align: left;
  font-size: 13px; color: var(--text-2);
  border-radius: 0;
  transition: background .15s;
  width: 100%;
}
.coin-dropdown button:hover { background: var(--chip-bg); color: var(--text); }
.coin-dropdown .coin-dot { width: 22px; height: 22px; font-size: 11px; flex: 0 0 22px; }

.trade-row input {
  background: transparent; border: 0; outline: 0;
  color: var(--text); text-align: right;
  font-size: 16px; font-weight: 600;
  width: 100%; min-width: 0; font-family: inherit;
}
.trade-row input:focus { color: var(--primary); }
.coin-dot {
  width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 700; font-size: 12px; color: #fff;
  flex: 0 0 26px;
}
.trade-cta { width: 100%; padding: 14px; font-size: 15px; transition: background .2s, transform .15s, box-shadow .25s; }
.trade-cta.flash {
  background: var(--positive); color: var(--bg);
  box-shadow: 0 0 0 6px color-mix(in oklab, var(--positive) 25%, transparent), 0 16px 30px -10px var(--positive);
}

/* ===== Hero tilted info chip ===== */
.hero-chip-tilt {
  position: relative; z-index: 2;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px; border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: 0 12px 24px -12px var(--primary-glow);
  font-size: 14px; color: var(--text-2);
  transform: rotate(-7deg);
  max-width: 320px;
  transition: transform .25s ease;
}
.hero-chip-tilt:hover { transform: rotate(-3deg) translateY(-2px); }
.hero-chip-tilt small { display: block; color: var(--text-3); font-size: 11px; }
.hero-chip-tilt .arrow-up {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--primary); color: var(--text);
  display: grid; place-items: center; flex: 0 0 32px;
}

/* ===== Hero right column (avatars + heading) ===== */
.hero-right {
  display: flex; flex-direction: column; align-items: flex-end;
  gap: 18px; text-align: right;
}
.avatar-stack { display: inline-flex; align-items: center; }
.avatar-stack .av {
  width: 40px; height: 40px; border-radius: 50%;
  border: 2px solid var(--surface);
  display: grid; place-items: center;
  margin-left: -10px; font-size: 18px;
  background-size: cover; background-position: center;
}
.avatar-stack .av:first-child { margin-left: 0; }
.avatar-stack .av.av-1 { background: linear-gradient(135deg, #ffd0a3, #c98e6b); }
.avatar-stack .av.av-2 { background: linear-gradient(135deg, #c4d8b7, #5e9477); }
.avatar-stack .av.arrow { background: var(--primary); color: var(--text); }
.hero-right h2 {
  font-size: clamp(28px, 3.6vw, 56px);
  font-weight: 700; line-height: 1; text-align: right;
  color: var(--text);
}

/* ===== Feature trio ===== */
.feature-trio {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin-top: 56px;
}
.feature-card {
  position: relative;
  display: flex; flex-direction: column; gap: 14px;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
  transition: transform .2s, border-color .2s, box-shadow .2s;
}
.feature-card:hover {
  transform: translateY(-3px);
  border-color: var(--primary);
  box-shadow: 0 20px 40px -20px var(--primary-glow);
}
.feature-card .feat-chip {
  align-self: flex-start;
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 999px;
  background: var(--chip-bg);
  font-size: 11px; color: var(--text-3);
  border: 1px solid var(--border);
}
.feature-card h4 { margin: 0; font-size: 18px; font-weight: 600; }
.feature-card p { margin: 0; font-size: 13px; color: var(--text-3); line-height: 1.6; }
.feature-card .feat-arrow {
  position: absolute; top: 18px; right: 18px;
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--primary); color: var(--text);
  display: grid; place-items: center;
  box-shadow: 0 8px 20px -10px var(--primary-glow);
  transition: transform .3s, background .2s;
}
.feature-card:hover .feat-arrow { transform: rotate(45deg); background: var(--primary-2); }

/* ===== Coin marquee ===== */
.marquee-wrap { margin-top: 56px; display: flex; flex-direction: column; gap: 16px; overflow: hidden; }
.marquee {
  display: flex; gap: 12px; width: max-content;
  animation: scroll 60s linear infinite;
}
.marquee.reverse { animation-direction: reverse; animation-duration: 75s; }
.marquee-wrap:hover .marquee { animation-play-state: paused; }
@keyframes scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.coin-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--border); border-radius: 999px;
  font-size: 14px; color: var(--text-2);
  background: var(--surface); flex: 0 0 auto;
  transition: border-color .2s, transform .15s;
}
.coin-pill:hover { border-color: var(--primary); transform: translateY(-1px); }
.coin-pill .coin-dot { width: 22px; height: 22px; font-size: 11px; flex: 0 0 22px; }
.coin-pill-name { color: var(--text-2); }
.coin-pill-price {
  font-weight: 600; font-variant-numeric: tabular-nums;
  padding-left: 10px; margin-left: 4px;
  border-left: 1px solid var(--border-2);
}
.coin-pill-price:empty { display: none; }
.coin-pill-price.up   { color: var(--positive); }
.coin-pill-price.down { color: var(--negative); }

/* ===== Tick flash — brief green/red pulse when a price ticks ===== */
@keyframes price-flash-up {
  0%   { background: color-mix(in oklab, var(--positive) 32%, transparent); box-shadow: 0 0 0 4px color-mix(in oklab, var(--positive) 18%, transparent); color: var(--positive); }
  60%  { background: color-mix(in oklab, var(--positive) 12%, transparent); box-shadow: 0 0 0 6px transparent; }
  100% { background: transparent; box-shadow: 0 0 0 0 transparent; }
}
@keyframes price-flash-down {
  0%   { background: color-mix(in oklab, var(--negative) 32%, transparent); box-shadow: 0 0 0 4px color-mix(in oklab, var(--negative) 18%, transparent); color: var(--negative); }
  60%  { background: color-mix(in oklab, var(--negative) 12%, transparent); box-shadow: 0 0 0 6px transparent; }
  100% { background: transparent; box-shadow: 0 0 0 0 transparent; }
}
.flash-up,
.flash-down {
  border-radius: 6px;
  padding-left: 4px; padding-right: 4px;
  margin-left: -4px;
  transition: none;
}
.flash-up   { animation: price-flash-up   .9s cubic-bezier(.25, .8, .25, 1); }
.flash-down { animation: price-flash-down .9s cubic-bezier(.25, .8, .25, 1); }
@media (prefers-reduced-motion: reduce) {
  .flash-up, .flash-down { animation: none; background: transparent; }
}

/* ===== Buy & Trade Securely ===== */
.buy-trade {
  display: grid; grid-template-columns: 1.1fr 1fr;
  gap: 56px; align-items: center;
}
.buy-trade-art {
  position: relative;
  height: 480px;
  border-radius: 24px;
  border: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
  padding: 16px;
}
.buy-trade-art::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(80% 70% at 50% 60%, color-mix(in oklab, var(--primary) 20%, transparent) 0%, transparent 70%),
    radial-gradient(1px 1px at 12% 18%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 32% 60%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 65% 25%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 80% 70%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 47% 88%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 92% 12%, var(--star) 50%, transparent 51%);
  pointer-events: none; opacity: .6;
}
.dash {
  position: relative; z-index: 1;
  width: 100%; height: 100%;
  display: grid;
  grid-template-columns: 56px 1fr;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  font-size: 11px;
}
.dash-side {
  background: var(--bg-2);
  border-right: 1px solid var(--border);
  padding: 14px 0;
  display: flex; flex-direction: column; gap: 14px; align-items: center;
}
.dash-side .dash-logo {
  width: 28px; height: 28px; border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  display: grid; place-items: center; color: var(--text); font-weight: 700; font-size: 12px;
}
.dash-side .dash-nav { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; color: var(--text-3); }
.dash-side .dash-nav a {
  width: 28px; height: 28px; border-radius: 8px;
  display: grid; place-items: center;
  color: var(--text-3);
  cursor: default;
}
.dash-side .dash-nav a.active { background: var(--primary-soft); color: var(--text); }
.dash-main { padding: 12px; display: grid; grid-template-rows: auto 1fr; gap: 10px; min-width: 0; }
.dash-bar {
  display: flex; align-items: center; justify-content: space-between;
  padding-bottom: 8px; border-bottom: 1px solid var(--border);
  color: var(--text-2);
}
.dash-bar .dash-user { display: inline-flex; align-items: center; gap: 8px; font-size: 11px; color: var(--text-2); }
.dash-bar .dash-user .av {
  width: 22px; height: 22px; border-radius: 50%;
  background: linear-gradient(135deg, #c4d8b7, #5e9477);
}
.dash-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 0.85fr;
  grid-template-rows: 0.55fr 1fr;
  gap: 10px;
  min-height: 0;
}
.dash-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px;
  display: flex; flex-direction: column; gap: 6px;
  min-width: 0;
}
.dash-card h6 { margin: 0; font-size: 11px; color: var(--text); font-weight: 600; }
.dash-card .pill { font-size: 9px; color: var(--text-3); border: 1px solid var(--border); border-radius: 6px; padding: 2px 6px; }
.dash-card .row { display: flex; align-items: center; justify-content: space-between; }
.dash-mining { grid-column: 1 / 2; grid-row: 1 / 2; }
.dash-progress { grid-column: 2 / 3; grid-row: 1 / 2; align-items: center; }
.dash-stat { grid-column: 1 / 3; grid-row: 2 / 3; }
.dash-fav { grid-column: 3 / 4; grid-row: 1 / 3; }
.dash-fav-row {
  display: grid; grid-template-columns: 18px 1fr auto;
  align-items: center; gap: 8px;
  padding: 6px 4px; border-bottom: 1px solid var(--border);
}
.dash-fav-row:last-child { border-bottom: 0; }
.dash-fav-row .coin-dot { width: 18px; height: 18px; font-size: 9px; flex: 0 0 18px; }
.dash-fav-row .nm { font-size: 10px; color: var(--text); font-weight: 600; }
.dash-fav-row .nm small { color: var(--text-3); font-weight: 400; font-size: 9px; }
.dash-fav-row .price { font-size: 10px; color: var(--text-2); font-variant-numeric: tabular-nums; }

.steps { display: flex; flex-direction: column; gap: 18px; max-width: 480px; }
.step { display: flex; align-items: center; gap: 14px; font-size: 15px; color: var(--text-2); }
.step .num {
  flex: 0 0 32px; width: 32px; height: 32px; border-radius: 50%;
  background: var(--primary-soft); border: 1px solid var(--border-2);
  color: var(--primary); display: grid; place-items: center;
  font-weight: 600; font-size: 14px;
}

/* ===== Trending exchange carousel ===== */
.exchange-row {
  display: grid; grid-auto-flow: column;
  grid-auto-columns: minmax(240px, 1fr);
  gap: 20px; margin-top: 48px;
  overflow-x: auto; padding-bottom: 12px;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  /* fade the right edge as a "swipe me" affordance — visible on mobile
     where the dim default scrollbar isn't a strong-enough hint */
  mask-image: linear-gradient(90deg, black 0%, black 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(90deg, black 0%, black 92%, transparent 100%);
}
.exchange-row::-webkit-scrollbar { height: 8px; }
.exchange-row::-webkit-scrollbar-track { background: transparent; }
.exchange-row::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

.exchange-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 18px;
  display: flex; flex-direction: column; gap: 14px;
  position: relative; scroll-snap-align: start;
  min-width: 0; min-height: 260px;
  transition: transform .2s, border-color .2s, box-shadow .25s;
}
.exchange-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: 0 24px 48px -24px var(--primary-glow);
}
.ex-head { display: flex; align-items: center; gap: 12px; }
.ex-coin-stack { display: inline-flex; align-items: center; flex: 0 0 auto; }
.ex-coin-stack .coin-dot {
  width: 28px; height: 28px; font-size: 13px;
  border: 2px solid var(--surface);
  flex: 0 0 28px;
}
.ex-coin-stack .coin-dot + .coin-dot { margin-left: -10px; }
.ex-pair-name {
  font-weight: 600; font-size: 14px; color: var(--text);
  letter-spacing: .01em;
}
.ex-price { font-size: 22px; font-weight: 700; color: var(--text); margin-top: 4px; font-variant-numeric: tabular-nums; }
.ex-meta {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
  font-size: 11px; color: var(--text-3);
}
.ex-meta .ex-d { display: flex; flex-direction: column; gap: 2px; }
.ex-meta .ex-d b { color: var(--text); font-weight: 600; font-size: 13px; }
.ex-meta .ex-d .up { color: var(--positive); }
.ex-meta .ex-d .down { color: var(--negative); }
.spark { width: 100%; height: 56px; }

/* CTA below the entire trending row — single button instead of one
   featured card with its own button. */
.exchange-cta {
  display: flex; justify-content: center;
  margin-top: 36px;
}
.exchange-card.featured .ex-buy:hover { background: var(--primary-2); }

/* ===== Borrow / Supply ===== */
.market {
  position: relative; border-radius: 24px; padding: 32px;
  background: radial-gradient(80% 90% at 50% 50%, rgba(67, 140, 115, 0.06) 0%, transparent 70%), var(--surface);
  border: 1px solid var(--border);
  overflow: hidden;
}
.market::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    radial-gradient(1px 1px at 12% 18%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 32% 60%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 65% 25%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 80% 70%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 47% 88%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 92% 12%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 22% 78%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 56% 45%, var(--star) 50%, transparent 51%);
  pointer-events: none; opacity: .6;
}
.market-top {
  display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-end;
  position: relative; z-index: 1; margin-bottom: 16px;
}
.market-stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 16px; flex: 1 1 480px; min-width: 0;
}
.stat {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 14px; padding: 14px 18px;
}
.stat .stat-label { font-size: 12px; color: var(--text-3); }
.stat .stat-value { font-size: 18px; font-weight: 700; color: var(--text); margin-top: 4px; font-variant-numeric: tabular-nums; }
.tab-toggle {
  display: inline-flex;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 12px; padding: 4px;
}
.tab-toggle button {
  padding: 10px 28px; border-radius: 9px;
  font-size: 14px; color: var(--text-3);
  transition: background .2s, color .2s;
}
.tab-toggle button.active { background: var(--primary); color: var(--text); }
.mkt-table-wrap { position: relative; z-index: 1; }
.mkt-table { width: 100%; border-collapse: separate; border-spacing: 0 8px; font-size: 14px; }
.mkt-table thead th {
  text-align: left; padding: 14px 18px;
  background: var(--bg);
  color: var(--text-3); font-weight: 500; font-size: 13px;
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  transition: background .25s, color .25s;
}
.mkt-table thead th:first-child { border-left: 1px solid var(--border); border-radius: 12px 0 0 12px; }
.mkt-table thead th:last-child { border-right: 1px solid var(--border); border-radius: 0 12px 12px 0; text-align: right; }
.mkt-table thead th:not(:first-child):not(:last-child) { text-align: right; }
.mkt-table tbody td {
  padding: 14px 18px;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
}
.mkt-table tbody td:first-child { color: var(--text); font-weight: 500; }
.mkt-table tbody td:not(:first-child) { text-align: right; color: var(--text-2); font-variant-numeric: tabular-nums; }
.mkt-table tbody td:last-child { color: var(--positive); font-weight: 600; }
.mkt-table .asset { display: inline-flex; align-items: center; gap: 10px; }
.mkt-table .apy-up { color: var(--positive); }
/* CTA below the borrow/supply table — sits on the .market starfield */
.market-cta {
  position: relative; z-index: 1;
  display: flex; justify-content: center;
  margin-top: 28px;
}

/* highlight Supply APY column when Supply tab is active, Borrow APY otherwise */
.mkt-table[data-mode="supply"] thead th:nth-child(3),
.mkt-table[data-mode="supply"] tbody td:nth-child(3) { color: var(--text); font-weight: 700; }
.mkt-table:not([data-mode="supply"]) thead th:nth-child(5),
.mkt-table:not([data-mode="supply"]) tbody td:nth-child(5) { color: var(--text); font-weight: 700; }

/* ===== Why Trade — bento ===== */
.bento {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 24px; margin-top: 48px;
  grid-template-areas: "a b" "c d";
}
.bento .bc-1 { grid-area: a; } .bento .bc-2 { grid-area: b; }
.bento .bc-3 { grid-area: c; } .bento .bc-4 { grid-area: d; }
.bento-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px; padding: 32px;
  overflow: hidden;
  display: flex; flex-direction: column;
  justify-content: space-between;
  min-height: 320px;
  transition: transform .25s, border-color .25s;
}
.bento-card:hover { transform: translateY(-4px); border-color: var(--primary); }
.bento-card .bc-text { display: flex; flex-direction: column; gap: 10px; max-width: min(70%, 460px); position: relative; z-index: 2; }
.bento-card .bc-text h3 { font-size: 22px; }
.bento-card .bc-text p { margin: 0; font-size: 14px; color: var(--text-2); line-height: 1.5; }
.bento-card .bc-art { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
@media (max-width: 1100px) {
  .bento { grid-template-areas: "a" "b" "c" "d"; grid-template-columns: 1fr; }
  .bento-card { min-height: 280px; }
}

/* ===== Coin Access — horizontal vortex ===== */
.orbit-section {
  position: relative; padding: 120px 0;
  background:
    radial-gradient(1200px 600px at 50% 50%, color-mix(in oklab, var(--primary) 15%, transparent) 0%, transparent 60%),
    var(--bg);
  overflow: hidden;
}
.orbit-section::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    radial-gradient(1.5px 1.5px at 5% 18%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 17% 70%, var(--star) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 30% 32%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 42% 88%, var(--star) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 60% 12%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 73% 60%, var(--star) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 88% 28%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 92% 78%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 9% 92%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 80% 8%, var(--star) 50%, transparent 51%);
  pointer-events: none; opacity: .5;
}
.vortex {
  position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: center;
  gap: clamp(8px, 2.4vw, 32px);
  margin: 80px auto 0;
  max-width: 1200px;
}
.vortex-side { display: flex; align-items: center; gap: clamp(8px, 1.6vw, 28px); flex: 1 1 0; min-width: 0; }
.vortex-side.left { justify-content: flex-end; }
.vortex-side.right { justify-content: flex-start; }
.vortex-coin {
  width: clamp(40px, 5vw, 64px); height: clamp(40px, 5vw, 64px);
  border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 700; color: var(--text); font-size: 20px;
  flex: 0 0 auto;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  border: 1px solid var(--primary-2);
  box-shadow: 0 12px 24px -12px var(--primary-glow);
  opacity: var(--coin-op, 1);
  animation: vortex-float 5s ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}
.vortex-coin svg { width: 60%; height: 60%; color: var(--text); }
@keyframes vortex-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}
@media (prefers-reduced-motion: reduce) {
  .vortex-coin { animation: none; }
}
.vortex-sphere {
  width: clamp(220px, 28vw, 360px);
  height: clamp(220px, 28vw, 360px);
  border-radius: 50%;
  position: relative; flex: 0 0 auto;
  background:
    radial-gradient(circle at 35% 30%, color-mix(in oklab, var(--primary) 60%, white 10%) 0%, var(--primary-3) 50%, color-mix(in oklab, var(--primary-3) 70%, var(--bg)) 80%, var(--bg) 100%);
  box-shadow:
    0 50px 100px -30px var(--primary-glow),
    inset 0 -20px 60px rgba(0,0,0,0.6),
    inset 0 20px 40px rgba(255,255,255,0.06);
}
.vortex-sphere::after {
  content: ""; position: absolute; inset: -8%;
  border-radius: 50%;
  background: radial-gradient(circle, transparent 60%, color-mix(in oklab, var(--primary) 40%, transparent) 70%, transparent 75%);
  pointer-events: none;
}
.vortex-sphere .core {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  color: var(--text);
}
.vortex-sphere .core svg { width: 36%; height: 36%; }

@media (max-width: 900px) {
  .vortex { flex-direction: column; }
  .vortex-side { width: 100%; justify-content: center; }
}

/* ===== Powerful Hub ===== */
.hub-section { position: relative; padding: 120px 0 0; overflow: hidden; }
.hub-section .hub-curve { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.hub-steps {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 24px; margin-top: 80px;
  align-items: end;
}
.hub-step { display: flex; flex-direction: column; gap: 14px; align-items: flex-start; position: relative; }
.hub-step.center { align-items: center; text-align: center; transform: translateY(80px); }
.hub-step.right { align-items: flex-end; text-align: right; transform: translateY(-60px); }
.hub-step .hub-num {
  font-family: "Montserrat", sans-serif; font-weight: 800;
  font-size: clamp(120px, 14vw, 200px); line-height: 0.85;
  color: var(--text); opacity: .85;
  letter-spacing: -0.06em;
}
.hub-step .hub-ico {
  width: 64px; height: 64px;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  display: grid; place-items: center; color: var(--text);
  box-shadow: 0 18px 36px -16px var(--primary-glow);
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
}
.hub-step h3 { font-size: 22px; margin: 0; }
.hub-step p { margin: 0; max-width: 280px; color: var(--text-2); font-size: 14px; }

/* ===== Community ===== */
.community {
  position: relative; padding: 120px 0 80px;
  text-align: center;
  overflow: hidden;
}
.community::before {
  /* Thin horizontal divider between the previous section and the CTA —
     the old radial ring was visibly clipped on either side at typical
     viewport widths. Soft gradient line reads as separator without
     announcing itself. */
  content: ""; position: absolute; top: 32px; left: 50%;
  width: min(960px, 86%); height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(90deg,
    transparent,
    color-mix(in oklab, var(--primary) 55%, transparent) 50%,
    transparent);
  pointer-events: none; z-index: 0;
}
.community::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    radial-gradient(1px 1px at 8% 60%, var(--star) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 92% 50%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 16% 75%, var(--star) 50%, transparent 51%),
    radial-gradient(1px 1px at 84% 78%, var(--star) 50%, transparent 51%);
  opacity: .5; pointer-events: none;
}
.community-inner { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 22px; }
.community h2 { max-width: 760px; }
.community .lead { max-width: 520px; }

/* ===== Footer ===== */
.site-footer {
  position: relative; padding: 64px 0 0;
  background: var(--bg); overflow: hidden;
}
.footer-inner {
  display: flex; flex-direction: column; align-items: center;
  gap: 22px; padding-bottom: 40px;
  position: relative; z-index: 2;
}
.footer-nav {
  display: flex; flex-wrap: wrap; gap: 36px;
  font-size: 15px; color: var(--text);
  justify-content: center;
}
.footer-nav a { transition: color .15s; }
.footer-nav a:hover { color: var(--primary); }
.footer-legal {
  display: flex; flex-wrap: wrap; gap: 28px;
  font-size: 13px; color: var(--text-3);
  justify-content: center;
}
.footer-legal a:hover { color: var(--text-2); }
.footer-copy { font-size: 12px; color: var(--text-4); margin-top: 8px; }
.footer-disclaimer {
  font-size: 12px; color: var(--text-4);
  max-width: 760px; text-align: center;
  padding: 12px 24px;
  border-top: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
  margin-top: 12px;
  line-height: 1.6;
}
.giant-mark {
  font-weight: 800; letter-spacing: -0.05em;
  font-size: 14.5vw; line-height: 0.85;
  background: linear-gradient(180deg, color-mix(in oklab, var(--primary) 50%, transparent) 0%, color-mix(in oklab, var(--primary) 5%, var(--bg)) 90%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-align: center;
  padding: 40px 0 0;
  user-select: none;
  text-transform: lowercase;
  white-space: nowrap;
  overflow: hidden;
  position: relative; z-index: 1;
}

/* ============================================================
   Page-specific styles — auth / about / markets / faq / 404
   ============================================================ */

/* ---- generic page hero (smaller than main hero) ---- */
.page-hero {
  position: relative; padding: 80px 0 56px; overflow: hidden;
  text-align: center;
}
.page-hero::before {
  content: ""; position: absolute; inset: -10% -10% auto -10%; height: 100%;
  background: var(--hero-glow);
  pointer-events: none; z-index: 0;
}
.page-hero .container {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}
.page-hero h1 { font-size: clamp(36px, 4.6vw, 64px); }
.page-hero .lead { text-align: center; }

/* ---- auth.html — secure redirect screen ---- */
.auth-stage {
  min-height: calc(100vh - 112px - 320px);
  display: flex; align-items: center; justify-content: center;
  padding: 80px 0;
  position: relative; overflow: hidden;
}
.auth-stage::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(50% 50% at 50% 50%, color-mix(in oklab, var(--primary) 18%, transparent) 0%, transparent 70%);
  pointer-events: none;
}
.auth-card {
  position: relative; z-index: 1;
  max-width: 520px; width: 100%;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 24px; padding: 48px 40px;
  text-align: center;
  box-shadow: 0 60px 120px -40px var(--primary-glow), 0 0 80px var(--primary-glow);
  display: flex; flex-direction: column; align-items: center; gap: 18px;
}
.auth-icon {
  width: 96px; height: 96px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  display: grid; place-items: center;
  color: var(--text);
  position: relative;
  box-shadow: 0 24px 48px -12px var(--primary-glow);
}
.auth-icon::before {
  content: ""; position: absolute; inset: -8px; border-radius: 50%;
  border: 2px solid color-mix(in oklab, var(--primary) 60%, transparent);
  animation: auth-pulse 2.4s ease-in-out infinite;
}
.auth-icon::after {
  content: ""; position: absolute; inset: -16px; border-radius: 50%;
  border: 1px solid color-mix(in oklab, var(--primary) 40%, transparent);
  animation: auth-pulse 2.4s ease-in-out infinite .8s;
}
@keyframes auth-pulse {
  0%   { transform: scale(.9); opacity: .9; }
  100% { transform: scale(1.4); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .auth-icon::before, .auth-icon::after { animation: none; opacity: 0; }
}
.auth-card h1 { font-size: clamp(26px, 2.8vw, 36px); }
.auth-card p { color: var(--text-2); margin: 0; max-width: 38ch; }
.auth-dots { display: inline-flex; gap: 8px; margin-top: 4px; }
.auth-dots span {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--primary);
  animation: auth-dot 1.2s ease-in-out infinite;
}
.auth-dots span:nth-child(2) { animation-delay: .2s; }
.auth-dots span:nth-child(3) { animation-delay: .4s; }
@keyframes auth-dot {
  0%, 100% { opacity: .25; transform: scale(.85); }
  50%      { opacity: 1;   transform: scale(1.05); }
}
.auth-fineprint {
  font-size: 12px; color: var(--text-4); margin-top: 4px;
}
.auth-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 8px; }

/* ---- about.html ---- */
.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 20px; margin-top: 24px;
}
.stats-grid .stat-card {
  padding: 28px 24px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px;
  display: flex; flex-direction: column; gap: 6px;
  transition: transform .25s, border-color .25s;
}
.stats-grid .stat-card:hover { transform: translateY(-3px); border-color: var(--primary); }
.stats-grid .stat-card .stat-num {
  font-size: clamp(28px, 3vw, 40px); font-weight: 800;
  background: linear-gradient(135deg, var(--text) 0%, var(--primary) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  font-variant-numeric: tabular-nums;
}
.stats-grid .stat-card .stat-name { font-size: 14px; color: var(--text-3); }

.mission-split {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 56px; align-items: center;
}
.mission-art {
  position: relative; aspect-ratio: 1.1 / 1;
  border-radius: 24px; border: 1px solid var(--border);
  background:
    radial-gradient(60% 60% at 50% 50%, color-mix(in oklab, var(--primary) 30%, transparent) 0%, transparent 70%),
    var(--surface);
  display: grid; place-items: center; overflow: hidden;
  padding: 32px;
}
.mission-art .quote-mark {
  font-family: "Montserrat", sans-serif; font-weight: 800;
  font-size: clamp(160px, 18vw, 240px); line-height: 0.7;
  color: var(--primary); opacity: .35; letter-spacing: -.06em;
}

.timeline { display: flex; flex-direction: column; gap: 0; margin-top: 32px; }
.timeline-row {
  display: grid; grid-template-columns: 100px 1fr;
  gap: 28px; padding: 24px 0;
  border-top: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
}
.timeline-row:first-child { border-top: 0; }
.timeline-year {
  font-size: clamp(28px, 3vw, 40px); font-weight: 800;
  color: var(--primary);
  font-variant-numeric: tabular-nums;
}
.timeline-row h4 { margin: 0 0 6px; font-size: 18px; color: var(--text); }
.timeline-row p { margin: 0; font-size: 14px; color: var(--text-3); line-height: 1.6; max-width: 56ch; }

.team-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 20px; margin-top: 32px;
}
.team-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 24px 20px;
  text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  transition: transform .25s, border-color .25s;
}
.team-card:hover { transform: translateY(-4px); border-color: var(--primary); }
.team-avatar {
  width: 88px; height: 88px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  border: 2px solid var(--surface);
  box-shadow: 0 18px 36px -16px var(--primary-glow);
}
.team-avatar.t1 { background: linear-gradient(135deg, #ffd0a3, #c98e6b); }
.team-avatar.t2 { background: linear-gradient(135deg, #c4d8b7, #5e9477); }
.team-avatar.t3 { background: linear-gradient(135deg, #b9c5e6, #5670a8); }
.team-avatar.t4 { background: linear-gradient(135deg, #efbed4, #b86699); }
.team-card h4 { margin: 0; font-size: 16px; color: var(--text); }
.team-card .team-role { color: var(--text-3); font-size: 13px; }

/* ---- markets.html ---- */
.markets-controls {
  display: flex; flex-wrap: wrap; gap: 16px;
  align-items: center; justify-content: space-between;
  margin: 32px 0 20px;
}
.markets-search {
  flex: 1 1 280px; min-width: 240px;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 18px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px;
  transition: border-color .15s;
}
.markets-search:focus-within { border-color: var(--primary); }
.markets-search input {
  flex: 1; background: transparent; border: 0; outline: 0;
  color: var(--text); font-family: inherit; font-size: 14px;
}
.markets-search svg { color: var(--text-3); flex: 0 0 auto; }

.markets-filters {
  display: inline-flex; gap: 4px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 12px; padding: 4px;
}
.markets-filters button {
  padding: 8px 16px; border-radius: 9px;
  font-size: 13px; color: var(--text-3);
  transition: background .2s, color .2s;
}
.markets-filters button.active { background: var(--primary); color: var(--text); }

.markets-table-wrap {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 8px; overflow-x: auto;
}
.markets-table {
  width: 100%; border-collapse: separate; border-spacing: 0;
  font-size: 14px; min-width: 720px;
}
.markets-table thead th {
  text-align: right; padding: 14px 16px;
  color: var(--text-3); font-weight: 500; font-size: 12px;
  border-bottom: 1px solid var(--border);
}
.markets-table thead th:first-child { text-align: left; }
.markets-table tbody td {
  padding: 16px;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 50%, transparent);
}
.markets-table tbody tr:last-child td { border-bottom: 0; }
.markets-table tbody tr:hover { background: color-mix(in oklab, var(--primary) 6%, transparent); }
.markets-table td.num { text-align: right; font-variant-numeric: tabular-nums; color: var(--text); }
.markets-table td.num .up   { color: var(--positive); }
.markets-table td.num .down { color: var(--negative); }
.markets-table .markets-coin { display: inline-flex; align-items: center; gap: 12px; }
.markets-table .markets-coin b { font-size: 14px; color: var(--text); display: block; line-height: 1.2; }
.markets-table .markets-coin small { color: var(--text-3); font-size: 11px; font-weight: 500; }
.markets-table .markets-spark { width: 100px; }
.markets-table .mini-spark { width: 100px; height: 28px; }
.markets-empty td { text-align: center; color: var(--text-3); padding: 32px 16px; }

/* ---- faq.html ---- */
.faq-section {
  max-width: 820px; margin: 0 auto;
  display: flex; flex-direction: column; gap: 12px;
}
.acc-item {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px;
  transition: border-color .2s;
}
.acc-item.open { border-color: var(--primary); }
.acc-head {
  width: 100%; text-align: left;
  padding: 20px 24px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  font-size: 15px; font-weight: 600; color: var(--text);
}
.acc-head .acc-toggle {
  width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid var(--border-2); color: var(--text-2);
  display: grid; place-items: center; flex: 0 0 32px;
  transition: transform .25s, background .2s, color .2s;
}
.acc-item.open .acc-head .acc-toggle {
  background: var(--primary); color: var(--text);
  border-color: var(--primary); transform: rotate(45deg);
}
.acc-body {
  display: grid; grid-template-rows: 0fr;
  transition: grid-template-rows .3s ease;
}
.acc-body > div { overflow: hidden; }
.acc-item.open .acc-body { grid-template-rows: 1fr; }
.acc-body p {
  padding: 0 24px 22px; margin: 0;
  color: var(--text-3); font-size: 14px; line-height: 1.7;
}

/* ---- features.html — feature grid + checkmark list ---- */
.features-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin-top: 32px;
}
.features-grid .feature-tile {
  position: relative;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 24px;
  display: flex; flex-direction: column; gap: 12px;
  transition: transform .25s, border-color .25s, box-shadow .25s;
}
.features-grid .feature-tile:hover {
  transform: translateY(-3px);
  border-color: var(--primary);
  box-shadow: 0 24px 48px -24px var(--primary-glow);
}
.features-grid .feature-tile .feat-ico {
  width: 48px; height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  display: grid; place-items: center; color: var(--text);
  box-shadow: 0 12px 24px -12px var(--primary-glow);
}
.features-grid .feature-tile h4 { margin: 0; font-size: 17px; color: var(--text); }
.features-grid .feature-tile p { margin: 0; font-size: 13px; color: var(--text-3); line-height: 1.6; }

.checkmark-list {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 16px 28px; margin-top: 24px; padding: 0; list-style: none;
}
.checkmark-list li {
  display: flex; align-items: flex-start; gap: 12px;
  font-size: 14px; color: var(--text-2); line-height: 1.5;
}
.checkmark-list li::before {
  content: ""; flex: 0 0 22px;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--primary-soft);
  border: 1px solid var(--primary);
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" fill="none" stroke="%2326e03c" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M3 8l3 3 7-7"/></svg>');
  background-repeat: no-repeat; background-position: center;
  background-size: 14px;
  margin-top: 1px;
}
@media (max-width: 900px) {
  .features-grid { grid-template-columns: 1fr 1fr; }
  .checkmark-list { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .features-grid { grid-template-columns: 1fr; }
}

/* ---- service pages (services-*.html) ---- */
.service-hero {
  position: relative; padding: 80px 0 48px; overflow: hidden;
  text-align: center;
}
.service-hero::before {
  content: ""; position: absolute; inset: -10% -10% auto -10%; height: 110%;
  background: var(--hero-glow); pointer-events: none; z-index: 0;
}
.service-hero .container {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: center; gap: 18px;
}
.service-hero .lead { text-align: center; }
.service-icon {
  width: 80px; height: 80px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  display: grid; place-items: center;
  color: var(--text);
  box-shadow: 0 24px 48px -16px var(--primary-glow);
  margin-bottom: 8px;
}
.service-icon svg { width: 38px; height: 38px; }

.how-steps {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin-top: 32px;
}
.how-step {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 24px;
  display: flex; flex-direction: column; gap: 12px;
}
.how-step .step-num {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--primary-soft);
  border: 1px solid var(--primary-2);
  color: var(--primary);
  display: grid; place-items: center;
  font-weight: 700; font-size: 14px;
}
.how-step h4 { margin: 0; font-size: 16px; color: var(--text); }
.how-step p { margin: 0; font-size: 13px; color: var(--text-3); line-height: 1.6; }
@media (max-width: 900px) { .how-steps { grid-template-columns: 1fr; } }

.benefits-list {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 24px; margin-top: 32px;
}
.benefit-item {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 22px;
  display: flex; gap: 16px; align-items: flex-start;
}
.benefit-item .b-ico {
  flex: 0 0 40px;
  width: 40px; height: 40px; border-radius: 10px;
  background: var(--primary-soft);
  border: 1px solid var(--primary-2);
  color: var(--primary);
  display: grid; place-items: center;
}
.benefit-item h4 { margin: 0 0 4px; font-size: 15px; color: var(--text); }
.benefit-item p { margin: 0; font-size: 13px; color: var(--text-3); line-height: 1.6; }
@media (max-width: 720px) { .benefits-list { grid-template-columns: 1fr; } }

.risk-callout {
  background: linear-gradient(135deg, color-mix(in oklab, var(--negative) 12%, var(--surface)), var(--surface));
  border: 1px solid color-mix(in oklab, var(--negative) 35%, var(--border));
  border-radius: 18px; padding: 24px;
  display: grid; grid-template-columns: 48px 1fr; gap: 16px;
  align-items: flex-start; margin-top: 32px;
}
.risk-callout .r-ico {
  width: 48px; height: 48px; border-radius: 12px;
  background: color-mix(in oklab, var(--negative) 25%, transparent);
  border: 1px solid var(--negative);
  color: var(--negative);
  display: grid; place-items: center;
}
.risk-callout h4 { margin: 0 0 6px; color: var(--text); font-size: 15px; }
.risk-callout p { margin: 0; color: var(--text-2); font-size: 13px; line-height: 1.6; }

.code-block {
  background: var(--bg-2); border: 1px solid var(--border);
  border-radius: 14px; padding: 18px 22px;
  font-family: "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 13px; color: var(--text-2);
  overflow-x: auto; line-height: 1.6;
  margin-top: 16px;
  white-space: pre;
  position: relative;
}
.code-block .tok-key  { color: #f0b34d; }
.code-block .tok-str  { color: var(--positive); }
.code-block .tok-com  { color: var(--text-4); }
.code-block .tok-kw   { color: #5da3ff; }
.code-tabs {
  display: inline-flex; gap: 4px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 10px; padding: 3px;
  margin-bottom: 8px;
}
.code-tabs button {
  padding: 6px 14px; border-radius: 7px;
  font-size: 12px; color: var(--text-3);
  font-family: inherit;
  transition: background .2s, color .2s;
}
.code-tabs button.active { background: var(--primary); color: var(--text); }

.api-endpoints {
  display: grid; grid-template-columns: 1fr;
  gap: 8px; margin-top: 24px;
}
.api-endpoint {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; padding: 14px 18px;
  display: grid; grid-template-columns: 60px 1fr 1fr;
  gap: 16px; align-items: center;
  font-size: 13px;
}
.api-endpoint .method {
  display: inline-block; padding: 3px 8px; border-radius: 6px;
  font-size: 10px; font-weight: 700; letter-spacing: .04em;
  text-align: center;
}
.api-endpoint .method.get  { background: color-mix(in oklab, var(--positive) 18%, transparent); color: var(--positive); }
.api-endpoint .method.post { background: color-mix(in oklab, #5da3ff 18%, transparent); color: #5da3ff; }
.api-endpoint .path {
  font-family: "SFMono-Regular", Menlo, Consolas, monospace;
  color: var(--text);
}
.api-endpoint .desc { color: var(--text-3); font-size: 12px; }
@media (max-width: 720px) {
  .api-endpoint { grid-template-columns: 56px 1fr; }
  .api-endpoint .desc { grid-column: 1 / -1; padding-top: 4px; }
}

.yield-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin-top: 32px;
}
.yield-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 28px;
  display: flex; flex-direction: column; gap: 10px;
  transition: transform .25s, border-color .25s;
}
.yield-card:hover { transform: translateY(-3px); border-color: var(--primary); }
.yield-card .y-apy {
  font-size: clamp(36px, 4vw, 48px); font-weight: 800;
  background: linear-gradient(135deg, var(--positive), var(--primary));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.yield-card .y-apy small {
  font-size: 13px; color: var(--text-3); font-weight: 500;
  -webkit-text-fill-color: var(--text-3);
  display: inline-block; margin-left: 6px;
}
.yield-card h4 { margin: 0; font-size: 18px; color: var(--text); }
.yield-card p { margin: 0; font-size: 13px; color: var(--text-3); line-height: 1.6; }
.yield-card .y-meta {
  margin-top: auto; padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 12px; color: var(--text-3);
  display: flex; justify-content: space-between;
}
.yield-card .y-meta b { color: var(--text); font-weight: 600; }
@media (max-width: 900px) { .yield-grid { grid-template-columns: 1fr; } }

/* ---- status.html: clickable "Subscribe to incidents" call-out ---- */
.status-subscribe {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  margin-top: 32px;
  padding: 20px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  text-decoration: none;
  transition: border-color .2s, transform .15s, box-shadow .25s;
}
.status-subscribe:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 16px 32px -16px var(--primary-glow);
}
.status-subscribe-arrow {
  flex: 0 0 36px;
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--primary);
  color: var(--text);
  display: grid; place-items: center;
  transition: transform .2s;
}
.status-subscribe:hover .status-subscribe-arrow { transform: translateX(2px); }

/* ---- legal-doc shared layout (privacy / terms / cookies / disclaimer) ---- */
.legal-doc {
  display: grid; grid-template-columns: 240px 1fr;
  gap: 56px; align-items: start;
  margin-top: 32px;
}
.legal-toc {
  position: sticky; top: 100px;
  display: flex; flex-direction: column; gap: 4px;
  font-size: 13px;
}
.legal-toc a {
  padding: 8px 12px; border-radius: 8px;
  color: var(--text-3);
  border-left: 2px solid transparent;
  transition: color .15s, background .15s, border-color .15s;
}
.legal-toc a:hover { color: var(--text); background: var(--chip-bg); }
.legal-toc a.active { color: var(--primary); border-left-color: var(--primary); }
.legal-toc-label {
  font-size: 11px; text-transform: uppercase; letter-spacing: .08em;
  color: var(--text-4); padding: 0 12px 8px;
}
.legal-body { max-width: 720px; }
.legal-body section { padding: 8px 0 32px; scroll-margin-top: 100px; }
.legal-body section:not(:last-child) {
  border-bottom: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
}
.legal-body h2 {
  font-size: clamp(22px, 2.4vw, 30px); margin-bottom: 14px;
}
.legal-body h3 { font-size: 17px; margin: 20px 0 8px; color: var(--text); }
.legal-body p, .legal-body li {
  color: var(--text-2); font-size: 14px; line-height: 1.7;
  margin: 0 0 12px;
}
.legal-body ul { padding-left: 22px; }
.legal-body li { margin-bottom: 6px; }
.legal-body code {
  background: var(--bg-2); padding: 1px 6px; border-radius: 4px;
  font-size: 12.5px; color: var(--primary);
}
.legal-meta {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; color: var(--text-4);
  background: var(--chip-bg); padding: 6px 12px; border-radius: 999px;
  border: 1px solid var(--border);
}
.legal-meta b { color: var(--text-2); font-weight: 600; }

@media (max-width: 900px) {
  .legal-doc { grid-template-columns: 1fr; gap: 24px; }
  .legal-toc {
    position: static;
    flex-direction: row; flex-wrap: wrap; gap: 6px;
    border-bottom: 1px solid var(--border); padding-bottom: 16px;
  }
  .legal-toc-label { display: none; }
  .legal-toc a {
    border-left: 0; border: 1px solid var(--border); padding: 6px 12px;
    border-radius: 999px; font-size: 12px;
  }
  .legal-toc a.active {
    border-color: var(--primary); background: var(--chip-bg);
  }
}

/* ---- comparison.html ---- */
.compare-table-wrap {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 8px;
  overflow-x: auto; margin-top: 32px;
}
.compare-table {
  width: 100%; min-width: 720px;
  border-collapse: separate; border-spacing: 0;
  font-size: 14px;
}
.compare-table thead th {
  padding: 18px 20px;
  text-align: left;
  font-weight: 500; font-size: 12px;
  color: var(--text-3);
  border-bottom: 1px solid var(--border);
  text-transform: uppercase; letter-spacing: .06em;
}
.compare-table thead th.us {
  color: var(--primary); font-weight: 700;
  position: relative;
}
.compare-table thead th.us::after {
  content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px;
  height: 2px; background: var(--primary);
}
.compare-table tbody th {
  text-align: left; padding: 16px 20px;
  font-weight: 600; color: var(--text); font-size: 14px;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 50%, transparent);
}
.compare-table tbody td {
  padding: 16px 20px;
  color: var(--text-2);
  border-bottom: 1px solid color-mix(in oklab, var(--border) 50%, transparent);
}
.compare-table tbody td.us {
  color: var(--text); font-weight: 600;
  background: color-mix(in oklab, var(--primary) 8%, transparent);
}
.compare-table tbody tr:last-child th,
.compare-table tbody tr:last-child td { border-bottom: 0; }
.compare-check {
  display: inline-flex; align-items: center; gap: 6px;
}
.compare-check .yes { color: var(--positive); }
.compare-check .no  { color: var(--negative); }

/* ---- resource.html ---- */
.resource-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 20px; margin-top: 32px;
}
.resource-card {
  position: relative;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 18px; padding: 24px;
  display: flex; flex-direction: column; gap: 12px;
  transition: transform .25s, border-color .25s, box-shadow .25s;
}
.resource-card:hover {
  transform: translateY(-4px); border-color: var(--primary);
  box-shadow: 0 24px 48px -24px var(--primary-glow);
}
.resource-card .res-tag {
  align-self: flex-start;
  display: inline-flex; gap: 6px; align-items: center;
  padding: 4px 10px; border-radius: 999px;
  font-size: 11px; color: var(--text-3);
  background: var(--chip-bg); border: 1px solid var(--border);
}
.resource-card .res-ico {
  width: 44px; height: 44px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  color: var(--text); display: grid; place-items: center;
}
.resource-card h4 { margin: 0; font-size: 17px; color: var(--text); }
.resource-card p { margin: 0; font-size: 13px; color: var(--text-3); line-height: 1.6; }
.resource-card .res-arrow {
  position: absolute; top: 22px; right: 22px;
  color: var(--text-3);
  transition: transform .2s, color .2s;
}
.resource-card:hover .res-arrow { color: var(--primary); transform: translate(2px, -2px); }
@media (max-width: 900px) { .resource-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .resource-grid { grid-template-columns: 1fr; } }

/* ---- 404.html ---- */
.notfound-stage {
  min-height: calc(100vh - 112px - 320px);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 64px 0;
  text-align: center; gap: 18px;
  position: relative; overflow: hidden;
}
.notfound-glyph {
  font-weight: 800; letter-spacing: -.06em;
  font-size: clamp(140px, 22vw, 320px); line-height: 0.85;
  background: linear-gradient(180deg, var(--primary) 0%, var(--primary-3) 70%, color-mix(in oklab, var(--primary-3) 20%, var(--bg)) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  user-select: none;
}
.notfound-stage h1 { font-size: clamp(28px, 3.4vw, 44px); }
.notfound-stage p { color: var(--text-2); max-width: 50ch; margin: 0; }
.notfound-stage .hero-cta { margin-top: 8px; }
.notfound-coin {
  position: absolute; width: 64px; height: 64px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-3));
  display: grid; place-items: center;
  color: var(--text); font-size: 24px; font-weight: 700;
  box-shadow: 0 18px 36px -16px var(--primary-glow);
  opacity: .6;
  animation: vortex-float 5s ease-in-out infinite;
}
.notfound-coin.c1 { top: 12%; left: 8%;  animation-delay: 0s; }
.notfound-coin.c2 { top: 18%; right: 12%; animation-delay: .8s; opacity: .45; }
.notfound-coin.c3 { bottom: 22%; left: 14%; animation-delay: 1.6s; opacity: .35; }
.notfound-coin.c4 { bottom: 14%; right: 10%; animation-delay: 2.4s; opacity: .55; }
@media (max-width: 720px) { .notfound-coin { display: none; } }

/* ---- Responsive overrides for secondary pages ---- */
@media (max-width: 1100px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .team-grid  { grid-template-columns: repeat(2, 1fr); }
  .mission-split { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 720px) {
  .stats-grid, .team-grid { grid-template-columns: 1fr; }
  .timeline-row { grid-template-columns: 80px 1fr; gap: 16px; }
  .markets-controls { flex-direction: column; align-items: stretch; }
  .markets-filters { overflow-x: auto; }
}

/* ===== Responsive ===== */
@media (max-width: 1100px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-right { align-items: center; text-align: center; }
  .hero-right h2 { text-align: center; }
  .feature-trio { grid-template-columns: 1fr 1fr; }
  .buy-trade { grid-template-columns: 1fr; }
  .buy-trade-art { height: 400px; }
  .hub-steps { grid-template-columns: 1fr; gap: 48px; }
  .hub-step.center, .hub-step.right { transform: none; align-items: flex-start; text-align: left; }
  .hub-step .hub-num { font-size: 140px; }
  .section-head.split { flex-direction: column; align-items: flex-start; text-align: left; }
}
@media (max-width: 720px) {
  .nav-toggle { display: grid; }
  .lang { display: none; }

  /* Off-canvas slide-down menu */
  .nav-links {
    position: fixed;
    top: 76px; left: 0; right: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 16px 20px 24px;
    border-radius: 0;
    box-shadow: 0 24px 48px -16px rgba(0,0,0,.6);

    /* hidden by default with smooth slide */
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform .25s ease, opacity .25s ease, visibility .25s;
    max-height: calc(100vh - 112px);
    overflow-y: auto;
    z-index: 49;
  }
  body.nav-open .nav-links {
    transform: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
  .nav-links a {
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 15px;
    border: 1px solid transparent;
  }
  .nav-links a.active { background: var(--primary); }

  /* Services dropdown becomes inline accordion on mobile */
  .nav-services { width: 100%; }
  .nav-services .nav-services-trigger {
    width: 100%; justify-content: space-between;
    padding: 12px 16px; border-radius: 10px;
    font-size: 15px;
  }
  .nav-dropdown {
    position: static;
    width: 100%;
    transform: none; opacity: 1; visibility: visible;
    box-shadow: none;
    margin-top: 4px;
    background: var(--bg-2);
    display: none;
  }
  .nav-services.open .nav-dropdown { display: flex; }
  /* on touch devices :hover doesn't trigger; the click toggle handles it */

  body.nav-open { overflow: hidden; }

  .feature-trio { grid-template-columns: 1fr; }
  .market-stats { grid-template-columns: 1fr; }
  /* Borrow/Supply table: tighten container padding + force horizontal scroll
     so 5-column data ($528.18M / 5.09% / etc.) doesn't get squeezed. Same
     pattern as markets-table-wrap and compare-table-wrap. */
  .market { padding: 20px 16px; }
  .mkt-table-wrap { overflow-x: auto; }
  .mkt-table { font-size: 12px; min-width: 640px; }
  .mkt-table thead th, .mkt-table tbody td { padding: 10px 12px; }
  /* Hero copy needs breathing room under the 76px sticky header */
  .hero { padding: 32px 0 64px; }
  /* Hero tilted chip with -7deg overhangs the column at narrow widths */
  .hero-chip-tilt { transform: rotate(-3deg); }
  /* Dashboard favorites text was 9px (Retina-blurry); bump to 10–11px so
     mock numbers stay readable when the .dash-fav panel goes full-width. */
  .dash-fav-row .nm { font-size: 11px; }
  .dash-fav-row .nm small { font-size: 10px; }
  .dash-fav-row .price { font-size: 11px; }
  /* Hamburger button bumped to 44×44 (WCAG AA touch target) */
  .nav-toggle { width: 44px; height: 44px; }
  .footer-nav { gap: 18px; font-size: 13px; }
  .section { padding: 64px 0; }
  .container { padding: 0 20px; }
  .dash { font-size: 9px; grid-template-columns: 44px 1fr; }
  .dash-grid { grid-template-columns: 1fr 1fr; grid-template-rows: auto auto auto; }
  .dash-mining { grid-column: 1 / 2; grid-row: 1 / 2; }
  .dash-progress { grid-column: 2 / 3; grid-row: 1 / 2; }
  .dash-stat { grid-column: 1 / 3; grid-row: 2 / 3; }
  .dash-fav { grid-column: 1 / 3; grid-row: 3 / 4; }
}

/* Galaxy Fold cover screens etc: shrink the giant brand mark a touch
   so "bitexasia" doesn't visibly clip its leading/trailing letters */
@media (max-width: 360px) {
  .giant-mark { font-size: 13vw; }
}

/* ============================================================
   Trust badges strip — SOC 2 / Singapore PSA / ISO 27001
   Used on index.html and audits.html as a credibility signal.
   ============================================================ */
.trust-badges {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  padding: 36px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.trust-badge {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 8px;
  text-decoration: none;
  color: var(--text-2);
  transition: color .2s, transform .2s;
}
.trust-badge:hover { color: var(--text); transform: translateY(-1px); }
.trust-badge:focus-visible { outline: 2px solid var(--primary); outline-offset: 4px; border-radius: 6px; }
.trust-badge-mark {
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(67, 140, 115, 0.05);
  color: var(--primary);
}
.trust-badge:hover .trust-badge-mark {
  background: rgba(67, 140, 115, 0.12);
  border-color: rgba(67, 140, 115, 0.4);
}
.trust-badge-mark svg { width: 32px; height: 32px; }
.trust-badge-text { display: flex; flex-direction: column; gap: 2px; }
.trust-badge-text b {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.01em;
}
.trust-badge-text small {
  font-size: 12px;
  color: var(--text-3);
  line-height: 1.4;
}
@media (max-width: 720px) {
  .trust-badges {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 24px 0;
  }
  .trust-badge { gap: 14px; }
  .trust-badge-mark { width: 48px; height: 48px; }
  .trust-badge-mark svg { width: 28px; height: 28px; }
}

/* ============================================================
   Language switcher — Eng / 中文 (简) / 中文 (繁) dropdown
   Lives inside .lang slot in nav-actions. CSS-only toggle via
   :focus-within (also covers touch via tabindex on the trigger).
   ============================================================ */
.lang-switcher {
  position: relative;
  display: inline-flex;
}
.lang-switcher-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: 0;
  color: var(--text-2);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  padding: 6px 4px;
}
.lang-switcher-trigger:hover { color: var(--text); }
.lang-switcher-trigger svg { transition: transform .2s; }
.lang-switcher:focus-within .lang-switcher-trigger svg.lang-chev { transform: rotate(180deg); }
.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--bg-2, #0a1f1a);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 6px;
  min-width: 160px;
  z-index: 100;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity .15s, visibility .15s, transform .15s;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}
.lang-switcher:focus-within .lang-dropdown,
.lang-switcher:hover .lang-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.lang-dropdown a {
  display: block;
  padding: 8px 12px;
  border-radius: 6px;
  color: var(--text-2);
  text-decoration: none;
  font-size: 13px;
  white-space: nowrap;
}
.lang-dropdown a:hover { background: rgba(67, 140, 115, 0.1); color: var(--text); }
.lang-dropdown a.active { color: var(--primary); font-weight: 600; }
@media (hover: none) {
  /* On touch devices, rely purely on :focus-within (tap toggles focus). */
  .lang-switcher:hover .lang-dropdown { opacity: 0; visibility: hidden; }
  .lang-switcher:focus-within .lang-dropdown { opacity: 1; visibility: visible; }
}
