/* Site kit: header, buttons, the overview sections and the download page. Tokens live on :root so the header and
   footer read the same on every page; the .mx class adds the overview typography where a page opts in.

   Contrast: every token used for normal-size text clears 4.5:1 on the cream background (--mx-muted 6.1:1,
   --mx-brand-text 5.0:1, --mx-ink-2 9.6:1). The lighter brand terracotta (--mx-brand) is kept for large decorative
   areas, borders and hover states, never for small text. */

:root {
  --mx-bg: #F4F2EA; --mx-bg-2: #EEECE2; --mx-surface: #FFFFFF; --mx-line: #D6D2C4; --mx-line-strong: #1F1E1D;
  --mx-ink: #1F1E1D; --mx-ink-2: #4A4740; --mx-muted: #5C5952;
  --mx-brand: #C15F3C; --mx-brand-text: #A84D2D; --mx-brand-dark: #A84D2D; --mx-brand-deeper: #8F3F22; --mx-brand-tint: #F2D9CC;
  --mx-green: #CDE8BF; --mx-green-ink: #2F6B2A; --mx-blue: #C6DAF0; --mx-blue-ink: #2F5FA0;
  --mx-display: "Inter", system-ui, sans-serif; --mx-body: "Inter", system-ui, sans-serif; --mx-mono: "JetBrains Mono", Consolas, monospace;
  --mx-radius: 8px; --mx-pad: clamp(1.25rem, 5vw, 4rem); --mx-max: 84rem; --mx-header-h: 3.75rem;
}

.mx { background: var(--mx-bg); color: var(--mx-ink); font-family: var(--mx-body); line-height: 1.55; overflow-x: clip; }
.mx h1, .mx h2, .mx h3 { font-family: var(--mx-display); font-weight: 700; letter-spacing: -0.025em; line-height: 1.05; margin: 0 0 0.6em; }
.mx h2 { font-size: clamp(1.7rem, 3.2vw, 2.6rem); }
.mx h3 { font-size: 1.15rem; }
.mx p { margin: 0 0 1rem; }
.mx kbd { font-family: var(--mx-mono); font-size: 0.8em; padding: 0.15em 0.5em; border: 1px solid var(--mx-line-strong); border-bottom-width: 3px; border-radius: 5px; background: var(--mx-surface); color: var(--mx-ink); }
.mx-kicker { font-family: var(--mx-mono); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mx-brand-text); margin: 0 0 1rem; }
/* The sticky header would otherwise cover the top of a section reached through a #fragment link. */
.mx section[id], .mx [id].mx-everything, .mx [id].mx-connect, .mx [id].mx-pdf, .mx [id].mx-md, .mx [id].mx-keys, .mx [id].mx-ai, .mx [id].mx-download { scroll-margin-top: calc(var(--mx-header-h) + 0.5rem); }

