/* Calsee website. The page wears a Calsee theme: every colour below comes
   from one of the app's hero themes, and html[data-theme] swaps the set. */

@font-face {
  font-family: "Space Grotesk";
  src: url("../fonts/SpaceGrotesk.ttf") format("truetype");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

/* ---------- Theme token sets (sampled from the app's screenshots) ---------- */

:root,
:root[data-theme="voltage-pink"] {
  --bg: #121014; --key: #2a2530; --key-edge: #0b090d;
  --ink: #f6f1f8; --ink-2: #c2b9c9;
  --op: #ff4d94; --on-op: #160410;
  --eq: #c6ff3d; --on-eq: #121014;
  --line: rgb(246 241 248 / 0.16);
  --shade: rgb(0 0 0 / 0.55);
  color-scheme: dark;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme]) {
    --bg: #eee9e1; --key: #f8f4ee; --key-edge: #cfc6b8;
    --ink: #2a2420; --ink-2: #5a5048;
    --op: #b6522d; --on-op: #ffffff;
    --eq: #b6522d; --on-eq: #ffffff;
    --line: rgb(42 36 32 / 0.16);
    --shade: rgb(80 60 40 / 0.22);
    color-scheme: light;
  }
}

:root[data-theme="lavender-dusk"] {
  --bg: #201b28; --key: #332e3d; --key-edge: #15111b;
  --ink: #f1ebf8; --ink-2: #c9bfd6;
  --op: #d0bcff; --on-op: #21182f;
  --eq: #ffb0cf; --on-eq: #3a0a22;
  --line: rgb(241 235 248 / 0.16);
  --shade: rgb(0 0 0 / 0.5);
  color-scheme: dark;
}
:root[data-theme="cyan-tube"] {
  --bg: #232427; --key: #3a3b3f; --key-edge: #141518;
  --ink: #eceef0; --ink-2: #bfc2c7;
  --op: #3bf4f4; --on-op: #031011;
  --eq: #4cb86a; --on-eq: #04150a;
  --line: rgb(236 238 240 / 0.16);
  --shade: rgb(0 0 0 / 0.5);
  color-scheme: dark;
}
:root[data-theme="porcelain-morning"] {
  --bg: #eee9e1; --key: #f8f4ee; --key-edge: #cfc6b8;
  --ink: #2a2420; --ink-2: #5a5048;
  --op: #b6522d; --on-op: #ffffff;
  --eq: #b6522d; --on-eq: #ffffff;
  --line: rgb(42 36 32 / 0.16);
  --shade: rgb(80 60 40 / 0.22);
  color-scheme: light;
}
:root[data-theme="midnight-sapphire"] {
  --bg: #0f1422; --key: #1d2537; --key-edge: #070a12;
  --ink: #e8edf8; --ink-2: #aeb8cc;
  --op: #adc6ff; --on-op: #0b1a3a;
  --eq: #ffd479; --on-eq: #2a1d00;
  --line: rgb(232 237 248 / 0.16);
  --shade: rgb(0 0 0 / 0.55);
  color-scheme: dark;
}
:root[data-theme="electric-mango"] {
  --bg: #0d0d0d; --key: #262626; --key-edge: #000000;
  --ink: #f2f2f2; --ink-2: #b8b8b8;
  --op: #ffb800; --on-op: #0d0d0d;
  --eq: #00e0b0; --on-eq: #0d0d0d;
  --line: rgb(242 242 242 / 0.16);
  --shade: rgb(0 0 0 / 0.6);
  color-scheme: dark;
}
:root[data-theme="oatmeal-desk"] {
  --bg: #d8ccb2; --key: #f1eadb; --key-edge: #b3a68b;
  --ink: #22261a; --ink-2: #4a4538;
  --op: #4a4540; --on-op: #f6f0e2;
  --eq: #d8732b; --on-eq: #1d0f04;
  --line: rgb(34 38 26 / 0.18);
  --shade: rgb(70 55 30 / 0.28);
  color-scheme: light;
}
:root[data-theme="slate-nocturne"] {
  --bg: #1d2229; --key: #272e37; --key-edge: #11151a;
  --ink: #e5eaf0; --ink-2: #aab3be;
  --op: #7ac8f5; --on-op: #0b2433;
  --eq: #7ac8f5; --on-eq: #0b2433;
  --line: rgb(229 234 240 / 0.16);
  --shade: rgb(0 0 0 / 0.5);
  color-scheme: dark;
}
:root[data-theme="midnight-lens"] {
  --bg: #0c1a3a; --key: #1a2a50; --key-edge: #050b1c;
  --ink: #eef3ff; --ink-2: #b9c6e6;
  --op: #9a8cf0; --on-op: #120d2e;
  --eq: #56c2e6; --on-eq: #04202b;
  --line: rgb(238 243 255 / 0.16);
  --shade: rgb(0 0 0 / 0.55);
  color-scheme: dark;
}
:root[data-theme="mango-sticker"] {
  --bg: #ffcb45; --key: #ffffff; --key-edge: #141414;
  --ink: #141414; --ink-2: #3d3420;
  --op: #ff8a65; --on-op: #141414;
  --eq: #141414; --on-eq: #ffcb45;
  --line: rgb(20 20 20 / 0.22);
  --shade: rgb(20 20 20 / 0.5);
  color-scheme: light;
}
/* Coral on yellow is too faint for a focus ring: use the ink outline. */
:root[data-theme="mango-sticker"] :focus-visible { outline-color: var(--ink); }
:root[data-theme="mango-sticker"] .band-ink :focus-visible { outline-color: var(--bg); }

