/* SMS Desk website. Apple-style product page in the SMS Desk palette.
   Logo is fixed (assets/logo-*.svg). Teal = action and links, marigold = money and the logo line,
   red = a fake sender and nothing else. */

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light dark;

  /* page */
  --bg: #ffffff;
  --bg-alt: #f5f5f7;
  --tile: #ffffff;
  --ink: #1d1d1f;
  --ink-2: #6e6e73;
  --hair: #d2d2d7;
  --link: #0b6468;
  --pill: #0b6468;
  --on-pill: #ffffff;
  --money: #946000;
  --nav-bg: rgb(255 255 255 / 0.78);

  /* black sections stay black in both themes */
  --night: #000000;
  --night-tile: #161617;
  --night-ink: #f5f5f7;
  --night-ink-2: #a1a1a6;
  --night-link: #7fd6d1;
  --night-hair: #2c2c2e;

  /* app screen (tokens-brand.json, light) */
  --app-bg: #ffffff;
  --app-surface: #eef2f3;
  --app-tint: #e7f3f2;
  --app-border: #dbe2e5;
  --app-text: #14191c;
  --app-muted: #58626a;
  --app-accent: #0b6468;
  --app-on-accent: #ffffff;
  --app-accent-soft: #c9e8e6;
  --app-danger-soft: #fdeceb;
  --app-on-danger-soft: #8f1a1a;
  --app-flag: #eceff1;
  --app-on-flag: #424a50;
  --app-hl-soft: #fdf0d9;
  --app-on-hl-soft: #6b4400;
  --app-av1: #e3eef8;
  --app-av2: #e5f2ee;
  --app-av3: #f6edd9;
  --app-av-text: #4a545b;

  --danger: #b42323;
  --marigold: #f2a93b;

  --font: "Inter", -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;
  --wrap: 980px;
  --wide: 1200px;
  --g: 22px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000;
    --bg-alt: #101012;
    --tile: #1c1c1e;
    --ink: #f5f5f7;
    --ink-2: #a1a1a6;
    --hair: #38383a;
    --link: #7fd6d1;
    --pill: #5cc3bf;
    --on-pill: #04201f;
    --money: #f5b956;
    --nav-bg: rgb(22 22 23 / 0.78);
    --night: #101012;
    --night-tile: #1c1c1e;

    --app-bg: #0b0f11;
    --app-surface: #172024;
    --app-tint: #10272a;
    --app-border: #2b363b;
    --app-text: #e4e9eb;
    --app-muted: #a0abb1;
    --app-accent: #5cc3bf;
    --app-on-accent: #04201f;
    --app-accent-soft: #123c3e;
    --app-danger-soft: #3a1513;
    --app-on-danger-soft: #ff8c86;
    --app-flag: #172024;
    --app-on-flag: #a0abb1;
    --app-hl-soft: #33240b;
    --app-on-hl-soft: #f5b956;
    --app-av1: #172024;
    --app-av2: #172024;
    --app-av3: #172024;
    --app-av-text: #e4e9eb;

    --danger: #ff8c86;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 64px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "cv11", "ss03";
}

