/* hushdisk.com. Light tokens first; dark tokens follow the OS unless the visitor picked a theme. */
:root {
  color-scheme: light;
  --bg: #faf9f6;
  --surface: #ffffff;
  --surface-2: #f3f1ec;
  --border: #e4dfd5;
  --text: #0f172a;
  --muted: #475569;
  --accent: #b45309;
  --on-accent: #ffffff;
  --mint: #047857;
  --sky: #0369a1;
  --focus: #0369a1;
  --glow: rgba(217, 119, 6, 0.16);
  --shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 12px 32px rgba(15, 23, 42, 0.07);
  --radius: 1.25rem;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, Cantarell, "Noto Sans", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0b0e17;
    --surface: #131826;
    --surface-2: #1a2131;
    --border: #263049;
    --text: #f8fafc;
    --muted: #94a3b8;
    --accent: #f59e0b;
    --on-accent: #0b0e17;
    --mint: #10b981;
    --sky: #38bdf8;
    --focus: #38bdf8;
    --glow: rgba(245, 158, 11, 0.2);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 16px 40px rgba(0, 0, 0, 0.35);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b0e17;
  --surface: #131826;
  --surface-2: #1a2131;
  --border: #263049;
  --text: #f8fafc;
  --muted: #94a3b8;
  --accent: #f59e0b;
  --on-accent: #0b0e17;
  --mint: #10b981;
  --sky: #38bdf8;
  --focus: #38bdf8;
  --glow: rgba(245, 158, 11, 0.2);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 16px 40px rgba(0, 0, 0, 0.35);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  body, .card, .site-header { transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.6;
  overflow-wrap: break-word;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--sky); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
code { font-family: var(--mono); font-size: 0.9em; background: var(--surface-2); border: 1px solid var(--border); border-radius: 0.375rem; padding: 0.05em 0.35em; }
h1, h2, h3, h4 { line-height: 1.15; margin: 0 0 0.6em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.2rem, 1.5rem + 3.2vw, 3.9rem); letter-spacing: -0.03em; }
h2 { font-size: clamp(1.7rem, 1.35rem + 1.5vw, 2.5rem); letter-spacing: -0.02em; }
h3 { font-size: 1.15rem; }
h4 { font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin-top: 1.2em; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 0.375rem; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 1.5rem; height: 1.5rem; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.skip-link { position: absolute; left: 1rem; top: -4rem; z-index: 20; padding: 0.6rem 1rem; background: var(--accent); color: var(--on-accent); border-radius: 0.75rem; font-weight: 600; }
.skip-link:focus { top: 1rem; }
.wrap { width: min(72rem, 100%); margin: 0 auto; padding: 0 clamp(1rem, 4vw, 2rem); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.site-header .wrap { display: flex; align-items: center; gap: 1rem; min-height: 4rem; }
.brand { display: flex; align-items: center; gap: 0.6rem; font-weight: 700; font-size: 1.1rem; color: var(--text); text-decoration: none; flex: none; }
.brand img { width: 2rem; height: 2rem; }
.site-nav { flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.site-nav ul { display: flex; gap: 0.25rem; list-style: none; margin: 0; padding: 0; justify-content: flex-end; }
.site-nav a { display: block; padding: 0.45rem 0.7rem; border-radius: 999px; color: var(--muted); text-decoration: none; font-size: 0.95rem; white-space: nowrap; }
.site-nav a:hover { color: var(--text); background: var(--surface-2); }
.theme-toggle { flex: none; display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text); cursor: pointer; }
.theme-toggle .icon { width: 1.25rem; height: 1.25rem; }
.theme-toggle .i-sun { display: none; }
.theme-toggle[data-mode="dark"] .i-sun { display: block; }
.theme-toggle[data-mode="dark"] .i-moon { display: none; }

/* Buttons and pills */
.button { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 2.9rem; padding: 0.6rem 1.25rem; border-radius: 999px; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; border: 1px solid transparent; }
.button-primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 6px 20px var(--glow); }
.button-primary:hover { filter: brightness(1.06); }
.button-quiet { background: var(--surface); color: var(--text); border-color: var(--border); }
.button-quiet:hover { background: var(--surface-2); }
.pill { display: inline-block; padding: 0.15rem 0.65rem; border-radius: 999px; font-size: 0.8rem; font-weight: 600; border: 1px solid currentColor; line-height: 1.5; white-space: nowrap; }
.pill-sky { color: var(--sky); }
.pill-mint { color: var(--mint); }
.pill-amber { color: var(--accent); }

/* Sections */
section { padding: clamp(3.5rem, 8vw, 6rem) 0; scroll-margin-top: 4rem; }
section + section { border-top: 1px solid var(--border); }
.section-intro { max-width: 42rem; color: var(--muted); font-size: 1.05rem; }
.eyebrow { display: inline-flex; gap: 0.5rem; align-items: center; color: var(--accent); font-weight: 600; font-size: 0.9rem; letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 1rem; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(1.25rem, 3vw, 1.75rem); }
.grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(16rem, 100%), 1fr)); margin-top: 2rem; }
.feature .icon { color: var(--accent); width: 1.75rem; height: 1.75rem; margin-bottom: 0.9rem; }
.feature p { color: var(--muted); margin: 0; }
.note { color: var(--muted); font-size: 0.95rem; }

