:root {
  --bg: #f5f0e8;
  --bg-soft: rgba(255, 252, 247, 0.78);
  --panel: rgba(255, 251, 245, 0.9);
  --panel-strong: rgba(255, 253, 249, 0.96);
  --line: rgba(33, 26, 18, 0.12);
  --line-strong: rgba(33, 26, 18, 0.24);
  --text: #241b14;
  --muted: #65574c;
  --accent: #7b9c87;
  --accent-deep: #46675a;
  --shadow: 0 24px 60px rgba(76, 56, 30, 0.12);
  --hero-glow: radial-gradient(circle at top left, rgba(143, 181, 158, 0.28), transparent 40%);
  --paper-edge: linear-gradient(180deg, rgba(255, 255, 255, 0.7), rgba(240, 231, 217, 0.5));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background:
    var(--hero-glow),
    linear-gradient(180deg, #f4efe7 0%, #f0e7da 100%);
}

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

a {
  color: inherit;
}

.page-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 48px;
}

.site-header {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 28px;
}

.eyebrow,
.section-kicker,
.panel-label,
.hero-kicker,
.results-title,
.footer-title {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--muted);
}

.header-line {
  height: 1px;
  flex: 1;
  background: var(--line);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(300px, 0.72fr);
  gap: 28px;
  padding: 38px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(248, 241, 233, 0.82)),
    var(--paper-edge);
  box-shadow: var(--shadow);
}

.hero-kicker {
  margin-bottom: 12px;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  line-height: 0.96;
  letter-spacing: -0.02em;
}

h1 {
  max-width: 12ch;
  font-size: clamp(3.5rem, 7vw, 6.4rem);
}

h2 {
  font-size: clamp(2.1rem, 4vw, 3.4rem);
  margin-top: 8px;
}

h3 {
  font-size: 2rem;
  line-height: 1.02;
  margin-top: 10px;
}

.hero-tagline {
  max-width: 54ch;
  margin: 18px 0 0;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  line-height: 1.6;
  color: var(--muted);
}

.hero-summary {
  margin-top: 20px;
  display: grid;
  gap: 12px;
}

.hero-summary p,
.section-body,
.footer-copy,
.feature-figure figcaption,
.results-note,
.panel-copy,
.idea-list {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.75;
  color: var(--muted);
}

.hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  text-decoration: none;
  font-weight: 700;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.cta:hover,
.cta:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(70, 103, 90, 0.45);
}

.cta-primary {
  background: linear-gradient(135deg, #5d7f70, #7fa28f);
  border-color: transparent;
  color: #fffdf9;
}

.cta-secondary {
  background: rgba(255, 252, 247, 0.8);
}

.hero-panel,
.results-card,
.feature-figure {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel);
  backdrop-filter: blur(16px);
}

.hero-panel {
  padding: 22px;
  align-self: end;
}

.hero-panel-feature {
  background:
    linear-gradient(160deg, rgba(255, 253, 248, 0.96), rgba(240, 230, 214, 0.92)),
    var(--panel);
}

.difficulty-cliff {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.difficulty-meter {
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(36, 27, 20, 0.08);
  background: rgba(255, 252, 247, 0.7);
}

.meter-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.meter-head strong {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.meter-track {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(36, 27, 20, 0.08);
}

.meter-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
}

.difficulty-meter.easy .meter-track span {
  background: linear-gradient(90deg, #b9e7ce, #6fcca2);
}

.difficulty-meter.medium .meter-track span {
  background: linear-gradient(90deg, #f4d99a, #e3b862);
}

.difficulty-meter.hard .meter-track span {
  background: linear-gradient(90deg, #f1b28a, #cf7251);
}

.panel-copy {
  margin-top: 18px;
}

.content-section,
.figure-section,
.results-section {
  margin-top: 34px;
  padding: 34px;
  border-radius: 28px;
  border: 1px solid var(--line);
  background: rgba(255, 252, 247, 0.62);
  box-shadow: 0 18px 45px rgba(82, 58, 28, 0.08);
}

.section-heading {
  max-width: 78ch;
}

.section-body {
  margin-top: 14px;
}

.chip-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.chip-cloud span,
.issue-stack span,
.family-card span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(122, 156, 135, 0.12);
  border: 1px solid rgba(70, 103, 90, 0.16);
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 600;
}

.rank-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.rank-list div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 252, 247, 0.7);
  border: 1px solid rgba(36, 27, 20, 0.08);
}

.rank-list span {
  font-weight: 700;
}

.rank-list strong {
  font-size: 0.92rem;
  color: var(--accent-deep);
}

.issue-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.stats-band,
.two-column-grid,
.split-layout,
.family-grid {
  margin-top: 28px;
}

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

.stats-band article,
.content-card,
.family-card {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(255, 254, 250, 0.96), rgba(243, 235, 224, 0.86));
  box-shadow: 0 14px 32px rgba(82, 58, 28, 0.06);
}

