/* ============================================================
   罗林森内容创造平台 · Rollinson Content Platform
   Token system + 3 theme skins (Terminal / Editorial / Luminous)
   ============================================================ */

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background .5s ease, color .4s ease;
  overflow-x: hidden;
}
button { font-family: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--accent); color: var(--bg); }
img { display: block; max-width: 100%; }

/* ---------- Base tokens (defaults; per-theme below) ---------- */
:root {
  --maxw: 1180px;
  --ease: cubic-bezier(.2,.7,.3,1);
  --font-display: "Space Grotesk", "Noto Sans SC", system-ui, sans-serif;
  --font-body: "Manrope", "Noto Sans SC", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
}

/* ============================================================
   THEME · LUMINOUS  (default — glass + cool glow)
   ============================================================ */
[data-theme="luminous"] {
  --bg: #07090f;
  --bg-2: #0a0e1a;
  --surface: rgba(255,255,255,.045);
  --surface-2: rgba(255,255,255,.07);
  --surface-hover: rgba(255,255,255,.09);
  --border: rgba(130,160,255,.16);
  --border-strong: rgba(130,160,255,.34);
  --text: #e9eeff;
  --text-dim: #a7b1d6;
  --text-mute: #6b7399;
  --accent: #6f8cff;
  --accent-2: #a172ff;
  --accent-ink: #060810;
  --radius: 16px;
  --radius-sm: 10px;
  --radius-pill: 100px;
  --font-display: "Space Grotesk", "Noto Sans SC", system-ui, sans-serif;
  --font-head: "Space Grotesk", "Noto Sans SC", system-ui, sans-serif;
  --font-body: "Manrope", "Noto Sans SC", system-ui, sans-serif;
  --shadow: 0 1px 0 rgba(255,255,255,.05) inset, 0 18px 50px rgba(0,0,0,.5);
  --glow: 0 0 0 1px var(--border), 0 20px 60px rgba(70,90,200,.18);
  --ph-a: rgba(111,140,255,.10); --ph-b: rgba(161,114,255,.05);
}
[data-theme="luminous"] body {
  background:
    radial-gradient(900px 520px at 78% -8%, rgba(111,140,255,.18), transparent 60%),
    radial-gradient(760px 520px at 8% 4%, rgba(161,114,255,.14), transparent 55%),
    var(--bg);
  background-attachment: fixed;
}

/* ============================================================
   THEME · TERMINAL  (monospace + phosphor + grid)
   ============================================================ */
[data-theme="terminal"] {
  --bg: #060807;
  --bg-2: #0a0e0c;
  --surface: rgba(120,255,205,.025);
  --surface-2: rgba(120,255,205,.05);
  --surface-hover: rgba(120,255,205,.08);
  --border: rgba(120,255,205,.16);
  --border-strong: rgba(120,255,205,.42);
  --text: #cfe7dd;
  --text-dim: #82a89c;
  --text-mute: #557068;
  --accent: #4ff0c0;
  --accent-2: #4ff0c0;
  --accent-ink: #04130d;
  --radius: 2px;
  --radius-sm: 2px;
  --radius-pill: 2px;
  --font-display: "JetBrains Mono", "Noto Sans SC", monospace;
  --font-head: "JetBrains Mono", "Noto Sans SC", monospace;
  --font-body: "JetBrains Mono", "Noto Sans SC", monospace;
  --shadow: 0 0 0 1px var(--border);
  --glow: 0 0 0 1px var(--border-strong), 0 0 30px rgba(79,240,192,.08);
  --ph-a: rgba(79,240,192,.09); --ph-b: rgba(79,240,192,.02);
}
[data-theme="terminal"] body {
  background:
    linear-gradient(var(--border) 1px, transparent 1px) 0 0 / 100% 38px,
    linear-gradient(90deg, var(--border) 1px, transparent 1px) 0 0 / 38px 100%,
    var(--bg);
  background-attachment: fixed;
}
[data-theme="terminal"] body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 999;
  background: repeating-linear-gradient(180deg, rgba(0,0,0,0) 0 2px, rgba(0,0,0,.16) 2px 3px);
  mix-blend-mode: multiply; opacity: .5;
}

/* ============================================================
   THEME · EDITORIAL  (serif display + warm gold + air)
   ============================================================ */
