@font-face {
  font-family: "Geist Serif";
  src: url("fonts/GeistSerifVF.woff2") format("woff2");
  font-weight: 400; /* the only weight the geist package declares for this file */
  font-style: normal;
  font-display: swap;
}
:root {
  color-scheme: light dark;
  --bg: #fff;
  --fg: #0f0f0f;
  --muted: #666970;
  --card: #f3f3f3;
  --border: #e4e4e4;
  --nav-bg: rgb(255 255 255 / 0.88);
  --nav-border: rgb(0 0 0 / 0.08);
  --button-bg: #0f0f0f;
  --button-fg: #fff;
  --bar: #7d7d83;
  --bar-eblan: #d1241a;
  --ink: #08080b; /* the always-dark hero and footer */
  --ink-fg: #fff;
  --ink-muted: #a9abb2;
  --ink-border: rgb(255 255 255 / 0.14);
  --bubble: #26262b;
  --bubble-eblan: #d1241a;
  --radius: 18px;
  --width: 68rem;
  --gutter: max(1.25rem, env(safe-area-inset-left), env(safe-area-inset-right));
  --font-display: "Geist Serif", "Times New Roman", Times, serif;
  --ease-out: cubic-bezier(0.2, 0, 0, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c0a09;
    --fg: #fafaf9;
    --muted: #a6a09b;
    --card: #1c1917;
    --border: rgb(255 255 255 / 0.1);
    --nav-bg: rgb(28 25 23 / 0.82);
    --nav-border: rgb(255 255 255 / 0.12);
    --button-bg: #fafaf9;
    --button-fg: #0c0a09;
    --bar: #8f8a85;
    --bar-eblan: #ef4438;
  }
}
@media (prefers-contrast: more) {
  :root { --muted: #4a4c52; --border: #8a8a8a; --nav-bg: var(--bg); --nav-border: var(--fg); --ink-muted: #d4d5d9; --bubble-eblan: #b01c13; }
}
@media (prefers-contrast: more) and (prefers-color-scheme: dark) {
  :root { --muted: #d6d3d1; --border: rgb(255 255 255 / 0.45); }
}
@media (prefers-reduced-transparency: reduce) {
  :root { --nav-bg: var(--bg); }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-block-start: 5.5rem; }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif; line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p, figure { margin: 0; }
h1, h2 { overflow-wrap: anywhere; }
a { color: inherit; text-underline-offset: 0.2em; -webkit-tap-highlight-color: transparent; }
:focus-visible:not(#chat-root *, [data-gate] *, [data-slot], [data-slot] *) { outline: 3px solid color-mix(in srgb, currentColor 55%, transparent); outline-offset: 2px; border-radius: 4px; }
.wrap { max-width: calc(var(--width) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}
.skip-link {
  display: flex; align-items: center; min-height: 2.75rem; position: absolute; inset-inline-start: 1rem; inset-block-start: -6rem; z-index: 20;
  padding: 0.5rem 1rem; border-radius: 0.5rem; background: var(--bg); color: var(--fg);
}
.skip-link:focus { inset-block-start: 0.5rem; }
.display { font-family: var(--font-display); font-weight: 400; }

/* ---- Floating navigation ---- */
.nav {
  position: fixed; z-index: 10; inset-inline: 0; inset-block-start: max(0.75rem, env(safe-area-inset-top));
  padding-inline: var(--gutter); pointer-events: none;
}
.nav-inner {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem 1.5rem;
  max-width: 52rem; margin-inline: auto; padding: 0.375rem 0.5rem 0.375rem 0.625rem; pointer-events: auto;
  border: 1px solid var(--nav-border); border-radius: 1.75rem; background: var(--nav-bg);
  -webkit-backdrop-filter: blur(16px) saturate(180%); backdrop-filter: blur(16px) saturate(180%);
  box-shadow: 0 8px 30px rgb(0 0 0 / 0.18), 0 1px 3px rgb(0 0 0 / 0.1);
}
.logo { display: inline-flex; align-items: center; gap: 0.25rem; font-weight: 600; text-decoration: none; }
.logo img { display: block; width: 2.25rem; height: 2.25rem; }
@media (prefers-color-scheme: dark) { .nav .logo img { filter: invert(1); } }
.nav-links { display: flex; gap: 1.5rem; margin-inline: auto; font-size: 0.875rem; font-weight: 500; }
.nav-links a { text-decoration: none; padding-block: 0.5rem; }
@media (hover: hover) { .nav-links a:hover { color: var(--muted); } }
@media (max-width: 44rem) {
  .nav-links { display: none; }
  .nav-inner { column-gap: 0.5rem; }
  .nav-inner .pill { margin-inline-start: auto; }
}

/* ---- Buttons ---- */
.pill {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 2.5rem; padding: 0.25rem 1.125rem; border-radius: 999px; text-align: center;
  position: relative; isolation: isolate; border: 0; background: none; color: var(--button-fg);
  font-size: 0.875rem; font-weight: 600; letter-spacing: -0.01em; text-decoration: none;
  will-change: transform; /* stays on its own layer, so browsers render the text the same before, during and after animations */
}
/* Only the capsule behind the label moves. Scaling the button itself makes browsers re-render the text, which visibly changes its weight. */
.pill::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background: var(--pill-bg, var(--button-bg)); box-shadow: var(--pill-shadow, none);
  transition: transform 280ms var(--ease-spring), box-shadow 280ms var(--ease-out);
}
@media (prefers-reduced-motion: no-preference) {
  .pill:active::before { transform: scale(0.95); transition-duration: 90ms; }
  @media (hover: hover) { .pill:hover:not(:active)::before { transform: scale(1.04); } }
}
@media (pointer: coarse) { .pill { min-height: 2.75rem; } }
/* The hero's main action: big, soft and inviting. */
.pill-light {
  gap: 0.625rem; min-height: 3.5rem; padding: 0.5rem 1.75rem 0.5rem 1.375rem;
  --pill-bg: #fff; --pill-shadow: 0 10px 30px rgb(0 0 0 / 0.35), 0 2px 6px rgb(0 0 0 / 0.2);
  color: #0f0f0f; font-size: 1.0625rem;
}
@media (hover: hover) { .pill-light:hover { --pill-shadow: 0 16px 44px rgb(0 0 0 / 0.45), 0 3px 8px rgb(0 0 0 / 0.25); } }
.pill-icon {
  width: 1.5rem; height: 1.5rem; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round;
}

/* ---- Hero ---- */
.hero { position: relative; overflow: hidden; background: var(--ink); color: var(--ink-fg); isolation: isolate; }
.hero-art { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 80% bottom; }
.hero::after { /* keeps the copy readable over the screenshot */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    /* Dissolves the screenshot into the page below instead of ending on a hard edge. */
    linear-gradient(to top, var(--bg), color-mix(in srgb, var(--bg) 72%, transparent) 3.5rem, color-mix(in srgb, var(--bg) 28%, transparent) 7rem, transparent 10.5rem),
    linear-gradient(to right, rgb(8 8 11 / 0.9), rgb(8 8 11 / 0.74) 45%, rgb(8 8 11 / 0.12) 62%),
    linear-gradient(to bottom, rgb(8 8 11 / 0.45), transparent 18%);
}
.hero-inner {
  display: grid; gap: 3rem 4rem; align-items: center;
  min-height: min(50rem, 100dvh); padding-block: 7.5rem 10.5rem;
}
.hero-inner > * { min-width: 0; }
@media (min-width: 58rem) { .hero-inner { grid-template-columns: 1.1fr 1fr; } }
/* Bubbles sit high so the gun in the screenshot stays visible beneath them. */
@media (min-width: 58rem) { .exchanges { align-self: start; } }
@media (max-width: calc(58rem - 1px)) {
  /* Phones: the screenshot fills the first screen behind the title, with room left for the gun, and the chats follow. */
  .hero-inner { padding-block-start: 0; }
  .hero-inner > :first-child {
    position: relative; min-height: 100vh; min-height: 100svh; padding-block: 7.5rem 15rem;
  }
  .hero-art { inset: 0 calc(-1 * var(--gutter)); width: calc(100% + 2 * var(--gutter)); }
  .hero::after { content: none; }
  .hero-inner > :first-child::after {
    content: ""; position: absolute; z-index: -1; inset: 0 calc(-1 * var(--gutter));
    /* Dark only as far down as the text reaches, so the gun below it stays bright on tall screens. */
    background: linear-gradient(to top, var(--ink), transparent 3rem, transparent calc(max(15rem, 100% - 36rem) - 9rem), rgb(8 8 11 / 0.8) max(15rem, 100% - 36rem), rgb(8 8 11 / 0.84));
  }
  /* The chats get their own view of the screenshot, so the blurred bubbles have something to blur. */
  .hero-inner { gap: 0; padding-block-end: 0; }
  .exchanges {
    margin-inline: calc(-1 * var(--gutter)); padding: 3.5rem var(--gutter) 8rem;
    background:
      linear-gradient(to top, var(--bg), color-mix(in srgb, var(--bg) 72%, transparent) 3rem, color-mix(in srgb, var(--bg) 28%, transparent) 5.5rem, transparent 8rem),
      linear-gradient(to bottom, var(--ink), rgb(8 8 11 / 0.2) 22%),
      url("images/hero-cs2.jpg") 62% center / cover;
  }
  .exchanges .bubble { font-size: 1rem; }
}
.hero h1 { font-size: clamp(3rem, 8.5vw, 5.75rem); line-height: 1.02; letter-spacing: -0.025em; text-wrap: balance; }
.hero-lede { margin-block: 1.5rem 2rem; max-width: 32rem; font-size: clamp(1.125rem, 2.2vw, 1.3125rem); line-height: 1.45; color: #e4e4e7; }
.hero-warning { margin-block-start: 1.5rem; max-width: 32rem; font-size: 0.8125rem; color: var(--ink-muted); }
.hero-warning strong { color: var(--ink-fg); font-weight: 600; }
.credit {
  display: inline-flex; align-items: center; gap: 0.5rem; min-height: 2.75rem;
  color: var(--ink-fg); font-size: 0.875rem; font-weight: 500; text-decoration: none;
}
.credit img { width: 1.75rem; height: 1.75rem; flex: none; border-radius: 50%; }
@media (hover: hover) { .credit:hover { text-decoration: underline; } }
.hero .credit { margin-block-start: 0.75rem; }

.exchanges { display: flex; flex-direction: column; gap: 1.5rem; }
.exchange { display: flex; flex-direction: column; gap: 0.375rem; }
.bubble {
  width: fit-content; max-width: 88%; padding: 0.5625rem 0.875rem; border-radius: 1.125rem;
  font-size: 0.9375rem; line-height: 1.35; overflow-wrap: anywhere;
}
.bubble-insult { background: var(--bubble); border-end-start-radius: 0.375rem; }
.bubble-eblan { margin-inline-start: auto; background: var(--bubble-eblan); color: #fff; font-weight: 500; border-end-end-radius: 0.375rem; }
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  /* The dimming inside the filter keeps the white text readable over bright parts of the screenshot. */
  .bubble {
    -webkit-backdrop-filter: blur(14px) saturate(150%) brightness(0.8);
    backdrop-filter: blur(14px) saturate(150%) brightness(0.8);
    box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.14);
  }
  .bubble-insult { background: rgb(20 20 24 / 0.62); }
  .bubble-eblan { background: rgb(150 16 12 / 0.72); }
}
@media (prefers-reduced-transparency: reduce), (prefers-contrast: more) {
  .bubble { -webkit-backdrop-filter: none; backdrop-filter: none; box-shadow: none; }
  .bubble-insult { background: var(--bubble); }
  .bubble-eblan { background: var(--bubble-eblan); }
}

/* ---- Results ---- */
.section { padding-block: clamp(3.5rem, 8vw, 5.5rem); }
.section-head { display: grid; gap: 1rem 3rem; align-items: end; margin-block-end: 2.5rem; }
.section-head > * { min-width: 0; }
@media (min-width: 48rem) { .section-head { grid-template-columns: 1fr 1.1fr; } }
h2:where(:not([data-slot], #chat-root *, [data-gate] *)) {   /* :where keeps it as weak as a plain h2 rule */ font-size: clamp(2.25rem, 6vw, 3.5rem); line-height: 1.08; letter-spacing: -0.02em; }
.section-head p { font-size: 1.0625rem; line-height: 1.5; color: var(--muted); }

.results { width: 100%; border-collapse: collapse; border-radius: var(--radius); background: var(--card); overflow: hidden; }
.results th, .results td { padding: 1rem 1.25rem; text-align: start; border-block-end: 1px solid var(--border); vertical-align: middle; }
.results tr:last-child > * { border-block-end: 0; }
.results thead th { padding-block: 0.875rem; font-size: 0.8125rem; font-weight: 500; color: var(--muted); }
.results tbody th { width: 38%; font-size: 0.9375rem; font-weight: 500; }
.results .is-eblan th { font-size: 1.0625rem; font-weight: 700; }
.score { display: flex; align-items: center; gap: 0.75rem; }
/* Bars start at zero and share one scale: 5 points fills the row. */
.bar {
  flex: 0 1 calc((100% - 3.25rem) * var(--value) / 5); min-width: 2px; height: 0.75rem;
  border-radius: 0 4px 4px 0; background: var(--bar);
}
.bar:dir(rtl) { border-radius: 4px 0 0 4px; }
.is-eblan .bar { height: 1.125rem; background: var(--bar-eblan); }
.value { flex: none; font-size: 0.9375rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.is-eblan .value { font-size: 1.0625rem; font-weight: 700; color: var(--fg); }
.note { margin-block-start: 1rem; max-width: 46rem; font-size: 0.875rem; line-height: 1.5; color: var(--muted); }
.note + .note { margin-block-start: 0.5rem; }
@media (max-width: 40rem) { /* the name stacks above the bar so the bars keep their length */
  .results, .results thead, .results tbody, .results tr, .results th, .results td { display: block; }
  .results caption { display: block; }
  .results thead th:first-child { display: none; }
  .results tbody th { width: auto; padding-block-end: 0.25rem; border-block-end: 0; }
  .results tbody td { padding-block-start: 0; }
  .results th, .results td { padding-inline: 1rem; }
}

/* ---- Footer ---- */
.footer { background: var(--ink); color: var(--ink-fg); padding-block: 4rem max(2.5rem, env(safe-area-inset-bottom)); }
.footer .logo img { filter: invert(1); }
.footer-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.5rem; }
.footer-links { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(9rem, 100%), 1fr)); gap: 2rem; margin-block: 2rem 3rem; font-size: 0.875rem; }
.footer-links h3 { font-size: 0.875rem; font-weight: 600; }
.footer-links ul { margin: 0.75rem 0 0; padding: 0; list-style: none; }
.footer-links li + li { margin-block-start: 0.25rem; }
.footer-links a { display: inline-block; padding-block: 0.125rem; color: var(--ink-muted); text-decoration: none; }
@media (hover: hover) { .footer-links a:hover { color: var(--ink-fg); } }
@media (pointer: coarse) {
  .footer-links a { padding-block: 0.75rem; }
  .nav-links a { padding-block: 0.75rem; }
  .logo { min-height: 2.75rem; }
}
.footer-legal { padding-block-start: 1.5rem; border-block-start: 1px solid var(--ink-border); font-size: 0.8125rem; color: var(--ink-muted); }

@media (forced-colors: active) {
  .pill, .bubble, .results, .nav-inner { border: 1px solid CanvasText; }
  .bar { background: CanvasText; forced-color-adjust: none; }
  .hero-art { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* ---- Legal pages and offline chat: same shell, readable content column ---- */
.document { max-width: calc(48rem + 2 * var(--gutter)); padding-block: 8rem 5rem; line-height: 1.7; }
.document h1 { margin-block-end: 0.75rem; font-size: clamp(2.5rem, 7vw, 4rem); line-height: 1.08; letter-spacing: -0.025em; }
.document h2 { margin-block: 2.5rem 0.75rem; font-size: 1.375rem; line-height: 1.35; letter-spacing: -0.015em; }
.document p { margin-block: 0.875rem; }
.document ul { padding-inline-start: 1.25rem; }
.document li + li { margin-block-start: 0.5rem; }
.document a { overflow-wrap: anywhere; }
.document .meta, .document .muted { color: var(--muted); font-size: 0.875rem; }
.document .notice { margin-block: 2rem; padding: clamp(1rem, 4vw, 1.5rem); background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); }
.document .notice p:first-child { margin-block-start: 0; }
.document .notice p:last-child { margin-block-end: 0; }
.document .eyebrow { margin-block: 0 1rem; font-size: 0.875rem; font-weight: 600; color: var(--bar-eblan); }
.chat-panel { margin-block: 2rem; padding: clamp(1.25rem, 4vw, 2rem); border: 1px solid var(--border); border-radius: var(--radius); }
.document .chat-panel h2 { margin-block-start: 0; }
.composer { display: grid; gap: 0.75rem; margin-block-start: 2rem; }
.composer label { font-weight: 600; }
.composer textarea, .composer button { font: inherit; border: 1px solid var(--border); border-radius: 0.75rem; }
.composer textarea { width: 100%; min-height: 6rem; padding: 0.875rem; background: var(--card); color: var(--muted); resize: vertical; }
.composer button { justify-self: end; padding: 0.625rem 1.5rem; background: var(--card); color: var(--muted); }
.composer :disabled { cursor: not-allowed; opacity: 1; -webkit-text-fill-color: currentColor; }
@media (forced-colors: active) { .notice, .chat-panel, .composer textarea, .composer button { border-color: CanvasText; } }

/* ---- Live chat: the page frame. The UI itself is the React + shadcn/ui app in chat-app/ (chat/app/chat-app.css). ---- */
.chat-page, .chat-page body { height: 100%; overflow: hidden; overscroll-behavior: none; }
.chat-app ~ .footer { display: none; }
.chat-app { position: fixed; inset: 0; background: #0c0a09; }
#chat-root { position: absolute; inset: 0; }
.no-topbar .nav, .ui-hidden .nav { display: none; }
.noscript { position: absolute; inset: 50% 0 auto; text-align: center; color: #fafaf9; }

/* ---- Page-load animations. Fill is "backwards" so hover and pressed states still work afterwards. ---- */
@keyframes art-in { from { opacity: 0; transform: scale(1.06); } }
@keyframes nav-in { from { opacity: 0; transform: translateY(-1rem); } }
@keyframes rise { from { opacity: 0; transform: translateY(1rem); } }
@keyframes headline-in { from { opacity: 0; transform: translateY(1.25rem); filter: blur(10px); } }
@keyframes bubble-in { from { opacity: 0; transform: translateY(0.5rem) scale(0.92); } }
@keyframes bar-grow { from { transform: scaleX(0); } }
@keyframes fade { from { opacity: 0; } }

.hero-art { animation: art-in 1400ms var(--ease-out) backwards; }
.nav-inner { animation: nav-in 500ms var(--ease-out) backwards; }
.hero h1 { animation: headline-in 800ms var(--ease-out) 100ms backwards; }
.hero-lede { animation: rise 600ms var(--ease-out) 300ms backwards; }
.hero .pill-light { animation: rise 600ms var(--ease-out) 420ms backwards; }
.hero-warning { animation: rise 600ms var(--ease-out) 540ms backwards; }
.hero .credit { animation: rise 600ms var(--ease-out) 660ms backwards; }

/* The exchanges arrive one message at a time, like a chat. */
.bubble { animation: bubble-in 350ms var(--ease-out) var(--bubble-delay, 0ms) backwards; }
.bubble-insult { transform-origin: bottom left; }
.bubble-eblan { transform-origin: bottom right; }
.exchange:nth-child(1) .bubble-insult { --bubble-delay: 600ms; }
.exchange:nth-child(1) .bubble-eblan { --bubble-delay: 950ms; }
.exchange:nth-child(2) .bubble-insult { --bubble-delay: 1400ms; }
.exchange:nth-child(2) .bubble-eblan { --bubble-delay: 1750ms; }
.exchange:nth-child(3) .bubble-insult { --bubble-delay: 2200ms; }
.exchange:nth-child(3) .bubble-eblan { --bubble-delay: 2550ms; }

.bar { transform-origin: left; }
.bar:dir(rtl) { transform-origin: right; }

.document > * { animation: rise 500ms var(--ease-out) 300ms backwards; }
.document > :nth-child(1) { animation-delay: 60ms; }
.document > :nth-child(2) { animation-delay: 120ms; }
.document > :nth-child(3) { animation-delay: 180ms; }
.document > :nth-child(4) { animation-delay: 240ms; }

/* Below-the-fold parts play once when they come into view. The script in templates/layout.html adds
   .reveal-ready to <html> (never with reduced motion) and .in-view to each block as it arrives.
   Without the script nothing here applies, so everything is simply visible. */
.reveal-ready .section-head > *,
.reveal-ready .note,
.reveal-ready .results tr,
.reveal-ready .footer .logo,
.reveal-ready .footer .credit,
.reveal-ready .footer-links > nav,
.reveal-ready .footer-legal,
.reveal-ready .document > :nth-child(n+5) {
  animation: rise 650ms var(--ease-out) var(--reveal-delay, 0ms) both;
  animation-play-state: paused;
}
.reveal-ready .bar {
  animation: bar-grow 1000ms var(--ease-out) var(--reveal-delay, 0ms) both;
  animation-play-state: paused;
}
.reveal-ready .in-view > *,
.reveal-ready .in-view tr,
.reveal-ready .in-view .bar,
.reveal-ready .in-view .logo,
.reveal-ready .in-view .credit,
.reveal-ready .in-view .footer-links > nav,
.reveal-ready .in-view .footer-legal,
.reveal-ready .note.in-view,
.reveal-ready .document > .in-view:nth-child(n+5) {
  animation-play-state: running;
}
.section-head > :nth-child(2) { --reveal-delay: 120ms; }
.results tbody tr:nth-child(1) { --reveal-delay: 100ms; }
.results tbody tr:nth-child(2) { --reveal-delay: 180ms; }
.results tbody tr:nth-child(3) { --reveal-delay: 260ms; }
.results tbody tr:nth-child(4) { --reveal-delay: 340ms; }
.results tbody tr:nth-child(5) { --reveal-delay: 420ms; }
.results tbody tr:nth-child(6) { --reveal-delay: 500ms; }
.results tbody tr:nth-child(7) { --reveal-delay: 580ms; }
.results tbody tr .bar { --reveal-delay: 300ms; }
.footer-links > nav:nth-child(1) { --reveal-delay: 100ms; }
.footer-links > nav:nth-child(2) { --reveal-delay: 180ms; }
.footer-links > nav:nth-child(3) { --reveal-delay: 260ms; }
.footer-legal { --reveal-delay: 360ms; }
@media print {
  .reveal-ready * { animation: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-art, .nav-inner, .hero h1, .hero-lede, .hero .pill-light, .hero-warning, .hero .credit, .bubble, .document > * {
    animation: fade 200ms linear backwards;
  }
  .bar { animation: none; }
}

/* ---- Benchmark page ---- */
.bench { padding-block: 8rem 5rem; }
.bench h1 { font-size: clamp(2.5rem, 7vw, 4rem); line-height: 1.08; letter-spacing: -0.025em; }
.bench-lede { margin-block-start: 1rem; max-width: 40rem; text-wrap: balance; font-size: clamp(1.0625rem, 2vw, 1.25rem); line-height: 1.45; color: var(--muted); }
.bench-warning { margin-block-start: 1rem; max-width: 46rem; font-size: 0.875rem; line-height: 1.5; color: var(--muted); }
.bench-warning strong { color: var(--fg); font-weight: 600; }

.bench-model, .bench-filter button, .bench-select select { font-family: inherit; color: inherit; }
.bench-dialog button, .bench-compare .pill, .bench-compare-button { font-family: inherit; }
.bench-models { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-block-start: 2rem; }
.bench-model {
  display: inline-flex; align-items: center; gap: 0.625rem; min-height: 2.75rem; padding: 0.375rem 1rem;
  border: 1px solid var(--border); border-radius: 999px; background: transparent; font-size: 0.875rem; font-weight: 500; cursor: pointer;
  transition: background-color 150ms;
}
.bench-model-score { color: var(--muted); font-variant-numeric: tabular-nums; }
.bench-model[aria-pressed="true"] { border-color: transparent; background: var(--button-bg); color: var(--button-fg); }
.bench-model[aria-pressed="true"] .bench-model-score { color: inherit; opacity: 0.75; }
@media (hover: hover) { .bench-model[aria-pressed="false"]:hover { background: var(--card); } }
.bench-model[aria-pressed="false"]:active { background: color-mix(in srgb, var(--fg) 12%, transparent); }

.bench-about { margin-block-start: 1.5rem; padding: clamp(1.25rem, 3vw, 1.75rem); border-radius: var(--radius); background: var(--card); }
.bench-about-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.25rem 1rem; }
.bench-about h2 { font-size: 1.375rem; font-weight: 600; line-height: 1.3; letter-spacing: -0.015em; }
.bench-score { font-size: 0.9375rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.bench-about > p { margin-block-start: 0.5rem; max-width: 48rem; font-size: 0.9375rem; line-height: 1.5; }
.bench-about .bench-counts { color: var(--muted); font-size: 0.875rem; }
.bench-prompt { margin-block-start: 0.75rem; }
.bench-prompt summary { display: flex; align-items: center; min-height: 2.75rem; font-size: 0.9375rem; font-weight: 600; cursor: pointer; }
.bench-prompt summary { gap: 0.5rem; list-style: none; }
.bench-prompt summary::-webkit-details-marker { display: none; }
.bench-prompt summary::before {
  content: ""; flex: none; width: 0.5rem; height: 0.5rem; margin-inline: 0.125rem 0.25rem;
  border-block-start: 2px solid currentColor; border-inline-end: 2px solid currentColor; border-radius: 1px;
  transform: rotate(45deg); transition: transform 200ms var(--ease-out);
}
.bench-prompt[open] summary::before { transform: rotate(135deg); }
.bench-settings { display: flex; flex-wrap: wrap; gap: 0.125rem 1.25rem; margin: 0 0 0.75rem; }
.bench-settings div { display: flex; gap: 0.375rem; }
.bench-settings dt { font-size: 0.8125rem; color: var(--muted); }
.bench-settings dd { margin: 0; font-size: 0.8125rem; font-weight: 600; }
.bench-prompt pre {
  margin: 0; padding: 1rem; overflow-x: auto; white-space: pre-wrap; overflow-wrap: anywhere;
  border: 1px solid var(--border); border-radius: 0.75rem; background: var(--bg);
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 0.8125rem; line-height: 1.5;
}

.bench-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem; margin-block-start: 2rem; }
.bench-filter { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 3px; border-radius: 999px; background: var(--card); }
.bench-filter button {
  min-height: 2.25rem; padding: 0.25rem 0.875rem; border: 0; border-radius: 999px; background: transparent;
  font-size: 0.875rem; font-weight: 500; cursor: pointer;
}
.bench-filter button[aria-pressed="true"] { background: var(--bg); box-shadow: 0 1px 3px rgb(0 0 0 / 0.16); }
@media (pointer: coarse) { .bench-filter button { min-height: 2.75rem; } }
/* The native arrow can't be positioned, so the select draws its own inside the pill. */
.bench-select { position: relative; display: inline-flex; }
.bench-select::after {
  content: ""; position: absolute; inset-block-start: 50%; inset-inline-end: 1rem; width: 0.4375rem; height: 0.4375rem;
  margin-block-start: -0.3125rem; border-block-end: 2px solid currentColor; border-inline-end: 2px solid currentColor;
  transform: rotate(45deg); pointer-events: none;
}
.bench-select select {
  appearance: none; -webkit-appearance: none; min-height: 2.75rem; padding: 0.25rem 2.5rem 0.25rem 1rem;
  border: 1px solid var(--border); border-radius: 999px; background: var(--bg); font-size: 0.9375rem; font-weight: 500; cursor: pointer;
}
.bench-switch { display: inline-flex; align-items: center; gap: 0.625rem; min-height: 2.75rem; margin-inline-start: auto; font-size: 0.9375rem; font-weight: 500; cursor: pointer; }
.bench-switch input {
  appearance: none; -webkit-appearance: none; position: relative; flex: none; width: 2.875rem; height: 1.75rem; margin: 0;
  border-radius: 999px; background: var(--bar); cursor: pointer; transition: background-color 200ms;
}
.bench-switch input::after {
  content: ""; position: absolute; inset-block-start: 2px; inset-inline-start: 2px; width: 1.5rem; height: 1.5rem;
  border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / 0.3); transition: transform 240ms var(--ease-spring);
}
.bench-switch input:checked { background: var(--bubble-eblan); }
.bench-switch input:checked::after { transform: translateX(1.125rem); }
.bench-switch input:checked:dir(rtl)::after { transform: translateX(-1.125rem); }

.bench-status { margin-block-start: 1.25rem; min-height: 1.5em; font-size: 0.875rem; color: var(--muted); }
.bench-list { display: grid; gap: 1rem; margin-block-start: 0.75rem; }
.bench-row { display: flex; flex-direction: column; gap: 0.375rem; padding: 1.125rem; border: 1px solid var(--border); border-radius: var(--radius); }
.bench-row { content-visibility: auto; contain-intrinsic-size: auto 12rem; }
.bench-row-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.25rem 1rem; }
.bench-compare-button {
  min-height: 2rem; padding: 0.125rem 0.75rem; border: 1px solid var(--border); border-radius: 999px; background: transparent;
  color: var(--fg); font-size: 0.8125rem; font-weight: 500; cursor: pointer; transition: background-color 150ms;
}
@media (hover: hover) { .bench-compare-button:hover { background: var(--card); } }
.bench-compare-button:active { background: color-mix(in srgb, var(--fg) 12%, transparent); }
@media (pointer: coarse) { .bench-compare-button { min-height: 2.75rem; padding-inline: 1rem; } }
.bench-row-meta { font-size: 0.8125rem; color: var(--muted); }
.bench .bubble { animation: none; max-width: min(88%, 44rem); -webkit-backdrop-filter: none; backdrop-filter: none; box-shadow: none; font-size: 1rem; }
.bench .bubble-insult { background: var(--card); color: var(--fg); }
.bench .bubble-eblan { background: var(--bubble-eblan); color: #fff; }
.bench .bubble-eblan.is-other { background: #3f4046; }
.bench-withheld { padding-block: 0.25rem; font-size: 0.875rem; font-style: italic; color: var(--muted); }
.bench-refusal { margin-inline-start: auto; max-width: min(88%, 44rem); padding: 0.625rem 0.875rem; border: 1px dashed var(--border); border-radius: 1.125rem; font-size: 0.9375rem; line-height: 1.4; }
.bench-refusal strong { display: block; font-size: 0.8125rem; font-weight: 600; }
.bench-refusal p { color: var(--muted); }
.bench-row-scores { display: flex; flex-wrap: wrap; gap: 0.25rem 1rem; margin: 0.5rem 0 0; padding: 0; list-style: none; font-size: 0.8125rem; color: var(--muted); }
.bench-row-scores b { margin-inline-start: 0.25rem; font-weight: 600; color: var(--fg); font-variant-numeric: tabular-nums; }
.bench-row-scores .is-overall { color: var(--fg); font-weight: 600; }
.bench-secondary { --pill-bg: var(--card); color: var(--fg); cursor: pointer; }
.bench-error { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem; padding: 1rem; border-radius: var(--radius); background: var(--card); }
.bench-compare { margin-block-start: 2rem; }
.bench-compare .bench-controls { margin-block-start: 0; justify-content: space-between; }
#compare-meta { margin-block-start: 1.5rem; }
#compare-insult { outline: none; }
.bench-compare > .bubble { margin-block: 0.5rem 1rem; }
.bench-compare-name { font-size: 1rem; font-weight: 600; line-height: 1.3; }
.bench-compare-name a { text-decoration: none; }
@media (hover: hover) { .bench-compare-name a:hover { text-decoration: underline; } }
@media (pointer: coarse) { .bench-compare-name a { display: inline-block; padding-block: 0.75rem; } }
.bench-compare-score { font-size: 0.875rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.bench-compare-steps { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem; margin-block-start: 1.5rem; }
.bench .pill:disabled { opacity: 0.45; cursor: default; }
.bench-footnote { margin-block-start: 2.5rem; max-width: 46rem; font-size: 0.8125rem; line-height: 1.5; color: var(--muted); }

.bench-dialog { max-width: min(26rem, calc(100vw - 2rem)); padding: 1.5rem; border: 0; border-radius: 1.25rem; background: var(--bg); color: var(--fg); box-shadow: 0 20px 60px rgb(0 0 0 / 0.4); }
.bench-dialog::backdrop { background: rgb(0 0 0 / 0.5); }
.bench-dialog h2 { font-size: 1.25rem; font-weight: 600; letter-spacing: -0.01em; line-height: 1.3; }
.bench-dialog p { margin-block-start: 0.5rem; font-size: 0.9375rem; line-height: 1.5; color: var(--muted); }
.bench-dialog-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.5rem; margin-block-start: 1.25rem; }
.bench-dialog-actions .pill { border: 0; cursor: pointer; }
@media (max-width: 40rem) {
  .bench { padding-block-start: 6.5rem; }
  .bench-switch { margin-inline-start: 0; }
  .bench-select, .bench-select select { width: 100%; }
}
@media (forced-colors: active) {
  .bench-model[aria-pressed="true"], .bench-filter button[aria-pressed="true"] { outline: 2px solid Highlight; }
  .bench-switch input { border: 1px solid CanvasText; }
}

/* ---- Homepage table rows open that model on the benchmark page ---- */
.results tbody tr { position: relative; }
.row-link { color: inherit; text-decoration: none; }
.row-link::after { content: ""; position: absolute; inset: 0; }
.row-link:focus-visible { outline: none; }
.row-link:focus-visible::after { outline: 3px solid color-mix(in srgb, currentColor 55%, transparent); outline-offset: -3px; border-radius: 8px; }
.results tbody tr:has(.row-link) { transition: background-color 150ms; }
@media (hover: hover) {
  .results tbody tr:has(.row-link):hover { background: color-mix(in srgb, var(--fg) 6%, transparent); }
  .results tbody tr:has(.row-link):hover .row-link { text-decoration: underline; }
}

/* ---- Chat page: always dark, whatever the system theme, so the top bar matches the dark chat UI ---- */
.chat-page {
  color-scheme: dark;
  --bg: #0c0a09; --fg: #fafaf9; --muted: #a6a09b; --card: #1c1917; --border: rgb(255 255 255 / 0.1);
  --nav-bg: rgb(28 25 23 / 0.82); --nav-border: rgb(255 255 255 / 0.12); --button-bg: #fafaf9; --button-fg: #0c0a09;
}
.chat-page .nav .logo img { filter: invert(1); }
/* the chat app's shadcn tokens reuse the name --muted (a dark fill there), so pin the top bar's hover color */
.chat-page .nav-links a:hover { color: #a6a09b; }