.content-card-wide {
  margin-top: 28px;
}

.stats-value {
  display: block;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.3rem, 4vw, 3.4rem);
  line-height: 0.95;
  color: var(--accent-deep);
}

.stats-label {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.6;
}

.split-layout,
.two-column-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.family-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.family-card h3 {
  font-size: 1.9rem;
}

.family-card p {
  margin: 12px 0 16px;
  color: var(--muted);
  line-height: 1.7;
}

.tokenization-scroll {
  overflow-x: auto;
  margin-top: 18px;
  padding-bottom: 4px;
}

.tokenization-strip {
  display: flex;
  flex-wrap: nowrap;
  align-items: flex-start;
  gap: 12px;
  width: max-content;
  min-width: 100%;
}

.tokenization-strip-wide {
  gap: 16px;
}

.tokenization-shot {
  margin: 0;
  flex: 0 0 calc((100% - 32px) / 3);
  width: calc((100% - 32px) / 3);
  min-width: 250px;
}

.tokenization-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 164px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(36, 27, 20, 0.08);
  background: #fffdf8;
}

.tokenization-shot img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.tokenization-shot figcaption {
  margin-top: 8px;
  text-align: center;
  font-size: 0.84rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.format-figure {
  margin: 18px 0 0;
}

.format-figure img {
  width: 100%;
  border-radius: 18px;
  border: 1px solid rgba(36, 27, 20, 0.08);
  background: #fffdf8;
}

.format-figure figcaption {
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.7;
}

.idea-list {
  margin-top: 18px;
  padding-left: 18px;
}

.idea-list li + li {
  margin-top: 8px;
}

.feature-figure {
  margin: 28px 0 0;
  padding: 20px;
  overflow: hidden;
}

.feature-figure img {
  border-radius: 18px;
  border: 1px solid rgba(36, 27, 20, 0.08);
  background: var(--panel-strong);
}

.feature-figure figcaption {
  margin-top: 14px;
}

.results-card {
  margin-top: 28px;
  padding: 22px;
  overflow: hidden;
}

.results-meta {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: end;
  margin-bottom: 18px;
}

.results-title {
  color: var(--text);
}

.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel-strong);
}

.results-table {
  width: 100%;
  min-width: 860px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.95rem;
}

.results-table th,
.results-table td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(36, 27, 20, 0.08);
  text-align: center;
}

.results-table thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  background: #f7f1e7;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.results-table th:first-child,
.results-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 2;
  text-align: left;
  background: inherit;
}

.results-table thead th:first-child {
  z-index: 4;
}

.difficulty-row th {
  padding: 16px 18px;
  text-align: left;
  background: #efe4d2;
  color: var(--text);
  border-top: 3px solid rgba(36, 27, 20, 0.12);
  border-bottom: 1px solid rgba(36, 27, 20, 0.08);
}

.difficulty-row th > span {
  display: inline-flex;
  align-items: center;
}

.difficulty-pill {
  min-width: 92px;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-weight: 800;
}

.difficulty-note {
  margin-left: 12px;
  font-size: 0.92rem;
  color: var(--muted);
}

.difficulty-row[data-difficulty="easy"] .difficulty-pill {
  background: rgba(121, 206, 167, 0.22);
}

.difficulty-row[data-difficulty="medium"] .difficulty-pill {
  background: rgba(243, 212, 140, 0.34);
}

.difficulty-row[data-difficulty="hard"] .difficulty-pill {
  background: rgba(229, 143, 108, 0.28);
}

.model-cell {
  min-width: 220px;
  font-weight: 700;
  color: var(--text);
  background: #fffaf2;
}

.metric-cell {
  font-variant-numeric: tabular-nums;
  background: var(--cell-bg, #fffdf8);
  color: var(--text);
}

.metric-cell.missing {
  color: rgba(36, 27, 20, 0.45);
  background: #fffdf8;
}

.site-footer {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin-top: 34px;
  padding: 28px 8px 0;
}

@media (max-width: 920px) {
  .hero,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 28px;
  }

  .figure-section,
  .content-section,
  .results-section {
    padding: 26px;
  }

  .results-meta {
    flex-direction: column;
    align-items: start;
  }
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 20px, 1180px);
    padding-top: 18px;
  }

  .hero,
  .content-section,
  .figure-section,
  .results-section {
    border-radius: 22px;
  }

  .hero,
  .content-section,
  .figure-section,
  .results-section,
  .results-card {
    padding-left: 18px;
    padding-right: 18px;
  }

  .stats-band,
  .split-layout,
  .two-column-grid,
  .family-grid {
    grid-template-columns: 1fr;
  }

  .tokenization-shot {
    flex: 0 0 240px;
    width: 240px;
  }

  .results-table th,
  .results-table td {
    padding: 12px 14px;
  }
}
