/* ==========================================================================
   calinsirian.com — Calin Sirian, independent app developer
   Design language borrowed from lumiere-camera.com: black stage, one accent,
   display sans + italic serif, mono eyebrows, and a theme picker that re-skins
   the whole site. Each app chapter carries its own brand color (--app).
   ========================================================================== */

@font-face { font-family: "Inter"; src: url("../fonts/inter-var.woff2") format("woff2"); font-weight: 300 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("../fonts/instrument-serif.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("../fonts/instrument-serif-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("../fonts/jetbrains-mono-var.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Orbitron"; src: url("../fonts/orbitron-var.woff2") format("woff2"); font-weight: 600 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Oxanium"; src: url("../fonts/oxanium-var.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }

:root {
  --bg: #000;
  --bg-2: #070707;
  --bg-3: #0e0e0e;
  --surface: rgba(255, 255, 255, 0.035);
  --surface-2: rgba(255, 255, 255, 0.065);
  --glass: rgba(18, 18, 18, 0.62);
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.15);
  --text: rgba(255, 255, 255, 0.9);
  --text-2: rgba(255, 255, 255, 0.6);
  --text-3: rgba(255, 255, 255, 0.4);
  --accent: #d6b063;
  --accent-hi: #f3dca0;
  --accent-ink: #000;
  --accent-rgb: 214, 176, 99;
  --glow: rgba(214, 176, 99, 0.35);
  --shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.85);

  --font-display: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", sans-serif;
  --font-text: "SF Pro Text", -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --font-serif: "Instrument Serif", "Times New Roman", serif;

  --gutter: clamp(16px, 4vw, 48px);
  --max: 1240px;
  --radius: 22px;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  color-scheme: dark;
}

