/* ===== Design tokens ===== */
:root {
  --bg: #f7f7f5;
  --bg-2: #efefec;
  --surface: #ffffff;
  --surface-2: #f6f6f3;
  --surface-3: #ececE8;
  --ink: #0b0d0e;
  --ink-2: #33383d;
  --muted: #6b7178;
  --faint: #9aa0a6;
  --line: rgba(11, 13, 14, 0.08);
  --line-2: rgba(11, 13, 14, 0.14);
  --accent: #0a8f68;
  --accent-2: #0ea5a4;
  --accent-ink: #ffffff;
  --accent-soft: rgba(10, 143, 104, 0.09);
  --accent-line: rgba(10, 143, 104, 0.28);
  --grad: linear-gradient(135deg, #0a8f68 0%, #0ea5a4 100%);
  --warn: #9a5b00;
  --warn-soft: rgba(245, 166, 35, 0.12);
  --warn-line: rgba(214, 140, 20, 0.35);
  --bad: #c0352b;
  --bad-soft: rgba(224, 72, 58, 0.09);
  --hi: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  --shadow-sm: 0 1px 2px rgba(15, 20, 25, 0.05);
  --shadow: 0 1px 2px rgba(15, 20, 25, 0.04), 0 4px 12px rgba(15, 20, 25, 0.05), 0 16px 40px -12px rgba(15, 20, 25, 0.12);
  --shadow-lg: 0 2px 4px rgba(15, 20, 25, 0.04), 0 24px 64px -16px rgba(15, 20, 25, 0.22);
  --grid: rgba(11, 13, 14, 0.045);
  --glow: rgba(14, 165, 164, 0.16);
  --r-xl: 28px; --r-lg: 20px; --r-md: 14px; --r-sm: 10px;
  --font: "SF Pro Display", -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --mono: "SF Mono", ui-monospace, "JetBrains Mono", Menlo, Consolas, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #08090a; --bg-2: #0d0f10; --surface: #121416; --surface-2: #17191c; --surface-3: #1e2124;
    --ink: #f2f4f5; --ink-2: #c9ced3; --muted: #8b9299; --faint: #5f666d;
    --line: rgba(255, 255, 255, 0.07); --line-2: rgba(255, 255, 255, 0.13);
    --accent: #34d399; --accent-2: #2dd4bf; --accent-ink: #04140e; --accent-soft: rgba(52, 211, 153, 0.1); --accent-line: rgba(52, 211, 153, 0.3);
    --grad: linear-gradient(135deg, #34d399 0%, #2dd4bf 100%);
    --warn: #fbbf4a; --warn-soft: rgba(251, 191, 74, 0.1); --warn-line: rgba(251, 191, 74, 0.32);
    --bad: #ff7b6e; --bad-soft: rgba(255, 123, 110, 0.1);
    --hi: inset 0 1px 0 rgba(255, 255, 255, 0.05);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 32px -8px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 24px 80px -12px rgba(0, 0, 0, 0.7);
    --grid: rgba(255, 255, 255, 0.035); --glow: rgba(45, 212, 191, 0.13);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #08090a; --bg-2: #0d0f10; --surface: #121416; --surface-2: #17191c; --surface-3: #1e2124;
  --ink: #f2f4f5; --ink-2: #c9ced3; --muted: #8b9299; --faint: #5f666d;
  --line: rgba(255, 255, 255, 0.07); --line-2: rgba(255, 255, 255, 0.13);
  --accent: #34d399; --accent-2: #2dd4bf; --accent-ink: #04140e; --accent-soft: rgba(52, 211, 153, 0.1); --accent-line: rgba(52, 211, 153, 0.3);
  --grad: linear-gradient(135deg, #34d399 0%, #2dd4bf 100%);
  --warn: #fbbf4a; --warn-soft: rgba(251, 191, 74, 0.1); --warn-line: rgba(251, 191, 74, 0.32);
  --bad: #ff7b6e; --bad-soft: rgba(255, 123, 110, 0.1);
  --hi: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 32px -8px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 24px 80px -12px rgba(0, 0, 0, 0.7);
  --grid: rgba(255, 255, 255, 0.035); --glow: rgba(45, 212, 191, 0.13);
  color-scheme: dark;
}

/* ===== Base ===== */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); font-family: var(--font); line-height: 1.55; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; font-feature-settings: "ss01", "cv11"; }
a { color: var(--accent); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
.i { width: 1em; height: 1em; flex: none; vertical-align: -0.14em; }
kbd { font-family: var(--mono); font-size: 10.5px; min-width: 18px; text-align: center; padding: 1px 5px; border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 5px; color: var(--muted); background: var(--surface); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 99; background: var(--surface); padding: 8px 12px; border-radius: 8px; }
.muted { color: var(--muted); }
.small { font-size: 0.85em; }
.mono { font-family: var(--mono); }
.label { font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* ===== Buttons & chips ===== */
.btn { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); font-size: 14px; font-weight: 550; box-shadow: var(--shadow-sm), var(--hi); transition: transform .15s ease, border-color .15s ease, background .15s ease; white-space: nowrap; }
.btn:hover { border-color: var(--accent-line); }
.btn:active { transform: scale(0.98); }
.btn.primary { background: var(--ink); color: var(--bg); border-color: transparent; }
.btn.primary:hover { opacity: 0.92; }
.btn.accent { background: var(--grad); color: var(--accent-ink); border-color: transparent; }
.btn.lg { height: 48px; padding: 0 22px; font-size: 16px; }
.btn.sm { height: 30px; padding: 0 12px; font-size: 13px; }
.chip { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px 0 3px; border-radius: 999px; font-size: 11.5px; line-height: 1; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-2); white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; transition: border-color .15s, background .15s; }
.chip b { font-family: var(--mono); font-weight: 600; font-size: 10px; color: var(--accent); background: var(--accent-soft); border-radius: 999px; padding: 3px 6px; }
.chip em { font-style: normal; color: var(--muted); font-family: var(--mono); font-size: 10.5px; }
a.chip:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.chip.ghost { color: var(--faint); padding-left: 8px; }

/* ===== Deck chrome ===== */
.deck { overflow: hidden; height: 100vh; }
.deck::before { content: ""; position: fixed; inset: 0; background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px); background-size: 48px 48px; mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 85%); pointer-events: none; }
.deck::after { content: ""; position: fixed; width: 900px; height: 600px; right: -200px; top: -240px; background: radial-gradient(closest-side, var(--glow), transparent); pointer-events: none; filter: blur(10px); }
.toolbar { position: fixed; top: 14px; left: 16px; right: 16px; height: 48px; display: flex; align-items: center; justify-content: space-between; z-index: 10; pointer-events: none; }
.toolbar > * { pointer-events: auto; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 600; font-size: 14px; letter-spacing: -0.01em; padding: 6px 14px 6px 6px; border-radius: 999px; background: color-mix(in srgb, var(--surface) 72%, transparent); border: 1px solid var(--line); backdrop-filter: blur(16px) saturate(1.4); box-shadow: var(--shadow-sm); }
.brand small { display: block; font-weight: 400; color: var(--muted); font-size: 11px; margin-top: -2px; }
.brand-mark { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 999px; background: var(--grad); color: var(--accent-ink); font-size: 16px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.2); }
.toolbar nav { display: flex; gap: 2px; padding: 4px; border-radius: 999px; background: color-mix(in srgb, var(--surface) 72%, transparent); border: 1px solid var(--line); backdrop-filter: blur(16px) saturate(1.4); box-shadow: var(--shadow-sm); }
.toolbar nav button, .tb-link { display: inline-flex; align-items: center; gap: 6px; height: 32px; border: 0; background: transparent; border-radius: 999px; padding: 0 12px; font-size: 13px; color: var(--ink-2); }
.toolbar nav button:hover, .tb-link:hover { background: var(--surface-2); color: var(--ink); }
.tb-link.accent { background: var(--ink); color: var(--bg); }
.tb-link.accent:hover { background: var(--ink); opacity: .9; color: var(--bg); }
.controls { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 10; display: flex; align-items: center; gap: 4px; padding: 4px; border-radius: 999px; background: color-mix(in srgb, var(--surface) 78%, transparent); border: 1px solid var(--line); backdrop-filter: blur(16px) saturate(1.4); box-shadow: var(--shadow); }
.controls button { display: inline-grid; place-items: center; height: 34px; min-width: 34px; padding: 0 10px; border: 0; border-radius: 999px; background: transparent; color: var(--ink-2); font-size: 13px; }
.controls button:hover { background: var(--surface-2); color: var(--ink); }
#page { font-family: var(--mono); font-size: 12px; color: var(--muted); min-width: 64px; }
.chapter { font-size: 12px; color: var(--muted); padding: 0 10px 0 12px; border-right: 1px solid var(--line); white-space: nowrap; }
.tip { position: fixed; right: 20px; bottom: 26px; font-size: 11.5px; color: var(--faint); display: flex; gap: 6px; align-items: center; }
#progress { position: fixed; left: 0; right: 0; top: 0; height: 2px; z-index: 11; }
#progress span { display: block; height: 100%; background: var(--grad); transition: width .4s cubic-bezier(.2,.8,.2,1); }