/* Header */
.mx-header { position: sticky; top: 0; z-index: 20; height: var(--mx-header-h); display: flex; align-items: center; gap: 0.6rem; padding: 0 var(--mx-pad); background: color-mix(in srgb, var(--mx-bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--mx-line); }
.mx-brand { display: inline-flex; align-items: center; gap: 0.6rem; margin-right: 0.4rem; font-family: var(--mx-mono); font-weight: 700; color: var(--mx-ink); text-decoration: none; }
.mx-brand:hover { text-decoration: none; }
.mx-brand img { border-radius: 6px; }
.mx-nav { display: flex; gap: 0.25rem; margin-left: auto; font-family: var(--mx-mono); font-size: 0.85rem; }
.mx-nav a { padding: 0.45rem 0.7rem; color: var(--mx-ink-2); text-decoration: none; }
.mx-nav a:hover { color: var(--mx-brand-text); text-decoration: none; }
/* Compact menu: a <details> disclosure that replaces the inline nav on narrow screens. */
.mx-menu { display: none; position: relative; margin-left: auto; font-family: var(--mx-mono); font-size: 0.85rem; }
.mx-menu summary { list-style: none; cursor: pointer; padding: 0.45rem 0.7rem; border: 1px solid var(--mx-line); border-radius: var(--mx-radius); color: var(--mx-ink-2); }
.mx-menu summary::-webkit-details-marker { display: none; }
.mx-menu summary::after { content: " ▾"; }
.mx-menu[open] summary::after { content: " ▴"; }
.mx-menu nav { position: absolute; right: 0; top: calc(100% + 0.4rem); min-width: 12rem; display: grid; padding: 0.4rem; background: var(--mx-surface); border: 1px solid var(--mx-line); border-radius: var(--mx-radius); box-shadow: 0 12px 30px -12px rgba(31, 30, 29, 0.35); }
.mx-menu nav a { padding: 0.55rem 0.8rem; color: var(--mx-ink); text-decoration: none; border-radius: 6px; }
.mx-menu nav a:hover { background: var(--mx-bg-2); color: var(--mx-brand-text); text-decoration: none; }
@media (max-width: 56rem) { .mx-nav { display: none; } .mx-menu { display: block; } }
@media (max-width: 40rem) { .mx-header { gap: 0.4rem; } .mx-header .mx-btn { padding: 0.45rem 0.7rem; font-size: 0.8rem; } }
@media (max-width: 32rem) { .mx-brand span { display: none; } .mx-header .mx-btn--alt { display: none; } }

/* Buttons. Every variant keeps the same box (border included), so two buttons side by side are the same size.
   White on the large button needs the darker terracotta: 5.6:1, where the lighter brand hue gives 4.2:1. */
.mx-btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 2.6rem; padding: 0.5rem 1.05rem; border: 1px solid transparent; border-radius: var(--mx-radius); background: var(--mx-ink); color: var(--mx-bg); font-family: var(--mx-mono); font-weight: 700; font-size: 0.9rem; line-height: 1.2; white-space: nowrap; text-decoration: none; cursor: pointer; transition: background 140ms, transform 140ms; }
.mx-btn:hover { background: var(--mx-brand-dark); transform: translateY(-1px); text-decoration: none; }
.mx-btn--lg { min-height: 3.4rem; padding: 0.8rem 1.6rem; font-size: 1.05rem; background: var(--mx-brand-dark); color: #fff; }
.mx-btn--lg:hover { background: var(--mx-brand-deeper); }
.mx-btn--alt { background: var(--mx-green); color: var(--mx-ink); border-color: var(--mx-line-strong); }
.mx-btn--alt:hover { background: var(--mx-blue); }

/* Overview hero: the filter box beside its answers */
.home-hero { max-width: var(--mx-max); margin: 0 auto; padding: clamp(3rem, 6vw, 5rem) var(--mx-pad) clamp(2rem, 5vw, 4rem); display: grid; gap: 2.5rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 64rem) { .home-hero { grid-template-columns: 1fr 1.1fr; } .home-stage { position: sticky; top: calc(var(--mx-header-h) + 1.5rem); } }
.home-hero h1 { font-family: "Archivo Hero", "Archivo", "Arial Black", sans-serif; font-stretch: 110%; font-weight: 800; font-size: clamp(2.6rem, 5.2vw, 4.4rem); letter-spacing: -0.035em; line-height: 0.98; margin-bottom: 0.7em; }
.home .mx-filter { font-size: clamp(1rem, 1.6vw, 1.3rem); }
.home .mx-queries { grid-template-columns: 1fr 1fr; font-size: 0.72rem; gap: 0.4rem; }
.home .mx-query { padding: 0.45rem 0.6rem; }
@media (max-width: 30rem) { .home .mx-queries { grid-template-columns: 1fr; } }
.home-band { border-top: 1px solid var(--mx-line); border-bottom: 1px solid var(--mx-line); }
.home-band--blue { background: color-mix(in srgb, var(--mx-blue) 45%, var(--mx-bg)); }
.home-band--blue .mx-kicker { color: var(--mx-blue-ink); }
.home-band--paper { background: var(--mx-bg-2); }
.home-band--green { background: color-mix(in srgb, var(--mx-green) 45%, var(--mx-bg)); }
.home-band--green .mx-kicker { color: var(--mx-green-ink); }
.home-band--green .mx-fkeys kbd { background: var(--mx-surface); }
.home .mx-card { border-radius: 12px; }
.home .mx-download h2 { font-size: clamp(1.3rem, 2.4vw, 1.95rem); }

/* Typing filter box */
.mx-typer { text-align: left; }
.mx-filter { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 0.9rem; padding: 0.9rem 1.2rem; background: var(--mx-surface); border: 2px solid var(--mx-line-strong); border-radius: var(--mx-radius); box-shadow: 8px 8px 0 var(--mx-brand-tint); font-family: var(--mx-mono); font-size: clamp(1.1rem, 2.4vw, 1.75rem); }
.mx-filter__icon { color: var(--mx-muted); font-size: 1.2em; }
.mx-filter__text { min-height: 1.4em; white-space: nowrap; overflow: hidden; }
/* The caret blinks under reduced motion too: a blink is not spatial motion, and a still caret reads as a broken box. */
.mx-filter__caret { display: inline-block; width: 0.55em; height: 1.05em; margin-left: 0.1em; vertical-align: -0.15em; background: var(--mx-brand); animation: mx-blink 1s steps(2) infinite; }
@keyframes mx-blink { to { opacity: 0; } }
.mx-queries { list-style: none; margin: 1rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); gap: 0.5rem; font-size: 0.75rem; }
.mx-queries li { margin: 0; display: grid; }
/* Each example is a real button: focusable, Enter/Space, aria-pressed for the selected one. */
.mx-query { appearance: none; font: inherit; text-align: left; width: 100%; cursor: pointer; padding: 0.55rem 0.7rem; border-radius: var(--mx-radius); border: 1px solid var(--mx-line); background: var(--mx-surface); color: inherit; display: grid; gap: 0.15rem; transition: background 140ms, border-color 140ms; }
.mx-query b { font-family: var(--mx-mono); font-size: 0.78rem; color: var(--mx-ink); }
.mx-query span { color: var(--mx-muted); }
.mx-query:hover { border-color: var(--mx-muted); }
.mx-query:focus-visible { outline: 2px solid var(--mx-brand-text); outline-offset: 2px; }
.mx-query.is-active { background: var(--mx-brand-tint); border-color: var(--mx-brand); }
.mx-queries li:nth-child(2) .mx-query.is-active { background: var(--mx-green); border-color: var(--mx-green-ink); }
.mx-queries li:nth-child(4) .mx-query.is-active { background: var(--mx-blue); border-color: var(--mx-blue-ink); }
.mx-stage { position: relative; margin-top: 1.5rem; aspect-ratio: 16 / 9.5; border: 1px solid var(--mx-line); border-radius: var(--mx-radius); overflow: hidden; background: var(--mx-bg-2); box-shadow: 0 30px 50px -30px rgba(31, 30, 29, 0.45); }
.mx-stage__shot { position: absolute; inset: 0; margin: 0; opacity: 0; transition: opacity 600ms ease, transform 900ms cubic-bezier(.2,.7,.2,1); transform: scale(1.02); }
.mx-stage__shot.is-active { opacity: 1; transform: none; }
.mx-stage__shot img { width: 100%; height: 100%; object-fit: cover; object-position: top left; display: block; }
/* Reduced motion keeps the crossfade and drops the zoom. */
@media (prefers-reduced-motion: reduce) { .mx-stage__shot { transition: opacity 600ms ease; transform: none; } }
/* The overview's stage sits in the hero grid and shows a taller crop; it must follow the generic .mx-stage rule
   because both selectors have the same specificity and the later one wins. */