/* ---- Themes ------------------------------------------------------------ */
:root[data-theme="silver"]   { --accent: #c9c9d1; --accent-hi: #f1f1f6; --accent-rgb: 201,201,209; --glow: rgba(201,201,209,.26); --bg: #080809; --bg-2: #0d0d0f; --bg-3: #141416; }
:root[data-theme="midnight"] { --accent: #7c9cf0; --accent-hi: #b9cbfa; --accent-rgb: 124,156,240; --accent-ink: #fff; --glow: rgba(124,156,240,.34); --bg: #04071a; --bg-2: #080c24; --bg-3: #0e1430; --glass: rgba(10,14,36,.62); }
:root[data-theme="aurora"]   { --accent: #5fd6a8; --accent-hi: #b5f3da; --accent-rgb: 95,214,168; --glow: rgba(95,214,168,.3); --bg: #020d0a; --bg-2: #04140f; --bg-3: #081c16; --glass: rgba(6,22,17,.62); }
:root[data-theme="ember"]    { --accent: #f59a52; --accent-hi: #fbc999; --accent-rgb: 245,154,82; --glow: rgba(245,154,82,.32); --bg: #0c0603; --bg-2: #130a05; --bg-3: #1b0f08; --glass: rgba(26,14,8,.62); }
:root[data-theme="rose"]     { --accent: #dc9c8c; --accent-hi: #f4cdbf; --accent-rgb: 220,156,140; --glow: rgba(220,156,140,.3); --bg: #0b0506; --bg-2: #110809; --bg-3: #190c0d; --glass: rgba(26,12,13,.62); }
:root[data-theme="deepspace"] {
  --accent: #72ddf7; --accent-hi: #c4f2fd; --accent-rgb: 114,221,247; --accent-ink: #080e1c; --glow: rgba(114,221,247,.32);
  --bg: #080e1c; --bg-2: #0b1324; --bg-3: #101b2f; --glass: rgba(11,19,36,.7);
  --surface: rgba(16, 27, 47, 0.6); --surface-2: rgba(24, 40, 68, 0.7);
  --line: #1a2944; --line-2: #243653;
  --text: #edf4ff; --text-2: #b4c3da; --text-3: #8399b8;
  --font-display: "Orbitron", "Oxanium", var(--font-text);
  --font-mono: "Oxanium", ui-monospace, monospace;
}
:root[data-theme="paper"] {
  color-scheme: light;
  --accent: #8a6220; --accent-hi: #b98a3c; --accent-rgb: 138,98,32; --accent-ink: #fff; --glow: rgba(138,98,32,.18);
  --bg: #f4f1ea; --bg-2: #ece8de; --bg-3: #e3ded1; --glass: rgba(244,241,234,.72);
  --surface: rgba(0,0,0,.035); --surface-2: rgba(0,0,0,.06);
  --line: rgba(0,0,0,.1); --line-2: rgba(0,0,0,.17);
  --text: rgba(20,16,10,.9); --text-2: rgba(20,16,10,.64); --text-3: rgba(20,16,10,.46);
  --shadow: 0 30px 70px -34px rgba(60,40,10,.45);
}

/* ---- Base ---------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 var(--font-text);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color .6s var(--ease), color .6s var(--ease);
}
main, .footer { overflow-x: clip; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--accent); color: var(--accent-ink); padding: 10px 16px; border-radius: 10px; font-weight: 600; }
.skip:focus { top: 12px; }

/* ---- Type ------------------------------------------------------------------ */
.eyebrow {
  font: 600 12px/1.2 var(--font-mono);
  letter-spacing: .22em; text-transform: uppercase;
  color: var(--accent);
  display: inline-flex; align-items: center; gap: 10px;
}
.eyebrow::before { content: ""; width: 22px; height: 1px; background: currentColor; opacity: .7; }
.eyebrow.plain::before { display: none; }
.h-display {
  font: 650 clamp(52px, 9vw, 128px)/0.92 var(--font-display);
  letter-spacing: -0.04em; margin: 0;
}
.h-section {
  font: 650 clamp(36px, 5.2vw, 68px)/1.02 var(--font-display);
  letter-spacing: -0.03em; margin: 18px 0 0;
  text-wrap: balance;
}
:root[data-theme="deepspace"] .h-display { letter-spacing: -0.02em; font-weight: 700; font-size: clamp(40px, 7.4vw, 104px); }
:root[data-theme="deepspace"] .h-section { letter-spacing: -0.01em; font-weight: 700; }
.serif { font-family: var(--font-serif); font-style: italic; font-weight: 400; letter-spacing: -0.01em; }
.accent { color: var(--accent); }
.grad {
  background: linear-gradient(100deg, var(--accent) 0%, var(--accent-hi) 45%, var(--accent) 70%, var(--accent-hi) 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: sheen 7s linear infinite;
}
@keyframes sheen { to { background-position: -220% 0; } }
.lede { font-size: clamp(17px, 1.55vw, 20px); color: var(--text-2); max-width: 640px; margin: 22px 0 0; text-wrap: pretty; }
.mono { font-family: var(--font-mono); }
.label { font: 600 11px/1.2 var(--font-mono); letter-spacing: .2em; text-transform: uppercase; color: var(--text-3); }
.section-head { max-width: 760px; }
.section-head.center { margin: 0 auto; text-align: center; }
.section-head.center .lede { margin-left: auto; margin-right: auto; }

/* Split-word headline reveal */
.split .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .16em; margin-bottom: -.16em; }
.split .w > span { display: inline-block; transform: translateY(105%); transition: transform 1s var(--ease); transition-delay: calc(var(--i, 0) * 70ms + 120ms); }
.split.in .w > span { transform: none; }

/* ---- Buttons & chips ------------------------------------------------------ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 52px; padding: 0 24px; border-radius: 999px;
  font: 600 15px/1 var(--font-text); letter-spacing: -0.005em;
  transition: transform .3s var(--ease), background-color .3s, color .3s, box-shadow .3s, border-color .3s;
  white-space: nowrap;
}
.btn svg { width: 16px; height: 16px; flex: none; }
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 12px 40px -12px var(--glow); }
.btn-primary:hover { background: var(--accent-hi); box-shadow: 0 16px 50px -10px var(--glow); }
.btn-ghost { border: 1px solid var(--line-2); color: var(--text); background: var(--surface); }
.btn-ghost:hover { border-color: rgba(var(--accent-rgb), .6); background: var(--surface-2); }
.btn-sm { height: 40px; padding: 0 16px; font-size: 14px; }
.btn-app { background: var(--app, var(--accent)); color: var(--app-ink, #000); box-shadow: 0 12px 40px -14px rgba(var(--app-rgb, var(--accent-rgb)), .7); }
.btn-app:hover { filter: brightness(1.08); box-shadow: 0 16px 50px -12px rgba(var(--app-rgb, var(--accent-rgb)), .8); }
.btn-store { background: var(--text); color: var(--bg); }
.btn-store:hover { background: var(--accent-hi); color: #000; }
:root[data-theme="paper"] .btn-store { background: #141008; color: #f4f1ea; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  height: 32px; padding: 0 13px; border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--surface);
  font: 500 13px/1 var(--font-text); color: var(--text-2);
  white-space: nowrap;
}
.chip svg { width: 14px; height: 14px; opacity: .85; }
.chip .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--app, var(--accent)); box-shadow: 0 0 10px var(--app, var(--accent)); }

/* ---- Nav ------------------------------------------------------------------ */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  transition: background-color .4s var(--ease), border-color .4s, backdrop-filter .4s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled { background: var(--glass); -webkit-backdrop-filter: saturate(160%) blur(20px); backdrop-filter: saturate(160%) blur(20px); border-bottom-color: var(--line); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 12px; font: 650 17px/1 var(--font-display); letter-spacing: -0.01em; }
:root[data-theme="deepspace"] .brand { font-size: 14px; letter-spacing: .04em; }
.mark {
  width: 34px; height: 34px; border-radius: 10px; flex: none;
  display: grid; place-items: center;
  background: radial-gradient(120% 120% at 20% 10%, var(--accent-hi), var(--accent) 45%, rgba(var(--accent-rgb), .55));
  color: var(--accent-ink);
  font: italic 400 21px/1 var(--font-serif); letter-spacing: -0.04em;
  box-shadow: 0 6px 24px -8px var(--glow), inset 0 1px 0 rgba(255,255,255,.35);
}
/* Portrait avatar: a cut-out photo standing in front of a glow in the theme's accent */
.avatar {
  position: relative; width: 40px; height: 40px; border-radius: 50%; flex: none; overflow: hidden;
  background: radial-gradient(110% 110% at 50% 16%, var(--accent-hi) 0%, var(--accent) 46%, rgba(var(--accent-rgb), .5) 100%);
  box-shadow: 0 0 0 2px var(--bg), 0 0 0 3.5px rgba(var(--accent-rgb), .7), 0 8px 26px -8px var(--glow);
  transition: transform .45s var(--ease-spring), box-shadow .3s var(--ease);
}
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.brand:hover .avatar { transform: scale(1.08) rotate(-4deg); box-shadow: 0 0 0 2px var(--bg), 0 0 0 3.5px var(--accent), 0 10px 30px -6px var(--glow); }
.avatar.lg { width: 60px; height: 60px; box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px rgba(var(--accent-rgb), .7), 0 12px 34px -10px var(--glow); }
.brand-txt { display: flex; flex-direction: column; gap: 5px; }
.brand-txt b { font-weight: 650; }
.brand-txt small { font: 500 10px/1 var(--font-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--text-3); }
:root[data-theme="deepspace"] .brand-txt small { letter-spacing: .12em; }
.nav-links { display: flex; align-items: center; gap: 30px; font-size: 14.5px; color: var(--text-2); }
.nav-links a { transition: color .25s; position: relative; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); }
.nav-links a[aria-current="page"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -8px; height: 2px; border-radius: 2px; background: var(--accent); }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.nav-progress { position: absolute; left: 0; bottom: -1px; height: 2px; width: 100%; transform-origin: 0 50%; transform: scaleX(var(--p, 0)); background: var(--nav-color, var(--accent)); transition: background-color .5s; opacity: .9; }

.theme-btn {
  height: 40px; padding: 0 12px 0 10px; border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--surface);
  display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--text-2);
  transition: border-color .3s, color .3s;
}
.theme-btn:hover, .theme-btn[aria-expanded="true"] { border-color: rgba(var(--accent-rgb), .6); color: var(--text); }
.theme-btn .sw { width: 18px; height: 18px; border-radius: 50%; background: conic-gradient(from 200deg, var(--accent), var(--accent-hi), var(--accent)); box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px rgba(var(--accent-rgb), .6); }
.menu-btn { display: none; width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--surface); align-items: center; justify-content: center; }
.menu-btn svg { width: 18px; height: 18px; }

.theme-pop {
  position: fixed; z-index: 120; top: 76px; right: max(var(--gutter), calc((100vw - var(--max)) / 2 + var(--gutter)));
  width: 280px; padding: 10px; border-radius: 20px;
  background: var(--glass); -webkit-backdrop-filter: saturate(160%) blur(24px); backdrop-filter: saturate(160%) blur(24px);
  border: 1px solid var(--line-2); box-shadow: var(--shadow);
  opacity: 0; transform: translateY(-8px) scale(.98); pointer-events: none; transition: opacity .25s var(--ease), transform .3s var(--ease);
}
.theme-pop.open { opacity: 1; transform: none; pointer-events: auto; }
.theme-pop .label { padding: 8px 10px 10px; display: block; }
.theme-opt { width: 100%; display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 12px; font-size: 14.5px; text-align: left; color: var(--text-2); transition: background-color .2s, color .2s; }
.theme-opt:hover { background: var(--surface-2); color: var(--text); }
.theme-opt[aria-checked="true"] { color: var(--text); background: var(--surface-2); }
.theme-opt .sw { width: 22px; height: 22px; border-radius: 50%; flex: none; background: var(--sw-bg); box-shadow: inset 0 0 0 6px var(--sw-bg), inset 0 0 0 30px var(--sw-ac), 0 0 0 1px var(--line-2); }
.theme-opt .chk { margin-left: auto; width: 16px; height: 16px; opacity: 0; color: var(--accent); }
.theme-opt[aria-checked="true"] .chk { opacity: 1; }
.theme-pop .hint { display: block; padding: 8px 10px 4px; font-size: 12px; color: var(--text-3); }
.theme-pop kbd { font: 600 11px/1 var(--font-mono); padding: 3px 6px; border-radius: 6px; border: 1px solid var(--line-2); }

.mobile-menu {
  position: fixed; inset: 72px 0 auto 0; z-index: 99;
  background: var(--glass); -webkit-backdrop-filter: saturate(160%) blur(24px); backdrop-filter: saturate(160%) blur(24px);
  border-bottom: 1px solid var(--line); padding: 12px var(--gutter) 24px;
  display: none;
}
.mobile-menu.open { display: block; animation: drop .35s var(--ease); }
.mobile-menu a { display: flex; justify-content: space-between; align-items: center; padding: 16px 4px; border-bottom: 1px solid var(--line); font: 600 20px/1 var(--font-display); }
.mobile-menu a span { color: var(--text-3); font: 500 12px/1 var(--font-mono); letter-spacing: .14em; }
@keyframes drop { from { opacity: 0; transform: translateY(-10px); } }

/* ---- Ambient background ------------------------------------------------- */
.ambient { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.ambient::before {
  content: ""; position: absolute; inset: -20% -10% auto; height: 90vh;
  background: radial-gradient(50% 60% at 70% 20%, rgba(var(--accent-rgb), .16), transparent 70%),
              radial-gradient(40% 50% at 10% 0%, rgba(var(--accent-rgb), .07), transparent 70%);
  transition: background .8s;
}
.grain { position: fixed; inset: 0; z-index: 1; pointer-events: none; opacity: .05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>"); }
:root[data-theme="paper"] .grain { opacity: .08; mix-blend-mode: multiply; }
.stars { position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: 0; transition: opacity .8s; }
:root[data-theme="deepspace"] .stars, :root[data-theme="midnight"] .stars { opacity: 1; }

/* ---- Hero ------------------------------------------------------------------ */
.hero { position: relative; padding: clamp(100px, 12.5vh, 150px) 0 clamp(60px, 8vw, 100px); min-height: min(100vh, 980px); display: flex; align-items: center; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); align-items: center; }
.hero h1 { margin: 18px 0 0; font-size: clamp(52px, 8vw, 112px); }
.hero .sub { font: 400 clamp(26px, 3vw, 40px)/1.12 var(--font-display); letter-spacing: -0.025em; margin: 20px 0 0; color: var(--text); max-width: 620px; text-wrap: balance; }
:root[data-theme="deepspace"] .hero .sub { font-family: var(--font-text); }
.hero .sub .serif { font-size: 1.12em; color: var(--accent); }
.hero .lede { margin-top: 16px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero .chips { margin-top: 32px; }

/* The phone stage */
.stage { position: relative; height: clamp(520px, 62vw, 680px); perspective: 1600px; outline: none; touch-action: pan-y; }
.stage-glow { position: absolute; left: 50%; top: 46%; width: 70%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%;
  background: radial-gradient(closest-side, rgba(var(--stage-rgb, var(--accent-rgb)), .45), transparent); filter: blur(30px); transition: background .8s; opacity: .8; }
.stage-track { position: absolute; inset: 0 0 90px; transform-style: preserve-3d; transition: transform .6s var(--ease); pointer-events: none; }
.stage-track .iphone { pointer-events: auto; }
.stage .iphone {
  --w: clamp(200px, 21vw, 268px);
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%) translateX(var(--x, 0)) translateZ(var(--z, 0)) rotateY(var(--ry, 0)) scale(var(--s, 1));
  opacity: var(--o, 1); z-index: var(--zi, 1);
  transition: transform .9s var(--ease), opacity .7s var(--ease), filter .7s, box-shadow .7s;
  filter: brightness(var(--b, 1)) saturate(var(--sat, 1));
  cursor: pointer;
}
.stage .iphone.active { cursor: default; }
.stage-caption { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; justify-content: center; gap: 14px; }
.stage-caption .info { display: block; min-width: 0; text-align: center; padding: 6px 14px; border-radius: 14px; transition: background-color .25s; }
.stage-caption .info:hover { background: var(--surface-2); }
.stage-caption .name { display: flex; align-items: center; justify-content: center; gap: 10px; font: 650 19px/1.2 var(--font-display); letter-spacing: -0.01em; }
.stage-caption .name::after { content: "↓"; font: 500 15px/1 var(--font-text); color: var(--text-3); transition: transform .3s var(--ease), color .3s; }
.stage-caption .info:hover .name::after { transform: translateY(3px); color: var(--stage-color, var(--accent)); }
.stage-caption .name img { width: 26px; height: 26px; border-radius: 7px; }
.stage-caption .tag { display: block; font-size: 14px; color: var(--text-2); margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* App dock in the hero: hover previews the app on the stage, click jumps to it */
.dock { margin-top: 28px; }
.dock .label { display: block; margin-bottom: 14px; }
.dock-icons { display: flex; flex-wrap: wrap; gap: 12px; }
.dock-app {
  position: relative; display: block; width: 52px; height: 52px; border-radius: 14px; flex: none;
  box-shadow: 0 10px 24px -12px rgba(0,0,0,.7), 0 0 0 1px rgba(255,255,255,.06);
  transition: transform .4s var(--ease-spring), box-shadow .35s var(--ease);
}
.dock-app img { width: 100%; height: 100%; border-radius: inherit; }
.dock-app:hover, .dock-app:focus-visible { transform: translateY(-6px) scale(1.12); box-shadow: 0 16px 34px -12px rgba(var(--app-rgb), .8), 0 0 0 1px rgba(var(--app-rgb), .55); }
.dock-app:active { transform: translateY(-2px) scale(1.02); }
.dock-app::after { content: ""; position: absolute; left: 50%; bottom: -10px; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: rgb(var(--app-rgb)); box-shadow: 0 0 8px rgb(var(--app-rgb)); opacity: 0; transform: scale(.4); transition: opacity .3s, transform .3s var(--ease-spring); }
.dock-app.on::after { opacity: 1; transform: none; }
.dock-app .tip {
  position: absolute; left: 50%; bottom: calc(100% + 12px); transform: translate(-50%, 4px);
  padding: 6px 10px; border-radius: 9px; background: var(--glass); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border: 1px solid var(--line-2); font: 600 12.5px/1 var(--font-text); white-space: nowrap; color: var(--text);
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .25s var(--ease);
}
@media (hover: hover) {
  .dock-app:hover .tip, .dock-app:focus-visible .tip { opacity: 1; transform: translate(-50%, 0); }
}
.stage-arrow { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line-2); background: var(--surface); display: grid; place-items: center; flex: none; transition: border-color .25s, background-color .25s; }
.stage-arrow:hover { border-color: rgba(var(--accent-rgb), .6); background: var(--surface-2); }
.stage-arrow svg { width: 16px; height: 16px; }
.stage-dots { position: absolute; left: 50%; bottom: 66px; transform: translateX(-50%); display: flex; gap: 6px; }
.stage-dots button { width: 7px; height: 7px; border-radius: 99px; background: var(--line-2); transition: width .4s var(--ease), background-color .4s; }
.stage-dots button[aria-current="true"] { width: 22px; background: var(--stage-color, var(--accent)); }

/* ---- Devices ---------------------------------------------------------------- */
.iphone {
  --w: 280px;
  width: var(--w); flex: none;
  padding: calc(var(--w) * 0.032);
  border-radius: calc(var(--w) * 0.17);
  background: linear-gradient(145deg, #2a2a2e, #0c0c0e 30%, #1c1c20 70%, #3a3a40);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.22), inset 0 0 0 calc(var(--w) * 0.012) #0b0b0c, 0 50px 90px -34px rgba(0,0,0,.9);
  position: relative;
}
.iphone .screen { position: relative; border-radius: calc(var(--w) * 0.138); overflow: hidden; background: #000; aspect-ratio: 660 / 1435; }
.iphone .screen img { width: 100%; height: 100%; object-fit: cover; }
.iphone .screen::after { content: ""; position: absolute; top: calc(var(--w) * 0.03); left: 50%; transform: translateX(-50%); width: 31%; height: calc(var(--w) * 0.085); border-radius: 99px; background: #000; }
.iphone .screen::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(120deg, rgba(255,255,255,.08), transparent 28%, transparent 70%, rgba(255,255,255,.04)); }
:root[data-theme="paper"] .iphone { box-shadow: inset 0 0 0 1px rgba(255,255,255,.25), inset 0 0 0 calc(var(--w) * 0.012) #0b0b0c, 0 50px 80px -36px rgba(60,40,10,.55); }

.browser { width: 100%; max-width: 600px; border-radius: 16px; overflow: hidden; background: #1a1a1c; box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), 0 50px 90px -34px rgba(0,0,0,.85); }
.browser-bar { display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 14px; background: #232326; border-bottom: 1px solid rgba(255,255,255,.06); }
.browser-bar .tl { display: flex; gap: 7px; }
.browser-bar .tl i { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.browser-bar .tl i:nth-child(2) { background: #febc2e; }
.browser-bar .tl i:nth-child(3) { background: #28c840; }
.browser-bar .url { flex: 1; max-width: 300px; margin: 0 auto; height: 24px; border-radius: 7px; background: rgba(255,255,255,.07); color: rgba(255,255,255,.6); font: 500 11.5px/24px var(--font-text); text-align: center; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; padding: 0 10px; }

/* Trackizon e-paper dashboard (illustration) */
.tz { background: #f3f0e8; color: #141414; padding: 18px; font: 500 12px/1.4 var(--font-text); }
.tz-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.tz-brand { display: flex; align-items: center; gap: 8px; font: 700 14px/1 var(--font-display); letter-spacing: -0.01em; }
.tz-brand img { width: 20px; height: 20px; border-radius: 5px; }
.tz-range { display: flex; gap: 4px; }
.tz-range span { padding: 4px 8px; border-radius: 6px; border: 1px solid #1414141f; font: 600 10px/1 var(--font-mono); letter-spacing: .06em; }
.tz-range span.on { background: #141414; color: #f3f0e8; border-color: #141414; }
.tz-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.tz-kpi { border: 1px solid #14141424; border-radius: 10px; padding: 9px 11px; background: #fbf9f4; }
.tz-kpi b { display: block; font: 700 18px/1.15 var(--font-display); letter-spacing: -0.02em; margin-top: 3px; font-variant-numeric: tabular-nums; }
.tz-kpi small { font: 600 9.5px/1 var(--font-mono); letter-spacing: .1em; text-transform: uppercase; color: #14141499; }
.tz-kpi em { font-style: normal; font-size: 10.5px; color: #2f7d3b; }
.tz-chart { margin-top: 10px; border: 1px solid #14141424; border-radius: 10px; padding: 10px 12px 8px; background: #fbf9f4; }
.tz-chart-head { display: flex; justify-content: space-between; font: 600 10px/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: #14141499; margin-bottom: 8px; }
.tz-bars { display: flex; align-items: flex-end; gap: 4px; height: 78px; }
.tz-bars i { flex: 1; border-radius: 3px 3px 1px 1px; background: #fbbf24; height: var(--h); transform-origin: bottom; transform: scaleY(0); transition: transform .9s var(--ease); transition-delay: calc(var(--d) * 40ms); }
.tz-bars i:nth-child(odd) { background: #141414; }
.in .tz-bars i, .tz-bars.in i { transform: none; }
.tz-table { margin-top: 10px; width: 100%; border-collapse: collapse; font-size: 11px; }
.tz-table th { text-align: left; font: 600 9.5px/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: #14141480; padding: 0 6px 6px; }
.tz-table td { padding: 6px; border-top: 1px solid #1414141a; font-variant-numeric: tabular-nums; }
.tz-table td:last-child, .tz-table th:last-child { text-align: right; }
.tz-pill { display: inline-block; padding: 2px 6px; border-radius: 5px; background: #14141410; font: 600 9.5px/1.3 var(--font-mono); }

/* ---- Stats strip ------------------------------------------------------------ */
.stats { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 34px 26px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat b { display: block; font: 650 clamp(40px, 5vw, 64px)/1 var(--font-display); letter-spacing: -0.04em; color: var(--text); font-variant-numeric: tabular-nums; }
.stat b .accent { color: var(--accent); }
.stat > span { display: block; margin-top: 12px; color: var(--text-2); font-size: 15px; max-width: 220px; }

/* ---- Sections ------------------------------------------------------------- */
.section { padding: clamp(90px, 12vw, 160px) 0; position: relative; }
.section.tight { padding-top: clamp(60px, 8vw, 100px); }

/* App index */
.index { margin-top: 56px; border-top: 1px solid var(--line); }
.index-row {
  display: grid; grid-template-columns: 54px 64px minmax(0, 1.1fr) minmax(0, 1.4fr) auto 28px; align-items: center; gap: 22px;
  padding: 22px 8px; border-bottom: 1px solid var(--line);
  position: relative; transition: background-color .35s var(--ease), padding .45s var(--ease);
}
.index-row::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(var(--app-rgb), .14), transparent 70%); opacity: 0; transition: opacity .35s; pointer-events: none; }
.index-row:hover::before, .index-row:focus-visible::before { opacity: 1; }
.index-row:hover { padding-left: 18px; }
.index-row .num { font: 600 13px/1 var(--font-mono); color: var(--text-3); letter-spacing: .1em; }
.index-row:hover .num { color: var(--app); }
.index-row .ico { width: 56px; height: 56px; border-radius: 13px; box-shadow: 0 8px 22px -10px rgba(0,0,0,.6); }
.index-row .nm { font: 650 clamp(22px, 2.4vw, 30px)/1.1 var(--font-display); letter-spacing: -0.025em; }
.index-row .nm small { display: block; margin-top: 6px; font: 500 12px/1 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--text-3); }
.index-row .desc { color: var(--text-2); font-size: 15.5px; line-height: 1.5; }
.index-row .plats { display: flex; gap: 6px; color: var(--text-3); }
.index-row .plats svg { width: 18px; height: 18px; }
.index-row .go { width: 28px; height: 28px; color: var(--text-3); transition: transform .35s var(--ease), color .3s; }
.index-row:hover .go { transform: translate(3px, 3px); color: var(--app); }
.peek { position: fixed; left: 0; top: 0; z-index: 90; width: 170px; pointer-events: none; opacity: 0; transform: translate(-50%, -50%) scale(.85) rotate(-4deg); transition: opacity .25s var(--ease), transform .35s var(--ease); }
.peek.on { opacity: 1; transform: translate(-50%, -50%) scale(1) rotate(-4deg); }
.peek .iphone { --w: 170px; }

/* App chapters */
.chapter { position: relative; padding: clamp(80px, 10vw, 140px) 0; border-top: 1px solid var(--line); }
.chapter::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(42% 55% at var(--gx, 75%) 50%, rgba(var(--app-rgb), .16), transparent 72%);
}
.chapter-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: center; position: relative; }
.chapter.flip { --gx: 25%; }
.chapter.flip .chapter-copy { order: 2; }
.chapter-head { display: flex; align-items: center; gap: 16px; }
.chapter-head .ico { width: 72px; height: 72px; border-radius: 17px; box-shadow: 0 14px 40px -14px rgba(var(--app-rgb), .7), 0 0 0 1px rgba(255,255,255,.06); }
.chapter-head .meta { display: flex; flex-direction: column; gap: 8px; }
.chapter-head .num { font: 600 12px/1 var(--font-mono); letter-spacing: .22em; text-transform: uppercase; color: var(--app); }
.chapter-head .cat { font: 500 13px/1 var(--font-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--text-3); }
.chapter h2 { font: 650 clamp(44px, 6vw, 84px)/0.98 var(--font-display); letter-spacing: -0.04em; margin: 30px 0 0; }
:root[data-theme="deepspace"] .chapter h2 { letter-spacing: -0.01em; font-size: clamp(36px, 5vw, 66px); }
.chapter .tagline { font: 400 italic clamp(28px, 3.3vw, 42px)/1.1 var(--font-serif); color: var(--app); margin: 12px 0 0; letter-spacing: -0.01em; }
.chapter .about { color: var(--text-2); font-size: clamp(16.5px, 1.4vw, 18.5px); margin: 24px 0 0; max-width: 560px; text-wrap: pretty; }
.feats { list-style: none; margin: 30px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.feats li { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); font-size: 14.5px; line-height: 1.45; color: var(--text); transition: border-color .3s, transform .4s var(--ease); }
.feats li:hover { border-color: rgba(var(--app-rgb), .45); transform: translateY(-2px); }
.feats li svg { width: 18px; height: 18px; flex: none; margin-top: 1px; color: var(--app); }
.chapter .chips { margin-top: 26px; }
.chapter .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

.visual { position: relative; display: flex; justify-content: center; align-items: center; min-height: 560px; }
.visual .iphone { --w: clamp(240px, 24vw, 300px); transform: rotate(var(--rot, -3deg)); transition: transform 1s var(--ease); }
.visual:hover .iphone { transform: rotate(0deg) translateY(-6px); }
.visual .halo { position: absolute; width: 78%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, rgba(var(--app-rgb), .38), transparent); filter: blur(10px); }
.visual .ring { position: absolute; width: 92%; aspect-ratio: 1; border-radius: 50%; border: 1px dashed rgba(var(--app-rgb), .25); animation: spin 80s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.float {
  position: absolute; z-index: 3;
  display: flex; align-items: center; gap: 10px;
  padding: 11px 14px; border-radius: 16px;
  background: var(--glass); -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%);
  border: 1px solid var(--line-2); box-shadow: 0 20px 40px -20px rgba(0,0,0,.7);
  font: 500 13px/1.3 var(--font-text); white-space: nowrap;
  animation: bob 6s ease-in-out infinite; animation-delay: var(--delay, 0s);
}
.float b { display: block; font-weight: 650; color: var(--text); }
.float small { display: block; color: var(--text-2); font-size: 12px; }
.float .fi { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; background: rgba(var(--app-rgb), .16); color: var(--app); flex: none; }
.float .fi svg { width: 17px; height: 17px; }
.float.mono b { font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .02em; }
@keyframes bob { 50% { transform: translateY(-10px); } }
.f1 { left: 0; top: 18%; }
.f2 { right: 0; top: 46%; --delay: -2s; }
.f3 { left: 6%; bottom: 12%; --delay: -4s; }
.visual.wide { min-height: 480px; }
.visual.wide .f1 { left: auto; right: 2%; top: -2%; }
.visual.wide .f2 { right: auto; left: 2%; top: auto; bottom: -2%; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #4cd97f; box-shadow: 0 0 0 0 rgba(76,217,127,.6); animation: pulse 2s infinite; flex: none; }
@keyframes pulse { 70% { box-shadow: 0 0 0 9px rgba(76,217,127,0); } 100% { box-shadow: 0 0 0 0 rgba(76,217,127,0); } }

/* ---- Multi-device compositions: Mac window / web dashboard + iPhone ------ */
.chapter.wide-visual .chapter-grid { grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr); }
.chapter.wide-visual.flip .chapter-grid { grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); }
.visual.has-combo { flex-direction: column; min-height: 0; padding: 34px 0 0; }
.combo { position: relative; width: 100%; max-width: 680px; }
.combo .mac, .combo .web {
  margin: 0; border-radius: 12px; overflow: hidden; background: #000;
  box-shadow: 0 0 0 1px rgba(255,255,255,.14), 0 40px 90px -34px rgba(0,0,0,.9), 0 0 140px -40px rgba(var(--app-rgb), .5);
}
.combo .mac img, .combo .web img { display: block; width: 100%; height: auto; }
.combo .web { background: #f6f6f4; max-width: none; }
:root[data-theme="paper"] .combo .mac, :root[data-theme="paper"] .combo .web { box-shadow: 0 0 0 1px rgba(0,0,0,.12), 0 40px 80px -36px rgba(60,40,10,.5); }
.visual .combo .iphone { position: absolute; z-index: 2; transition: transform 1s var(--ease); }
.visual.has-combo:hover .combo .iphone { transform: rotate(0deg) translateY(-6px); }

/* duo: the Mac window, with the iPhone standing in front of its outer corner */
.combo.duo { padding: 0 6% 92px 0; }
.visual .combo.duo .iphone { --w: clamp(100px, 8.8vw, 134px); right: 0; bottom: 0; transform: rotate(4deg); }
.chapter.flip .combo.duo { padding: 0 0 92px 6%; }
.chapter.flip .visual .combo.duo .iphone { right: auto; left: 0; transform: rotate(-4deg); }
.chapter.flip .visual.has-combo:hover .combo.duo .iphone { transform: rotate(0deg) translateY(-6px); }

/* trio: web dashboard behind, Mac app in front of it, iPhone in front of both */
.combo.trio { aspect-ratio: 100 / 86; }
.combo.trio .web { position: absolute; left: 0; top: 0; width: 76%; }
.combo.trio .mac { position: absolute; right: 0; bottom: 4%; width: 62%; z-index: 1; }
.visual .combo.trio .iphone { --w: clamp(96px, 9.5vw, 140px); left: 6%; bottom: 0; transform: rotate(-4deg); }

/* pair: two Mac windows, the second standing in front of the first's outer corner */
.combo.pair { padding: 0 9% 16% 0; }
/* Harbor's shots are rendered from the app's views, without window chrome: draw the traffic lights where they sit */
.combo.pair .mac:first-child { position: relative; }
.combo.pair .mac:first-child::before {
  content: ""; position: absolute; z-index: 1; left: 1.56%; top: 5.8%; width: 4.06%; aspect-ratio: 104 / 24; transform: translateY(-50%);
  background: radial-gradient(circle closest-side, #ff5f57 90%, transparent) 0 0 / 23.08% 100% no-repeat,
              radial-gradient(circle closest-side, #febc2e 90%, transparent) 50% 0 / 23.08% 100% no-repeat,
              radial-gradient(circle closest-side, #28c840 90%, transparent) 100% 0 / 23.08% 100% no-repeat;
}
.combo.pair .mac + .mac {
  position: absolute; z-index: 2; right: 0; bottom: 0; width: 46%; transition: transform 1s var(--ease);
  box-shadow: 0 0 0 1px rgba(255,255,255,.16), 0 22px 54px -14px rgba(0,0,0,.8), 0 40px 90px -34px rgba(0,0,0,.9);
}
.chapter.flip .combo.pair { padding: 0 0 16% 9%; }
.chapter.flip .combo.pair .mac + .mac { right: auto; left: 0; }
.visual.has-combo:hover .combo.pair .mac + .mac { transform: translateY(-6px); }
:root[data-theme="paper"] .combo.pair .mac + .mac { box-shadow: 0 0 0 1px rgba(255,255,255,.18), 0 22px 50px -16px rgba(60,40,10,.55); }

.combo-legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 18px; margin-top: 28px; color: var(--text-3); font: 500 12px/1 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; }
.combo-legend span { display: inline-flex; align-items: center; gap: 7px; }
.combo-legend svg { width: 16px; height: 16px; color: var(--app); }

/* ---- Craft ------------------------------------------------------------------ */
.craft-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 56px; }
.card { position: relative; padding: 28px 24px 30px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); overflow: hidden; transition: border-color .35s, transform .5s var(--ease); }
.card:hover { border-color: rgba(var(--accent-rgb), .4); transform: translateY(-4px); }
.card::after { content: ""; position: absolute; inset: auto -30% -60% auto; width: 80%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, rgba(var(--accent-rgb), .14), transparent); opacity: 0; transition: opacity .5s; }
.card:hover::after { opacity: 1; }
.card .ci { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: rgba(var(--accent-rgb), .12); color: var(--accent); }
.card .ci svg { width: 22px; height: 22px; }
.card h3 { font: 650 21px/1.2 var(--font-display); letter-spacing: -0.02em; margin: 22px 0 0; }
:root[data-theme="deepspace"] .card h3 { font-size: 16px; letter-spacing: .01em; }
.card p { color: var(--text-2); font-size: 15px; margin: 10px 0 0; }

/* ---- Platform matrix ------------------------------------------------------ */
.matrix-wrap { margin-top: 56px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow-x: auto; -webkit-overflow-scrolling: touch; }
.matrix { width: 100%; min-width: 720px; border-collapse: collapse; }
.matrix th, .matrix td { padding: 16px 14px; text-align: center; border-bottom: 1px solid var(--line); }
.matrix tr:last-child td { border-bottom: 0; }
.matrix thead th { font: 600 11px/1.2 var(--font-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--text-3); padding-top: 20px; }
.matrix thead th svg { display: block; margin: 0 auto 8px; width: 20px; height: 20px; color: var(--text-2); }
.matrix th:first-child, .matrix td:first-child { text-align: left; padding-left: 24px; }
.matrix td:first-child a { display: inline-flex; align-items: center; gap: 12px; font: 600 16px/1.2 var(--font-display); letter-spacing: -0.01em; }
.matrix td:first-child img { width: 34px; height: 34px; border-radius: 9px; }
.matrix tbody tr { transition: background-color .25s; }
.matrix tbody tr:hover { background: var(--surface-2); }
.yes { display: inline-block; width: 12px; height: 12px; border-radius: 50%; background: var(--app); box-shadow: 0 0 14px rgba(var(--app-rgb), .7); }
.no { display: inline-block; width: 12px; height: 2px; border-radius: 2px; background: var(--line-2); vertical-align: middle; }

/* ---- Themes ------------------------------------------------------------------ */
.themes-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 56px; }
.theme-card {
  display: block; width: 100%;
  text-align: left; border-radius: 20px; padding: 14px; border: 1px solid var(--line); background: var(--surface);
  transition: border-color .3s, transform .4s var(--ease), box-shadow .4s;
}
.theme-card:hover { transform: translateY(-4px); border-color: var(--line-2); }
.theme-card[aria-checked="true"] { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 20px 50px -24px var(--glow); }
.theme-card .pv { display: block; position: relative; height: 128px; border-radius: 12px; overflow: hidden; background: var(--t-bg); border: 1px solid rgba(128,128,128,.18); }
.theme-card .pv::before { content: ""; position: absolute; inset: 0; background: radial-gradient(70% 90% at 80% 0%, color-mix(in srgb, var(--t-ac) 30%, transparent), transparent 70%); }
.theme-card .pv .l1 { position: absolute; left: 14px; top: 18px; width: 46%; height: 12px; border-radius: 4px; background: var(--t-tx); opacity: .9; }
.theme-card .pv .l2 { position: absolute; left: 14px; top: 38px; width: 30%; height: 12px; border-radius: 4px; background: var(--t-ac); }
.theme-card .pv .l3 { position: absolute; left: 14px; top: 62px; width: 62%; height: 6px; border-radius: 3px; background: var(--t-tx); opacity: .28; }
.theme-card .pv .l4 { position: absolute; left: 14px; top: 74px; width: 50%; height: 6px; border-radius: 3px; background: var(--t-tx); opacity: .2; }
.theme-card .pv .pill { position: absolute; left: 14px; bottom: 14px; width: 64px; height: 20px; border-radius: 99px; background: var(--t-ac); }
.theme-card .pv .ph { position: absolute; right: 14px; bottom: -26px; width: 52px; height: 100px; border-radius: 12px; background: #111; box-shadow: 0 0 0 3px #222, 0 0 30px color-mix(in srgb, var(--t-ac) 50%, transparent); }
.theme-card .pv .ph::after { content: ""; position: absolute; inset: 8px 6px auto; height: 40px; border-radius: 6px; background: linear-gradient(160deg, var(--t-ac), transparent); opacity: .7; }
.theme-card .nm { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; padding: 0 4px; font: 600 15px/1.2 var(--font-display); }
.theme-card .nm small { font: 500 11px/1 var(--font-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--text-3); }

/* ---- About ------------------------------------------------------------------- */
.about-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.quote { font: 400 italic clamp(34px, 4.2vw, 58px)/1.08 var(--font-serif); letter-spacing: -0.015em; margin: 22px 0 0; text-wrap: balance; }
.quote .accent { font-style: italic; }
.about-copy p { color: var(--text-2); font-size: 18px; margin: 0 0 18px; text-wrap: pretty; }
.about-copy p strong { color: var(--text); font-weight: 600; }
.sig { display: flex; align-items: center; gap: 14px; margin-top: 30px; }
.sig .mark { width: 48px; height: 48px; border-radius: 14px; font-size: 28px; }
.sig b { display: block; font: 650 17px/1.2 var(--font-display); }
.sig small { color: var(--text-3); font-size: 14px; }
.stack { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }

/* ---- Contact CTA -------------------------------------------------------------- */
.cta { position: relative; text-align: center; border-radius: 32px; padding: clamp(56px, 8vw, 100px) var(--gutter); border: 1px solid var(--line); overflow: hidden;
  background: radial-gradient(70% 90% at 50% 0%, rgba(var(--accent-rgb), .2), transparent 70%), var(--surface); }
.cta .h-section { margin-left: auto; margin-right: auto; max-width: 900px; }
.cta .lede { margin-left: auto; margin-right: auto; }
.mail {
  display: inline-flex; align-items: center; gap: 4px; margin-top: 34px; padding: 6px 6px 6px 24px; border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--bg-2); font: 600 clamp(16px, 2vw, 22px)/1 var(--font-display); letter-spacing: -0.01em;
  max-width: 100%;
}
.mail a { padding: 12px 6px 12px 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mail a:hover { color: var(--accent); }
.copy-btn { height: 44px; padding: 0 16px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font: 600 14px/1 var(--font-text); display: inline-flex; align-items: center; gap: 8px; flex: none; transition: background-color .25s; }
.copy-btn:hover { background: var(--accent-hi); }
.copy-btn svg { width: 15px; height: 15px; }
.cta .actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 18px; }

/* ---- Chargy: its popover open under a Mac menu bar (real screenshots) ------------ */
.cg { position: relative; z-index: 1; width: min(100%, 520px); aspect-ratio: 520 / 560; }
.cg-bar { position: absolute; left: 0; right: 0; top: 0; height: 30px; padding: 0 14px; border-radius: 12px;
  display: flex; align-items: center; justify-content: flex-end; gap: 14px;
  font: 600 12.5px/1 var(--font-text); color: rgba(255,255,255,.9); white-space: nowrap;
  background: rgba(28, 30, 36, .74); -webkit-backdrop-filter: blur(16px) saturate(150%); backdrop-filter: blur(16px) saturate(150%);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08), 0 20px 50px -24px rgba(0,0,0,.8); }
.cg-bar svg { width: 15px; height: 15px; flex: none; }
.cg-item { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 9px; border-radius: 7px; background: rgba(255,255,255,.17); }
.cg-item svg { width: 13px; height: 13px; }
.cg-pop, .cg-back { position: absolute; display: block; height: auto; transition: transform 1s var(--ease); }
.cg-pop { z-index: 2; right: 10%; top: 44px; width: 60%; filter: drop-shadow(0 40px 50px rgba(0,0,0,.65)); }
.cg-back { z-index: 1; left: 2%; top: 96px; width: 50%; transform: rotate(-5deg); filter: drop-shadow(0 30px 40px rgba(0,0,0,.6)) brightness(.86); }
.visual:hover .cg-pop { transform: translateY(-6px); }
.visual:hover .cg-back { transform: rotate(-3deg) translateY(-4px); }
@media (max-width: 420px) { .cg-bar .cg-opt { display: none; } }

/* ---- Footer: paper under the page, with the name set large ---------------------
   The paper takes the opposite of the theme: cream tinted by the accent under the dark
   themes, ink under Paper. Where it fits on screen it waits underneath (fixed) and the
   page lifts off it: the page becomes a solid sheet with rounded bottom corners that
   carries the glow, stars and grain inside it (site.js moves them in; its clip keeps
   them to the sheet), so the browser hides the footer without any script while you
   scroll. Otherwise it's an ordinary footer at the end of the page. */
:root {
  --ft-paper: color-mix(in oklab, var(--accent) 12%, #f4f1ea);
  --ft-ink: color-mix(in oklab, var(--bg) 35%, #15110b);
  --ft-accent: color-mix(in oklab, var(--accent) 70%, #15110b);
}
:root[data-theme="paper"] {
  --ft-paper: color-mix(in oklab, var(--accent) 8%, #15110b);
  --ft-ink: #f4f1ea;
  --ft-accent: var(--accent-hi);
}
:root {
  --ft-ink-2: color-mix(in oklab, var(--ft-ink) 70%, var(--ft-paper));
  --ft-ink-3: color-mix(in oklab, var(--ft-ink) 50%, var(--ft-paper));
  --ft-line: color-mix(in oklab, var(--ft-ink) 14%, var(--ft-paper));
}
.footer { position: relative; overflow: hidden; padding: 84px 0 0; color: var(--ft-ink-2);
  background: radial-gradient(120% 80% at 50% 120%, color-mix(in srgb, var(--ft-accent) 24%, transparent), transparent 60%), var(--ft-paper);
  transition: background-color .6s var(--ease); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.footer .brand, .footer .brand-txt b { color: var(--ft-ink); }
.footer .brand-txt small { color: var(--ft-ink-3); }
.footer .avatar { box-shadow: 0 0 0 2px var(--ft-paper), 0 0 0 3.5px var(--ft-accent), 0 8px 22px -8px rgba(0,0,0,.35); }
.footer p { color: var(--ft-ink-2); font-size: 15px; max-width: 360px; margin: 18px 0 0; }
.footer h4 { font: 600 11px/1.2 var(--font-mono); letter-spacing: .2em; text-transform: uppercase; color: var(--ft-ink-3); margin: 0 0 16px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: 15px; }
.footer ul a { color: var(--ft-ink-2); display: inline-flex; align-items: center; gap: 10px; transition: color .2s; }
.footer ul a:hover { color: var(--ft-accent); }
.footer ul img { width: 20px; height: 20px; border-radius: 5px; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
/* The apps in two columns keep the footer short enough to fit on a laptop screen, so it
   can wait under the page there too (site.js only lifts it when it fits). */
.footer .footer-grid > div:nth-child(2) ul { grid-template-columns: 1fr 1fr; column-gap: 20px; }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 14px; margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--ft-line); color: var(--ft-ink-3); font-size: 13.5px; }
.footer-bottom a:hover { color: var(--ft-accent); }
.ft-word { margin: 40px 0 -.17em; text-align: center; white-space: nowrap; user-select: none; pointer-events: none;
  font: 650 17.2vw/.8 var(--font-display); letter-spacing: -.055em; color: var(--ft-ink); }
.ft-word em { font: italic 400 1.1em/.8 var(--font-serif); letter-spacing: -.03em; color: var(--ft-accent); }
:root[data-theme="deepspace"] .ft-word { font-size: 11.4vw; font-weight: 700; letter-spacing: -.01em; }
:root[data-theme="deepspace"] .ft-word em { font-size: 1.35em; }
/* The glow and stars ride inside the page as sticky layers: they stay put on screen like
   before, and end where the page ends, so nothing has to be clipped (a clip-path on a page
   this tall stops Chrome drawing it). */
main > .ambient, main > canvas.stars { position: sticky; inset: auto; top: 0; display: block; width: 100%; height: 100vh; margin-bottom: -100vh; }
html.has-footer-reveal main { position: relative; z-index: 1; background: var(--bg); transition: background-color .6s var(--ease); }
html.has-footer-reveal .footer { position: fixed; left: 0; right: 0; bottom: 0; z-index: 0; padding-top: 132px; }
/* After the sheet: the room to scroll the footer into view, the sheet's shadow on it, and
   paper-colored corners that round the sheet's bottom edge. */
.sheet-gap { display: none; --r: 44px; }
html.has-footer-reveal .sheet-gap { display: block; position: relative; z-index: 1; height: calc(var(--footer-h, 48px) - 48px); pointer-events: none;
  background: linear-gradient(rgba(0,0,0,.3), rgba(0,0,0,.08) 34px, transparent 90px); }
:root[data-theme="paper"] .sheet-gap { background: linear-gradient(rgba(60,40,10,.38), transparent 80px); }
html.has-footer-reveal .sheet-gap::before, html.has-footer-reveal .sheet-gap::after { content: ""; position: absolute; top: calc(var(--r) * -1); width: var(--r); height: var(--r); }
.sheet-gap::before { left: 0; background: radial-gradient(circle at 100% 0, transparent calc(var(--r) - .5px), var(--ft-paper) var(--r)); }
.sheet-gap::after { right: 0; background: radial-gradient(circle at 0 0, transparent calc(var(--r) - .5px), var(--ft-paper) var(--r)); }

/* ---- Back to top: bottom right, its ring filling with how far down you are ------- */
.to-top { position: fixed; z-index: 95; right: max(var(--gutter), env(safe-area-inset-right)); bottom: max(20px, env(safe-area-inset-bottom)); width: 52px; height: 52px;
  display: grid; place-items: center; border-radius: 50%; color: var(--text); touch-action: manipulation;
  background: var(--glass); backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px) saturate(1.4);
  box-shadow: inset 0 0 0 1px var(--line-2), 0 14px 34px -14px rgba(0,0,0,.8);
  opacity: 0; transform: translateY(14px) scale(.9); pointer-events: none; -webkit-tap-highlight-color: transparent;
  transition: opacity .35s var(--ease), transform .45s var(--ease), color .3s, background-color .3s, box-shadow .3s; }
.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
@media (hover: hover) { .to-top.is-visible:hover { transform: translateY(-2px); } }
.to-top.is-visible:active { transform: scale(.94); transition-duration: .12s; }
.to-top::after { content: ""; position: absolute; inset: -12px; border-radius: 50%; }
.to-top-ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.to-top-track, .to-top-progress { fill: none; stroke-width: 2.5; }
.to-top-track { stroke: var(--line-2); }
.to-top-progress { stroke: var(--accent); stroke-linecap: round; stroke-dasharray: 150.8px; stroke-dashoffset: calc(150.8px * (1 - var(--read, 0)));
  filter: drop-shadow(0 0 4px var(--glow)); }
.to-top-arrow { position: relative; width: 20px; height: 20px; }
.to-top.on-paper { color: var(--ft-ink); background: color-mix(in srgb, var(--ft-paper) 84%, transparent); box-shadow: inset 0 0 0 1px var(--ft-line), 0 14px 30px -14px rgba(0,0,0,.45); }
.to-top.on-paper .to-top-track { stroke: var(--ft-line); }
.to-top.on-paper .to-top-progress { stroke: var(--ft-accent); filter: none; }
html:has(#mobileMenu.open) .to-top { opacity: 0; pointer-events: none; }
@media (max-width: 640px) {
  /* Compact on phones (no blurb, site links in a line) so the footer fits on screen and
     can wait under the page there too. */
  .footer { padding-top: 60px; }
  html.has-footer-reveal .footer { padding-top: 104px; }
  .sheet-gap { --r: 28px; }
  .footer .footer-grid { gap: 22px; }
  .footer .footer-grid > div:first-child p { display: none; }
  .footer h4 { margin-bottom: 12px; }
  .footer .footer-grid > div:nth-child(2) ul { gap: 8px 16px; }
  .footer .footer-grid > div:nth-child(3) ul { display: flex; flex-wrap: wrap; gap: 8px 20px; }
  .footer-bottom { margin-top: 26px; padding-top: 16px; font-size: 11.5px; gap: 8px; }
  .ft-word { margin-top: 28px; }
}

/* ---- Document pages (privacy, terms, contact) --------------------------------- */
.page-hero { padding: clamp(130px, 18vh, 180px) 0 clamp(36px, 5vw, 60px); }
.page-hero .h-section { font-size: clamp(44px, 6.4vw, 88px); }
.page-hero .meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; }
.doc-grid { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.toc { position: sticky; top: 100px; display: grid; gap: 2px; font-size: 14px; }
.toc .label { margin-bottom: 12px; }
.toc a { color: var(--text-3); padding: 7px 12px; border-left: 1px solid var(--line); transition: color .2s, border-color .2s; }
.toc a:hover { color: var(--text); }
.toc a.on { color: var(--text); border-left-color: var(--accent); }
.doc { max-width: 760px; }
.doc section { padding-bottom: 14px; }
.doc h2 { font: 650 clamp(24px, 2.6vw, 30px)/1.2 var(--font-display); letter-spacing: -0.02em; margin: 48px 0 0; scroll-margin-top: 100px; }
.doc section:first-child h2 { margin-top: 0; }
:root[data-theme="deepspace"] .doc h2 { font-size: 20px; letter-spacing: .01em; }
.doc h3 { font: 650 18px/1.3 var(--font-display); margin: 28px 0 0; }
.doc p, .doc li { color: var(--text-2); font-size: 16.5px; line-height: 1.7; }
.doc p { margin: 14px 0 0; }
.doc ul { margin: 14px 0 0; padding-left: 20px; }
.doc li { margin: 6px 0; }
.doc li::marker { color: var(--accent); }
.doc strong { color: var(--text); font-weight: 600; }
.doc code { font: 500 .86em/1 var(--font-mono); padding: 3px 6px; border-radius: 6px; background: var(--surface-2); color: var(--text); white-space: nowrap; }
.doc a:not(.btn) { color: var(--accent); text-decoration: underline; text-decoration-color: rgba(var(--accent-rgb), .4); text-underline-offset: 3px; }
.doc a:not(.btn):hover { text-decoration-color: currentColor; }
.callout { margin: 22px 0 0; padding: 20px 22px; border-radius: 18px; border: 1px solid rgba(var(--accent-rgb), .35); background: rgba(var(--accent-rgb), .07); }
.callout p { margin: 0; color: var(--text); }
.callout p + p { margin-top: 8px; color: var(--text-2); }
.data-table { width: 100%; border-collapse: collapse; margin-top: 18px; font-size: 15px; }
.data-table th, .data-table td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.data-table th { font: 600 11px/1.2 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--text-3); }
.data-table td { color: var(--text-2); }
.data-table td:first-child { color: var(--text); font-weight: 600; white-space: nowrap; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 16px; margin-top: 18px; }
.table-wrap .data-table { margin: 0; min-width: 560px; }
.table-wrap .data-table tr:last-child td { border-bottom: 0; }
.app-links { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.app-link { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); transition: border-color .25s, transform .35s var(--ease); text-decoration: none !important; color: var(--text) !important; }
.app-link:hover { border-color: rgba(var(--app-rgb), .5); transform: translateY(-2px); }
.app-link img { width: 34px; height: 34px; border-radius: 9px; flex: none; }
.app-link b { display: block; font: 600 15px/1.2 var(--font-display); }
.app-link small { display: block; color: var(--text-3); font-size: 12.5px; margin-top: 2px; }
.app-link svg { width: 15px; height: 15px; margin-left: auto; color: var(--text-3); flex: none; }
.optout { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.optout p { margin: 0 !important; }
.switch { position: relative; width: 52px; height: 30px; border-radius: 99px; background: var(--line-2); flex: none; transition: background-color .3s; }
.switch::after { content: ""; position: absolute; left: 3px; top: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.3); transition: transform .35s var(--ease-spring); }
.switch[aria-checked="true"] { background: var(--accent); }
.switch[aria-checked="true"]::after { transform: translateX(22px); }

/* Contact page */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.panel { border-radius: 26px; border: 1px solid var(--line); background: var(--surface); padding: clamp(22px, 3vw, 36px); }
.panel h2 { font: 650 26px/1.2 var(--font-display); letter-spacing: -0.02em; margin: 0; }
:root[data-theme="deepspace"] .panel h2 { font-size: 20px; }
.panel > p { color: var(--text-2); margin: 10px 0 0; font-size: 15.5px; }
.form { display: grid; gap: 16px; margin-top: 26px; }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: grid; gap: 8px; }
.field label { font: 600 11px/1.2 var(--font-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--text-3); }
.field input, .field select, .field textarea {
  width: 100%; font: 400 16px/1.4 var(--font-text); color: var(--text);
  background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 14px; padding: 14px 16px;
  transition: border-color .2s, box-shadow .2s; -webkit-appearance: none; appearance: none;
}
.field select { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path d='M1 1l5 5 5-5' fill='none' stroke='%23888' stroke-width='1.6' stroke-linecap='round'/></svg>"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px; }
.field textarea { min-height: 170px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .15); }
.field input::placeholder, .field textarea::placeholder { color: var(--text-3); }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.form-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 4px; }
.form-foot small { color: var(--text-3); font-size: 13px; max-width: 340px; }
.form-foot small a { color: var(--text-2); text-decoration: underline; text-underline-offset: 3px; }
.status { display: none; padding: 14px 16px; border-radius: 14px; font-size: 15px; }
.status.show { display: block; animation: drop .3s var(--ease); }
.status.ok { background: rgba(76,217,127,.12); border: 1px solid rgba(76,217,127,.35); color: var(--text); }
.status.err { background: rgba(230,80,80,.12); border: 1px solid rgba(230,80,80,.35); color: var(--text); }
.btn[disabled] { opacity: .6; pointer-events: none; }
.side { display: grid; gap: 14px; }
.mail-card { display: grid; gap: 14px; }
.mail-card .addr { font: 650 clamp(19px, 2vw, 24px)/1.2 var(--font-display); letter-spacing: -0.01em; word-break: break-all; }
.mail-card .row2 { display: flex; gap: 10px; flex-wrap: wrap; }
.side .app-links { grid-template-columns: 1fr; margin-top: 16px; }

/* ---- Reveal ------------------------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 1s var(--ease), transform 1s var(--ease); transition-delay: var(--rd, 0s); }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal, .no-js .split .w > span { opacity: 1; transform: none; }

/* ---- Responsive --------------------------------------------------------------- */
/* Short laptop screens: keep the app dock above the fold */
@media (min-width: 961px) and (max-height: 900px) {
  .hero { padding-top: 92px; }
  .hero h1 { font-size: clamp(52px, 7vw, 100px); margin-top: 14px; }
  .hero .sub { font-size: clamp(24px, 2.6vw, 34px); margin-top: 16px; }
  .hero .lede { font-size: 17px; margin-top: 14px; }
  .hero .actions { margin-top: 24px; }
  .hero .btn { height: 48px; }
  .dock { margin-top: 22px; }
  .dock .label { margin-bottom: 12px; }
}

@media (min-width: 961px) and (max-height: 760px) {
  .hero { padding-top: 84px; }
  .hero h1 { font-size: clamp(48px, 6vw, 84px); }
  .hero .sub { font-size: clamp(22px, 2.3vw, 30px); }
  .hero .lede { font-size: 16px; line-height: 1.5; }
  .hero .actions { margin-top: 20px; }
}

@media (min-width: 961px) and (max-height: 720px) {
  .hero { padding-top: 78px; }
  .hero h1 { font-size: clamp(44px, 5.4vw, 76px); }
  .hero .sub { font-size: clamp(21px, 2.1vw, 28px); margin-top: 12px; }
  .dock { margin-top: 18px; }
  .dock .label { margin-bottom: 10px; }
}

@media (max-width: 1080px) {
  .craft-grid, .themes-grid { grid-template-columns: repeat(2, 1fr); }
  .index-row { grid-template-columns: 40px 56px minmax(0, 1fr) auto 24px; }
  .index-row .desc { display: none; }
}
@media (max-width: 960px) {
  .nav-links { display: none; }
  .menu-btn { display: inline-flex; }
  .nav-actions .btn { display: none; }
  .hero { min-height: 0; }
  .hero-grid { grid-template-columns: 1fr; }
  .stage { height: 600px; margin-top: 10px; }
  .chapter-grid, .chapter.wide-visual .chapter-grid, .chapter.wide-visual.flip .chapter-grid { grid-template-columns: 1fr; }
  .chapter.flip .chapter-copy { order: 0; }
  .combo { max-width: 620px; }
  .chapter::before { background: radial-gradient(70% 40% at 50% 78%, rgba(var(--app-rgb), .16), transparent 72%); }
  .visual { min-height: 520px; margin-top: 10px; }
  .about-grid, .contact-grid, .doc-grid { grid-template-columns: 1fr; }
  .toc { display: none; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; padding-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .theme-btn .tl { display: none; }
  .theme-btn { padding: 0 10px; }
  .hero .actions .btn { flex: 1 1 auto; }
  .stage { height: 540px; }
  .stage .iphone { --w: 210px; }
  .dock { margin-top: 30px; }
  .dock-icons { gap: 8px; }
  .dock-app { width: 42px; height: 42px; border-radius: 11px; }
  .index-row { grid-template-columns: 48px minmax(0, 1fr) 22px; gap: 14px; padding: 18px 4px; }
  .index-row .num, .index-row .plats { display: none; }
  .index-row .ico { width: 48px; height: 48px; border-radius: 11px; }
  .index-row:hover { padding-left: 4px; }
  .feats { grid-template-columns: 1fr; }
  .chapter .actions .btn { flex: 1 1 auto; }
  .visual { min-height: 500px; }
  .float { font-size: 12px; padding: 9px 11px; }
  .float .fi { width: 28px; height: 28px; }
  .f1 { left: -4px; }
  .f2 { right: -4px; }
  .craft-grid, .themes-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .card { padding: 22px 18px; }
  .theme-card .pv { height: 96px; }
  .theme-card .pv .ph { display: none; }
  .stat { padding: 26px 14px; }
  .stat > span { font-size: 14px; }
  .form .row { grid-template-columns: 1fr; }
  .app-links { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .mail { padding-left: 18px; }
  .tz-kpis { grid-template-columns: repeat(2, 1fr); }
  .tz-kpi:nth-child(n+5) { display: none; }
  .visual.wide .f2 { display: none; }
  .combo.duo, .chapter.flip .combo.duo { padding-bottom: 56px; }
  .visual .combo.duo .iphone { --w: 80px; }
  .combo .web .browser-bar { height: 22px; gap: 8px; padding: 0 8px; }
  .combo .web .browser-bar .tl { gap: 4px; }
  .combo .web .browser-bar .tl i { width: 7px; height: 7px; }
  .combo .web .browser-bar .url { height: 15px; font-size: 8.5px; line-height: 15px; max-width: 160px; }
  .visual .combo.trio .iphone { --w: 76px; left: 3%; }
  .visual.has-combo { padding-top: 10px; }
  .combo-legend { gap: 8px 14px; font-size: 11px; }
  .visual.wide .f1 { top: -18px; right: 0; }
  .matrix { min-width: 0; table-layout: fixed; }
  .matrix th, .matrix td { padding: 12px 2px; }
  .matrix th:first-child, .matrix td:first-child { width: 42%; padding-left: 12px; }
  .matrix thead th { font-size: 0; letter-spacing: 0; padding-top: 14px; }
  .matrix thead th:first-child { font-size: 10px; letter-spacing: .14em; }
  .matrix thead th svg { margin: 0 auto; width: 18px; height: 18px; }
  .matrix td:first-child a { font-size: 13.5px; gap: 8px; }
  .matrix td:first-child img { width: 26px; height: 26px; border-radius: 7px; }
  .yes { width: 10px; height: 10px; }
  .no { width: 8px; }
}
@media (max-width: 420px) {
  .craft-grid { grid-template-columns: 1fr; }
  .mail { flex-direction: column; padding: 8px; border-radius: 22px; width: 100%; }
  .mail a { padding: 10px 6px; }
  .mail .copy-btn { width: 100%; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
  .reveal, .split .w > span { opacity: 1 !important; transform: none !important; }
}