/* ---------- System ---------- */

:root {
  --font-display: "Space Grotesk", ui-sans-serif, system-ui, sans-serif;
  --font-body: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
    "Noto Sans", "Noto Sans Devanagari", "Kohinoor Devanagari", sans-serif;
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1240px;
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px;
  --s7: 48px; --s8: 64px; --s9: 96px; --s10: 128px;
  --r-key: 18px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --theme-fade: 320ms;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: var(--s5);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--theme-fade) var(--ease-out),
    color var(--theme-fade) var(--ease-out);
}

img { display: block; max-width: 100%; height: auto; }

::selection { background: var(--op); color: var(--on-op); }

:focus-visible {
  outline: 3px solid var(--op);
  outline-offset: 3px;
  border-radius: 6px;
}

a {
  color: inherit;
  text-decoration-line: underline;
  text-decoration-color: var(--op);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.22em;
}
a:hover { text-decoration-thickness: 3px; }

html { scrollbar-color: var(--ink-2) var(--bg); }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: -0.03em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; text-wrap: pretty; }

.wrap {
  width: 100%;
  max-width: calc(var(--max) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.num, .tnum { font-variant-numeric: tabular-nums; }

.skip {
  position: absolute; left: var(--s4); top: -100px;
  background: var(--eq); color: var(--on-eq);
  padding: var(--s2) var(--s4); border-radius: 10px; z-index: 10;
  font-family: var(--font-display); font-weight: 600; text-decoration: none;
}
.skip:focus { top: var(--s4); }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* JS-only and no-JS-only bits */
.js-only { display: none; }
.js .js-only { display: revert; }
.js .no-js { display: none; }

/* ---------- Header ---------- */

/* The brand and the nav always keep at least --s6 between them; on very
   narrow screens the nav wraps under the brand instead of touching it. */
.site-header {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  column-gap: var(--s6); row-gap: 0;
  padding-block: var(--s4);
}
.site-nav { margin-inline-start: auto; min-width: 0; }
.brand {
  flex: none; white-space: nowrap;
  display: inline-flex; align-items: center; gap: var(--s3);
  font-family: var(--font-display); font-weight: 700; font-size: 1.375rem;
  letter-spacing: -0.02em; text-decoration: none;
}
.brand img { width: 36px; height: 36px; border-radius: 9px; }
.site-nav ul {
  display: flex; flex-wrap: wrap; justify-content: flex-end;
  column-gap: clamp(var(--s4), 2.4vw, var(--s6)); row-gap: 0;
  list-style: none; margin: 0; padding: 0;
  font-family: var(--font-display); font-weight: 500; font-size: 1rem;
}
.site-nav a { text-decoration: none; padding-block: var(--s3); display: inline-block; }
.site-nav a:hover, .site-nav a[aria-current="page"] {
  text-decoration: underline; text-decoration-color: var(--op);
  text-decoration-thickness: 2px;
}
@media (max-width: 640px) {
  .site-nav .nav-anchor { display: none; }
}

/* ---------- Keys (buttons drawn as calculator keys) ---------- */

.key {
  --face: var(--key); --label: var(--ink); --edge: var(--key-edge);
  appearance: none; border: 0; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--s2);
  min-height: 48px; min-width: 48px;
  padding: var(--s3) var(--s5);
  border-radius: var(--r-key);
  background: var(--face); color: var(--label);
  font-family: var(--font-display); font-weight: 600; font-size: 1.0625rem;
  line-height: 1.15; text-decoration: none; text-align: center;
  box-shadow: inset 0 -4px 0 rgb(0 0 0 / 0.22), inset 0 1px 0 rgb(255 255 255 / 0.12),
    0 8px 18px -10px var(--shade);
  transition: transform 90ms var(--ease-out), box-shadow 90ms var(--ease-out),
    background-color var(--theme-fade) var(--ease-out), color var(--theme-fade) var(--ease-out);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  user-select: none; -webkit-user-select: none;
}
.key:hover { filter: brightness(1.06); }
.key:active, .key.is-down {
  transform: translateY(2px);
  box-shadow: inset 0 -1px 0 rgb(0 0 0 / 0.22), inset 0 1px 0 rgb(255 255 255 / 0.08),
    0 3px 8px -6px var(--shade);
}
.key--op { --face: var(--op); --label: var(--on-op); }
.key--eq { --face: var(--eq); --label: var(--on-eq); }
.key svg { width: 22px; height: 22px; flex: none; }

/* Coming-soon store keys: not links, so no pointer and no press. */
.store-row { display: flex; flex-wrap: wrap; gap: var(--s3); }
.store-key {
  cursor: default; flex-direction: column; align-items: flex-start;
  gap: 2px; padding: var(--s3) var(--s5) calc(var(--s3) + 2px);
  min-width: 11.5rem;
}
.store-key:hover { filter: none; }
.store-key:active { transform: none; }
.store-key small {
  font-family: var(--font-body); font-weight: 500; font-size: 0.8125rem;
  letter-spacing: 0.01em;
}
.store-key strong { font-weight: 700; font-size: 1.125rem; }

/* ---------- Hero ---------- */

.hero { padding-top: clamp(var(--s4), 3vw, var(--s6)); }
.hero-top {
  display: grid; gap: var(--s5) var(--s7);
  grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr);
  align-items: end;
}
.hero h1 {
  font-size: clamp(2.5rem, 4.9vw, 4.6rem);
  letter-spacing: -0.04em; line-height: 0.98;
  max-width: 14ch;
}
.hero-side { display: grid; gap: var(--s5); padding-bottom: var(--s2); }
.hero-side p { color: var(--ink-2); font-size: 1.125rem; max-width: 34ch; }
.hero-side p strong { color: var(--ink); font-weight: 600; }

