:root {
  color-scheme: light;
  --ink: #13221d;
  --muted: #5e6d68;
  --paper: #f4f0e8;
  --paper-2: #ebe6dc;
  --panel: #fffdf8;
  --line: #d8d3c8;
  --green: #1f6f50;
  --green-dark: #12362c;
  --blue: #2f65a3;
  --gold: #b5791e;
  --rose: #aa5451;
  --focus: #1f6f50;
  --shadow: 0 18px 50px rgba(24, 36, 31, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--paper);
  color: var(--ink);
}

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

a:hover {
  text-decoration: underline;
}

.shell {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -44px;
  z-index: 20;
  padding: 10px 12px;
  border-radius: 6px;
  background: var(--ink);
  color: white;
  transition: top 160ms ease;
}

.skip-link:focus {
  top: 12px;
}

header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(216, 211, 200, 0.9);
  background: rgba(244, 240, 232, 0.92);
  backdrop-filter: blur(14px);
}

.nav {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--green-dark);
  color: white;
  font-size: 18px;
}

nav {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #43514c;
  font-size: 14px;
  font-weight: 750;
}

main {
  overflow: hidden;
}

.hero-band {
  padding: 72px 0 42px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 253, 248, 0.82), rgba(244, 240, 232, 0.86));
}

.profile-hero {
  background: linear-gradient(180deg, rgba(220, 239, 228, 0.9), rgba(244, 240, 232, 0.88));
}

.hero-stack {
  display: grid;
  gap: 22px;
}

.eyebrow {
  color: var(--green);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

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

h1 {
  max-width: 920px;
  margin: 0;
  font-size: clamp(42px, 6.2vw, 78px);
  line-height: 0.98;
}

h2 {
  margin: 0;
  font-size: clamp(28px, 3.4vw, 44px);
  line-height: 1.05;
}

h3 {
  margin: 0;
  font-size: 21px;
  line-height: 1.2;
}

.lede {
  max-width: 820px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.5;
}

.hero-actions,
.card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.button {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ink);
  border-radius: 8px;
  padding: 0 16px;
  font-weight: 900;
  text-decoration: none;
}

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

.button.secondary {
  background: rgba(255, 253, 248, 0.78);
}

.button:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(31, 111, 80, 0.28);
  outline-offset: 2px;
}

.stat-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 920px;
}

.stat-strip div,
.panel,
.university-card,
.link-tile,
.source-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.stat-strip div {
  min-height: 88px;
  display: grid;
  gap: 4px;
  align-content: center;
  padding: 16px;
}

.stat-strip strong {
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1;
}

.stat-strip span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.section {
  padding: 68px 0;
  border-top: 1px solid var(--line);
}

.section:first-child {
  border-top: 0;
}

.tinted {
  background: rgba(255, 253, 248, 0.44);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(280px, 0.5fr);
  gap: 34px;
  align-items: end;
  margin-bottom: 28px;
}

.section-heading.compact h2 {
  margin-top: 8px;
}

.section-heading p,
.summary-copy,
.muted,
.empty-note,
.cta-grid p,
.disclaimer p {
  color: var(--muted);
  line-height: 1.55;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.62fr) minmax(320px, 0.72fr);
  gap: 36px;
  align-items: start;
}

.summary-copy {
  margin: 0;
  font-size: 19px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

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

th,
td {
  padding: 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  background: #fbf8f1;
  color: #43514c;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

tbody tr:last-child td {
  border-bottom: 0;
}

td strong {
  font-size: 21px;
}

.seed-note {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

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

.weight-item {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.weight-item span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.weight-item strong {
  font-size: 26px;
}

.meter {
  height: 8px;
  border-radius: 999px;
  overflow: hidden;
  background: #ebe8df;
}

.meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
}

.source-panel {
  margin-top: 24px;
  padding: 20px;
}

.source-grid,
.card-grid,
.link-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.source-grid {
  margin-top: 14px;
}

.source-grid article {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(244, 240, 232, 0.52);
}

.source-grid p {
  margin: 8px 0;
  color: var(--muted);
  line-height: 1.45;
}

.source-grid span {
  color: var(--green);
  font-size: 13px;
  font-weight: 850;
}

.university-card {
  display: grid;
  gap: 14px;
  padding: 20px;
  min-height: 100%;
}

.card-rank {
  width: 44px;
  min-height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--green-dark);
  color: white;
  font-weight: 950;
}

.score-badge {
  display: inline-grid;
  justify-self: start;
  min-width: 98px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #edf7f1;
  color: var(--green-dark);
}

.score-badge strong {
  font-size: 30px;
  line-height: 1;
}

.score-badge span {
  color: var(--green);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid #b6c9bd;
  border-radius: 999px;
  background: #edf7f1;
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 850;
}

.text-link {
  color: var(--green-dark);
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.profile-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}

.panel {
  padding: 22px;
}

.panel h2 {
  margin-top: 8px;
  font-size: clamp(24px, 2.4vw, 34px);
}

.fact-list {
  display: grid;
  gap: 0;
  margin: 14px 0 0;
}

.fact-list div {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.fact-list div:last-child {
  border-bottom: 0;
}

dt {
  color: var(--muted);
  font-weight: 850;
}

dd {
  margin: 0;
  font-weight: 750;
}

.form-row {
  display: grid;
  gap: 7px;
  margin: 16px 0;
}

.form-row label {
  color: #3f4d48;
  font-size: 13px;
  font-weight: 850;
}

.form-row input,
.form-row select {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: white;
  color: var(--ink);
  font: inherit;
}

.form-message {
  min-height: 20px;
  margin: 12px 0 0;
  color: var(--green);
  font-size: 14px;
  font-weight: 850;
}

.hidden {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.compact-cards .university-card {
  min-height: auto;
}

.breakdown-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.breakdown-list div {
  display: grid;
  gap: 8px;
}

.breakdown-list span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 850;
}

.breakdown-list strong {
  font-size: 22px;
}

.link-tile {
  display: grid;
  gap: 8px;
  padding: 18px;
  min-height: 112px;
}

.link-tile span {
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.link-tile strong {
  font-size: 19px;
  line-height: 1.25;
}

.cta-band {
  padding: 64px 0;
  background: var(--green-dark);
  color: white;
}

.cta-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) minmax(320px, 0.52fr);
  gap: 36px;
  align-items: start;
}

.cta-grid .eyebrow,
.cta-grid p {
  color: #c7e6d2;
}

.cta-grid h2 {
  max-width: 720px;
}

.cta-list {
  display: grid;
  gap: 10px;
}

.cta-band .button.secondary {
  color: white;
  border-color: rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.08);
}

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

.disclaimer {
  padding: 24px 0 34px;
  border-top: 1px solid var(--line);
  background: #ebe6dc;
}

.disclaimer p {
  margin: 0;
  font-size: 14px;
}

footer {
  padding: 30px 0 40px;
  color: var(--muted);
  font-size: 14px;
  border-top: 1px solid var(--line);
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

@media (max-width: 940px) {
  nav {
    display: none;
  }

  .section-heading,
  .split,
  .profile-layout,
  .cta-grid {
    grid-template-columns: 1fr;
  }

  .weight-grid,
  .source-grid,
  .card-grid,
  .link-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .shell {
    width: min(100% - 22px, 1160px);
  }

  .hero-band,
  .section {
    padding: 44px 0;
  }

  h1 {
    font-size: 42px;
  }

  .stat-strip,
  .weight-grid,
  .source-grid,
  .card-grid,
  .link-grid {
    grid-template-columns: 1fr;
  }

  .button {
    width: 100%;
  }

  .fact-list div {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}
