/* =========================================================================
   localpix.org — shared stylesheet
   -------------------------------------------------------------------------
   Tokens lifted verbatim from the LocalPix design system. A small set of
   web-only type roles (hero, page-title) extend the app's compressed
   utility scale upward for marketing surfaces. No new colors, no new
   spacing — every value resolves to a documented token.
   ========================================================================= */

/* --- Tokens -------------------------------------------------------------- */
:root {
  --bg:            oklch(0.985 0.003 250);
  --surface:       #ffffff;
  --surface-2:     oklch(0.975 0.004 250);
  --surface-hover: oklch(0.965 0.005 250);
  --border:        oklch(0.92  0.006 250);
  --border-strong: oklch(0.86  0.008 250);
  --text:          oklch(0.22  0.01  250);
  --text-muted:    oklch(0.5   0.008 250);
  --text-faint:    oklch(0.65  0.006 250);
  --accent:        oklch(0.54  0.14  250);
  --accent-hover:  oklch(0.48  0.15  250);
  --accent-soft:   oklch(0.955 0.035 250);
  --accent-ring:   oklch(0.54  0.14  250 / 0.25);
  --success:       oklch(0.58  0.13  150);
  --success-soft:  oklch(0.965 0.035 150);
  --danger:        oklch(0.58  0.18   27);
  --danger-soft:   oklch(0.965 0.035  27);
  --warn:          oklch(0.55  0.13   75);

  --radius-sm: 6px;
  --radius:    8px;
  --radius-lg: 12px;

  --font:      'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;

  --container: 880px;
}

@font-face {
  font-family: 'Inter';
  src: url('./fonts/Inter-VariableFont_opsz_wght.ttf') format('truetype-variations');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg:            oklch(0.16 0.014 250);
    --surface:       oklch(0.20 0.014 250);
    --surface-2:     oklch(0.245 0.014 250);
    --surface-hover: oklch(0.275 0.014 250);
    --border:        oklch(0.30 0.016 250);
    --border-strong: oklch(0.40 0.018 250);
    --text:          oklch(0.94 0.008 250);
    --text-muted:    oklch(0.66 0.010 250);
    --text-faint:    oklch(0.50 0.010 250);
    --accent:        oklch(0.68 0.16 250);
    --accent-hover:  oklch(0.75 0.15 250);
    --accent-soft:   oklch(0.27 0.06 250);
    --accent-ring:   oklch(0.68 0.16 250 / 0.30);
    --success:       oklch(0.70 0.14 150);
    --success-soft:  oklch(0.26 0.05 150);
    --danger:        oklch(0.70 0.18  27);
    --danger-soft:   oklch(0.27 0.06  27);
    --warn:          oklch(0.70 0.14  75);
  }
}

:root[data-theme="dark"] {
  --bg:            oklch(0.16 0.014 250);
  --surface:       oklch(0.20 0.014 250);
  --surface-2:     oklch(0.245 0.014 250);
  --surface-hover: oklch(0.275 0.014 250);
  --border:        oklch(0.30 0.016 250);
  --border-strong: oklch(0.40 0.018 250);
  --text:          oklch(0.94 0.008 250);
  --text-muted:    oklch(0.66 0.010 250);
  --text-faint:    oklch(0.50 0.010 250);
  --accent:        oklch(0.68 0.16 250);
  --accent-hover:  oklch(0.75 0.15 250);
  --accent-soft:   oklch(0.27 0.06 250);
  --accent-ring:   oklch(0.68 0.16 250 / 0.30);
  --success:       oklch(0.70 0.14 150);
  --success-soft:  oklch(0.26 0.05 150);
  --danger:        oklch(0.70 0.18  27);
  --danger-soft:   oklch(0.27 0.06  27);
  --warn:          oklch(0.70 0.14  75);
}

.theme-switching, .theme-switching * { transition: none !important; }

/* --- Reset --------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

html, body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 13px;
  line-height: 1.55;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; text-underline-offset: 2px; }

img { display: block; max-width: 100%; }
hr { border: 0; border-top: 1px solid var(--border); margin: 0; }

/* --- Container ----------------------------------------------------------- */
.site-container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
@media (max-width: 720px) {
  .site-container { padding: 0 16px; }
}

