/* Pointe's page and the Ballerine Engineering hub above it. Brand Guidelines V6 type and colour with Pointe's light and
   dark tokens (assets/theme.json, docs/design/brand-v6.md). Fonts are the repo's bundled OFL files as WOFF2: nothing is
   fetched from another host. Text sizes: 11 (kicker), 12.5 (small, code), 15 (body), 18 (lead), and the display sizes. */

@font-face { font-family: 'Bricolage Grotesque'; font-weight: 300; font-style: normal; font-display: swap;
  src: url(../fonts/BricolageGrotesque-Light.woff2) format('woff2');
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20A0-20CF, U+2100-214F, U+2190-2193; }
@font-face { font-family: 'Bricolage Grotesque'; font-weight: 400; font-style: normal; font-display: swap;
  src: url(../fonts/BricolageGrotesque-Regular.woff2) format('woff2');
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20A0-20CF, U+2100-214F, U+2190-2193; }
@font-face { font-family: 'Instrument Sans'; font-weight: 400; font-style: normal; font-display: swap;
  src: url(../fonts/InstrumentSans-Regular.woff2) format('woff2');
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20A0-20CF, U+2100-214F, U+2190-2193; }
@font-face { font-family: 'Instrument Sans'; font-weight: 500; font-style: normal; font-display: swap;
  src: url(../fonts/InstrumentSans-Medium.woff2) format('woff2');
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20A0-20CF, U+2100-214F, U+2190-2193; }
@font-face { font-family: 'Instrument Sans'; font-weight: 600; font-style: normal; font-display: swap;
  src: url(../fonts/InstrumentSans-SemiBold.woff2) format('woff2');
  unicode-range: U+0000-024F, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20A0-20CF, U+2100-214F, U+2190-2193; }

