/* ==========================================================================
   Recit website — one stylesheet for every page.
   Dark theme, purple accents. Sections: tokens, base, layout, header,
   buttons, home page sections, legal pages, footer, motion, print.
   ========================================================================== */

/* ---- Fonts (Manrope, SIL OFL: assets/fonts/OFL.txt) --------------------- */
@font-face { font-family: "Manrope"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/manrope-regular.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/manrope-semibold.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/manrope-bold.woff2") format("woff2"); }

/* ---- Tokens -------------------------------------------------------------- */
:root {
  --bg: #0b0a12;
  --bg-2: #100e19;
  --surface: #15121f;
  --surface-2: #1c1829;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --text: #eeecf6;
  --muted: #a9a4bc;
  --accent: #8b6cff;          /* icons, highlights */
  --accent-text: #b9a2ff;     /* purple text on dark (9:1) */
  --accent-strong: #6d3cf0;   /* buttons, white text on it (5.9:1) */
  --accent-soft: rgba(139, 108, 255, 0.14);
  --rec: #ff5a4e;             /* the record dot, as in the app icon */
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 20px 60px -24px rgba(0, 0, 0, 0.65);
  --container: 1160px;
  --gutter: 20px;
  --header-h: 68px;
  --font: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}
@media (min-width: 768px) { :root { --gutter: 32px; } }

/* ---- Base ---------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.65 var(--font);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--accent-text); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: #d4c7ff; }
h1, h2, h3, h4 { margin: 0 0 0.5em; line-height: 1.2; font-weight: 700; letter-spacing: -0.02em; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.3em; }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; border-radius: 6px; }
::selection { background: rgba(139, 108, 255, 0.35); }

.icon { width: 22px; height: 22px; flex: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -48px; z-index: 100; padding: 10px 14px; border-radius: 10px; background: var(--accent-strong); color: #fff; font-weight: 600; text-decoration: none; }
.skip-link:focus { top: 12px; color: #fff; }

/* ---- Layout -------------------------------------------------------------- */
.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: 88px 0; position: relative; }
.section--tight { padding: 56px 0; }
.section--alt { background: var(--bg-2); border-block: 1px solid var(--line); }
@media (max-width: 767px) { .section { padding: 64px 0; } }

.section-head { max-width: 680px; margin: 0 auto 48px; text-align: center; }
.section-head h2 { font-size: clamp(28px, 4vw, 40px); }
.section-head p { color: var(--muted); font-size: 17px; margin: 0; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  margin-bottom: 16px; padding: 6px 12px; border-radius: 999px;
  background: var(--accent-soft); border: 1px solid rgba(139, 108, 255, 0.28);
  color: var(--accent-text); font-size: 13px; font-weight: 600; letter-spacing: 0.01em;
}
.gradient-text {
  background: linear-gradient(100deg, #c4b2ff 0%, #9d7bff 45%, #d08bff 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---- Header -------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 10, 18, 0.72);
  -webkit-backdrop-filter: saturate(160%) blur(14px); backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); background: rgba(11, 10, 18, 0.88); }