/* --- Header -------------------------------------------------------------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0 18px;
  border-bottom: 1px solid var(--border);
}
.site-brand {
  display: flex; align-items: center; gap: 10px;
  color: var(--text);
}
.site-brand:hover { color: var(--text); text-decoration: none; }
.brand-mark {
  width: 22px; height: 22px; border-radius: 6px;
  background: var(--accent); display: grid; place-items: center; color: #fff;
}
.brand-name {
  font-size: 14px; font-weight: 600; letter-spacing: -0.01em; color: var(--text);
}

.site-nav {
  display: flex; align-items: center; gap: 4px;
}
.site-nav a {
  display: inline-flex; align-items: center;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  font-size: 12.5px; font-weight: 500;
  color: var(--text-muted);
  transition: color 0.12s, background-color 0.12s;
}
.site-nav a:hover { color: var(--text); background: var(--surface-2); text-decoration: none; }
.site-nav a[aria-current="page"] { color: var(--text); }

.site-nav-divider {
  width: 1px; height: 18px; background: var(--border);
  margin: 0 6px;
}

.theme-toggle {
  width: 28px; height: 28px;
  display: grid; place-items: center;
  background: transparent; border: 1px solid transparent;
  border-radius: var(--radius-sm);
  color: var(--text-muted); cursor: pointer;
  transition: background-color 0.12s, color 0.12s, border-color 0.12s;
}
.theme-toggle:hover {
  color: var(--text); background: var(--surface-2); border-color: var(--border);
}
.theme-toggle svg { width: 15px; height: 15px; }

@media (max-width: 560px) {
  .site-nav a { padding: 6px 7px; font-size: 12px; }
  .site-nav-divider { margin: 0 2px; }
}

/* --- Privacy chip (header on desktop) ----------------------------------- */
.privacy-chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11.5px; color: var(--text-muted);
  padding: 0 4px;
}
.privacy-dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--success);
}
@media (max-width: 720px) { .privacy-chip { display: none; } }

/* --- Footer -------------------------------------------------------------- */
.site-footer {
  margin-top: 80px;
  padding: 28px 0 48px;
  border-top: 1px solid var(--border);
}
.site-footer-row {
  display: flex; flex-wrap: wrap; gap: 18px 28px;
  align-items: baseline; justify-content: space-between;
}
.site-footer-tag {
  font-size: 11.5px; color: var(--text-faint);
}
.site-footer-tag .sep { color: var(--text-faint); margin: 0 6px; }
.site-footer-links {
  display: flex; flex-wrap: wrap; gap: 4px 0;
}
.site-footer-links a {
  font-size: 12px; color: var(--text-muted);
  padding: 2px 10px;
}
.site-footer-links a:hover { color: var(--text); text-decoration: none; }
.site-footer-links .sep { color: var(--text-faint); align-self: center; }

/* --- Type roles --------------------------------------------------------- */
/* App-faithful (lifted from DS) */
.lp-section-label {
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-muted);
}
.lp-body  { font-size: 13px; color: var(--text); line-height: 1.55; }
.lp-meta  { font-size: 11.5px; color: var(--text-muted); }
.lp-hint  { font-size: 11.5px; color: var(--text-muted); font-style: italic; }
.lp-faint { font-size: 11px; color: var(--text-faint); }
.lp-mono  {
  font-family: var(--font-mono); font-size: 11.5px; color: var(--text);
}
.lp-kind-chip {
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600;
  letter-spacing: 0.02em;
  padding: 1px 6px;
  border-radius: 3px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  display: inline-block;
}

/* Web-only extensions — the only types larger than 14px in the system.
   Tight tracking, semibold; reads as "the utility, but on a page." */
.web-hero {
  font-size: clamp(30px, 4.5vw, 44px);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.025em;
  color: var(--text);
  text-wrap: balance;
}
.web-hero em {
  font-style: normal;
  color: var(--accent);
}
.web-lede {
  font-size: clamp(15px, 1.6vw, 17px);
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: -0.008em;
  color: var(--text-muted);
  max-width: 60ch;
}
.web-title {
  font-size: 22px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--text);
}
.web-subtitle {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--text);
}