/* ===== Stage ===== */
#viewport { position: fixed; inset: 76px 0 70px 0; display: grid; place-items: center; padding: 0 32px; }
.slide { position: relative; width: min(100%, calc((100vh - 160px) * 16 / 9)); aspect-ratio: 16 / 9; display: flex; flex-direction: column; container-type: inline-size; outline: none; padding: 2.2cqi 3.2cqi; animation: enter .45s cubic-bezier(.2,.8,.2,1); }
@keyframes enter { from { opacity: 0; transform: translateY(8px); filter: blur(4px); } to { opacity: 1; transform: none; filter: none; } }
.slide-head { margin-bottom: 2.6cqi; }
.chapter-tag { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 1cqi; font-family: var(--mono); font-size: max(11px, 1.02cqi); letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.chapter-tag::before { content: ""; width: 18px; height: 1px; background: currentColor; }
.slide h2 { margin: 0; font-size: max(24px, 4.1cqi); line-height: 1.1; letter-spacing: -0.035em; font-weight: 700; }
.slide-body { flex: 1; min-height: 0; display: flex; flex-direction: column; justify-content: center; font-size: max(14px, 1.7cqi); }
.slide h3 { margin: 0 0 .4em; font-size: 1.2em; letter-spacing: -0.02em; }
.big { font-size: 2.3em; line-height: 1.15; font-weight: 700; letter-spacing: -0.03em; margin: 0 0 .35em; }
.lead { font-size: 1.45em; color: var(--ink-2); margin: 0 0 .4em; letter-spacing: -0.015em; }
.note { color: var(--muted); font-size: .88em; margin: 1.6em 0 0; display: flex; gap: .5em; align-items: center; }
.note.center { justify-content: center; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 3.4cqi; align-items: center; }
.split.wide-left { grid-template-columns: 1.3fr 1fr; }
.trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4cqi; }