.home-stage { margin-top: 0; aspect-ratio: 16 / 11; }

/* Frames. Every screenshot comes from a PNG master in doc/screenshots via tools/convert-screenshots.ps1, so the
   crops below are the only place the site reshapes one. .mx-frame clips at the corner radius, which also hides the
   few pixels of window border and rounded-corner backdrop the masters carry at their edges. */
.mx-frame { margin: 0; background: var(--mx-surface); border: 1px solid var(--mx-line); border-radius: var(--mx-radius); overflow: hidden; box-shadow: 0 30px 50px -30px rgba(31, 30, 29, 0.45); }
.mx-frame img { display: block; width: 100%; height: auto; }
.mx-frame figcaption { font-family: var(--mx-mono); font-size: 0.76rem; color: var(--mx-muted); padding: 0.6rem 1rem; border-top: 1px solid var(--mx-line); }

/* Everything grid */
.mx-everything { max-width: var(--mx-max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--mx-pad); }
.mx-cards { display: grid; gap: 1.25rem; grid-template-columns: 1fr; margin-top: 1.5rem; }
@media (min-width: 48rem) { .mx-cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 80rem) { .mx-cards { grid-template-columns: repeat(3, 1fr); } }
.mx-card { background: var(--mx-surface); border: 1px solid var(--mx-line); border-radius: var(--mx-radius); overflow: hidden; transition: border-color 150ms, transform 150ms; }
.mx-card:hover { border-color: var(--mx-brand); transform: translateY(-2px); }
.mx-card figure { margin: 0; border-bottom: 1px solid var(--mx-line); }
.mx-card img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: left top; }
.mx-card h3 { margin: 1rem 1.2rem 0.3rem; }
.mx-card p { margin: 0 1.2rem 1.2rem; color: var(--mx-ink-2); font-size: 0.92rem; }
.mx-card--green h3 { color: var(--mx-green-ink); }
.mx-card--blue h3 { color: var(--mx-blue-ink); }
.mx-card--green:hover { border-color: var(--mx-green-ink); }
.mx-card--blue:hover { border-color: var(--mx-blue-ink); }

