/* Tokens. Family colors were checked with the dataviz palette validator against each surface. */
:root {
  color-scheme: light;
  --bg: #fbfaf7;
  --fg: #1b1a17;
  --fg2: #5d594f;
  --fg3: #77736a;
  --line: #e5e1d8;
  --track: #efece5;
  --tip-bg: #ffffff;
  --tip-shadow: 0 1px 2px rgba(27, 26, 23, .06), 0 8px 24px rgba(27, 26, 23, .12);
  --stripe: rgba(255, 255, 255, .6);
  --f-gpt: #00a07f; --f-claude: #e2621f; --f-gemini: #2f74d0; --f-open: #d18f00; --f-other: #b8507a;
  --serif: "Iowan Old Style", "Charter", "Bitstream Charter", "Sitka Text", Cambria, Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --z-tip: 300;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #141412; --fg: #ecebe6; --fg2: #a7a399; --fg3: #8b877d; --line: #2d2b27; --track: #23221f;
    --tip-bg: #22211e; --tip-shadow: 0 8px 24px rgba(0, 0, 0, .5); --stripe: rgba(20, 20, 18, .55);
    --f-gpt: #1fb894; --f-claude: #ee7536; --f-gemini: #4b93ee; --f-open: #c98c12; --f-other: #d57099;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #141412; --fg: #ecebe6; --fg2: #a7a399; --fg3: #8b877d; --line: #2d2b27; --track: #23221f;
  --tip-bg: #22211e; --tip-shadow: 0 8px 24px rgba(0, 0, 0, .5); --stripe: rgba(20, 20, 18, .55);
  --f-gpt: #1fb894; --f-claude: #ee7536; --f-gemini: #4b93ee; --f-open: #c98c12; --f-other: #d57099;
}

.f-gpt { --c: var(--f-gpt); } .f-claude { --c: var(--f-claude); } .f-gemini { --c: var(--f-gemini); }
.f-open { --c: var(--f-open); } .f-other { --c: var(--f-other); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font: 400 16px/1.55 var(--sans);
  font-variant-numeric: tabular-nums; font-synthesis: none;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
a { color: inherit; text-decoration-thickness: from-font; text-underline-offset: .18em; }
a:hover { color: var(--fg2); }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; border-radius: 4px; }
ul { list-style: none; margin: 0; padding: 0; }

.page { max-width: 760px; margin: 0 auto; padding: 20px 20px 56px; }
@media (max-width: 480px) { .page { padding: 12px 16px 40px; } }

.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }
.site { font-size: 13px; color: var(--fg3); letter-spacing: .01em; }
.theme {
  display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px 0 10px;
  border: 1px solid var(--line); border-radius: 999px; background: transparent; color: var(--fg2);
  font: 500 13px/1 var(--sans); cursor: pointer; position: relative;
  transition-property: color, border-color, transform; transition-duration: 150ms; transition-timing-function: ease-out;
}
.theme::before { content: ""; position: absolute; inset: -4px; }
.theme:hover { color: var(--fg); border-color: var(--fg3); }
.theme:active { transform: scale(.96); }
.theme svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.theme .i-moon { display: none; }
:root[data-theme="dark"] .theme .i-sun { display: none; }
:root[data-theme="dark"] .theme .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) .theme .i-sun { display: none; }
  :root:not([data-theme]) .theme .i-moon { display: block; }
}

/* Hero */
.hero { padding: 40px 0 8px; }
.kicker { margin: 0 0 10px; font-size: 14px; color: var(--fg2); }
h1 {
  font-family: var(--serif); font-weight: 600; font-size: clamp(34px, 7.4vw, 54px); line-height: 1.06;
  letter-spacing: -.018em; margin: 0; text-wrap: balance;
}
.stats { display: grid; grid-template-columns: auto auto 1fr; gap: 16px 40px; margin: 32px 0 0; align-items: end; }
.stat dt { font-size: 13px; color: var(--fg2); margin-bottom: 2px; }
.stat dd { margin: 0; font-size: clamp(30px, 6.4vw, 44px); font-weight: 650; line-height: 1.05; letter-spacing: -.02em; }
.approx { color: var(--fg3); font-weight: 500; font-size: .8em; margin-right: .02em; }
.stat-split dd { font-size: 17px; font-weight: 500; letter-spacing: 0; line-height: 1.35; display: flex; flex-wrap: wrap; gap: 2px 16px; padding-bottom: 4px; }
.mach-k { color: var(--fg2); font-weight: 400; }
@media (max-width: 520px) {
  .stats { grid-template-columns: 1fr 1fr; gap: 20px 16px; }
  .stat-split { grid-column: 1 / -1; }
}

