/**
 * =============================================================================
 *                  SP BOUCHER | SOFTWARE & RESEARCH
 *             ARTIFICIAL INTELLIGENCE • FINANCE • ENGINEERING
 * =============================================================================
 *
 * Project          : SP GlassKit
 * File             : Website/static/site.css
 * Module           : Website
 * Repository       : https://git.spboucher.ai/sp-glasskit
 * Project Website  : https://glass.spboucher.ai
 * Created          : 2026-12-02
 * Last Modified    : 2026-12-02
 *
 * Author           : Simon-Pierre Boucher
 * Position         : Professor of Finance
 * Institution      : Université du Québec en Outaouais (UQO)
 * Organization     : SP Boucher
 * Website          : https://spboucher.ai
 * Git              : https://git.spboucher.ai
 *
 * Preferred Contact: contact@spboucher.ai
 * Development      : dev@spboucher.ai
 * Support          : support@spboucher.ai
 * Security/Admin   : admin@spboucher.ai
 *
 * Copyright (c) 2026
 * Simon-Pierre Boucher
 * All rights reserved where applicable. This file is governed by the
 * applicable project license, copyright notices and relevant law.
 * Existing third-party rights and notices remain unaffected.
 *
 * License          : MIT
 *
 * Do not embed credentials, private keys, access tokens,
 * certificates or confidential personal information.
 *
 * =============================================================================
 * END OF SP BOUCHER SOURCE HEADER
 * =============================================================================
 */

/* SP GlassKit documentation site.
   No web font, no gradient, no blur, no imitation of glass: the product's material is shown only through
   captures of the real application. Hierarchy comes from type, spacing, hairlines and flat colour planes.
   Colours are defined once with light-dark(); the appearance follows the system unless the visitor chose one
   (data-theme on <html>, set by theme.js before first paint). */

/* -- tokens ------------------------------------------------------------------------------------------- */
:root {
  color-scheme: light;
  --bg: #ffffff; --bg-2: #f6f6f3; --bg-3: #ecece8;
  --ink: #0d1117; --ink-2: #434d58; --ink-3: #626b76;
  --line: #e4e4df; --line-2: #cdcdc6;
  --accent: #1d4ed8; --accent-soft: #e9eefb; --focus: #1d4ed8;
  --button: #0d1117; --button-ink: #ffffff;
  --code-bg: #0f1318; --code-ink: #e7eaee; --code-line: #262d37; --code-muted: #9aa5b2;
  --shadow: 0 1px 2px rgb(13 17 23 / 0.06), 0 14px 32px -14px rgb(13 17 23 / 0.28);
  --sa0: #dde4ec; --sa1: #cbd6e2; --sa2: #edf1f5;
  --sb0: #ebe4d7; --sb1: #ddd2bf; --sb2: #f4efe6;
  --sc0: #dbe6de; --sc1: #c8d8cc; --sc2: #ecf2ed;
  --sd0: #eedfd7; --sd1: #e2cbbf; --sd2: #f6ece7;
  --se0: #e2e0ec; --se1: #d1cee0; --se2: #f0eff5;
  --header-h: 3.75rem;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}