:root {
  --bg: #FFFFFF; --surface: #FCFAFA; --card: #FFFFFF; --raised: #F5F1EF;
  --text: #0A0400; --body: #4F4845; --muted: #5C5450; --dim: #6E6762;
  --line: rgba(10, 5, 0, .10); --line-strong: rgba(10, 5, 0, .18); --line-faint: rgba(10, 5, 0, .05);
  --orange: #FF5A01; --accent: #C24F0D; --ok: #0E7A41; --no: #C83A37;
  --primary: #0A0400; --on-primary: #FCFAFA;
  --dark: #0C0906; --dark-card: #0F0B08; --bone: #F7F2F0; --dark-body: #B5ADA8; --dark-dim: #958D88;
  --dark-line: rgba(255, 255, 255, .10); --accent-dark: #FF8C4A;
  --shadow: 0 30px 60px -30px rgba(10, 5, 0, .35), 0 0 0 1px rgba(10, 5, 0, .08);
  --hero: linear-gradient(180deg, #F5F1EF 0%, #FBF9F8 55%, #FFFFFF 100%);
  --font-display: 'Bricolage Grotesque', 'Instrument Sans', system-ui, sans-serif;
  --font-sans: 'Instrument Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  --ease: cubic-bezier(.22, 1, .36, 1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0A0400; --surface: #0C0906; --card: #0F0B08; --raised: #1A1410;
    --text: #F7F2F0; --body: #B5ADA8; --muted: #B5ADA8; --dim: #958D88;
    --line: rgba(255, 255, 255, .08); --line-strong: rgba(255, 255, 255, .16); --line-faint: rgba(255, 255, 255, .04);
    --accent: #FF8C4A; --ok: #3DBE7B; --no: #F0706B;
    --primary: #F7F2F0; --on-primary: #0A0400;
    --dark: #14100C; --dark-card: #14100C;
    --shadow: 0 30px 60px -30px rgba(0, 0, 0, .9), 0 0 0 1px rgba(255, 255, 255, .10);
    --hero: linear-gradient(180deg, #14100C 0%, #0A0400 80%);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 15px/24px var(--font-sans);
       -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
h1, h2, h3, p, ul, ol, dl, dd, figure, pre { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, video { max-width: 100%; height: auto; display: block; }
[hidden] { display: none !important; }
b, strong { font-weight: 600; color: var(--text); }
a { color: inherit; text-decoration: underline; text-decoration-color: var(--line-strong); text-decoration-thickness: 1px;
    text-underline-offset: 3px; }
a:hover { color: var(--accent); text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
code { font-family: var(--font-mono); font-size: 12.5px; }
:not(pre) > code { background: var(--raised); padding: 1px 5px; border-radius: 3px; overflow-wrap: break-word; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 10; background: var(--card); padding: 8px 12px; }
.page { max-width: 1240px; margin: 0 auto; padding: 0 32px; position: relative; }

/* Type */
.h-hero { font-family: var(--font-display); font-weight: 300; font-size: clamp(32px, 3.7vw, 52px); line-height: 1.1;
          letter-spacing: -.02em; }
.h1 { font-family: var(--font-display); font-weight: 400; font-size: clamp(30px, 3.4vw, 48px); line-height: 1.08;
      letter-spacing: -.02em; }
.h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(26px, 2.6vw, 36px); line-height: 1.14;
      letter-spacing: -.015em; }
.h3 { font-family: var(--font-display); font-weight: 400; font-size: 20px; line-height: 26px; letter-spacing: -.01em; }
.lead { font-size: 18px; line-height: 28px; color: var(--body); }
.body { color: var(--body); }
.small { font-size: 12.5px; line-height: 18px; color: var(--dim); }
.kicker { font-size: 11px; line-height: 16px; font-weight: 600; text-transform: uppercase; letter-spacing: .12em; color: var(--dim); }
.title { font-weight: 600; color: var(--text); }
.accent { color: var(--accent); }
.link { font-weight: 500; color: var(--text); }

/* Header */
.site-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 72px; }
.wordmark { font-family: var(--font-display); font-size: 24px; letter-spacing: -.01em; text-decoration: none; color: var(--text); }
.wordmark img, .pg-wordmark img { display: block; height: 32px; width: auto; }  /* the lockup, compact drawing (docs/brand/logo.md) */
.project .project-lockup img { display: block; height: clamp(36px, 3.6vw, 48px); width: auto; border-radius: 0; box-shadow: none; }
.beta-tag { font-size: 12px; font-weight: 500; letter-spacing: .04em; text-transform: uppercase; color: var(--muted);
  border: 1px solid currentColor; border-radius: 999px; padding: 2px 9px; margin-right: auto; margin-left: 12px; }
.beta-tag:empty { display: none; }
.site-header nav { display: flex; align-items: center; gap: 26px; }
.site-header nav a { text-decoration: none; font-weight: 500; color: var(--muted); }
.site-header nav a:hover { color: var(--text); }
.site-header nav a.gh { color: var(--text); display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px;
                        border: 1px solid var(--line-strong); border-radius: 12px; }
.site-header nav a.gh:hover { border-color: var(--text); }
.gh svg { width: 16px; height: 16px; }

/* Hero: the copy and the two buttons on the left; on the right a drawing of the idea: your voice on a phone, thin wires
   to five agents on three machines. The drawing animates in CSS on one 12 s cycle (.hv-*): you send work to billing, ask
   everyone and hear back, approve shop. hero_svg.py in the launch kit wrote its markup. */
.hero { background: var(--hero); border-radius: 16px 16px 0 0; padding: 48px 40px 40px 48px; display: grid;
        grid-template-columns: minmax(0, 5.6fr) minmax(0, 6.4fr); gap: 32px 48px; align-items: center; }
.hero .h-hero { font-size: clamp(36px, 4.2vw, 58px); }
.hero-copy > * + * { margin-top: 18px; }
.hero-copy .proof { font-size: 14px; line-height: 21px; }
.hero-copy .proof strong { display: block; font-size: 15px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.hero-dl, .app-meta { margin-top: 10px; color: var(--muted); }
.btn[hidden], .hero-dl[hidden], .site-header nav a[hidden] { display: none; }
.btn { display: inline-flex; align-items: center; height: 44px; padding: 0 20px; border-radius: 12px; font-weight: 600; text-decoration: none;
       color: var(--text); border: 1px solid var(--line-strong); }
.btn:hover { color: var(--text); border-color: var(--text); }
.btn--primary { background: var(--primary); color: var(--on-primary); border-color: var(--primary); }
.btn--primary:hover { color: var(--on-primary); opacity: .88; }
.cmd { position: relative; }
.cmd pre { padding: 13px 88px 13px 16px; background: var(--card); border: 1px solid var(--line-strong); border-radius: 12px;
           white-space: pre-wrap; overflow-wrap: anywhere; line-height: 20px; color: var(--text); }
.copy { position: absolute; top: 7px; right: 7px; height: 32px; padding: 0 12px; font: 600 12.5px var(--font-sans);
        color: var(--text); background: var(--raised); border: 0; border-radius: 8px; cursor: pointer; }
.hv figcaption { margin-top: 12px; max-width: 60ch; }
.hv-svg { display: block; width: 100%; height: auto; overflow: visible; }
.hv-tall { display: none; }
.hv-wire { fill: none; stroke: var(--line-strong); stroke-width: 1.2; }
.hv-pulse { fill: none; stroke: var(--orange); stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 9 200; stroke-dashoffset: 9; opacity: 0; }
.hv-port { fill: var(--orange); }
.hv-card { fill: var(--card); stroke: var(--line-strong); }
.hv-lit { fill: none; stroke: var(--orange); stroke-width: 1.6; opacity: 0; }
.hv-dot { fill: var(--line-strong); }
.hv-g { fill: none; stroke: var(--line-strong); }
.hv-gt { font: 600 10px var(--font-sans); fill: var(--muted); }
.hv-nm { font-family: var(--font-sans); font-weight: 600; fill: var(--text); }
.hv-sub { font-family: var(--font-sans); fill: var(--dim); }
.hv-body { fill: #0A0400; }
.hv-screen { fill: #14100C; }
.hv-island { fill: #0A0400; }
.hv-call { font: 600 13px var(--font-sans); fill: #F7F2F0; }
.hv-calls { font: 400 11px var(--font-sans); fill: #958D88; }
.hv-bar { fill: var(--orange); transform-box: fill-box; transform-origin: center; }
.hv-you { font: 600 10px var(--font-sans); letter-spacing: .12em; fill: #958D88; }
.hv-line { font: 400 14px var(--font-sans); fill: #F7F2F0; }
.hv-tall .hv-line { font-size: 12px; }
.hv-say { opacity: 0; }
.hv-say--first { opacity: 1; }
.hv-mic { fill: var(--orange); }
.hv-mic-i { fill: #0A0400; }
.hv-mic-s { fill: none; stroke: #0A0400; stroke-width: 1.6; stroke-linecap: round; }
@media (prefers-color-scheme: dark) { .hv-body { fill: #2B241F; } }
@media (prefers-reduced-motion: no-preference) {
  .hv-bar { animation: hv-wave 1.1s ease-in-out infinite alternate; }
  .hv-say, .hv-say--first { animation: hv-say 12s infinite both; }
  .hv-out { animation: hv-out 12s linear infinite both; }
  .hv-back { animation: hv-back 12s linear infinite both; }
  .hv-lit { animation: hv-lit 12s infinite both; }
  .hv-lit--long { animation-name: hv-lit-long; }
}
@keyframes hv-wave { from { transform: scaleY(.3); } to { transform: scaleY(1); } }
@keyframes hv-say { 0% { opacity: 0; } 2%, 30% { opacity: 1; } 33%, 100% { opacity: 0; } }
@keyframes hv-out { 0% { opacity: 0; stroke-dashoffset: 9; } .5% { opacity: 1; } 9% { opacity: 1; stroke-dashoffset: -100; } 9.5%, 100% { opacity: 0; stroke-dashoffset: -100; } }
@keyframes hv-back { 0% { opacity: 0; stroke-dashoffset: -100; } .5% { opacity: 1; } 9% { opacity: 1; stroke-dashoffset: 9; } 9.5%, 100% { opacity: 0; stroke-dashoffset: 9; } }
@keyframes hv-lit { 0% { opacity: 0; } 2%, 12% { opacity: 1; } 16%, 100% { opacity: 0; } }
@keyframes hv-lit-long { 0% { opacity: 0; } 2%, 26% { opacity: 1; } 30%, 100% { opacity: 0; } }

/* Three problems, one conversation: three columns on hairlines, today above, Pointe's answer below */
.problems .h1 { max-width: 20ch; }
.pairs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 32px; border-top: 1px solid var(--line-strong); }
.pairs > li { padding: 22px 28px 24px 0; }
.pairs > li + li { padding-left: 28px; border-left: 1px solid var(--line); }
.pairs .kicker { display: block; margin-bottom: 6px; }
.pain { color: var(--body); }
.fix { margin-top: 18px; font-size: 18px; line-height: 27px; color: var(--text); }
.fix .kicker { color: var(--accent); }
.why { margin-top: 28px; max-width: 84ch; color: var(--body); }

/* Before: four close-ups of the pain, each with three or four words */
.before .h1, .with .h1 { margin-top: 10px; max-width: 24ch; }
.pains { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; margin-top: 28px; }
.pain-clip { position: relative; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; background: #0A0400; }
.pain-clip img, .pain-clip video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pain-clip .ai { top: auto; bottom: 8px; left: 8px; }
.pains p { margin-top: 10px; font-size: 18px; line-height: 26px; color: var(--body); }

/* With Pointe: one film, footage and panel and sound rendered from one timeline (the launch kit's film/), behind one
   button. */
.film { position: relative; margin-top: 28px; aspect-ratio: 16 / 9; border: 1px solid var(--line-strong); border-radius: 12px; overflow: hidden; background: #0A0400; }
.film img, .film video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.film-play { position: absolute; left: 27.5%; top: 50%; transform: translate(-50%, -50%); z-index: 1; display: inline-flex; align-items: center; gap: 12px;
             min-height: 56px; padding: 0 26px 0 22px; border: 0; border-radius: 99px; background: #F7F2F0; color: #0A0400;
             font: 600 16px/1 var(--font-sans); cursor: pointer; white-space: nowrap; box-shadow: 0 10px 30px rgba(10, 5, 0, .4); }
.film-play:hover { background: #fff; }
.film-play i { width: 0; height: 0; border-left: 14px solid currentColor; border-top: 9px solid transparent; border-bottom: 9px solid transparent; }
.film-link { position: absolute; left: 16px; bottom: 16px; padding: 10px 16px; border-radius: 99px; background: #F7F2F0; color: #0A0400; }
.film-out { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 16px; margin-top: 18px; }
.film-out .figure { font-size: clamp(30px, 3.2vw, 42px); white-space: nowrap; color: var(--text); }

/* The line over the headline that says what Pointe is */
.descriptor { color: var(--body); }

/* The strip under the hero: five facts in one row of hairlines */
.strip { display: grid; grid-template-columns: 1.25fr 1.35fr 1.35fr .7fr .8fr; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.strip > div { padding: 18px 24px 20px 0; }
.strip > div + div { padding-left: 24px; border-left: 1px solid var(--line); }
.strip dt { margin-bottom: 4px; }
.strip dd { color: var(--body); }

/* Sections */
.section { padding: 56px 0; }
.section + .section, .section--rule { border-top: 1px solid var(--line); }
.head-row { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 24px 64px; align-items: end; }
.head-row .kicker { grid-column: 1 / -1; margin-bottom: -8px; }
.head-stack .lead, .head-stack .body { margin-top: 16px; max-width: 68ch; }
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px 64px; align-items: start; }
.split--wide { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.split--half { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.stack > * + * { margin-top: 16px; }
.block { margin-top: 40px; }
.note { margin-top: 20px; max-width: 96ch; }

/* The example call: plain rows, no box */
.talk { border-top: 1px solid var(--line-strong); }
.talk > div { display: grid; grid-template-columns: 64px 1fr; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.talk dt { padding-top: 5px; }
.talk dd { font-size: 18px; line-height: 28px; color: var(--text); }
.talk .bot dt { color: var(--accent); }
.talk .aside { display: block; font-size: 12.5px; line-height: 18px; color: var(--dim); margin-top: 2px; }

/* How it works: the daemon's pipeline beside its three other roles */
.daemon { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 24px 64px; align-items: start; margin-top: 48px;
          border: 1px solid var(--line-strong); border-radius: 12px; padding: 24px 28px 26px; background: var(--card); }
.daemon .kicker { margin-bottom: 12px; }
.daemon .small { margin-top: 10px; }
.pipe { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px; font-family: var(--font-display); font-size: 20px; line-height: 26px; }
.pipe i { font-style: normal; color: var(--dim); font-family: var(--font-sans); font-size: 15px; }
.pipe .key { color: var(--accent); }
.hub-roles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px 24px; }
.hub-roles span { display: block; font-size: 12.5px; line-height: 18px; color: var(--dim); margin-top: 2px; }

/* Lists of hairline rows */
.rows { border-top: 1px solid var(--line-strong); }
.rows > li { padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--body); }
.rows--cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 64px; border-top: 0; }
.rows--cols > li { border-top: 1px solid var(--line); border-bottom: 0; }
.rows--two > li { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 4px 32px; }

.shot + figcaption { margin-top: 12px; }
.shot { border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); }

/* Tables */
.scroll { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; }
.table caption { text-align: left; padding-bottom: 10px; }
.table th { text-align: left; vertical-align: bottom; padding: 0 20px 10px 0; border-bottom: 1px solid var(--line-strong);
            font-size: 11px; line-height: 16px; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--dim); }
.table td, .table tbody th { padding: 13px 20px 13px 0; border-bottom: 1px solid var(--line); color: var(--body); vertical-align: top;
                             font-variant-numeric: tabular-nums; text-align: left; }
.table tbody th { font-size: 15px; line-height: 24px; font-weight: 600; text-transform: none; letter-spacing: 0; color: var(--text); }
.table td:last-child, .table th:last-child { padding-right: 0; }
.table tr.total td { color: var(--text); font-weight: 600; }
.table .num { text-align: right; white-space: nowrap; }
.verdict { font-weight: 600; white-space: nowrap; }
.verdict--yes { color: var(--ok); }
.verdict--no { color: var(--no); }
.compare th[scope=col] { font-family: var(--font-display); font-size: 20px; line-height: 26px; font-weight: 400; text-transform: none;
                         letter-spacing: -.01em; color: var(--text); width: 21%; }
.compare th[scope=col]:first-child { width: 16%; }
.compare th[scope=col] small { display: block; font: 400 12.5px/18px var(--font-sans); color: var(--dim); letter-spacing: 0; }
.compare td:nth-child(2) { color: var(--text); }

/* The one dark band */
.band-dark { background: var(--dark); color: var(--bone); padding: 64px 0; }
.band-dark .h1, .band-dark b, .band-dark .title, .band-dark .table tbody th { color: var(--bone); }
.band-dark .lead, .band-dark .body, .band-dark .table td { color: var(--dark-body); }
.band-dark .kicker, .band-dark .small, .band-dark .table th { color: var(--dark-dim); }
.band-dark .table th, .band-dark .table td, .band-dark .table tbody th { border-color: var(--dark-line); }
.band-dark a { text-decoration-color: rgba(255, 255, 255, .35); }
.band-dark a:hover { color: var(--accent-dark); }
.band-dark code { background: rgba(255, 255, 255, .08); }
.band-dark .table td.verdict--yes { color: #3DBE7B; }
.band-dark .table td.verdict--no { color: #F0706B; }
.band-dark .table td.verdict--none { color: var(--bone); }
.band-dark .table td.verdict { width: 30%; white-space: normal; }
.band-dark .conds { margin-top: 6px; }
.conds li { position: relative; padding-left: 16px; }
.conds li::before { content: "–"; position: absolute; left: 0; color: var(--dark-dim); }
.band-foot { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 32px 64px; margin-top: 40px; align-items: start; }
.figure { font-family: var(--font-display); font-weight: 300; font-size: clamp(44px, 5vw, 64px); line-height: 1; letter-spacing: -.03em;
          font-variant-numeric: tabular-nums; }
.figure--key { color: var(--accent-dark); }
.figure + p { margin-top: 10px; }
@media (prefers-color-scheme: dark) { .band-dark { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); } }

/* Privacy notes and measured cells */
.cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 48px; }
.cols > div > .title { margin-bottom: 6px; }
.cells { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line-strong); border-bottom: 1px solid var(--line); }
.cells > div { padding: 24px 24px 26px 0; }
.cells > div + div { padding-left: 24px; border-left: 1px solid var(--line); }
.cells .figure { color: var(--text); }
.cells .figure.figure--key { color: var(--orange); }
.cells .title { margin-top: 12px; }
details.more-detail { border-bottom: 1px solid var(--line); }
details.more-detail summary { cursor: pointer; padding: 14px 0; font-weight: 500; color: var(--text); }
details.more-detail > div { padding: 8px 0 28px; }
.usage { max-width: 760px; }

/* Install */
/* The apps first: two cards whose links come from apps.json (tools/apps_status.py) */
.apps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.app-card { padding: 22px 24px 24px; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--card); }
.app-card .h3 { margin-top: 8px; }
.app-card .body { margin-top: 6px; }
.app-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin-top: 18px; }
.app-soon { display: inline-flex; align-items: center; gap: 7px; padding: 4px 12px; border: 1px solid var(--line-strong); border-radius: 999px;
            font: 500 13px/20px var(--font-sans); color: var(--text); }
.app-soon::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--orange); }
.steps { counter-reset: step; border-top: 1px solid var(--line-strong); }
.steps > li { counter-increment: step; display: grid; grid-template-columns: 40px 1fr; padding: 16px 0; border-bottom: 1px solid var(--line); color: var(--body); }
.steps > li::before { content: counter(step); font-family: var(--font-display); font-size: 20px; line-height: 26px; color: var(--dim); }
.steps .title { display: block; }
.term { background: #0C0906; color: #F7F2F0; border-radius: 12px; padding: 18px 20px 20px; overflow-x: auto; box-shadow: var(--shadow); }
.term::before { content: ""; display: block; width: 44px; height: 8px; margin-bottom: 16px; border-radius: 4px;
                background: radial-gradient(circle 4px at 4px 4px, #3A322C 98%, transparent) 0 0 / 18px 8px repeat-x; }
.term code { display: block; white-space: pre; line-height: 22px; }
.split--term { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.term .p { color: #958D88; user-select: none; }
.term .c { color: #958D88; }
.term + .small { margin-top: 12px; }
.tablist { display: flex; gap: 8px; margin-bottom: 24px; flex-wrap: wrap; }
.tablist [role=tab] { font: inherit; font-weight: 500; padding: 8px 16px; border-radius: 999px; cursor: pointer;
                      border: 1px solid var(--line-strong); background: transparent; color: var(--body); }
.tablist [role=tab][aria-selected=true] { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.tablist [role=tab]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tabpanel + .tabpanel { margin-top: 32px; }
.tabpanel[hidden] { display: none; }
.tabs + .small { margin-top: 24px; }

/* The day story. Each beat is its copy and its picture: footage, with a screenshot of the page laid over one corner.
   Stacked by default. On a wide screen, with the script, the pictures share one sticky stage (.is-stage) and the
   copy scrolls past it: the list items become `display: contents` so that every picture sits in the same grid area. */
.story-grid { margin-top: 36px; }
.rail { display: none; }
.beats { display: grid; gap: 64px; }
.beat { display: grid; grid-template-columns: minmax(0, 4.6fr) minmax(0, 7.4fr); gap: 24px 64px; align-items: center; scroll-margin-top: 30vh; }
.story .head-row { margin-bottom: 8px; }
.beat-copy .when { color: var(--accent); font-variant-numeric: tabular-nums; margin-right: 6px; }
.beat-copy .h2 { margin-top: 10px; }
.beat-copy .body { margin-top: 14px; }
.beat-copy .small { margin-top: 12px; }
.beat-media { position: relative; padding-bottom: 56px; }
.beat-frame { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: #0A0400; }
.beat-frame > img, .beat-frame > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ai { position: absolute; left: 10px; top: 10px; padding: 2px 8px; border-radius: 4px; background: rgba(10, 4, 0, .62); color: #F7F2F0;
      font-size: 11px; line-height: 16px; font-weight: 500; letter-spacing: .02em; }
.beat-ui { position: absolute; bottom: 0; overflow: hidden; background: var(--card); box-shadow: var(--shadow); }
.beat-ui img { width: 100%; }
.beat-ui--mac { right: -20px; width: 46%; border-radius: 10px; }
.beat-ui--phone { right: -20px; width: 41%; border-radius: 24px; border: 5px solid #0A0400; box-shadow: var(--shadow), 0 0 0 1px rgba(255, 255, 255, .14); }
.beat-ui--left { left: -20px; right: auto; }
.beat-ui--card { right: -20px; width: 37%; border-radius: 14px; }
/* A phone whose screen steps through a few moments, each a real screenshot. Without motion, the one marked .still shows. */
.beat-ui--seq { width: 30%; aspect-ratio: 560 / 910; }
.beat-ui--seq picture { position: absolute; inset: 0; opacity: 0; }
.beat-ui--seq picture.still { opacity: 1; }
@media (prefers-reduced-motion: no-preference) {
  .beat-ui--seq picture, .beat-ui--seq picture.still { opacity: 0; animation: seq calc(var(--n) * 3.2s) calc(var(--i) * 3.2s) infinite; }
  .beat-ui--seq[style*="--n:2"] picture { animation-name: seq2; }
}
@keyframes seq { 0%, 23% { opacity: 1; } 25%, 100% { opacity: 0; } }
@keyframes seq2 { 0%, 48% { opacity: 1; } 50%, 100% { opacity: 0; } }
.beat-ui--bubble { right: -20px; bottom: 14px; width: 44%; background: none; border-radius: 17px; }

@media (min-width: 1081px) {
  .story-grid.is-stage { display: grid; grid-template-columns: minmax(0, 4.6fr) minmax(0, 7.4fr); column-gap: 64px;
                         --stage-top: max(16px, calc(50vh - 290px)); }
  .is-stage .beats, .is-stage .beat { display: contents; }
  .is-stage .rail { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); column-gap: 10px; grid-column: 2; grid-row: 1 / span 7; align-self: start;
                    position: sticky; top: var(--stage-top); z-index: 2; height: 60px; box-sizing: content-box;
                    padding-bottom: calc(56.25% + 56px); pointer-events: none; }
  .rail a { pointer-events: auto; padding-top: 8px; border-top: 1px solid var(--line-strong); text-decoration: none; color: var(--dim);
            font-size: 11px; line-height: 16px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em;
            transition: color .3s, border-color .3s; }
  .rail a .when { display: block; font-variant-numeric: tabular-nums; }
  .rail a:hover { color: var(--text); }
  .rail a[aria-current] { color: var(--text); border-top: 2px solid var(--orange); padding-top: 7px; }
  .is-stage .beat-copy { grid-column: 1; min-height: 34vh; padding: 10px 0; display: flex; flex-direction: column; justify-content: center;
                         opacity: .36; transition: opacity .4s; }
  .is-stage .beat.is-active .beat-copy { opacity: 1; }
  /* The picture leaving stays under the one arriving until that one has faded in, so the page never shows through. */
  .is-stage .beat-media { grid-column: 2; grid-row: 1 / span 7; align-self: start; position: sticky; top: calc(var(--stage-top) + 60px);
                          margin: 60px 0 0; opacity: 0; visibility: hidden; transition: opacity 0s .5s, visibility 0s .5s; }
  .is-stage .beat.is-active .beat-media { opacity: 1; visibility: visible; z-index: 1; transition: opacity .5s var(--ease); }
  .is-stage .beat-ui { opacity: 0; transform: translateY(18px); transition: opacity .2s, transform 0s .2s; }
  .is-stage .beat.is-active .beat-ui { opacity: 1; transform: none; transition: opacity .45s .2s, transform .7s var(--ease) .2s; }
}

/* The working group: one paragraph and one link, until there are names to show */
.partners { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 32px; }
.partners .body { max-width: 72ch; }
.partners .link { text-decoration: none; }
.partners .link:hover { text-decoration: underline; }
#working-group { padding: 36px 0; }
.wg-logos { flex-basis: 100%; display: grid; grid-template-columns: max-content minmax(0, 1fr) auto;
  grid-template-areas: "label logos pause"; align-items: center; gap: 12px 28px; margin-top: 12px; }
.wg-label { grid-area: label; margin: 0; }
.wg-viewport { grid-area: logos; }
/* WCAG 2.2.2: the loop moves for more than five seconds, so it has a pause. A fixed size, so nothing shifts. */
.wg-pause { grid-area: pause; position: relative; width: 28px; height: 28px; padding: 0; border: 1px solid var(--line-strong);
  border-radius: 50%; background: transparent; color: var(--muted); cursor: pointer; }
.wg-pause:hover { color: var(--text); }
.wg-pause:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.wg-pause::before { content: ""; position: absolute; inset: 0; margin: auto; width: 8px; height: 10px;
  border-left: 3px solid currentColor; border-right: 3px solid currentColor; }
.wg-pause[aria-pressed="true"]::before { width: 0; height: 0; border-style: solid; border-color: transparent;
  border-width: 5px 0 5px 9px; border-left-color: currentColor; margin-left: 10px; }
.wg-logos.is-paused .wg-track { animation-play-state: paused; }
/* Ten logos to a viewport on a wide screen, four on a phone; the height is fixed, so nothing shifts as logos load. */
.wg-viewport { container-type: inline-size; overflow: hidden; }
.wg-track { display: flex; }
.wg-list { display: flex; margin: 0; padding: 0; list-style: none; }
.wg-list li { flex: 0 0 10cqi; min-width: 0; height: 44px; display: flex; align-items: center; justify-content: center;
  padding: 0 1.2cqi; }
@container (max-width: 640px) { .wg-list li { flex-basis: 25cqi; padding: 0 4cqi; } }
.wg-list a { display: flex; max-width: 100%; height: 100%; align-items: center; }
/* Width and height come from tools/working_group.py: the same area for every logo. */
.wg-logo { display: block; max-width: 100%; margin: 0 auto; background: var(--muted); opacity: .85;
  -webkit-mask: var(--logo) center / contain no-repeat; mask: var(--logo) center / contain no-repeat; }
.wg-list a:hover .wg-logo, .wg-list a:focus-visible .wg-logo { background: var(--text); opacity: 1; }
/* Fewer than six: the label and the logos as one centered row, each logo in a cell of its own width. */
.wg-logos--static { display: flex; flex-wrap: wrap; justify-content: center; }
.wg-static { container-type: normal; }
.wg-static .wg-list { flex-wrap: wrap; justify-content: center; }
.wg-static .wg-list li { flex: 0 0 auto; padding: 0 16px; }
/* The list is there twice; moving the track by half its width puts the copy exactly where the first one started. */
.wg-marquee { -webkit-mask: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  mask: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.wg-marquee .wg-track { width: max-content; animation: wg-scroll calc(var(--n) * 3s) linear infinite; }
.wg-marquee:hover .wg-track, .wg-marquee:focus-within .wg-track { animation-play-state: paused; }
@keyframes wg-scroll { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .wg-marquee { -webkit-mask: none; mask: none; }
  .wg-marquee .wg-track { width: auto; animation: none; }
  .wg-marquee .wg-list { flex-wrap: wrap; justify-content: center; width: 100%; }
  .wg-marquee .wg-list[aria-hidden] { display: none; }
  .wg-pause { display: none; }
}
@media (max-width: 640px) {
  .wg-logos { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "label pause" "logos logos"; }
}

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 40px 0 56px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 24px 64px; }
.footer-grid .stack > * + * { margin-top: 6px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 24px; align-content: start; }
.footer-links a { font-weight: 500; color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--text); }

/* The hub (eng.ballerine.com/) */
.hub-hero { padding: 96px 0 56px; }
.hub-hero .lead { margin-top: 20px; max-width: 60ch; }
.project { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 24px 64px; padding: 32px 0; border-top: 1px solid var(--line-strong);
           border-bottom: 1px solid var(--line); text-decoration: none; align-items: center; }
.project:hover { color: inherit; }
.project:hover .h1 { color: var(--accent); }
.project .body { margin-top: 12px; max-width: 46ch; }
.project .small { margin-top: 12px; }
.project img { border-radius: 8px; box-shadow: var(--shadow); }

@media (max-width: 1080px) {
  /* Anything a thumb presses is at least 44 px tall. */
  .site-header nav a.gh, .copy, .o-pause { min-height: 44px; }
  .copy { height: 44px; }
  .footer-links a, .partners .link, .wg a.link, a.link { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; }
  .footer-links { gap: 0 22px; }
  .site-header nav a:not(.gh) { display: none; }
  .hero { padding: 48px 32px 36px; grid-template-columns: minmax(0, 1fr); }
  .hv { max-width: 640px; }
  .pairs { grid-template-columns: minmax(0, 1fr); }
  .pairs > li, .pairs > li + li { padding: 20px 0; border-left: 0; }
  .pairs > li + li { border-top: 1px solid var(--line); }
  .pains { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .apps { grid-template-columns: minmax(0, 1fr); }
      .daemon { grid-template-columns: minmax(0, 1fr); }
  .head-row, .split, .split--wide, .split--term, .split--half, .band-foot, .footer-grid, .project { grid-template-columns: minmax(0, 1fr); }
  .head-row .kicker { margin-bottom: 0; }
  .strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .strip > div { padding: 16px 16px 16px 0; border-bottom: 1px solid var(--line); }
  .strip > div + div { padding-left: 0; border-left: 0; }
  .strip > div:last-child { border-bottom: 0; }
  .cells { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cells > div:nth-child(3) { padding-left: 0; border-left: 0; }
  .cells > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .beat { grid-template-columns: minmax(0, 1fr); }
  .beat-media { order: -1; padding-bottom: 0; display: flex; flex-direction: column; }
  .beat-ui { position: relative; margin-top: -14%; }
  .beat-ui--mac { right: 16px; align-self: flex-end; }
  .beat-ui--left { left: 16px; right: auto; align-self: flex-start; }
  .beat-ui--phone { right: 16px; align-self: flex-end; }
  .beat-ui--phone.beat-ui--left { left: 16px; right: auto; align-self: flex-start; }
  .beat-ui--card { right: 16px; width: 40%; align-self: flex-end; }
  .beat-ui--seq { width: 30%; }
  .beat-ui--bubble { right: 16px; bottom: 0; align-self: flex-end; }
  .compare { min-width: 860px; }
}
/* Up to a portrait tablet the film is its tall variant (the script and the poster use the same width). */
@media (max-width: 820px) {
  .film { aspect-ratio: 4 / 5; max-width: 560px; }
  .film-play { left: 50%; top: 22.5%; }
}
@media (max-width: 640px) {
  .page { padding: 0 18px; }
  .section { padding: 56px 0; }
  .band-dark { padding: 56px 0; }
  .site-header { height: 60px; }
  .hero { padding: 28px 18px 28px; margin: 0 -10px; border-radius: 12px 12px 0 0; row-gap: 0; }
  /* On a phone the drawing comes right under the headline, so the value and the picture of it share the first screen. */
  .hero-copy { display: contents; }
  .hero-copy > *, .hv { margin-top: 14px; }
  .hero .descriptor { order: 1; margin-top: 0; font-size: 17px; line-height: 23px; }
  .hero .h-hero { order: 2; font-size: 38px; line-height: 1.06; }
  .hv { order: 3; margin-top: 18px; }
  .hero .lead { order: 4; font-size: 16px; line-height: 24px; margin-top: 20px; }
  .hero .proof { order: 5; }
  .hero-cta { order: 6; margin-top: 20px; }
  .hero .hero-dl { order: 6; margin-top: 8px; }
  .hero-copy > .small:last-child { order: 7; }
  .hv-wide { display: none; }
  .hv-tall { display: block; }
  .hv figcaption { display: none; }
  .btn { flex: 1; justify-content: center; }
  .btn { white-space: nowrap; }
  .btn-meta { display: none; }
  .strip, .cols, .rows--cols { grid-template-columns: minmax(0, 1fr); }
  .rows--cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 64px; border-top: 0; }
.rows--cols > li { border-top: 1px solid var(--line); border-bottom: 0; }
.rows--two > li { grid-template-columns: minmax(0, 1fr); }
  .hub-roles { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .talk > div { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .talk dt { padding-top: 0; }
  [data-cmd] pre { padding: 13px 16px 50px; }
  .copy { top: auto; bottom: 8px; right: 8px; }
  /* One screen each: the four pains as a 2 by 2 grid, and the film in its tall variant (4:5) with its button. */
  .pains { gap: 10px; margin-top: 18px; }
  .pains p { margin-top: 6px; font-size: 15px; line-height: 21px; }
  .pain-clip { border-radius: 10px; }
  .film { margin-top: 18px; }
  .film-play { min-height: 52px; font-size: 15px; padding: 0 20px 0 16px; }
  .film-out { flex-direction: column; gap: 2px; }
  .problems .h1, .before .h1, .with .h1 { font-size: 30px; }
  .fix { font-size: 17px; line-height: 25px; }
  /* The day's beats are cards to swipe through, one at a time: each is its clip, its screen and a few lines. */
  .beats { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -18px; padding: 0 18px 10px; overscroll-behavior-x: contain; }
  .beat { flex: 0 0 86%; scroll-snap-align: center; align-content: start; gap: 14px; }
  .beat-copy .small { display: none; }
  .beat-copy .h2 { font-size: 22px; line-height: 27px; margin-top: 6px; }
  .beat-copy .body { margin-top: 8px; }
  .beat-frame { border-radius: 10px; }
  .beat-ui { margin-top: -19%; }
  .story { padding: 44px 0; }
  .beat-ui--card { right: 8px; width: 52%; }
  .beat-ui--phone.beat-ui--seq { width: 46%; }
  .beat-ui--bubble { right: 8px; width: 68%; margin-top: -9%; }
  .beat-ui--mac { right: 8px; width: 76%; }
  .beat-ui--phone { right: 8px; width: 68%; border-radius: 18px; border-width: 4px; }
  .beat-ui--left, .beat-ui--phone.beat-ui--left { left: 8px; }
  .cells > div { padding-right: 12px; }
  .cells > div + div { padding-left: 12px; }
  .cells > div:nth-child(3) { padding-left: 0; }
  .hub-hero { padding: 56px 0 40px; }
  /* Tables that hold sentences read as stacked rows on a phone */
  .table--stack thead { position: absolute; left: -999px; }
  .table--stack tr { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .band-dark .table--stack tr { border-color: var(--dark-line); }
  .table--stack td, .table--stack tbody th { display: block; padding: 0; border: 0; }
  .table--stack td + td, .table--stack tbody th + td { margin-top: 4px; }
  .band-dark .table td.verdict { width: auto; }
}
@media (prefers-reduced-motion: reduce) { *, .is-stage .beat-media, .is-stage .beat-ui { transition: none !important; } }
@media print {
  * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
  .site-header nav, .copy, .skip { display: none !important; }
}
