/* SPDX-License-Identifier: MIT */
/*
 * The project website's styles: the layout, the landing page and the frame around the
 * documentation. The Markdown styles and shared foundations use Quaso's palette.
 * Light and dark themes follow the visitor's system setting.
 */

/* SPDX-License-Identifier: MIT */
/* Import once, before consumer styles. Foundations refine the shared document defaults. */
/* SPDX-License-Identifier: MIT */
/*
 * The theme's colours. Generated from tokens.ts: change them there, then run
 * npm run design:tokens
 * The light theme is the default; the dark one follows the system setting unless the
 * visitor picked a theme (data-theme on <html>).
 */

:root {
  --paper-0: #ffffff;
  --paper-50: #f4f4f1;
  --paper-100: #eeebf1;
  --paper-200: #d7d0de;
  --paper-300: #c4b6ce;
  --paper-400: #93829f;
  --paper-500: #74657f;
  --paper-600: #62546c;
  --ink-500: #594366;
  --ink-600: #493257;
  --ink-700: #3b2648;
  --ink-800: #30173d;
  --ink-900: #291634;
  --ink-950: #261230;
  --lime-50: #f0f7dc;
  --lime-300: #e3ff97;
  --lime-400: #d7ff64;
  --lime-500: #c5ee50;
  --lime-700: #546b16;
  --mint-50: #e7faf5;
  --mint-300: #80e5dc;
  --mint-700: #18665e;
  --mint-950: #163a38;
  --vermilion-50: #fdeceb;
  --vermilion-300: #ffa36f;
  --vermilion-400: #f7703f;
  --vermilion-500: #c23b09;
  --vermilion-600: #ad4424;
  --vermilion-700: #b42318;
  --vermilion-950: #3a1714;
  --amber-50: #fff4d9;
  --amber-300: #e8b14a;
  --amber-700: #8a5300;
  --amber-950: #33260c;
  --teal-50: #e7f6ed;
  --teal-200: #62e3c6;
  --teal-300: #56d38c;
  --teal-700: #116a3a;
  --teal-800: #00665a;
  --teal-950: #10291b;
  --blue-50: #e8effd;
  --blue-200: #86a9f8;
  --blue-300: #6cb6ff;
  --blue-600: #0b62d6;
  --blue-700: #0a54b4;
  --blue-800: #1d3794;
  --blue-950: #1d2d4a;
  --violet-50: #ede7ff;
  --violet-200: #cdbdff;
  --violet-700: #4b2aa8;
  --violet-950: #2f2552;
  color-scheme: light;
  --brand: var(--ink-950);
  --brand-soft: var(--lime-50);
  --accent: var(--lime-400);
  --accent-alt: var(--mint-300);
  --accent-fg: var(--ink-950);
  --bg: var(--paper-50);
  --surface: var(--paper-0);
  --surface-alt: var(--paper-100);
  --hover: var(--paper-100);
  --selected: var(--lime-50);
  --fg: var(--ink-950);
  --fg-muted: var(--paper-600);
  --border: var(--paper-200);
  --border-strong: var(--paper-400);
  --link: var(--violet-700);
  --focus: var(--violet-700);
  --primary: var(--lime-400);
  --primary-hover: var(--lime-500);
  --primary-fg: var(--ink-950);
  --danger: var(--vermilion-700);
  --danger-bg: var(--vermilion-50);
  --warning: var(--amber-700);
  --warning-bg: var(--amber-50);
  --success: var(--teal-700);
  --success-bg: var(--teal-50);
  --state-red: var(--vermilion-500);
  --state-green: var(--teal-800);
  --state-blue: var(--blue-800);
  --bar-track: var(--paper-500);
  --mark-bg: var(--violet-50);
  --mark-fg: var(--violet-700);
  --shadow: 4px 4px 0 var(--border);
  --backdrop: color-mix(in srgb, var(--ink-950) 48%, transparent);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --brand: var(--lime-400);
    --brand-soft: var(--ink-800);
    --accent: var(--lime-400);
    --accent-alt: var(--mint-300);
    --accent-fg: var(--ink-950);
    --bg: var(--ink-950);
    --surface: var(--ink-900);
    --surface-alt: var(--ink-800);
    --hover: var(--ink-700);
    --selected: var(--blue-950);
    --fg: var(--paper-50);
    --fg-muted: var(--paper-300);
    --border: var(--ink-600);
    --border-strong: var(--paper-400);
    --link: var(--mint-300);
    --focus: var(--mint-300);
    --primary: var(--lime-400);
    --primary-hover: var(--lime-300);
    --primary-fg: var(--ink-950);
    --danger: var(--vermilion-300);
    --danger-bg: var(--vermilion-950);
    --warning: var(--amber-300);
    --warning-bg: var(--amber-950);
    --success: var(--teal-300);
    --success-bg: var(--teal-950);
    --state-red: var(--vermilion-400);
    --state-green: var(--teal-200);
    --state-blue: var(--blue-200);
    --bar-track: var(--paper-400);
    --mark-bg: var(--violet-950);
    --mark-fg: var(--violet-200);
    --shadow: 4px 4px 0 var(--ink-950);
    --backdrop: color-mix(in srgb, var(--ink-950) 72%, transparent);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --brand: var(--lime-400);
  --brand-soft: var(--ink-800);
  --accent: var(--lime-400);
  --accent-alt: var(--mint-300);
  --accent-fg: var(--ink-950);
  --bg: var(--ink-950);
  --surface: var(--ink-900);
  --surface-alt: var(--ink-800);
  --hover: var(--ink-700);
  --selected: var(--blue-950);
  --fg: var(--paper-50);
  --fg-muted: var(--paper-300);
  --border: var(--ink-600);
  --border-strong: var(--paper-400);
  --link: var(--mint-300);
  --focus: var(--mint-300);
  --primary: var(--lime-400);
  --primary-hover: var(--lime-300);
  --primary-fg: var(--ink-950);
  --danger: var(--vermilion-300);
  --danger-bg: var(--vermilion-950);
  --warning: var(--amber-300);
  --warning-bg: var(--amber-950);
  --success: var(--teal-300);
  --success-bg: var(--teal-950);
  --state-red: var(--vermilion-400);
  --state-green: var(--teal-200);
  --state-blue: var(--blue-200);
  --bar-track: var(--paper-400);
  --mark-bg: var(--violet-950);
  --mark-fg: var(--violet-200);
  --shadow: 4px 4px 0 var(--ink-950);
  --backdrop: color-mix(in srgb, var(--ink-950) 72%, transparent);
}