/* Surface card */
.card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1.3em 1.4em; box-shadow: var(--shadow-sm), var(--hi); }
.card p { margin: 0; color: var(--muted); }
.card h3 { margin-top: .7em; }
.ico { display: inline-grid; place-items: center; width: 2.3em; height: 2.3em; border-radius: 12px; background: var(--accent-soft); color: var(--accent); font-size: 1em; box-shadow: inset 0 0 0 1px var(--accent-line); }
.ico .i { width: 1.15em; height: 1.15em; }
.ico.warn { background: var(--warn-soft); color: var(--warn); box-shadow: inset 0 0 0 1px var(--warn-line); }
.ico.bad { background: var(--bad-soft); color: var(--bad); box-shadow: inset 0 0 0 1px rgba(224,72,58,.25); }

/* Cover */
.cover { display: grid; grid-template-columns: 1.15fr 1fr; gap: 4cqi; align-items: center; height: 100%; }
.cover .eyebrow { display: inline-flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: max(11px, 1.05cqi); letter-spacing: .08em; color: var(--muted); padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); margin: 0 0 2.4cqi; }
.cover .eyebrow i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.cover h1 { font-size: max(36px, 6.6cqi); line-height: 1.02; margin: 0 0 .35em; letter-spacing: -0.05em; font-weight: 750; }
.cover .lead { font-size: max(17px, 2.1cqi); color: var(--muted); }
.byline { display: flex; align-items: center; gap: 12px; margin-top: 3.4cqi; }
.byline img { width: max(44px, 4.4cqi); height: max(44px, 4.4cqi); border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--line-2); }
.byline strong { display: block; font-size: 1.05em; letter-spacing: -0.01em; }
.byline span { color: var(--muted); font-size: .85em; }
.hero-visual { position: relative; height: 100%; display: grid; place-items: center; perspective: 1400px; }
.hero-visual .store-card { width: 92%; transform: rotateY(-10deg) rotateX(4deg); box-shadow: var(--shadow-lg); font-size: max(11px, 1.12cqi); }
.float-chip { position: absolute; display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); font-size: max(11px, 1.05cqi); white-space: nowrap; animation: bob 6s ease-in-out infinite; }
.float-chip .i { color: var(--accent); }
.float-chip.warn .i { color: var(--warn); }
.float-chip.a { top: 6%; right: 0; }
.float-chip.b { bottom: 10%; left: -4%; animation-delay: -3s; }
@keyframes bob { 50% { transform: translateY(-6px); } }

