/* ==========================================================================
   OvenLaunch — design system
   Warm oven tones with a BNB-yellow accent, glassy cards, Space Grotesk + Inter.
   Dark by default; light theme via [data-theme="light"].
   ========================================================================== */

:root,
:root[data-theme="dark"] {
  --bg: #0f0906;
  --bg-2: #140c08;
  --surface: rgba(255, 196, 150, 0.045);
  --surface-2: rgba(255, 196, 150, 0.08);
  --surface-3: rgba(255, 196, 150, 0.12);
  --surface-solid: #1a110b;
  --surface-raised: #221710;
  --border: rgba(255, 196, 150, 0.13);
  --border-strong: rgba(255, 196, 150, 0.28);
  --text: #fbf1e7;
  --text-2: #cdb8a6;
  --text-3: #93806f;
  --primary: #ff7a2f;
  --primary-2: #ffad5c;
  --primary-ink: #1d0b02;
  --bnb: #f3ba2f;
  --success: #3ddc84;
  --success-bg: rgba(61, 220, 132, 0.12);
  --danger: #ff6464;
  --danger-bg: rgba(255, 100, 100, 0.12);
  --warning: #ffc24a;
  --warning-bg: rgba(255, 194, 74, 0.12);
  --info: #6cc8ff;
  --info-bg: rgba(108, 200, 255, 0.1);
  --shield: #6cc8ff;
  --degen: #ff6a3d;
  --reward: #3ddc84;
  --burn: #ff9a3d;
  --grad: linear-gradient(135deg, #ff5a2b 0%, #ff9a3d 55%, #f3ba2f 100%);
  --grad-text: linear-gradient(100deg, #ffd36b 0%, #ff9a3d 50%, #ff5a2b 100%);
  --glow-1: rgba(255, 106, 43, 0.2);
  --glow-2: rgba(243, 186, 47, 0.12);
  --grid-line: rgba(255, 196, 150, 0.04);
  --radius-xs: 8px;
  --radius-sm: 12px;
  --radius: 16px;
  --radius-lg: 22px;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --shadow-sm: 0 6px 20px rgba(0, 0, 0, 0.3);
  --font-sans: "Inter", "Inter Fallback", system-ui, -apple-system, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-display: "Space Grotesk", "Space Grotesk Fallback", system-ui, "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  --header-h: 66px;
  --tabbar-h: 64px;
  color-scheme: dark;
}

:root[data-theme="light"] {
  --bg: #fff8f0;
  --bg-2: #fff3e6;
  --surface: rgba(120, 60, 20, 0.04);
  --surface-2: rgba(120, 60, 20, 0.07);
  --surface-3: rgba(120, 60, 20, 0.11);
  --surface-solid: #ffffff;
  --surface-raised: #ffffff;
  --border: rgba(120, 60, 20, 0.14);
  --border-strong: rgba(120, 60, 20, 0.28);
  --text: #2a160a;
  --text-2: #6b4d39;
  --text-3: #8f7360;
  --primary: #e85a12;
  --primary-2: #c24a0c;
  --primary-ink: #ffffff;
  --success: #12a05a;
  --success-bg: rgba(18, 160, 90, 0.1);
  --danger: #d63838;
  --danger-bg: rgba(214, 56, 56, 0.1);
  --warning: #b07600;
  --warning-bg: rgba(220, 150, 0, 0.12);
  --info: #1a7fc4;
  --info-bg: rgba(26, 127, 196, 0.1);
  --shield: #1a7fc4;
  --degen: #d9481c;
  --reward: #12a05a;
  --burn: #d86a10;
  --grad-text: linear-gradient(100deg, #d98200 0%, #e85a12 55%, #c9330c 100%);
  --glow-1: rgba(255, 140, 60, 0.2);
  --glow-2: rgba(243, 186, 47, 0.18);
  --grid-line: rgba(120, 60, 20, 0.05);
  --shadow: 0 18px 50px rgba(120, 60, 20, 0.14);
  --shadow-sm: 0 6px 20px rgba(120, 60, 20, 0.1);
  color-scheme: light;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: clip; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font: 400 15px/1.6 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  /* a fine warm grain, like flour on a worktop, over the glows */
  background:
    radial-gradient(900px 520px at 10% -10%, var(--glow-1), transparent 60%),
    radial-gradient(700px 480px at 95% 0%, var(--glow-2), transparent 60%),
    var(--bg);
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 75%);
}
body.modal-open { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: var(--primary-2); text-decoration: none; }
a:hover { color: var(--primary); }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; margin: 0 0 0.5em; letter-spacing: -0.02em; color: var(--text); }
h1 { font-size: clamp(2.3rem, 5.4vw, 4.2rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 3vw, 2.3rem); font-weight: 700; }
h3 { font-size: 1.12rem; font-weight: 600; }
h4 { font-size: 0.98rem; font-weight: 600; }
p { margin: 0 0 1em; color: var(--text-2); }
code, .mono { font-family: var(--font-mono); font-size: 0.92em; }
code { background: var(--surface-2); border: 1px solid var(--border); padding: 1px 6px; border-radius: 6px; }
sub { font-size: 0.7em; }
hr { border: 0; border-top: 1px solid var(--border); margin: 20px 0; }
::selection { background: rgba(255, 122, 47, 0.35); }

/* ---------- utilities ---------- */
.muted { color: var(--text-3); }
.small { font-size: 0.86rem; }
.tiny { font-size: 0.76rem; }
.center { text-align: center; }
.hidden { display: none !important; }
.nowrap { white-space: nowrap; }
.num { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.row { display: flex; align-items: center; gap: 10px; }
.row.wrap, .wrap { flex-wrap: wrap; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.gradient-text { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.up { color: var(--success); font-weight: 600; }
.down { color: var(--danger); font-weight: 600; }
.label { font-size: 0.8rem; font-weight: 600; color: var(--text-3); text-transform: uppercase; letter-spacing: 0.06em; }

.container { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 20px; }
.container-narrow { max-width: 820px; }
.section { padding: 84px 0; }
.section-tight { padding: 40px 0; }
.section-alt { background: linear-gradient(180deg, transparent, var(--surface) 20%, var(--surface) 80%, transparent); }
.section-head { max-width: 720px; margin: 0 auto 40px; text-align: center; }
.page { padding-top: 36px; padding-bottom: 72px; }
.page-head { margin-bottom: 26px; }
.page-head h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); margin-bottom: 8px; }
.page-head p { max-width: 720px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 0.74rem/1 var(--font-sans); letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--primary-2); margin-bottom: 14px;
}
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.5s, transform 0.5s; }
.js .reveal.in { opacity: 1; transform: none; }
/* other languages wait for the dictionary; the header and tab bar copied from the previous page are already translated */
.i18n-wait main, .i18n-wait #site-footer, .i18n-wait #site-header:not(.pre), .i18n-wait .env-bar:not([data-pre]), .i18n-wait .tabbar:not([data-pre]) { visibility: hidden; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 0 18px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface-2); color: var(--text);
  font: 600 0.93rem/1 var(--font-sans); cursor: pointer; white-space: nowrap;
  transition: transform 0.15s, filter 0.15s, border-color 0.15s, background 0.15s, box-shadow 0.15s;
}
.btn svg { width: 17px; height: 17px; flex: none; }
.btn:hover { border-color: var(--border-strong); color: var(--text); background: var(--surface-3); }
.btn:focus-visible, .icon-btn:focus-visible, .chip:focus-visible, .list-item:focus-visible { outline: 3px solid rgba(255, 122, 47, 0.45); outline-offset: 2px; }
.btn:disabled, .btn.disabled { opacity: 0.55; cursor: not-allowed; transform: none !important; filter: none !important; }
.btn.disabled { pointer-events: none; }
.btn-primary { background: var(--grad); border-color: transparent; color: #1d0b02; box-shadow: 0 8px 26px rgba(255, 106, 43, 0.32); }
.btn-primary:hover { filter: brightness(1.07); transform: translateY(-1px); color: #1d0b02; background: var(--grad); }
.btn-ghost { background: transparent; }
.btn-outline { background: transparent; border-color: var(--border-strong); }
.btn-danger { background: var(--danger-bg); border-color: rgba(255, 100, 100, 0.4); color: var(--danger); }
.btn-danger:hover { background: rgba(255, 100, 100, 0.2); color: var(--danger); }
.btn-buy { background: var(--success); border-color: transparent; color: #04140b; }
.btn-buy:hover { filter: brightness(1.08); background: var(--success); color: #04140b; }
.btn-sell { background: var(--danger); border-color: transparent; color: #1a0303; }
.btn-sell:hover { filter: brightness(1.08); background: var(--danger); color: #1a0303; }
.btn-sm { min-height: 36px; padding: 0 14px; font-size: 0.86rem; }
.btn-xs { min-height: 30px; padding: 0 11px; font-size: 0.8rem; }
.btn-lg { min-height: 50px; padding: 0 24px; font-size: 1rem; }
.btn-block { width: 100%; }
.btn-icon { width: 38px; min-height: 38px; padding: 0; }
.icon-btn { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; border: 1px solid transparent; background: transparent; color: var(--text-3); cursor: pointer; }
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn.sm { width: 24px; height: 24px; }
.icon-btn.sm svg { width: 14px; height: 14px; }
.icon-btn:hover { color: var(--text); background: var(--surface-2); border-color: var(--border); }
.link-btn { background: none; border: 0; padding: 0; color: var(--primary-2); font: inherit; cursor: pointer; }

/* ---------- badges ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; white-space: nowrap;
  font: 600 0.72rem/1.4 var(--font-sans); border: 1px solid var(--border); background: var(--surface-2); color: var(--text-2);
}
.badge.ember { background: rgba(255, 122, 47, 0.13); color: #ffb084; border-color: rgba(255, 122, 47, 0.35); }
.badge.bnb { background: rgba(243, 186, 47, 0.13); color: #ffd56b; border-color: rgba(243, 186, 47, 0.35); }
.badge.shield { background: rgba(108, 200, 255, 0.12); color: var(--shield); border-color: rgba(108, 200, 255, 0.32); }
.badge.shield.live { box-shadow: 0 0 0 3px rgba(108, 200, 255, 0.12); }
.badge.degen { background: rgba(255, 106, 61, 0.13); color: var(--degen); border-color: rgba(255, 106, 61, 0.35); }
.badge.reward { background: var(--success-bg); color: var(--reward); border-color: rgba(61, 220, 132, 0.3); }
.badge.burn { background: rgba(255, 154, 61, 0.13); color: var(--burn); border-color: rgba(255, 154, 61, 0.32); }
.badge.success { background: var(--success-bg); color: var(--success); border-color: rgba(61, 220, 132, 0.3); }
.badge.warning { background: var(--warning-bg); color: var(--warning); border-color: rgba(255, 194, 74, 0.35); }
.badge.danger { background: var(--danger-bg); color: var(--danger); border-color: rgba(255, 100, 100, 0.35); }
.badge.info { background: var(--info-bg); color: var(--info); border-color: rgba(108, 200, 255, 0.3); }
:root[data-theme="light"] .badge.ember { color: #b8460c; }
:root[data-theme="light"] .badge.bnb { color: #8a6200; }

/* ---------- cards & panels ---------- */
.card {
  position: relative; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 22px;
}
.card-solid { background: var(--surface-solid); }
.card-hover { transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s; }
.card-hover:hover { transform: translateY(-3px); border-color: var(--border-strong); box-shadow: var(--shadow); }
.card-glow::before {
  content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px; pointer-events: none;
  background: var(--grad); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude; opacity: 0.7;
}
.card h3 { margin-bottom: 12px; }
.panel { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; }
.kv-row { display: flex; justify-content: space-between; gap: 12px; font-size: 0.9rem; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60; height: var(--header-h);
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.header-row { position: relative; height: 100%; display: flex; align-items: center; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--text); font: 700 1.22rem/1 var(--font-display); flex: none; letter-spacing: -0.01em; }
.brand-logo { position: relative; display: inline-grid; flex: none; transition: transform 0.25s; }
.brand-logo img { width: 38px; height: 38px; filter: drop-shadow(0 4px 10px rgba(243, 160, 40, 0.3)); }
/* the oven light: a warm glow that breathes in the logo's window */
.brand-logo::after {
  content: ""; position: absolute; left: 24%; right: 24%; top: 44%; bottom: 16%; border-radius: 35%; pointer-events: none;
  background: radial-gradient(closest-side, rgba(255, 190, 80, 0.9), rgba(255, 110, 30, 0.35) 65%, transparent); mix-blend-mode: screen;
  opacity: 0.5;
}
.brand:hover { color: var(--text); }
.brand:hover .brand-logo { transform: rotate(-6deg) scale(1.06); }
.brand:hover .brand-logo::after { animation-duration: 0.8s; }
@keyframes oven-light { 0%, 100% { opacity: 0.2; } 40% { opacity: 0.75; } 55% { opacity: 0.45; } 70% { opacity: 0.65; } }
.brand-word { white-space: nowrap; }
.brand-accent { background: linear-gradient(100deg, #ffd36b, var(--bnb) 45%, #ff9a3d); -webkit-background-clip: text; background-clip: text; color: transparent; }
:root[data-theme="light"] .brand-accent { background: linear-gradient(100deg, #d99a00, #e07b12); -webkit-background-clip: text; background-clip: text; }
.nav { display: flex; gap: 2px; margin-left: 6px; }
.nav a { color: var(--text-2); font-weight: 600; font-size: 0.92rem; padding: 8px 12px; border-radius: 999px; white-space: nowrap; transition: color 0.15s, background 0.15s; }
.nav a:hover { color: var(--text); background: var(--surface-2); }
.nav a.active { color: var(--text); background: var(--surface-3); }
.header-search {
  position: relative; flex: 1; min-width: 0; max-width: 340px; height: 38px; margin-left: auto; display: flex; align-items: center; gap: 9px; padding: 0 10px 0 12px;
  border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text-3); font: 500 0.88rem var(--font-sans); cursor: pointer; transition: border-color 0.15s, background 0.15s;
}
.header-search:hover { border-color: var(--border-strong); background: var(--surface-2); color: var(--text-2); }
.header-search > svg { width: 16px; height: 16px; flex: none; }
.hs-text { flex: 1; min-width: 0; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.search-kbd { display: grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 6px; border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text-3); font: 600 0.72rem/1 var(--font-mono); }
.lang-quick { gap: 6px; padding: 0 10px; font-weight: 600; }
.lang-quick svg { width: 15px; height: 15px; }
.lang-quick svg:last-child { width: 13px; height: 13px; opacity: 0.7; }
/* language list: header pop-up and menu grid */
.lang-menu { position: relative; }
.lang-pop {
  position: absolute; top: calc(100% + 8px); inset-inline-end: 0; z-index: 95; display: grid; gap: 2px; width: 220px; padding: 6px;
  border-radius: 16px; border: 1px solid var(--border-strong); background: var(--surface-raised); box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(-4px); transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
}
.lang-pop.open { opacity: 1; visibility: visible; transform: none; }
.lang-opt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border: 0; border-radius: 10px; background: none; color: var(--text-2); font: 600 0.9rem var(--font-sans); text-align: start; cursor: pointer; }
.lang-opt:hover { background: var(--surface-2); color: var(--text); }
.lang-opt.active { background: rgba(255, 122, 47, 0.12); color: var(--text); }
.lang-opt svg { width: 16px; height: 16px; margin-inline-start: auto; color: var(--primary); }
.lang-badge { display: inline-grid; place-items: center; min-width: 28px; height: 24px; padding: 0 5px; border-radius: 7px; background: var(--surface-3); color: var(--text); font: 700 0.74rem/1 var(--font-sans); }
.lang-opt.active .lang-badge { background: var(--grad); color: #1d0b02; }
.menu-lang { display: grid; gap: 8px; width: 100%; color: var(--text-3); font-size: 0.84rem; font-weight: 600; }
.lang-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.lang-grid .lang-opt { padding: 7px 8px; font-size: 0.82rem; border: 1px solid var(--border); }
.lang-grid .lang-opt svg { display: none; }
.lang-grid .lang-opt.active { border-color: var(--primary); }

/* ---------- search palette (core/palette.js) ---------- */
.palette-open { overflow: hidden; }
.palette-backdrop { position: fixed; inset: 0; z-index: 120; display: grid; justify-items: center; align-items: start; padding: 10vh 16px 16px; background: rgba(8, 4, 2, 0.6); backdrop-filter: blur(6px); animation: pal-in 0.14s ease; }
@keyframes pal-in { from { opacity: 0; } }
.palette { display: flex; flex-direction: column; width: min(640px, 100%); max-height: min(620px, 80vh); border-radius: 20px; border: 1px solid var(--border-strong); background: var(--surface-raised); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5); overflow: hidden; }
.pal-input { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.pal-input > svg { width: 19px; height: 19px; color: var(--text-3); flex: none; }
.pal-input input { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; color: var(--text); font: 500 1.02rem var(--font-sans); }
.pal-input input::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }
.pal-close svg { display: none; width: 18px; height: 18px; }
.pal-close { border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text-3); border-radius: 7px; padding: 3px 8px; font: 600 0.72rem var(--font-mono); cursor: pointer; }
.pal-results { flex: 1; overflow-y: auto; padding: 6px 8px 10px; overscroll-behavior: contain; }
.pal-section { padding: 12px 10px 6px; color: var(--text-3); font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.pal-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 10px; border: 0; border-radius: 12px; background: none; color: var(--text-2); font: inherit; text-align: left; cursor: pointer; }
.pal-item.static { cursor: default; }
.pal-item.active { background: var(--surface-2); color: var(--text); box-shadow: inset 3px 0 0 var(--primary); }
.pal-ic { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border-radius: 10px; background: var(--surface-2); color: var(--text-3); }
.pal-ic svg { width: 17px; height: 17px; }
.pal-ic .tok-logo { width: 34px; height: 34px; }
.pal-emoji { font-size: 1.05rem; line-height: 1; }
.pal-item.active .pal-ic { background: rgba(255, 122, 47, 0.14); color: var(--primary); }
.pal-text { display: grid; gap: 1px; flex: 1; min-width: 0; }
.pal-text b { font-size: 0.92rem; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-text small { font-size: 0.76rem; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-go { color: var(--text-3); font-size: 0.8rem; opacity: 0; }
.pal-item.active .pal-go { opacity: 1; }
.pal-foot { display: flex; gap: 16px; padding: 10px 16px; border-top: 1px solid var(--border); color: var(--text-3); font-size: 0.74rem; }
.pal-foot kbd { display: inline-grid; place-items: center; min-width: 20px; height: 20px; margin-right: 3px; padding: 0 5px; border-radius: 5px; border: 1px solid var(--border-strong); background: var(--surface-2); font: 600 0.68rem var(--font-mono); }

/* ---------- watchlist stars (core/watchlist.js) ---------- */
.star-btn { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; cursor: pointer; color: var(--text-3); transition: color 0.15s, transform 0.15s, background 0.15s; }
.star-btn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.star-btn:hover { color: #ffc83d; transform: scale(1.1); }
.star-btn.on { color: #ffc83d; }
.star-btn.sm { width: 24px; height: 24px; }
.star-btn.sm svg { width: 15px; height: 15px; }
.btn.star-toggle.on { color: #ffc83d; border-color: rgba(255, 200, 61, 0.5); }
.btn.star-toggle.on svg { fill: currentColor; }
.star-btn.on svg { fill: currentColor; }
.star-btn:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.tile-art .star-btn { position: absolute; right: 8px; bottom: 8px; z-index: 2; background: rgba(15, 9, 6, 0.55); color: #e8d5c4; }
.tile-art .star-btn.on { color: #ffc83d; }
.header-right { display: flex; align-items: center; gap: 8px; flex: none; }
.search-toggle { display: none; }
.header-bake { padding: 0 16px; }
.connect-btn { background: transparent; border-color: var(--border-strong); }
.connect-btn:hover { background: var(--surface-2); }
.menu-btn svg { width: 19px; height: 19px; }

/* menu: a dropdown under the header on desktop, a drawer on phones (see responsive) */
.menu-backdrop { display: none; position: fixed; inset: 0; z-index: 80; background: rgba(8, 4, 2, 0.55); opacity: 0; visibility: hidden; transition: opacity 0.2s, visibility 0.2s; }
.site-menu {
  position: fixed; z-index: 90; top: calc(var(--header-h) - 2px); right: max(16px, calc((100vw - 1240px) / 2 + 20px));
  width: min(820px, calc(100vw - 32px)); max-height: calc(100vh - var(--header-h) - 16px); overflow-y: auto; padding: 16px;
  background: var(--surface-raised); border: 1px solid var(--border-strong); border-radius: var(--radius-lg); box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity 0.18s, transform 0.18s, visibility 0.18s;
}
.menu-open .site-menu { opacity: 1; visibility: visible; transform: none; }
.menu-head { display: none; }
.menu-quick { display: none; }
.menu-groups { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px 14px; padding-bottom: 14px; margin-bottom: 14px; border-bottom: 1px solid var(--border); }
.menu-group { min-width: 0; }
.menu-group-title { display: flex; align-items: center; justify-content: space-between; padding: 6px 10px 6px; color: var(--text-3); font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; list-style: none; cursor: default; pointer-events: none; }
.menu-group-title::-webkit-details-marker { display: none; }
.menu-group-title .chev { display: none; }
.menu-group-body { display: grid; gap: 2px; align-content: start; }
.menu-group-body > a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; color: var(--text-2); }
.menu-group-body > a > svg { width: 32px; height: 32px; padding: 7px; border-radius: 10px; background: var(--surface-2); color: var(--text-3); flex: none; transition: color 0.15s, background 0.15s; }
.menu-group-body > a span { display: grid; gap: 1px; min-width: 0; }
.menu-group-body > a b { font-size: 0.9rem; font-weight: 600; color: var(--text); }
.menu-group-body > a small { font-size: 0.74rem; line-height: 1.35; color: var(--text-3); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.menu-group-body > a:hover, .menu-group-body > a.active { background: var(--surface-2); }
.menu-group-body > a:hover > svg, .menu-group-body > a.active > svg { background: rgba(255, 122, 47, 0.14); color: var(--primary); }
.menu-links { display: grid; gap: 1px; margin: 6px 0 0; padding: 6px 0 0 10px; border-top: 1px dashed var(--border); }
.menu-links a { padding: 5px 8px; border-radius: 8px; color: var(--text-2); font-size: 0.82rem; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.menu-links a:hover { background: var(--surface-2); color: var(--text); }
.menu-settings { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 22px; padding: 0 6px 2px; }
.menu-settings .menu-env { margin-left: auto; }
.menu-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--text-3); font-size: 0.84rem; font-weight: 600; }
.menu-row .seg-sm button { display: inline-flex; align-items: center; gap: 5px; }
.menu-row .seg-sm svg { width: 13px; height: 13px; }
.menu-env { display: block; padding: 10px; border-radius: 12px; border: 1px dashed var(--border-strong); text-align: center; font-size: 0.86rem; font-weight: 600; }
.site-menu .socials { margin-top: 14px; padding: 0 6px; }
.chain-pill { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--border); font-size: 0.82rem; font-weight: 600; color: var(--text-2); white-space: nowrap; }
.chain-pill img { width: 18px; height: 18px; border-radius: 5px; }
/* in the header the network is an icon (its name is in the tooltip, the banner and the menu): the search keeps its room */
.header-right .chain-pill { width: 36px; padding: 0; justify-content: center; }
.header-right .chain-pill .chain-name { display: none; }
.chain-pill.local { border-color: rgba(108, 200, 255, 0.4); color: var(--info); }
.chain-pill.wrong { border-color: rgba(255, 100, 100, 0.5); color: var(--danger); }
.lang-select {
  height: 36px; padding: 0 28px 0 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface);
  color: var(--text-2); font: 600 0.82rem var(--font-sans); cursor: pointer; appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 15px) 16px, calc(100% - 10px) 16px; background-size: 5px 5px; background-repeat: no-repeat;
}
.lang-select option { background: var(--surface-solid); color: var(--text); }
.account-btn { gap: 8px; }
.wallet-avatar { display: inline-block; flex: none; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15); }
.env-bar { background: linear-gradient(90deg, rgba(255, 106, 43, 0.16), rgba(243, 186, 47, 0.1)); border-bottom: 1px solid var(--border); font-size: 0.85rem; color: var(--text-2); }
.env-bar .container { display: flex; align-items: center; gap: 12px; padding-top: 7px; padding-bottom: 7px; }
.env-bar b { color: var(--text); }
.env-msg { flex: 1 1 auto; min-width: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.env-bar a { flex: none; white-space: nowrap; font-weight: 600; }
.env-bar.local { background: linear-gradient(90deg, rgba(108, 200, 255, 0.14), rgba(108, 200, 255, 0.05)); }

/* mobile tab bar */
.tabbar { display: none; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding: 36px 0 30px; margin-top: 40px; background: linear-gradient(180deg, transparent, var(--surface)); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 2fr auto; gap: 28px; align-items: start; }
.footer-brand p { margin: 12px 0; max-width: 340px; }
.footer-links { display: grid; grid-template-columns: repeat(4, max-content); gap: 10px 28px; }
.footer-links a { color: var(--text-2); font-size: 0.9rem; }
.footer-links a:hover { color: var(--text); }
.socials { display: flex; gap: 8px; }
.socials a { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--border); color: var(--text-2); }
.socials a svg { width: 16px; height: 16px; }
.socials a:hover { color: var(--text); border-color: var(--border-strong); }
.footer-legal { margin: 18px 0 0; font-size: 0.78rem; color: var(--text-3); max-width: 900px; }

/* ---------- hero ---------- */
.hero { padding: 56px 0 28px; }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; }
.live-dot { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--primary); flex: none; display: inline-block; }
/* the ring scales and fades (transform + opacity only, so the GPU animates it without repainting the page) */
.live-dot::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: rgba(255, 122, 47, 0.6); animation: pulse 1.8s ease-out infinite; }
@keyframes pulse { from { transform: scale(1); opacity: 0.8; } 70%, to { transform: scale(3.4); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .live-dot::after { animation: none; opacity: 0; } }
.hero-sub { font-size: 1.1rem; max-width: 560px; }
.hero-sub b { color: var(--text); font-weight: 600; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin: 26px 0 30px; }
.hero-points { list-style: none; padding: 0; margin: 0; display: flex; gap: 28px; flex-wrap: wrap; color: var(--text-3); font-size: 0.86rem; }
.hero-points span { display: block; font: 700 1.6rem/1.2 var(--font-display); background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* hero art: the 3D oven from the logo, with a live "baking" card */
.hero-art { position: relative; display: grid; place-items: center; min-height: 430px; }
.hero-glow { position: absolute; inset: 6% 4%; border-radius: 50%; background: radial-gradient(closest-side, rgba(255, 176, 60, 0.4), rgba(255, 106, 43, 0.14) 62%, transparent 78%); }
@keyframes glow { from { opacity: 0.7; } to { opacity: 1; } }
.hero-oven { position: relative; width: min(420px, 84%); height: auto; filter: drop-shadow(0 28px 44px rgba(0, 0, 0, 0.45)); }
.bake-card { position: relative; background: rgba(20, 10, 4, 0.82); border: 1px solid rgba(255, 196, 150, 0.22); border-radius: 16px; padding: 14px; color: #fbf1e7; }
.hero-card { position: absolute; right: 0; bottom: 4%; width: min(270px, 72%); box-shadow: 0 18px 44px rgba(0, 0, 0, 0.45); }
.bc-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.bc-head small { display: block; color: #b79b86; font-size: 0.74rem; white-space: nowrap; }
.bc-head .badge { margin-left: auto; color: #ffb084; }
.bc-temp { font: 500 0.74rem/1 var(--font-mono); color: #ffcf7a; }
.bc-bar { height: 8px; border-radius: 99px; background: rgba(255, 255, 255, 0.1); overflow: hidden; margin-bottom: 10px; }
.bc-bar i { display: block; height: 100%; width: 100%; background: var(--grad); border-radius: inherit; transform: scaleX(var(--fill, 0.08)); transform-origin: 0 50%; transition: transform 0.8s ease; }
[dir="rtl"] .bc-bar i { transform-origin: 100% 50%; }
.bc-row { display: flex; justify-content: space-between; font-size: 0.84rem; color: #b79b86; }
.bc-row b { color: #fbf1e7; font-variant-numeric: tabular-nums; }

/* ---------- token logos ---------- */
.tok-logo { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex: none; background: var(--surface-2); }
.tok-logo.sm { width: 22px; height: 22px; }
.tok-logo.lg { width: 48px; height: 48px; }
.tok-logo.xl { width: 64px; height: 64px; }
.tok-logo.xxl { width: 84px; height: 84px; }
.tok-avatar, .tok-emoji {
  --h: 20;
  display: inline-grid; place-items: center; color: #fff; font: 700 0.78rem/1 var(--font-display); letter-spacing: 0.02em;
  background: linear-gradient(135deg, hsl(var(--h) 80% 58%), hsl(calc(var(--h) + 40) 75% 38%));
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.tok-emoji { font-size: 1.2rem; border-radius: 12px; }
.tok-avatar.sm { font-size: 0.55rem; }
.tok-avatar.lg { font-size: 1rem; }
.tok-avatar.xl, .tok-emoji.xl { font-size: 1.3rem; }
.tok-avatar.xxl, .tok-emoji.xxl { font-size: 1.7rem; }
.tok-emoji.xxl { font-size: 2.6rem; border-radius: 22px; }
.tok { display: flex; align-items: center; gap: 10px; min-width: 0; }
.tok-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.tok-text b { color: var(--text); }
.tok-name { color: var(--text-3); font-size: 0.8rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.verified { width: 16px; height: 16px; flex: none; display: inline-block; vertical-align: -2px; margin-left: 4px; }
.pair-chip { display: inline-flex; align-items: center; gap: 4px; padding: 1px 7px 1px 2px; border-radius: 999px; border: 1px solid var(--border); font-size: 0.72rem; font-weight: 600; color: var(--text-2); background: var(--surface); }
.pair-chip img { width: 15px; height: 15px; border-radius: 50%; }
.brand-ico { width: 16px; height: 16px; border-radius: 4px; display: inline-block; }

/* ---------- stats strip ---------- */
.stats-section { padding-top: 8px; }
.stat-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--border); background: var(--border); }
.stat { display: flex; flex-direction: column; gap: 2px; padding: 18px 20px; background: color-mix(in srgb, var(--bg) 82%, transparent); }
.stat b { font: 700 1.55rem/1.2 var(--font-display); color: var(--text); font-variant-numeric: tabular-nums; }
.stat span { color: var(--text-2); font-size: 0.86rem; }
.stat small { font-size: 0.74rem; }

/* ---------- live feed ---------- */
.feed { display: flex; align-items: center; gap: 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--surface); overflow: hidden; height: 44px; }
.feed-label { display: flex; align-items: center; gap: 8px; padding: 0 16px; font: 600 0.78rem var(--font-sans); text-transform: uppercase; letter-spacing: 0.08em; color: var(--primary-2); background: var(--bg-2); height: 100%; border-right: 1px solid var(--border); flex: none; z-index: 1; }
.feed-track { flex: 1; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent); }
.feed-run { display: flex; gap: 22px; width: max-content; animation: marquee 70s linear infinite; }
.feed:hover .feed-run { animation-play-state: paused; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.feed-item { display: inline-flex; align-items: center; gap: 7px; color: var(--text); font-size: 0.84rem; white-space: nowrap; }
.feed-item:hover { color: var(--text); }
.feed-item .side { font: 700 0.66rem/1 var(--font-sans); padding: 3px 6px; border-radius: 5px; }
.side.buy { background: var(--success-bg); color: var(--success); }
.side.sell { background: var(--danger-bg); color: var(--danger); }

/* ---------- king & bakers ---------- */
.board-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 18px; align-items: stretch; }
.king { display: flex; flex-direction: column; gap: 18px; color: var(--text); background: linear-gradient(140deg, rgba(255, 122, 47, 0.12), rgba(243, 186, 47, 0.05) 60%, var(--surface)); height: 100%; }
.king:hover { color: var(--text); }
.king-crown { font: 600 0.78rem var(--font-sans); letter-spacing: 0.1em; text-transform: uppercase; color: var(--bnb); }
.king-main { display: flex; align-items: center; gap: 18px; }
.king-name { font: 700 1.5rem/1.2 var(--font-display); margin-bottom: 8px; }
.king-name .muted { font-size: 0.95rem; font-weight: 500; }
.king-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.king-stats div { display: flex; flex-direction: column; gap: 2px; }
.king-stats b { font: 700 1.1rem var(--font-display); font-variant-numeric: tabular-nums; }
.king-progress .row-between { margin-bottom: 6px; color: var(--text-2); }
.bakers-card { display: flex; flex-direction: column; gap: 10px; }
.bakers-card h3 { margin: 0; }
.bakers { display: flex; flex-direction: column; gap: 4px; }
.baker-row { display: grid; grid-template-columns: 34px 32px 1fr auto; gap: 12px; align-items: center; padding: 9px 10px; border-radius: 12px; color: var(--text); }
.baker-row:hover { background: var(--surface-2); color: var(--text); }
.baker-rank { font-size: 1.15rem; text-align: center; color: var(--text-3); font-weight: 700; }
.baker-id, .baker-earn { display: flex; flex-direction: column; line-height: 1.3; min-width: 0; }
.baker-earn { text-align: right; }
.baker-earn b { font-variant-numeric: tabular-nums; }

/* heat bar (progress to golden brown) */
.heat { height: 6px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.heat i { display: block; height: 100%; border-radius: inherit; background: var(--grad); }
.heat.lg { height: 9px; }

/* ---------- doneness: thermometer, stage chips, the oven dial (core/doneness.js) ---------- */
.thermo { --th: #f3dcb5; display: flex; align-items: center; margin: 8px 0 2px; }
.thermo-bulb { position: relative; z-index: 1; width: 12px; height: 12px; flex: none; border-radius: 50%; background: var(--th); box-shadow: 0 0 0 2px var(--surface-3), 0 0 10px color-mix(in srgb, var(--th) 50%, transparent); }
.thermo-tube {
  position: relative; flex: 1; height: 6px; margin-left: -3px; border-radius: 0 99px 99px 0; overflow: hidden;
  background: linear-gradient(90deg, transparent 19.6%, var(--border-strong) 19.6% 20.4%, transparent 20.4% 49.6%, var(--border-strong) 49.6% 50.4%, transparent 50.4% 79.6%, var(--border-strong) 79.6% 80.4%, transparent 80.4%), var(--surface-3);
}
.thermo-tube i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #ffe2b0, var(--th)); transition: width 0.6s ease; }
.thermo-label { margin-left: 8px; font-size: 0.74rem; color: var(--text-2); white-space: nowrap; }
.thermo-label b { font: 600 0.76rem var(--font-mono); color: var(--text); }
.st-raw { --th: #f3dcb5; }
.st-rising { --th: #ffc07a; }
.st-baking { --th: #ff8a3d; }
.st-almost { --th: #ff6a2b; }
.st-golden { --th: #ffc83d; }
.st-cold { --th: #7cc4ff; }
.thermo.st-golden .thermo-tube i { background: linear-gradient(90deg, #ffe08a, #ffb000); box-shadow: 0 0 12px rgba(255, 190, 40, 0.6); }
.thermo.st-cold .thermo-tube i { background: linear-gradient(90deg, #cfeaff, #7cc4ff); }
.stage-chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 99px; font-size: 0.74rem; font-weight: 600; color: var(--text-2); background: color-mix(in srgb, var(--th) 12%, transparent); border: 1px solid color-mix(in srgb, var(--th) 40%, transparent); }
.stage-chip.st-golden { color: #ffc83d; }
:root[data-theme="light"] .stage-chip.st-golden { color: #a86b00; }
.king-progress .thermo { margin-top: 10px; }
.king-progress .thermo-tube { height: 9px; }
.king-progress .thermo-bulb { width: 16px; height: 16px; }
/* golden tiles get a warm crust; cold ones lose their colour */
.tile.st-golden { border-color: rgba(255, 200, 61, 0.55); box-shadow: 0 0 0 1px rgba(255, 200, 61, 0.18), 0 12px 32px rgba(255, 176, 0, 0.14); }
.tile.st-golden .tile-art::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 35%, rgba(255, 236, 170, 0.32) 48%, transparent 60%); background-size: 260% 100%;
}
.tile.st-cold .tile-art { filter: saturate(0.45) brightness(0.85); }

.oven-dial { text-align: center; }
.oven-dial svg { display: block; width: 100%; max-width: 250px; margin: 0 auto; overflow: visible; }
.dial-track, .dial-fill { fill: none; stroke-width: 14; stroke-linecap: round; }
.dial-track { stroke: var(--surface-3); }
.dial-fill { stroke: url(#dial-grad); filter: drop-shadow(0 0 8px rgba(255, 140, 50, 0.35)); transition: stroke-dasharray 0.9s ease; }
.oven-dial.st-cold .dial-fill { stroke: #7cc4ff; filter: none; }
.dial-ticks line { stroke: var(--text-3); stroke-width: 2; stroke-linecap: round; opacity: 0.55; }
.dial-knob { fill: var(--surface-raised); stroke: var(--th, #ff9a3d); stroke-width: 3; }
.dial-readout { display: grid; gap: 3px; margin-top: -50px; }
.dial-temp { font: 700 2rem/1 var(--font-display); letter-spacing: -0.02em; }
.oven-dial.st-golden .dial-temp { color: #ffc83d; text-shadow: 0 0 26px rgba(255, 200, 61, 0.4); }
.dial-stage { font-size: 0.9rem; font-weight: 600; color: var(--text-2); }
.dial-foot { margin: 12px 0 0; font-size: 0.8rem; color: var(--text-3); }
.dial-card h3 { margin-bottom: 4px; }

/* ---------- Fair Bake seal (core/fairbake.js) ---------- */
.fair-card { --fb: #3ddc84; }
.fair-card.fb-mostly { --fb: #ffb84d; }
.fair-card.fb-care { --fb: #ff6b5b; }
.fair-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.fair-head h3 { margin: 0 0 2px; }
.fair-grade { font-weight: 700; color: var(--fb); font-size: 0.92rem; }
.fair-seal { position: relative; width: 74px; height: 74px; flex: none; display: grid; place-items: center; }
.fair-seal svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.seal-ring { fill: none; stroke: var(--fb); stroke-width: 1.5; stroke-dasharray: 3 4; opacity: 0.6; }
.seal-track, .seal-fill { fill: none; stroke-width: 7; }
.seal-track { stroke: var(--surface-3); }
.seal-fill { stroke: var(--fb); stroke-linecap: round; transition: stroke-dasharray 0.8s ease; }
.fair-seal b { position: relative; font: 700 1.45rem/1 var(--font-display); }
.fair-checks { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 6px; }
.fair-checks li { display: grid; grid-template-columns: 20px 1fr auto; align-items: center; gap: 8px; font-size: 0.84rem; color: var(--text-2); }
.fair-checks i { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; font: 700 0.7rem/1 var(--font-sans); font-style: normal; }
.fair-checks .ok i { background: rgba(61, 220, 132, 0.15); color: #3ddc84; }
.fair-checks .mid i { background: rgba(255, 184, 77, 0.15); color: #ffb84d; }
.fair-checks .bad i { background: rgba(255, 107, 91, 0.15); color: #ff6b5b; }
.fair-checks em { font: 500 0.74rem var(--font-mono); font-style: normal; color: var(--text-3); }
/* phones: doneness + Fair Bake summary under the token stats */
.bake-strip { display: none; }
.bake-strip a { --fb: #3ddc84; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; border: 1px solid var(--border); background: var(--surface); color: var(--text-2); font-size: 0.82rem; font-weight: 600; min-width: 0; }
.bake-strip a span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bake-strip a.fb-mostly { --fb: #ffb84d; }
.bake-strip a.fb-care { --fb: #ff6b5b; }
.strip-temp { font: 700 1.05rem/1 var(--font-display); color: var(--th); }
.strip-score { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 50%; border: 3px solid var(--fb); font: 700 0.8rem/1 var(--font-display); color: var(--text); }

/* ---------- tiles ---------- */
.row-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.row-head h2 { margin-bottom: 4px; }
.row-head p { margin: 0; font-size: 0.9rem; }
.tabs-line { display: flex; gap: 4px; padding: 4px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.tabs-line::-webkit-scrollbar { display: none; }
.tabs-line button { border: 0; background: transparent; color: var(--text-2); font: 600 0.85rem/1 var(--font-sans); padding: 9px 14px; border-radius: 999px; cursor: pointer; white-space: nowrap; }
.tabs-line button.active { background: var(--surface-3); color: var(--text); box-shadow: inset 0 0 0 1px var(--border-strong); }
.tile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 16px; }
.tile {
  position: relative; display: flex; flex-direction: column; color: var(--text); border-radius: var(--radius-lg); overflow: hidden;
  background: var(--surface); border: 1px solid var(--border); transition: transform 0.18s, border-color 0.18s, box-shadow 0.18s;
}
.tile:hover { transform: translateY(-3px); border-color: var(--border-strong); box-shadow: var(--shadow); color: var(--text); }
.tile-art {
  --h: 24;
  position: relative; overflow: hidden; display: grid; place-items: center; aspect-ratio: 16 / 10;
  background: radial-gradient(90% 90% at 50% 25%, hsl(var(--h) 70% 50% / 0.55), hsl(var(--h) 60% 22% / 0.35) 60%, transparent), var(--surface-2);
}
.tile-art .tok-logo { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35); }
.tile-emoji { font-size: 3.6rem; filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.35)); }
.tile-badges { position: absolute; top: 10px; left: 10px; display: flex; gap: 6px; }
.tile-badges .badge { background: rgba(20, 10, 4, 0.82); }
:root[data-theme="light"] .tile-badges .badge { background: rgba(255, 255, 255, 0.92); }
.tile-corner { position: absolute; top: 10px; right: 10px; font: 600 0.72rem/1 var(--font-sans); padding: 5px 8px; border-radius: 999px; background: rgba(20, 10, 4, 0.55); color: #fbf1e7; }
:root[data-theme="light"] .tile-corner { background: rgba(255, 255, 255, 0.8); color: var(--text); }
.tile-body { display: flex; flex-direction: column; gap: 7px; padding: 12px 14px 14px; }
.tile-name { display: flex; align-items: center; gap: 4px; min-width: 0; }
.tile-name b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 1rem; }
.tile-sub { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 0.82rem; }
.tile-mcap { display: flex; align-items: baseline; gap: 6px; font-variant-numeric: tabular-nums; }
.tile-mcap b { font: 700 1.15rem/1.2 var(--font-display); }
.tile-foot { display: flex; gap: 6px; flex-wrap: wrap; min-height: 22px; align-items: center; }
.tile.sample { cursor: help; }

/* ---------- steps / features / fee flow / compare ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.step-n { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; margin-bottom: 14px; background: var(--grad); color: #1d0b02; font: 700 1.05rem/1 var(--font-display); }
.step p, .feat p { margin: 0; font-size: 0.93rem; }
.step b { color: var(--text); }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feat-ic { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--border); font-size: 1.3rem; margin-bottom: 14px; }
.fee-flow { display: grid; grid-template-columns: 1fr auto 1.2fr auto 1.4fr; gap: 14px; align-items: center; }
.ff-split { display: flex; flex-direction: column; gap: 12px; }
.ff-node { display: flex; flex-direction: column; gap: 2px; padding: 16px 18px; border-radius: var(--radius); background: var(--surface-2); border: 1px solid var(--border); }
.ff-node span:last-child { font-size: 0.86rem; color: var(--text-2); }
.ff-n { font: 700 1.6rem/1.1 var(--font-display); color: var(--text); }
.ff-node.muted-node { opacity: 0.75; }
.ff-node.hot-node { background: linear-gradient(135deg, rgba(255, 106, 43, 0.18), rgba(243, 186, 47, 0.1)); border-color: rgba(255, 122, 47, 0.45); }
.ff-arrow { color: var(--text-3); font-size: 1.4rem; }
.compare { margin-top: 28px; padding: 8px 24px; }
.cmp-head, .cmp-row { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 16px; align-items: center; padding: 14px 0; }
.cmp-head { font-size: 0.86rem; border-bottom: 1px solid var(--border); }
.cmp-row { border-bottom: 1px solid var(--border); font-size: 0.93rem; }
.cmp-row:last-child { border-bottom: 0; }
.cmp-row span { color: var(--text-2); }
.yes { color: var(--success); }
.no { color: var(--text-3); font-weight: 500; }

/* ---------- pairs / faq / cta ---------- */
.pairs { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; }
.pair { display: inline-flex; align-items: center; gap: 8px; padding: 7px 15px 7px 8px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); font-weight: 600; }
.pair img { width: 24px; height: 24px; border-radius: 50%; }
.faq { padding: 0; margin-bottom: 12px; border-radius: var(--radius); }
.faq summary { cursor: pointer; list-style: none; padding: 18px 22px; font-weight: 600; display: flex; justify-content: space-between; gap: 12px; color: var(--text); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--primary-2); font-size: 1.3rem; line-height: 1; transition: transform 0.2s; }
.faq[open] summary::after { transform: rotate(45deg); }
.faq p { padding: 0 22px 18px; margin: 0; }
.cta { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding: 36px; }
.cta h2 { margin-bottom: 6px; }
.cta p { margin: 0; }

/* ---------- forms ---------- */
.field { display: flex; flex-direction: column; gap: 7px; }
.field > label, .field > .label-row { font-size: 0.86rem; font-weight: 600; color: var(--text-2); display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.hint { font-size: 0.8rem; color: var(--text-3); font-weight: 400; }
.input, .textarea, select.input {
  width: 100%; min-height: 44px; padding: 10px 14px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font: 500 0.95rem var(--font-sans); outline: none; transition: border-color 0.15s, background 0.15s;
}
.textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
.input:focus, .textarea:focus { border-color: var(--primary); background: var(--surface-2); }
.input.invalid, .textarea.invalid { border-color: var(--danger); }
.input::placeholder, .textarea::placeholder { color: var(--text-3); }
select.input option { background: var(--surface-solid); color: var(--text); }
.input-group { position: relative; display: flex; align-items: center; }
.input-group > svg { position: absolute; left: 13px; width: 16px; height: 16px; color: var(--text-3); pointer-events: none; }
.input-group > svg + .input { padding-left: 38px; }
.input-group .suffix { position: absolute; right: 12px; font-weight: 600; color: var(--text-3); font-size: 0.86rem; pointer-events: none; }
.input-group .input.has-suffix { padding-right: 64px; }
.error-text { color: var(--danger); font-size: 0.82rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
.chip-row { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text-2); font: 600 0.84rem var(--font-sans); cursor: pointer;
}
.chip:hover { border-color: var(--border-strong); color: var(--text); }
.chip.active { border-color: var(--primary); background: rgba(255, 122, 47, 0.12); color: var(--text); }
.segmented { display: inline-flex; padding: 3px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); gap: 2px; }
.segmented button { border: 0; background: transparent; color: var(--text-2); font: 600 0.84rem var(--font-sans); padding: 7px 12px; border-radius: 9px; cursor: pointer; }
.segmented button.active { background: var(--surface-3); color: var(--text); }
.option-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.option-card {
  position: relative; display: flex; flex-direction: column; gap: 4px; text-align: left; padding: 14px 16px; border-radius: var(--radius);
  border: 1px solid var(--border); background: var(--surface); color: var(--text-2); cursor: pointer; font: inherit; transition: border-color 0.15s, background 0.15s;
}
.option-card b { color: var(--text); font-size: 0.98rem; display: flex; align-items: center; gap: 8px; }
.option-card span { font-size: 0.84rem; line-height: 1.45; }
.option-card:hover { border-color: var(--border-strong); }
.option-card.active { border-color: var(--primary); background: linear-gradient(135deg, rgba(255, 122, 47, 0.12), rgba(243, 186, 47, 0.06)); box-shadow: 0 0 0 3px rgba(255, 122, 47, 0.12); }
.option-card .opt-tag { position: absolute; top: 10px; right: 10px; }
/* bake recipes: recipe cards in a bakery-menu style */
.recipe-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.recipe-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 3px; padding: 14px; border-radius: var(--radius); text-align: left; font: inherit; cursor: pointer;
  border: 1px dashed var(--border-strong); background: repeating-linear-gradient(0deg, transparent 0 23px, color-mix(in srgb, var(--border) 60%, transparent) 23px 24px), var(--surface);
  color: var(--text-2); transition: border-color 0.15s, transform 0.15s;
}
.recipe-card:hover { border-color: var(--primary); transform: translateY(-2px); }
.recipe-card.active { border-style: solid; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(255, 122, 47, 0.14); }
.recipe-card:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.recipe-emoji { font-size: 1.6rem; line-height: 1; margin-bottom: 4px; }
.recipe-card b { color: var(--text); font-size: 0.92rem; }
.recipe-card span:last-child { font-size: 0.78rem; line-height: 1.4; }
.range { width: 100%; accent-color: var(--primary); }
.toggle-row { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); cursor: pointer; }
.toggle-row input { margin-top: 3px; accent-color: var(--primary); width: 18px; height: 18px; flex: none; }
.toggle-row b { color: var(--text); }
.dropzone {
  position: relative; display: grid; place-items: center; width: 112px; height: 112px; border-radius: 26px; flex: none; cursor: pointer; overflow: hidden;
  border: 1.5px dashed var(--border-strong); background: var(--surface); color: var(--text-3); text-align: center; font-size: 0.78rem;
}
.dropzone:hover, .dropzone.drag { border-color: var(--primary); color: var(--text); }
.dropzone img { width: 100%; height: 100%; object-fit: cover; }
.dropzone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.dz-hint { padding: 0 8px; font-size: 0.68rem; line-height: 1.4; }
.dz-hint b { display: block; color: var(--text); font-size: 0.86rem; margin-bottom: 2px; }

/* ---------- alerts ---------- */
.alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--surface-2); font-size: 0.88rem; color: var(--text-2); line-height: 1.5; }
.alert > svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.alert b { color: var(--text); }
.alert.info { background: var(--info-bg); border-color: rgba(108, 200, 255, 0.28); }
.alert.info > svg { color: var(--info); }
.alert.warning { background: var(--warning-bg); border-color: rgba(255, 194, 74, 0.32); }
.alert.warning > svg { color: var(--warning); }
.alert.danger { background: var(--danger-bg); border-color: rgba(255, 100, 100, 0.32); }
.alert.danger > svg { color: var(--danger); }
.alert.success { background: var(--success-bg); border-color: rgba(61, 220, 132, 0.3); }
.alert.success > svg { color: var(--success); }

/* ---------- modal ---------- */
.modal-backdrop { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(8, 4, 2, 0.6); backdrop-filter: blur(6px); animation: fadein 0.15s; }
@keyframes fadein { from { opacity: 0; } }
.modal { width: min(460px, 100%); max-height: calc(100vh - 40px); display: flex; flex-direction: column; background: var(--surface-solid); border: 1px solid var(--border-strong); border-radius: var(--radius-lg); box-shadow: var(--shadow); animation: pop 0.18s; }
.modal.wide { width: min(640px, 100%); }
@keyframes pop { from { transform: translateY(10px) scale(0.98); opacity: 0; } }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 20px 12px; }
.modal-head h3 { margin: 0; }
.modal-close { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--border); background: transparent; color: var(--text-2); cursor: pointer; }
.modal-close svg { width: 16px; height: 16px; }
.modal-close:hover { color: var(--text); background: var(--surface-2); }
.modal-body { padding: 4px 20px 20px; overflow-y: auto; }
.modal-foot { padding: 14px 20px; border-top: 1px solid var(--border); }
.list-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; padding: 11px 12px; border-radius: 12px; border: 1px solid transparent; background: transparent; color: var(--text); text-align: left; font: inherit; cursor: pointer; }
.list-item:hover { background: var(--surface-2); border-color: var(--border); color: var(--text); }
.list-item:disabled { opacity: 0.45; cursor: not-allowed; }
.list-item > svg { width: 16px; height: 16px; color: var(--text-3); }
.wallet-ico { width: 32px; height: 32px; border-radius: 9px; }
.tp-list { display: flex; flex-direction: column; gap: 2px; max-height: 360px; overflow-y: auto; }

/* ---------- toasts ---------- */
.toast-stack { position: fixed; right: 18px; bottom: 18px; z-index: 120; display: flex; flex-direction: column; gap: 10px; width: min(380px, calc(100vw - 36px)); }
.toast { display: flex; gap: 10px; align-items: flex-start; padding: 13px 14px; border-radius: 14px; background: var(--surface-raised); border: 1px solid var(--border-strong); box-shadow: var(--shadow); animation: pop 0.18s; }
.t-icon { display: grid; place-items: center; width: 22px; height: 22px; flex: none; }
.t-icon svg { width: 20px; height: 20px; }
.toast.success .t-icon { color: var(--success); }
.toast.error .t-icon { color: var(--danger); }
.toast.info .t-icon { color: var(--info); }
.toast.pending .t-icon { color: var(--primary); }
.t-body { flex: 1; min-width: 0; }
.t-title { font-weight: 600; font-size: 0.92rem; }
.t-msg { font-size: 0.84rem; color: var(--text-2); word-break: break-word; }
.t-close { border: 0; background: transparent; color: var(--text-3); cursor: pointer; padding: 0; width: 20px; height: 20px; }
.t-close svg { width: 16px; height: 16px; }

/* ---------- spinner & skeletons ---------- */
.spinner { width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; display: inline-block; animation: spin 0.7s linear infinite; flex: none; opacity: 0.85; }
.spinner.sm { width: 12px; height: 12px; vertical-align: -1px; }
@keyframes spin { to { transform: rotate(360deg); } }
.skeleton-line, .skeleton-card, .skeleton-tile, .skeleton-text {
  background: linear-gradient(90deg, var(--surface-2), var(--surface-3), var(--surface-2)); background-size: 200% 100%; animation: shimmer 1.4s infinite;
}
.skeleton-line { height: 46px; border-radius: 12px; }
.skeleton-card { min-height: 280px; }
.skeleton-tile { min-height: 290px; border: 0; }
.skeleton-text { color: transparent !important; border-radius: 6px; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- empty state ---------- */
.empty-state { text-align: center; padding: 40px 20px; grid-column: 1 / -1; }
.empty-state .empty-oven { font-size: 2.6rem; margin-bottom: 8px; }
.empty-state p { max-width: 460px; margin: 0 auto 18px; }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; border-radius: var(--radius); }
.table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.table th { text-align: left; font: 600 0.76rem var(--font-sans); text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-3); padding: 10px 12px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.table th.num { text-align: right; }
.table td { padding: 11px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr[data-href] { cursor: pointer; }
.table tbody tr:hover td { background: var(--surface); }
.th-sort { background: none; border: 0; color: inherit; font: inherit; text-transform: inherit; letter-spacing: inherit; cursor: pointer; padding: 0; }
.th-sort.active { color: var(--text); }

/* ---------- tabs ---------- */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); overflow-x: auto; scrollbar-width: none; margin-bottom: 16px; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { border: 0; background: transparent; color: var(--text-2); font: 600 0.9rem var(--font-sans); padding: 10px 14px; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs button:hover { color: var(--text); }
.tabs button.active { color: var(--text); border-bottom-color: var(--primary); }

/* ---------- explore ---------- */
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.filters .input-group { flex: 1; min-width: 220px; max-width: 380px; }
.filters select.input { width: auto; min-height: 40px; padding: 8px 32px 8px 12px; }
/* Explore quick chips: one tap for the common views; the full filters fold away on phones */
.quick-chips { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; overflow-x: auto; scrollbar-width: none; padding: 2px 0; }
.quick-chips::-webkit-scrollbar { display: none; }
.qchip { flex: none; display: inline-flex; align-items: center; gap: 4px; padding: 7px 13px; border-radius: 99px; border: 1px solid var(--border); background: var(--surface); color: var(--text-2); font: 600 0.84rem var(--font-sans); white-space: nowrap; cursor: pointer; transition: border-color 0.15s, background 0.15s; }
.qchip:hover { border-color: var(--border-strong); color: var(--text); }
.qchip.active { border-color: var(--primary); background: rgba(255, 122, 47, 0.12); color: var(--text); }
.qchip-sep { flex: none; width: 1px; height: 22px; background: var(--border); }
.more-filters { display: none; }
.qcount { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--primary); color: #1d0b02; font-size: 0.7rem; }
.link-btn { flex: none; border: 0; background: none; padding: 6px 4px; color: var(--primary-2); font: 600 0.84rem var(--font-sans); cursor: pointer; white-space: nowrap; }
.link-btn:hover { text-decoration: underline; }
.result-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: -4px 0 14px; }
.result-bar p { margin: 0; }

/* ---------- token page ---------- */
.tk-head { display: grid; grid-template-columns: 1fr auto auto; gap: 18px; align-items: center; margin-bottom: 16px; }
.tk-id { display: flex; align-items: center; gap: 16px; min-width: 0; }
.tk-name { margin: 0 0 6px; font-size: clamp(1.5rem, 3vw, 2.1rem); display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.tk-name .muted { font-size: 0.6em; font-weight: 500; }
.tk-tags { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.tk-price { text-align: right; }
.tk-price-v { font: 700 1.7rem/1.1 var(--font-display); font-variant-numeric: tabular-nums; }
.tk-actions { display: flex; gap: 8px; }
.tk-stats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); background: var(--border); margin-bottom: 18px; }
.tk-stats > div { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; background: color-mix(in srgb, var(--bg) 84%, transparent); }
.tk-stats em { font-style: normal; font-size: 0.74rem; color: var(--text-3); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600; }
.tk-stats b { font: 600 1.02rem var(--font-display); font-variant-numeric: tabular-nums; }
.token-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px; align-items: start; }
.tk-side { position: sticky; top: calc(var(--header-h) + 16px); display: flex; flex-direction: column; gap: 18px; }
.chart-card { padding: 14px 16px; }
.chart-toolbar { display: flex; gap: 10px; justify-content: space-between; flex-wrap: wrap; margin-bottom: 10px; }
.seg-sm { display: inline-flex; padding: 2px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface); }
.seg-sm button { border: 0; background: transparent; color: var(--text-3); font: 600 0.78rem var(--font-sans); padding: 5px 9px; border-radius: 8px; cursor: pointer; }
.seg-sm button.active { background: var(--surface-3); color: var(--text); }
.chart-box { min-height: 340px; position: relative; }
.chart-empty { display: grid; place-items: center; min-height: 340px; text-align: center; color: var(--text-3); padding: 20px; }
.chart-src { margin: 6px 0 0; text-align: right; }
.chart-svg { width: 100%; height: auto; display: block; }
.chart-svg .grid-line { stroke: var(--border); stroke-width: 1; }
.chart-svg .axis-text { fill: var(--text-3); font: 500 10.5px var(--font-sans); font-variant-numeric: tabular-nums; }
.chart-svg .candle line { stroke-width: 1; }
.chart-svg .candle.up line, .chart-svg .candle.up rect { stroke: var(--success); fill: var(--success); }
.chart-svg .candle.down line, .chart-svg .candle.down rect { stroke: var(--danger); fill: var(--danger); }
.chart-svg .vol.up { fill: var(--success); opacity: 0.3; }
.chart-svg .vol.down { fill: var(--danger); opacity: 0.3; }
.chart-svg .cline { fill: none; stroke: var(--primary); stroke-width: 2; }
.chart-svg .cline-area { fill: rgba(255, 122, 47, 0.12); }
.chart-svg .last-line { stroke: var(--text-3); stroke-dasharray: 3 3; }
.chart-svg .last-tag.up { fill: var(--success); }
.chart-svg .last-tag.down { fill: var(--danger); }
.chart-svg .last-text { fill: #0f0906; font: 700 10.5px var(--font-sans); }
.chart-svg .crosshair { stroke: var(--text-3); stroke-dasharray: 2 3; }
.chart-svg .chart-hit { fill: transparent; cursor: crosshair; }
.chart-tip { position: fixed; z-index: 130; pointer-events: none; padding: 8px 10px; border-radius: 10px; background: var(--surface-raised); border: 1px solid var(--border-strong); box-shadow: var(--shadow-sm); font-size: 0.8rem; line-height: 1.45; color: var(--text-2); font-variant-numeric: tabular-nums; }
.chart-tip b { color: var(--text); }
.tip-up { color: var(--success); }
.tip-down { color: var(--danger); }
.trade-box { padding: 18px; }
.tb-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 4px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); margin-bottom: 14px; }
.tb-tabs button { border: 0; background: transparent; color: var(--text-2); font: 700 0.95rem var(--font-sans); padding: 10px; border-radius: 10px; cursor: pointer; }
.tb-tabs button.active.buy { background: var(--success-bg); color: var(--success); box-shadow: inset 0 0 0 1px rgba(61, 220, 132, 0.35); }
.tb-tabs button.active.sell { background: var(--danger-bg); color: var(--danger); box-shadow: inset 0 0 0 1px rgba(255, 100, 100, 0.35); }
.tb-pay { display: flex; gap: 6px; margin-bottom: 10px; flex-wrap: wrap; }
.preset-row { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.preset-row .btn { min-height: 30px; padding: 0 10px; font-size: 0.8rem; }
.tb-out { min-height: 46px; margin: 12px 0; font-size: 0.86rem; color: var(--text-2); }
.tb-out b { color: var(--text); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 0; font-size: 0.88rem; }
.kv dt { color: var(--text-3); }
.kv dd { margin: 0; text-align: right; color: var(--text); min-width: 0; overflow-wrap: anywhere; }
.check-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.check-list li { display: flex; gap: 10px; align-items: flex-start; font-size: 0.9rem; color: var(--text-2); }
.check-list li svg { width: 18px; height: 18px; flex: none; margin-top: 2px; }
.check-list li.ok svg { color: var(--success); }
.check-list li.warn svg { color: var(--warning); }
.check-list .cl { flex: none; display: grid; place-items: center; width: 20px; height: 20px; margin-top: 1px; border-radius: 50%; font: 700 0.72rem/1 var(--font-sans); font-style: normal; }
.check-list li.ok .cl { background: rgba(61, 220, 132, 0.15); color: var(--success); }
.check-list li.warn .cl { background: rgba(255, 184, 77, 0.15); color: var(--warning); }

/* help center */
.help-search { display: flex; align-items: center; gap: 10px; width: min(560px, 100%); margin-top: 18px; padding: 13px 16px; border-radius: 16px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text-3); font: 500 0.98rem var(--font-sans); cursor: pointer; text-align: left; }
.help-search span { flex: 1; }
.help-search:hover { border-color: var(--primary); color: var(--text-2); }
.help-search kbd, .prose kbd { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 6px; border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text-2); font: 600 0.74rem/1 var(--font-mono); }
.help-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 0 0 34px; }
.help-card { display: grid; gap: 6px; padding: 18px; color: var(--text-2); font-size: 0.88rem; }
.help-card b { color: var(--text); font: 600 1rem var(--font-display); }
.help-ic { display: block; height: 30px; font-size: 1.7rem; line-height: 30px; margin-bottom: 4px; }
.prose .help-steps { padding: 0; }
.help-steps { list-style: none; counter-reset: step; padding: 0; display: grid; gap: 12px; margin: 14px 0 18px; }
.help-steps li { counter-increment: step; position: relative; padding: 12px 14px 12px 54px; border-radius: 14px; border: 1px solid var(--border); background: var(--surface); }
.help-steps li::before { content: counter(step); position: absolute; left: 14px; top: 12px; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--grad); color: #1d0b02; font: 700 0.86rem/1 var(--font-display); }
.glossary { display: grid; grid-template-columns: max-content 1fr; gap: 10px 18px; margin: 12px 0 0; }
.glossary dt { font-weight: 700; color: var(--text); }
.glossary dd { margin: 0; color: var(--text-2); }
.check-list b { color: var(--text); }
.holder-tag { display: inline-block; margin-left: 6px; padding: 1px 6px; border-radius: 6px; font-size: 0.7rem; font-weight: 600; background: var(--surface-3); color: var(--text-2); }
.addr-wrap { display: inline-flex; align-items: center; gap: 2px; }
.addr { font-family: var(--font-mono); font-size: 0.86rem; color: var(--text-2); }
.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.metric { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border); }
.metric span { font-size: 0.76rem; color: var(--text-3); }
.metric b { font: 700 1.1rem var(--font-display); font-variant-numeric: tabular-nums; }
.metric small { font-size: 0.76rem; color: var(--text-3); }
.stack-bar { display: flex; height: 10px; border-radius: 99px; overflow: hidden; background: var(--surface-3); }
.stack-bar span { height: 100%; }
.sb-creator { background: var(--primary); }
.sb-holders { background: var(--reward); }
.sb-buyback { background: var(--bnb); }
.sb-referrer { background: var(--info); }
.sb-platform { background: var(--text-3); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 10px; font-size: 0.8rem; color: var(--text-2); }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 5px; vertical-align: 0; }
.sniped-meter { display: flex; align-items: center; gap: 12px; }
.sniped-meter .heat { flex: 1; }
.tk-mobile-bar { display: none; }

/* ---------- bake ---------- */
.bake-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 22px; align-items: start; }
.stepper { display: flex; gap: 6px; margin-bottom: 22px; }
.stepper button { flex: 1; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); color: var(--text-3); font: 600 0.9rem var(--font-sans); cursor: pointer; text-align: left; }
.stepper .n { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; background: var(--surface-3); font: 700 0.85rem var(--font-display); color: var(--text-2); flex: none; }
.stepper button.active { border-color: var(--primary); color: var(--text); background: rgba(255, 122, 47, 0.08); }
.stepper button.active .n { background: var(--grad); color: #1d0b02; }
.stepper button.done .n { background: var(--success-bg); color: var(--success); }
.form-section { display: none; }
.form-section.active { display: flex; flex-direction: column; gap: 22px; animation: fadein 0.2s; }
.form-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 6px; }
.sect-title { margin: 0 0 4px; font-size: 1.02rem; }
.sect-desc { margin: 0 0 12px; font-size: 0.88rem; }
.split-sliders { display: flex; flex-direction: column; gap: 14px; }
.split-row { display: grid; grid-template-columns: 150px 1fr 56px; gap: 12px; align-items: center; font-size: 0.9rem; }
.split-row b { text-align: right; font-variant-numeric: tabular-nums; }
.preview-card { display: flex; flex-direction: column; gap: 16px; }
.pv-head { display: flex; align-items: center; gap: 14px; min-width: 0; }
.pv-name { font: 700 1.25rem/1.2 var(--font-display); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.summary-list { display: flex; flex-direction: column; gap: 8px; }
.si { display: flex; justify-content: space-between; gap: 12px; font-size: 0.88rem; }
.si > span:first-child { color: var(--text-3); }
.si > span:last-child { text-align: right; color: var(--text); font-weight: 500; }
.total-row { display: flex; justify-content: space-between; align-items: baseline; padding-top: 12px; margin-top: 12px; border-top: 1px dashed var(--border-strong); }
.total-row .v { font: 700 1.2rem var(--font-display); }
.sticky-col { position: sticky; top: calc(var(--header-h) + 16px); }
.success-burst { text-align: center; font-size: 3rem; margin-bottom: 6px; }

/* ---------- swap ---------- */
.swap-wrap { max-width: 480px; margin: 0 auto; }
.swap-card { padding: 18px; }
.swap-field { padding: 14px 16px; border-radius: var(--radius); background: var(--surface-2); border: 1px solid var(--border); }
.swap-field .row-between { margin-bottom: 8px; }
.swap-amount { width: 100%; border: 0; background: transparent; color: var(--text); font: 700 1.7rem var(--font-display); outline: none; min-width: 0; padding: 0; }
.swap-amount::placeholder { color: var(--text-3); }
.token-btn { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px 0 6px; border-radius: 999px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font: 700 0.95rem var(--font-sans); cursor: pointer; flex: none; }
.token-btn:hover { background: var(--surface-3); }
.token-btn svg { width: 16px; height: 16px; color: var(--text-3); }
.swap-flip { display: grid; place-items: center; width: 40px; height: 40px; margin: -12px auto; position: relative; z-index: 2; border-radius: 12px; border: 4px solid var(--bg); background: var(--surface-raised); color: var(--text-2); cursor: pointer; }
.swap-flip svg { width: 18px; height: 18px; }
.swap-flip:hover { color: var(--text); }
.swap-details { margin: 14px 0; display: flex; flex-direction: column; gap: 6px; font-size: 0.86rem; }

/* ---------- portfolio ---------- */
.pf-head { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.pf-summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 22px; }
.pf-list { display: flex; flex-direction: column; gap: 10px; }
.pf-item { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)) auto; gap: 14px; align-items: center; padding: 14px 16px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); }
.pf-item .metric-inline { display: flex; flex-direction: column; font-size: 0.86rem; min-width: 0; }
.pf-item .metric-inline span { color: var(--text-3); font-size: 0.74rem; }
.pf-item .metric-inline b { font-variant-numeric: tabular-nums; }
.ref-box { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.ticket-preview { display: grid; place-items: center; aspect-ratio: 1200 / 630; border-radius: 14px; border: 1px solid var(--border); background: var(--surface); overflow: hidden; color: var(--text-3); font-size: 0.88rem; }
.ticket-preview img { width: 100%; height: 100%; display: block; }
.ref-box .input { flex: 1; min-width: 240px; font-family: var(--font-mono); font-size: 0.86rem; }

/* ---------- docs ---------- */
.docs-grid { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 36px; align-items: start; }
.toc { position: sticky; top: calc(var(--header-h) + 20px); display: flex; flex-direction: column; gap: 2px; }
.toc a { color: var(--text-2); font-size: 0.88rem; padding: 6px 10px; border-radius: 8px; border-left: 2px solid transparent; }
.toc a:hover { color: var(--text); background: var(--surface); }
.toc a.active { color: var(--text); border-left-color: var(--primary); background: var(--surface); }
.prose { max-width: 820px; }
.prose section { padding-bottom: 26px; margin-bottom: 26px; border-bottom: 1px solid var(--border); scroll-margin-top: calc(var(--header-h) + 20px); }
.prose section:last-child { border-bottom: 0; }
.prose h2 { font-size: 1.55rem; margin-bottom: 12px; }
.prose h3 { margin-top: 18px; }
.prose ul, .prose ol { color: var(--text-2); padding-left: 20px; }
.prose li { margin-bottom: 6px; }
.prose li b, .prose p b { color: var(--text); }
.prose table { width: 100%; border-collapse: collapse; margin: 12px 0 16px; font-size: 0.88rem; }
.prose th, .prose td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.prose th { color: var(--text-3); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.05em; }
.prose td { color: var(--text-2); }
.prose td:first-child { color: var(--text); font-weight: 500; }
.prose pre { margin: 10px 0 16px; padding: 14px 16px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); overflow-x: auto; font-size: 0.82rem; line-height: 1.55; }
.prose pre code { font-size: inherit; color: var(--text-2); white-space: pre; background: none; border: 0; padding: 0; border-radius: 0; }
.prose td code { overflow-wrap: anywhere; }
/* home: signature features */
.signature-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.sig-card { display: flex; flex-direction: column; gap: 6px; padding: 18px; }
.sig-card h3 { margin: 6px 0 2px; }
.sig-card p { margin: 0; font-size: 0.9rem; }
.sig-demo { display: grid; align-content: center; gap: 10px; min-height: 132px; padding: 14px; border-radius: 14px; border: 1px solid var(--border); background: radial-gradient(90% 100% at 50% 0%, rgba(255, 122, 47, 0.12), transparent), var(--surface-2); }
.sig-stages { display: flex; flex-wrap: wrap; gap: 6px; }
.sig-fair { grid-template-columns: auto 1fr; align-items: center; }
.sig-fair .fair-checks { margin: 0; }
.sig-fair .fair-checks li { grid-template-columns: 20px 1fr; font-size: 0.8rem; }
.sig-recipes { grid-template-columns: 1fr; gap: 6px; }
.sig-recipes span { padding: 6px 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; border-radius: 10px; border: 1px dashed var(--border-strong); background: var(--surface); font-size: 0.78rem; font-weight: 600; color: var(--text-2); }
.sig-recipes span:first-child { border-style: solid; border-color: var(--primary); color: var(--text); }
.mini-ticket { position: relative; display: grid; gap: 4px; padding: 12px 14px; border-radius: 12px; border: 1px solid rgba(255, 196, 150, 0.25); background: rgba(20, 10, 4, 0.75); color: #e8d5c4; font-size: 0.78rem; transform: rotate(-2deg); box-shadow: 0 10px 24px rgba(0, 0, 0, 0.3); }
.mini-ticket::before, .mini-ticket::after { content: ""; position: absolute; top: 50%; width: 14px; height: 14px; margin-top: -7px; border-radius: 50%; background: var(--surface-2); }
.mini-ticket::before { left: -8px; }
.mini-ticket::after { right: -8px; }
.mini-ticket b { font: 700 1.05rem var(--font-display); color: #fbf1e7; }
.mini-ticket span { display: flex; justify-content: space-between; }
.mini-ticket em { font-style: normal; font-weight: 700; color: #ffc83d; }

/* brand kit (developers page) */
.brand-kit { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 14px 0 18px; }
.kit-item { margin: 0; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.kit-item.wide { grid-column: span 2; }
.kit-preview { display: grid; place-items: center; height: 150px; padding: 16px; background: radial-gradient(80% 90% at 50% 30%, rgba(255, 122, 47, 0.16), transparent), #140b07; }
.kit-preview.light { background: #fff8f0; }
.kit-preview.accent { background: linear-gradient(135deg, #ff5a2b, #f3ba2f); }
.kit-preview img { max-width: 100%; max-height: 118px; width: auto; height: auto; object-fit: contain; }
.kit-preview img[src$=".svg"] { width: 104px; height: 104px; }
.kit-item figcaption { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; align-items: center; padding: 10px 14px; font-size: 0.82rem; }
.kit-item figcaption b { color: var(--text); }
.kit-item figcaption span { grid-column: 1; color: var(--text-3); }
.kit-item figcaption a { grid-column: 2; grid-row: 1 / span 2; font-weight: 600; }
.swatches { display: flex; flex-wrap: wrap; gap: 10px; margin: 10px 0 16px; }
.swatches span { display: grid; grid-template-columns: 34px auto; grid-template-rows: auto auto; column-gap: 10px; align-items: center; padding: 8px 12px 8px 8px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); font-size: 0.8rem; }
.swatches i { grid-row: span 2; width: 34px; height: 34px; border-radius: 9px; background: var(--c); border: 1px solid var(--border-strong); }
.swatches b { color: var(--text); }
.swatches code { padding: 0; border: 0; background: none; font-size: 0.74rem; color: var(--text-3); }

/* ---------- responsive ---------- */
@media (max-width: 1400px) {
  /* laptops (1280–1366 px at 100%): the network label lives in the banner and the menu, so the header fits */
  .desktop-only { display: none !important; }
}
@media (max-width: 1180px) {
  .header-search { max-width: 260px; }
  .nav a { padding: 8px 11px; }
}
@media (max-width: 1060px) {
  /* the search field folds into an icon that opens the search palette */
  .header-search { display: none; }
  .menu-groups { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lang-quick svg:last-child { display: none; }
  .header-right { margin-left: auto; }
  .search-toggle { display: inline-flex; }
  .token-grid, .bake-grid { grid-template-columns: 1fr; }
  .tk-side, .sticky-col { position: static; }
  .bake-strip { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: -6px 0 16px; }
  .board-grid { grid-template-columns: 1fr; }
  .fee-flow { grid-template-columns: 1fr; }
  .ff-arrow { transform: rotate(90deg); justify-self: center; }
  .docs-grid { grid-template-columns: minmax(0, 1fr); }
  .brand-kit { grid-template-columns: 1fr 1fr; }
  .help-cards { grid-template-columns: 1fr 1fr; }
  .toc { display: none; }
  .tk-stats { grid-template-columns: repeat(3, 1fr); }
  .pf-summary { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { min-height: 330px; }
  .steps, .features { grid-template-columns: 1fr 1fr; }
  .signature-grid { grid-template-columns: 1fr 1fr; }
  .nav { display: none; }
  .header-search { max-width: none; }
  .stat-strip { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-links { grid-template-columns: repeat(3, max-content); }
  .tabbar {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 70;
    height: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
    background: var(--bg); border-top: 1px solid var(--border);
  }
  .tabbar a { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--text-3); font-size: 0.7rem; font-weight: 600; }
  .tabbar a svg { width: 21px; height: 21px; }
  .tabbar a.active { color: var(--primary-2); }
  .tabbar a.active:not(.tab-bake)::before { content: ""; position: absolute; top: 0; width: 26px; height: 3px; border-radius: 0 0 3px 3px; background: var(--grad); }
  .header-bake { display: none; }
  .connect-btn, .connect-btn:hover { background: var(--grad); border-color: transparent; color: #1d0b02; box-shadow: 0 6px 20px rgba(255, 106, 43, 0.3); }
  .hero-art { min-height: 360px; }
  .hero-oven { width: min(340px, 72%); }
  .tabbar a.tab-bake svg { width: 40px; height: 40px; padding: 9px; border-radius: 14px; background: var(--grad); color: #1d0b02; box-shadow: 0 6px 18px rgba(255, 106, 43, 0.4); margin-top: -14px; }
  body { padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); }
  .toast-stack { bottom: calc(var(--tabbar-h) + 14px + env(safe-area-inset-bottom)); }
  .tk-mobile-bar { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; position: fixed; left: 0; right: 0; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); z-index: 65; padding: 10px 16px; background: color-mix(in srgb, var(--bg) 90%, transparent); border-top: 1px solid var(--border); }
  .page-token { padding-bottom: 80px; }
}
@media (max-width: 720px) {
  .container { padding-left: 16px; padding-right: 16px; }
  .page { padding-top: 22px; padding-bottom: 48px; }
  .header-row { gap: 6px; }
  .header-right { gap: 6px; }
  .brand { font-size: 1.12rem; }
  .brand-logo img { width: 34px; height: 34px; }
  .env-bar { font-size: 0.8rem; }
  .env-extra { display: none; }
  .hero-art { min-height: 0; display: flex; flex-direction: column; align-items: center; padding-top: 6px; }
  .hero-oven { width: min(280px, 76%); }
  .hero-card { position: relative; right: auto; bottom: auto; align-self: flex-end; width: min(270px, 80%); margin-top: -42px; }
  /* the menu becomes a drawer from the right */
  .menu-backdrop { display: block; }
  .site-menu {
    top: 0; right: 0; bottom: 0; width: min(86vw, 340px); max-height: none; border-radius: 22px 0 0 22px;
    padding: 16px 14px calc(16px + env(safe-area-inset-bottom)); transform: translateX(100%); transition: transform 0.24s ease, visibility 0.24s;
    opacity: 1;
  }
  .menu-open .menu-backdrop { opacity: 1; visibility: visible; }
  .menu-head { display: flex; align-items: center; justify-content: space-between; padding: 2px 6px 14px; }
  .menu-head .brand-logo img { width: 30px; height: 30px; }
  .site-menu { width: min(90vw, 360px); }
  .lang-menu { display: none; }
  .lang-grid { grid-template-columns: 1fr 1fr; }
  .palette-backdrop { padding: 0; align-items: stretch; }
  .palette { width: 100%; max-height: none; height: 100%; border-radius: 0; border: 0; }
  .pal-foot { display: none; }
  .pal-close { border: 0; background: none; padding: 4px; }
  .pal-close span { display: none; }
  .pal-close svg { display: block; }
  .menu-quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; }
  .menu-quick-btn { display: grid; justify-items: center; gap: 4px; padding: 10px 4px; border-radius: 14px; border: 1px solid var(--border); background: var(--surface); color: var(--text-2); font: 600 0.74rem var(--font-sans); cursor: pointer; }
  .menu-quick-btn svg { width: 19px; height: 19px; color: var(--text-3); }
  .menu-quick-btn.primary { background: var(--grad); border-color: transparent; color: #1d0b02; }
  .menu-quick-btn.primary svg { color: #1d0b02; }
  .menu-groups { grid-template-columns: 1fr; gap: 2px; padding-bottom: 12px; margin-bottom: 12px; }
  .menu-group { border-radius: 14px; }
  .menu-group[open] { background: color-mix(in srgb, var(--surface) 70%, transparent); }
  .menu-group-title { pointer-events: auto; cursor: pointer; padding: 11px 12px; font-size: 0.74rem; }
  .menu-group-title .chev { display: inline-grid; transition: transform 0.2s; }
  .menu-group-title .chev svg { width: 16px; height: 16px; }
  .menu-group[open] .menu-group-title .chev { transform: rotate(180deg); }
  .menu-group-body { padding: 0 4px 8px; }
  .menu-links { grid-template-columns: 1fr 1fr; padding-left: 4px; }
  .menu-settings { display: grid; gap: 12px; }
  .menu-settings .menu-env { margin-left: 0; }
  .section { padding: 60px 0; }
  .hero { padding-top: 30px; }
  .steps, .features { grid-template-columns: 1fr; }
  .signature-grid { grid-template-columns: 1fr; }
  .cmp-head, .cmp-row { grid-template-columns: 1.3fr 1fr 1fr; gap: 10px; font-size: 0.82rem; }
  .compare { padding: 6px 14px; }
  .cta { padding: 24px; }
  .king-stats { grid-template-columns: repeat(2, 1fr); }
  .tile-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .tile-body { padding: 10px 11px 12px; }
  .tile-badges .badge:nth-child(n + 2) { display: none; }
  .tile-mcap b { font-size: 1rem; }
  .tk-head { grid-template-columns: 1fr; }
  .tk-price { text-align: left; }
  .tk-stats { grid-template-columns: repeat(2, 1fr); }
  .form-grid, .grid-2, .grid-3, .metric-grid { grid-template-columns: 1fr; }
  .recipe-cards { grid-template-columns: 1fr 1fr; }
  .brand-kit { grid-template-columns: 1fr; }
  .glossary { grid-template-columns: 1fr; gap: 2px; }
  .glossary dd { margin-bottom: 10px; }
  .kit-item.wide { grid-column: auto; }
  .split-row { grid-template-columns: 110px 1fr 48px; }
  .stepper button { font-size: 0; gap: 0; justify-content: center; }
  .stepper .n { font-size: 0.85rem; }
  .pf-summary { grid-template-columns: 1fr 1fr; }
  .pf-item { grid-template-columns: 1fr 1fr; }
  .pf-item > :first-child { grid-column: 1 / -1; }
  .hide-sm { display: none; }
  .filters { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  /* the search box stays; the selects open with the Filters chip */
  .filters > select.input, .filters > .chip { display: none; }
  .filters.open > select.input { display: block; }
  .filters.open > .chip { display: inline-flex; }
  .more-filters { display: inline-flex; }
  .filters .input-group { grid-column: 1 / -1; max-width: none; }
  .filters select.input { width: 100%; min-width: 0; padding-right: 28px; font-size: 0.9rem; }
  .filters select:first-of-type { grid-column: 1 / -1; }
  .filters .chip { justify-self: start; }
  .footer-links { grid-template-columns: repeat(2, max-content); }
}
@media (max-width: 1060px) { .hide-md { display: none; } }
@media (max-width: 379px) {
  .site-header .brand-word { display: none; }
  .filters select.input { font-size: 0.84rem; padding-left: 10px; padding-right: 24px; }
}
@media (max-width: 420px) {
  .stat b { font-size: 1.25rem; }
  .stat { padding: 14px; }
  .hero-points { gap: 18px; }
  .tile-art { aspect-ratio: 4 / 3; }
  .tok-logo.xxl { width: 64px; height: 64px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- right-to-left (Arabic) ---------- */
/* tickers, names, addresses and numbers keep their own left-to-right order ($CROIS, 0x…) */
[dir="rtl"] [data-no-i18n]:not(.lang-grid):not(.lang-menu):not(.brand-word),
[dir="rtl"] .mono, [dir="rtl"] .addr, [dir="rtl"] .tok-name { direction: ltr; unicode-bidi: isolate; }
[dir="rtl"] .site-menu { right: auto; left: max(16px, calc((100vw - 1240px) / 2 + 20px)); }
[dir="rtl"] .toast-stack { right: auto; left: 20px; }
@media (max-width: 720px) {
  [dir="rtl"] .site-menu { left: 0; right: auto; border-radius: 0 22px 22px 0; transform: translateX(-100%); }
  [dir="rtl"] .menu-open .site-menu { transform: none; }
}
/* longer nav labels in other languages: the network stays visible in the banner and the menu */
html:not([lang="en"]) .chain-pill.desktop-only { display: none !important; }
[dir="rtl"] .up, [dir="rtl"] .down, [dir="rtl"] .chart-box, [dir="rtl"] .tk-price-v, [dir="rtl"] .hero-points b { direction: ltr; unicode-bidi: isolate; }
@media (max-width: 1280px) {
  /* other languages: the header search folds to an icon on smaller desktops so the nav still fits */
  html:not([lang="en"]) .header-search { flex: 0 0 auto; width: 38px; padding: 0; justify-content: center; margin-left: auto; }
  html:not([lang="en"]) .header-search .hs-text, html:not([lang="en"]) .header-search .search-kbd { display: none; }
}

/* ==========================================================================
   Degen neon (25 Oct 2026): near-black kitchen, neon ember accents, glowing CTAs, trading-card tiles.
   The heavy glow lives in the dark theme; the light theme keeps a softer version.
   ========================================================================== */
:root, :root[data-theme="dark"] {
  --bg: #070405;
  --bg-2: #0d0708;
  --surface: rgba(255, 140, 70, 0.04);
  --surface-2: rgba(255, 140, 70, 0.075);
  --surface-3: rgba(255, 140, 70, 0.12);
  --surface-solid: #100909;
  --surface-raised: #170d0b;
  --border: rgba(255, 150, 80, 0.14);
  --border-strong: rgba(255, 150, 80, 0.32);
  --neon-glow: 0 0 18px rgba(255, 94, 26, 0.55), 0 0 42px rgba(255, 94, 26, 0.25);
  --grad: linear-gradient(135deg, #ff3d1a 0%, #ff7a1a 45%, #ffc21a 100%);
  --grad-text: linear-gradient(100deg, #ffe066 0%, #ffb21a 35%, #ff6a1a 65%, #ff3d6e 100%);
  --glow-1: rgba(255, 70, 20, 0.22);
  --glow-2: rgba(255, 190, 30, 0.12);
  --grid-line: rgba(255, 120, 60, 0.05);
}
/* neon haze across the top of every page */
:root:not([data-theme="light"]) body::before {
  background:
    radial-gradient(1100px 500px at 50% -180px, rgba(255, 80, 20, 0.28), transparent 70%),
    radial-gradient(700px 480px at 100% 10%, rgba(255, 45, 110, 0.08), transparent 60%),
    radial-gradient(700px 480px at 0% 20%, rgba(255, 190, 30, 0.08), transparent 60%),
    var(--bg);
}
:root:not([data-theme="light"]) .site-header { background: #070405; border-bottom-color: transparent; }
.site-header::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; pointer-events: none; background: linear-gradient(90deg, transparent, rgba(255, 94, 26, 0.7), rgba(255, 194, 26, 0.7), transparent); opacity: 0.6; }

/* headlines glow; gradient text shimmers slowly */
:root:not([data-theme="light"]) h1 { text-shadow: 0 0 40px rgba(255, 110, 40, 0.18); }
.eyebrow { padding: 6px 12px; border-radius: 999px; border: 1px solid rgba(255, 140, 60, 0.35); background: rgba(255, 94, 26, 0.08); }
:root:not([data-theme="light"]) .section-head h2 { text-shadow: 0 0 30px rgba(255, 110, 40, 0.2); }

/* buttons: the primary action glows and breathes */
:root:not([data-theme="light"]) .btn-primary { box-shadow: 0 0 0 1px rgba(255, 220, 140, 0.35) inset, var(--neon-glow); }
:root:not([data-theme="light"]) .btn:not(.btn-primary):not(.btn-buy):not(.btn-sell):hover { border-color: rgba(255, 140, 60, 0.6); box-shadow: 0 0 16px rgba(255, 94, 26, 0.25); }

/* hero: retro neon floor behind the oven (static) */
.hero { position: relative; overflow: hidden; }
.hero > .container { position: relative; z-index: 1; }
.hero-floor {
  position: absolute; left: -20%; right: -20%; bottom: -6%; height: 52%; pointer-events: none;
  background:
    repeating-linear-gradient(90deg, rgba(255, 94, 26, 0.45) 0 1px, transparent 1px 64px),
    repeating-linear-gradient(0deg, rgba(255, 94, 26, 0.45) 0 1px, transparent 1px 44px);
  transform: perspective(420px) rotateX(68deg); transform-origin: 50% 100%;
  mask-image: linear-gradient(to top, #000 10%, transparent 85%); -webkit-mask-image: linear-gradient(to top, #000 10%, transparent 85%);
  opacity: 0.7;
}
:root[data-theme="light"] .hero-floor { opacity: 0.22; }
:root:not([data-theme="light"]) .hero-glow { background: radial-gradient(closest-side, rgba(255, 140, 30, 0.55), rgba(255, 60, 20, 0.2) 60%, transparent 78%); }
:root:not([data-theme="light"]) .hero-oven { filter: drop-shadow(0 0 40px rgba(255, 120, 30, 0.35)) drop-shadow(0 30px 40px rgba(0, 0, 0, 0.6)); }
:root:not([data-theme="light"]) .hero-card { border-color: rgba(255, 140, 60, 0.45); box-shadow: 0 0 30px rgba(255, 94, 26, 0.25), 0 18px 44px rgba(0, 0, 0, 0.6); }
.hero-points span { filter: drop-shadow(0 0 14px rgba(255, 120, 30, 0.4)); }

/* stats: neon numbers */
.stat b { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
:root:not([data-theme="light"]) .stat-strip { border-color: rgba(255, 140, 60, 0.28); box-shadow: 0 0 40px rgba(255, 94, 26, 0.08); }

/* live feed: a neon marquee */
:root:not([data-theme="light"]) .feed { background: linear-gradient(90deg, rgba(255, 94, 26, 0.08), rgba(255, 194, 26, 0.04)); border-color: rgba(255, 140, 60, 0.3); }
:root:not([data-theme="light"]) .feed-label { color: #ffd04a; text-shadow: 0 0 10px rgba(255, 180, 40, 0.8); background: #0d0708; }

/* tiles: trading cards with a neon edge */
.tile {
  border: 1.5px solid transparent;
  background: linear-gradient(var(--surface-solid), var(--surface-solid)) padding-box,
    linear-gradient(150deg, rgba(255, 110, 40, 0.55), rgba(255, 194, 26, 0.18) 38%, rgba(255, 255, 255, 0.05) 70%, rgba(255, 60, 110, 0.25)) border-box;
}
.tile:hover {
  transform: translateY(-6px) scale(1.015); border-color: transparent;
  background: linear-gradient(var(--surface-solid), var(--surface-solid)) padding-box, var(--grad) border-box;
  box-shadow: 0 0 0 1px rgba(255, 140, 60, 0.3), 0 0 34px rgba(255, 94, 26, 0.35), 0 20px 50px rgba(0, 0, 0, 0.55);
}
:root[data-theme="light"] .tile { background: linear-gradient(#fff, #fff) padding-box, linear-gradient(150deg, rgba(232, 90, 18, 0.45), rgba(232, 90, 18, 0.08)) border-box; }
:root[data-theme="light"] .tile:hover { background: linear-gradient(#fff, #fff) padding-box, var(--grad) border-box; box-shadow: 0 16px 40px rgba(232, 90, 18, 0.2); }
.tile-art::before { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, var(--surface-solid), transparent 45%); pointer-events: none; }
:root[data-theme="light"] .tile-art::before { background: linear-gradient(to top, #fff, transparent 45%); }
.tile-art .tok-logo { position: relative; transition: transform 0.25s; }
.tile:hover .tile-art .tok-logo { transform: scale(1.08) rotate(-3deg); }
.tile-corner { font-family: var(--font-display); background: rgba(10, 5, 5, 0.75); border: 1px solid rgba(255, 150, 60, 0.4); color: #ffd04a; }
.tile-name b { font-family: var(--font-display); font-size: 1.05rem; }
.tile-mcap b { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.tile.st-golden { background: linear-gradient(var(--surface-solid), var(--surface-solid)) padding-box, linear-gradient(135deg, #ffe066, #ffb21a, #ff7a1a) border-box; box-shadow: 0 0 26px rgba(255, 190, 30, 0.3); }

/* cards: neon edge on hover; the King card burns all the time */
:root:not([data-theme="light"]) .card-hover:hover { border-color: rgba(255, 140, 60, 0.5); box-shadow: 0 0 30px rgba(255, 94, 26, 0.18), var(--shadow); }
.king { border: 1.5px solid transparent; background: linear-gradient(140deg, #1a0d08, #120a08 60%) padding-box, conic-gradient(from 200deg, #ff3d1a, #ffc21a, #ff3d6e, #ff7a1a, #ff3d1a) border-box; }
:root[data-theme="light"] .king { background: linear-gradient(140deg, #fff3e6, #fff 60%) padding-box, conic-gradient(from 200deg, #e85a12, #ffb21a, #ff3d6e, #e85a12) border-box; }
.king-crown { color: #ffd04a; text-shadow: 0 0 12px rgba(255, 190, 40, 0.7); }

/* chips and nav pick up a soft glow */
:root:not([data-theme="light"]) .badge.shield { box-shadow: 0 0 10px rgba(108, 200, 255, 0.25); }
:root:not([data-theme="light"]) .badge.degen { box-shadow: 0 0 10px rgba(255, 106, 61, 0.3); }
:root:not([data-theme="light"]) .qchip.active { box-shadow: 0 0 16px rgba(255, 94, 26, 0.3); }
:root:not([data-theme="light"]) .nav a.active { background: rgba(255, 94, 26, 0.14); box-shadow: inset 0 0 0 1px rgba(255, 140, 60, 0.35); }

@media (prefers-reduced-motion: reduce) {
}

/* Degen neon, hero boost: a striped synthwave sun behind the oven, a brighter floor, a bigger headline */
.hero h1 { font-size: clamp(2.6rem, 6vw, 5rem); letter-spacing: -0.035em; }
.hero-art { isolation: isolate; }
.hero-art::before {
  content: ""; position: absolute; z-index: -1; left: 50%; top: 50%; width: min(540px, 118%); aspect-ratio: 1; transform: translate(-50%, -50%);
  border-radius: 50%; background: linear-gradient(180deg, #ffe066 0%, #ffb21a 30%, #ff6a1a 58%, #ff2d6e 100%);
  -webkit-mask-image: linear-gradient(180deg, #000 52%, transparent 52% 56%, #000 56% 63%, transparent 63% 67%, #000 67% 73%, transparent 73% 78%, #000 78% 83%, transparent 83% 89%, #000 89%);
  mask-image: linear-gradient(180deg, #000 52%, transparent 52% 56%, #000 56% 63%, transparent 63% 67%, #000 67% 73%, transparent 73% 78%, #000 78% 83%, transparent 83% 89%, #000 89%);
  opacity: 0.9;
}
:root[data-theme="light"] .hero-art::before { opacity: 0.55; }
.hero-floor { height: 46%; opacity: 1; background:
    repeating-linear-gradient(90deg, rgba(255, 110, 40, 0.75) 0 2px, transparent 2px 72px),
    repeating-linear-gradient(0deg, rgba(255, 60, 110, 0.6) 0 2px, transparent 2px 48px); }
.hero-floor::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, transparent, #ff6a1a, #ffc21a, #ff2d6e, transparent); box-shadow: 0 0 20px #ff6a1a; }
:root:not([data-theme="light"]) .hero-copy h1 { text-shadow: 0 0 1px rgba(255, 220, 180, 0.4), 0 0 50px rgba(255, 110, 40, 0.25); }
.hero-points li { padding-left: 12px; border-left: 2px solid rgba(255, 110, 40, 0.6); }
:root[dir="rtl"] .hero-points li { padding-left: 0; padding-right: 12px; border-left: 0; border-right: 2px solid rgba(255, 110, 40, 0.6); }
@media (max-width: 720px) {
  .hero-art::before { width: min(360px, 100%); }
}

/* ==========================================================================
   Degen UI pack (25 Oct 2026): neon identicons, a glowing trade box, flashing trades, logo-tinted token banner,
   live preview in the bake form, the bake success show and live activity toasts.
   ========================================================================== */
/* identicon avatars */
.tok-avatar { overflow: hidden; background: hsl(var(--h) 45% 9%); box-shadow: 0 0 0 1px hsl(var(--h) 90% 60% / 0.35) inset; }
.tok-avatar svg { width: 100%; height: 100%; display: block; }
:root:not([data-theme="light"]) .tok-avatar.xl, :root:not([data-theme="light"]) .tok-avatar.xxl { box-shadow: 0 0 0 1px hsl(var(--h) 90% 60% / 0.5) inset, 0 0 24px hsl(var(--h) 90% 55% / 0.35); }

/* token banner tinted by the logo */
.tk-head {
  --tk-h: 24; --tk-h2: 50;
  position: relative; isolation: isolate; padding: 20px 22px; border-radius: 22px; border: 1px solid hsl(var(--tk-h) 80% 60% / 0.3);
  background:
    radial-gradient(600px 220px at 0% 0%, hsl(var(--tk-h) 90% 55% / 0.28), transparent 70%),
    radial-gradient(500px 220px at 100% 100%, hsl(var(--tk-h2) 90% 55% / 0.18), transparent 70%),
    var(--surface);
  overflow: hidden;
}
.tk-head::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: 0.5;
  background: repeating-linear-gradient(115deg, hsl(var(--tk-h) 90% 60% / 0.06) 0 2px, transparent 2px 22px); }
:root:not([data-theme="light"]) .tk-head { box-shadow: 0 0 40px hsl(var(--tk-h) 90% 50% / 0.14); }
.tk-head .tk-id .tok-logo { box-shadow: 0 0 0 3px hsl(var(--tk-h) 90% 60% / 0.45), 0 0 26px hsl(var(--tk-h) 90% 55% / 0.45); }
@media (max-width: 720px) { .tk-head { padding: 16px; border-radius: 18px; } }

/* trade box: neon frame that turns red on Sell, big quick-amount pads */
.trade-box { --tb: 145 70% 52%; border: 1.5px solid hsl(var(--tb) / 0.45); box-shadow: 0 0 0 1px hsl(var(--tb) / 0.12) inset, 0 0 34px hsl(var(--tb) / 0.16); transition: border-color 0.25s, box-shadow 0.25s; }
.trade-box.is-sell { --tb: 0 85% 62%; }
:root[data-theme="light"] .trade-box { box-shadow: 0 10px 30px hsl(var(--tb) / 0.14); }
.tb-tabs button { font-size: 1.02rem; padding: 12px; letter-spacing: 0.02em; }
.tb-tabs button.active.buy { background: var(--success); color: #04140b; box-shadow: 0 0 18px rgba(61, 220, 132, 0.45); }
.tb-tabs button.active.sell { background: var(--danger); color: #1a0303; box-shadow: 0 0 18px rgba(255, 100, 100, 0.45); }
.trade-box #tb-amount { font: 700 1.5rem var(--font-display); min-height: 58px; }
.trade-box .preset-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.trade-box .preset-row .btn { min-height: 50px; padding: 4px; flex-direction: column; gap: 0; border-radius: 12px; line-height: 1.1; }
.trade-box .preset-row .btn b { font: 700 0.98rem var(--font-display); }
.trade-box .preset-row .btn small { font-size: 0.66rem; color: var(--text-3); }
.trade-box .preset-row .btn:hover { border-color: hsl(var(--tb) / 0.7); box-shadow: 0 0 14px hsl(var(--tb) / 0.3); }
.trade-box .preset-row .btn:active { transform: scale(0.95); }
.trade-box #tb-btn { min-height: 56px; font-size: 1.08rem; }
:root:not([data-theme="light"]) .trade-box .btn-buy:not(:disabled) { box-shadow: 0 0 22px rgba(61, 220, 132, 0.45); }
:root:not([data-theme="light"]) .trade-box .btn-sell:not(:disabled) { box-shadow: 0 0 22px rgba(255, 100, 100, 0.45); }

/* new trades flash in */
@keyframes row-flash-buy { from { background: rgba(61, 220, 132, 0.32); } to { background: transparent; } }
@keyframes row-flash-sell { from { background: rgba(255, 100, 100, 0.32); } to { background: transparent; } }
.table tr.fresh.buy td { animation: row-flash-buy 2.4s ease-out; }
.table tr.fresh.sell td { animation: row-flash-sell 2.4s ease-out; }
.table tr.fresh td:first-child { box-shadow: inset 3px 0 0 currentColor; }
.table tr.fresh.buy td:first-child { color: var(--success); }
.table tr.fresh.sell td:first-child { color: var(--danger); }

/* bake form: live tile preview */
.pv-tile-wrap { display: grid; gap: 8px; }
.pv-tile-label { display: flex; align-items: center; gap: 8px; font: 600 0.75rem var(--font-sans); color: var(--text-2); text-transform: uppercase; letter-spacing: 0.08em; }
.pv-tile .tile { cursor: default; max-width: 100%; }
.pv-tile .tile:hover { transform: none; }
.pv-tile.bump .tile { animation: pv-bump 0.35s ease-out; }
@keyframes pv-bump { 0% { transform: scale(0.985); } 60% { transform: scale(1.01); } 100% { transform: scale(1); } }
@media (max-width: 1100px) { .pv-tile { max-width: 340px; } }

/* bake success show */
.bake-show { position: fixed; inset: 0; z-index: 1200; display: grid; place-items: center; background: radial-gradient(circle at 50% 55%, rgba(255, 110, 30, 0.35), rgba(5, 2, 2, 0.88) 60%); animation: bs-in 0.3s ease-out; cursor: pointer; }
.bake-show.out { opacity: 0; transition: opacity 0.4s; }
@keyframes bs-in { from { opacity: 0; } }
.bs-stage { position: relative; width: 260px; height: 260px; }
.bs-oven { position: absolute; left: 30px; top: 60px; width: 200px; height: 170px; border-radius: 22px; background: linear-gradient(160deg, #ffd34d, #f5a300 60%, #c97800); box-shadow: 0 0 60px rgba(255, 150, 30, 0.6), inset 0 -8px 0 rgba(0, 0, 0, 0.15); perspective: 500px; animation: bs-shake 0.5s ease-in-out 0.2s 2; }
.bs-top { position: absolute; left: 0; right: 0; top: 12px; display: flex; justify-content: center; gap: 12px; }
.bs-top span { width: 14px; height: 14px; border-radius: 50%; background: #3a2208; box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.25); }
.bs-cavity { position: absolute; left: 18px; right: 18px; top: 40px; bottom: 16px; border-radius: 12px; background: #2a0d04; overflow: hidden; }
.bs-heat { position: absolute; inset: 0; background: radial-gradient(circle at 50% 100%, #ffcf4a, #ff5a1a 45%, transparent 75%); animation: bs-heat 0.6s ease-in-out infinite alternate; }
@keyframes bs-heat { from { opacity: 0.7; } to { opacity: 1; } }
.bs-door { position: absolute; left: 18px; right: 18px; top: 40px; bottom: 16px; border-radius: 12px; background: linear-gradient(160deg, #ffe07a, #e89a00); transform-origin: 50% 100%; animation: bs-door 0.6s cubic-bezier(0.3, 1.4, 0.6, 1) 1.1s forwards; box-shadow: inset 0 0 0 3px rgba(0, 0, 0, 0.15); }
.bs-window { position: absolute; left: 16px; right: 16px; top: 16px; bottom: 26px; border-radius: 8px; background: radial-gradient(circle at 50% 80%, #ff9a2a, #6a1c04); box-shadow: inset 0 0 18px rgba(0, 0, 0, 0.5); }
.bs-handle { position: absolute; left: 30%; right: 30%; bottom: 9px; height: 7px; border-radius: 4px; background: #3a2208; }
@keyframes bs-door { to { transform: rotateX(-100deg); } }
@keyframes bs-shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-4px) rotate(-1deg); } 75% { transform: translateX(4px) rotate(1deg); } }
.bs-token { position: absolute; left: 50%; top: 150px; display: grid; justify-items: center; gap: 8px; transform: translate(-50%, 0) scale(0.2); opacity: 0; animation: bs-pop 0.9s cubic-bezier(0.2, 1.6, 0.5, 1) 1.45s forwards; z-index: 2; }
.bs-token .tok-logo { box-shadow: 0 0 0 4px #ffcf4a, 0 0 50px rgba(255, 190, 40, 0.9); }
.bs-token b { font: 800 1.5rem var(--font-display); color: #fff; text-shadow: 0 0 18px rgba(255, 150, 30, 0.9); white-space: nowrap; }
@keyframes bs-pop { to { transform: translate(-50%, -170px) scale(1.25); opacity: 1; } }
.bs-burst { position: absolute; left: 50%; top: 40%; z-index: 1; }
.bs-burst i { position: absolute; width: 9px; height: 14px; border-radius: 2px; background: var(--c); opacity: 0; animation: bs-bit 1.6s cubic-bezier(0.1, 0.8, 0.3, 1) calc(1.55s + var(--d)) forwards; }
.bs-burst i.cb-flame { width: auto; height: auto; background: none; font-size: 1.4rem; font-style: normal; }
@keyframes bs-bit { 0% { transform: translate(0, 0) rotate(0); opacity: 1; } 80% { opacity: 1; } 100% { transform: translate(var(--dx), calc(var(--dy) + 140px)) rotate(var(--r)); opacity: 0; } }

/* live activity pop-ups and the tile shake */
.act-stack { position: fixed; left: 18px; bottom: 18px; z-index: 110; display: flex; flex-direction: column; gap: 8px; width: min(320px, calc(100vw - 36px)); pointer-events: none; }
[dir="rtl"] .act-stack { left: auto; right: 18px; }
.act-pop { position: relative; pointer-events: auto; display: flex; align-items: center; border-radius: 16px; background: var(--surface-raised); border: 1px solid var(--border-strong); box-shadow: var(--shadow); animation: act-in 0.45s cubic-bezier(0.2, 1.4, 0.5, 1); overflow: hidden; }
.act-pop::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--success); }
.act-pop.sell::before { background: var(--danger); }
:root:not([data-theme="light"]) .act-pop.buy { box-shadow: 0 0 24px rgba(61, 220, 132, 0.22), var(--shadow); }
:root:not([data-theme="light"]) .act-pop.sell { box-shadow: 0 0 24px rgba(255, 100, 100, 0.2), var(--shadow); }
.act-pop.out { opacity: 0; transform: translateY(8px); transition: 0.35s; }
.act-body { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; padding: 10px 6px 10px 14px; color: var(--text); text-decoration: none; }
.act-text { display: grid; gap: 2px; min-width: 0; font-size: 0.82rem; }
.act-line { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act-sub { display: flex; align-items: center; gap: 6px; font-size: 0.78rem; }
.act-sub .side { font: 700 0.62rem var(--font-sans); padding: 2px 6px; border-radius: 5px; }
.act-x { flex: none; align-self: flex-start; border: 0; background: transparent; color: var(--text-3); cursor: pointer; padding: 8px 10px; font-size: 0.8rem; }
.act-x:hover { color: var(--text); }
@keyframes act-in { from { opacity: 0; transform: translateX(-30px) scale(0.95); } }
[dir="rtl"] .act-pop::before { inset: 0 0 0 auto; }
@media (max-width: 960px) {
  .act-stack { bottom: calc(var(--tabbar-h, 64px) + 14px + env(safe-area-inset-bottom)); left: 12px; width: min(300px, calc(100vw - 24px)); }
  [dir="rtl"] .act-stack { right: 12px; }
}
@keyframes just-traded { 0%, 100% { transform: translate(0, 0) rotate(0); } 15% { transform: translate(-3px, 0) rotate(-1.2deg); } 30% { transform: translate(3px, -2px) rotate(1.2deg); } 45% { transform: translate(-2px, 0) rotate(-0.6deg); } 60% { transform: translate(2px, 0) rotate(0.6deg); } }
.just-traded { animation: just-traded 0.6s ease-in-out; }
.tile.just-traded.buy { box-shadow: 0 0 0 2px var(--success), 0 0 30px rgba(61, 220, 132, 0.45); }
.tile.just-traded.sell { box-shadow: 0 0 0 2px var(--danger), 0 0 30px rgba(255, 100, 100, 0.4); }
.table tr.just-traded.buy td { animation: row-flash-buy 1.4s ease-out; }
.table tr.just-traded.sell td { animation: row-flash-sell 1.4s ease-out; }
.table tr.just-traded { animation: none; }
@media (prefers-reduced-motion: reduce) {
  .act-pop, .just-traded, .pv-tile.bump .tile { animation: none; }
  .trade-box .preset-row .btn:active { transform: none; }
}
.trade-box .tb-out { min-height: 22px; margin: 10px 0; }

/* ==========================================================================
   UX polish (25 Oct 2026): readable colours (WCAG AA) and finger-sized controls on phones
   ========================================================================== */
:root, :root[data-theme="dark"] { --text-3: #a28d7a; }
:root[data-theme="light"] {
  --text-3: #7a5e4b;
  --primary-2: #a83f08;
  --success: #0b7f45;
  --danger: #b92a2a;
  --info: #1468a6;
  --shield: #1468a6;
  --reward: #0b7f45;
  --burn: #a8500a;
  --degen: #b53a14;
}
:root[data-theme="light"] .eyebrow, :root[data-theme="light"] .feed-label { color: #a83f08; }
:root[data-theme="light"] .strip-temp, :root[data-theme="light"] .thermo b, :root[data-theme="light"] .thermo-temp { color: color-mix(in srgb, var(--th) 40%, #2a160a); }

@media (max-width: 720px) {
  .seg-sm button { min-height: 36px; min-width: 40px; padding: 6px 10px; font-size: 0.82rem; }
  .icon-btn.sm { width: 34px; height: 34px; }
  .star-btn { width: 38px; height: 38px; }
  .star-btn.sm { width: 34px; height: 34px; }
  .link-btn { min-height: 36px; padding-inline: 8px; }
  .site-footer a, footer a { display: inline-block; padding-block: 8px; }
  .feed-item { min-height: 34px; }
  .tabs button { min-height: 42px; }
  .chip, .qchip { min-height: 38px; }
}

/* term hints (ⓘ) */
.hint-i { display: inline-grid; place-items: center; width: 16px; height: 16px; margin-inline-start: 5px; padding: 0; vertical-align: middle; border-radius: 50%; border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text-2); font: italic 700 10px/1 Georgia, serif; text-transform: none; letter-spacing: 0; cursor: help; position: relative; }
.hint-i::after { content: ""; position: absolute; inset: -12px; } /* finger-sized hit area */
.hint-i:hover, .hint-i[aria-expanded="true"] { color: var(--primary); border-color: var(--primary); }
.hint-pop { position: absolute; z-index: 1300; width: min(280px, calc(100vw - 24px)); display: grid; gap: 4px; padding: 12px 14px; border-radius: 12px; background: var(--surface-raised); border: 1px solid var(--border-strong); box-shadow: var(--shadow); font-size: 0.82rem; line-height: 1.45; color: var(--text-2); animation: hint-in 0.15s ease-out; }
.hint-pop b { color: var(--text); font-size: 0.86rem; }
@keyframes hint-in { from { opacity: 0; transform: translateY(-4px); } }

/* token page: safety line */
.safe-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: -4px 0 16px; padding: 10px 14px; border-radius: 14px; border: 1px solid rgba(61, 220, 132, 0.28); background: var(--success-bg); }
.safe-strip.has-warn { border-color: rgba(255, 194, 74, 0.35); background: var(--warning-bg); }
.safe-title { font: 700 0.82rem var(--font-display); margin-inline-end: 4px; }
.safe-chip { display: inline-flex; align-items: center; gap: 2px; padding: 4px 9px; border-radius: 999px; font-size: 0.78rem; font-weight: 600; background: var(--surface-solid); border: 1px solid var(--border); }
.safe-chip.ok { color: var(--success); }
.safe-chip.warn { color: var(--warning); border-color: rgba(255, 194, 74, 0.45); }
#safe-more { margin-inline-start: auto; }
@media (max-width: 720px) {
  .safe-strip { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-inline: -16px; border-radius: 0; border-inline: 0; padding-inline: 16px; }
  .safe-strip::-webkit-scrollbar { display: none; }
  .safe-chip, .safe-title, #safe-more { flex: none; white-space: nowrap; }
}

/* first-visit guide */
.guide-card { position: relative; display: grid; gap: 10px; margin-bottom: 16px; padding: 16px 44px 16px 18px; border-radius: 16px; border: 1px dashed rgba(255, 150, 60, 0.5); background: linear-gradient(120deg, rgba(255, 110, 30, 0.1), rgba(255, 194, 26, 0.05)); }
.guide-title { font: 700 1rem var(--font-display); }
.guide-steps { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.guide-steps li { display: flex; gap: 10px; align-items: flex-start; font-size: 0.86rem; color: var(--text-2); }
.guide-steps span { flex: none; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--grad); color: #1a0a02; font: 800 0.8rem var(--font-display); }
.guide-x { position: absolute; top: 6px; inset-inline-end: 6px; width: 36px; height: 36px; border: 0; background: transparent; color: var(--text-3); cursor: pointer; border-radius: 50%; }
.guide-x:hover { color: var(--text); background: var(--surface-2); }
@media (max-width: 720px) { .guide-steps { grid-template-columns: 1fr; } }

/* trade box: dollar value of the typed amount */
.tb-usd { min-height: 1.2em; margin-top: 6px; text-align: end; }

/* phone trade sheet */
.sheet-backdrop { position: fixed; inset: 0; z-index: 140; background: rgba(5, 2, 2, 0.6); backdrop-filter: blur(3px); animation: bs-in 0.2s ease-out; }
.trade-box.as-sheet { position: fixed; inset: auto 0 0 0; z-index: 150; margin: 0; max-height: 88vh; overflow-y: auto; border-radius: 22px 22px 0 0; border-bottom: 0; background: var(--surface-solid); padding-bottom: calc(18px + env(safe-area-inset-bottom)); animation: sheet-up 0.28s cubic-bezier(0.2, 1, 0.4, 1); }
@keyframes sheet-up { from { transform: translateY(100%); } }
.sheet-grip { position: relative; display: flex; justify-content: center; margin: -6px 0 10px; }
.sheet-grip span { width: 44px; height: 5px; border-radius: 3px; background: var(--border-strong); margin-top: 2px; }
.sheet-close { position: absolute; inset-inline-end: -6px; top: -10px; width: 38px; height: 38px; border: 0; border-radius: 50%; background: var(--surface-2); color: var(--text-2); cursor: pointer; }
html.sheet-lock, html.sheet-lock body { overflow: hidden; }
@media (prefers-reduced-motion: reduce) { .trade-box.as-sheet, .sheet-backdrop, .hint-pop { animation: none; } }
:root[data-theme="light"] .btn-buy, :root[data-theme="light"] .btn-buy:hover, :root[data-theme="light"] .btn-sell, :root[data-theme="light"] .btn-sell:hover,
:root[data-theme="light"] .tb-tabs button.active.buy, :root[data-theme="light"] .tb-tabs button.active.sell { color: #fff; }
:root[data-theme="light"] { --success: #0a7340; --reward: #0a7340; }
:root[data-theme="light"] .fair-card, :root[data-theme="light"] .bake-strip a { --fb: #0a7340; }
:root[data-theme="light"] .fair-card.fb-mostly, :root[data-theme="light"] .bake-strip a.fb-mostly { --fb: #9a5a00; }
:root[data-theme="light"] .fair-card.fb-care, :root[data-theme="light"] .bake-strip a.fb-care { --fb: #b92a2a; }
:root[data-theme="light"] .fair-checks .ok i { color: #0a7340; }
:root[data-theme="light"] .bake-card .badge.ember { color: #ffb084; }

/* bake form: folded optional sections */
.bake-more { border: 1px solid var(--border); border-radius: 16px; background: var(--surface); }
.bake-more > summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: center; padding: 14px 16px; min-height: 56px; border-radius: 16px; }
.bake-more > summary::-webkit-details-marker { display: none; }
.bake-more > summary::after { content: "＋"; grid-row: 1 / span 2; grid-column: 2; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--surface-2); color: var(--text-2); font-weight: 700; transition: transform 0.2s; }
.bake-more[open] > summary::after { content: "－"; }
.bake-more > summary:hover { background: var(--surface-2); }
.bm-title { font: 700 0.98rem var(--font-display); color: var(--text); }
.bm-sub { font-size: 0.8rem; color: var(--text-3); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bm-body { padding: 4px 16px 18px; }
.bake-more[open] { border-color: var(--border-strong); }

/* creator kitchen (Portfolio → Baked) */
.ck-hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 26px; margin-bottom: 18px; background: radial-gradient(500px 220px at 0% 0%, rgba(255, 110, 30, 0.16), transparent 70%), var(--surface-solid); }
.ck-hero-main { display: grid; gap: 12px; align-content: start; justify-items: start; }
.ck-total { display: grid; gap: 2px; }
.ck-total span { color: var(--text-3); font-size: 0.82rem; }
.ck-total b { font: 800 clamp(2rem, 4vw, 2.8rem) var(--font-display); background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.ck-claim { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; font-size: 0.92rem; }
.ck-earn { display: grid; grid-template-columns: 74px 1fr auto; gap: 10px; align-items: center; font-size: 0.82rem; margin-bottom: 8px; }
.ck-earn-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-2); font-weight: 600; }
.ck-earn-track { height: 10px; border-radius: 6px; background: var(--surface-2); overflow: hidden; }
.ck-earn-track i { display: block; height: 100%; border-radius: 6px; background: var(--grad); }
.ck-earn b { font-variant-numeric: tabular-nums; }
.ck-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr)); gap: 16px; }
.ck-card { display: grid; gap: 12px; align-content: start; }
.ck-card-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.ck-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.ck-metrics .metric-inline { display: flex; flex-direction: column; font-size: 0.88rem; min-width: 0; }
.ck-metrics .metric-inline span { color: var(--text-3); font-size: 0.72rem; }
.ck-metrics .metric-inline b { font-variant-numeric: tabular-nums; }
.ck-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.ck-list { display: grid; gap: 4px; padding: 12px; border-radius: 14px; background: var(--surface); border: 1px dashed var(--border-strong); }
.ck-head { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.ck-bar { flex: 1; height: 6px; border-radius: 4px; background: var(--surface-3); overflow: hidden; }
.ck-bar i { display: block; height: 100%; background: var(--success); border-radius: 4px; }
.ck-item { display: flex; align-items: center; gap: 10px; min-height: 38px; padding: 4px 8px; border-radius: 10px; color: var(--text); font-size: 0.88rem; text-decoration: none; }
.ck-item:hover { background: var(--surface-2); }
.ck-item.done { color: var(--text-3); text-decoration: line-through; text-decoration-color: var(--border-strong); }
.ck-box { flex: none; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 7px; border: 1.5px solid var(--border-strong); font-size: 0.8rem; font-weight: 800; }
.ck-item.done .ck-box { background: var(--success); border-color: var(--success); color: #fff; }
.ck-go { margin-inline-start: auto; color: var(--primary); }
@media (max-width: 820px) {
  .ck-hero { grid-template-columns: 1fr; }
  .ck-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* WalletConnect pairing view */
.wc-view { display: grid; gap: 12px; }
.wc-qr { justify-self: center; width: min(260px, 100%); padding: 10px; border-radius: 16px; background: #fff; box-shadow: 0 0 0 1px var(--border); }
.wc-qr svg { display: block; width: 100%; height: auto; }

/* lite mode (theme-init.js): slow phones, Save-Data or reduced motion. No glass blur, no looping decoration. */
html.lite *, html.lite *::before, html.lite *::after { backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
html.lite .hero-floor { display: none; }
html.lite .gradient-text, html.lite .hero-cta .btn-primary, html.lite .header-bake, html.lite .cta .btn-primary,
html.lite .king, html.lite .hero-oven, html.lite .brand-logo::after, html.lite .tile.st-golden .tile-art::after, html.lite .bs-heat, html.lite .hero-glow { animation: none !important; }
html.lite .site-header { background: var(--bg); }
html.lite .tile:hover { transform: none; }
html.lite .feed-run { animation-duration: 140s; }

/* smooth loading: keep the space of things JavaScript draws later, so nothing jumps (CLS) */
#site-header:empty { display: block; height: var(--header-h); margin-bottom: var(--envbar-reserve, 0px); border-bottom: 1px solid var(--border); }
main.page { min-height: calc(100vh - var(--header-h)); min-height: calc(100svh - var(--header-h)); }
.recipe-cards:empty { min-height: 128px; }
#pv-tile:empty { min-height: 400px; }
@media (max-width: 720px) {
  .recipe-cards:empty { min-height: 260px; }
}

/* page-to-page transitions (cross-document View Transitions; browsers without support just navigate) */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: vt-out 0.16s ease-in both; }
::view-transition-new(root) { animation: vt-in 0.22s ease-out both; }
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; transform: translateY(6px); } }
.site-header { view-transition-name: site-header; }
.tabbar { view-transition-name: tabbar; }
::view-transition-group(site-header), ::view-transition-group(tabbar) { animation-duration: 0s; }
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
}
html.lite ::view-transition-old(root), html.lite ::view-transition-new(root) { animation-duration: 0.1s; }
html.booting::after, .nav-progress { position: fixed; z-index: 2000; top: 0; left: 0; height: 3px; width: 100%; pointer-events: none; background: var(--grad); transform-origin: 0 50%; box-shadow: 0 0 12px rgba(255, 110, 30, 0.8); animation: nav-progress 8s cubic-bezier(0.1, 0.7, 0.2, 1) forwards; }
@keyframes nav-progress { 0% { transform: scaleX(0); } 10% { transform: scaleX(0.35); } 100% { transform: scaleX(0.92); } }
[dir="rtl"] .nav-progress { transform-origin: 100% 50%; }

/* tiles fade in when a list is drawn or re-filtered */
.tile-grid > *, .strip > .tile, .ck-grid > * { animation: tile-in 0.28s ease-out both; }
@keyframes tile-in { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .nav-progress { animation: none; transform: scaleX(0.6); } .tile-grid > *, .strip > .tile, .ck-grid > * { animation: none; } }
html.lite .tile-grid > *, html.lite .strip > .tile, html.lite .ck-grid > * { animation: none; }
html.booting::after { content: ""; animation-duration: 6s; }
html.booting .nav-progress { display: none; }

/* referrals: hidden while the factory pays no referrer (ui.js toggles html.no-referrals) */
html.no-referrals [data-referral], html:not(.no-referrals) [data-no-referral] { display: none !important; }