@media (max-width: 860px) {
  .hero-top { grid-template-columns: 1fr; }
  .hero-side { order: 2; }
}

/* The filmstrip: a native horizontal scroller with snap points, so swiping
   works without any script. Script only reads which phone is centred. */
.strip {
  --phone-h: clamp(360px, calc(100svh - 430px), 600px);
  --phone-w: calc(var(--phone-h) * 9 / 16);
  display: flex; gap: clamp(var(--s4), 2.2vw, var(--s6));
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  padding: var(--s4) calc(50vw - var(--phone-w) / 2) var(--s4);
  margin-top: var(--s3);
  scrollbar-width: none;
  outline-offset: -3px;
}
.strip::-webkit-scrollbar { display: none; }
.phone {
  flex: none; margin: 0;
  width: var(--phone-w);
  scroll-snap-align: center;
  transition: transform 420ms var(--ease-out), opacity 420ms var(--ease-out);
}
.phone img {
  width: 100%; aspect-ratio: 9 / 16;
  border-radius: calc(var(--phone-w) * 0.085);
  box-shadow: 0 0 0 1px var(--line), 0 30px 60px -28px var(--shade),
    0 12px 24px -16px var(--shade);
  background: var(--key);
}
.js .phone:not(.is-current) { transform: scale(0.88); opacity: 0.62; cursor: pointer; }
.js .phone:not(.is-current):hover { opacity: 0.85; }