/* --- Sections (1px dividers, NEVER cards-in-cards — per DS) -------------- */
.section {
  padding: 56px 0;
  border-bottom: 1px solid var(--border);
}
.section.tight   { padding: 32px 0; }
.section.loose   { padding: 80px 0; }
.section:last-of-type { border-bottom: none; }

.section-head {
  display: flex; flex-wrap: wrap; gap: 8px 16px;
  align-items: baseline; justify-content: space-between;
  margin-bottom: 24px;
}
.section-head .lp-section-label { margin-bottom: 0; }

/* --- Buttons (lifted from DS) ------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px;
  border: 1px solid transparent; border-radius: var(--radius-sm);
  font-size: 12.5px; font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background-color 0.12s, border-color 0.12s, color 0.12s, transform 0.05s;
  white-space: nowrap;
  text-decoration: none;
}
.btn:hover { text-decoration: none; }
.btn:active:not(:disabled) { transform: translateY(0.5px); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }

.btn-primary {
  background: var(--accent); color: #fff; border-color: var(--accent);
}
.btn-primary:hover:not(:disabled) {
  background: var(--accent-hover); border-color: var(--accent-hover); color: #fff;
}
.btn-secondary {
  background: var(--surface); color: var(--text); border-color: var(--border-strong);
}
.btn-secondary:hover:not(:disabled) {
  background: var(--surface-hover); border-color: var(--text-muted); color: var(--text);
}
.btn-ghost {
  background: transparent; color: var(--text-muted); border-color: transparent;
  padding: 7px 10px;
}
.btn-ghost:hover:not(:disabled) {
  color: var(--text); background: var(--surface-2);
}
.btn-lg { padding: 12px 20px; font-size: 13.5px; }
.btn .btn-sub {
  font-weight: 500; color: rgba(255,255,255,0.7);
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0;
}
.btn-secondary .btn-sub { color: var(--text-muted); }

/* --- Cards (single-pane, 1px border, no shadow) ------------------------ */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
}
.card-lg {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}

/* --- Inline pill / chip ------------------------------------------------- */
.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px;
  font-size: 11px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-muted);
  letter-spacing: 0.01em;
}
.pill .dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--success);
}
.pill.accent { color: var(--accent); background: var(--accent-soft); border-color: transparent; }
.pill.accent .dot { background: var(--accent); }

/* --- Brand mark big variant -------------------------------------------- */
.brand-mark-lg {
  width: 56px; height: 56px; border-radius: 14px;
  background: var(--accent); display: grid; place-items: center; color: #fff;
}
.brand-mark-lg svg { width: 32px; height: 32px; }

/* --- Drop zone (page-level mock, for the home hero) -------------------- */
.dz-mock {
  border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius-lg);
  padding: 36px 24px;
  text-align: center;
  background: var(--surface);
  transition: border-color 0.15s, background-color 0.15s;
}
.dz-mock:hover { border-color: var(--accent); background: var(--accent-soft); }
.dz-mock .dz-icon {
  width: 36px; height: 36px;
  margin: 0 auto 10px; display: block;
  color: var(--text-faint);
  transition: color 0.15s, transform 0.15s;
}
.dz-mock:hover .dz-icon { color: var(--accent); transform: translateY(-2px); }
.dz-mock .dz-title { font-size: 14px; font-weight: 600; color: var(--text); }
.dz-mock .dz-title em { font-style: normal; color: var(--accent); font-weight: 600; }
.dz-mock .dz-formats { font-size: 11.5px; color: var(--text-muted); margin-top: 6px; letter-spacing: 0.01em; }
.dz-mock .dz-tag { font-size: 11.5px; color: var(--text-faint); margin-top: 10px; font-style: italic; }