/* Pain chat */
.pain { display: grid; grid-template-columns: 1.1fr 1fr; gap: 4.4cqi; align-items: center; }
.chat { display: flex; flex-direction: column; gap: .55em; padding: 1.4em; border-radius: var(--r-xl); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); font-size: .95em; }
.chat-top { display: flex; align-items: center; gap: .6em; padding-bottom: .8em; margin-bottom: .3em; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .85em; }
.chat-top .av { width: 1.9em; height: 1.9em; border-radius: 50%; background: linear-gradient(135deg, #f6c177, #eb6f92); }
.bubble { max-width: 78%; padding: .55em .95em; border-radius: 18px 18px 18px 6px; background: var(--surface-2); border: 1px solid var(--line); animation: enter .4s both; }
.bubble.right { align-self: flex-end; border-radius: 18px 18px 6px 18px; background: var(--ink); color: var(--bg); border-color: transparent; }
.bubble:nth-child(3) { animation-delay: .1s } .bubble:nth-child(4) { animation-delay: .2s } .bubble:nth-child(5) { animation-delay: .3s } .bubble:nth-child(6) { animation-delay: .4s } .bubble:nth-child(7) { animation-delay: .5s }
.stat { font-size: 5.2em; font-weight: 750; letter-spacing: -0.06em; line-height: 1; margin: 0; }
.pain-side p { margin: .3em 0 0; font-size: 1.35em; letter-spacing: -0.02em; }
.pain-side .muted { font-size: 1em; margin-top: 1.2em; }

/* Me */
.me { display: grid; grid-template-columns: auto 1fr; gap: 4.4cqi; align-items: center; }
.portrait { width: 21cqi; height: 21cqi; border-radius: 32px; object-fit: cover; box-shadow: var(--shadow-lg); }
.me h3 { font-size: 2.2em; letter-spacing: -0.04em; margin: 0 0 .15em; }
.apps { display: flex; gap: 1.2cqi; margin-top: 2.4cqi; }
.apps figure { margin: 0; display: flex; gap: .8em; align-items: center; background: var(--surface); border-radius: var(--r-md); padding: .65em 1.1em .65em .65em; border: 1px solid var(--line); box-shadow: var(--shadow-sm), var(--hi); }
.apps img { width: 3em; height: 3em; border-radius: 12px; object-fit: cover; }
.apps figcaption { font-weight: 600; line-height: 1.3; font-size: .95em; }
.apps figcaption span { font-weight: 400; color: var(--muted); font-size: .85em; }

/* ===== Store card (shared by deck, chat, store page) ===== */
.store-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1.1em; box-shadow: var(--shadow), var(--hi); font-size: .86em; display: grid; grid-template-columns: auto 1fr; gap: .1em .9em; text-align: left; }
.sc-photo { width: 3.2em; height: 3.2em; border-radius: 14px; display: grid; place-items: center; font-size: 1.35em; color: #fff; background: radial-gradient(120% 120% at 20% 10%, #c79a6b 0%, #7a4b2a 55%, #3d2416 100%); box-shadow: inset 0 0 0 1px rgba(255,255,255,.15); }
.sc-head { display: flex; flex-direction: column; justify-content: center; min-width: 0; }
.sc-head strong { font-size: 1.12em; letter-spacing: -0.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-head span { color: var(--muted); font-size: .82em; display: flex; gap: .5em; align-items: center; }
.sc-badge { display: inline-flex; align-items: center; gap: 4px; font-size: .9em; color: var(--accent); }
.sc-badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.store-card dl { grid-column: 1 / -1; margin: .9em 0 0; display: grid; gap: 2px; }
.store-card dl > div { display: grid; grid-template-columns: 1.6em 6em 1fr; gap: .2em .5em; padding: .55em .6em; border-radius: 12px; align-items: start; }
.store-card dl > div + div { border-top: 1px solid var(--line); border-radius: 0; }
.store-card dl > div.conflict { background: var(--warn-soft); border-radius: 12px; border-top-color: transparent; box-shadow: inset 0 0 0 1px var(--warn-line); }
.store-card dl > div.conflict + div { border-top-color: transparent; }
.store-card .fi { color: var(--muted); padding-top: .15em; }
.store-card .conflict .fi { color: var(--warn); }
.store-card dt { color: var(--muted); font-size: .92em; padding-top: .05em; }
.store-card dd { margin: 0; display: flex; flex-wrap: wrap; gap: .35em .4em; align-items: center; min-width: 0; }
.store-card .v { color: var(--ink); font-weight: 500; width: 100%; }
.store-card dd.empty { color: var(--bad); font-weight: 500; }
.store-card.after dd.empty { color: var(--faint); font-weight: 400; }
.store-card .alt { width: 100%; color: var(--warn); font-size: .88em; display: flex; flex-wrap: wrap; gap: .3em; align-items: center; }
.store-card .ph { color: var(--faint); }
.store-card.before .sc-photo { filter: grayscale(1) opacity(.5); }
.map-row { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: .6em; margin-top: 1em; }
.map-btn { display: inline-flex; justify-content: center; align-items: center; gap: .45em; height: 2.9em; border-radius: 12px; background: var(--ink); color: var(--bg); font-weight: 600; font-size: .95em; }
.map-btn.alt { background: var(--surface-2); color: var(--ink); border: 1px solid var(--line); }

/* Compare */
.compare { display: grid; grid-template-columns: 1fr auto 1fr; gap: 2.4cqi; align-items: center; }
.compare .arrow { display: grid; place-items: center; width: 3em; height: 3em; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); color: var(--accent); box-shadow: var(--shadow); }
.compare .store-card { font-size: .8em; }
.tag { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 .8em; font-family: var(--mono); font-size: .68em; letter-spacing: .08em; text-transform: uppercase; }
.tag::before { content: ""; width: 7px; height: 7px; border-radius: 50%; }
.tag.bad { color: var(--bad); } .tag.bad::before { background: var(--bad); }
.tag.good { color: var(--accent); } .tag.good::before { background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.steps3 { list-style: none; padding: 0; margin: 2.4cqi 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2cqi; }
.steps3 li { display: flex; align-items: center; gap: .7em; padding: .75em 1em; border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--line); color: var(--muted); font-size: .92em; box-shadow: var(--shadow-sm); }
.steps3 .n { font-family: var(--mono); font-size: .75em; color: var(--accent); }
.steps3 b { color: var(--ink); }

.qs { list-style: none; margin: 0; padding: 0; display: grid; gap: .7em; font-size: 1.08em; }
.qs li { display: flex; align-items: center; gap: .8em; padding: .8em 1em; border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.qs em { margin-left: auto; font-style: normal; color: var(--bad); font-size: .8em; font-family: var(--mono); background: var(--bad-soft); padding: .2em .6em; border-radius: 999px; }

/* Why */
.why { display: grid; gap: 2.4cqi; }
.why .card h3 { font-size: 1.5em; }
.sells { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2cqi; padding: 1.2em; border-radius: var(--r-lg); background: linear-gradient(180deg, var(--accent-soft), transparent); border: 1px solid var(--accent-line); }
.sells .label { grid-column: 1 / -1; color: var(--accent); }
.sell { display: flex; gap: .7em; align-items: flex-start; }
.sell b { display: block; font-size: 1.02em; letter-spacing: -0.01em; }
.sell span { color: var(--muted); font-size: .86em; }

/* Prompt / code */
.prompt-box, .code-box { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow), var(--hi); overflow: hidden; }
.box-top { display: flex; align-items: center; gap: .6em; padding: .7em 1em; border-bottom: 1px solid var(--line); background: var(--surface-2); font-size: .78em; color: var(--muted); }
.box-top .dots { display: flex; gap: 5px; } .box-top .dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-2); }
.prompt-box pre, .code-box pre { margin: 0; padding: 1.1em 1.3em; white-space: pre-wrap; font-family: var(--font); font-size: .95em; line-height: 1.75; }
.code-box pre { font-family: var(--mono); font-size: .8em; line-height: 1.7; }
.code-box .k { color: var(--accent); } .code-box .s { color: var(--warn); }
.copy { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); font-size: 12px; color: var(--ink-2); }
.copy:hover { color: var(--accent); border-color: var(--accent-line); }
.side-tips { display: flex; flex-direction: column; gap: .8em; align-items: flex-start; }
.side-tips .label { color: var(--accent); }
mark { background: var(--accent-soft); color: var(--accent); padding: 0 .25em; border-radius: 6px; box-shadow: inset 0 0 0 1px var(--accent-line); }