/* PDF detour */
.mx-pdf { display: grid; grid-template-columns: 1fr; gap: 2.5rem; align-items: center; max-width: var(--mx-max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--mx-pad); }
@media (min-width: 60rem) { .mx-pdf { grid-template-columns: 7fr 5fr; } .mx-pdf--flip .mx-pdf__copy { order: -1; } }
.mx-pdf__copy p { color: var(--mx-ink-2); }

/* Connect */
.mx-connect { max-width: var(--mx-max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--mx-pad); display: grid; gap: 2rem; grid-template-columns: 1fr; }
@media (min-width: 60rem) { .mx-connect { grid-template-columns: 5fr 7fr; } .mx-connect .mx-secure { grid-column: 1 / -1; } }
.mx-connect__head p { color: var(--mx-ink-2); max-width: 36rem; }
.mx-frame--connect img { aspect-ratio: 16 / 10; object-fit: cover; object-position: 55% top; }
/* transfers-window.png is a 1800x970 dialog, not a browser window, so it is shown whole rather than cropped.
   It stacks under the Connect dialog in the same column: two figures of the same width read as one exhibit,
   where a centred full-width block would line up with neither. */
.mx-frame--transfers img { display: block; }
@media (min-width: 60rem) { .mx-connect .mx-frame--transfers { grid-column: 2; } }
.mx-secure { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
.mx-secure li { background: var(--mx-surface); border: 1px solid var(--mx-line); border-radius: var(--mx-radius); padding: 1rem 1.1rem; display: grid; gap: 0.3rem; border-top: 3px solid var(--mx-blue-ink); }
.mx-secure b { font-family: var(--mx-display); font-weight: 700; }
.mx-secure span { color: var(--mx-ink-2); font-size: 0.9rem; }

/* Optional AI */
.mx-ai { max-width: var(--mx-max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--mx-pad); display: grid; gap: 2rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 60rem) { .mx-ai { grid-template-columns: 6fr 6fr; } .mx-ai .mx-providers { grid-column: 1 / -1; } }
.mx-ai__head > p { color: var(--mx-ink-2); max-width: 36rem; }
.mx-ai__gains { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; gap: 0.6rem; }
.mx-ai__gains li { display: grid; gap: 0.15rem; padding: 0.7rem 0; border-top: 1px solid var(--mx-line); }
.mx-ai__gains b { font-family: var(--mx-display); font-weight: 700; }
.mx-ai__gains span { color: var(--mx-ink-2); font-size: 0.92rem; }
.mx-ai__gains code { font-family: var(--mx-mono); font-size: 0.85em; background: var(--mx-surface); border: 1px solid var(--mx-line); border-radius: 4px; padding: 0.05em 0.35em; }
.mx-frame--ai img { aspect-ratio: 4 / 3; object-fit: cover; object-position: left top; }
.mx-providers { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
.mx-providers li { background: var(--mx-surface); border: 1px solid var(--mx-line); border-radius: var(--mx-radius); padding: 1rem 1.1rem; display: grid; gap: 0.3rem; border-top: 3px solid var(--mx-line-strong); }
.mx-providers b { font-family: var(--mx-display); font-weight: 700; }
.mx-providers span { color: var(--mx-ink-2); font-size: 0.9rem; }
.mx-providers__local { background: var(--mx-green); border-color: var(--mx-green-ink); }
.mx-providers__local b { color: var(--mx-green-ink); }

/* Markdown, built in. The section used to draw its own source/rendered pair in HTML; it now shows
   doc/screenshots/markdown-commander-readme.png in a plain .mx-frame, so only the layout and the cards live here. */
.mx-md { max-width: var(--mx-max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--mx-pad); display: grid; gap: 2rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 60rem) { .mx-md { grid-template-columns: 5fr 7fr; } .mx-md__cards { grid-column: 1 / -1; } }
.mx-md__head p { color: var(--mx-ink-2); max-width: 36rem; }
.mx-md__cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
.mx-md__cards li { background: var(--mx-surface); border: 1px solid var(--mx-line); border-radius: var(--mx-radius); padding: 1rem 1.1rem; display: grid; gap: 0.3rem; border-top: 3px solid var(--mx-brand); }
.mx-md__cards b { font-family: var(--mx-display); font-weight: 700; }
.mx-md__cards span { color: var(--mx-ink-2); font-size: 0.9rem; }

/* Keyboard */
.mx-keys { max-width: var(--mx-max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--mx-pad); }
.mx-keys__head { max-width: 40rem; margin-bottom: 2rem; }
.mx-keys__head p { color: var(--mx-ink-2); }
.mx-fkeys { list-style: none; margin: 0 0 2rem; padding: 0; display: grid; grid-template-columns: repeat(9, 1fr); gap: 0.5rem; }
.mx-fkeys li { display: grid; gap: 0.35rem; text-align: center; margin: 0; }
.mx-fkeys kbd { display: block; font-family: var(--mx-mono); font-size: clamp(0.9rem, 2vw, 1.4rem); font-weight: 700; padding: clamp(0.5rem, 1.6vw, 1rem) 0; background: var(--mx-surface); border-radius: 8px; }
.mx-fkeys span { font-family: var(--mx-mono); font-size: 0.72rem; color: var(--mx-muted); }
@media (prefers-reduced-motion: no-preference) {
  /* Start the nine key animations when their section is revealed, not while it is far below the viewport. */
  .mx-fkeys kbd { animation: mx-press 5.4s ease-in-out infinite; animation-play-state: paused; }
  .mx-keys.in .mx-fkeys kbd { animation-play-state: running; }
  .mx-fkeys li:nth-child(2) kbd { animation-delay: 0.6s; } .mx-fkeys li:nth-child(3) kbd { animation-delay: 1.2s; } .mx-fkeys li:nth-child(4) kbd { animation-delay: 1.8s; } .mx-fkeys li:nth-child(5) kbd { animation-delay: 2.4s; } .mx-fkeys li:nth-child(6) kbd { animation-delay: 3s; } .mx-fkeys li:nth-child(7) kbd { animation-delay: 3.6s; } .mx-fkeys li:nth-child(8) kbd { animation-delay: 4.2s; } .mx-fkeys li:nth-child(9) kbd { animation-delay: 4.8s; }
}
@keyframes mx-press { 0%, 8%, 100% { transform: none; border-bottom-width: 3px; } 4% { transform: translateY(2px); border-bottom-width: 1px; background: var(--mx-green); } }
@media (max-width: 40rem) { .mx-fkeys { grid-template-columns: repeat(3, 1fr); } }
.mx-chords { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.5rem 2rem; grid-template-columns: repeat(auto-fit, minmax(20rem, 1fr)); }
.mx-chords li { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; font-size: 0.92rem; color: var(--mx-ink-2); padding: 0.6rem 0; border-bottom: 1px solid var(--mx-line); margin: 0; }
.mx-chords span { margin-left: auto; text-align: right; }

/* Download call to action at the end of the overview */
.mx-download { max-width: var(--mx-max); margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--mx-pad); text-align: center; }
.mx-download__inner { max-width: 40rem; margin: 0 auto; }
.mx-download__brand { display: flex; align-items: center; justify-content: center; gap: 1rem; margin: 0 0 2rem; font-family: var(--mx-mono); font-weight: 700; font-size: clamp(2rem, 3.75vw, 3rem); letter-spacing: -0.02em; }
.mx-download__brand img { width: clamp(3.75rem, 6.25vw, 5.6rem); height: auto; border-radius: 14px; }
.mx-download__free { color: var(--mx-green-ink); }
.mx-download__exe { color: var(--mx-blue-ink); }

/* Download page: two independent choices side by side, the paid Store and the free direct download, each with its
   facts and its price stated before the button. */
.dl { max-width: 64rem; margin: 0 auto; padding: clamp(3rem, 7vw, 6rem) var(--mx-pad); text-align: center; }
.dl h1 { font-size: clamp(2rem, 4.2vw, 3.2rem); }
.dl .dl__lead { color: var(--mx-ink-2); font-size: 1.1rem; max-width: 36rem; margin: 0 auto 2rem; text-align: center; }
.dl__choices { display: grid; gap: 1.5rem; grid-template-columns: 1fr; text-align: left; margin-top: 2rem; }
.dl__choices--direct { max-width: 52rem; margin-inline: auto; }
@media (min-width: 56rem) { .dl__choices--with-store { grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); align-items: start; } }
.dl__choice { min-width: 0; padding: 1.5rem; background: var(--mx-surface); border: 1px solid var(--mx-line); border-radius: 12px; }
.dl__choice h2 { font-size: clamp(1.3rem, 2.2vw, 1.7rem); }
.dl__choice--store { border-top: 4px solid var(--mx-blue-ink); }
.dl__choice:not(.dl__choice--store) { border-top: 4px solid var(--mx-green-ink); }
.dl__choice-kicker { font-family: var(--mx-mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mx-muted); margin: 0 0 0.6rem; }
.dl__store { margin: 1rem 0 0; }
.dl__store .mx-btn, .dl__file .mx-btn { width: 100%; white-space: normal; }
.dl__note { font-size: 0.92rem; color: var(--mx-ink-2); }
.dl__file { margin: 0.5rem 0 0; }
.dl__facts { margin: 1.25rem 0 0; padding: 0; display: grid; font-size: 0.92rem; }
.dl__facts div { display: grid; grid-template-columns: 6.5rem 1fr; gap: 1rem; padding: 0.5rem 0; border-top: 1px solid var(--mx-line); }
.dl__facts dt { font-family: var(--mx-mono); font-size: 0.75rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--mx-muted); align-self: center; }
.dl__facts dd { margin: 0; min-width: 0; overflow-x: auto; }
.dl__facts code { font-family: var(--mx-mono); font-size: 0.78rem; white-space: nowrap; }
.dl__checksum { border-top: 1px solid var(--mx-line); border-bottom: 1px solid var(--mx-line); }
.dl__checksum summary { position: relative; display: grid; grid-template-columns: 6.5rem minmax(0, 1fr); gap: 0.5rem 1rem; padding: 0.75rem 0; cursor: pointer; list-style: none; }
.dl__checksum summary::-webkit-details-marker { display: none; }
.dl__checksum summary:focus-visible, .dl__copy-actions button:focus-visible { outline: 2px solid var(--mx-blue-ink); outline-offset: 4px; }
.dl__hash-label { font-family: var(--mx-mono); font-size: 0.75rem; letter-spacing: 0.06em; color: var(--mx-muted); align-self: center; }
.dl__checksum summary code { font-family: var(--mx-mono); font-size: 0.78rem; white-space: normal; overflow-wrap: anywhere; }
.dl__verify-toggle { grid-column: 2; font-size: 0.85rem; color: var(--mx-brand-text); }
.dl__verify-toggle::before { content: '▸ '; }
.dl__checksum[open] .dl__verify-toggle::before { content: '▾ '; }
.dl__verification { padding-bottom: 1rem; }
.dl__verification .dl__verify { margin-top: 0.75rem; }
.dl__copy-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 0.75rem; margin-top: 0.75rem; font-size: 0.85rem; }
.dl__copy-actions button { border: 1px solid var(--mx-line); border-radius: var(--mx-radius); background: var(--mx-bg-2); color: var(--mx-ink); padding: 0.4rem 0.75rem; cursor: pointer; font: inherit; }
@media (max-width: 35rem) {
  .dl__facts div { grid-template-columns: 4.5rem minmax(0, 1fr); gap: 0.5rem; }
  .dl__checksum summary { grid-template-columns: minmax(0, 1fr); }
  .dl__verify-toggle { grid-column: 1; }
}
.dl__verify { font-size: 0.9rem; color: var(--mx-ink-2); margin: 1.25rem 0 0; }
.dl__verify + .dl__verify { margin-top: 0; }
.dl__command { margin: 0.5rem 0 0.75rem; padding: 0.7rem 1rem; font-family: var(--mx-mono); font-size: 0.85rem; background: var(--mx-bg-2); border: 1px solid var(--mx-line); border-radius: var(--mx-radius); overflow-x: auto; }
.dl__command code { font-family: inherit; font-size: inherit; white-space: pre-wrap; overflow-wrap: anywhere; }
.dl__small { font-size: 0.85rem; color: var(--mx-muted); margin: 1.25rem 0 0; }
.dl__preview { margin: 2rem auto 0; max-width: 40rem; padding: 1.25rem 1.5rem; text-align: left; background: var(--mx-bg-2); border: 1px dashed var(--mx-line-strong); border-radius: 12px; }
.dl__preview h2 { font-size: 1.3rem; }
.dl__preview code { font-family: var(--mx-mono); font-size: 0.78rem; overflow-wrap: anywhere; }
.dl__version { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 1.25rem; }
.dl__notes { font-family: var(--mx-mono); font-size: 0.85rem; }
.dl__notes a { color: var(--mx-brand-text); }
.dl .notice { text-align: left; }