/* Sections */
section { margin-top: 56px; }
.hero { margin-top: 0; }
h2 { font-size: 20px; font-weight: 650; letter-spacing: -.01em; line-height: 1.25; margin: 0 0 6px; text-wrap: balance; }
h3 { font-size: 15px; font-weight: 600; margin: 0 0 4px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.h-aside { font-size: 13px; font-weight: 400; color: var(--fg2); }
.lede { margin: 0 0 18px; color: var(--fg2); font-size: 15px; line-height: 1.5; max-width: 62ch; text-wrap: pretty; }

.sw { width: 10px; height: 10px; border-radius: 50%; background: var(--c); flex: none; display: inline-block; }

/* Family share */
.share { display: flex; gap: 2px; height: 10px; margin: 0 0 16px; }
.share .seg { flex-basis: 0; min-width: 4px; background: var(--c); border-radius: 2px; }
.share .seg:first-child { border-radius: 5px 2px 2px 5px; }
.share .seg:last-child { border-radius: 2px 5px 5px 2px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(136px, 1fr)); gap: 0; border-top: 1px solid var(--line); }
.tile { padding: 14px 16px 14px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.tile-lab { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; }
.tile-big { font-size: 26px; font-weight: 650; letter-spacing: -.015em; line-height: 1.2; margin-top: 6px; }
.tile-unit { font-size: 13px; font-weight: 400; color: var(--fg2); letter-spacing: 0; }
.tile-sub { display: flex; flex-direction: column; font-size: 13px; color: var(--fg2); line-height: 1.45; }
.tile-note { margin: 6px 0 0; font-size: 12.5px; color: var(--fg3); line-height: 1.4; text-wrap: pretty; }
@media (max-width: 480px) {
  .tiles { grid-template-columns: 1fr 1fr; }
  .tile { padding-right: 12px; }
}

/* Legend */
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; color: var(--fg2); margin: 0 0 14px; }
.legend li { display: inline-flex; align-items: center; gap: 6px; }

/* Weekly dots */
.chart { margin: 0; position: relative; }
.chart-lab { font-size: 13px; font-weight: 600; color: var(--fg); margin: 0 0 4px; }
.chart-lab span { color: var(--fg3); font-weight: 400; }
.chart-lab:last-of-type { margin: 4px 0 0; }
.chart-plot { position: relative; outline: none; }
.dots { display: block; width: 100%; height: auto; overflow: visible; }
.dots circle { fill: var(--c); }
.hit { fill: transparent; cursor: default; outline: none; }
.hit:hover, .hit.on { fill: var(--fg); fill-opacity: .06; }
.hit:focus-visible { fill: var(--fg); fill-opacity: .08; stroke: var(--fg); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.axis { position: relative; height: 26px; border-top: 1px solid var(--fg3); }
.axis .mon { position: absolute; top: 5px; font-size: 12px; color: var(--fg2); padding-left: 2px; line-height: 1; white-space: nowrap; }
.axis .mon::before { content: ""; position: absolute; left: 0; top: -5px; height: 4px; border-left: 1px solid var(--fg3); }

/* Table view */
details > summary { cursor: pointer; color: var(--fg2); font-size: 14px; padding: 10px 0; min-height: 44px; display: flex; align-items: center; gap: 8px; list-style: none; width: fit-content; }
details > summary::-webkit-details-marker { display: none; }
details > summary::before { content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); transition: transform 150ms ease-out; margin-right: 2px; }
details[open] > summary::before { transform: rotate(45deg); }
details > summary:hover { color: var(--fg); }
.table-view { margin-top: 12px; }
.table-scroll { overflow-x: auto; max-width: 100%; }
table { border-collapse: collapse; font-size: 13px; min-width: 100%; }
th, td { padding: 5px 10px 5px 0; text-align: end; white-space: nowrap; border-bottom: 1px solid var(--line); }
th[scope="row"], thead th:first-child { text-align: start; font-weight: 500; }
thead th { color: var(--fg2); font-weight: 500; }