/* Check */
.actions { margin: 0; padding: 0; list-style: none; display: grid; gap: 1.1em; }
.actions li { display: grid; grid-template-columns: auto 1fr; column-gap: 1em; align-items: start; }
.actions .ico { grid-row: 1 / 3; }
.actions b { font-size: 1.15em; letter-spacing: -0.01em; }
.actions span { color: var(--muted); }
.sources-preview { background: var(--surface); border-radius: var(--r-lg); border: 1px solid var(--line); box-shadow: var(--shadow), var(--hi); overflow: hidden; font-size: .82em; }
.src-list { list-style: none; margin: 0; padding: .4em; display: grid; gap: 2px; }
.src-list li { display: grid; grid-template-columns: auto 1fr; column-gap: .7em; padding: .6em .7em; border-radius: 10px; }
.src-list li:hover { background: var(--surface-2); }
.src-list .sid { grid-row: 1 / 3; font-family: var(--mono); font-size: .8em; color: var(--accent); background: var(--accent-soft); border-radius: 6px; padding: .15em .45em; align-self: start; margin-top: .15em; }
.src-list span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--ink); }
.src-list small { color: var(--muted); font-family: var(--mono); font-size: .82em; }
.src-list .old { color: var(--warn); }
.placeholder { color: var(--muted); text-align: center; padding: 2em 1em; }