/* SPDX-License-Identifier: MIT */
/*
 * Shared document defaults, focus rings and utilities.
 * Colours come from theme.css (generated from tokens.ts).
 */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: var(--text-md);
  line-height: 1.5;
}

h1,
h2,
h3,
h4,
p,
ul,
ol,
dl,
dd,
figure,
blockquote {
  margin: 0;
}

h1 {
  font-size: var(--text-xl);
  line-height: 1.25;
  font-weight: 650;
}

h2 {
  font-size: var(--text-lg);
  line-height: 1.3;
  font-weight: 620;
}

h3 {
  font-size: var(--text-md);
  font-weight: 620;
}

h1:focus,
main:focus {
  outline: none;
}

a {
  color: var(--link);
  text-underline-offset: 0.15em;
}

code,
kbd {
  font-family: var(--mono);
  font-size: 0.9em;
}

code {
  background: var(--surface-alt);
  padding: 0.05em 0.3em;
  border-radius: 0;
}

kbd {
  display: inline-block;
  min-width: 1.6em;
  padding: 0.05em 0.4em;
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: 0;
  background: var(--surface);
  text-align: center;
  line-height: 1.4;
}

img,
svg {
  vertical-align: middle;
}

.icon {
  flex: none;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

fieldset {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}

/* Visible focus everywhere, for keyboard users (WCAG 2.4.7, 2.4.11). */
:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

::selection {
  background: var(--selected);
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.muted {
  color: var(--fg-muted);
}

.small {
  font-size: var(--text-sm);
}

.pad {
  padding: var(--space-4);
}

/* The first keyboard stop skips repeated navigation. */

.skip-link {
  position: absolute;
  top: var(--space-2);
  left: var(--space-2);
  z-index: 100;
  padding: var(--space-2) var(--space-3);
  background: var(--primary);
  color: var(--primary-fg);
  border-radius: var(--radius-small);
  transform: translateY(-200%);
}

.skip-link:focus {
  transform: none;
}

/* Respect reduced motion: no animations or smooth scrolling. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* SPDX-License-Identifier: MIT */
@font-face {
  font-family: "Jersey 25";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./jersey-25.ttf") format("truetype");
}
@font-face {
  font-family: "Jersey 20";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./jersey-20.ttf") format("truetype");
}
@font-face {
  font-family: "Jersey 15";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./jersey-15.ttf") format("truetype");
}
@font-face {
  font-family: "Jersey 10";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./jersey-10.ttf") format("truetype");
}

:root {
  --font:
    system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Roboto, Helvetica, Arial,
    sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  --font-display: "Jersey 25", var(--font);
  --font-h2: "Jersey 20", var(--font);
  --font-h3: "Jersey 15", var(--font);
  --font-h4: "Jersey 10", var(--font);
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-md: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.5rem;
  --heading-1: clamp(2.5rem, 4vw, 3.5rem);
  --heading-2: clamp(1.75rem, 2.5vw, 2.25rem);
  --heading-3: 1.75rem;
  --heading-4: 1.5rem;
  --heading-compact: 1.5rem;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --radius: 0;
  --radius-small: 0;
  --control-height: 2.75rem;
  --header-height: 4.5rem;
  --page-width: 76rem;
  --transition: 120ms ease;
}

h1,
h2,
h3,
h4,
.heading {
  min-width: 0;
  font-weight: 400;
  letter-spacing: normal;
  line-height: 1.1;
  text-wrap: balance;
  overflow-wrap: anywhere;
}
h1 {
  font-family: var(--font-display);
}
h2 {
  font-family: var(--font-h2);
}
h3 {
  font-family: var(--font-h3);
}
h4 {
  font-family: var(--font-h4);
}
.heading-ink {
  display: block;
}
h1.heading {
  font-size: var(--heading-1);
}
h2.heading {
  font-size: var(--heading-2);
}
h3.heading {
  font-size: var(--heading-3);
}
h4.heading {
  font-size: var(--heading-4);
}
.heading.heading-display {
  font-size: clamp(4rem, 9vw, 8rem);
  line-height: 0.95;
}
.heading.heading-ui {
  font-size: var(--heading-compact);
  line-height: 1.15;
}
h1.heading.heading-ui {
  font-size: 2rem;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font: 400 2.5rem / 1 var(--font-display);
  color: var(--fg);
  white-space: nowrap;
}
.quaso-mascot {
  display: inline-block;
  flex: none;
  width: 4rem;
  height: 3rem;
  background: url("./quaso-cat.svg") center / contain no-repeat;
  image-rendering: pixelated;
}

/* A monochrome pixel tile takes its two colors from the theme. */
.pixel-pattern {
  position: relative;
  overflow: hidden;
  background: var(--accent);
  color: color-mix(in srgb, var(--accent-fg) 48%, transparent);
}
.pixel-pattern::before {
  content: "";
  position: absolute;
  inset: 0;
  background: currentColor;
  mask: url("./pixel-weave.svg") repeat 0 0 / 128px 128px;
}
.pixel-pattern-mint {
  background: var(--accent-alt);
}
.pixel-pattern-plum {
  background: var(--ink-800);
  color: var(--ink-600);
}

/* SPDX-License-Identifier: MIT */
/* Shared controls, notices, state indicators, dialogs, tabs and chips. */

/* --- Buttons. */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: var(--control-height);
  padding: 0.4rem 0.9rem;
  border: 2px solid var(--border-strong);
  border-radius: var(--radius-small);
  background: var(--surface);
  color: var(--fg);
  font-weight: 560;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition:
    background var(--transition),
    border-color var(--transition);
  /* Long labels wrap between words; break-word (unlike anywhere) leaves the min-content width
     alone, so a button in a crowded flex row never shrinks into "Sa/ve". */
  white-space: normal;
  overflow-wrap: break-word;
}

.btn:hover:not(:disabled, [aria-busy="true"]) {
  background: var(--hover);
}

.btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

/* Busy: still focusable (aria-disabled), clicks ignored, the spinner shows it. */
.btn[aria-busy="true"] {
  cursor: progress;
}

.btn-primary {
  background: var(--primary);
  border-color: var(--primary-fg);
  color: var(--primary-fg);
  box-shadow: 3px 3px 0 var(--primary-fg);
}

.btn-primary:hover:not(:disabled, [aria-busy="true"]) {
  background: var(--primary-hover);
  border-color: var(--primary-fg);
}

.btn-primary:active:not(:disabled, [aria-busy="true"]) {
  transform: translate(2px, 2px);
  box-shadow: 1px 1px 0 var(--primary-fg);
}

.btn-danger {
  background: var(--danger);
  border-color: var(--danger);
  color: var(--surface);
}

.btn-danger:hover:not(:disabled, [aria-busy="true"]) {
  background: var(--danger);
  text-decoration: underline;
}

.btn-ghost {
  border-color: transparent;
  background: transparent;
}

.btn-danger-text {
  color: var(--danger);
}

.btn-small {
  padding: 0.25rem 0.6rem;
  font-size: var(--text-sm);
}

.btn-block {
  width: 100%;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: var(--control-height);
  min-height: var(--control-height);
  padding: 0;
  border: 1px solid transparent;
  border-radius: var(--radius-small);
  background: transparent;
  color: var(--fg-muted);
  cursor: pointer;
}

.icon-btn:hover {
  background: var(--hover);
  color: var(--fg);
}

.link-button {
  padding: 0;
  border: 0;
  background: none;
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 0.15em;
  cursor: pointer;
}

/* --- Form fields. */

.form {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.field {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.field-label {
  font-weight: 560;
}

.field-hint {
  color: var(--fg-muted);
  font-size: var(--text-sm);
}

.field-error {
  color: var(--danger);
  font-size: var(--text-sm);
  font-weight: 520;
}

.input,
.select,
.textarea {
  width: 100%;
  min-height: var(--control-height);
  padding: 0.4rem 0.6rem;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-small);
  background: var(--surface);
  color: var(--fg);
}

.select {
  width: auto;
  padding-inline-end: 1.8rem;
}

.input[type="file"] {
  padding: 0;
}
.input::file-selector-button {
  min-height: calc(var(--control-height) - 2px);
  padding: 0.4rem 0.75rem;
  margin-inline-end: 0.75rem;
  border: 0;
  border-inline-end: 1px solid var(--border-strong);
  border-radius: 0;
  background: var(--surface-alt);
  color: var(--fg);
  font: inherit;
  cursor: pointer;
}

/* Safari's native popup control needs a height, not just a minimum. */
.select:not([multiple], [size]) {
  appearance: none;
  height: var(--control-height);
  background-image:
    linear-gradient(45deg, transparent 50%, var(--fg-muted) 50%),
    linear-gradient(135deg, var(--fg-muted) 50%, transparent 50%);
  background-position:
    calc(100% - 1rem) center,
    calc(100% - 0.6875rem) center;
  background-size: 0.3125rem 0.3125rem;
  background-repeat: no-repeat;
}

.select:dir(rtl) {
  background-position:
    0.6875rem center,
    1rem center;
}

.control-label:has(> .choice-input, > .switch) {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: var(--control-height);
  min-width: var(--control-height);
  cursor: pointer;
}

.textarea {
  resize: vertical;
  line-height: 1.65;
  overflow: auto;
}

.input[aria-invalid="true"],
.select[aria-invalid="true"],
.textarea[aria-invalid="true"] {
  border-color: var(--danger);
  box-shadow: 0 0 0 1px var(--danger);
}

.input:focus-visible,
.select:focus-visible,
.textarea:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 0;
  border-color: var(--focus);
}

.fieldset {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4) var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.fieldset legend {
  padding: 0 var(--space-1);
  font-weight: 620;
}

.checkbox {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  cursor: pointer;
}

.checkbox input,
.row-check {
  width: 1rem;
  height: 1rem;
  margin: 0;
  accent-color: var(--primary);
}

.inline-field {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--fg-muted);
  font-size: var(--text-sm);
}