/* Footer */
.mx-footer { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; padding: 1.5rem var(--mx-pad); border-top: 1px solid var(--mx-line); background: var(--mx-bg); color: var(--mx-muted); font-size: 0.85rem; font-family: var(--mx-mono); }
.mx-footer nav { display: flex; gap: 1rem; }
.mx-footer a { color: var(--mx-muted); text-decoration: none; }
.mx-footer a:hover { color: var(--mx-brand-text); }

/* Reveal (site.js initReveal): sections fade up as they scroll in, [data-stagger] children 0.1s apart and
   [data-hero-fade] children on load. The hidden states apply only once the script has attached its observer and
   set data-fx on the same [data-spec] root, so nothing is invisible without JavaScript or when the script fails:
   the disposer removes the flag again. Reduced motion reduces rather than removes: the fades stay, the
   movement (the translateY below) goes. */
[data-spec][data-fx] section { opacity: 0; transition: opacity 0.6s ease-out, transform 0.6s ease-out; }
[data-spec][data-fx] section.in { opacity: 1; transform: none; }
[data-spec][data-fx] [data-stagger] > * { opacity: 0; transition: opacity 0.6s ease-out, transform 0.6s ease-out; }
[data-spec][data-fx] [data-stagger].in > * { opacity: 1; transform: none; }
[data-spec][data-fx] [data-hero-fade] > * { opacity: 0; transition: opacity 0.7s ease-out, transform 0.7s ease-out; }
[data-spec][data-fx] [data-hero-fade].in > * { opacity: 1; transform: none; }
@media (prefers-reduced-motion: no-preference) {
  [data-spec][data-fx] section { transform: translateY(24px); }
  [data-spec][data-fx] [data-stagger] > * { transform: translateY(30px); }
  [data-spec][data-fx] [data-hero-fade] > * { transform: translateY(16px); }
}