@media (max-width: 640px) {
  .strip { --phone-h: min(60svh, 520px); }
}

.chip-row {
  display: flex; align-items: center; justify-content: center;
  gap: var(--s4); padding-bottom: var(--s4);
}
.theme-chip {
  flex: 0 1 22rem; min-width: 0;
  text-align: center;
  font-family: var(--font-display);
}
.theme-chip .name { display: block; font-weight: 600; font-size: 1.375rem; letter-spacing: -0.02em; }
.theme-chip .meta { display: block; color: var(--ink-2); font-size: 0.9375rem; }
.chip-row .key { padding: 0; width: 56px; height: 56px; border-radius: 50%; }
.hint { color: var(--ink-2); font-size: 0.9375rem; text-align: center; padding-bottom: var(--s4); }
.hero + .section { padding-top: clamp(var(--s7), 7vw, var(--s9)); }
.hint kbd, kbd {
  font-family: var(--font-display); font-weight: 600; font-size: 0.875em;
  display: inline-block; min-width: 1.8em; padding: 0 0.4em;
  border-radius: 6px; background: var(--key); color: var(--ink);
  box-shadow: inset 0 -2px 0 rgb(0 0 0 / 0.25); text-align: center;
}

/* ---------- Sections ---------- */

.section { padding-block: clamp(var(--s8), 9vw, var(--s10)); }
.section h2 { font-size: clamp(2.1rem, 4.4vw, 4rem); max-width: 18ch; }
.lede { font-size: clamp(1.0625rem, 1.4vw, 1.25rem); max-width: 60ch; color: var(--ink-2); margin-top: var(--s5); }
.band-key { background: var(--key); }
.band-op { background: var(--op); color: var(--on-op); }
.band-op .lede, .band-op .muted { color: var(--on-op); }
.band-op :focus-visible { outline-color: var(--on-op); }
.band-ink :focus-visible { outline-color: var(--bg); }
.contact-card :focus-visible { outline-color: var(--on-op); }
.band-op a { text-decoration-color: currentColor; }
.band-op ::selection { background: var(--on-op); color: var(--op); }
.band-ink { background: var(--ink); color: var(--bg); }
.band-ink .lede, .band-ink .muted { color: var(--bg); opacity: 0.84; }
.band-ink a { text-decoration-color: var(--op); }
.band-ink ::selection { background: var(--bg); color: var(--ink); }
.band-op, .band-key, .band-ink {
  transition: background-color var(--theme-fade) var(--ease-out), color var(--theme-fade) var(--ease-out);
}
.muted { color: var(--ink-2); }

/* Families: a spec sheet, one row per family */
.families-intro {
  display: grid; gap: var(--s6) var(--s8);
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  align-items: end;
}
.families-intro figure { margin: 0; justify-self: end; width: min(440px, 100%); }
.families-intro figure img { border-radius: 22px; box-shadow: 0 0 0 1px var(--line), 0 24px 48px -30px var(--shade); }
/* Before → after: one sum, two themes, with a swipe arrow between. */
.swipe-pair .pair {
  display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center; gap: var(--s3);
}
.swipe-pair .pair img { width: 100%; height: auto; }
.swipe-arrow { width: 28px; height: 28px; color: var(--ink-2); }
.swipe-pair figcaption { text-align: center; }
.families-intro figcaption, .shot figcaption { color: var(--ink-2); font-size: 0.875rem; margin-top: var(--s3); line-height: 1.45; }
.guard { margin-top: var(--s5); max-width: 60ch; }

