:root {
  color-scheme: light;
  --bg: #f6f7f5;
  --surface: #ffffff;
  --surface-2: #eef2ee;
  --ink: #15202b;
  --muted: #5c6670;
  --line: #d7ded7;
  --blue: #1f5f9f;
  --blue-dark: #143d66;
  --gold: #b98518;
  --green: #557860;
  --shadow: 0 18px 45px rgba(21, 32, 43, 0.1);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.55;
}

a {
  color: var(--blue);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

img {
  display: block;
  max-width: 100%;
}

button,
a {
  font: inherit;
}

:focus-visible {
  outline: 3px solid rgba(31, 95, 159, 0.4);
  outline-offset: 3px;
}

.site-header {
  position: fixed;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  padding: 16px clamp(20px, 4vw, 56px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(2, 3, 5, 0.42);
  backdrop-filter: blur(14px);
}

.brand {
  color: #ffffff;
  font-weight: 800;
  text-decoration: none;
  text-shadow: 0 1px 16px rgba(0, 0, 0, 0.38);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  justify-content: flex-end;
}

.nav a {
  color: rgba(255, 255, 255, 0.84);
  font-size: 0.95rem;
  text-decoration: none;
  text-shadow: 0 1px 14px rgba(0, 0, 0, 0.38);
}

.nav a:hover {
  color: #ffffff;
}

.section {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 76px 0;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1240px);
  gap: 0;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: none;
  min-height: 100vh;
  min-height: 100svh;
  padding: 112px clamp(20px, 4vw, 56px) 96px;
  background:
    linear-gradient(90deg, rgba(7, 11, 15, 0.92) 0%, rgba(8, 13, 18, 0.78) 38%, rgba(8, 13, 18, 0.36) 65%, rgba(7, 11, 15, 0.72) 100%),
    url("assets/mosaic-bg.png");
  background-position: center, center;
  background-size: auto, 122% auto;
}

.hero-copy {
  width: 100%;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  max-width: 1120px;
  font-size: clamp(2.05rem, 3.8vw, 3.7em);
  line-height: 1.06;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: clamp(1.65rem, 2.35vw, 2.6rem);
  line-height: 1.06;
  letter-spacing: 0;
  white-space: nowrap;
}

h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
  line-height: 1.25;
}

.authors,
.affiliation,
.hero-summary,
.section-heading p {
  color: var(--muted);
}

.hero h1 {
  color: #ffffff;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.32);
}

.hero .eyebrow {
  color: #e2aa35;
}

.hero .authors,
.hero .affiliation,
.hero .hero-summary {
  color: rgba(255, 255, 255, 0.82);
}

.authors {
  margin: 28px 0 6px;
  font-weight: 700;
}

.affiliation {
  margin: 0;
}

.hero-summary {
  max-width: 780px;
  margin: 28px 0 0;
  font-size: 1.05rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-weight: 750;
  text-decoration: none;
  box-shadow: 0 8px 20px rgba(21, 32, 43, 0.06);
  cursor: pointer;
}

.button.primary {
  border-color: var(--blue-dark);
  background: var(--blue-dark);
  color: white;
}

.button:hover {
  transform: translateY(-1px);
}

.button.disabled {
  color: var(--muted);
  cursor: not-allowed;
}

.button.disabled span {
  color: var(--gold);
  font-size: 0.82rem;
}

.paper-figure {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.dataset-band {
  width: 100%;
  max-width: none;
  padding: 80px clamp(20px, 4vw, 56px);
  background: var(--surface-2);
}

.dataset-band > * {
  width: min(1180px, 100%);
  margin-left: auto;
  margin-right: auto;
}

.section-heading {
  max-width: 1180px;
  margin-bottom: 34px;
}

.section-heading p {
  margin: 18px 0 0;
  font-size: 1.05rem;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
}

.metric {
  min-height: 118px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.metric strong {
  display: block;
  color: var(--blue-dark);
  font-size: clamp(1.55rem, 2.4vw, 2.35rem);
  line-height: 1;
}

.metric span {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.92rem;
}

.viewer-callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin-top: 18px;
  padding: 24px;
  border: 1px solid #ced9cf;
  border-radius: 8px;
  background: #fbfbf8;
}

.viewer-callout p {
  margin: 0;
  color: var(--muted);
}

.split-section {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: start;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.feature-grid article {
  min-height: 160px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.feature-grid p {
  margin: 0;
  color: var(--muted);
}

.overview-detail {
  grid-column: 1 / -1;
  padding: 10px;
}

.figure-section .paper-figure {
  padding: 10px;
}

.paper-figure img {
  width: 100%;
  border-radius: 6px;
}

.schema-table {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.schema-row {
  display: grid;
  grid-template-columns: 0.8fr 1.25fr 2fr;
  gap: 0;
  border-top: 1px solid var(--line);
}

.schema-row:first-child {
  border-top: 0;
}

.schema-row span {
  padding: 16px 18px;
  border-left: 1px solid var(--line);
}

.schema-row span:first-child {
  border-left: 0;
  font-weight: 800;
}

.schema-row.header {
  background: #e8eee9;
  color: var(--blue-dark);
  font-weight: 800;
}

.citation-section {
  display: grid;
  grid-template-columns: minmax(260px, 0.66fr) minmax(0, 1.34fr);
  gap: 34px;
  align-items: start;
}

.code-block {
  position: relative;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #eef0f2;
  color: var(--ink);
  box-shadow: var(--shadow);
}

pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  font: 0.92rem/1.55 "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

.copy-button {
  margin-top: 16px;
  box-shadow: none;
}

.copy-status {
  min-height: 1.4em;
  margin: 10px 0 0;
  color: var(--green);
  font-size: 0.9rem;
}

.contact-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  border-top: 1px solid var(--line);
}

.contact-section p {
  margin: 0;
  color: var(--muted);
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 28px clamp(20px, 4vw, 56px);
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.92rem;
}

@media (max-width: 1080px) {
  .hero,
  .split-section,
  .citation-section {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .section {
    width: min(100% - 28px, 1180px);
    padding: 54px 0;
  }

  .hero {
    width: 100%;
    padding: 104px 14px 76px;
    background-size: auto, auto 122%;
  }

  h2 {
    white-space: normal;
  }

  .dataset-band {
    padding: 58px 14px;
  }

  .metrics,
  .feature-grid {
    grid-template-columns: 1fr;
  }

  .viewer-callout,
  .contact-section,
  .footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .schema-row {
    grid-template-columns: 1fr;
  }

  .schema-row span {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .schema-row span:first-child {
    border-top: 0;
  }

  .actions .button {
    width: 100%;
  }
}