.header-inner { display: flex; align-items: center; gap: 24px; height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; font-size: 20px; letter-spacing: -0.02em; }
.brand:hover { color: var(--text); }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.nav a { color: var(--muted); text-decoration: none; font-weight: 600; font-size: 15px; padding: 8px 12px; border-radius: 10px; transition: color 0.15s ease, background-color 0.15s ease; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.nav .btn { margin-left: 8px; color: #fff; }
.nav-toggle { display: none; margin-left: auto; width: 44px; height: 44px; border: 1px solid var(--line-2); border-radius: 12px; background: transparent; color: var(--text); cursor: pointer; align-items: center; justify-content: center; }
.nav-toggle .icon-close { display: none; }

@media (max-width: 899px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0; z-index: 49;
    flex-direction: column; align-items: stretch; gap: 2px;
    padding: 12px var(--gutter) 20px; background: rgba(11, 10, 18, 0.97);
    border-bottom: 1px solid var(--line);
    transform: translateY(-8px); opacity: 0; visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  }
  .nav a { padding: 12px 14px; font-size: 16px; }
  .nav .btn { margin: 10px 0 0; justify-content: center; }
  .site-header.is-open .nav { transform: none; opacity: 1; visibility: visible; }
  .site-header.is-open .nav-toggle .icon-menu { display: none; }
  .site-header.is-open .nav-toggle .icon-close { display: block; }
  /* Without JavaScript the menu can't open, so show it in place. */
  .no-js .nav { position: static; opacity: 1; visibility: visible; transform: none; flex-direction: row; flex-wrap: wrap; padding: 0; background: none; border: 0; }
  .no-js .nav-toggle { display: none; }
  .no-js .header-inner { flex-wrap: wrap; height: auto; padding: 12px 0; }
}

/* ---- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 22px; border-radius: 14px;
  font: 600 16px/1 var(--font); text-decoration: none; cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.15s ease, background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.2s ease;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: linear-gradient(135deg, #7446f5 0%, #6d3cf0 55%, #6233e0 100%); color: #fff; box-shadow: 0 10px 30px -12px rgba(109, 60, 240, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.18); }
.btn--primary:hover { color: #fff; box-shadow: 0 14px 36px -12px rgba(109, 60, 240, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.22); transform: translateY(-1px); }
.btn--ghost { background: rgba(255, 255, 255, 0.04); color: var(--text); border-color: var(--line-2); }
.btn--ghost:hover { color: var(--text); background: rgba(255, 255, 255, 0.08); }
.btn--sm { min-height: 40px; padding: 0 16px; font-size: 15px; border-radius: 12px; }
.btn .icon { width: 20px; height: 20px; }

/* The Google Play button: two-line label, like a store badge. */
.btn--store { min-height: 56px; padding: 0 22px 0 18px; gap: 12px; text-align: left; }
.btn--store .icon { width: 24px; height: 24px; }
.btn--store small { display: block; font-size: 12px; font-weight: 600; opacity: 0.85; letter-spacing: 0.02em; margin-bottom: 3px; }
.btn--store strong { display: block; font-size: 18px; font-weight: 700; letter-spacing: -0.01em; }

/* ---- Hero ---------------------------------------------------------------- */
.hero { position: relative; padding: 72px 0 88px; overflow: hidden; isolation: isolate; }
.hero::before, .hero::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; filter: blur(10px); pointer-events: none; }
.hero::before { width: 720px; height: 720px; right: -180px; top: -220px; background: radial-gradient(closest-side, rgba(124, 77, 255, 0.30), transparent 70%); }
.hero::after { width: 520px; height: 520px; left: -260px; top: 10%; background: radial-gradient(closest-side, rgba(168, 85, 247, 0.12), transparent 70%); }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; align-items: center; gap: 56px; }
.hero h1 { font-size: clamp(38px, 6vw, 64px); line-height: 1.06; letter-spacing: -0.035em; margin-bottom: 20px; }
.hero .lead { font-size: clamp(17px, 2vw, 19px); color: var(--muted); max-width: 560px; margin-bottom: 32px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 28px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 0; padding: 0; list-style: none; color: var(--muted); font-size: 14px; font-weight: 600; }
.hero-meta li { display: inline-flex; align-items: center; gap: 8px; }
.hero-meta .icon { width: 18px; height: 18px; color: var(--accent); }
@media (max-width: 899px) {
  .hero { padding: 40px 0 64px; }
  .hero-grid { grid-template-columns: 1fr; gap: 48px; text-align: center; }
  .hero .lead { margin-inline: auto; }
  .hero-actions, .hero-meta { justify-content: center; }
}