/* Keep delays in the stylesheet: setting transitionDelay from JavaScript is an inline style and Firefox
   correctly rejects it under the site's style-src 'self' Content Security Policy. */
[data-spec][data-fx] [data-hero-fade] > :nth-child(2),
[data-spec][data-fx] [data-stagger] > :nth-child(2) { transition-delay: 0.1s; }
[data-spec][data-fx] [data-stagger] > :nth-child(3) { transition-delay: 0.2s; }
[data-spec][data-fx] [data-stagger] > :nth-child(4) { transition-delay: 0.3s; }
[data-spec][data-fx] [data-stagger] > :nth-child(5) { transition-delay: 0.4s; }
[data-spec][data-fx] [data-stagger] > :nth-child(6) { transition-delay: 0.5s; }
[data-spec][data-fx] [data-stagger] > :nth-child(7) { transition-delay: 0.6s; }
[data-spec][data-fx] [data-stagger] > :nth-child(8) { transition-delay: 0.7s; }
[data-spec][data-fx] [data-stagger] > :nth-child(9) { transition-delay: 0.8s; }

/* The mobile hero is the LCP content: don't hide already-rendered text when the script attaches.
   Desktop keeps its entrance; lower sections and screenshot selection keep their existing transitions. */
@media (max-width: 63.999rem) {
  [data-spec][data-fx] .home-hero,
  [data-spec][data-fx] .home-hero [data-hero-fade] > * { opacity: 1; transform: none; transition: none; }
}