.family-list { list-style: none; margin: clamp(var(--s7), 6vw, var(--s9)) 0 0; padding: 0; }
.family {
  display: grid; gap: var(--s5) var(--s8);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
  padding-block: clamp(var(--s6), 4vw, var(--s7));
  border-top: 1px solid var(--line);
  align-items: center;
}
.family:last-child { border-bottom: 1px solid var(--line); }
.family h3 { font-size: clamp(1.75rem, 3vw, 2.75rem); }
.family p { margin-top: var(--s3); max-width: 46ch; }
.family dl {
  display: grid; grid-template-columns: auto 1fr; gap: var(--s1) var(--s4);
  margin: var(--s5) 0 0; font-size: 0.9375rem;
}
.family dt { color: var(--ink-2); font-family: var(--font-display); font-weight: 500; }
.family dd { margin: 0; }
.shots { display: flex; gap: var(--s4); justify-content: flex-end; }
.shots img {
  width: clamp(120px, 13vw, 180px); aspect-ratio: 9 / 20; object-fit: cover;
  border-radius: 18px; box-shadow: 0 0 0 1px var(--line), 0 18px 36px -24px var(--shade);
}
@media (max-width: 860px) {
  .families-intro, .family { grid-template-columns: 1fr; }
  .families-intro figure { justify-self: start; }
  .shots { justify-content: flex-start; overflow-x: auto; padding-bottom: var(--s2); }
  .shots img { width: 140px; flex: none; }
}

/* Exact maths: a running tape */
.exact-grid {
  display: grid; gap: var(--s7) var(--s8);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  align-items: start;
}
.exact h2 { font-size: clamp(2.6rem, 6vw, 5.5rem); max-width: 10ch; }
.tape {
  list-style: none; margin: 0; padding: 0;
  font-family: var(--font-display); font-variant-numeric: tabular-nums;
  border-top: 2px solid currentColor;
}
.tape li {
  display: grid; grid-template-columns: 1fr auto; align-items: baseline;
  gap: var(--s1) var(--s4);
  padding-block: var(--s4);
  border-bottom: 1px solid color-mix(in srgb, currentColor 28%, transparent);
}
.tape .expr { font-size: clamp(1.25rem, 2.2vw, 1.75rem); font-weight: 500; }
.tape .res { font-size: clamp(1.75rem, 3.4vw, 2.75rem); font-weight: 700; letter-spacing: -0.02em; text-align: right; }
.tape .float {
  grid-column: 1 / -1; font-family: var(--font-body); font-size: 0.9375rem;
}
.tape .float s { text-decoration-thickness: 2px; }
.exact .lede + .lede { margin-top: var(--s4); }

@media (max-width: 860px) { .exact-grid { grid-template-columns: 1fr; } }

/* Amount in words */
.words-grid {
  display: grid; gap: var(--s7) var(--s8);
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  margin-top: clamp(var(--s6), 5vw, var(--s8));
  align-items: start;
}
.display {
  background: var(--key); border-radius: 28px;
  padding: clamp(var(--s5), 3vw, var(--s6));
  box-shadow: 0 0 0 1px var(--line), 0 24px 48px -32px var(--shade);
}
.display label { display: block; font-family: var(--font-display); font-weight: 500; color: var(--ink-2); font-size: 0.9375rem; }
.display input {
  width: 100%; margin-top: var(--s2);
  background: transparent; border: 0; border-bottom: 2px solid var(--line);
  color: var(--ink); caret-color: var(--op);
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(2rem, 5vw, 3.5rem); letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums; text-align: right;
  padding: var(--s2) 0; border-radius: 0;
}
.display input:focus { outline: none; border-bottom-color: var(--op); }
.display input:focus-visible { outline: none; }
.presets { display: flex; flex-wrap: wrap; gap: var(--s2); margin-top: var(--s4); }
.presets .key { min-height: 44px; padding: var(--s2) var(--s4); font-size: 0.9375rem; border-radius: 14px; --face: var(--bg); }
.readouts { margin: var(--s5) 0 0; display: grid; gap: var(--s5); }
.readout { border-top: 1px solid var(--line); padding-top: var(--s4); }
.readout dt { font-family: var(--font-display); font-weight: 500; color: var(--ink-2); font-size: 0.9375rem; }
.readout .grouped { font-family: var(--font-display); font-variant-numeric: tabular-nums; color: var(--ink-2); }
.readout .compact { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.5rem, 2.6vw, 2rem); letter-spacing: -0.015em; line-height: 1.2; }
.readout .spelled { margin-top: var(--s1); max-width: 60ch; }
.readout dd { margin: var(--s1) 0 0; }
.words-aside { display: grid; gap: var(--s5); }
.words-aside .shots { justify-content: flex-start; }
.words-aside ul { margin: 0; padding-left: 1.1em; display: grid; gap: var(--s2); }
.words-aside li::marker { color: var(--op); }
@media (max-width: 860px) { .words-grid { grid-template-columns: 1fr; } }