/* Hero */
.hero { position: relative; overflow: hidden; padding-top: clamp(3rem, 7vw, 5.5rem); }
.hero::before { content: ""; position: absolute; inset: -20% -10% auto auto; width: 60rem; height: 60rem; background: radial-gradient(closest-side, var(--glow), transparent 70%); pointer-events: none; }
.hero .wrap { position: relative; display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
@media (min-width: 900px) { .hero .wrap { grid-template-columns: 1.15fr 0.85fr; } }
.lead { font-size: clamp(1.1rem, 1rem + 0.45vw, 1.3rem); color: var(--muted); max-width: 38rem; }
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.75rem 0 1.25rem; }
.hero-visual { display: grid; justify-items: center; gap: 1.5rem; }
.hero-icon { width: min(16rem, 62vw); filter: drop-shadow(0 30px 40px rgba(11, 14, 23, 0.35)); }
@media (prefers-reduced-motion: no-preference) {
  .hero-icon { animation: float 7s ease-in-out infinite; }
  @keyframes float { 50% { transform: translateY(-10px) rotate(-1deg); } }
}

/* Mount preview */
.demo { width: min(22rem, 100%); }
.demo-row { display: flex; align-items: center; gap: 0.85rem; }
.demo-row > .icon { color: var(--accent); width: 2rem; height: 2rem; }
.demo-name { margin: 0; font-weight: 650; }
.demo-meta { margin: 0; font-size: 0.85rem; color: var(--muted); }
.demo-status { margin-left: auto; }
.demo-files { list-style: none; margin: 1rem 0 0; padding: 0; display: grid; gap: 0.35rem; max-height: 0; overflow: hidden; opacity: 0; }
.demo-files li { display: flex; gap: 0.6rem; align-items: center; padding: 0.4rem 0.6rem; border-radius: 0.6rem; background: var(--surface-2); font-size: 0.9rem; }
.demo-files .icon { width: 1.1rem; height: 1.1rem; color: var(--muted); }
.demo[data-state="mounted"] .demo-files { max-height: 12rem; opacity: 1; }
.demo-toggle { width: 100%; margin-top: 1rem; }
.demo-caption { margin: 0.75rem 0 0; font-size: 0.8rem; color: var(--muted); text-align: center; }
@media (prefers-reduced-motion: no-preference) {
  .demo-files { transition: max-height 0.4s ease, opacity 0.4s ease; }
}

/* Definition lists */
.facts { display: grid; gap: 0; margin: 2rem 0 0; }
.facts > div { display: grid; gap: 0.25rem 2rem; padding: 1rem 0; border-top: 1px solid var(--border); }
.facts > div:last-child { border-bottom: 1px solid var(--border); }
@media (min-width: 720px) { .facts > div { grid-template-columns: 13rem 1fr; } }
.facts dt { font-weight: 650; }
.facts dd { margin: 0; color: var(--muted); }