[data-theme="editorial"] {
  --bg: #f6f3ec;
  --bg-2: #fdfbf6;
  --surface: rgba(40,32,20,.022);
  --surface-2: rgba(40,32,20,.045);
  --surface-hover: rgba(40,32,20,.06);
  --border: rgba(40,32,20,.13);
  --border-strong: rgba(40,32,20,.30);
  --text: #1c1812;
  --text-dim: #5b5345;
  --text-mute: #8c8474;
  --accent: #9a4b2e;
  --accent-2: #b9603a;
  --accent-ink: #fdfbf6;
  --radius: 4px;
  --radius-sm: 3px;
  --radius-pill: 3px;
  --font-display: "Newsreader", "Noto Serif SC", Georgia, serif;
  --font-head: "Newsreader", "Noto Serif SC", Georgia, serif;
  --font-body: "Inter", "Noto Sans SC", system-ui, sans-serif;
  --shadow: 0 24px 60px rgba(60,45,20,.12);
  --glow: 0 0 0 1px var(--border-strong), 0 22px 48px rgba(80,55,25,.13);
  --ph-a: rgba(154,75,46,.10); --ph-b: rgba(154,75,46,.03);
}
[data-theme="editorial"] body {
  background:
    radial-gradient(1100px 620px at 80% -12%, rgba(154,75,46,.06), transparent 60%),
    var(--bg);
  background-attachment: fixed;
}
[data-theme="editorial"] ::selection { background: var(--accent); color: var(--accent-ink); }
[data-theme="editorial"] .hero h1 .grad { -webkit-text-fill-color: var(--accent); }

/* ============================================================
   LAYOUT
   ============================================================ */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }
.app { min-height: 100vh; position: relative; }

/* ---------- Top bar ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  border-bottom: 1px solid var(--border);
}
.nav-in { display: flex; align-items: center; gap: 12px; height: 66px; }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; flex-shrink: 0; }
.brand-mark {
  width: 34px; height: 34px; flex: 0 0 auto; border-radius: var(--radius-sm);
  display: grid; place-items: center; font-family: var(--font-display);
  font-weight: 700; font-size: 16px; letter-spacing: -.5px;
  color: var(--accent-ink); background: var(--accent);
  box-shadow: 0 0 20px color-mix(in srgb, var(--accent) 45%, transparent);
}
[data-theme="terminal"] .brand-mark { box-shadow: none; border: 1px solid var(--accent); background: transparent; color: var(--accent); }
.brand-name { font-family: var(--font-head); font-weight: 600; font-size: 16px; letter-spacing: -.2px; line-height: 1.1; }
.brand-sub { font-size: 11px; color: var(--text-mute); letter-spacing: .14em; text-transform: uppercase; font-family: var(--font-mono); }
.nav-spacer { flex: 1; }
.nav-links { display: flex; gap: 4px; }
.nav-link {
  font-size: 13.5px; color: var(--text-dim); padding: 8px 12px; border-radius: var(--radius-sm);
  letter-spacing: .01em; transition: color .2s, background .2s; white-space: nowrap;
}
.nav-link:hover { color: var(--text); background: var(--surface); }
.nav-link.on { color: var(--accent); }

/* segmented control (theme + lang) */
.seg { display: inline-flex; padding: 3px; gap: 2px; border: 1px solid var(--border); border-radius: var(--radius-pill); background: var(--surface); }
.seg button {
  border: 0; background: transparent; color: var(--text-mute);
  font-size: 12px; font-weight: 600; letter-spacing: .03em; padding: 6px 11px;
  border-radius: var(--radius-pill); transition: color .2s, background .2s; white-space: nowrap;
  font-family: var(--font-mono);
}
.seg button:hover { color: var(--text-dim); }
.seg button.on { color: var(--accent-ink); background: var(--accent); }
[data-theme="terminal"] .seg button.on { color: var(--accent); background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--accent); }

.icon-seg button { font-family: var(--font-display); }