/* A phone drawn in CSS, holding a real app screen. */
.device-wrap { position: relative; display: flex; justify-content: center; }
.device {
  position: relative; width: min(300px, 74vw); aspect-ratio: 648 / 1382;
  padding: 10px; border-radius: 46px;
  background: linear-gradient(160deg, #2b2640, #15121f 40%, #0d0b15);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08), 0 40px 80px -30px rgba(0, 0, 0, 0.8), 0 0 120px -20px rgba(124, 77, 255, 0.35);
}
.device img { width: 100%; height: 100%; object-fit: cover; border-radius: 36px; }
.device::after { content: ""; position: absolute; top: 20px; left: 50%; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: #05040a; }
.float-chip {
  position: absolute; display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 14px; border-radius: 14px;
  background: rgba(21, 18, 31, 0.86); border: 1px solid var(--line-2);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  box-shadow: var(--shadow); font-size: 14px; font-weight: 600; white-space: nowrap;
  animation: float 6s ease-in-out infinite;
}
.float-chip .icon { width: 18px; height: 18px; color: var(--accent-text); }
.float-chip--rec { top: 14%; left: calc(50% - 230px); }
.float-chip--rec .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--rec); box-shadow: 0 0 0 4px rgba(255, 90, 78, 0.18); }
.float-chip--cam { top: 46%; right: calc(50% - 250px); animation-delay: -2s; }
.float-chip--fps { bottom: 9%; left: calc(50% - 232px); animation-delay: -4s; }
.tnum { font-variant-numeric: tabular-nums; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@media (max-width: 520px) {
  .float-chip { font-size: 13px; padding: 8px 11px; }
  .float-chip--rec { left: 0; }
  .float-chip--cam { right: 0; }
  .float-chip--fps { left: 4px; }
}

/* ---- Highlights strip ---------------------------------------------------- */
.highlights { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.highlight { background: var(--surface); padding: 24px; }
.highlight strong { display: block; font-size: 20px; letter-spacing: -0.02em; margin-bottom: 4px; }
.highlight span { color: var(--muted); font-size: 14px; }
@media (max-width: 899px) { .highlights { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .highlight { padding: 18px; } .highlight strong { font-size: 17px; } }

/* ---- Feature cards ------------------------------------------------------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 999px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 639px) { .cards { grid-template-columns: 1fr; } }
.card {
  position: relative; padding: 26px; border-radius: var(--radius);
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover { border-color: rgba(139, 108, 255, 0.35); transform: translateY(-3px); box-shadow: var(--shadow); }
.card h3 { font-size: 19px; margin: 18px 0 8px; }
.card p { color: var(--muted); margin: 0; font-size: 15px; }
.icon-tile { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 14px; background: var(--accent-soft); border: 1px solid rgba(139, 108, 255, 0.25); color: var(--accent-text); }
.icon-tile .icon { width: 24px; height: 24px; }

/* ---- Editor rows (text beside a screenshot) ------------------------------ */
.rows { display: grid; gap: 96px; }
.row { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 64px; }
.row:nth-child(even) .row-media { order: -1; }
.row h3 { font-size: clamp(26px, 3.4vw, 34px); letter-spacing: -0.03em; }
.row p { color: var(--muted); font-size: 17px; }
.row-media { position: relative; display: flex; justify-content: center; }
.row-media::before { content: ""; position: absolute; inset: 10% 6%; z-index: 0; border-radius: 50%; background: radial-gradient(closest-side, rgba(124, 77, 255, 0.28), transparent 72%); }
.shot-card { position: relative; z-index: 1; width: min(420px, 100%); border-radius: 26px; overflow: hidden; border: 1px solid var(--line-2); box-shadow: var(--shadow); background: #141a28; }
.ticks { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; }
.ticks li { display: flex; gap: 10px; align-items: flex-start; color: var(--text); font-weight: 600; font-size: 15px; }
.ticks .icon { width: 20px; height: 20px; margin-top: 2px; color: var(--accent-text); }
@media (max-width: 899px) {
  .rows { gap: 72px; }
  .row { grid-template-columns: 1fr; gap: 32px; }
  .row:nth-child(even) .row-media { order: 0; }
  .row-text { text-align: center; }
  .ticks { justify-content: center; }
  .ticks li { justify-content: center; }
}

.mini-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 88px; }
.mini { display: flex; gap: 16px; padding: 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.mini h3 { font-size: 17px; margin: 0 0 4px; }
.mini p { margin: 0; color: var(--muted); font-size: 15px; }
@media (max-width: 899px) { .mini-grid { grid-template-columns: 1fr; margin-top: 64px; } }

/* ---- Screenshot gallery -------------------------------------------------- */
.gallery { position: relative; }
.shots {
  display: grid; grid-auto-flow: column; grid-auto-columns: clamp(200px, 23vw, 250px); gap: 18px;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter);
  padding: 8px var(--gutter) 24px; margin: 0; list-style: none;
  scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}
.shots::-webkit-scrollbar { height: 8px; }
.shots::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.16); border-radius: 8px; }
.shots li { scroll-snap-align: start; }
.shots figure { margin: 0; }
.shots img { width: 100%; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 20px; border: 1px solid var(--line-2); background: #141a28; }
.shots figcaption { margin-top: 10px; color: var(--muted); font-size: 14px; font-weight: 600; text-align: center; }
.gallery-controls { display: flex; justify-content: center; gap: 12px; margin-top: 8px; }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.04); color: var(--text); cursor: pointer; transition: background-color 0.15s ease, border-color 0.15s ease; }
.icon-btn:hover { background: rgba(255, 255, 255, 0.09); border-color: rgba(139, 108, 255, 0.45); }
.icon-btn:disabled { opacity: 0.35; cursor: default; }
.no-js .gallery-controls { display: none; }
@media (min-width: 1240px) { .shots { padding-inline: calc((100vw - var(--container)) / 2); scroll-padding-inline: calc((100vw - var(--container)) / 2); } }