/* Sounds */
.sound-grid {
  display: grid; gap: var(--s7) var(--s8);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
}
.packs { border: 0; margin: var(--s6) 0 0; padding: 0; }
.packs legend { font-family: var(--font-display); font-weight: 600; margin-bottom: var(--s3); padding: 0; }
.pack-list { display: flex; flex-wrap: wrap; gap: var(--s2); }
.pack input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pack span {
  display: inline-flex; align-items: center; min-height: 44px;
  padding: var(--s2) var(--s4); border-radius: 14px; cursor: pointer;
  background: var(--bg); color: var(--ink);
  font-family: var(--font-display); font-weight: 500; font-size: 0.9375rem;
  box-shadow: inset 0 -3px 0 rgb(0 0 0 / 0.2), 0 0 0 1px var(--line);
  transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out), transform 90ms var(--ease-out);
}
.pack input:checked + span { background: var(--op); color: var(--on-op); box-shadow: inset 0 -1px 0 rgb(0 0 0 / 0.2); transform: translateY(2px); }
.pack input:focus-visible + span { outline: 3px solid var(--ink); outline-offset: 2px; }
.match { display: flex; align-items: center; gap: var(--s3); margin-top: var(--s4); font-size: 0.9375rem; cursor: pointer; }
.match input { width: 22px; height: 22px; accent-color: var(--op); margin: 0; }
.pad-wrap { justify-self: center; width: min(400px, 100%); }
.pad {
  background: var(--bg); border-radius: 32px; padding: var(--s5);
  box-shadow: 0 0 0 1px var(--line), 0 30px 60px -36px var(--shade);
}
.pad-display {
  font-family: var(--font-display); font-variant-numeric: tabular-nums;
  text-align: right; min-height: 3.6rem; padding: var(--s2) var(--s2) var(--s4);
  font-size: 2.25rem; font-weight: 500; letter-spacing: -0.02em;
  overflow: hidden; white-space: nowrap; text-overflow: clip; direction: rtl;
}
.pad-display span { direction: ltr; unicode-bidi: isolate; }
.pad-keys { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s3); }
.pad-keys .key { padding: 0; height: 64px; font-size: 1.5rem; border-radius: 22px; }
.pad-keys .tall { grid-row: span 2; height: auto; }
.pad-note { color: var(--ink-2); font-size: 0.875rem; margin-top: var(--s4); text-align: center; }
@media (max-width: 860px) { .sound-grid { grid-template-columns: 1fr; } }

/* The rest: a ruled ledger */
.rest-grid {
  display: grid; gap: var(--s7) var(--s8);
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  margin-top: clamp(var(--s6), 4vw, var(--s7));
  align-items: start;
}
.ledger { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--s7); }
.ledger div { border-top: 1px solid var(--line); padding: var(--s4) 0 var(--s5); }
.ledger dt { font-family: var(--font-display); font-weight: 600; font-size: 1.1875rem; letter-spacing: -0.01em; }
.ledger dd { margin: var(--s1) 0 0; color: var(--ink-2); }
.rest-grid .shot { margin: 0; justify-self: end; width: min(260px, 100%); }
.rest-grid .shot img { border-radius: 22px; box-shadow: 0 0 0 1px var(--line), 0 24px 48px -30px var(--shade); }
@media (max-width: 860px) {
  .rest-grid { grid-template-columns: 1fr; }
  .rest-grid .shot { justify-self: start; }
}
@media (max-width: 560px) { .ledger { grid-template-columns: 1fr; } }