/* Fields */
.fields-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1cqi; }
.field { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: 1em 1.1em; display: flex; flex-direction: column; gap: .7em; box-shadow: var(--shadow-sm), var(--hi); }
.field strong { font-size: 1.05em; letter-spacing: -0.01em; }
.field small { font-family: var(--mono); color: var(--faint); font-size: .7em; }
.field.hot { border-color: var(--warn-line); background: linear-gradient(180deg, var(--warn-soft), var(--surface)); }
.field.hot small { color: var(--warn); }

/* Ladder */
.ladder { display: grid; grid-template-columns: 1.35fr 1fr; gap: 0 4cqi; align-items: center; }
.rungs { display: grid; gap: .6em; }
.rung { display: flex; gap: 1em; align-items: center; background: var(--surface); border-radius: var(--r-md); padding: .8em 1.1em; border: 1px solid var(--line); box-shadow: var(--shadow-sm), var(--hi); width: calc(100% - var(--i) * 6%); }
.rung .n { font-family: var(--mono); font-size: .8em; color: var(--accent); width: 1.6em; }
.rung strong { display: block; letter-spacing: -0.01em; }
.rung span { color: var(--muted); font-size: .86em; }
.rung .bar { margin-left: auto; height: 6px; width: calc((4 - var(--i)) * 1.6em); border-radius: 999px; background: var(--grad); opacity: calc(1 - var(--i) * .2); }
.ladder-note { display: grid; gap: 1em; }
.ladder-note .card { padding: 1.1em 1.2em; }
.warn-card { background: var(--warn-soft); border-color: var(--warn-line); color: var(--warn); }
.warn-card p { color: var(--warn); }