/* --- Reason grid (Why LocalPix) ---------------------------------------- */
.reasons {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
}
.reason {
  padding: 22px 22px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.reason:nth-child(2n) { border-right: none; }
.reason:nth-last-child(-n+2) { border-bottom: none; }
.reason h3 {
  font-size: 13px; font-weight: 600; color: var(--text);
  margin: 0 0 6px; letter-spacing: -0.005em;
}
.reason p {
  font-size: 12.5px; color: var(--text-muted); margin: 0; line-height: 1.55;
}
@media (max-width: 560px) {
  .reasons { grid-template-columns: 1fr; }
  .reason { border-right: none; }
  .reason:nth-last-child(2) { border-bottom: 1px solid var(--border); }
}

/* --- Format matrix ------------------------------------------------------ */
.fmt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 6px;
  background: var(--surface-2);
  padding: 6px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.fmt-cell {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 12px;
  display: flex; flex-direction: column; gap: 4px;
  min-width: 0;
}
.fmt-name {
  font-family: var(--font-mono);
  font-size: 12px; font-weight: 700; letter-spacing: 0.02em;
  color: var(--text);
}
.fmt-flags {
  display: flex; gap: 6px;
  font-size: 10px; font-family: var(--font-mono);
  color: var(--text-faint);
  letter-spacing: 0.04em; text-transform: uppercase;
}
.fmt-flag.read  { color: var(--text-muted); }
.fmt-flag.write { color: var(--accent); }
.fmt-flag.none  { color: var(--text-faint); text-decoration: line-through; opacity: 0.6; }

/* --- Compare table ----------------------------------------------------- */
.cmp-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 12.5px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.cmp-table th, .cmp-table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.cmp-table tr:last-child td { border-bottom: none; }
.cmp-table th {
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-muted);
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}
.cmp-table th.cmp-col-good {
  background: var(--success-soft);
  color: var(--success);
  border-bottom-color: var(--success);
}
.cmp-table th.cmp-col-bad {
  background: var(--danger-soft);
  color: var(--danger);
  border-bottom-color: var(--danger);
}
.cmp-col-label {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.02em;
}
.cmp-col-icon {
  width: 13px; height: 13px;
  display: inline-block;
}
.cmp-table td.cmp-good { background: color-mix(in oklab, var(--success-soft) 50%, transparent); }
.cmp-table td.cmp-bad  { background: color-mix(in oklab, var(--danger-soft)  35%, transparent); }
.cmp-table td.row-label {
  color: var(--text-muted);
  font-size: 12px;
  width: 30%;
}
.cmp-table td.cmp-good   { color: var(--text); }
.cmp-table td.cmp-bad    { color: var(--text-muted); }
.cmp-table .cmp-mark {
  display: inline-block; width: 14px; height: 14px;
  margin-right: 6px; vertical-align: -3px;
}
.cmp-table .cmp-mark.good { color: var(--success); }
.cmp-table .cmp-mark.bad  { color: var(--danger); }

/* --- Blog list ---------------------------------------------------------- */
.post-list { display: flex; flex-direction: column; }
.post-row {
  display: grid;
  grid-template-columns: 110px 1fr auto;
  gap: 20px;
  align-items: baseline;
  padding: 22px 0;
  border-bottom: 1px solid var(--border);
}
.post-row:last-child { border-bottom: none; }
.post-row .post-date {
  font-family: var(--font-mono);
  font-size: 11.5px; color: var(--text-faint);
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.post-row .post-body { min-width: 0; }
.post-row h3 {
  margin: 0 0 4px;
  font-size: 15px; font-weight: 600; color: var(--text);
  letter-spacing: -0.01em;
}
.post-row h3 a { color: var(--text); }
.post-row h3 a:hover { color: var(--accent); text-decoration: none; }
.post-row p {
  margin: 0;
  font-size: 12.5px; color: var(--text-muted); line-height: 1.55;
  max-width: 60ch;
}
.post-row .post-tag {
  font-family: var(--font-mono); font-size: 10.5px;
  font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--text-muted);
  padding: 3px 8px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 999px;
  white-space: nowrap;
}
@media (max-width: 600px) {
  .post-row { grid-template-columns: 1fr; gap: 4px; }
  .post-row .post-tag { justify-self: start; }
}

/* --- Post body --------------------------------------------------------- */
.post-meta {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-size: 11.5px; color: var(--text-faint);
  margin-bottom: 12px;
}
.post-meta .sep { color: var(--text-faint); }
.post-meta .post-tag {
  font-family: var(--font-mono); font-size: 10.5px;
  font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--text-muted);
  padding: 2px 8px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 999px;
}

