/* Copyright (c) 2026 Caret Labs. All rights reserved. */

@font-face {
  font-family: "Outfit";
  src: url("fonts/Outfit-Variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "DM Mono";
  src: url("fonts/DMMono-Light.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "DM Mono";
  src: url("fonts/DMMono-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "DM Mono";
  src: url("fonts/DMMono-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

/* Tokens. Each colour is defined once, for both schemes, with light-dark():
   `color-scheme` picks the side, the system by default and a visitor's choice
   through data-theme. Text tokens (ink*) and surface tokens (bg*, surface) are
   paired by check-contrast.py; the brand gold is for rules, marks and fills
   only, and gold-ink is the gold that may carry text. */
:root {
  color-scheme: light dark;
  --bg: light-dark(#ffffff, #0e0e0d);
  --bg-alt: light-dark(#f7f7f6, #161615);
  --surface: light-dark(#ffffff, #1c1c1a);
  --ink: light-dark(#0a0a0a, #f1f0eb);
  --ink-2: light-dark(#474744, #c9c7c0);
  --ink-3: light-dark(#5f5e5a, #a9a69e);
  --gold-ink: light-dark(#7a5d27, #d6b985);
  --rule: light-dark(#e6e5e1, #2e2d2a);
  --rule-strong: light-dark(#c9c7c0, #4a4843);
  --gold: light-dark(#a8874a, #c9a96e);
  --inverse-bg: light-dark(#0a0a0a, #1f1e1b);
  --inverse-ink: #f1f0eb;
  --inverse-ink-2: #c4c1b9;
  --inverse-gold-ink: #d6b985;
  --focus: light-dark(#0a0a0a, #f1f0eb);
  --s1: 4px; --s2: 8px; --s3: 16px; --s4: 24px; --s5: 32px; --s6: 48px; --s7: 64px;
  --font-display: "Outfit", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "DM Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --max: 1200px;
  --measure: 44rem;
  --header-h: 64px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --t: 0.3s var(--ease);
}
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  font-size: 16px;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 56px);
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body {
  font-family: var(--font-display);
  font-weight: 300;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  overflow-x: hidden;
}
::selection { background: var(--gold); color: #0a0a0a; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--gold-ink); }
img, svg { max-width: 100%; }
img { display: block; height: auto; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3, h4 { font-weight: 200; line-height: 1.15; letter-spacing: -0.03em; color: var(--ink); }
h1 { font-size: clamp(2.3rem, 5.5vw, 4.4rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 3rem); }
h3 { font-size: clamp(1.25rem, 2.2vw, 1.6rem); font-weight: 300; }
h4 { font-size: 1.05rem; font-weight: 400; letter-spacing: -0.01em; }
p, li, dd { color: var(--ink-2); }
strong { font-weight: 500; color: var(--ink); }
code, kbd, samp, pre { font-family: var(--font-mono); font-size: 0.86em; }
code { background: var(--bg-alt); padding: 0.05em 0.35em; border-radius: 2px; color: var(--ink); }
pre {
  background: var(--bg-alt);
  border-left: 3px solid var(--gold);
  padding: 1.1rem 1.4rem;
  overflow-x: auto;
  line-height: 1.6;
  color: var(--ink);
}
pre code { background: none; padding: 0; }
hr { border: 0; height: 1px; background: var(--rule); margin: 2.5rem 0; }

[hidden] { display: none !important; }
.container { max-width: var(--max); margin: 0 auto; padding: 0 clamp(var(--s3), 4.5vw, var(--s7)); }
.skip {
  position: absolute; left: 16px; top: -48px; z-index: 2000;
  background: var(--inverse-bg); color: var(--inverse-ink); padding: var(--s2) var(--s3);
}
.skip:focus { top: 12px; }

/* The brand pipe is drawn, not typed: a rectangle the same everywhere, with
   the "|" kept in the DOM (transparent) so copying still yields the mark. */
.wm { white-space: nowrap; }
.pipe {
  position: relative; display: inline-block; width: max(1px, 0.05em); height: 1.22em;
  margin: 0 0.07em; overflow: hidden; color: transparent; vertical-align: -0.24em;
}
.pipe::after { content: ""; position: absolute; inset: 0; background: var(--gold); }

.eyebrow {
  display: inline-flex; align-items: center; gap: var(--s2);
  font-family: var(--font-mono); font-size: 0.72rem; font-weight: 400;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3);
}
.eyebrow::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); }
.lede { font-size: clamp(1.05rem, 1.6vw, 1.22rem); line-height: 1.8; color: var(--ink-2); max-width: 42rem; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 1000;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--rule);
}
.bar { display: flex; align-items: center; gap: var(--s5); height: var(--header-h); }
.brand { font-weight: 200; font-size: 1.2rem; letter-spacing: 0.05em; color: var(--ink); }
.nav-primary { margin-left: auto; }
.header-links { display: flex; align-items: center; gap: var(--s4); list-style: none; }
.header-links a { font-size: 0.82rem; color: var(--ink-2); }
.header-links a:hover { color: var(--ink); }

/* Footer */
.site-footer { border-top: 1px solid var(--rule); background: var(--bg-alt); padding: var(--s7) 0 var(--s5); margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: var(--s6); margin-bottom: var(--s6); }
.footer-brand p { font-size: 0.86rem; color: var(--ink-3); max-width: 19rem; margin-top: var(--s2); }
.footer-title { font-family: var(--font-mono); font-size: 0.68rem; font-weight: 400; letter-spacing: 0.14em; color: var(--ink-3); margin-bottom: var(--s3); }
.site-footer ul { list-style: none; display: grid; gap: 9px; }
.site-footer li { color: var(--ink-2); }
.site-footer a { font-size: 0.86rem; color: var(--ink-2); }
/* The footer sets the pipe as the font's own glyph; the drawn bar is for the header, the hero and the comparison column. */
.site-footer .pipe { position: static; display: inline; width: auto; height: auto; margin: 0; overflow: visible; color: var(--gold-ink); vertical-align: baseline; }
.site-footer .pipe::after { content: none; }
.site-footer a:hover { color: var(--ink); }
.footer-bottom { display: flex; flex-wrap: wrap; gap: var(--s3) var(--s5); align-items: center; justify-content: space-between; border-top: 1px solid var(--rule); padding-top: var(--s4); }
.footer-bottom p { font-family: var(--font-mono); font-size: 0.7rem; color: var(--ink-3); }
.theme-switch { display: inline-flex; gap: var(--s1); border: 1px solid var(--rule-strong); border-radius: 999px; padding: 2px; }
.theme-switch button { font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.08em; text-transform: uppercase; padding: var(--s1) var(--s2); border-radius: 999px; color: var(--ink-2); }
.theme-switch button[aria-pressed="true"] { background: var(--inverse-bg); color: var(--inverse-ink); }
/* Page structure */
.page-hero { padding: clamp(var(--s7), 9vw, 120px) 0 clamp(var(--s6), 6vw, 72px); position: relative; overflow: hidden; }
.page-hero h1 { margin: var(--s3) 0 var(--s4); max-width: 16ch; }
.page-hero .lede + .lede { margin-top: var(--s3); }
.hero-actions { display: flex; gap: var(--s4); flex-wrap: wrap; margin-top: 34px; align-items: center; }
.hero-rings::before, .hero-rings::after {
  content: ""; position: absolute; top: 50%; border-radius: 50%; pointer-events: none; transform: translateY(-50%);
}
.hero-rings::before { width: 560px; height: 560px; right: -300px; border: 1px solid var(--rule); }
.hero-rings::after { width: 380px; height: 380px; right: -210px; border: 1px solid var(--gold); opacity: 0.35; }
.hero-rings > .container { position: relative; z-index: 1; }
h1.hero-mark { font-size: clamp(3.6rem, 12vw, 8.5rem); font-weight: 200; line-height: 1; letter-spacing: -0.03em; margin: var(--s4) 0 var(--s4); }
.status {
  display: inline-block; font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.09em; text-transform: uppercase;
  padding: var(--s1) var(--s3); border: 1px solid var(--gold); color: var(--gold-ink); line-height: 1.5;
}
.hero-note { margin-top: var(--s3); max-width: 34rem; font-size: 0.95rem; color: var(--ink-3); }

.band { padding: clamp(var(--s6), 7vw, 96px) 0; }
.band-alt { background: var(--bg-alt); }
.section-head { max-width: 46rem; margin-bottom: clamp(var(--s5), 4vw, var(--s6)); }
.section-head h2 { margin: var(--s3) 0 var(--s3); }
.section-head p { font-size: 1.04rem; line-height: 1.8; }
.btn {
  display: inline-flex; align-items: center; gap: var(--s2); font-family: var(--font-mono); font-size: 0.78rem;
  letter-spacing: 0.08em; text-transform: uppercase; padding: 13px var(--s4); border: 1px solid var(--ink);
  background: var(--ink); color: var(--bg); transition: background var(--t), color var(--t), border-color var(--t);
}
.btn:hover { background: transparent; color: var(--ink); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--rule-strong); }
.btn-ghost:hover { border-color: var(--ink); }
.principles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: var(--s6); list-style: none; counter-reset: principle; }
.principles li { counter-increment: principle; }
.principles li::before { content: counter(principle, decimal-leading-zero); display: block; font-family: var(--font-mono); font-size: 0.8rem; color: var(--gold-ink); margin-bottom: var(--s3); letter-spacing: 0.1em; }
.principles p { font-size: 0.95rem; line-height: 1.8; }
.rows { list-style: none; border-top: 1px solid var(--rule); }
.rows > li { display: grid; grid-template-columns: 220px 1fr; gap: var(--s5); padding: var(--s4) 0; border-bottom: 1px solid var(--rule); }
.rows .row-label { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold-ink); padding-top: 3px; }
.note { border-left: 3px solid var(--gold); background: var(--bg-alt); padding: var(--s3) var(--s4); margin-bottom: var(--s4); font-size: 0.92rem; max-width: var(--measure); }
.prose { max-width: var(--measure); padding-bottom: var(--s7); }
.prose > * + * { margin-top: 1.15rem; }
.prose h2 { font-size: clamp(1.4rem, 2.6vw, 1.85rem); margin-top: 2.8rem; }
.prose h3 { font-size: clamp(1.12rem, 1.8vw, 1.32rem); margin-top: 2rem; }
.prose p, .prose li { font-size: 0.99rem; line-height: 1.85; }
.prose p code, .prose li code, .note code { overflow-wrap: anywhere; }
.prose ul, .prose ol { padding-left: 1.25rem; }
.prose li + li { margin-top: 0.4rem; }
.prose li::marker { color: var(--gold-ink); }
.prose blockquote { border-left: 2px solid var(--gold); padding: var(--s2) 0 var(--s2) var(--s4); }
.prose blockquote p { color: var(--ink); font-size: 1.06rem; }
.prose a, .text-link { color: var(--ink); box-shadow: inset 0 -1px 0 var(--gold); }
.prose a:hover, .text-link:hover { color: var(--gold-ink); }

@media (max-width: 960px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .rows > li { grid-template-columns: 1fr; gap: var(--s2); }
  .hero-rings::before, .hero-rings::after { display: none; }
}
@media (max-width: 640px) {
  .footer-grid { grid-template-columns: 1fr; }
  .rows > li { padding: var(--s4) 0; }
  .header-links { gap: var(--s3); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

@media print {
  .site-header, .site-footer, .skip { display: none; }
  body { color: #000000; background: #ffffff; }
}

.highlights { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: var(--s5) var(--s6); list-style: none; padding: 0; margin: 0; }
.highlights li { border-top: 1px solid var(--gold-ink); padding-top: var(--s3); }
.highlights li p { margin: 0; }

.brand-lockup { font-family: var(--font-display); font-weight: 200; font-size: clamp(1.4rem, 2.4vw, 2rem); letter-spacing: -0.02em; color: var(--gold-ink); margin: 0 0 var(--s3); }
.hero-title { font-size: clamp(2rem, 4.4vw, 3.6rem); max-width: 24ch; text-wrap: balance; margin: 0 0 var(--s4); }
.highlights li h3 { font-size: 1.05rem; font-weight: 400; letter-spacing: -0.01em; margin: 0 0 var(--s2); color: var(--ink); }

.footer-company { color: var(--ink-3); font-size: 0.92rem; max-width: 34ch; margin: 0 0 var(--s3); }

.highlights li.span { grid-column: 1 / -1; border-top: 2px solid var(--gold-ink); }
.highlights li.span h3 { font-size: 1.3rem; font-weight: 300; }

.cmp-wrap { overflow-x: auto; border: 1px solid var(--line, rgba(0,0,0,.12)); border-radius: 6px; }
.cmp { border-collapse: collapse; width: 100%; font-size: 0.95rem; table-layout: auto; }
.cmp th, .cmp td { padding: var(--s3) var(--s3); border-bottom: 1px solid var(--line, rgba(0,0,0,.12)); text-align: left; vertical-align: middle; }
.cmp thead th { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3); }
.cmp thead th:first-child + th { color: var(--gold-ink); }
.cmp tbody th { font-weight: 400; color: var(--ink); }
.cmp td span { font-family: var(--font-mono); font-size: 0.8rem; letter-spacing: 0.06em; }
.cmp tr:last-child th, .cmp tr:last-child td { border-bottom: 0; }
.cmp-note { color: var(--ink-3); font-size: 0.9rem; max-width: 72ch; margin-top: var(--s4); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.mark { display: inline-block; }
.mark::before { font-family: var(--font-mono); font-size: 1.05rem; line-height: 1; }
.mark-yes::before { content: "\25CF"; color: var(--ok-ink, #2f6f4f); }
.mark-partial::before { content: "\25D0"; color: var(--gold-ink); }
.mark-quarter::before { content: "\25D4"; color: var(--gold-ink); }
.mark-no::before { content: "\25CB"; color: var(--ink-3); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.cmp-prop { display: block; font-weight: 400; color: var(--ink); }
.cmp-desc { display: block; font-size: 0.82rem; color: var(--ink-3); margin-top: var(--s1); max-width: 34ch; line-height: 1.45; }
.cmp { width: 100%; min-width: 0; }
.cmp-row summary { cursor: pointer; list-style: none; font-weight: 400; color: var(--ink); display: flex; align-items: baseline; gap: var(--s2); }
.cmp-row summary::-webkit-details-marker { display: none; }
.cmp-row summary::before { content: "+"; font-family: var(--font-mono); color: var(--gold-ink); width: 1ch; flex: none; }
.cmp-row[open] summary::before { content: "\2013"; }
.cmp-row .cmp-desc { margin-left: calc(1ch + var(--s2)); }
.cmp-toolbar { display: flex; justify-content: flex-end; align-items: center; gap: var(--s3); margin-bottom: var(--s3); flex-wrap: wrap; }
.cmp-legend { font-family: var(--font-mono); font-size: 0.75rem; color: var(--ink-3); display: flex; gap: var(--s2); align-items: center; flex-wrap: wrap; margin: var(--s3) 0 0; }
.cmp-toggle { font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.06em; background: transparent; color: var(--ink); border: 1px solid var(--line, rgba(0,0,0,.2)); border-radius: 4px; padding: var(--s1) var(--s3); cursor: pointer; }
.cmp-toggle:hover, .cmp-toggle:focus-visible { border-color: var(--gold-ink); outline: none; }
.cmp td { width: 1%; white-space: nowrap; text-align: center; }
.cmp thead th:not(:first-child) { text-align: center; white-space: nowrap; }
.cmp tbody th { min-width: 12rem; }
.cmp-row summary { white-space: normal; }
.cmp-detail { display: none; }
.cmp tr:has(details.cmp-row[open]) + .cmp-detail { display: table-row; }
.cmp tr:has(details.cmp-row[open]) th, .cmp tr:has(details.cmp-row[open]) td { border-bottom: 0; }
.cmp .cmp-detail td { width: auto; white-space: normal; text-align: left; padding-top: 0; }
.cmp-text { margin: 0 0 0 calc(1ch + var(--s2)); max-width: 44rem; }
.cmp-text p { margin: 0 0 var(--s2); font-size: 0.86rem; color: var(--ink-2); line-height: 1.5; white-space: normal; }
.cmp-text p:last-child { margin-bottom: 0; }
.cmp-text strong { font-weight: 500; color: var(--ink); }