/* ---- Privacy band -------------------------------------------------------- */
.band {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 28px;
  padding: 36px; border-radius: 24px;
  background: radial-gradient(120% 140% at 0% 0%, rgba(124, 77, 255, 0.22), transparent 55%), var(--surface);
  border: 1px solid rgba(139, 108, 255, 0.25);
}
.band h2 { font-size: clamp(24px, 3vw, 30px); margin-bottom: 8px; }
.band p { color: var(--muted); margin: 0; }
.band .icon-tile { width: 64px; height: 64px; border-radius: 18px; }
.band .icon-tile .icon { width: 30px; height: 30px; }
.band-points { display: flex; flex-wrap: wrap; gap: 8px 20px; list-style: none; padding: 0; margin: 14px 0 0; }
.band-points li { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; }
.band-points .icon { width: 18px; height: 18px; color: var(--accent-text); }
@media (max-width: 899px) { .band { grid-template-columns: 1fr; text-align: center; padding: 28px 22px; justify-items: center; } .band-points { justify-content: center; } }

/* ---- FAQ ----------------------------------------------------------------- */
.faq { max-width: 820px; margin: 0 auto; display: grid; gap: 12px; }
.faq details { border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); transition: border-color 0.2s ease; }
.faq details[open] { border-color: rgba(139, 108, 255, 0.35); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 20px; cursor: pointer; list-style: none; font-weight: 600; font-size: 17px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .icon { color: var(--muted); transition: transform 0.2s ease; }
.faq details[open] summary .icon { transform: rotate(180deg); color: var(--accent-text); }
.faq .answer { padding: 0 20px 18px; color: var(--muted); }
.faq .answer p:last-child { margin: 0; }

/* ---- Support ------------------------------------------------------------- */
.support { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.support .card { display: flex; flex-direction: column; }
.support .card p { flex: 1; }
.support .card .link { margin-top: 18px; display: inline-flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; word-break: break-word; }
.support .card .link .icon { width: 18px; height: 18px; }
.support .card .link a { text-decoration: none; }
@media (max-width: 899px) { .support { grid-template-columns: 1fr; } }

/* ---- Closing call to action ---------------------------------------------- */
.cta {
  position: relative; overflow: hidden; isolation: isolate; text-align: center;
  padding: 64px 24px; border-radius: 28px; border: 1px solid rgba(139, 108, 255, 0.3);
  background: linear-gradient(160deg, #1d1736 0%, #140f26 60%, #110d1e 100%);
}
.cta::before { content: ""; position: absolute; z-index: -1; inset: -40% 10% auto; height: 120%; background: radial-gradient(closest-side, rgba(124, 77, 255, 0.35), transparent 70%); }
.cta img { width: 72px; height: 72px; border-radius: 18px; margin: 0 auto 22px; box-shadow: 0 16px 40px -16px rgba(0, 0, 0, 0.8); }
.cta h2 { font-size: clamp(28px, 4vw, 42px); }
.cta p { color: var(--muted); max-width: 520px; margin: 0 auto 28px; font-size: 17px; }

/* ---- Footer -------------------------------------------------------------- */
.site-footer { border-top: 1px solid var(--line); padding: 56px 0 32px; background: var(--bg-2); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.footer-grid p { color: var(--muted); font-size: 15px; max-width: 360px; margin-top: 14px; }
.footer-grid h2 { font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-links a { color: var(--text); text-decoration: none; font-weight: 600; font-size: 15px; }
.footer-links a:hover { color: var(--accent-text); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 44px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.footer-bottom p { margin: 0; }
@media (max-width: 767px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > :first-child { grid-column: 1 / -1; } }

.to-top { position: fixed; right: 18px; bottom: 18px; z-index: 40; opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s; background: rgba(21, 18, 31, 0.9); }
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }

/* ---- Legal pages --------------------------------------------------------- */
.doc-hero { padding: 56px 0 40px; border-bottom: 1px solid var(--line); background: radial-gradient(80% 120% at 100% 0%, rgba(124, 77, 255, 0.16), transparent 60%); }
.doc-hero h1 { font-size: clamp(34px, 5vw, 48px); letter-spacing: -0.03em; margin-bottom: 12px; }
.doc-hero p { color: var(--muted); max-width: 720px; margin: 0; font-size: 17px; }
.doc-meta { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 20px; color: var(--muted); font-size: 14px; font-weight: 600; }
.doc-meta span strong { color: var(--text); }
.doc-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 56px; padding-top: 48px; padding-bottom: 88px; }
.toc { position: sticky; top: calc(var(--header-h) + 24px); align-self: start; max-height: calc(100vh - var(--header-h) - 48px); overflow: auto; }
.toc h2 { font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a::before { content: counter(toc) ". "; color: var(--accent-text); font-variant-numeric: tabular-nums; }
.toc a { display: block; padding: 6px 10px; border-radius: 8px; color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 600; line-height: 1.4; }
.toc a:hover, .toc a.is-active { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.toc a.is-active { box-shadow: inset 2px 0 0 var(--accent); }
.doc { max-width: 780px; counter-reset: sec; }
.doc section { padding-top: 8px; margin-bottom: 40px; }
.doc h2 { font-size: 24px; margin-bottom: 14px; padding-top: 8px; counter-increment: sec; }
.doc h2::before { content: counter(sec) ". "; color: var(--accent-text); }
.doc h3 { font-size: 18px; margin: 24px 0 8px; }
.doc p, .doc li { color: #d6d3e4; }
.doc li { margin-bottom: 6px; }
.doc strong { color: var(--text); }
.doc code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.86em; padding: 2px 6px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); color: var(--text); word-break: break-word; }
.summary-box { margin: 0 0 40px; padding: 22px 24px; border-radius: var(--radius); background: var(--surface); border: 1px solid rgba(139, 108, 255, 0.28); }
.summary-box h2 { font-size: 18px; margin-bottom: 10px; counter-increment: none; }
.summary-box h2::before { content: none; }
.summary-box ul { margin: 0; }
.table-wrap { overflow-x: auto; margin: 0 0 1.2em; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.doc table { width: 100%; border-collapse: collapse; font-size: 15px; }
.doc td:first-child { width: 34%; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.doc th { background: var(--surface-2); color: var(--text); font-weight: 700; font-size: 14px; }
.doc td { color: #d6d3e4; }
.doc tr:last-child td { border-bottom: 0; }
@media (max-width: 899px) {
  .doc-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; padding-top: 28px; }
  .toc { position: static; max-height: none; padding: 18px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); }
}

/* ---- Not found ----------------------------------------------------------- */
.not-found { min-height: 60vh; display: grid; place-items: center; text-align: center; padding: 80px 0; }
.not-found h1 { font-size: clamp(40px, 7vw, 72px); }
.not-found p { color: var(--muted); }

/* ---- Motion: content fades up as it scrolls in (only with JavaScript) ---- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1); }
.js .reveal.is-visible { opacity: 1; transform: none; }
.js .reveal[data-delay="1"] { transition-delay: 0.08s; }
.js .reveal[data-delay="2"] { transition-delay: 0.16s; }
.js .reveal[data-delay="3"] { transition-delay: 0.24s; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---- Print (legal pages) ------------------------------------------------- */
@media print {
  :root { color-scheme: light; }
  body { background: #fff; color: #000; font-size: 12pt; }
  .site-header, .site-footer, .toc, .to-top, .skip-link { display: none !important; }
  .doc-hero { background: none; border: 0; padding: 0 0 12pt; }
  .doc-layout { display: block; padding: 0; }
  .doc p, .doc li, .doc td, .doc-hero p, .doc-meta { color: #000; }
  .doc h2::before { color: #000; }
  a { color: #000; }
  .summary-box, .table-wrap { border-color: #999; background: none; }
  .doc th { background: #eee; color: #000; }
}