/* Flow */
.flow { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1cqi; position: relative; }
.flow::before { content: ""; position: absolute; left: 6%; right: 6%; top: 2.6em; height: 1px; background: linear-gradient(90deg, transparent, var(--accent-line), var(--accent-line), transparent); }
.node { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1.1em; display: flex; flex-direction: column; gap: .5em; box-shadow: var(--shadow-sm), var(--hi); }
.node.hl { border-color: var(--accent-line); box-shadow: 0 0 0 4px var(--accent-soft), var(--shadow); }
.node strong { letter-spacing: -0.01em; margin-top: .3em; }
.node small { color: var(--muted); font-size: .8em; line-height: 1.5; }
.node .step { position: absolute; top: .9em; right: 1em; font-family: var(--mono); font-size: .7em; color: var(--faint); }

/* Live */
.live { display: grid; grid-template-columns: 1.2fr 1fr; gap: 4cqi; align-items: center; }
.live-preview { border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-lg); background: var(--surface); font-size: .78em; }
.lp-top { display: flex; align-items: center; gap: .5em; padding: .7em 1em; border-bottom: 1px solid var(--line); background: var(--surface-2); color: var(--muted); font-size: .85em; }
.lp-body { padding: 1em; display: grid; gap: .7em; }
.lp-user { justify-self: end; background: var(--ink); color: var(--bg); padding: .5em .9em; border-radius: 16px 16px 4px 16px; }
.lp-step { display: flex; align-items: center; gap: .6em; color: var(--muted); }
.lp-step .i { color: var(--accent); }
.lp-step b { color: var(--ink); font-weight: 500; }
.lp-step em { margin-left: auto; font-style: normal; font-family: var(--mono); font-size: .85em; color: var(--accent); }
.live-legend { display: grid; gap: .7em; margin: 1.4em 0; color: var(--muted); font-size: .92em; }
.live-legend span { display: flex; align-items: center; gap: .7em; }
.dot { display: inline-block; width: .7em; height: .7em; border-radius: 50%; }
.dot.ok { background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); } .dot.warn { background: var(--warn); box-shadow: 0 0 0 4px var(--warn-soft); } .dot.none { border: 1.5px dashed var(--faint); }

.kv { list-style: none; margin: 0 0 1em; padding: 0; display: grid; gap: 1px; background: var(--line); border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--line); }
.kv li { display: grid; grid-template-columns: 6.2em 1fr; gap: .6em; padding: .55em .9em; background: var(--surface); font-size: .92em; }
.kv code { font-family: var(--mono); color: var(--accent); font-size: .9em; }