/* Models */
.pinned { margin: 8px 0 28px; padding: 14px 16px 2px; border: 1px solid var(--line); border-radius: 10px; }
.pinned .models .model:last-child { border-bottom: 0; }
.h-all { margin-bottom: 4px; }
.models { border-top: 1px solid var(--line); }
.pinned .models { border-top: 0; }
.model { padding: 12px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.m-head { display: flex; align-items: baseline; gap: 8px; }
.m-head .sw { transform: translateY(-1px); }
.m-name { font-weight: 600; font-size: 15.5px; min-width: 0; flex: 1 1 auto; overflow-wrap: anywhere; }
.m-n { font-size: 15px; font-weight: 600; white-space: nowrap; }
.m-unit { color: var(--fg2); font-weight: 400; font-size: 13px; }
.m-bar { display: flex; gap: 2px; height: 8px; margin: 8px 0 6px; }
.m-bar .b { height: 100%; min-width: 3px; background: var(--c); border-radius: 2px; }
.m-bar .b.pc { background-image: repeating-linear-gradient(135deg, transparent 0 2.5px, var(--stripe) 2.5px 4.5px); }
.m-meta { display: flex; flex-wrap: wrap; gap: 0 14px; font-size: 13px; color: var(--fg2); line-height: 1.5; }
.more > summary { margin-top: 4px; }

/* Tools */
.tools { border-top: 1px solid var(--line); }
.tool { display: grid; grid-template-columns: 7.5em 1fr auto; align-items: center; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.t-name { font-weight: 600; font-size: 15px; overflow-wrap: anywhere; }
.t-bar { height: 8px; background: var(--track); border-radius: 2px; overflow: hidden; display: block; }
.t-bar > span { display: block; height: 100%; min-width: 2px; background: var(--fg2); border-radius: 2px; }
.t-n { font-weight: 600; font-size: 15px; text-align: end; display: flex; gap: 10px; align-items: baseline; justify-content: flex-end; min-width: 6.5em; }
.t-p { font-weight: 400; color: var(--fg2); font-size: 13px; min-width: 2.8em; text-align: end; }
@media (max-width: 480px) { .tool { grid-template-columns: 6.2em 1fr auto; gap: 10px; } .t-n { min-width: 5.6em; } }

/* Method */
.method { margin-top: 64px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--fg2); font-size: 14px; line-height: 1.55; }
.method h2 { font-size: 15px; color: var(--fg); }
.method ul { display: grid; gap: 6px; max-width: 64ch; }
.method li { padding-left: 14px; position: relative; text-wrap: pretty; }
.method li::before { content: ""; position: absolute; left: 0; top: .62em; width: 5px; height: 5px; border-radius: 50%; background: var(--fg3); }
.raw { margin: 16px 0 0; }

/* Tooltip */
.tip {
  position: fixed; left: 0; top: 0; z-index: var(--z-tip); pointer-events: none;
  min-width: 180px; max-width: min(260px, calc(100vw - 16px));
  background: var(--tip-bg); color: var(--fg); border: 1px solid var(--line); border-radius: 8px;
  box-shadow: var(--tip-shadow); padding: 9px 11px; font-size: 13px; line-height: 1.45;
}
.tip[hidden] { display: none; }
.tip .t { font-weight: 600; margin-bottom: 4px; }
.tip .r { display: flex; align-items: center; gap: 7px; }
.tip .r b { margin-left: auto; padding-left: 14px; font-weight: 600; }
.tip .tot { color: var(--fg2); border-top: 1px solid var(--line); margin-top: 5px; padding-top: 4px; }
.tip .tot b { color: var(--fg); }

/* Entrance: one quiet fade for the hero, once. Disabled for reduced motion. */
@media (prefers-reduced-motion: no-preference) {
  .hero, .hero + section { animation: rise 420ms cubic-bezier(.2, .7, .2, 1) both; }
  .hero + section { animation-delay: 60ms; }
  @keyframes rise { from { opacity: 0; transform: translateY(6px); } }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0ms !important; animation: none !important; }
}
@media (forced-colors: active) {
  .dots circle, .sw, .share .seg, .m-bar .b, .t-bar > span { forced-color-adjust: none; }
}