/* Platform tabs */
.tablist { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 2rem 0 1rem; }
.tablist [role="tab"] { font: inherit; font-weight: 600; padding: 0.55rem 1.1rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--muted); cursor: pointer; }
.tablist [role="tab"][aria-selected="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.platform { margin-top: 1rem; }
.platform h3 { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.platform .facts { margin-top: 1rem; }
.tabs-ready .platform h3 .platform-name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Tables */
.table-wrap { overflow-x: auto; margin-top: 2rem; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
table { border-collapse: collapse; width: 100%; }
th, td { text-align: left; padding: 0.85rem 1rem; border-bottom: 1px solid var(--border); vertical-align: top; }
tr:last-child th, tr:last-child td { border-bottom: 0; }
thead th { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); background: var(--surface-2); }
tbody th { font-weight: 600; }

/* Editions */
.planned { margin-top: 2rem; }
.planned .card h3 { display: flex; gap: 0.6rem; align-items: center; flex-wrap: wrap; }
.planned .card p { color: var(--muted); }
.planned .card p:last-child { margin-bottom: 0; }

/* Downloads */
.editions-downloads { display: grid; gap: 1rem; margin-top: 2rem; grid-template-columns: repeat(auto-fit, minmax(min(20rem, 100%), 1fr)); }
.download-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.75rem; }
.download { padding: 1rem; border-radius: 1rem; background: var(--surface-2); border: 1px solid transparent; }
.download.is-current { border-color: var(--accent); }
.download .os { font-weight: 650; margin-right: 0.5rem; }
.download .meta { color: var(--muted); font-size: 0.9rem; }
.download .current-badge { display: none; }
.download.is-current .current-badge { display: inline-block; }
.editions-downloads > .card, .download { min-width: 0; }
.checksum { display: flex; gap: 0.5rem; align-items: center; margin-top: 0.6rem; }
.checksum code { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 0.8rem; padding: 0.35rem 0.5rem; }
.editions-downloads + .note { margin-top: 1rem; }
.copy { font: inherit; font-size: 0.85rem; font-weight: 600; padding: 0.35rem 0.75rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text); cursor: pointer; flex: none; }
.empty { margin-top: 2rem; display: flex; gap: 1rem; align-items: flex-start; }
.empty .icon { color: var(--accent); width: 2rem; height: 2rem; }
.empty p:last-child { margin-bottom: 0; }

/* Changelog */
.filters { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 2rem 0 0.5rem; }
.filters button { font: inherit; font-size: 0.9rem; font-weight: 600; padding: 0.4rem 0.95rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--muted); cursor: pointer; }
.filters button[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.filter-status { font-size: 0.9rem; color: var(--muted); min-height: 1.5em; }
.releases { list-style: none; margin: 1rem 0 0; padding: 0; display: grid; gap: 0.75rem; }
.release { padding: 0; }
.release summary { list-style: none; cursor: pointer; padding: 1rem 1.25rem; display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.release summary::-webkit-details-marker { display: none; }
.release summary::after { content: ""; margin-left: auto; width: 0.6rem; height: 0.6rem; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); }
.release[open] summary::after { transform: rotate(-135deg); }
.release summary h3 { margin: 0; font-size: 1.05rem; }
.release time { color: var(--muted); font-size: 0.9rem; }
.release-body { padding: 0 1.25rem 1.25rem; }
.release-body h4:first-child { margin-top: 0; }
.release-body ul { margin: 0 0 0.5rem; padding-left: 1.2rem; color: var(--muted); }
.release-body li + li { margin-top: 0.35rem; }

/* FAQ */
.faq-list { display: grid; gap: 0.75rem; margin-top: 2rem; }
.faq { padding: 0; }
.faq summary { list-style: none; cursor: pointer; padding: 1.1rem 1.25rem; display: flex; gap: 1rem; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary h3 { margin: 0; font-size: 1.05rem; flex: 1; }
.faq summary::after { content: "+"; font-size: 1.4rem; line-height: 1; color: var(--accent); }
.faq[open] summary::after { content: "\2212"; }
.faq .answer { padding: 0 1.25rem 1.25rem; color: var(--muted); }
.faq .answer p:last-child { margin-bottom: 0; }

/* Support and footer */
.support { display: grid; gap: 1.5rem; align-items: center; }
@media (min-width: 720px) { .support { grid-template-columns: 1fr auto; } }
.site-footer { border-top: 1px solid var(--border); padding: 2.5rem 0 3rem; color: var(--muted); font-size: 0.9rem; }
.site-footer .wrap { display: grid; gap: 0.75rem; }
.site-footer p { margin: 0; }
.footer-brand { display: flex; align-items: center; gap: 0.5rem; color: var(--text); font-weight: 650; }
.footer-brand img { width: 1.5rem; height: 1.5rem; }

@media (max-width: 719px) {
  .site-nav ul { justify-content: flex-start; }
  .brand span { display: none; }
  th, td { padding: 0.7rem 0.6rem; font-size: 0.92rem; }
  thead th { font-size: 0.72rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
#download .wrap > h3 { margin-top: 2.5rem; }
.planned + .note { margin-top: 1rem; }