.search {
  position: relative;
  flex: 1;
  min-width: 10rem;
}

.search-icon {
  position: absolute;
  inset-inline-start: 0.6rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--fg-muted);
  pointer-events: none;
}

.search-input {
  padding-inline-start: 2rem;
}

.toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-3);
}

/* --- Cards, notices, empty states, spinners. */

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
}

.notice {
  display: flex;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.notice-icon {
  flex: none;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  min-height: 1.5em;
}

.notice-body {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  min-width: 0;
}

.notice-title {
  font-weight: 620;
}

.notice-error {
  background: var(--danger-bg);
  border-color: var(--danger);
}

.notice-error .notice-icon {
  color: var(--danger);
}

.notice-warning {
  background: var(--warning-bg);
  border-color: var(--warning);
}

.notice-warning .notice-icon {
  color: var(--warning);
}

.notice-success {
  background: var(--success-bg);
  border-color: var(--success);
}

.notice-success .notice-icon {
  color: var(--success);
}

.notice-info .notice-icon {
  color: var(--link);
}

.notice-details {
  padding-inline-start: 1.2rem;
  font-size: var(--text-sm);
}

.notice .btn {
  align-self: flex-start;
}

.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-6) var(--space-4);
  text-align: center;
  color: var(--fg-muted);
}

.empty-icon {
  color: var(--fg-muted);
}

.empty-title {
  color: var(--fg);
  font-weight: 620;
}

.loading {
  display: flex;
  justify-content: center;
  padding: var(--space-5);
}

.spinner-wrap {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--fg-muted);
}