/* ---------- Hero ---------- */
.hero { padding: 92px 0 56px; position: relative; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 9px; font-family: var(--font-mono);
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-mute);
  margin-bottom: 26px;
}
.hero-eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 12px var(--accent); animation: pulse 2.4s var(--ease) infinite; }
@keyframes pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:.4;transform:scale(.7)} }
.hero h1 {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(40px, 6.4vw, 78px); line-height: 1.02; letter-spacing: -.025em;
  margin: 0 0 22px; max-width: 16ch; text-wrap: balance;
}
[data-theme="editorial"] .hero h1 { font-weight: 500; letter-spacing: -.01em; }
.hero h1 .grad {
  background: linear-gradient(96deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
[data-theme="editorial"] .hero h1 .grad { font-style: italic; }
.hero-lede { font-size: clamp(16px, 1.8vw, 20px); color: var(--text-dim); max-width: 52ch; margin: 0 0 34px; line-height: 1.6; text-wrap: pretty; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.btn {
  display: inline-flex; align-items: center; gap: 9px; padding: 13px 20px; border-radius: var(--radius-pill);
  font-size: 14px; font-weight: 600; letter-spacing: .01em; border: 1px solid transparent;
  transition: transform .18s var(--ease), box-shadow .25s, background .2s, border-color .2s; font-family: var(--font-head); white-space: nowrap;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 0 0 transparent; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 32px color-mix(in srgb, var(--accent) 38%, transparent); }
[data-theme="terminal"] .btn-primary { background: transparent; color: var(--accent); border-color: var(--accent); }
[data-theme="terminal"] .btn-primary:hover { background: var(--surface-2); box-shadow: 0 0 24px rgba(79,240,192,.2); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--border-strong); background: var(--surface-2); transform: translateY(-2px); }

.hero-stats { display: flex; gap: 34px; margin-top: 50px; flex-wrap: wrap; }
.stat .n { font-family: var(--font-display); font-size: 27px; font-weight: 600; letter-spacing: -.02em; }
.stat .l { font-size: 12px; color: var(--text-mute); letter-spacing: .04em; font-family: var(--font-mono); }

/* ---------- CURRENTLY ticker (lixiaolai homage) ---------- */
.currently {
  margin-top: 40px; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  display: flex; align-items: stretch; overflow: hidden;
}
.currently-label {
  flex: 0 0 auto; display: flex; align-items: center; gap: 8px; padding: 14px 20px 14px 0;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--accent); border-right: 1px solid var(--border); margin-right: 0; white-space: nowrap;
}
.currently-label .lv { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.currently-track { flex: 1; overflow: hidden; position: relative; -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.currently-move { display: inline-flex; align-items: center; gap: 0; white-space: nowrap; animation: ticker 38s linear infinite; }
.no-motion .currently-move { animation: none; }
.currently:hover .currently-move { animation-play-state: paused; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.tick { display: inline-flex; align-items: center; gap: 10px; padding: 14px 24px; font-family: var(--font-mono); font-size: 12.5px; color: var(--text-dim); }
.tick b { color: var(--text); font-weight: 600; }
.tick::after { content: "·"; color: var(--text-mute); margin-left: 14px; }

/* ---------- Numbered index (works list) ---------- */
.index-list { display: flex; flex-direction: column; border-top: 1px solid var(--border); }
.index-row {
  display: grid; grid-template-columns: 56px 1fr auto; align-items: center; gap: 18px;
  padding: 20px 8px; border-bottom: 1px solid var(--border); background: transparent; text-align: left;
  color: inherit; width: 100%; transition: background .25s var(--ease), padding .25s var(--ease);
}
.index-row:hover { background: var(--surface); padding-left: 18px; padding-right: 0; }
.index-num { font-family: var(--font-mono); font-size: 13px; color: var(--text-mute); letter-spacing: .04em; }
.index-row:hover .index-num { color: var(--accent); }
.index-main { min-width: 0; }
.index-title { font-family: var(--font-head); font-size: 19px; font-weight: 600; letter-spacing: -.01em; line-height: 1.3; margin-bottom: 5px; transition: color .2s; }
[data-theme="editorial"] .index-title { font-weight: 500; }
.index-row:hover .index-title { color: var(--accent); }
[data-theme="editorial"] .index-row:hover .index-title { color: var(--text); }
.index-sub { font-size: 13px; color: var(--text-mute); display: flex; align-items: center; gap: 9px; font-family: var(--font-mono); flex-wrap: wrap; }
.index-sub .pdot { width: 6px; height: 6px; border-radius: 50%; }
.index-right { display: flex; align-items: center; gap: 16px; color: var(--text-mute); font-family: var(--font-mono); font-size: 12px; }
.index-right .arrow { transition: transform .25s var(--ease); }
.index-row:hover .index-right .arrow { transform: translateX(5px); color: var(--accent); }
@media (max-width: 600px){ .index-row { grid-template-columns: 40px 1fr; } .index-right { display: none; } }

/* view toggle */
.view-toggle { display: inline-flex; gap: 2px; padding: 3px; border: 1px solid var(--border); border-radius: var(--radius-pill); background: var(--surface); }
.view-toggle button { border: 0; background: transparent; color: var(--text-mute); width: 32px; height: 28px; display: grid; place-items: center; border-radius: var(--radius-pill); transition: all .2s; }
.view-toggle button:hover { color: var(--text-dim); }
.view-toggle button.on { color: var(--accent-ink); background: var(--accent); }
[data-theme="terminal"] .view-toggle button.on { color: var(--accent); background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--accent); }

@media (max-width: 680px) {
  .nav-in { gap: 8px; }
  .brand-sub { display: none; }
  .brand-name { font-size: 14px; }
  .icon-seg { display: none; }
  .nav-links { gap: 0; }
  .nav-link { padding: 8px 8px; font-size: 13px; }
  .seg button { padding: 6px 8px; font-size: 11px; }
}

/* ---------- Section header ---------- */
.sec { padding: 30px 0 8px; }
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 26px; flex-wrap: wrap; }
.sec-title { font-family: var(--font-head); font-size: 24px; font-weight: 600; letter-spacing: -.02em; display: flex; align-items: baseline; gap: 12px; }
.sec-title .hash { color: var(--accent); font-family: var(--font-mono); font-size: 18px; }
.sec-desc { font-size: 14px; color: var(--text-mute); }

/* ---------- Filter chips ---------- */
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  border: 1px solid var(--border); background: var(--surface); color: var(--text-dim);
  padding: 8px 15px; border-radius: var(--radius-pill); font-size: 13px; font-weight: 500;
  display: inline-flex; align-items: center; gap: 8px; transition: all .2s var(--ease);
}
.chip:hover { color: var(--text); border-color: var(--border-strong); }
.chip.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
[data-theme="terminal"] .chip.on { background: var(--surface-2); color: var(--accent); border-color: var(--accent); }
.chip .ct { font-family: var(--font-mono); font-size: 11px; opacity: .7; }
.chip.on .ct { opacity: .85; }

/* ---------- Grid ---------- */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 8px; }
.grid.feat { grid-template-columns: 1.5fr 1fr 1fr; }
@media (max-width: 900px){ .grid, .grid.feat { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px){ .grid, .grid.feat { grid-template-columns: 1fr; } }

/* ---------- Card ---------- */
.card {
  position: relative; display: flex; flex-direction: column; text-align: left;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; transition: transform .28s var(--ease), border-color .28s, box-shadow .28s, background .28s;
  width: 100%; color: inherit;
}
.card:hover { transform: translateY(-5px); border-color: var(--border-strong); box-shadow: var(--glow); background: var(--surface-hover); }
.card.big { grid-row: span 2; }

.cover { position: relative; width: 100%; aspect-ratio: 16/10; overflow: hidden; background: var(--bg-2); }
.cover-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.card:hover .cover-img { transform: scale(1.05); }
.card.big .cover { aspect-ratio: 16/13; }
.cover-ph {
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(135deg, var(--ph-a) 0 11px, var(--ph-b) 11px 22px);
  display: grid; place-items: center;
  transition: transform .5s var(--ease);
}
.card:hover .cover-ph { transform: scale(1.05); }
.cover-ph .tag { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; color: var(--text-mute); text-transform: uppercase; background: color-mix(in srgb, var(--bg) 60%, transparent); padding: 5px 10px; border-radius: var(--radius-pill); border: 1px solid var(--border); }
.cover-grad { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 40%, color-mix(in srgb, var(--bg) 78%, transparent)); }