/* Privacy (inverted band) */
.privacy h2 { font-size: clamp(2.4rem, 5.6vw, 5rem); max-width: 13ch; }
.no-list {
  list-style: none; margin: clamp(var(--s6), 4vw, var(--s7)) 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--s7);
}
.no-list li {
  display: grid; grid-template-columns: 28px 1fr; gap: var(--s3);
  padding-block: var(--s4); border-top: 1px solid color-mix(in srgb, currentColor 22%, transparent);
}
.no-list svg { width: 24px; height: 24px; margin-top: 3px; color: var(--op); }
.no-list strong { font-family: var(--font-display); font-weight: 600; display: block; font-size: 1.125rem; }
.privacy-foot { margin-top: var(--s6); display: flex; flex-wrap: wrap; gap: var(--s3) var(--s6); align-items: center; }
@media (max-width: 720px) { .no-list { grid-template-columns: 1fr; } }

/* Close */
.close { text-align: center; }
.close img { width: clamp(112px, 14vw, 160px); height: auto; margin: 0 auto var(--s6); border-radius: 22%; box-shadow: 0 28px 50px -26px var(--shade); }
.close h2 { margin-inline: auto; max-width: 14ch; }
.close .lede { margin-inline: auto; }
.close .store-row { justify-content: center; margin-top: var(--s6); }
.next-up { margin: var(--s7) auto 0; max-width: 56ch; color: var(--ink-2); font-size: 0.9375rem; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding-block: var(--s6) var(--s7); font-size: 0.9375rem; color: var(--ink-2); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s4) var(--s6); }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--s2) var(--s5); }
.site-footer a { color: var(--ink); }

/* ---------- Reading pages (privacy, support, theme link) ---------- */

.page-head { padding-block: clamp(var(--s7), 7vw, var(--s9)) clamp(var(--s6), 4vw, var(--s7)); }
.page-head h1 { font-size: clamp(2.4rem, 6vw, 4.75rem); letter-spacing: -0.04em; max-width: 16ch; }
.page-head .lede { margin-top: var(--s4); }
.prose { max-width: 68ch; padding-bottom: clamp(var(--s8), 8vw, var(--s10)); }
.prose h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); margin: var(--s7) 0 var(--s3); letter-spacing: -0.02em; }
.prose h3 { font-size: 1.25rem; margin: var(--s6) 0 var(--s2); letter-spacing: -0.01em; }
.prose p + p, .prose p + ul, .prose ul + p { margin-top: var(--s4); }
.prose ul, .prose ol { padding-left: 1.2em; margin: var(--s3) 0 0; display: grid; gap: var(--s2); }
.prose li::marker { color: var(--op); font-weight: 700; }
.prose strong { font-weight: 650; }
.updated { font-family: var(--font-display); color: var(--ink-2); font-size: 0.9375rem; }

.contact-card {
  background: var(--op); color: var(--on-op); border-radius: 28px;
  padding: clamp(var(--s5), 4vw, var(--s7));
  display: grid; gap: var(--s3); margin-bottom: var(--s7);
}
.contact-card a { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.5rem, 4vw, 2.5rem); letter-spacing: -0.02em; text-decoration-color: currentColor; word-break: break-word; }
.contact-card p { max-width: 54ch; }