.spinner {
  display: inline-block;
  width: 1em;
  height: 1em;
  border: 2px solid currentColor;
  border-inline-end-color: transparent;
  border-radius: 0;
  animation: spin 0.8s steps(4) infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Keep the loading indicator visible when animation is disabled. */
@media (prefers-reduced-motion: reduce) {
  .spinner {
    animation: none;
  }
}

/* --- String states: shapes and colours (colour is never the only signal). */

.state-red {
  color: var(--state-red);
}

.state-green {
  color: var(--state-green);
}

.state-blue {
  color: var(--state-blue);
}

.flag-outdated,
.flag-pending {
  color: var(--warning);
}

.flag-qa {
  color: var(--danger);
}

.state-marker {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  flex: none;
}

.state-marker .flag-icon {
  width: 12px;
  height: 12px;
}

.state-badges {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--space-1);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 0.1rem 0.5rem;
  border: 1px solid currentColor;
  border-radius: 0;
  font-size: var(--text-sm);
  font-weight: 560;
  background: var(--surface);
}

.badge-red {
  color: var(--state-red);
}

.badge-green {
  color: var(--state-green);
}

.badge-blue {
  color: var(--state-blue);
}

.badge-flag {
  color: var(--fg);
  border-color: var(--border-strong);
}

.colour-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-sm);
  font-weight: 560;
}

.colour-red {
  color: var(--state-red);
}

.colour-green {
  color: var(--state-green);
}

.colour-blue {
  color: var(--state-blue);
}

.flag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-sm);
  color: var(--fg-muted);
}

/* --- Dialogs. */

.dialog {
  width: min(36rem, calc(100vw - 2rem));
  max-height: calc(100vh - 4rem);
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--fg);
  box-shadow: var(--shadow);
}

.dialog-small {
  width: min(26rem, calc(100vw - 2rem));
}

.dialog-large {
  width: min(52rem, calc(100vw - 2rem));
}

.dialog::backdrop {
  background: var(--backdrop);
}

.dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
}

.dialog-title.heading {
  font-size: var(--heading-3);
}

.dialog-body {
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.dialog-footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  border-top: 1px solid var(--border);
}

/* --- Tabs. */

.tab-list {
  display: flex;
  gap: var(--space-1);
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
}

.tab {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-2) var(--space-3);
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  color: var(--fg-muted);
  font-weight: 560;
  cursor: pointer;
  white-space: nowrap;
}

.tab:hover {
  color: var(--fg);
}

.tab[aria-selected="true"] {
  color: var(--fg);
  border-bottom-color: var(--fg);
}

.tab-count {
  min-width: 1.3rem;
  padding: 0 0.35rem;
  border-radius: 0;
  background: var(--surface-alt);
  color: var(--fg);
  font-size: var(--text-xs);
  text-align: center;
}

.tab-panel {
  padding: var(--space-3) 0;
}

/* --- Chips. */

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 0.15rem 0.3rem 0.15rem 0.5rem;
  border: 1px solid var(--border-strong);
  border-radius: 0;
  background: var(--mark-bg);
  color: var(--mark-fg);
  font-family: var(--mono);
  font-size: var(--text-sm);
  cursor: pointer;
}

.chip:hover {
  border-color: var(--mark-fg);
}

.chip-reference {
  background: var(--surface-alt);
  color: var(--fg);
}

.chip-key {
  min-width: 1.2rem;
  padding: 0 0.25rem;
  font-size: var(--text-xs);
  border-bottom-width: 1px;
  color: var(--fg-muted);
}

/* --- Theme switch and disclosure menus. */

.theme-switch {
  position: relative;
  display: flex;
  align-items: center;
}

.theme-switch-icon {
  position: absolute;
  inset-inline-start: 0.55rem;
  color: var(--fg-muted);
  pointer-events: none;
}

.theme-select {
  padding: 0.2rem 0.4rem 0.2rem 1.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-small);
  background-color: var(--surface);
  font-size: var(--text-sm);
  cursor: pointer;
}

.menu {
  position: absolute;
  inset-inline-end: 0;
  top: calc(100% + 0.3rem);
  z-index: 30;
  min-width: 14rem;
  width: max-content;
  max-width: calc(100vw - 2 * var(--space-3));
  max-height: calc(100dvh - var(--header-block-size, var(--header-height)) - var(--space-3));
  overflow-y: auto;
  padding: var(--space-1);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.dropdown {
  position: relative;
  display: inline-flex;
}

.dropdown-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
}

.menu-caption {
  padding: var(--space-2) var(--space-3);
  color: var(--fg-muted);
  font-size: var(--text-sm);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--space-1);
}

.menu-item {
  display: flex;
  align-items: center;
  min-height: var(--control-height);
  width: 100%;
  padding: var(--space-2) var(--space-3);
  border: 0;
  border-radius: var(--radius-small);
  background: none;
  text-align: start;
  cursor: pointer;
  color: var(--fg);
  text-decoration: none;
  white-space: normal;
  overflow-wrap: anywhere;
}

.menu-item:hover,
.menu-item:focus-visible {
  background: var(--hover);
}

/* The native controls retain their keyboard, autofill and form behavior. */
:where(.button-plain) {
  min-height: var(--control-height);
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.button-plain:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
.choice-input {
  appearance: none;
  display: inline-grid;
  place-content: center;
  width: 1.125rem;
  height: 1.125rem;
  margin: 0;
  flex: none;
  vertical-align: middle;
  border: 2px solid var(--border-strong);
  background: var(--surface);
  cursor: pointer;
}
.choice-input::before {
  content: "";
  width: 0.625rem;
  height: 0.625rem;
  background: var(--fg);
  transform: scale(0);
}
.choice-input[type="radio"]::before {
  clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%);
}
.choice-input[type="checkbox"]::before {
  clip-path: polygon(
    0 35%,
    25% 35%,
    25% 60%,
    40% 60%,
    40% 40%,
    60% 40%,
    60% 20%,
    80% 20%,
    80% 0,
    100% 0,
    100% 40%,
    80% 40%,
    80% 60%,
    60% 60%,
    60% 80%,
    40% 80%,
    40% 100%,
    20% 100%,
    20% 80%,
    0 80%
  );
}
.choice-input:checked::before,
.choice-input:indeterminate::before {
  transform: scale(1);
}
.choice-input:indeterminate::before {
  clip-path: inset(35% 0);
}
.choice-input:disabled {
  opacity: 0.55;
}
@media (forced-colors: active) {
  .choice-input {
    appearance: auto;
  }
  .choice-input::before {
    display: none;
  }
}
.choice-input:disabled {
  cursor: not-allowed;
}
.switch {
  appearance: none;
  display: inline-block;
  width: 2.5rem;
  height: 1.5rem;
  margin: 0;
  padding: 3px;
  border: 1px solid var(--border-strong);
  border-radius: 0;
  background: var(--surface-alt);
  cursor: pointer;
  flex: none;
  transition: background var(--transition);
}
.switch::before {
  content: "";
  display: block;
  width: 1rem;
  height: 1rem;
  border-radius: 0;
  background: var(--fg-muted);
  transition: transform var(--transition);
}
.switch:checked {
  background: var(--primary);
  border-color: var(--border-strong);
}
.switch:checked::before {
  background: var(--primary-fg);
  transform: translateX(1rem);
}
.switch:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  cursor: pointer;
  color: var(--fg-muted);
}
/*
 * Ticks every 8px. The fill ends 2px before the tick nearest its value and draws that tick
 * thicker, as its head. Progress sets --progress, from 0 to 1.
 */
