:root {
  --ink: #17202a;
  --muted: #687385;
  --line: #d8e0ea;
  --paper: #fbfcfd;
  --panel: #ffffff;
  --blue: #2563eb;
  --cyan: #0891b2;
  --green: #159947;
  --orange: #c8671a;
  --violet: #7048c4;
  --shadow: 0 22px 60px rgba(23, 32, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(180deg, #eef6ff 0, rgba(238, 246, 255, 0) 520px),
    var(--paper);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

.hero {
  min-height: 92vh;
  padding: 24px clamp(20px, 5vw, 72px) 72px;
}

.nav {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  max-width: 1180px;
  margin: 0 auto 68px;
}

.nav a {
  border: 1px solid transparent;
  border-radius: 8px;
  color: #334155;
  font-size: 14px;
  padding: 8px 12px;
}

.nav a:hover {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.7);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.78fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--cyan);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

h1 {
  max-width: 860px;
  margin: 0;
  font-size: clamp(44px, 7vw, 86px);
  line-height: 0.98;
  letter-spacing: 0;
}

h2 {
  margin: 0 0 18px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.08;
  letter-spacing: 0;
}

h3 {
  margin: 0 0 10px;
  font-size: 20px;
  line-height: 1.22;
}

.subtitle {
  max-width: 760px;
  margin: 26px 0 24px;
  color: #435063;
  font-size: clamp(18px, 2vw, 22px);
}

.authors {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin-top: 28px;
  font-weight: 700;
}

.affiliation,
.note {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 14px;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 112px;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #1f2937;
  font-weight: 800;
  box-shadow: 0 10px 22px rgba(23, 32, 42, 0.08);
}

.button.primary {
  border-color: var(--blue);
  background: var(--blue);
  color: #fff;
}

.hero-panel {
  border: 1px solid rgba(37, 99, 235, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
  padding: clamp(18px, 3vw, 30px);
}

.pipeline {
  display: grid;
  gap: 14px;
}

.node,
.objective,
.formula {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 14px 16px;
  text-align: center;
  font-weight: 800;
}

.prompt {
  border-color: rgba(37, 99, 235, 0.4);
  background: #edf4ff;
  color: #1d4ed8;
}

.context {
  border-color: rgba(112, 72, 196, 0.35);
  background: #f2edff;
  color: #5b35a8;
}

.model {
  border-color: rgba(8, 145, 178, 0.4);
  background: #ecfeff;
  color: #0e7490;
}

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

.student {
  border-color: rgba(37, 99, 235, 0.35);
  color: #1d4ed8;
}

.teacher {
  border-color: rgba(200, 103, 26, 0.38);
  color: #9a4d12;
}

.objective {
  border-color: rgba(21, 153, 71, 0.4);
  background: #effaf3;
  color: #126f38;
  font-size: 18px;
}

.section {
  max-width: 1180px;
  margin: 0 auto;
  padding: 72px clamp(20px, 5vw, 72px);
}

.section.narrow {
  max-width: 900px;
}

.section-heading {
  max-width: 820px;
  margin-bottom: 28px;
}

.section-heading p,
.narrow p,
.feature-grid p,
.formula-band p,
.two-column p,
.formula-card p,
.figure-notes p {
  color: #475569;
  font-size: 17px;
}

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

.feature-grid article {
  min-height: 260px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 24px;
  box-shadow: 0 10px 30px rgba(23, 32, 42, 0.06);
}

.index {
  display: block;
  margin-bottom: 28px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 900;
}

.formula-band {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 22px;
  align-items: center;
  margin-top: 24px;
  border: 1px solid #cbdce8;
  border-radius: 8px;
  background: linear-gradient(135deg, #ffffff, #f5fbff);
  padding: clamp(22px, 4vw, 34px);
}

.formula {
  overflow-x: auto;
  padding: 22px;
  text-align: left;
  white-space: nowrap;
}

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

.formula-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 24px;
  box-shadow: 0 10px 30px rgba(23, 32, 42, 0.06);
}

.math {
  overflow-x: auto;
  margin: 14px 0 16px;
  border: 1px solid #d8e7f0;
  border-radius: 8px;
  background: #f8fbff;
  padding: 16px;
  color: #143b6d;
  font-weight: 800;
  white-space: nowrap;
}

.schedule-row {
  margin-top: 28px;
}

.equation-list {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.equation-list div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
}

.equation-list strong {
  display: block;
  margin-bottom: 8px;
  color: #1f3f75;
}

.equation-list span {
  display: block;
  overflow-x: auto;
  color: #334155;
  white-space: nowrap;
}

.small-figure object {
  height: 300px;
}

.process {
  margin-top: 28px;
  border: 1px solid #cbdce8;
  border-radius: 8px;
  background: linear-gradient(135deg, #ffffff, #f7fbf9);
  padding: 26px;
}

.process ol {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.process li {
  position: relative;
  min-height: 150px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 48px 14px 14px;
  color: #475569;
  font-size: 14px;
  counter-increment: step;
}

.process li::before {
  content: counter(step);
  position: absolute;
  top: 14px;
  left: 14px;
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
}

.takeaways {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.takeaways article {
  border: 1px solid #d9e7df;
  border-radius: 8px;
  background: #f4fbf7;
  padding: 18px;
}

.takeaways strong {
  display: block;
  margin-bottom: 6px;
  color: #126f38;
}

.takeaways span {
  color: #4c5d68;
  font-size: 15px;
}

.results-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(23, 32, 42, 0.06);
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

caption {
  padding: 18px 18px 4px;
  color: #475569;
  font-weight: 800;
  text-align: left;
}

th,
td {
  border-bottom: 1px solid #e5edf4;
  padding: 12px 14px;
  text-align: right;
}

th:first-child,
td:first-child {
  text-align: left;
}

thead th {
  color: #334155;
  font-size: 13px;
  text-transform: uppercase;
}

tbody th {
  font-weight: 800;
}

.ours {
  background: #ecfdf5;
}

.figure-showcase {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 22px;
  margin-top: 24px;
}

figure {
  margin: 0;
}

.figure-showcase figure,
.compact-figure {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 14px;
  box-shadow: 0 10px 30px rgba(23, 32, 42, 0.06);
}

object {
  display: block;
  width: 100%;
  height: 520px;
  border: 0;
  background: #fff;
}

figcaption {
  margin-top: 12px;
  color: #5f6d7e;
  font-size: 14px;
}

.figure-notes {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 18px;
  margin-top: 22px;
}

.figure-notes article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 22px;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 0.7fr) minmax(320px, 1fr);
  gap: 28px;
  align-items: start;
}

.compact-figure object {
  height: 440px;
}

pre {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f172a;
  color: #e2e8f0;
  padding: 22px;
}

code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 14px;
}

footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  border-top: 1px solid var(--line);
  padding: 28px;
  color: #64748b;
  font-size: 14px;
}

footer span {
  color: #334155;
  font-weight: 800;
}

footer a {
  color: var(--blue);
  font-weight: 800;
}

@media (max-width: 920px) {
  .hero {
    min-height: auto;
  }

  .nav {
    justify-content: flex-start;
    margin-bottom: 36px;
    overflow-x: auto;
  }

  .hero-grid,
  .formula-band,
  .two-column {
    grid-template-columns: 1fr;
  }

  .feature-grid,
  .figure-showcase,
  .analysis-grid,
  .figure-notes,
  .takeaways {
    grid-template-columns: 1fr;
  }

  .process ol {
    grid-template-columns: 1fr;
  }

  .process li {
    min-height: 0;
  }

  object,
  .compact-figure object {
    height: 430px;
  }
}

@media (max-width: 560px) {
  .hero {
    padding-top: 16px;
  }

  .split {
    grid-template-columns: 1fr;
  }

  .actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .button {
    min-width: 0;
  }

  .section {
    padding-top: 52px;
    padding-bottom: 52px;
  }

  .feature-grid article {
    min-height: 0;
  }

  object,
  .compact-figure object {
    height: 360px;
  }
}
