/* type.css (foundation, F-C): the type scale, headings, labels, buttons, and the type-kit hooks
   (.kin kinetic sizer, .typed machine text, .is-human). Fonts: Unbounded for display, Space Grotesk for body,
   a system mono for data. Always lowercase "inertia". Scene sheets may restyle only their own classes. */

:root {
  --t-h1: clamp(2.4rem, 11vw, 11.5rem);
  --t-h2: clamp(2rem, 6vw, 5.5rem);
  --t-h3: clamp(1.25rem, 2.2vw, 2rem);
  --t-body: clamp(1rem, 1.05vw, 1.2rem);
  --t-data: .72rem;
  --t-mega: clamp(10rem, 36vw, 34rem);
}

h1, h2, h3 { font-family: var(--font-display); text-wrap: balance; }
h1 { font-size: var(--t-h1); font-weight: 800; letter-spacing: -.045em; line-height: .9; }
h2 { font-size: var(--t-h2); font-weight: 700; letter-spacing: -.035em; line-height: .98; }
h3 { font-size: var(--t-h3); font-weight: 600; letter-spacing: -.02em; line-height: 1.1; }
.sec--page h1 { font-size: var(--t-h2); font-weight: 700; letter-spacing: -.035em; line-height: .98; }

p, li { text-wrap: pretty; }
strong, b { font-weight: 600; }

/* data face: labels, tags, typed text, readouts, ticker */
.label, .eyebrow, .tag, .mono, .loop-tag {
  font-family: var(--font-mono);
  font-size: var(--t-data);
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
}
.label { margin-bottom: 1.4rem; color: var(--mut); }
.eyebrow { color: var(--mut); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6em;
  padding: .95em 1.7em;
  border: 1px solid var(--fg); border-radius: 999px;
  background: transparent; color: var(--fg);
  font-family: var(--font-body); font-size: 1rem; font-weight: 600; line-height: 1; text-decoration: none; white-space: nowrap;
  transition: background-color .2s, color .2s;
}
.btn--signal { border-color: var(--signal); background: var(--signal); color: var(--on-signal); }
html.static .btn { transition: none; }
.btn:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; }

.link { font-weight: 600; text-decoration: underline; text-underline-offset: .28em; text-decoration-thickness: 1px; }
.link:focus-visible { text-decoration-thickness: 2px; color: var(--signal); }
body [data-theme=ink] .link:focus-visible { color: var(--line2); }

/* Standard hover (fine pointers only): colour, fill and underline change, nothing moves. */
@media (hover: hover) {
  .btn:hover { background: var(--fg); color: var(--bg); }
  .btn--signal:hover { background: var(--signal-d); color: var(--on-signal); border-color: var(--signal-d); }
  .link:hover { text-decoration-thickness: 2px; color: var(--signal); }
  body [data-theme=ink] .link:hover { color: var(--line2); }
  body [data-theme=signal] .link:hover { color: inherit; }
}

/* Kinetic sizer: the hidden copy holds the box at max weight; the visible copy changes weight without reflow. */
.kin { position: relative; display: block; white-space: nowrap; }
.kin__sizer { display: block; visibility: hidden; pointer-events: none; font-weight: var(--wght-max, 900); }
.kin__text { position: absolute; inset: 0; font-weight: var(--wght, 700); }

/* Machine text: the full copy keeps the layout (invisible), an overlay types over it. */
.is-typed { position: relative; }
.is-typed .typed__full { opacity: 0; }
.is-typed .typed__vis { position: absolute; inset: 0; }
.typed__vis.has-caret::after {
  content: ''; display: inline-block; width: 2px; height: 1em; margin-left: 2px; vertical-align: -.12em; background: currentColor;
}
html.js:not(.static) .typed__vis.has-caret::after { animation: caret-blink 1s steps(1) infinite; }
@keyframes caret-blink { 50% { opacity: 0; } }

/* Human grammar: one frame, then a vermilion ring that drops at the end (steps, never an ease). */
html.js:not(.static) .is-human { outline: 2px solid var(--signal); outline-offset: 4px; animation: human-ring .9s steps(1, end) both; }
@keyframes human-ring { to { outline-color: transparent; } }

/* Noun swap and focus-pull helpers */
.slot { display: inline-block; position: relative; overflow: hidden; vertical-align: bottom; }
.slot__w { display: block; }
.slot__w + .slot__w { position: absolute; left: 0; top: 0; }
.focus__bar { position: absolute; left: 0; top: 0; width: 2px; background: var(--signal); pointer-events: none; opacity: 0; }

/* Split chars produced by SplitText keep their box so layout does not jump. */
.sx-char, .sx-word { display: inline-block; will-change: auto; }
.sx-line { display: block; }

/* Example frame (D1): the one frame every worked scenario wears, so an example is never mistaken for the offer. Markup:
   <div class="example-frame" data-copy><p class="example-frame__tab">Example</p><p class="example-frame__setup">one line</p>
   <p class="example-frame__fine">optional small print</p></div>
   One solid vermilion block with ink type (it reads on ink and on bone alike): the mono tab, then the setup line at body size, so the
   frame is read before the scenario's own headline. A plain solid fill, no stripes, no tape. */
.example-frame { display: grid; gap: .45rem; width: fit-content; max-width: 100%; margin: 0; padding: .55rem .9rem .7rem; background: var(--signal); color: var(--on-signal); }
.example-frame__tab, .example-frame__setup, .example-frame__fine { margin: 0; }
.example-frame__tab {
  justify-self: start; font-family: var(--font-mono); font-size: .75rem; font-weight: 700; letter-spacing: .16em; line-height: 1.2; text-transform: uppercase;
}
.example-frame__setup { max-width: 52ch; font-family: var(--font-body); font-size: clamp(1.125rem, 1rem + .35vw, 1.25rem); font-weight: 600; letter-spacing: 0; line-height: 1.3; color: inherit; }
.example-frame__fine { max-width: 60ch; font-size: .8125rem; font-weight: 500; line-height: 1.35; color: inherit; }
/* a narrow phone: a tighter block, so the frame still ends above the art band under it */
@media (max-width: 600px) {
  .example-frame { gap: .3rem; padding: .4rem .75rem .5rem; }
}
/* the "we often see" lead-in on a claim about industries: it is our view, not a fact about every business */
.panel__lead { font-weight: 700; color: var(--fg); }