.progress {
  width: 100%;
  height: 0.75rem;
  appearance: none;
  border: 0;
  border-radius: 0;
  background: var(--state-blue);
  /* The ticks are an image, not a repeating gradient: at zooms such as 115%, a gradient
     rounds them to unequal widths. */
  mask-image:
    linear-gradient(to left, black 0 4px, transparent 4px 6px, black 6px),
    url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 1' preserveAspectRatio='none'><rect width='2' height='1'/></svg>");
  mask-size:
    calc(round(var(--progress, 0) * 100%, 8px) + 4px) 100%,
    8px 100%;
  mask-repeat: no-repeat, repeat;
}
.progress-full {
  mask: none;
}
/* The browsers' own track and fill would cover the drawing. */
.progress::-webkit-progress-bar,
.progress::-webkit-progress-value {
  background: transparent;
}
.progress::-moz-progress-bar {
  background: transparent;
}
.table {
  width: 100%;
  border-collapse: collapse;
  text-align: start;
}
.table th {
  font-weight: 600;
  color: var(--fg-muted);
  background: var(--surface-alt);
}
.table th,
.table td {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
  text-align: start;
}
.disclosure > summary {
  min-height: var(--control-height);
  cursor: pointer;
  font-weight: 560;
  padding: var(--space-2) 0;
}
.disclosure[open] > summary {
  margin-bottom: var(--space-2);
}
.input:disabled,
.select:disabled,
.textarea:disabled {
  background: var(--surface-alt);
  color: var(--fg-muted);
  cursor: not-allowed;
}



:root {
  --site-width: 72rem;
}

/* The site header scrolls with the document. */
html {
  scroll-padding-top: var(--space-4);
}

body,
#root {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

.container {
  width: 100%;
  max-width: var(--site-width);
  margin: 0 auto;
  padding-inline: var(--space-5);
}

/* Header and footer */

.site-header {
  border-bottom: 1px solid var(--border);
}

.site-header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2) var(--space-5);
  padding-top: var(--space-3);
  padding-bottom: var(--space-3);
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--fg);
  min-height: var(--control-height);
  text-decoration: none;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-5);
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--control-height);
  min-width: var(--control-height);
  color: var(--fg-muted);
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current] {
  color: var(--fg);
  text-decoration: underline;
}

.site-footer {
  border-top: 1px solid var(--border);
  color: var(--fg-muted);
  font-size: var(--text-sm);
}