.badge {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600; letter-spacing: .04em;
  padding: 5px 9px; border-radius: var(--radius-pill);
  background: color-mix(in srgb, var(--bg) 55%, transparent); color: var(--text);
  border: 1px solid var(--border-strong); backdrop-filter: blur(8px);
  display: inline-flex; align-items: center; gap: 6px;
}
.badge .pdot { width: 6px; height: 6px; border-radius: 50%; background: var(--pcolor, var(--accent)); }

.card-body { padding: 17px 18px 19px; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.card-meta { display: flex; align-items: center; gap: 9px; font-family: var(--font-mono); font-size: 11px; color: var(--text-mute); letter-spacing: .02em; }
.card-meta .sepd { width: 3px; height: 3px; border-radius: 50%; background: var(--text-mute); }
.card-title { font-family: var(--font-head); font-size: 18px; font-weight: 600; line-height: 1.28; letter-spacing: -.01em; text-wrap: pretty; transition: color .2s; }
.card.big .card-title { font-size: 23px; }
[data-theme="editorial"] .card-title { font-weight: 500; }
.card:hover .card-title { color: var(--accent); }
[data-theme="editorial"] .card:hover .card-title { color: var(--text); }
.card-excerpt { font-size: 13.5px; color: var(--text-dim); line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card.big .card-excerpt { -webkit-line-clamp: 3; font-size: 14.5px; }
.card-foot { margin-top: auto; padding-top: 12px; display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--text-mute); font-family: var(--font-mono); }
.card-foot .arrow { margin-left: auto; transition: transform .25s var(--ease); }
.card:hover .card-foot .arrow { transform: translateX(4px); color: var(--accent); }
.tagrow { display: flex; gap: 6px; flex-wrap: wrap; }
.minitag { font-family: var(--font-mono); font-size: 10.5px; color: var(--text-mute); border: 1px solid var(--border); padding: 2px 7px; border-radius: var(--radius-pill); }

/* video card play */
.play { position: absolute; inset: 0; display: grid; place-items: center; z-index: 2; }
.play .pbtn { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--bg) 40%, transparent); border: 1px solid var(--border-strong); backdrop-filter: blur(8px); transition: transform .25s var(--ease), background .25s; }
.card:hover .play .pbtn { transform: scale(1.12); background: var(--accent); }
.play .pbtn svg { fill: var(--text); transition: fill .25s; margin-left: 3px; }
.card:hover .play .pbtn svg { fill: var(--accent-ink); }
.vlen { position: absolute; bottom: 12px; right: 12px; z-index: 2; font-family: var(--font-mono); font-size: 11px; padding: 3px 8px; border-radius: var(--radius-sm); background: color-mix(in srgb, var(--bg) 60%, transparent); border: 1px solid var(--border); }

