:root {
  color-scheme: dark;
  --page: #1f242b;
  --surface: #282f38;
  --surface-hover: #2e3640;
  --tint: #232a33;
  --ink: #ebeff5;
  --body-copy: #c6d0dc;
  --muted: #9aa7b8;
  --line: #3b4552;
  --accent: #79c0ff;
  --accent-hover: #a5d6ff;
  --gold: #f5c54a;
  --gold-hover: #f8d36f;
  --gold-ink: #171b20;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --radius: 16px;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; background: var(--page); }
body {
  margin: 0;
  background:
    radial-gradient(circle at 16% 0%, rgba(121, 192, 255, 0.09), transparent 30rem),
    radial-gradient(circle at 86% 10%, rgba(245, 197, 74, 0.06), transparent 28rem),
    var(--page);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.65;
  -webkit-tap-highlight-color: rgba(245, 197, 74, 0.2);
}
::selection { background: #334e68; color: #ffffff; }
[hidden] { display: none !important; }
button, input, select { font: inherit; }
button, a, input, select, summary { touch-action: manipulation; }
button, select { cursor: pointer; }
button { color: inherit; }
a { color: var(--accent); text-underline-offset: 4px; }
a:hover { color: var(--accent-hover); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }
img, svg { display: block; max-width: 100%; }
svg { flex-shrink: 0; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { color: var(--ink); font-weight: 650; line-height: 1.15; text-wrap: balance; }
h1 { font-size: clamp(2.4rem, 5vw, 3.75rem); letter-spacing: -0.055em; }
h2 { font-size: clamp(1.65rem, 3vw, 2rem); letter-spacing: -0.04em; }
h3 { font-size: 1.18rem; letter-spacing: -0.025em; }
p, li, dd { text-wrap: pretty; }
[id] { scroll-margin-top: 24px; }
code { font-family: var(--mono); font-size: 0.82em; overflow-wrap: anywhere; }
code:not(.hash-value) { padding: 2px 6px; border: 1px solid var(--line); border-radius: 5px; background: var(--tint); color: var(--ink); }
main { min-width: 0; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 50;
  padding: 12px 20px;
  border-radius: 8px;
  background: var(--gold);
  color: var(--gold-ink);
  font-weight: 600;
  text-decoration: none;
  transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); color: var(--gold-ink); }
.layout-container { display: flex; min-height: 100svh; flex-direction: column; }
.page-container, .header-inner, .site-footer-inner {
  width: min(1160px, 100% - 80px);
  margin-inline: auto;
}
.page-container { flex: 1; padding-block: 48px 80px; }
.site-header {
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top);
  background: rgba(31, 36, 43, 0.86);
  backdrop-filter: blur(10px);
}
.header-inner { display: flex; align-items: center; gap: 40px; min-height: 88px; }
.website-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-size: 26px;
  font-weight: 750;
  letter-spacing: -1.2px;
}
.website-link:hover { color: var(--accent-hover); }
.logo-mark { width: 35px; height: 35px; object-fit: contain; }
.main-nav { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.nav-item {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  padding: 8px 15px;
  border: 1px solid transparent;
  border-radius: 7px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 550;
  text-decoration: none;
}
.nav-item:hover { background: var(--surface); border-color: var(--line); color: var(--ink); }
.nav-item[aria-current] { background: var(--surface); border-color: #4b5868; color: var(--ink); }
.header-guide { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; text-decoration: none; min-height: 44px; }
.icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.icon.small { width: 16px; height: 16px; }
.eyebrow { color: var(--gold); font: 600 11px/1.5 var(--mono); letter-spacing: 0.13em; text-transform: uppercase; }
.eyebrow-dot { display: inline-block; width: 7px; height: 7px; margin-right: 9px; border-radius: 50%; background: var(--gold); }
.lede { max-width: 59ch; color: var(--body-copy); font-size: 17px; line-height: 1.75; }
.button-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 11px 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  text-align: center;
  text-decoration: none;
}
.button:hover { border-color: var(--accent); background: var(--surface-hover); color: var(--ink); }
.button[data-copied="true"], .copy-button[data-copied="true"] { border-color: var(--gold); color: var(--gold); }
.button.primary { border-color: var(--gold); background: var(--gold); color: var(--gold-ink); }
.button.primary:hover { border-color: var(--gold-hover); background: var(--gold-hover); color: var(--gold-ink); }
.button.small { min-height: 40px; padding: 8px 13px; font-size: 12px; }
.text-link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 13px; font-weight: 600; text-decoration: none; }
.text-link:hover { text-decoration: underline; }
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 24px; }
.section-heading .eyebrow { margin-bottom: 8px; }
.section-heading > p { color: var(--muted); font-size: 13px; }
.section-block { margin-top: 64px; }
.type-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid #2f4f44;
  border-radius: 12px;
  background: #1f332c;
  color: #7ee2b8;
  font-size: 20px;
  font-weight: 600;
}
.type-icon.images { background: #352b20; border-color: #54422e; color: #f6c177; }
.type-icon.audio { background: #1f2f3f; border-color: #314b63; color: #8cc8ff; }
.type-icon.metadata { background: #2e273b; border-color: #493d5e; color: #d2a8ff; }
.badge { display: inline-flex; align-items: center; padding: 3px 9px; border: 1px solid var(--line); border-radius: 5px; background: var(--tint); color: var(--body-copy); font: 11px/1.5 var(--mono); }
.dataset-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.dataset-card {
  display: flex;
  position: relative;
  flex-direction: column;
  min-width: 0;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.16);
}
.dataset-card:hover { border-color: #5b6d82; background: var(--surface-hover); color: var(--ink); }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 23px; }
.dataset-card h3 { font-size: 20px; overflow-wrap: anywhere; }
.card-slug { margin-top: 4px; color: var(--muted); font: 11px/1.6 var(--mono); overflow-wrap: anywhere; }
.card-description { margin-block: 14px 24px; color: var(--body-copy); font-size: 13px; line-height: 1.8; }
.card-bottom { display: flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 17px; border-top: 1px solid var(--line); font-size: 12px; font-variant-numeric: tabular-nums; }
.card-bottom .file-count { color: var(--muted); }
.card-bottom .icon { margin-left: auto; color: var(--accent); }
.dot { color: var(--muted); }
.page-heading { display: flex; align-items: end; justify-content: space-between; gap: 32px; margin: 8px 0 40px; }
.page-heading .eyebrow { margin-bottom: 13px; }
.page-heading .lede { margin-top: 16px; }
.collection-total { flex-shrink: 0; border-left: 1px solid var(--line); padding-left: 25px; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.collection-total strong { display: block; color: var(--ink); font-size: 26px; font-weight: 600; letter-spacing: -1px; font-variant-numeric: tabular-nums; }
.site-footer { border-top: 1px solid var(--line); background: #1b2026; padding-block: 30px calc(30px + env(safe-area-inset-bottom)); }
.site-footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 30px; }
.footer-brand { display: flex; align-items: center; gap: 20px; }
.footer-brand .website-link { font-size: 21px; }
.footer-brand .logo-mark { width: 28px; height: 28px; }
.footer-brand p { max-width: 28ch; color: var(--muted); font-size: 12px; line-height: 1.6; }
.footer-links { display: flex; flex-wrap: wrap; gap: 24px; }
.footer-links a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); font-size: 12px; text-decoration: none; }
.footer-links a:hover { color: var(--accent-hover); text-decoration: underline; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.copy-button { display: inline-flex; justify-content: center; align-items: center; min-height: 44px; min-width: 44px; padding: 6px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--tint); color: var(--accent); font-size: 11px; }
.copy-button:hover { border-color: var(--accent); background: var(--surface-hover); color: var(--accent-hover); }
.copy-button:disabled { cursor: wait; }
.copy-status { color: var(--gold); font-size: 12px; }
.copy-status:not(:empty) { margin-top: 12px; }

@media (max-width: 1000px) {
  .header-inner { gap: 20px; }
  .header-guide { display: none; }
  .dataset-card { padding: 20px; }
  .footer-brand { align-items: flex-start; flex-direction: column; gap: 8px; }
}
@media (max-width: 760px) {
  .page-container, .header-inner, .site-footer-inner { width: min(100% - 40px, 620px); }
  .page-container { padding-block: 32px 56px; }
  .header-inner { min-height: 80px; flex-wrap: wrap; gap: 6px; padding-block: 17px 10px; }
  .website-link { font-size: 24px; }
  .main-nav { gap: 2px; }
  .nav-item { padding-inline: 11px; font-size: 12px; }
  .page-heading { align-items: start; flex-direction: column; gap: 24px; margin-bottom: 28px; }
  .collection-total { display: flex; align-items: baseline; gap: 10px; border: 0; padding: 0; }
  .collection-total strong { font-size: 20px; }
  .dataset-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .section-block { margin-top: 44px; }
  .section-heading { align-items: start; gap: 12px; }
  .section-heading > p { max-width: 17ch; text-align: right; }
  .site-footer-inner { align-items: start; }
  .footer-links { column-gap: 16px; row-gap: 0; justify-content: flex-end; }
}
@media (max-width: 520px) {
  .header-inner { justify-content: center; }
  .main-nav { justify-content: center; width: 100%; margin: 4px 0 0; }
  .nav-item { flex: 1; justify-content: center; }
  .dataset-grid { grid-template-columns: 1fr; }
  .dataset-card { padding: 23px; }
  .section-heading { flex-direction: column; }
  .section-heading > p { max-width: none; text-align: left; }
  .site-footer-inner { flex-direction: column; gap: 18px; }
  .footer-brand { flex-direction: row; align-items: center; gap: 20px; }
  .footer-links { justify-content: flex-start; gap: 24px; }
  .lede { font-size: 16px; }
}
@supports (padding: max(0px)) {
  body { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