/* Landing page: the shared pixel language, with room for the story. */
.landing {
  --section-gap: clamp(4rem, 7vw, 6rem);
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font: 0.6875rem / 1.6 var(--mono);
  letter-spacing: 0.06em;
}
.section-index {
  display: inline-grid;
  place-items: center;
  width: 1.75rem;
  height: 1.75rem;
  border: 1px solid currentColor;
  font-size: var(--text-xs);
}
.hero {
  overflow: clip;
  padding-top: clamp(2rem, 5vw, 4.5rem);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.04fr 1fr;
  align-items: center;
  gap: var(--space-7);
  padding-bottom: var(--section-gap);
}
.hero h1.heading {
  margin: var(--space-5) 0;
  font-size: clamp(4.5rem, 7.7vw, 6.75rem);
  line-height: 0.94;
}
.hero-highlight {
  background: var(--accent);
  color: var(--accent-fg);
  padding: 0 0.08em;
  margin-left: -0.08em;
  box-decoration-break: clone;
}
.lead {
  max-width: 30rem;
  font-size: var(--text-lg);
  line-height: 1.7;
  color: var(--fg-muted);
}
.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-5);
  margin-top: var(--space-6);
}
.landing .btn {
  gap: var(--space-5);
  padding: var(--space-3) var(--space-5);
  white-space: normal;
}
.text-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: var(--control-height);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
}
.text-link:hover {
  text-decoration: underline;
}
.hero-footnote {
  margin-top: var(--space-4);
  font-size: var(--text-xs);
  color: var(--fg-muted);
}
.hero-scene {
  position: relative;
  isolation: isolate;
  padding: 8.5rem 0 2rem;
}
.hero-weave {
  position: absolute;
  z-index: -1;
  inset: 2rem -5rem 0 3rem;
  clip-path: polygon(
    0 0,
    85% 0,
    85% 8%,
    100% 8%,
    100% 84%,
    92% 84%,
    92% 100%,
    12% 100%,
    12% 91%,
    0 91%
  );
}
.mascot-greeting {
  position: absolute;
  top: 0;
  right: var(--space-5);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.mascot-greeting img {
  image-rendering: pixelated;
  flex: none;
}
.speech-bubble {
  position: relative;
  background: var(--surface);
  color: var(--fg);
  border: 2px solid var(--ink-950);
  box-shadow: 4px 4px 0 var(--ink-950);
  padding: var(--space-2) var(--space-3);
  font: 1.625rem / 1.2 var(--font-h2);
  transform: translateY(-0.5rem);
}
.speech-bubble::after {
  content: "";
  position: absolute;
  bottom: -9px;
  right: 16px;
  width: 12px;
  height: 9px;
  background: var(--surface);
  border-right: 2px solid var(--ink-950);
  border-bottom: 2px solid var(--ink-950);
}
.translation-window {
  border: 2px solid var(--ink-950);
  background: var(--surface);
  box-shadow: 8px 8px 0 var(--ink-950);
}
.translation-bar,
.terminal-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  background: var(--ink-950);
  color: var(--paper-50);
  font: 0.625rem / 1.5 var(--mono);
  letter-spacing: 0.08em;
}
.window-mark {
  color: var(--lime-400);
  font-size: 0.5rem;
  white-space: nowrap;
}
.translation-body {
  padding: var(--space-5);
}
.string-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
  color: var(--fg-muted);
  font: 0.6875rem / 1.5 var(--mono);
}
.language-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
}
.language-label > span:first-child {
  border: 1px solid var(--border-strong);
  padding: 0.0625rem 0.25rem;
  font: 0.6875rem / 1.5 var(--mono);
}
.language-role {
  margin-left: auto;
  color: var(--fg-muted);
  font-size: 0.6875rem;
}
.example-string {
  margin-top: var(--space-3);
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  line-height: 1.5;
}
.translation-divider {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin: var(--space-5) 0;
  padding-block: var(--space-3);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  color: var(--fg-muted);
  font-size: 0.6875rem;
}
.translation-divider > span:first-child {
  font-size: var(--text-xl);
  color: var(--fg);
}
.build-history {
  display: grid;
  gap: var(--space-5);
  margin: 0;
  padding: 0;
  list-style: none;
}
.build-label {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-1) var(--space-3);
}
.build-label > span:last-child {
  color: var(--fg-muted);
  font: 0.6875rem / 1.5 var(--mono);
}
.build-history .example-string {
  margin-top: var(--space-2);
}
/* The earlier build's wording is history now, not a mistake: it shipped. */
.build-history li:first-child .example-string {
  color: var(--fg-muted);
}
.translation-proof {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
  color: var(--fg-muted);
  font-size: var(--text-xs);
}
.scene-caption {
  display: block;
  width: fit-content;
  margin: var(--space-5) 0 0 var(--space-4);
  padding: var(--space-1) var(--space-2);
  background: var(--ink-950);
  color: var(--paper-50);
  font: 0.625rem / 1.5 var(--mono);
}
.format-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-4) var(--space-5);
  padding-block: var(--space-5);
  border-top: 1px solid var(--border-strong);
  font-size: var(--text-sm);
}
.format-strip > span {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}
.format-strip .eyebrow {
  color: var(--fg-muted);
  font-size: 0.625rem;
}
.soon {
  display: inline-block;
  color: var(--fg-muted);
  font: 0.625rem / 1.5 var(--mono);
}
.section {
  padding-block: var(--section-gap);
}
.why-section,
.features-section {
  background: var(--surface-alt);
  border-block: 1px solid var(--border);
}
.section-heading {
  display: flex;
  justify-content: space-between;
  gap: var(--space-6);
  align-items: end;
  margin-bottom: var(--space-7);
}
.section-heading h2.heading {
  margin-top: var(--space-5);
  font-size: clamp(3.25rem, 5.5vw, 4.5rem);
  line-height: 0.98;
}
.section-heading > p {
  max-width: 19rem;
  padding-bottom: var(--space-1);
  color: var(--fg-muted);
  font-size: var(--text-sm);
  line-height: 1.75;
}
.release-compare {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-5);
}
.release-lane {
  display: flex;
  flex-direction: column;
  padding: var(--space-6);
  border: 1px solid var(--border-strong);
  background: var(--bg);
}
.release-quaso {
  background: var(--lime-400);
  color: var(--ink-950);
  border-color: var(--ink-950);
  box-shadow: 6px 6px 0 var(--ink-950);
}
.release-lane h3.heading {
  margin-bottom: var(--space-5);
  font-size: 2.375rem;
  line-height: 1.05;
}
.release-steps {
  display: grid;
  gap: var(--space-4);
  margin: 0 0 var(--space-6);
  padding: 0;
  list-style: none;
}
.release-steps li {
  display: grid;
  grid-template-columns: 6.5rem minmax(0, 1fr);
  gap: var(--space-4);
  font-size: var(--text-sm);
  line-height: 1.6;
}
.release-when {
  padding-top: 0.125rem;
  font: 0.6875rem / 1.6 var(--mono);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.release-usual .release-steps,
.release-usual .release-when {
  color: var(--fg-muted);
}
.release-outcome {
  margin-top: auto;
  padding-top: var(--space-4);
  border-top: 1px solid var(--border-strong);
  font: 1.625rem / 1.15 var(--font-h2);
}
.release-quaso .release-outcome {
  border-color: var(--ink-950);
}
.safeguards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6);
  margin-top: var(--space-7);
  padding: var(--space-6) 0 0;
  border-top: 1px solid var(--border-strong);
  list-style: none;
}
.safeguards h3.heading {
  margin-bottom: var(--space-3);
  font-size: 1.625rem;
  line-height: 1.1;
}
.safeguards p {
  color: var(--fg-muted);
  font-size: var(--text-sm);
  line-height: 1.75;
}
.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  list-style: none;
  gap: var(--space-4);
  padding: 0;
}
.feature {
  display: flex;
  flex-direction: column;
  padding: var(--space-5);
  border: 1px solid var(--border-strong);
  background: var(--bg);
}
.feature-lime {
  background: var(--lime-400);
  color: var(--ink-950);
  border-color: var(--ink-950);
  box-shadow: 4px 4px 0 var(--ink-950);
}
.feature-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-6);
}
.feature-top > span {
  font: 0.6875rem / 1.5 var(--mono);
}
/* An inventory slot; padding, border and bevel are whole art pixels (2 px) so the grid stays even. */
.feature-art {
  box-sizing: content-box;
  padding: 6px;
  border: 2px solid var(--border-strong);
  background: var(--surface);
  box-shadow: inset -2px -2px 0 var(--border);
  image-rendering: pixelated;
}
.feature-lime .feature-art {
  border-color: var(--ink-950);
}
.feature h3.heading {
  font-size: 1.875rem;
  margin-bottom: var(--space-3);
  line-height: 1.05;
}
.feature > p {
  font-size: var(--text-sm);
  line-height: 1.75;
  color: var(--fg-muted);
  margin-bottom: var(--space-5);
}
.feature-note {
  margin-top: auto;
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
  font: 0.625rem / 1.7 var(--mono);
}
.feature-lime > p {
  color: var(--ink-700);
}
.feature-lime .feature-note {
  border-color: var(--lime-700);
}
.workflow-steps {
  list-style: none;
  padding: 0;
}
.workflow-step {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: var(--space-7) var(--space-8);
  align-items: center;
  padding-block: var(--space-8);
  border-top: 1px solid var(--border-strong);
}
.workflow-step:last-child {
  padding-bottom: 0;
}
.step-number {
  display: inline-grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  margin-bottom: var(--space-4);
  background: var(--accent);
  color: var(--accent-fg);
  border: 1px solid var(--accent-fg);
  box-shadow: 3px 3px 0 var(--accent-fg);
  font: 1.875rem / 1 var(--font-h2);
}
.step-copy h3.heading {
  margin-bottom: var(--space-4);
  font-size: 2.375rem;
  line-height: 1.05;
}
.step-copy > p {
  font-size: var(--text-sm);
  line-height: 1.8;
  color: var(--fg-muted);
}
.step-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0 var(--space-5);
  margin-top: var(--space-4);
}
.terminal {
  min-width: 0;
  background: var(--ink-950);
  color: var(--paper-50);
  border: 1px solid var(--ink-600);
  box-shadow: 6px 6px 0 var(--border);
}
.terminal-bar {
  border-bottom: 1px solid var(--ink-600);
  color: var(--paper-300);
  letter-spacing: normal;
  font-size: 0.6875rem;
}
.terminal pre {
  margin: 0;
  padding: var(--space-5);
  overflow-x: auto;
  font: 0.75rem / 1.85 var(--mono);
  tab-size: 2;
}
.terminal pre code {
  font: inherit;
  padding: 0;
  background: none;
  color: inherit;
}
.prompt,
.code-accent {
  color: var(--lime-400);
}
.prompt {
  user-select: none;
}
.code-comment {
  color: var(--paper-300);
}
.code-string {
  color: var(--mint-300);
}
.hosting-diagram {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-5);
  border: 1px solid var(--border-strong);
  margin: var(--space-5) var(--space-4) 0;
  padding: var(--space-5) var(--space-5) 0;
  background: var(--surface);
  font-size: var(--text-sm);
}
.hosting-diagram > span {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}
.hosting-diagram .hosting-footer {
  justify-content: center;
  width: calc(100% + 3rem);
  margin-inline: calc(-1 * var(--space-5));
  padding: var(--space-3);
  border-top: 1px solid var(--border);
  color: var(--fg-muted);
  font: 0.6875rem / 1.5 var(--mono);
}
.file-route {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-5);
  font: 0.75rem / 1.6 var(--mono);
}
.file-route code {
  padding: var(--space-2);
}
.translation-states {
  display: grid;
  gap: var(--space-4);
  list-style: none;
  padding: 0;
  margin-top: var(--space-5);
}
.translation-states li {
  display: flex;
  flex-direction: column;
  align-items: start;
  gap: var(--space-1);
}
.translation-states li > span:last-child {
  margin-left: 1.5rem;
  font-size: var(--text-xs);
  color: var(--fg-muted);
}
.product-shot {
  min-width: 0;
}
.product-shot > a {
  display: block;
  border: 1px solid var(--border-strong);
  box-shadow: 6px 6px 0 var(--border);
  transition: box-shadow var(--transition);
}
.product-shot > a:hover {
  box-shadow: 6px 6px 0 var(--accent);
}
.product-shot img {
  display: block;
  width: 100%;
  height: auto;
}
.product-shot figcaption {
  margin-top: var(--space-4);
  color: var(--fg-muted);
  font-size: var(--text-xs);
  line-height: 1.6;
}
.workspace-gallery {
  grid-column: 1 / -1;
  border-block: 1px solid var(--border);
}
.workspace-gallery > summary {
  padding-block: var(--space-4);
  min-height: var(--control-height);
  font-size: var(--text-sm);
  cursor: pointer;
}
.gallery-hint {
  margin-left: var(--space-4);
  font-size: var(--text-xs);
  font-weight: 400;
  color: var(--fg-muted);
}
.screenshots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-5);
  padding-block: var(--space-5);
}
.workflow-loop {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3) var(--space-5);
  margin-top: var(--space-8);
  padding: var(--space-5);
  border: 1px solid var(--border-strong);
  background: var(--surface);
}
.loop-mark {
  display: inline-grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  flex: none;
  background: var(--accent);
  color: var(--accent-fg);
  border: 1px solid var(--accent-fg);
  font-size: 1.75rem;
}
.workflow-loop p {
  flex: 1 1 24rem;
  font-size: var(--text-sm);
  line-height: 1.75;
}
.step-game .terminal {
  margin-block: var(--space-5);
}
.step-game .terminal pre {
  padding: var(--space-4);
}
.closing-section {
  position: relative;
  isolation: isolate;
  background: var(--ink-950);
  color: var(--paper-50);
  overflow: hidden;
}
.closing-pattern {
  position: absolute;
  z-index: -1;
  right: -4rem;
  bottom: -6rem;
  width: 22rem;
  height: 18rem;
  background: var(--ink-950);
  color: color-mix(in srgb, var(--lime-400) 24%, var(--ink-950));
  clip-path: polygon(20% 0, 100% 0, 100% 100%, 0 100%, 0 30%, 20% 30%);
}
.closing-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-7);
  padding-block: var(--section-gap);
}
.closing-inner .eyebrow {
  color: var(--mint-300);
  font-size: 0.625rem;
}
.closing-inner h2.heading {
  margin-block: var(--space-5);
  font-size: clamp(3.25rem, 6vw, 5rem);
  line-height: 0.98;
}
.closing-inner p:last-child {
  color: var(--paper-300);
  font-size: var(--text-sm);
}
.closing-actions {
  display: flex;
  align-items: start;
  flex-direction: column;
  gap: var(--space-4);
  flex: none;
}
.closing-actions > a:not(.btn) {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: var(--control-height);
  color: var(--paper-50);
  font-size: var(--text-xs);
}
.closing-section :focus-visible {
  outline-color: var(--mint-300);
}
.resource-section {
  padding-block: var(--space-7);
}
.resource-links {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: var(--space-6);
  align-items: center;
}
.resource-links .eyebrow,
.resource-links p {
  font-size: var(--text-xs);
  color: var(--fg-muted);
}
.site-footer {
  padding-block: var(--space-5);
}
.site-footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-4);
}
.footer-note {
  font: 0.6875rem / 1.5 var(--mono);
}