::selection { background: #c9e8e6; color: #14191c; }
html { scrollbar-color: var(--hair) var(--bg); accent-color: var(--pill); }
:focus-visible { outline: 3px solid var(--link); outline-offset: 3px; border-radius: 6px; }

img, svg { display: block; max-width: 100%; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3 { text-wrap: balance; margin: 0; }
p { text-wrap: pretty; }

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

.skip { position: absolute; left: -9999px; top: 8px; z-index: 20; background: var(--pill); color: var(--on-pill); padding: 8px 14px; border-radius: 999px; }
.skip:focus { left: 8px; }

/* ---------- Product bar ---------- */

.bar {
  position: sticky; top: 0; z-index: 10;
  background: var(--nav-bg);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--hair);
}
.bar .wide { display: flex; align-items: center; justify-content: space-between; height: 52px; gap: 16px; }
.brand { display: inline-flex; align-items: center; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand img { height: 26px; width: auto; }
.bar nav { display: flex; align-items: center; gap: 20px; font-size: 13px; }
.bar nav a.quiet { color: var(--ink); opacity: 0.86; }
.bar nav a.quiet[aria-current="page"] { opacity: 1; color: var(--ink-2); }

.pill {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 44px; padding: 0 22px; border-radius: 999px;
  background: var(--pill); color: var(--on-pill);
  font-size: 17px; font-weight: 500; letter-spacing: -0.01em; white-space: nowrap;
  transition: filter 160ms ease, transform 160ms ease;
}
.pill:hover { text-decoration: none; filter: brightness(1.12); }
.pill:active { transform: scale(0.98); }
.pill.small { min-height: 28px; padding: 0 12px; font-size: 12px; }
.bar .pill.small { min-height: 32px; }

.more { font-size: 17px; white-space: nowrap; }
.more::after { content: ""; display: inline-block; width: 7px; height: 7px; margin-left: 6px; border: solid currentColor; border-width: 1.5px 1.5px 0 0; transform: translateY(-1px) rotate(45deg); }

/* ---------- Type scale ---------- */

.display { font-size: clamp(48px, 9.6vw, 96px); line-height: 1.04; font-weight: 700; letter-spacing: -0.035em; }
.headline { font-size: clamp(36px, 6.4vw, 64px); line-height: 1.06; font-weight: 700; letter-spacing: -0.03em; }
.lead { font-size: clamp(19px, 2.3vw, 24px); line-height: 1.35; font-weight: 500; letter-spacing: -0.015em; color: var(--ink-2); }
.lead strong { color: var(--ink); font-weight: 600; }
.small-print { font-size: 14px; color: var(--ink-2); }

section { position: relative; }
.pad { padding: 96px 0; }
@media (min-width: 734px) { .pad { padding: 140px 0; } }
.alt { background: var(--bg-alt); }
.dark { background: var(--night); color: var(--night-ink); }
.dark .lead { color: var(--night-ink-2); }
.dark .lead strong { color: var(--night-ink); }
.dark a { color: var(--night-link); }
.center { text-align: center; }

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

.hero { padding-top: 56px; overflow: hidden; text-align: center; }
@media (min-width: 734px) { .hero { padding-top: 88px; } }
.hero .lead { margin: 14px auto 0; max-width: 22em; }
.hero .lead strong { display: block; }
.actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 28px; margin-top: 32px; }
.hero .note { margin-top: 18px; }

.stage { --w: min(86vw, 380px); position: relative; margin-top: 48px; display: grid; justify-items: center; font-size: calc(var(--w) * 0.0405); }
.crop { --w: inherit; height: calc(var(--w) * 1.32); overflow: hidden; -webkit-mask-image: linear-gradient(#000 78%, transparent); mask-image: linear-gradient(#000 78%, transparent); }
.stage .hero-phone { --w: inherit; }
.hero { padding-bottom: 72px; }
@media (min-width: 1000px) {
  .hero { padding-bottom: 0; }
  .crop { height: auto; overflow: visible; -webkit-mask-image: none; mask-image: none; }
  .stage .hero-phone { margin-bottom: calc(var(--w) * -0.62); }
}
.callouts { display: none; }

.legend { list-style: none; margin: 28px auto 0; padding: 0; max-width: 360px; display: grid; gap: 12px; text-align: left; font-size: 15px; color: var(--ink-2); }
.legend li { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: baseline; }
.tag-demo { padding: 3px 8px; border-radius: 6px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.tag-demo.red { background: var(--app-danger-soft); color: var(--app-on-danger-soft); }
.tag-demo.grey { background: var(--app-flag); color: var(--app-on-flag); }
.id-demo { font-weight: 700; color: var(--ink); font-size: 14px; padding: 3px 0; white-space: nowrap; }
@media (min-width: 1000px) { .legend { display: none; } }

@media (min-width: 1000px) {
  .stage { margin-top: 72px; grid-template-columns: 1fr auto 1fr; align-items: start; column-gap: 40px; }
  .callouts { display: block; position: relative; height: 100%; justify-self: stretch; }
  .callout { position: absolute; width: 240px; text-align: left; font-size: 15px; line-height: 1.4; color: var(--ink-2); }
  /* row centres measured in the phone's own em (stage font-size = --w * 0.0405); 12px = leader offset */
  .callout.c-id { top: calc(var(--w) * 0.0405 * 20.62 - 12px); }
  .callout.c-fake { top: calc(var(--w) * 0.0405 * 15.53 - 12px); }
  .callout.c-grey { top: calc(var(--w) * 0.0405 * 27.66 - 12px); }
  .callout strong { display: block; color: var(--ink); font-size: 17px; font-weight: 600; letter-spacing: -0.015em; margin-bottom: 2px; }
  .callout::before { content: ""; position: absolute; top: 12px; height: 1px; width: 52px; background: var(--hair); }
  .callouts.left .callout { right: 0; text-align: right; }
  .callouts.left .callout::before { right: -64px; }
  .callouts.right .callout { left: 0; }
  .callouts.right .callout::before { left: -64px; }
}

/* ---------- Phone (drawn, shows the app's real layout) ---------- */

.phone {
  width: var(--w, min(84vw, 330px)); aspect-ratio: 9 / 19.2;
  --w: min(84vw, 330px);
  padding: calc(var(--w) * 0.03);
  border-radius: calc(var(--w) * 0.15);
  background: #1d1d1f;
  box-shadow: inset 0 0 0 2px #3a3a3c, 0 50px 80px -40px rgb(0 0 0 / 0.45), 0 20px 30px -20px rgb(0 0 0 / 0.3);
  text-align: left;
  font-size: calc(var(--w) * 0.0405);
  letter-spacing: 0;
  line-height: 1.3;
}
.screen {
  position: relative; height: 100%; overflow: hidden;
  border-radius: calc(var(--w) * 0.125);
  background: linear-gradient(var(--app-tint), var(--app-bg) 28%);
  color: var(--app-text);
  display: flex; flex-direction: column;
}
.screen::before { /* punch-hole camera */
  content: ""; position: absolute; top: 1.1em; left: 50%; width: 0.9em; height: 0.9em; margin-left: -0.45em;
  border-radius: 50%; background: #0b0b0c; z-index: 2;
}
.status { display: flex; justify-content: space-between; align-items: center; padding: 1.05em 1.6em 0.4em; font-size: 0.9em; font-weight: 600; }
.status .icons { display: flex; gap: 0.35em; align-items: center; }
.status svg { width: 1.05em; height: 1.05em; }
.appbar { display: flex; align-items: center; justify-content: space-between; padding: 1.6em 1.2em 0.6em 1.3em; }
.appbar .t { font-size: 2.05em; font-weight: 500; letter-spacing: -0.02em; }
.appbar .tools { display: flex; gap: 1.1em; color: var(--app-text); }
.appbar svg { width: 1.35em; height: 1.35em; }
.chips { display: flex; gap: 0.5em; padding: 0.6em 1.2em 0.9em; overflow: hidden; }
.chip { flex: none; padding: 0.42em 0.95em; border-radius: 999px; border: 1px solid var(--app-border); font-size: 0.95em; font-weight: 500; white-space: nowrap; background: var(--app-bg); }
.chip.on { background: var(--app-accent); border-color: var(--app-accent); color: var(--app-on-accent); }
.list { flex: 1; overflow: hidden; background: var(--app-bg); }
.msg { position: relative; display: grid; grid-template-columns: 2.7em 1fr auto; gap: 0.8em; padding: 0.85em 1.2em; align-items: start; }
.msg + .msg::before { content: ""; position: absolute; top: 0; left: 4.7em; right: 0; height: 1px; background: var(--app-border); }
.av { width: 2.7em; height: 2.7em; border-radius: 50%; display: grid; place-items: center; font-weight: 500; font-size: 1.15em; background: var(--app-av1); color: var(--app-av-text); }
.av.b { background: var(--app-av2); }
.av.c { background: var(--app-av3); }
.av.fake { background: var(--app-danger-soft); color: var(--app-on-danger-soft); }
.who { font-weight: 600; font-size: 1.08em; overflow-wrap: anywhere; }
.snip { color: var(--app-muted); margin-top: 0.15em; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.when { font-size: 0.85em; color: var(--app-muted); text-align: right; white-space: nowrap; }
.when.new { color: var(--app-accent); font-weight: 600; }
.badge { display: inline-grid; place-items: center; min-width: 1.5em; height: 1.5em; margin-top: 0.35em; border-radius: 999px; background: var(--app-accent); color: var(--app-on-accent); font-size: 0.8em; font-weight: 600; }
.tag { display: inline-block; margin-top: 0.35em; padding: 0.22em 0.55em; border-radius: 0.45em; font-size: 0.82em; font-weight: 500; line-height: 1.3; }
.tag.red { background: var(--app-danger-soft); color: var(--app-on-danger-soft); }
.tag.grey { background: var(--app-flag); color: var(--app-on-flag); }
.fab { position: absolute; right: 1.2em; bottom: 5.4em; width: 3.6em; height: 3.6em; border-radius: 1.1em; background: var(--app-accent); color: var(--app-on-accent); display: grid; place-items: center; box-shadow: 0 6px 14px -6px rgb(0 0 0 / 0.4); }
.fab svg { width: 1.4em; height: 1.4em; }
.nav { display: grid; grid-template-columns: 1fr 1fr 1fr; text-align: center; padding: 1em 0 1.8em; background: var(--app-tint); font-size: 0.95em; color: var(--app-muted); }
.nav .on { color: var(--app-accent); font-weight: 600; }
.nav::after { content: ""; grid-column: 1 / -1; justify-self: center; width: 30%; height: 0.25em; border-radius: 1em; background: var(--app-text); opacity: 0.6; margin-top: 1.1em; }

/* finance screen */
.fin-list { background: var(--app-bg); }
.showbal { display: flex; justify-content: space-between; align-items: center; gap: 1em; padding: 0.8em 1.3em; background: var(--app-tint); }
.snip.multi { display: block; -webkit-line-clamp: unset; }
.showbal .sw { flex: none; width: 2.6em; height: 1.5em; border-radius: 1em; background: var(--app-accent); position: relative; }
.showbal .sw::after { content: ""; position: absolute; top: 0.2em; right: 0.2em; width: 1.1em; height: 1.1em; border-radius: 50%; background: var(--app-on-accent); }
.fin-list .sec { margin: 0; padding: 0.9em 1.3em 0.5em; background: var(--app-surface); color: var(--app-muted); font-size: 0.88em; font-weight: 600; }
.acct-row { display: flex; justify-content: space-between; align-items: center; gap: 1em; padding: 0.85em 1.3em; }
.acct-row + .acct-row { box-shadow: inset 0 1px 0 var(--app-border); }
.acct-row .amt { font-size: 1.25em; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.fin-list .due { margin: 0 1.3em 0.8em; padding: 0.6em 0.8em; border-radius: 0.6em; background: var(--app-hl-soft); color: var(--app-on-hl-soft); font-size: 0.92em; }
.fin-list .due b { font-variant-numeric: tabular-nums; }
.fin-head { padding: 1.6em 1.3em 0.4em; font-size: 2.05em; font-weight: 500; letter-spacing: -0.02em; }
.fin { margin: 0.8em 1.1em 0; background: var(--app-bg); border: 1px solid var(--app-border); border-radius: 1.1em; overflow: hidden; }
.fin .row { padding: 0.95em 1.1em; }
.fin .row + .row { border-top: 1px solid var(--app-border); }
.fin .acct { color: var(--app-muted); font-size: 0.92em; }
.fin .amt { font-size: 1.9em; font-weight: 600; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; margin-top: 0.1em; }
.fin .src { color: var(--app-muted); font-size: 0.88em; }
.fin .due { margin: 0 1.1em 1em; padding: 0.7em 0.9em; border-radius: 0.7em; background: var(--app-hl-soft); color: var(--app-on-hl-soft); display: flex; justify-content: space-between; font-size: 0.92em; }
.fin .due b { font-variant-numeric: tabular-nums; }
.fin-foot { margin: 0.9em 1.3em; color: var(--app-muted); font-size: 0.85em; }

/* ---------- Sender anatomy (dark) ---------- */

.anatomy { margin-top: 72px; }
.idline { display: flex; justify-content: center; align-items: baseline; flex-wrap: wrap; font-size: clamp(44px, 9.6vw, 96px); font-weight: 700; letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.idline .dash { color: var(--night-ink-2); font-weight: 400; padding: 0 0.04em; }
.idline .part { position: relative; }
.idline .exp { display: none; }
@media (min-width: 900px) {
  .anatomy .parts { display: none; }
  .idline { margin-bottom: 170px; }
  .idline .exp {
    display: block; position: absolute; top: 100%; margin-top: 34px; width: 220px;
    font-size: 15px; line-height: 1.4; font-weight: 400; letter-spacing: -0.005em; color: var(--night-ink-2); text-align: left;
  }
  .idline .exp::before { content: ""; position: absolute; top: -26px; left: 0; width: 1px; height: 18px; background: var(--night-ink-2); }
  .idline .exp b { display: block; color: var(--night-ink); font-size: 17px; font-weight: 600; }
  .idline .p1 .exp { left: 0.06em; }
  .idline .p2 .exp { left: 50%; margin-left: -110px; text-align: center; }
  .idline .p2 .exp::before { left: 50%; }
  .idline .p3 .exp { right: 0.06em; text-align: right; }
  .idline .p3 .exp::before { left: auto; right: 0; }
}
.parts { display: grid; grid-template-columns: 1fr; gap: 20px; max-width: 760px; margin: 40px auto 0; text-align: left; }
.parts div { border-top: 1px solid var(--night-hair); padding-top: 14px; color: var(--night-ink-2); font-size: 15px; }
.parts b { display: block; color: var(--night-ink); font-size: 19px; font-weight: 600; letter-spacing: -0.015em; margin-bottom: 2px; }
@media (min-width: 734px) { .parts { grid-template-columns: repeat(3, 1fr); gap: 28px; } }

.versus { margin: 72px auto 0; scroll-margin-top: 80px; max-width: 760px; border-radius: 28px; background: var(--night-tile); padding: 36px 28px; text-align: left; display: grid; gap: 22px; }
@media (min-width: 734px) { .versus { padding: 48px 56px; } }
.versus .fake-id { font-size: clamp(36px, 6.4vw, 64px); font-weight: 700; letter-spacing: -0.03em; line-height: 1; text-decoration: line-through; text-decoration-color: var(--danger); text-decoration-thickness: 0.07em; }
.versus .why { font-size: clamp(19px, 2.4vw, 24px); line-height: 1.35; font-weight: 500; color: var(--night-ink); letter-spacing: -0.015em; }
.versus .why .red { color: #ff8c86; }
.versus .small-print { color: var(--night-ink-2); }

/* ---------- Privacy bento ---------- */

.bento { display: grid; gap: 20px; margin-top: 64px; grid-template-columns: 1fr; }
.tile { background: var(--tile); border-radius: 28px; padding: 36px 30px; overflow: hidden; }
.t-a, .t-e { display: grid; gap: 28px; }
.tile h3 { font-size: clamp(26px, 3.4vw, 40px); line-height: 1.08; font-weight: 700; letter-spacing: -0.028em; }
.tile p { margin: 12px 0 0; color: var(--ink-2); font-size: 17px; max-width: 30em; }
.tile.hero-tile h3 { font-size: clamp(36px, 6.4vw, 64px); }
@media (min-width: 734px) {
  .bento { grid-template-columns: repeat(6, 1fr); }
  .tile { padding: 44px 40px; }
  .t-a { grid-column: span 6; display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center; }
  .t-b, .t-c, .t-d { grid-column: span 2; }
  .t-e { grid-column: span 6; display: grid; grid-template-columns: 1fr 1.1fr; gap: 40px; align-items: center; }
}
.perms { border-radius: 18px; background: var(--bg-alt); padding: 6px 20px; font-size: 17px; }
.perms .grp { margin: 0; padding: 14px 0 4px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.perms .grp + div { border-top: 0; }
.perms div { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; }
.perms div + div { border-top: 1px solid var(--hair); }
.perms span:last-child { color: var(--ink-2); white-space: nowrap; }
.perms .off span:first-child { font-weight: 600; }
.perms .off span:last-child { color: var(--link); font-weight: 600; }
.folder { border-radius: 18px; background: var(--bg-alt); padding: 22px; display: grid; gap: 14px; font-size: 17px; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-weight: 600; }
.crumbs i { font-style: normal; color: var(--ink-2); font-weight: 400; }
.seg { display: inline-grid; grid-auto-flow: column; background: var(--tile); border-radius: 10px; padding: 3px; gap: 2px; justify-self: start; border: 1px solid var(--hair); font-size: 14px; }
.seg span { padding: 6px 14px; border-radius: 8px; color: var(--ink-2); }
.seg .on { background: var(--pill); color: var(--on-pill); font-weight: 600; }

/* ---------- Money ---------- */

.split { display: grid; gap: 56px; align-items: center; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr auto; gap: 80px; } }
.split .lead { margin-top: 20px; max-width: 24em; }
.facts { margin: 36px 0 0; padding: 0; list-style: none; display: grid; gap: 22px; max-width: 30em; }
.facts li { border-top: 1px solid var(--hair); padding-top: 14px; color: var(--ink-2); }
.facts b { display: block; color: var(--ink); font-weight: 600; font-size: 19px; letter-spacing: -0.015em; }
.facts .rupee { color: var(--money); }
.split .phone { justify-self: center; }

/* ---------- Alerts (dark) ---------- */

.alerts-grid { display: grid; gap: 20px; margin-top: 64px; }
@media (min-width: 900px) { .alerts-grid { grid-template-columns: 1.05fr 1fr; } }
.alerts-grid .panel { background: var(--night-tile); border-radius: 28px; padding: 32px 28px; }
@media (min-width: 734px) { .alerts-grid .panel { padding: 44px 40px; } }
.notice { display: grid; grid-template-columns: 40px 1fr; gap: 16px; align-items: start; }
.notice .ic { width: 40px; height: 40px; border-radius: 12px; background: #123c3e; color: #7fd6d1; display: grid; place-items: center; }
.notice .ic svg { width: 22px; height: 22px; }
.notice .txt { font-size: clamp(19px, 2.3vw, 24px); line-height: 1.36; font-weight: 500; letter-spacing: -0.012em; }
.notice .txt b { font-weight: 700; }
.notice .fixbtn { grid-column: 2; justify-self: start; margin-top: 6px; padding: 8px 18px; border-radius: 999px; background: #5cc3bf; color: #04201f; font-size: 15px; font-weight: 600; }
.panel .cap { margin: 0 0 18px; color: var(--night-ink-2); font-size: 15px; }
.switches div { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 15px 0; font-size: 17px; }
.switches div + div { border-top: 1px solid var(--night-hair); }
.switches .state { display: inline-flex; align-items: center; gap: 10px; color: var(--night-ink-2); font-size: 15px; white-space: nowrap; }
.toggle { width: 44px; height: 26px; border-radius: 999px; background: #5cc3bf; position: relative; flex: none; }
.toggle::after { content: ""; position: absolute; top: 3px; right: 3px; width: 20px; height: 20px; border-radius: 50%; background: #04201f; }
.toggle.off { background: #3a3a3c; }
.toggle.off::after { right: auto; left: 3px; background: #a1a1a6; }
.switches .culprit { color: var(--night-ink); }
.switches .culprit .state { color: var(--night-ink); font-weight: 700; }

/* ---------- FAQ ---------- */

.faq { margin-top: 48px; border-top: 1px solid var(--hair); }
.faq details { border-bottom: 1px solid var(--hair); }
.faq summary { list-style: none; cursor: pointer; position: relative; padding: 24px 48px 24px 0; font-size: clamp(19px, 2.2vw, 24px); font-weight: 600; letter-spacing: -0.018em; line-height: 1.25; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before, .faq summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 16px; height: 2px; margin-top: -1px; border-radius: 2px; background: var(--ink-2); transition: transform 240ms cubic-bezier(0.16, 1, 0.3, 1); }
.faq summary::after { transform: rotate(90deg); }
.faq details[open] summary::after { transform: rotate(0); }
.faq summary:hover { color: var(--link); }
.faq details p { margin: 0 0 26px; max-width: 40em; color: var(--ink-2); font-size: 17px; }

/* ---------- Close ---------- */

.close .lead { margin: 18px auto 0; max-width: 26em; }
.close .actions { margin-top: 36px; }

/* ---------- Footer ---------- */

footer { background: var(--bg-alt); color: var(--ink-2); font-size: 12px; line-height: 1.5; padding: 22px 0 36px; }
footer .notes { margin: 0; padding: 0 0 16px; border-bottom: 1px solid var(--hair); list-style: none; display: grid; gap: 8px; max-width: 60em; }
footer .row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding-top: 16px; }
footer nav { display: flex; gap: 18px; }
footer a { color: var(--ink); }

/* ---------- Privacy page ---------- */

.doc-hero { padding: 72px 0 40px; text-align: center; }
.doc-hero .lead { margin: 18px auto 0; max-width: 24em; }
.doc-body { padding: 24px 0 120px; }
.doc-body .col { max-width: 692px; margin: 0 auto; }
.doc-body h2 { font-size: clamp(28px, 4vw, 40px); line-height: 1.12; letter-spacing: -0.025em; margin: 64px 0 0; }
.doc-body h2:first-child { margin-top: 0; }
.doc-body p, .doc-body li { color: var(--ink-2); font-size: 17px; }
.doc-body p { margin: 14px 0 0; }
.doc-body ul { margin: 16px 0 0; padding: 0; list-style: none; }
.doc-body li { padding: 14px 0; border-top: 1px solid var(--hair); }
.doc-body li strong { display: block; color: var(--ink); font-weight: 600; }
.doc-summary { max-width: 860px; margin: 8px auto 0; display: grid; gap: 16px; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 734px) { .doc-summary { grid-template-columns: repeat(4, 1fr); } }
.doc-summary div { background: var(--bg-alt); border-radius: 22px; padding: 22px 20px; text-align: left; font-size: 15px; color: var(--ink-2); }
.doc-summary b { display: block; color: var(--ink); font-size: 19px; letter-spacing: -0.02em; line-height: 1.15; margin-bottom: 4px; }

/* ---------- Motion: scroll-linked, content visible without it ---------- */

@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .idline .part { animation: spread linear both; animation-timeline: view(); animation-range: entry 20% cover 45%; }
    .idline .part.p1 { --dx: 0.18em; }
    .idline .part.p3 { --dx: -0.18em; }
    @keyframes spread { from { translate: var(--dx, 0) 0; } to { translate: 0 0; } }

    .versus .fake-id { animation: strike linear both; animation-timeline: view(); animation-range: entry 30% cover 50%; }
    @keyframes strike { from { text-decoration-color: transparent; } to { text-decoration-color: var(--danger); } }
  }
}

/* sender IDs never break mid-ID */
.notice .txt b, .why, .tag { overflow-wrap: normal; }
.notice .txt b, .nb { white-space: nowrap; }
@media (max-width: 419px) { .bar nav a.quiet[href$="#questions"] { display: none; } }

/* ---------- Sorted: tabs as a scroll story (fallback: tap the tabs) ---------- */

.sorted { padding: 96px 0; }
@media (min-width: 734px) { .sorted { padding: 140px 0; } }
.tab-in { position: absolute; opacity: 0; pointer-events: none; }
.tabbar { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 40px auto 0; padding: 0 var(--g); }
.tabbar label { cursor: pointer; padding: 8px 18px; border-radius: 999px; border: 1px solid var(--hair); background: var(--tile); font-size: 15px; font-weight: 500; }
.tabbar label:hover { border-color: var(--link); }
#tab-people:checked ~ .tabbar [for="tab-people"],
#tab-trans:checked ~ .tabbar [for="tab-trans"],
#tab-updates:checked ~ .tabbar [for="tab-updates"],
#tab-offers:checked ~ .tabbar [for="tab-offers"] { background: var(--pill); border-color: var(--pill); color: var(--on-pill); }
#tab-people:focus-visible ~ .tabbar [for="tab-people"],
#tab-trans:focus-visible ~ .tabbar [for="tab-trans"],
#tab-updates:focus-visible ~ .tabbar [for="tab-updates"],
#tab-offers:focus-visible ~ .tabbar [for="tab-offers"] { outline: 3px solid var(--link); outline-offset: 3px; }

.sort-stage { --w: min(84vw, 330px); display: grid; gap: 32px; justify-items: center; align-items: center; margin-top: 40px; padding: 0 var(--g); }
.sort-stage .phone { --w: inherit; }
.sort-copy { display: grid; max-width: 26em; text-align: center; }
.sort-copy .k, .plists .plist { grid-area: 1 / 1; display: none; }
.plists { display: grid; align-content: start; }
.sort-copy h3 { font-size: clamp(36px, 6.4vw, 64px); line-height: 1.04; font-weight: 700; letter-spacing: -0.03em; }
.sort-copy p { margin: 14px 0 0; color: var(--ink-2); font-size: clamp(19px, 2.3vw, 24px); line-height: 1.35; font-weight: 500; letter-spacing: -0.015em; }
.otp { display: inline-block; margin-top: 0.4em; padding: 0.3em 0.75em; border-radius: 999px; background: var(--app-accent-soft); color: var(--app-text); font-size: 0.85em; font-weight: 600; }

#tab-people:checked ~ .sort-stage .k1, #tab-trans:checked ~ .sort-stage .k2,
#tab-updates:checked ~ .sort-stage .k3, #tab-offers:checked ~ .sort-stage .k4 { display: block; }
#tab-people:checked ~ .sort-stage .c1, #tab-trans:checked ~ .sort-stage .c2,
#tab-updates:checked ~ .sort-stage .c3, #tab-offers:checked ~ .sort-stage .c4 { background: var(--app-accent); border-color: var(--app-accent); color: var(--app-on-accent); }

@media (min-width: 900px) {
  .sort-stage { grid-template-columns: 1fr auto; gap: 80px; max-width: calc(var(--wrap) + 2 * var(--g)); margin-left: auto; margin-right: auto; }
  .sort-copy { text-align: left; justify-self: start; }
}

/* The scroll story: the phone stays pinned while the page scrolls through four tabs. */
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .sorted { padding-bottom: 0; }
    .sorter { height: 420svh; view-timeline-name: --sort; view-timeline-axis: block; }
    .tabbar { display: none; }
    .sort-stage {
      --w: min(80vw, 330px, calc((100svh - 300px) / 2.15));
      position: sticky; top: 52px; height: calc(100svh - 52px); margin-top: 0;
      align-content: center;
    }
    @media (min-width: 900px) { .sort-stage { --w: min(330px, calc((100svh - 120px) / 2.15)); } }
    .sort-copy .k, .plists .plist { display: block; animation-timeline: --sort; animation-range: contain 0% contain 100%; animation-fill-mode: both; animation-timing-function: linear; }
    .k1, .plist.k1 { animation-name: step1; }
    .k2, .plist.k2 { animation-name: step2; }
    .k3, .plist.k3 { animation-name: step3; }
    .k4, .plist.k4 { animation-name: step4; }
    /* every chip slides with the row (the row itself clips), and the active one fills in */
    .sort-stage .chip { animation-name: chiprow; animation-timeline: --sort; animation-range: contain 0% contain 100%; animation-fill-mode: both; animation-timing-function: linear; }
    .sort-stage .chip.c1 { animation-name: chip1, chiprow; }
    .sort-stage .chip.c2 { animation-name: chip2, chiprow; }
    .sort-stage .chip.c3 { animation-name: chip3, chiprow; }
    .sort-stage .chip.c4 { animation-name: chip4, chiprow; }

    @keyframes step1 { 0%, 20% { opacity: 1; translate: 0 0; } 23%, 100% { opacity: 0; translate: 0 -16px; } }
    @keyframes step2 { 0%, 23% { opacity: 0; translate: 0 16px; } 26%, 45% { opacity: 1; translate: 0 0; } 48%, 100% { opacity: 0; translate: 0 -16px; } }
    @keyframes step3 { 0%, 48% { opacity: 0; translate: 0 16px; } 51%, 70% { opacity: 1; translate: 0 0; } 73%, 100% { opacity: 0; translate: 0 -16px; } }
    @keyframes step4 { 0%, 73% { opacity: 0; translate: 0 16px; } 76%, 100% { opacity: 1; translate: 0 0; } }
    @keyframes chip1 { 0%, 22% { background: var(--app-accent); border-color: var(--app-accent); color: var(--app-on-accent); } 24%, 100% { background: var(--app-bg); border-color: var(--app-border); color: var(--app-text); } }
    @keyframes chip2 { 0%, 22% { background: var(--app-bg); border-color: var(--app-border); color: var(--app-text); } 24%, 47% { background: var(--app-accent); border-color: var(--app-accent); color: var(--app-on-accent); } 49%, 100% { background: var(--app-bg); border-color: var(--app-border); color: var(--app-text); } }
    @keyframes chip3 { 0%, 47% { background: var(--app-bg); border-color: var(--app-border); color: var(--app-text); } 49%, 72% { background: var(--app-accent); border-color: var(--app-accent); color: var(--app-on-accent); } 74%, 100% { background: var(--app-bg); border-color: var(--app-border); color: var(--app-text); } }
    @keyframes chip4 { 0%, 72% { background: var(--app-bg); border-color: var(--app-border); color: var(--app-text); } 74%, 100% { background: var(--app-accent); border-color: var(--app-accent); color: var(--app-on-accent); } }
    /* measured: Offers ends at 26.3em on a 23.2em screen, so step 4 slides the row 5.6em */
    @keyframes chiprow { 0%, 72% { translate: 0 0; } 76%, 100% { translate: -5.6em 0; } }
  }
}

/* ---------- Spam ---------- */

.duo { display: grid; gap: 20px; margin-top: 64px; }
@media (min-width: 900px) { .duo { grid-template-columns: 1fr 1fr; } }
.alt .tile, .duo .tile { background: var(--tile); }
.duo .tile { background: var(--bg-alt); display: grid; align-content: start; gap: 0; }
.duo .tile h3 { margin-top: 32px; }
.sheet, .rules { background: var(--app-bg); color: var(--app-text); border-radius: 18px; border: 1px solid var(--app-border); overflow: hidden; font-size: 17px; }
.sheet-head { display: grid; grid-template-columns: 2.7em 1fr; gap: 0.8em; padding: 16px; align-items: start; border-bottom: 1px solid var(--app-border); }
.sheet-head .who { font-weight: 600; }
.sheet-row { padding: 14px 20px; }
.sheet-row + .sheet-row { border-top: 1px solid var(--app-border); }
.sheet-row.strong { font-weight: 700; }
.rules div { display: flex; justify-content: space-between; gap: 16px; padding: 16px 20px; }
.rules div + div { border-top: 1px solid var(--app-border); }
.rules b { color: var(--app-accent); white-space: nowrap; }
.rules p { margin: 0; padding: 14px 20px; background: var(--app-surface); color: var(--app-muted); font-size: 14px; }

/* ---------- Reminders ---------- */

@media (min-width: 900px) { .split.flip { grid-template-columns: auto 1fr; } }
.rem-list { padding: 0.4em 0; }
.rem { display: flex; justify-content: space-between; align-items: center; gap: 0.8em; margin: 0.5em 1.1em; padding: 0.9em 1em; border-radius: 1em; background: var(--app-bg); border: 1px solid var(--app-border); }
.due-chip { flex: none; padding: 0.3em 0.7em; border-radius: 999px; background: var(--app-hl-soft); color: var(--app-on-hl-soft); font-size: 0.85em; font-weight: 600; white-space: nowrap; }
.due-chip.soft { background: var(--app-accent-soft); color: var(--app-text); }

/* ---------- Everyday things ---------- */

.more-list { margin: 48px 0 0; display: grid; gap: 0 48px; }
@media (min-width: 734px) { .more-list { grid-template-columns: 1fr 1fr; } }
.more-list div { border-top: 1px solid var(--hair); padding: 18px 0 20px; }
.more-list dt { font-weight: 600; font-size: 19px; letter-spacing: -0.015em; }
.more-list dd { margin: 4px 0 0; color: var(--ink-2); }

/* ---------- Show balance: a working switch (checkbox + CSS, like the app's finance_hidden) ---------- */

.phone-wrap { justify-self: center; display: grid; justify-items: center; gap: 18px; }
.phone-wrap .try { margin: 0; text-align: center; max-width: 22em; }
.phone-wrap .try b { color: var(--ink); font-weight: 600; }
.bal-in { position: absolute; opacity: 0; width: 1px; height: 1px; }
label.showbal { cursor: pointer; }
.showbal > span:first-child { display: grid; }
.amt .h, .due .h { display: none; letter-spacing: 0.08em; }
.bal-in:not(:checked) ~ .acct-row .v, .bal-in:not(:checked) ~ .due .v { display: none; }
.bal-in:not(:checked) ~ .acct-row .h, .bal-in:not(:checked) ~ .due .h { display: inline; }
.showbal .sw { transition: background-color 200ms ease; }
.showbal .sw::after { transition: translate 200ms cubic-bezier(0.16, 1, 0.3, 1); }
.bal-in:not(:checked) ~ .showbal .sw { background: var(--app-border); }
.bal-in:not(:checked) ~ .showbal .sw::after { translate: -1.1em 0; background: var(--app-muted); }
.bal-in:focus-visible ~ .showbal .sw { outline: 3px solid var(--link); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .showbal .sw, .showbal .sw::after { transition: none; } }

/* ---------- Join testing form (/join/) ---------- */

:root { --field-border: #86868b; --field-bg: #ffffff; --error: #b42323; }
@media (prefers-color-scheme: dark) { :root { --field-border: #8e8e93; --field-bg: #1c1c1e; --error: #ff8c86; } }

.join .doc-hero { padding-bottom: 24px; }
.join-body { padding: 24px 0 120px; }
.join-form, .form-alert { max-width: 560px; margin: 0 auto; }
.join-form { display: grid; gap: 22px; }
.form-alert { margin-bottom: 24px; padding: 14px 18px; border-radius: 18px; background: var(--app-danger-soft); color: var(--app-on-danger-soft); font-weight: 500; }
.field { display: grid; gap: 8px; }
.field > label { font-size: 17px; font-weight: 600; letter-spacing: -0.01em; }
.field .req { margin-left: 6px; font-size: 14px; font-weight: 500; color: var(--ink-2); }
.field input[type="text"], .field input[type="email"], .field select {
  width: 100%; min-height: 52px; padding: 12px 16px; border-radius: 12px;
  border: 1px solid var(--field-border); background: var(--field-bg); color: var(--ink);
  font: inherit; font-size: 17px; letter-spacing: -0.01em;
}
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%), linear-gradient(135deg, var(--ink-2) 50%, transparent 50%); background-position: calc(100% - 22px) 50%, calc(100% - 16px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 40px; }
.field input::placeholder { color: var(--ink-2); opacity: 1; }
.field input:focus-visible, .field select:focus-visible { outline: 3px solid var(--link); outline-offset: 1px; border-color: var(--link); }
.field .hint { margin: 0; font-size: 14px; color: var(--ink-2); }
.field .err { margin: 0; font-size: 14px; font-weight: 600; color: var(--error); }
.field.bad input { border-color: var(--error); border-width: 2px; }
.field-row { display: grid; gap: 22px; }
@media (min-width: 560px) { .field-row { grid-template-columns: 1fr 1fr; } }
.robot { display: flex; align-items: center; gap: 14px; min-height: 64px; padding: 12px 18px; border: 1px solid var(--field-border); border-radius: 12px; background: var(--field-bg); cursor: pointer; font-size: 17px; font-weight: 500; }
.robot input { width: 26px; height: 26px; margin: 0; accent-color: var(--pill); flex: none; }
.field.bad .robot { border-color: var(--error); border-width: 2px; }
.trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.join-form .pill { justify-self: start; border: 0; cursor: pointer; font: inherit; font-size: 17px; font-weight: 500; }
.form-note { margin: 0; }

main.join { min-height: calc(100svh - 52px - 96px); }