.prose {
  max-width: 64ch;
  font-size: 14px; line-height: 1.65;
  color: var(--text);
}
.prose > * + * { margin-top: 16px; }
.prose h2 {
  font-size: 18px; font-weight: 600;
  letter-spacing: -0.015em;
  margin-top: 36px;
  color: var(--text);
}
.prose h3 {
  font-size: 14px; font-weight: 600;
  margin-top: 22px;
  color: var(--text);
}
.prose p { color: var(--text); }
.prose a { color: var(--accent); }
.prose strong { color: var(--text); font-weight: 600; }
.prose ul, .prose ol {
  padding-left: 22px;
  color: var(--text);
}
.prose li { margin-top: 6px; line-height: 1.55; }
.prose code {
  font-family: var(--font-mono);
  font-size: 12.5px;
  padding: 1px 6px;
  border-radius: 3px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
}
.prose blockquote {
  margin-left: 0; padding-left: 16px;
  border-left: 3px solid var(--border-strong);
  color: var(--text-muted);
  font-style: normal;
}
.prose .callout {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: 13px; color: var(--text);
  line-height: 1.55;
}
.prose .callout strong { color: var(--text); }

.post-nav {
  display: flex; gap: 14px; flex-wrap: wrap;
  margin-top: 56px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 12.5px;
}

/* --- About specifics --------------------------------------------------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}
@media (max-width: 720px) { .about-grid { grid-template-columns: 1fr; } }

.fact-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.fact-list li {
  display: grid; grid-template-columns: 90px 1fr; gap: 14px;
  font-size: 12.5px; color: var(--text);
}
.fact-list li .k {
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-muted);
}
.fact-list li .v code {
  font-family: var(--font-mono); font-size: 12px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 1px 6px;
  color: var(--text);
}

/* --- Download specifics ------------------------------------------------ */
.dl-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
@media (max-width: 600px) { .dl-grid { grid-template-columns: 1fr; } }
.dl-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  display: flex; flex-direction: column; gap: 12px;
}
.dl-card .dl-plat {
  display: flex; align-items: center; justify-content: space-between;
}
.dl-card .dl-plat .pname {
  font-size: 13px; font-weight: 600; color: var(--text);
}
.dl-card .dl-plat .parch {
  font-family: var(--font-mono); font-size: 10.5px;
  color: var(--text-muted);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 1px 6px;
}
.dl-card .dl-file {
  font-family: var(--font-mono); font-size: 11.5px;
  color: var(--text-muted); word-break: break-all;
}
.dl-card .dl-btn-row { display: flex; gap: 8px; flex-wrap: wrap; }

/* --- FAQ ---------------------------------------------------------------- */
.faq-list { display: flex; flex-direction: column; }
.faq-item {
  border-bottom: 1px solid var(--border);
  padding: 18px 0;
}
.faq-item:last-child { border-bottom: none; }
.faq-q {
  font-size: 14px; font-weight: 600; color: var(--text);
  letter-spacing: -0.005em;
  margin: 0 0 8px;
}
.faq-a {
  font-size: 13px; color: var(--text-muted); margin: 0; line-height: 1.6;
  max-width: 64ch;
}
.faq-a a { color: var(--accent); }

/* --- TOC ---------------------------------------------------------------- */
.toc {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  display: flex; flex-wrap: wrap; gap: 6px 14px;
  font-size: 12px;
}
.toc .toc-label {
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-muted);
}
.toc a { color: var(--text-muted); }
.toc a:hover { color: var(--text); text-decoration: none; }

/* --- Code block --------------------------------------------------------- */
.codeblock {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text);
  line-height: 1.6;
  overflow-x: auto;
  white-space: pre;
}

/* --- Tweaks panel (home page only) ------------------------------------- */
.tweaks-panel {
  position: fixed;
  right: 20px; bottom: 20px;
  width: 280px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 14px 12px;
  font-size: 12px;
  z-index: 80;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}