@media (min-width: 90rem) {
  :root {
    --site-width: 78rem;
  }
}
@media (max-width: 64rem) {
  .hero-grid {
    gap: var(--space-5);
  }
  .mascot-greeting {
    right: 0;
  }
  .speech-bubble {
    font-size: 1.375rem;
  }
  .translation-body {
    padding: var(--space-4);
  }
  .workflow-step {
    gap: var(--space-6);
  }
  .feature {
    padding: var(--space-4);
  }
  .features {
    gap: var(--space-3);
  }
  .format-strip {
    justify-content: start;
  }
  .format-strip > .eyebrow {
    flex-basis: 100%;
  }
}
@media (max-width: 48rem) {
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-6);
  }
  .hero h1.heading {
    font-size: clamp(4.25rem, 13vw, 6.5rem);
  }
  .hero-copy {
    max-width: 34rem;
  }
  .hero-scene {
    width: min(100%, 30rem);
    margin-inline: auto;
  }
  .hero-weave {
    right: -2rem;
  }
  .features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .release-compare,
  .safeguards {
    grid-template-columns: minmax(0, 1fr);
  }
  .safeguards {
    gap: var(--space-5);
  }
  .section-heading {
    align-items: start;
    flex-direction: column;
    gap: var(--space-5);
  }
  .section-heading > p {
    max-width: 30rem;
  }
  .workflow-step {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-5);
  }
  .step-copy {
    max-width: 36rem;
  }
  .screenshots {
    grid-template-columns: minmax(0, 1fr);
  }
  .gallery-hint {
    display: block;
    margin: var(--space-1) 0 0 1.1rem;
  }
  .closing-inner {
    flex-direction: column;
    align-items: start;
  }
  .resource-links {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-5);
  }
  .resource-links > div + div {
    border-top: 1px solid var(--border);
    padding-top: var(--space-4);
  }
}
@media (max-width: 36rem) {
  .container {
    padding-inline: var(--space-5);
  }
  .site-header-inner {
    gap: var(--space-2);
  }
  .site-brand .wordmark {
    font-size: 2rem;
  }
  .site-brand .quaso-mascot {
    width: 3rem;
    height: 2.4375rem;
  }
  .site-header nav {
    width: 100%;
  }
  .site-nav {
    justify-content: space-between;
    gap: var(--space-2);
    font-size: var(--text-xs);
  }
  .hero-grid {
    padding-bottom: var(--space-7);
  }
  .hero h1.heading {
    font-size: clamp(3.5rem, 15vw, 5.4rem);
  }
  .lead {
    font-size: var(--text-md);
  }
  .eyebrow {
    font-size: 0.625rem;
  }
  .mascot-greeting {
    right: 0;
  }
  .mascot-greeting img {
    width: 120px;
    height: 96px;
  }
  .hero-scene {
    padding-top: 6.5rem;
  }
  .speech-bubble {
    font-size: 1.25rem;
  }
  .scene-caption {
    margin-left: 0;
    font-size: 0.5625rem;
  }
  .format-strip {
    gap: var(--space-3);
    font-size: var(--text-xs);
  }
  .format-strip > span {
    flex-wrap: wrap;
  }
  .features {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-4);
  }
  .feature {
    padding: var(--space-5);
  }
  .release-lane {
    padding: var(--space-5);
  }
  .release-steps li {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }
  .feature-top {
    margin-bottom: var(--space-5);
  }
  .feature h3.heading {
    font-size: 2rem;
  }
  .feature-note {
    font-size: 0.6875rem;
  }
  .section-heading h2.heading {
    font-size: 3.25rem;
  }
  .terminal pre {
    padding: var(--space-4);
    font-size: 0.6875rem;
  }
  .hosting-diagram {
    margin-inline: 0;
  }
}