.faq details { border-top: 1px solid var(--line); }
.faq details:last-of-type { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; padding: var(--s4) 0;
  display: flex; justify-content: space-between; gap: var(--s4); align-items: center;
  font-family: var(--font-display); font-weight: 600; font-size: 1.1875rem; letter-spacing: -0.01em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { width: 22px; height: 22px; flex: none; color: var(--op); transition: transform 220ms var(--ease-out); }
.faq details[open] summary svg { transform: rotate(45deg); }
.faq .answer { padding: 0 0 var(--s5); display: grid; gap: var(--s3); }
.faq .answer p, .faq .answer ul { margin: 0; }
.faq-group { margin-top: var(--s7); }
.faq-group h2 { margin: 0 0 var(--s3); }

/* Theme link page */
.share { padding-block: clamp(var(--s6), 6vw, var(--s9)) clamp(var(--s8), 8vw, var(--s10)); }
.share-grid {
  display: grid; gap: var(--s7) var(--s8);
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); align-items: center;
}
.share h1 { font-size: clamp(2.4rem, 5.6vw, 4.5rem); letter-spacing: -0.04em; max-width: 13ch; }
.code-display {
  font-family: var(--font-display); font-variant-numeric: tabular-nums;
  font-size: clamp(1.9rem, 5vw, 3.25rem); font-weight: 600; letter-spacing: 0.04em;
  margin-top: var(--s5); word-break: break-all;
}
.share-meta { color: var(--ink-2); margin-top: var(--s2); font-size: 1.0625rem; }
.share-actions { display: flex; flex-wrap: wrap; gap: var(--s3); margin-top: var(--s6); align-items: center; }
.share-note { margin-top: var(--s5); max-width: 52ch; color: var(--ink-2); font-size: 0.9375rem; }
.share-shot { justify-self: center; width: min(300px, 80vw); }
.share-shot img { border-radius: 26px; box-shadow: 0 0 0 1px var(--line), 0 30px 60px -28px var(--shade); }
.code-form { display: flex; flex-wrap: wrap; gap: var(--s3); margin-top: var(--s6); align-items: end; }
.code-form label { display: grid; gap: var(--s1); font-family: var(--font-display); font-weight: 500; color: var(--ink-2); font-size: 0.9375rem; }
.code-form input {
  min-height: 52px; min-width: min(16rem, 100%); padding: 0 var(--s4);
  border-radius: 14px; border: 2px solid var(--line); background: var(--key); color: var(--ink);
  font-family: var(--font-display); font-size: 1.25rem; letter-spacing: 0.06em; text-transform: uppercase;
  font-variant-numeric: tabular-nums;
}
.code-form input:focus { outline: none; border-color: var(--op); }
.error-text { color: var(--ink); font-weight: 600; }
[hidden] { display: none !important; }
@media (max-width: 860px) { .share-grid { grid-template-columns: 1fr; } .share-shot { justify-self: start; } }

/* ---------- Motion preferences ---------- */

/* Reduced motion: nothing moves or scales; colours still change, as a
   short fade (the app does the same). */
@media (prefers-reduced-motion: reduce) {
  :root { --theme-fade: 150ms; }
  html { scroll-behavior: auto; }
  .phone, .key, .pack span, .faq summary svg { transition-property: opacity, background-color, color, box-shadow; }
  .js .phone:not(.is-current) { transform: none; }
  .key:active, .key.is-down, .pack input:checked + span { transform: none; }
}
.static-amount { font-family: var(--font-display); font-size: clamp(2rem, 5vw, 3.5rem); text-align: right; font-variant-numeric: tabular-nums; margin-top: var(--s2); }
.nf-title { margin-top: var(--s5); font-size: clamp(2.4rem, 5.6vw, 4.5rem); letter-spacing: -0.04em; max-width: 14ch; }
@media (max-width: 480px) {
  .store-row .store-key { flex: 1 1 0; min-width: 0; padding-inline: var(--s4); }
  .store-key strong { font-size: 1.0625rem; }
}
.pad-keys .key--op, .pad-keys .key--eq { font-size: 1.875rem; font-weight: 500; }

/* Coming-soon store labels are not controls: flat, no keycap bevel. */
.store-key, .store-key:active {
  box-shadow: inset 0 0 0 1.5px var(--line);
  transform: none;
}
@media (max-width: 640px) {
  .hero .store-row { display: none; }
  .hero .avail-line { display: block; }
  .strip { --phone-h: min(42svh, 520px); }
}

.avail-line { display: none; font-family: var(--font-display); font-weight: 500; font-size: 0.9375rem; color: var(--ink); margin-top: calc(-1 * var(--s3)); }
.prose ol + p { margin-top: var(--s4); }