.tweaks-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 10px;
}
.tweaks-title {
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-muted);
}
.tweaks-close {
  background: transparent; border: 0; cursor: pointer;
  color: var(--text-muted); padding: 2px;
  display: grid; place-items: center;
  border-radius: 4px;
}
.tweaks-close:hover { color: var(--text); background: var(--surface-2); }
.tweaks-row { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.tweaks-row:last-child { margin-bottom: 0; }
.tweaks-row > label {
  font-size: 11px; font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-muted);
}
.tweaks-seg {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  background: var(--surface-2);
  padding: 4px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.tweaks-seg.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tweaks-seg button {
  background: transparent; border: 1px solid transparent;
  padding: 6px 4px; border-radius: 4px;
  font-size: 11px; font-weight: 600;
  color: var(--text-muted); cursor: pointer;
  font-family: inherit;
  transition: background-color 0.12s, color 0.12s, border-color 0.12s;
}
.tweaks-seg button:hover { color: var(--text); background: var(--surface); }
.tweaks-seg button.on {
  background: var(--surface); color: var(--accent);
  border-color: var(--border-strong);
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.tweaks-swatches { display: flex; gap: 6px; }
.tweaks-swatches button {
  width: 24px; height: 24px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer; padding: 0;
  outline: 1px solid var(--border);
  transition: outline-color 0.12s;
}
.tweaks-swatches button.on {
  outline: 2px solid var(--text);
  outline-offset: 1px;
}

/* --- Hero variants ----------------------------------------------------- */
[data-hero="a"] .hero-a,
[data-hero="b"] .hero-b,
[data-hero="c"] .hero-c,
[data-hero="d"] .hero-d {
  display: block;
}
.hero-a, .hero-b, .hero-c, .hero-d { display: none; }

/* Hero shared */
.hero {
  padding: 64px 0 56px;
}
.hero .pill { margin-bottom: 18px; }
.hero .web-lede { margin-top: 14px; }
.hero .hero-actions {
  display: flex; gap: 10px; flex-wrap: wrap;
  margin-top: 26px;
  align-items: center;
}
.hero .hero-actions .lp-faint { font-size: 11px; }

/* Variant A: screenshot hero (single column, centered) */
.hero-a {
  text-align: center;
}
.hero-a .hero-actions { justify-content: center; }
.hero-a .web-lede { margin-left: auto; margin-right: auto; }
.hero-a .hero-shot {
  margin-top: 44px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
}
.hero-a .hero-shot img { width: 100%; height: auto; display: block; }

/* Variant B: side-by-side copy + screenshot */
.hero-b {
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: 44px;
  align-items: center;
}
[data-hero="b"] .hero-b { display: grid; }
.hero-b .hero-shot {
  border-radius: 10px; overflow: hidden;
  border: 1px solid var(--border); background: var(--surface);
}
@media (max-width: 720px) {
  [data-hero="b"] .hero-b { grid-template-columns: 1fr; }
}

/* Variant C: animated drop zone teaser */
.hero-c { text-align: center; }
.hero-c .web-lede { margin-left: auto; margin-right: auto; }
.hero-c .hero-actions { justify-content: center; }
.hero-c .dz-mock {
  margin-top: 36px;
  padding: 56px 24px;
  position: relative;
  overflow: hidden;
}
.hero-c .dz-mock .dz-icon {
  width: 48px; height: 48px;
  animation: dz-bob 2.6s ease-in-out infinite;
}
@keyframes dz-bob {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-4px); }
}
.hero-c .dz-mock .dz-flow {
  display: flex; align-items: center; justify-content: center;
  gap: 10px; margin-top: 18px;
  font-family: var(--font-mono);
  font-size: 11px; color: var(--text-muted);
  letter-spacing: 0.04em;
}
.hero-c .dz-flow .arr { color: var(--text-faint); }
.hero-c .dz-flow .from { color: var(--text-muted); }
.hero-c .dz-flow .to   { color: var(--accent); font-weight: 700; }

/* Variant D: minimal */
.hero-d { text-align: center; padding: 96px 0 80px; }
.hero-d .brand-mark-lg { margin: 0 auto 22px; }
.hero-d .web-lede { margin: 16px auto 0; }
.hero-d .hero-actions { justify-content: center; }

/* --- Sticky-ish app preview (variant A bottom) ------------------------ */
.shot-wrap {
  position: relative;
  padding: 14px;
  background: linear-gradient(180deg, var(--surface-2), transparent 70%);
  border-radius: var(--radius-lg);
}
/* --bare: keeps the padding (spacing under the buttons) but removes the
   container styling — the screenshot already has its own bordered card. */
.shot-wrap.shot-wrap--bare {
  background: transparent;
  border-radius: 0;
}

/* --- Misc -------------------------------------------------------------- */
.kbd {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
}
.lead-quote {
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: 1.55;
  max-width: 60ch;
}