/* Documentation pages */

.docs-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-6);
  padding-top: var(--space-6);
  padding-bottom: var(--space-7);
}

/* The sidebar comes after the page in the HTML, so phones show the page first; wide
   screens put it on the left. */
@media (min-width: 60rem) {
  .docs-layout {
    grid-template-columns: 15rem minmax(0, 1fr);
    grid-template-areas: "nav content";
    gap: var(--space-7);
  }
  .docs-content {
    grid-area: content;
  }
  .docs-nav {
    grid-area: nav;
  }
}

.docs-content {
  min-width: 0;
}

.docs-source {
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
  font-size: var(--text-sm);
}

.docs-nav {
  align-self: start;
  font-size: var(--text-sm);
}

@media (min-width: 60rem) {
  .docs-nav {
    position: sticky;
    top: var(--space-4);
    max-height: calc(100vh - 2 * var(--space-4));
    overflow-y: auto;
    scrollbar-width: thin;
  }
}

.docs-nav h2.heading {
  margin: 0 0 var(--space-3);
  font-size: var(--heading-compact);
}

.docs-nav h3.heading {
  margin: var(--space-5) 0 var(--space-2);
  font-size: var(--text-lg);
  color: var(--fg-muted);
}

.docs-nav ul {
  margin: 0;
  padding: 0;
  list-style: none;
  border-left: 1px solid var(--border);
}

.docs-nav a {
  display: flex;
  align-items: center;
  min-height: var(--control-height);
  margin-left: -1px;
  padding: var(--space-1) 0 var(--space-1) var(--space-3);
  border-left: 2px solid transparent;
  color: var(--fg-muted);
  text-decoration: none;
}

.docs-nav a:hover {
  color: var(--fg);
}

@media (min-width: 60rem) {
  .docs-nav a {
    min-height: 2rem;
  }
}

.docs-nav a[aria-current="page"] {
  border-left-color: var(--link);
  color: var(--fg);
  font-weight: 600;
}