@supports (color: light-dark(#000, #fff)) {
  :root {
    color-scheme: light dark;
    --bg: light-dark(#ffffff, #0b0d10); --bg-2: light-dark(#f6f6f3, #12151a); --bg-3: light-dark(#ecece8, #1b2027);
    --ink: light-dark(#0d1117, #f1f3f5); --ink-2: light-dark(#434d58, #b9c1ca); --ink-3: light-dark(#626b76, #8f99a5);
    --line: light-dark(#e4e4df, #22272e); --line-2: light-dark(#cdcdc6, #363d47);
    --accent: light-dark(#1d4ed8, #93b4ff); --accent-soft: light-dark(#e9eefb, #172038); --focus: light-dark(#1d4ed8, #93b4ff);
    --button: light-dark(#0d1117, #f1f3f5); --button-ink: light-dark(#ffffff, #0b0d10);
    --code-bg: light-dark(#0f1318, #12151a); --code-line: light-dark(#262d37, #262c35);
    --shadow: light-dark(0 1px 2px rgb(13 17 23 / 0.06), 0 1px 2px rgb(0 0 0 / 0.4)), 0 14px 32px -14px light-dark(rgb(13 17 23 / 0.28), rgb(0 0 0 / 0.7));
    --sa0: light-dark(#dde4ec, #19202a); --sa1: light-dark(#cbd6e2, #253142); --sa2: light-dark(#edf1f5, #131920);
    --sb0: light-dark(#ebe4d7, #24211a); --sb1: light-dark(#ddd2bf, #353025); --sb2: light-dark(#f4efe6, #1c1a14);
    --sc0: light-dark(#dbe6de, #18221c); --sc1: light-dark(#c8d8cc, #24362b); --sc2: light-dark(#ecf2ed, #131b16);
    --sd0: light-dark(#eedfd7, #281e19); --sd1: light-dark(#e2cbbf, #3b2c25); --sd2: light-dark(#f6ece7, #1f1814);
    --se0: light-dark(#e2e0ec, #1d1c28); --se1: light-dark(#d1cee0, #2d2b3d); --se2: light-dark(#f0eff5, #17161f);
  }
  :root[data-theme="light"] { color-scheme: light; }
  :root[data-theme="dark"] { color-scheme: dark; }
}

/* -- base --------------------------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 1.5rem); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 1rem/1.6 var(--sans); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { display: block; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; font-weight: 660; letter-spacing: -0.02em; text-wrap: balance; }
p { margin: 0 0 1rem; }
ul, ol { margin: 0 0 1rem; padding-left: 1.25rem; }
code, pre, kbd { font-family: var(--mono); }
code { font-size: 0.875em; background: var(--bg-3); padding: 0.12em 0.36em; border-radius: 4px; }
a code { color: inherit; }
.visually-hidden, .toggle-input, .tab-input { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; opacity: 0; }
.skip { position: absolute; left: -999rem; }
.skip:focus { left: 1rem; top: 0.6rem; background: var(--bg); color: var(--ink); padding: 0.5rem 0.9rem; z-index: 30; border: 1px solid var(--line-2); border-radius: 8px; }
.wrap { width: 100%; max-width: 80rem; margin-inline: auto; padding-inline: var(--gutter); }
.muted { color: var(--ink-3); font-size: 0.875rem; }
.icon { flex: none; }
.eyebrow { font: 500 0.75rem/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 1.25rem; }
.eyebrow span { color: var(--line-2); margin-inline: 0.35em; }
.eyebrow .number { color: var(--ink); margin: 0 0.9em 0 0; }
.lead { font-size: clamp(1.1rem, 1.6vw, 1.3rem); line-height: 1.5; color: var(--ink-2); max-width: 44rem; text-wrap: pretty; }
.note { border-left: 2px solid var(--ink); padding: 0.15rem 0 0.15rem 1rem; color: var(--ink-2); font-size: 0.95rem; }
.more { display: inline-flex; align-items: center; gap: 0.4rem; font-weight: 560; text-decoration: none; }
.more:hover { text-decoration: underline; }

/* -- header ------------------------------------------------------------------------------------------- */
header.site { position: sticky; top: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--line); }
.bar { display: flex; align-items: center; gap: 0.5rem; height: var(--header-h); max-width: 90rem; margin-inline: auto; padding-inline: var(--gutter); position: relative; }
.brand { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ink); text-decoration: none; font-weight: 660; letter-spacing: -0.015em; margin-right: 1.25rem; white-space: nowrap; }
.brand img { border-radius: 6px; }
.brand small { font: 500 0.7rem/1 var(--mono); color: var(--ink-3); border: 1px solid var(--line-2); border-radius: 999px; padding: 0.25rem 0.5rem; letter-spacing: 0; }
nav.primary { flex: 1 1 auto; min-width: 0; }
nav.primary ul { display: flex; gap: 0.15rem; list-style: none; margin: 0; padding: 0; }
nav.primary a { display: block; padding: 0.4rem 0.65rem; border-radius: 7px; color: var(--ink-2); text-decoration: none; font-size: 0.9rem; font-weight: 500; }
nav.primary a:hover { color: var(--ink); background: var(--bg-2); }
nav.primary a[aria-current="page"] { color: var(--ink); font-weight: 620; }
.icon-button { display: inline-grid; place-items: center; width: 2.5rem; height: 2.5rem; flex: none; border: 0; border-radius: 9px; background: none; color: var(--ink-2); cursor: pointer; }
.icon-button:hover { background: var(--bg-2); color: var(--ink); }
.menu-button { display: none; }
.toggle-input:focus-visible + label, .tab-input:focus-visible + label { outline: 2px solid var(--focus); outline-offset: 2px; }
.theme-toggle { display: none; }
.js .theme-toggle { display: inline-grid; }
.theme-toggle .icon:first-child { display: none; }
@media (prefers-color-scheme: dark) {
  .theme-toggle .icon:first-child { display: block; }
  .theme-toggle .icon:last-child { display: none; }
}
[data-theme="light"] .theme-toggle .icon:first-child { display: none; }
[data-theme="light"] .theme-toggle .icon:last-child { display: block; }
[data-theme="dark"] .theme-toggle .icon:first-child { display: block; }
[data-theme="dark"] .theme-toggle .icon:last-child { display: none; }

.search { display: none; position: relative; align-items: center; gap: 0.5rem; width: 15rem; height: 2.25rem; padding: 0 0.55rem 0 0.7rem; border: 1px solid var(--line); border-radius: 9px; background: var(--bg-2); color: var(--ink-3); }
.js .search { display: flex; }
.search:focus-within { border-color: var(--ink-3); background: var(--bg); }
.search input { flex: 1; min-width: 0; height: 100%; font: inherit; font-size: 0.9rem; border: 0; outline: 0; background: none; color: var(--ink); padding: 0; appearance: none; -webkit-appearance: none; }
.search input::placeholder { color: var(--ink-3); opacity: 1; }
.search input::-webkit-search-cancel-button { display: none; }
kbd { font-size: 0.7rem; line-height: 1; color: var(--ink-3); border: 1px solid var(--line-2); border-radius: 5px; padding: 0.2rem 0.4rem; background: var(--bg); }
.search:focus-within kbd { visibility: hidden; }
.results { position: absolute; right: 0; top: calc(100% + 0.6rem); width: min(31rem, calc(100vw - 2 * var(--gutter))); max-height: min(70vh, 32rem); overflow: auto; margin: 0; padding: 0.4rem; list-style: none; background: var(--bg); border: 1px solid var(--line-2); border-radius: 14px; box-shadow: var(--shadow); }
.results a { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0.1rem 0.75rem; padding: 0.55rem 0.7rem; border-radius: 9px; text-decoration: none; color: var(--ink); }
.results strong { font-weight: 600; font-size: 0.95rem; }
.results .hit-kind { font: 500 0.68rem/1.6 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.results small { grid-column: 1 / -1; color: var(--ink-3); font-size: 0.82rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.results a:hover, .results [aria-selected="true"] a { background: var(--bg-2); }
.results [aria-selected="true"] a { box-shadow: inset 2px 0 0 var(--ink); }
.results .empty { padding: 0.9rem 0.7rem; color: var(--ink-3); font-size: 0.9rem; }
.results .hint { display: flex; gap: 1rem; padding: 0.55rem 0.7rem 0.3rem; margin-top: 0.3rem; border-top: 1px solid var(--line); color: var(--ink-3); font-size: 0.75rem; }

@media (max-width: 68.75rem) {
  .brand { margin-right: auto; }
  .menu-button { display: inline-grid; order: 5; }
  nav.primary { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--bg); border-bottom: 1px solid var(--line-2); padding: 0.5rem var(--gutter) 1.25rem; max-height: calc(100vh - var(--header-h)); overflow: auto; }
  #menu-toggle:checked ~ nav.primary { display: block; }
  #menu-toggle:checked + .menu-button { background: var(--bg-3); color: var(--ink); }
  nav.primary ul { flex-direction: column; gap: 0; }
  nav.primary a { padding: 0.85rem 0.25rem; border-radius: 0; border-bottom: 1px solid var(--line); font-size: 1.05rem; }
  nav.primary a[aria-current="page"] { box-shadow: inset 2px 0 0 var(--ink); padding-left: 0.9rem; }
  .search { flex: 0 1 15rem; width: auto; min-width: 0; }
}
@media (max-width: 40rem) {
  .brand small, .search kbd { display: none; }
  .search { flex-basis: 9rem; }
  .results { position: fixed; left: var(--gutter); right: var(--gutter); top: calc(var(--header-h) + 0.4rem); width: auto; }
}

/* -- buttons, commands, code -------------------------------------------------------------------------- */
.actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 0; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 2.75rem; padding: 0.5rem 1.15rem; border: 1px solid var(--line-2); border-radius: 10px; background: var(--bg); color: var(--ink); font-weight: 560; font-size: 0.95rem; text-decoration: none; white-space: nowrap; }
.button:hover { border-color: var(--ink-3); background: var(--bg-2); }
.button.primary { background: var(--button); border-color: var(--button); color: var(--button-ink); }
.button.primary:hover { background: var(--ink-2); border-color: var(--ink-2); }
.button.quiet { border-color: transparent; color: var(--ink-2); padding-inline: 0.7rem; }
.button.small { min-height: 2.25rem; padding: 0.3rem 0.8rem; font-size: 0.85rem; border-radius: 8px; }

.copy { display: none; align-items: center; gap: 0.4rem; flex: none; font: 500 0.78rem/1 var(--sans); padding: 0.45rem 0.6rem; border: 1px solid var(--code-line); border-radius: 7px; background: transparent; color: var(--code-muted); cursor: pointer; }
.js .copy { display: inline-flex; }
.copy:hover { color: var(--code-ink); border-color: var(--code-muted); }
.copy code { background: none; padding: 0; color: inherit; }
.copy[data-state="done"] { color: #9fd9ad; border-color: #3c6b49; }

.command { display: flex; align-items: center; gap: 0.75rem; max-width: 34rem; padding: 0.5rem 0.5rem 0.5rem 1rem; min-height: 3rem; border-radius: 12px; background: var(--code-bg); color: var(--code-ink); border: 1px solid var(--code-line); }
.prose > .command, .steps .command { margin: 1.25rem 0; }
.command .prompt { color: var(--code-muted); font-family: var(--mono); user-select: none; }
.command code { flex: 1; min-width: 0; overflow-x: auto; white-space: nowrap; background: none; padding: 0.3rem 0; font-size: 0.9rem; color: inherit; scrollbar-width: none; }

figure { margin: 0; }
figure.code { margin: 1.5rem 0; border-radius: 12px; overflow: hidden; background: var(--code-bg); color: var(--code-ink); border: 1px solid var(--code-line); }
figure.code figcaption { display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 2.75rem; padding: 0.35rem 0.5rem 0.35rem 1.1rem; border-bottom: 1px solid var(--code-line); font: 500 0.75rem/1.3 var(--mono); letter-spacing: 0.03em; color: var(--code-muted); }
figure.code pre { margin: 0; padding: 1.1rem 1.1rem 1.2rem; overflow-x: auto; font-size: 0.84rem; line-height: 1.65; tab-size: 4; }
figure.code pre:focus-visible { outline-offset: -3px; outline-color: #93b4ff; }
figure.code code { background: none; padding: 0; font-size: inherit; color: inherit; }
.t-com { color: #8792a0; font-style: italic; }
.t-str { color: #a8d5b0; }
.t-kw { color: #93b4ff; }
.t-ty { color: #e6c690; }
.t-num { color: #e6c690; }
.t-dot { color: #c5d4f7; }

.tabs { display: flex; flex-wrap: wrap; gap: 0 0.25rem; margin: 1.25rem 0; }
.tab { position: relative; padding: 0.55rem 0.2rem; margin: 0 1.1rem -1px 0; font-size: 0.9rem; font-weight: 560; color: var(--ink-3); border-bottom: 2px solid transparent; cursor: pointer; }
.tab:hover { color: var(--ink); }
.tab-input:checked + .tab { color: var(--ink); border-bottom-color: var(--ink); }
.tab-panel { display: none; flex: 0 0 100%; min-width: 0; border-top: 1px solid var(--line); padding-top: 1.25rem; }
.tab-panel > :first-child { margin-top: 0; }
.tab-panel > :last-child { margin-bottom: 0; }
.tab-input:nth-of-type(1):checked ~ .tab-panel:nth-of-type(1),
.tab-input:nth-of-type(2):checked ~ .tab-panel:nth-of-type(2),
.tab-input:nth-of-type(3):checked ~ .tab-panel:nth-of-type(3) { display: block; }

/* -- kinds -------------------------------------------------------------------------------------------- */
.kind { display: inline-flex; align-items: center; gap: 0.45rem; font-size: 0.75rem; font-weight: 560; line-height: 1.5; color: var(--ink-2); border: 1px solid var(--line-2); border-radius: 999px; padding: 0.08rem 0.6rem 0.08rem 0.5rem; white-space: nowrap; background: var(--bg); }
.kind::before { content: ""; width: 0.5rem; height: 0.5rem; flex: none; }
.kind-native-wrapper::before { border: 1.5px solid var(--ink-2); border-radius: 50%; }
.kind-custom-glass::before { background: var(--accent); transform: rotate(45deg) scale(0.85); }
.kind-content-component::before { background: var(--ink-2); border-radius: 1px; }
.kind-primitive::before { border: 1.5px solid var(--ink-3); }

/* -- stages and captures ------------------------------------------------------------------------------ */
/* A stage is a flat colour plane with two geometric shapes. It carries captures; it never imitates glass. */
.stage { position: relative; display: block; overflow: hidden; isolation: isolate; border-radius: 16px; background: var(--s0); --s0: var(--sa0); --s1: var(--sa1); --s2: var(--sa2); }
.stage::before { content: ""; position: absolute; z-index: -1; width: 72%; aspect-ratio: 1; left: -20%; bottom: -46%; border-radius: 50%; background: var(--s1); }
.stage::after { content: ""; position: absolute; z-index: -1; right: 0; top: 0; width: 36%; height: 44%; background: var(--s2); }
.tone-b { --s0: var(--sb0); --s1: var(--sb1); --s2: var(--sb2); }
.tone-c { --s0: var(--sc0); --s1: var(--sc1); --s2: var(--sc2); }
.tone-d { --s0: var(--sd0); --s1: var(--sd1); --s2: var(--sd2); }
.tone-e { --s0: var(--se0); --s1: var(--se1); --s2: var(--se2); }
.tone-b::before, .tone-e::before { left: auto; right: -22%; bottom: -50%; }
.tone-b::after, .tone-e::after { right: auto; left: 0; top: auto; bottom: 0; width: 30%; height: 38%; }
.tone-c::before { bottom: auto; top: -52%; left: 30%; }
.tone-c::after { top: auto; bottom: 0; width: 46%; height: 30%; }
.tone-d::before { border-radius: 0; width: 44%; aspect-ratio: auto; height: 100%; left: 0; bottom: 0; }
.tone-d::after { border-radius: 50%; width: 38%; height: auto; aspect-ratio: 1; right: -8%; top: -18%; }
.shot { border-radius: 12px; box-shadow: var(--shadow); background: #fff; }
.tag { position: absolute; left: 0.9rem; top: 0.8rem; font: 500 0.66rem/1 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-2); }
.figure { margin: 2rem 0; }
.figure .stage { display: grid; place-items: center; padding: clamp(2.5rem, 6vw, 4rem) clamp(1.25rem, 5vw, 3.5rem); min-height: 17rem; }
.figure figcaption, .mosaic-figure figcaption { margin-top: 0.75rem; font-size: 0.82rem; line-height: 1.5; color: var(--ink-3); max-width: 44rem; }
.figure .shot { height: auto; }
.figure .shot-tall { width: min(100%, 19rem); }
.figure .shot-even { width: min(100%, 26rem); }
.figure .shot-wide { width: min(100%, 31rem); }
.device .shot { width: 100%; border-radius: 10px; }
.device-phone .shot { width: min(100%, 15rem); border-radius: 22px; }

/* -- home --------------------------------------------------------------------------------------------- */
.hero { padding: clamp(3rem, 7vw, 5.5rem) 0 0; }
.hero h1 { font-size: clamp(2.6rem, 5.5vw, 4.6rem); line-height: 0.98; letter-spacing: -0.045em; font-weight: 700; max-width: 12ch; margin-bottom: 1.75rem; }
.hero .lead { margin-bottom: 2.25rem; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(2.5rem, 5vw, 4rem); }
@media (min-width: 68.76rem) {
  .hero-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: start; }
  .hero-text { padding-top: 1.5rem; }
  .hero .mosaic { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: clamp(9.5rem, 13.6vw, 12.75rem); }
  .hero .tile-5 { grid-column: span 3; }
}
.hero-install { margin-bottom: 1.5rem; }
.hero-note { margin: 0.6rem 0 0; font-size: 0.85rem; color: var(--ink-3); }
.facts-strip { display: grid; grid-template-columns: repeat(4, 1fr); margin: clamp(3rem, 6vw, 4.5rem) 0 0; border-bottom: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts-strip > div { padding: 1.4rem 1.5rem 1.5rem; border-left: 1px solid var(--line); }
.facts-strip > div:first-child { border-left: 0; padding-left: 0; }
.facts-strip dt { font: 500 0.72rem/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.facts-strip dd { margin: 0.5rem 0 0; font-size: clamp(2rem, 4vw, 3rem); font-weight: 660; letter-spacing: -0.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.facts-strip .fact-note { margin-top: 0.6rem; font-size: 0.85rem; font-weight: 400; letter-spacing: 0; line-height: 1.4; color: var(--ink-3); }

.mosaic { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: clamp(11rem, 21vw, 18rem); grid-auto-flow: dense; gap: 0.85rem; list-style: none; margin: 0; padding: 0; }
.tile-tall { grid-row: span 2; }
.tile-wide { grid-column: span 2; }
.tile .stage { width: 100%; height: 100%; color: var(--ink-2); text-decoration: none; }
.tile .shot, .card .shot { position: absolute; inset: 1.5rem; margin: auto; width: auto; height: auto; max-width: calc(100% - 3rem); max-height: calc(100% - 3rem); }
.tile .shot { inset: 2.4rem 1.5rem; max-height: calc(100% - 4.8rem); }
.tile-name { position: absolute; left: 0.9rem; bottom: 0.7rem; font: 500 0.7rem/1 var(--mono); letter-spacing: 0.04em; }
.tile a:hover .tile-name { text-decoration: underline; color: var(--ink); }

.band { border-top: 1px solid var(--line); padding: clamp(4rem, 9vw, 7rem) 0; }
.band h2 { font-size: clamp(1.75rem, 3.6vw, 2.75rem); letter-spacing: -0.035em; line-height: 1.05; margin-bottom: 1.25rem; }
.band-head { max-width: 46rem; margin-bottom: clamp(2rem, 4vw, 3rem); }
.band-head p:not(.eyebrow), .split-head p:not(.eyebrow) { color: var(--ink-2); font-size: 1.05rem; text-wrap: pretty; }
.band-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.75rem 2rem; margin: 1.75rem 0 0; }
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(2rem, 6vw, 5.5rem); align-items: start; }
.split-body > :first-child { margin-top: 0; }
.split-body .tabs { margin-top: -0.55rem; }
.kinds, .points, .grid-cells, .index, .theme-chips, .legend, .badges, .gallery, .chips, .swatches, .artifacts, .modules, .link-list, .files, .theme-meta { list-style: none; margin: 0; padding: 0; }
.kinds li { display: grid; grid-template-columns: 9.5rem 2rem minmax(0, 1fr); gap: 1rem; align-items: baseline; padding: 1rem 0; border-top: 1px solid var(--line); color: var(--ink-2); font-size: 0.95rem; }
.kinds .kind { justify-self: start; align-self: center; }
.kind-count { font: 600 1.05rem/1 var(--sans); font-variant-numeric: tabular-nums; color: var(--ink); text-align: right; }
.points { border-bottom: 1px solid var(--line); margin-top: 0; }
.points li { padding: 1rem 0; border-top: 1px solid var(--line); color: var(--ink-2); font-size: 0.95rem; }
.points strong, .grid-cells strong { color: var(--ink); font-weight: 620; }
.grid-cells { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.grid-cells li { padding: 1.5rem 1.75rem 1.75rem 0; border-bottom: 1px solid var(--line); color: var(--ink-2); font-size: 0.95rem; }
.grid-cells li:not(:nth-child(3n + 1)) { padding-left: 1.75rem; border-left: 1px solid var(--line); }
.grid-cells strong { display: block; margin-bottom: 0.4rem; font-size: 1rem; }

.theme-chips { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.85rem; }
.theme-chip { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--line-2); border-radius: 14px; overflow: hidden; text-decoration: none; color: var(--ink); background: var(--bg); }
.theme-chip:hover { border-color: var(--ink-3); }
.theme-chip-name { grid-column: 1 / -1; padding: 0.65rem 0.9rem; border-top: 1px solid var(--line-2); font-size: 0.9rem; font-weight: 600; }
.mini { display: grid; align-content: start; gap: 0.5rem; padding: 0.9rem; min-height: 6.5rem; background: var(--t-background); }
.mini-bar { height: 1.5rem; border-radius: 6px; background: var(--t-surface); border: 1px solid var(--t-separator); }
.mini-line { height: 0.35rem; width: 62%; border-radius: 2px; background: var(--t-textPrimary); }
.mini-dots { display: flex; gap: 0.3rem; margin-top: 0.15rem; }
.mini-dots i { width: 0.9rem; height: 0.9rem; border-radius: 50%; }
.d-primary { background: var(--t-primary); } .d-secondary { background: var(--t-secondary); } .d-accent { background: var(--t-accent); }

.devices { display: grid; grid-template-columns: minmax(0, 2.7fr) minmax(0, 1fr); gap: 0.85rem; }
.devices .figure { margin: 0; display: flex; flex-direction: column; }
.devices .stage { flex: 1; }
.device-mac .stage { padding: clamp(1.75rem, 4vw, 3rem); }

.index { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: clamp(2rem, 6vw, 5.5rem); border-bottom: 1px solid var(--line); }
.index a { display: grid; grid-template-columns: 2.25rem 8.5rem minmax(0, 1fr) auto; gap: 0.75rem; align-items: baseline; padding: 1.05rem 0; border-top: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.index a:hover strong { text-decoration: underline; }
.index-number, .index-count { font: 500 0.75rem/1.4 var(--mono); color: var(--ink-3); }
.index-names { color: var(--ink-3); font-size: 0.85rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.closing { text-align: left; }
.closing h2 { margin-bottom: 1.75rem; }

/* -- page heads and articles -------------------------------------------------------------------------- */
.page-head { padding: clamp(2.75rem, 6vw, 4.5rem) 0 clamp(2rem, 4vw, 3rem); }
.page-head h1, .docs-main h1, .missing h1 { font-size: clamp(2.25rem, 5vw, 3.5rem); letter-spacing: -0.04em; line-height: 1; font-weight: 700; margin-bottom: 1.25rem; }
.page-head .lead { margin: 0; }
.article { padding-bottom: clamp(4rem, 8vw, 6rem); }
.article .page-head { border-bottom: 1px solid var(--line); margin-bottom: 2.5rem; }
.article-grid { display: grid; grid-template-columns: minmax(0, 48rem) 13rem; justify-content: space-between; gap: 3rem; align-items: start; }
.toc { position: sticky; top: calc(var(--header-h) + 2rem); max-height: calc(100vh - var(--header-h) - 4rem); overflow: auto; font-size: 0.85rem; }
.toc-title { font: 500 0.7rem/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 0.75rem; }
.toc ul { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.toc a { display: block; padding: 0.3rem 0 0.3rem 0.9rem; margin-left: -1px; border-left: 1px solid transparent; color: var(--ink-3); text-decoration: none; line-height: 1.4; }
.toc a:hover { color: var(--ink); }
.toc a[aria-current="true"] { color: var(--ink); border-left-color: var(--ink); font-weight: 560; }

.prose { min-width: 0; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-size: 1.6rem; letter-spacing: -0.03em; margin: 3.25rem 0 1rem; padding-top: 2rem; border-top: 1px solid var(--line); }
.prose > h2:first-child { border-top: 0; padding-top: 0; }
.prose h3 { color: var(--ink); font-size: 1.12rem; letter-spacing: -0.015em; margin: 2.25rem 0 0.6rem; }
.prose h4 { font-size: 1rem; margin: 1.5rem 0 0.4rem; }
.prose p, .prose li { color: var(--ink-2); text-wrap: pretty; }
.prose li { margin: 0.35rem 0; }
.prose li::marker { color: var(--ink-3); }
.prose strong { color: var(--ink); font-weight: 620; }
.prose h2 a, .prose h3 a { color: inherit; text-decoration: none; }
.prose h3 a:hover { text-decoration: underline; }
.section-lead { color: var(--ink-2); max-width: 44rem; }

.table { overflow-x: auto; margin: 1.25rem 0 1.75rem; border-top: 1px solid var(--line-2); }
table { border-collapse: collapse; width: 100%; font-size: 0.9rem; line-height: 1.5; }
th, td { text-align: left; vertical-align: top; padding: 0.7rem 1rem 0.7rem 0; border-bottom: 1px solid var(--line); color: var(--ink-2); }
th:last-child, td:last-child { padding-right: 0; }
thead th { font: 500 0.7rem/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); white-space: nowrap; padding-top: 0.75rem; }
tbody th { font-weight: 560; color: var(--ink); }
.facts tbody th { width: 9.5rem; font-weight: 400; color: var(--ink-3); white-space: nowrap; }
td code, th code { white-space: nowrap; }
td:last-child code { white-space: normal; overflow-wrap: anywhere; }
@media (min-width: 48rem) { tbody th { white-space: nowrap; } }

.steps { list-style: none; padding: 0; counter-reset: step; margin: 1.75rem 0; }
.steps > li { counter-increment: step; position: relative; padding: 0 0 1.25rem 3.25rem; margin: 0; border-left: 1px solid var(--line); margin-left: 1rem; }
.steps > li:last-child { border-left-color: transparent; padding-bottom: 0; }
.steps > li::before { content: counter(step); position: absolute; left: -1rem; top: -0.2rem; width: 2rem; height: 2rem; display: grid; place-items: center; border: 1px solid var(--line-2); border-radius: 50%; background: var(--bg); font: 500 0.8rem/1 var(--mono); color: var(--ink); }
.steps h3 { margin-top: 0; }
.link-list { border-top: 1px solid var(--line); }
.link-list li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.25rem 1.5rem; padding: 0.7rem 0; margin: 0; border-bottom: 1px solid var(--line); }
.link-list a { font-family: var(--mono); font-size: 0.875rem; }
.link-list span { color: var(--ink-3); font-size: 0.9rem; }
.files { border-top: 1px solid var(--line); }
.files li { padding: 0.6rem 0; margin: 0; border-bottom: 1px solid var(--line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.2rem 1.5rem; }
.files code { overflow-wrap: anywhere; }
.modules { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 2.5rem; border-bottom: 1px solid var(--line); }
.modules li { padding: 1rem 0; margin: 0; border-top: 1px solid var(--line); display: grid; gap: 0.35rem; align-content: start; }
.modules code { justify-self: start; font-size: 0.85rem; color: var(--ink); }
.modules span { font-size: 0.9rem; color: var(--ink-2); }
.artifacts { border-top: 1px solid var(--line-2); }
.artifact { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0.75rem 1.5rem; align-items: start; padding: 1.4rem 0; margin: 0; border-bottom: 1px solid var(--line); }
.artifact h3 { margin: 0 0 0.3rem; font-size: 1.05rem; }
.artifact p { margin: 0; font-size: 0.9rem; }
.checksum { grid-column: 1 / -1; display: flex; align-items: center; gap: 0.75rem; padding: 0.4rem 0.4rem 0.4rem 0.9rem; border-radius: 10px; background: var(--code-bg); color: var(--code-ink); border: 1px solid var(--code-line); }
.checksum span:first-child { font: 500 0.68rem/1 var(--mono); letter-spacing: 0.08em; color: var(--code-muted); white-space: nowrap; }
.checksum code { flex: 1; min-width: 0; background: none; padding: 0.4rem 0; color: inherit; font-size: 0.78rem; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
.changelog .prose h2 { font-size: 2rem; font-variant-numeric: tabular-nums; }
.missing { padding: clamp(5rem, 14vw, 10rem) var(--gutter); min-height: 60vh; }
.missing .lead { margin-bottom: 2rem; }

/* -- components gallery ------------------------------------------------------------------------------- */
.legend { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 2rem; margin-top: 2.5rem; border-top: 1px solid var(--line); }
.legend .kind { justify-self: start; align-self: start; }
.legend li { display: grid; gap: 0.6rem; justify-items: start; align-content: start; padding: 1.1rem 0 0; color: var(--ink-3); font-size: 0.875rem; line-height: 1.5; }
.subnav { position: sticky; top: var(--header-h); z-index: 10; background: var(--bg); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.subnav-inner { display: flex; align-items: center; gap: 1rem; min-height: 3.5rem; }
.subnav nav { min-width: 0; flex: 1; }
.filter { display: none; align-items: center; gap: 0.5rem; flex: 0 0 14rem; height: 2.25rem; padding: 0 0.7rem; border: 1px solid var(--line); border-radius: 9px; background: var(--bg-2); color: var(--ink-3); }
.js .filter { display: flex; }
.filter:focus-within { border-color: var(--ink-3); background: var(--bg); }
.filter input { flex: 1; min-width: 0; height: 100%; font: inherit; font-size: 0.9rem; border: 0; outline: 0; background: none; color: var(--ink); appearance: none; -webkit-appearance: none; padding: 0; }
.filter input::placeholder { color: var(--ink-3); opacity: 1; }
.chips { display: flex; gap: 0.4rem; overflow-x: auto; scrollbar-width: none; padding: 0.6rem 0; }
.chips::-webkit-scrollbar { display: none; }
.chips.jump { flex-wrap: wrap; margin-bottom: 0.5rem; }
.chip { display: block; padding: 0.3rem 0.8rem; border: 1px solid var(--line-2); border-radius: 999px; font-size: 0.85rem; font-weight: 500; color: var(--ink-2); text-decoration: none; white-space: nowrap; background: var(--bg); }
.chip:hover { border-color: var(--ink-3); color: var(--ink); }
.js .chip[aria-current="true"] { background: var(--button); border-color: var(--button); color: var(--button-ink); }
.gallery-wrap { padding-bottom: clamp(4rem, 8vw, 6rem); }
.page-gallery { scroll-padding-top: 9rem; }
.gallery-section { padding-top: clamp(2.5rem, 5vw, 3.5rem); }
.gallery-section h2 { scroll-margin-top: calc(var(--header-h) + 5rem); }
.gallery-head { display: flex; align-items: baseline; gap: 0.75rem; margin-bottom: 1.5rem; }
.gallery-head h2 { font-size: 1.6rem; letter-spacing: -0.03em; }
.count { font: 500 0.75rem/1 var(--mono); color: var(--ink-3); }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(13.25rem, 1fr)); gap: 2rem 1rem; }
.card a { display: block; color: var(--ink); text-decoration: none; }
.card .stage { aspect-ratio: 5 / 4; border-radius: 14px; }
.card .shot { border-radius: 9px; inset: 1.4rem; max-width: calc(100% - 2.8rem); max-height: calc(100% - 2.8rem); }
.no-shot { position: absolute; inset: 0; display: grid; place-items: center; font: 500 0.72rem/1 var(--mono); color: var(--ink-3); }
.card-text { display: grid; gap: 0.2rem; justify-items: start; padding: 0.85rem 0.15rem 0; }
.kind.plain { border: 0; padding: 0; background: none; color: var(--ink-3); font-weight: 500; }
.card-text strong { font-weight: 620; letter-spacing: -0.01em; }
.card-text p { margin: 0.25rem 0 0; color: var(--ink-3); font-size: 0.875rem; line-height: 1.45; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; }
.card a:hover strong { text-decoration: underline; text-underline-offset: 0.2em; }
.card a:hover .stage { box-shadow: inset 0 0 0 1px var(--line-2); }
.empty-note { padding: 4rem 0; color: var(--ink-3); text-align: center; }
.capture-note { margin: 3rem 0 0; padding-top: 1.25rem; border-top: 1px solid var(--line); }
[hidden] { display: none !important; }

/* -- component page ----------------------------------------------------------------------------------- */
.docs { display: grid; grid-template-columns: 13.5rem minmax(0, 1fr) 12.5rem; gap: clamp(2rem, 4vw, 3.5rem); align-items: start; }
.sidebar { position: sticky; top: var(--header-h); height: calc(100vh - var(--header-h)); overflow-y: auto; padding: 2.25rem 0.5rem 3rem 0; border-right: 1px solid var(--line); scrollbar-width: thin; }
.side-label { display: none; }
.side-all { display: inline-flex; align-items: center; gap: 0.4rem; margin-bottom: 0.5rem; font-size: 0.85rem; font-weight: 560; color: var(--ink-2); text-decoration: none; }
.side-all:hover { color: var(--ink); }
.side-title { font: 500 0.7rem/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); margin: 1.6rem 0 0.4rem; }
.sidebar ul { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.sidebar li a { display: block; padding: 0.28rem 0 0.28rem 0.85rem; margin-left: -1px; border-left: 1px solid transparent; font-size: 0.875rem; color: var(--ink-2); text-decoration: none; }
.sidebar li a:hover { color: var(--ink); border-left-color: var(--line-2); }
.sidebar li a[aria-current="page"] { color: var(--ink); font-weight: 620; border-left-color: var(--ink); }
.docs-main { min-width: 0; max-width: 48rem; padding: 2.25rem 0 clamp(4rem, 8vw, 6rem); }
.docs > .toc { margin-top: 2.25rem; }
.crumbs { display: flex; gap: 0.5rem; font-size: 0.85rem; color: var(--ink-3); margin-bottom: 1.5rem; }
.crumbs a { color: var(--ink-3); text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }
.docs-main .lead { margin-bottom: 1.5rem; }
.badges { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1.1rem; font-size: 0.82rem; color: var(--ink-3); margin-bottom: 0.9rem; }
.kind-note { font-size: 0.9rem; color: var(--ink-3); margin: 0; }
.docs-main > h2 { font-size: 1.6rem; letter-spacing: -0.03em; margin: 3rem 0 0; padding-top: 2rem; border-top: 1px solid var(--line); }
.docs-main > .tabs { margin-top: 0.75rem; }
.docs-main .prose { margin-top: 0.5rem; }
.docs-main .prose > .table:first-child { margin-top: 2.5rem; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 0.85rem; margin-top: 4rem; }
.pager a { display: grid; gap: 0.25rem; padding: 1rem 1.2rem; border: 1px solid var(--line-2); border-radius: 12px; text-decoration: none; color: var(--ink); }
.pager a:hover { border-color: var(--ink-3); background: var(--bg-2); }
.pager span { font: 500 0.7rem/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.pager-next { text-align: right; }

/* -- themes ------------------------------------------------------------------------------------------- */
.themes-page > h2 { font-size: 1.6rem; letter-spacing: -0.03em; margin: 4rem 0 1rem; padding-top: 2rem; border-top: 1px solid var(--line-2); }
.themes-intro { display: grid; grid-template-columns: minmax(0, 48rem) minmax(0, 20rem); justify-content: space-between; gap: 3rem; align-items: start; }
.themes-intro .figure { margin: 0; }
.theme { padding: 2.5rem 0 3rem; border-top: 1px solid var(--line); }
.themes-page nav + .theme { border-top: 0; padding-top: 1.5rem; }
.theme-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 1rem 3rem; margin-bottom: 1.5rem; }
.theme-head h3 { font-size: 1.9rem; letter-spacing: -0.035em; margin-bottom: 0.4rem; }
.theme-head p { margin: 0; color: var(--ink-2); max-width: 34rem; }
.theme-meta { display: grid; grid-template-columns: repeat(2, auto); gap: 0.2rem 2rem; font-size: 0.82rem; color: var(--ink-2); }
.theme-meta span { display: inline-block; min-width: 3.6rem; font: 500 0.68rem/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.theme-modes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.85rem; }
.theme-mode { padding: 1.4rem; border-radius: 16px; background: var(--t-background); color: var(--t-textPrimary); border: 1px solid var(--line-2); }
.theme-mode-title { font: 500 0.68rem/1 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--t-textSecondary); margin-bottom: 1.1rem; }
.specimen { display: grid; gap: 0.9rem; font-size: 0.875rem; line-height: 1.3; margin-bottom: 1.5rem; font-family: var(--sans); }
.font-rounded { font-family: ui-rounded, "SF Pro Rounded", var(--sans); }
.font-serif { font-family: ui-serif, "New York", Georgia, serif; }
.font-mono { font-family: var(--mono); }
.sp-head { display: flex; justify-content: space-between; align-items: center; }
.sp-title { font-size: 1.15rem; font-weight: 660; letter-spacing: -0.02em; }
.sp-pill { font-size: 0.7rem; font-weight: 620; padding: 0.2rem 0.6rem; border-radius: 999px; background: var(--t-accent); color: var(--t-on-accent); }
.sp-card { display: grid; gap: 0.45rem; padding: 1rem 1.1rem 1.1rem; background: var(--t-surface); border: 1px solid var(--t-separator); border-radius: var(--t-r-large, 18px); }
.sp-label { font-size: 0.66rem; font-weight: 600; letter-spacing: 0.09em; text-transform: uppercase; color: var(--t-textSecondary); }
.sp-figure { font-size: 1.8rem; font-weight: 660; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.sp-figure small { font-size: 0.8rem; font-weight: 500; letter-spacing: 0; color: var(--t-textSecondary); }
.sp-meter { display: block; height: 0.4rem; border-radius: 999px; background: var(--t-separator); overflow: hidden; }
.sp-meter i { display: block; width: 62%; height: 100%; background: var(--t-primary); border-radius: inherit; }
.sp-sub { font-size: 0.8rem; color: var(--t-textSecondary); }
.sp-actions { display: flex; align-items: center; gap: 0.5rem; }
.sp-button { padding: 0.5rem 1rem; border-radius: var(--t-r-medium, 12px); background: var(--t-primary); color: var(--t-on-primary); font-weight: 600; border: 1px solid var(--t-primary); }
.sp-button.plain { background: transparent; color: var(--t-textPrimary); border-color: var(--t-separator); }
.sp-switch { margin-left: auto; width: 2.6rem; height: 1.55rem; border-radius: 999px; background: var(--t-primary); padding: 0.15rem; display: flex; justify-content: flex-end; }
.sp-switch i { width: 1.25rem; height: 1.25rem; border-radius: 50%; background: var(--t-on-primary); }
.sp-status { display: flex; flex-wrap: wrap; gap: 0.4rem 1.1rem; font-size: 0.78rem; font-weight: 560; }
.sp-status span { display: inline-flex; align-items: center; gap: 0.4rem; }
.sp-status span::before { content: ""; width: 0.55rem; height: 0.55rem; }
.s-success { color: var(--t-success); } .s-success::before { background: currentColor; border-radius: 50%; }
.s-warning { color: var(--t-warning); } .s-warning::before { background: currentColor; transform: rotate(45deg) scale(0.85); }
.s-destructive { color: var(--t-destructive); } .s-destructive::before { background: currentColor; }
.swatches { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.9rem 0.6rem; padding-top: 1.25rem; border-top: 1px solid var(--t-separator); }
.swatches li { display: grid; gap: 0.15rem; min-width: 0; }
.swatch { height: 2.1rem; border-radius: 7px; border: 1px solid var(--t-separator); margin-bottom: 0.3rem; }
.swatch-role { font-size: 0.74rem; font-weight: 560; overflow: hidden; text-overflow: ellipsis; }
.swatch-value { font: 0.68rem/1.3 var(--mono); color: var(--t-textSecondary); }
.sw-background { background: var(--t-background); } .sw-surface { background: var(--t-surface); } .sw-textPrimary { background: var(--t-textPrimary); }
.sw-textSecondary { background: var(--t-textSecondary); } .sw-separator { background: var(--t-separator); } .sw-primary { background: var(--t-primary); }
.sw-secondary { background: var(--t-secondary); } .sw-accent { background: var(--t-accent); } .sw-success { background: var(--t-success); }
.sw-warning { background: var(--t-warning); } .sw-destructive { background: var(--t-destructive); } .sw-focusRing { background: var(--t-focusRing); }
.theme-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; margin-top: 0.85rem; }
.theme-actions .command { flex: 0 1 24rem; min-height: 2.6rem; padding-block: 0.3rem; }
.theme-actions > .copy { color: var(--ink-2); border-color: var(--line-2); min-height: 2.25rem; border-radius: 8px; }
.theme-actions > .copy:hover { color: var(--ink); border-color: var(--ink-3); }

/* -- footer ------------------------------------------------------------------------------------------- */
footer.site { border-top: 1px solid var(--line); padding: 3.5rem 0 2.5rem; font-size: 0.9rem; color: var(--ink-2); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 2.2fr) repeat(3, minmax(0, 1fr)); gap: 2.5rem; }
.footer-name { display: flex; align-items: center; gap: 0.55rem; color: var(--ink); margin-bottom: 0.75rem; }
.footer-name img { border-radius: 5px; }
.footer-name span { font: 500 0.72rem/1 var(--mono); color: var(--ink-3); }
.footer-brand p:last-child { max-width: 24rem; color: var(--ink-3); }
.footer-title { font: 500 0.7rem/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 0.75rem; }
footer.site ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.15rem; }
footer.site li a { display: inline-block; padding: 0.25rem 0; color: var(--ink-2); text-decoration: none; }
footer.site li a:hover { color: var(--ink); text-decoration: underline; }
.footer-legal { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--line); font-size: 0.8rem; color: var(--ink-3); }
.footer-legal p { margin: 0 0 0.4rem; max-width: 56rem; }

/* -- responsive --------------------------------------------------------------------------------------- */
@media (max-width: 75rem) {
  .docs { grid-template-columns: 13.5rem minmax(0, 1fr); }
  .docs > .toc { display: none; }
}
@media (max-width: 64rem) {
  .article-grid { grid-template-columns: minmax(0, 1fr); }
  .article-grid > .toc { display: none; }
  .themes-intro { grid-template-columns: minmax(0, 1fr); }
  .themes-intro .figure { max-width: 24rem; }
}
@media (max-width: 56rem) {
  .split { grid-template-columns: minmax(0, 1fr); }
  .grid-cells { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-cells li:not(:nth-child(3n + 1)) { padding-left: 0; border-left: 0; }
  .grid-cells li:nth-child(2n) { padding-left: 1.5rem; border-left: 1px solid var(--line); }
  .index { grid-template-columns: minmax(0, 1fr); }
  .legend { grid-template-columns: minmax(0, 1fr); }
  .legend li { grid-template-columns: 9rem minmax(0, 1fr); padding: 0.8rem 0; border-bottom: 1px solid var(--line); }
  .docs { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .sidebar { position: static; height: auto; overflow: visible; padding: 0; border-right: 0; margin-inline: calc(-1 * var(--gutter)); border-bottom: 1px solid var(--line); }
  .side-label { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 0.8rem var(--gutter); cursor: pointer; font-weight: 600; font-size: 0.95rem; }
  .side-kicker { color: var(--ink-3); font-weight: 400; margin-right: 0.6rem; }
  .sidebar nav { display: none; padding: 0.5rem var(--gutter) 1.5rem; border-top: 1px solid var(--line); max-height: 60vh; overflow: auto; }
  #side-toggle:checked ~ nav { display: block; }
  #side-toggle:checked + .side-label .icon { transform: rotate(180deg); }
  .sidebar li a { padding-block: 0.5rem; font-size: 0.95rem; }
  .footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
  .theme-modes { grid-template-columns: minmax(0, 1fr); }
  .devices { grid-template-columns: minmax(0, 1fr); }
  .theme-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 45rem) {
  .facts-strip { grid-template-columns: repeat(2, 1fr); }
  .facts-strip > div { padding: 1.1rem 1rem 1.2rem 0; border-left: 0; }
  .facts-strip > div:nth-child(2n) { padding-left: 1rem; border-left: 1px solid var(--line); }
  .facts-strip > div:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .mosaic { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: clamp(9rem, 44vw, 15rem); gap: 0.6rem; }
  .kinds li { grid-template-columns: minmax(0, 1fr) auto; gap: 0.4rem 1rem; }
  .kinds li span:last-child { grid-column: 1 / -1; }
  .index a { grid-template-columns: 2rem minmax(0, 1fr) auto; }
  .index-names { grid-column: 2 / -1; grid-row: 2; white-space: normal; }
  .index-count { grid-column: 3; grid-row: 1; }
  .subnav-inner { flex-wrap: wrap; gap: 0; padding-top: 0.6rem; }
  .filter { flex: 1 1 100%; }
  .subnav nav { flex: 1 1 100%; }
  .modules { grid-template-columns: minmax(0, 1fr); }
  .artifact { grid-template-columns: minmax(0, 1fr); }
  .swatches { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .theme-meta { grid-template-columns: minmax(0, 1fr); }
  .steps > li { padding-left: 1.75rem; margin-left: 0.9rem; }
  .pager { grid-template-columns: minmax(0, 1fr); }
  .pager-next { text-align: left; }
}
@media (max-width: 34rem) {
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 0.75rem; }
  .card .shot { inset: 0.9rem; max-width: calc(100% - 1.8rem); max-height: calc(100% - 1.8rem); }
}
@media (max-width: 30rem) {
  .grid-cells { grid-template-columns: minmax(0, 1fr); }
  .grid-cells li:nth-child(n) { padding-left: 0; border-left: 0; padding-right: 0; }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .actions .button { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  .button, .chip, .icon-button, nav.primary a, .copy { transition: background-color 0.12s, border-color 0.12s, color 0.12s; }
}
@media print {
  header.site, footer.site nav, .subnav, .sidebar, .toc, .copy, .pager { display: none !important; }
}