.more { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2cqi; }
.paths .card .label { color: var(--accent); margin-top: 1em; display: block; }
.paths .card h3 { font-size: 1.15em; margin-top: .25em; }
.end { display: grid; grid-template-columns: 1.5fr 1fr; gap: 4cqi; align-items: center; }
.three { list-style: none; margin: 0; padding: 0; display: grid; gap: 1em; counter-reset: t; }
.three li { counter-increment: t; display: flex; gap: .8em; align-items: baseline; font-size: 1.55em; letter-spacing: -0.025em; font-weight: 600; }
.three li::before { content: "0" counter(t); font-family: var(--mono); font-size: .5em; color: var(--accent); font-weight: 500; }
.three b { color: var(--accent); }
.qr { display: flex; flex-direction: column; align-items: center; gap: .8em; color: var(--muted); padding: 1.4em; border-radius: var(--r-xl); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); font-size: .85em; }
.qr img { width: 14cqi; height: 14cqi; border-radius: 12px; background: #fff; padding: 8px; }
.qr code { font-size: .75em; word-break: break-all; }

/* ===== Notes & TOC ===== */
#notes { position: fixed; right: 16px; bottom: 72px; width: min(440px, calc(100vw - 32px)); max-height: 62vh; overflow: auto; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(20px); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); padding: 16px 18px; z-index: 20; display: none; font-size: 14px; }
#notes[open] { display: block; animation: enter .25s; }
#notes h3 { font-family: var(--mono); font-size: 10.5px; letter-spacing: .1em; color: var(--accent); margin: 14px 0 4px; text-transform: uppercase; }
#notes p { margin: 0 0 6px; color: var(--ink-2); line-height: 1.7; }
#notes .meta { color: var(--muted); font-size: 11.5px; font-family: var(--mono); }
.notes-top, .toc-top { display: flex; justify-content: space-between; align-items: center; }
.notes-top button, .toc-top button { border: 0; background: var(--surface-2); color: var(--muted); width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; }
#toc { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); color: var(--ink); width: min(580px, calc(100vw - 32px)); max-height: 80vh; padding: 16px; box-shadow: var(--shadow-lg); }
#toc::backdrop { background: rgba(0, 0, 0, .3); backdrop-filter: blur(6px); }
#toc-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 2px; }
#toc-list button { width: 100%; text-align: left; border: 0; background: transparent; padding: 9px 10px; border-radius: 10px; display: grid; grid-template-columns: 2.2em 1fr auto; gap: 8px; align-items: baseline; font-size: 14px; }
#toc-list button:hover, #toc-list button[aria-current] { background: var(--surface-2); }
#toc-list button[aria-current] span { color: var(--accent); }
#toc-list span, #toc-list small { color: var(--muted); font-family: var(--mono); font-size: 11.5px; }

/* ===== Mobile ===== */
@media (max-width: 760px) {
  .deck { overflow: auto; height: auto; }
  .toolbar { top: 10px; left: 12px; right: 12px; }
  .toolbar nav .tb-link:not(.accent), #presenter-open, #fullscreen, #notes-open, .tip, .brand small { display: none; }
  .controls { bottom: 12px; }
  .chapter { display: none; }
  #viewport { position: static; display: block; padding: 76px 16px 84px; }
  .slide { width: 100%; aspect-ratio: auto; min-height: calc(100vh - 170px); padding: 8px 0; }
  .slide-body { font-size: 15px; justify-content: flex-start; }
  .slide h2 { font-size: 28px; }
  .cover, .split, .split.wide-left, .pain, .me, .compare, .ladder, .end, .trio, .live { grid-template-columns: 1fr; }
  .hero-visual { height: auto; margin-top: 12px; } .hero-visual .store-card { transform: none; width: 100%; font-size: 13px; } .float-chip { display: none; }
  .compare .arrow { transform: rotate(90deg); justify-self: center; }
  .sells, .fields-grid, .more { grid-template-columns: 1fr 1fr; }
  .steps3, .flow { grid-template-columns: 1fr; } .flow::before { display: none; }
  .rung { width: 100%; }
  .portrait { width: 120px; height: 120px; }
  .apps { flex-direction: column; }
  .stat { font-size: 64px; }
  .qr img { width: 160px; height: 160px; }
}

/* Screenshot figure */
.shot { margin: 0; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-lg); background: var(--surface); }
.shot img { display: block; width: 100%; height: auto; max-height: 52cqi; object-fit: cover; object-position: top; }
.steps3 li .ico { width: 2em; height: 2em; border-radius: 10px; }
.layout-cover .slide-body { justify-content: center; }
.live-preview { max-height: 33cqi; -webkit-mask-image: linear-gradient(#000 78%, transparent); mask-image: linear-gradient(#000 78%, transparent); }
.live-preview .store-card { font-size: .9em; box-shadow: none; }
.compare .store-card dl > div, .hero-visual .store-card dl > div { padding: .45em .6em; }

/* Type badges */
.tb { display: inline-flex; align-items: center; height: 16px; padding: 0 5px; border-radius: 5px; font-size: 9.5px; font-weight: 600; letter-spacing: .02em; flex: none; }
.tb-official { background: var(--accent); color: var(--accent-ink); }
.tb-platform { background: rgba(59, 130, 246, .12); color: #3b82f6; }
.tb-media { background: rgba(139, 92, 246, .12); color: #8b5cf6; }
.tb-personal { background: var(--surface-3); color: var(--muted); }
.chip .tb { height: 14px; font-size: 9px; }