/* photo card */
.card.photo .cover { aspect-ratio: 1/1; }
.photo-count { position: absolute; bottom: 12px; right: 12px; z-index: 2; font-family: var(--font-mono); font-size: 11px; padding: 3px 8px; border-radius: var(--radius-sm); background: color-mix(in srgb, var(--bg) 55%, transparent); border: 1px solid var(--border); display: flex; gap: 6px; align-items: center; }

/* ---------- Reader overlay ---------- */
.reader-back { position: fixed; inset: 0; z-index: 100; background: color-mix(in srgb, var(--bg) 60%, rgba(0,0,0,.6)); backdrop-filter: blur(10px); display: flex; justify-content: center; overflow-y: auto; padding: 0; animation: fade .25s ease; }
@keyframes fade { from { opacity: 0; } }
.reader {
  position: relative; width: 100%; max-width: 760px; margin: 56px 20px; background: var(--bg-2);
  border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 40px 120px rgba(0,0,0,.6);
  animation: rise .35s var(--ease); overflow: hidden;
}
@keyframes rise { from { transform: translateY(24px); opacity: 0; } }
.reader-cover { position: relative; aspect-ratio: 21/9; overflow: hidden; }
.reader-x { position: fixed; top: 20px; right: 24px; z-index: 110; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--border); background: color-mix(in srgb, var(--bg) 70%, transparent); color: var(--text); font-size: 20px; backdrop-filter: blur(10px); display: grid; place-items: center; transition: transform .2s, background .2s; }
.reader-x:hover { transform: rotate(90deg); background: var(--surface-2); }
.reader-inner { padding: 38px clamp(24px, 5vw, 60px) 50px; }
.reader-kicker { display: flex; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 12px; color: var(--text-mute); margin-bottom: 16px; letter-spacing: .03em; }
.reader h2 { font-family: var(--font-display); font-size: clamp(26px, 3.6vw, 40px); font-weight: 600; line-height: 1.12; letter-spacing: -.02em; margin: 0 0 14px; text-wrap: balance; }
[data-theme="editorial"] .reader h2 { font-weight: 500; }
.reader-sub { font-size: 17px; color: var(--text-dim); line-height: 1.6; margin: 0 0 24px; font-family: var(--font-body); }
.reader-byline { display: flex; align-items: center; gap: 12px; padding: 16px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin-bottom: 28px; font-size: 13px; color: var(--text-dim); font-family: var(--font-mono); flex-wrap: wrap; }
.byline-cta { margin-left: auto; display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: var(--radius-pill); background: var(--accent); color: var(--accent-ink); font-family: var(--font-head); font-weight: 600; font-size: 12.5px; letter-spacing: .01em; transition: transform .18s var(--ease), box-shadow .25s; }
.byline-cta:hover { transform: translateY(-1px); box-shadow: 0 8px 22px color-mix(in srgb, var(--accent) 38%, transparent); }
[data-theme="terminal"] .byline-cta { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
.reader-body p { font-size: 16.5px; line-height: 1.78; color: var(--text); margin: 0 0 20px; }
.reader-body p.lead::first-letter { font-family: var(--font-display); font-size: 3em; float: left; line-height: .8; padding: 6px 10px 0 0; color: var(--accent); }
.reader-body h3 { font-family: var(--font-head); font-size: 20px; font-weight: 600; margin: 32px 0 12px; letter-spacing: -.01em; }
.reader-body blockquote { margin: 24px 0; padding: 4px 0 4px 22px; border-left: 2px solid var(--accent); font-family: var(--font-display); font-size: 19px; line-height: 1.5; color: var(--text); font-style: italic; }
.orig-link { display: inline-flex; align-items: center; gap: 10px; margin-top: 14px; padding: 13px 20px; border: 1px solid var(--border-strong); border-radius: var(--radius-pill); font-family: var(--font-mono); font-size: 13px; color: var(--text); transition: all .2s; }
.orig-link:hover { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

/* ---------- About strip ---------- */
.about { margin: 30px 0; padding: 44px clamp(26px,5vw,56px); border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); position: relative; overflow: hidden; }
.about::before { content: ""; position: absolute; inset: 0; background: radial-gradient(600px 300px at 90% 10%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 60%); pointer-events: none; }
.about-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; position: relative; }
@media (max-width: 760px){ .about-grid { grid-template-columns: 1fr; } }
.about h3 { font-family: var(--font-head); font-size: clamp(22px,3vw,30px); font-weight: 600; letter-spacing: -.02em; margin: 0 0 16px; }
.about p { color: var(--text-dim); line-height: 1.7; margin: 0 0 14px; font-size: 15px; }
.topics { display: flex; flex-direction: column; gap: 12px; }
.topic { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg-2); transition: border-color .2s, transform .2s; }
.topic:hover { border-color: var(--border-strong); transform: translateX(4px); }
.topic .ti { width: 30px; height: 30px; border-radius: var(--radius-sm); display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent); flex: 0 0 auto; }
.topic .tt { font-family: var(--font-head); font-size: 14px; font-weight: 600; }
.topic .td { font-size: 12px; color: var(--text-mute); font-family: var(--font-mono); }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--border); margin-top: 40px; padding: 44px 0 56px; }
.footer-grid { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; align-items: flex-start; }
.footer-tag { font-family: var(--font-mono); font-size: 12px; color: var(--text-mute); max-width: 38ch; line-height: 1.7; }
.socials { display: flex; gap: 10px; flex-wrap: wrap; }
.social { display: inline-flex; align-items: center; gap: 9px; padding: 10px 15px; border: 1px solid var(--border); border-radius: var(--radius-pill); font-family: var(--font-mono); font-size: 12px; color: var(--text-dim); transition: all .2s; }
.social:hover { border-color: var(--border-strong); color: var(--text); transform: translateY(-2px); }
.social .sdot { width: 7px; height: 7px; border-radius: 50%; }
.copyright { margin-top: 34px; font-family: var(--font-mono); font-size: 11.5px; color: var(--text-mute); letter-spacing: .03em; }

/* ---------- Empty state ---------- */
.empty { grid-column: 1/-1; text-align: center; padding: 60px 0; color: var(--text-mute); font-family: var(--font-mono); font-size: 14px; }

/* ---------- Scroll reveal ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce){ .reveal { opacity: 1; transform: none; transition: none; } .hero-eyebrow .dot { animation: none; } }

/* fade swap when theme/lang change — never starts fully invisible (clone-safe) */
.swap { animation: swapfade .38s var(--ease) both; }
@keyframes swapfade { from { opacity: .25; } to { opacity: 1; } }

/* ---------- Tweak-driven knobs ---------- */
[data-density="cozy"] .grid, [data-density="cozy"] .grid.feat { grid-template-columns: repeat(2, 1fr); }
[data-density="cozy"] .grid .card.big { grid-row: auto; }
@media (max-width: 900px){ [data-density="cozy"] .grid, [data-density="cozy"] .grid.feat { grid-template-columns: 1fr; } }
[data-dropcap="off"] .reader-body p.lead::first-letter { font-family: inherit; font-size: inherit; float: none; padding: 0; color: inherit; }
.no-motion .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
.no-motion .hero-eyebrow .dot { animation: none; }
.no-motion .swap { animation: none; }
