:root {
  color-scheme: light;
  --ink: #10283f;
  --ink-soft: #516579;
  --navy: #0b2b49;
  --navy-deep: #071d31;
  --teal: #007f82;
  --teal-dark: #006467;
  --paper: #ffffff;
  --canvas: #f5f8f9;
  --tint: #eaf3f2;
  --line: #cddade;
  --line-strong: #9db3ba;
  --focus: #ffb000;
  --radius: 14px;
  --shadow: 0 16px 40px rgba(13, 42, 63, 0.11);
  --shell: min(1320px, calc(100% - 40px));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

html[lang="ko"] body {
  font-family: Pretendard, "Noto Sans KR", "Apple SD Gothic Neo", ui-sans-serif, system-ui, sans-serif;
  word-break: keep-all;
}

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

a {
  color: inherit;
  text-underline-offset: 0.18em;
}

button,
input,
select {
  color: inherit;
  font: inherit;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

[hidden],
.hidden {
  display: none !important;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--navy);
  box-shadow: var(--shadow);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.shell {
  width: var(--shell);
  margin-inline: auto;
}

.narrow {
  max-width: 960px;
}

.site-header {
  position: relative;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--paper) 94%, transparent);
}

.nav-shell {
  display: flex;
  width: var(--shell);
  min-height: 68px;
  margin-inline: auto;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  color: var(--navy);
  font-size: 1.25rem;
  font-weight: 850;
  letter-spacing: -0.03em;
  text-decoration: none;
}

.wordmark span {
  color: var(--ink-soft);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 0.9rem;
  font-weight: 700;
}

.nav-links a {
  text-decoration: none;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--teal-dark);
}

.nav-links .nav-cta {
  padding: 8px 13px;
  border: 1px solid var(--navy);
  border-radius: var(--radius);
  background: var(--navy);
  color: #ffffff;
}

.catalog-hero,
.course-hero {
  display: grid;
  min-height: min(650px, calc(100svh - 68px));
  padding-block: clamp(46px, 8vw, 92px);
  align-items: center;
  gap: clamp(30px, 6vw, 84px);
}

.catalog-hero {
  grid-template-columns: minmax(0, 0.9fr) minmax(420px, 1.1fr);
}

.course-hero {
  grid-template-columns: minmax(0, 1.1fr) minmax(390px, 0.72fr);
  min-height: 0;
  padding-block: clamp(34px, 4vw, 54px);
  gap: clamp(30px, 4vw, 58px);
}

.hero-copy {
  max-width: 670px;
}

.eyebrow {
  margin: 0 0 13px;
  color: var(--teal-dark);
  font-size: 0.77rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  text-wrap: pretty;
}

h1,
h2,
h3 {
  margin-top: 0;
  color: var(--navy);
  line-height: 1.12;
  letter-spacing: -0.035em;
}

h1 {
  max-width: 14ch;
  margin-bottom: 22px;
  font-size: clamp(2.55rem, 5.8vw, 5.5rem);
  font-weight: 880;
}

.course-hero h1 {
  max-width: none;
  margin-bottom: 14px;
  font-size: clamp(2.2rem, 3.35vw, 3.35rem);
  line-height: 1.06;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(1.55rem, 2.5vw, 2.25rem);
  font-weight: 820;
}

h3 {
  margin-bottom: 10px;
  font-size: 1.1rem;
  font-weight: 790;
}

.hero-lead {
  max-width: 56ch;
  margin: 0;
  color: var(--ink-soft);
  font-size: clamp(1.05rem, 1.8vw, 1.3rem);
}

.course-hero .hero-lead {
  max-width: 58ch;
  color: var(--navy);
  font-size: clamp(0.96rem, 1.25vw, 1.08rem);
  font-weight: 680;
  line-height: 1.42;
}

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

.course-access-note {
  max-width: 66ch;
  margin: 10px 0 0;
  color: #bfd1d9;
  font-size: 0.78rem;
  line-height: 1.45;
}

.button.button-course-access {
  background: var(--navy-deep);
  border-color: var(--navy-deep);
}

.button.button-course-access:hover {
  background: var(--teal-dark);
  border-color: var(--teal-dark);
}

.button {
  display: inline-flex;
  min-height: 44px;
  padding: 9px 17px;
  border: 1px solid var(--teal-dark);
  border-radius: var(--radius);
  align-items: center;
  justify-content: center;
  background: var(--teal-dark);
  color: #ffffff;
  font-weight: 780;
  line-height: 1.2;
  text-decoration: none;
}

.button:hover {
  background: var(--navy);
  border-color: var(--navy);
}

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

.button-secondary {
  background: transparent;
  color: var(--navy);
  border-color: var(--line-strong);
}

.button-secondary:hover {
  color: #ffffff;
}

.hero-media,
.support-media,
.evidence-summary figure {
  position: relative;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--tint);
  box-shadow: var(--shadow);
}

.hero-media::after {
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: calc(var(--radius) - 5px);
  content: "";
  pointer-events: none;
}

.hero-media img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}

.course-hero .hero-media {
  transform: none;
}

.course-hero .hero-media img {
  max-height: 480px;
  aspect-ratio: 4 / 3;
}

.answer-band {
  border-block: 1px solid var(--line);
  background: var(--navy);
  color: #ffffff;
}

.answer-band .shell {
  display: grid;
  grid-template-columns: minmax(140px, 0.28fr) minmax(0, 1fr);
  padding-block: 27px;
  align-items: start;
  gap: 24px;
}

.answer-band strong {
  color: #9ee4df;
  font-size: 0.79rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.answer-band p {
  margin: 0;
  font-size: clamp(1.02rem, 1.7vw, 1.23rem);
}

.answer-band .course-summary-grid {
  grid-template-columns: minmax(0, 1.05fr) minmax(560px, 0.95fr);
  padding-block: 28px;
  gap: clamp(28px, 4vw, 54px);
}

.answer-copy > p:not(.course-access-note) {
  margin-top: 7px;
  color: #f0f6f8;
  font-size: 0.94rem;
  line-height: 1.55;
}

.course-fact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0;
  border-left: 1px solid rgb(255 255 255 / 0.22);
}

.course-fact-grid > div {
  min-width: 0;
  padding: 3px 14px 12px;
  border-right: 1px solid rgb(255 255 255 / 0.16);
  border-bottom: 1px solid rgb(255 255 255 / 0.16);
}

.course-fact-grid > div:nth-last-child(-n + 3) {
  padding-top: 12px;
  padding-bottom: 3px;
  border-bottom: 0;
}

.course-fact-grid dt {
  color: #9ee4df;
  font-size: 0.66rem;
  font-weight: 820;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.course-fact-grid dd {
  margin: 5px 0 0;
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 680;
  line-height: 1.35;
}

.fact-link {
  display: block;
  margin-top: 5px;
  color: #9ee4df;
  font-size: 0.7rem;
  font-weight: 780;
}

.research-bridge {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 1.45fr) auto;
  padding-top: 18px;
  border-top: 1px solid rgb(255 255 255 / 0.22);
  align-items: center;
  gap: 18px 32px;
}

.research-bridge h2 {
  margin: 0 0 5px;
  color: #ffffff;
  font-size: 1.03rem;
  letter-spacing: -0.025em;
}

.answer-band .research-bridge p {
  max-width: 88ch;
  color: #d8e6ed;
  font-size: 0.82rem;
  line-height: 1.45;
}

.research-pill-list {
  display: flex;
  margin: 0;
  padding: 0;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}

.research-pill {
  display: inline-flex;
  min-height: 30px;
  padding: 6px 11px;
  border: 1px solid rgb(158 228 223 / 0.52);
  border-radius: 999px;
  align-items: center;
  background: rgb(158 228 223 / 0.1);
  color: #c9f0ed;
  font-size: 0.72rem;
  font-weight: 820;
  line-height: 1;
  white-space: nowrap;
}

.university-source-rail {
  display: grid;
  min-width: 0;
  margin-top: 18px;
  gap: 7px;
}

.university-source-label {
  color: var(--ink-soft);
  font-size: 0.64rem;
  font-weight: 850;
  letter-spacing: 0.11em;
  line-height: 1.2;
  text-transform: uppercase;
}

.university-source-list {
  display: flex;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}

.university-source-mark {
  display: inline-flex;
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid transparent;
  border-radius: 999px;
  align-items: baseline;
  gap: 7px;
  color: #ffffff;
  font-size: clamp(0.88rem, 1vw, 1.04rem);
  line-height: 1;
  white-space: nowrap;
}

.university-source-mark strong {
  color: inherit;
  font-size: 1em;
  font-weight: 900;
  letter-spacing: -0.025em;
  line-height: 1;
  text-transform: none;
}

.university-source-mark span {
  font-size: 0.66em;
  font-weight: 760;
  letter-spacing: 0;
  opacity: 0.88;
}

.university-source-mark[data-institution="mit"] {
  border-color: #a63f1c;
  background: #a63f1c;
}

.university-source-mark[data-institution="stanford"] {
  border-color: #8c1515;
  background: #8c1515;
}

.university-source-mark[data-institution="stanford-medicine"] {
  border-color: #006e94;
  background: #006e94;
}

.university-source-mark[data-institution="harvard"] {
  border-color: #4b3f8f;
  background: #4b3f8f;
}

.university-source-mark[data-institution="github"] {
  border-color: #24313a;
  background: #24313a;
}

.university-source-rail-hero .university-source-mark {
  min-height: 42px;
  padding: 9px 15px;
  font-size: clamp(0.94rem, 1.15vw, 1.12rem);
}

.university-source-rail-answer {
  margin-top: 0;
  justify-items: end;
}

.university-source-rail-answer .university-source-label {
  color: #9ee4df;
}

.university-source-rail-answer .university-source-list {
  justify-content: flex-end;
}

.university-source-rail-outline,
.university-source-rail-faq {
  margin: 0 0 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line-strong);
}

.section {
  padding-block: clamp(44px, 5vw, 68px);
}

.section-tint {
  background: var(--canvas);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(260px, 0.7fr);
  margin-bottom: 38px;
  align-items: end;
  gap: 30px;
}

.section-heading h2,
.section-heading p {
  margin-bottom: 0;
}

.section-heading p,
.two-column > div > p,
.evidence-layout > div > p,
.evidence-summary p,
.faq-section details p,
.large-copy {
  color: var(--ink-soft);
}

.two-column,
.evidence-layout,
.evidence-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
  gap: clamp(34px, 7vw, 88px);
}

.check-list {
  margin-top: 18px;
}

.check-list p {
  position: relative;
  margin: 9px 0;
  padding-left: 23px;
  font-size: 0.9rem;
}

.check-list p::before {
  position: absolute;
  top: 0.5em;
  left: 2px;
  width: 8px;
  height: 8px;
  border: 2px solid var(--teal-dark);
  content: "";
}

.learning-panel {
  padding-left: clamp(24px, 3vw, 36px);
  border-left: 1px solid var(--line);
}

.learning-panel ol {
  margin: 0;
  padding-left: 1.35rem;
}

.learning-panel li {
  padding: 6px 0 6px 5px;
  font-size: 0.9rem;
}

.course-decision-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.42fr);
  align-items: start;
  gap: clamp(28px, 4vw, 52px);
}

.student-recommendation {
  padding-right: clamp(28px, 4vw, 48px);
  border-right: 1px solid var(--line-strong);
}

.student-hook-copy > p {
  max-width: 50ch;
  margin-bottom: 0;
  color: var(--navy);
  font-size: clamp(1.02rem, 1.45vw, 1.18rem);
  font-weight: 640;
  line-height: 1.5;
  letter-spacing: -0.025em;
}

.student-outcome {
  display: grid;
  gap: 5px;
  margin-top: 20px !important;
  padding: 12px 14px;
  border-left: 3px solid var(--teal);
  background: var(--tint);
  font-size: 0.88rem !important;
  font-weight: 500 !important;
}

.student-outcome strong {
  color: var(--teal-dark);
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.interest-panel {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.interest-panel h3 {
  margin-bottom: 8px;
  font-size: 0.86rem;
  line-height: 1.45;
}

.interest-panel ul {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.interest-panel li {
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 690;
  line-height: 1.45;
}

.interest-panel li::before {
  content: none;
}

.fit-learning-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

.fit-panel {
  padding-right: clamp(24px, 3vw, 36px);
}

.fit-panel > p,
.evidence-copy > p,
.faq-section details p {
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.curriculum-evidence-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.84fr) minmax(0, 1.46fr);
  align-items: start;
  gap: clamp(30px, 4vw, 52px);
}

.outline-panel {
  padding-right: clamp(26px, 3vw, 42px);
  border-right: 1px solid var(--line-strong);
}

.course-outline {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 20px 0 0;
  padding: 0;
  border-top: 1px solid var(--line-strong);
  list-style: none;
}

.course-outline li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  min-height: 0;
  padding: 11px 10px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.course-outline li:nth-child(2n) {
  border-right: 0;
}

.course-outline span {
  color: var(--teal-dark);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.69rem;
  font-weight: 850;
  letter-spacing: 0.08em;
}

.course-outline strong {
  color: var(--navy);
  font-size: 0.84rem;
  line-height: 1.4;
}

.compact-evidence {
  display: grid;
  grid-template-columns: minmax(190px, 0.56fr) minmax(0, 1.2fr);
  align-items: stretch;
  gap: clamp(20px, 2.5vw, 32px);
}

.compact-evidence .support-media,
.compact-evidence .support-media picture,
.compact-evidence .support-media img {
  height: 100%;
}

.compact-evidence .support-media img {
  min-height: 390px;
  aspect-ratio: auto;
}

.evidence-copy h3 {
  margin-top: 18px;
  font-size: 0.98rem;
}

.evidence-type {
  margin: 0 0 16px;
  color: var(--navy) !important;
  font-size: 0.96rem !important;
  font-weight: 760;
}

.flow-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 34px;
  border-block: 1px solid var(--line-strong);
}

.flow-grid article {
  min-height: 175px;
  padding: 25px 22px;
  border-right: 1px solid var(--line);
}

.flow-grid article:last-child {
  border-right: 0;
}

.flow-grid span {
  display: block;
  margin-bottom: 28px;
  color: var(--teal-dark);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.1em;
}

.flow-grid h3 {
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.support-media img,
.evidence-summary figure img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.disclaimer {
  margin-top: 16px;
  padding-left: 13px;
  border-left: 3px solid var(--teal);
  font-size: 0.82rem !important;
}

.text-link,
.card-link {
  color: var(--teal-dark);
  font-weight: 790;
}

.fact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 34px;
  border-top: 1px solid var(--line-strong);
}

.fact-grid article {
  min-height: 132px;
  padding: 24px 20px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.fact-grid article:nth-child(3n) {
  border-right: 0;
}

.fact-grid span,
.card-meta,
.review-date {
  display: block;
  color: var(--ink-soft);
  font-size: 0.75rem;
  font-weight: 720;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.fact-grid strong {
  display: block;
  margin-top: 9px;
  color: var(--navy);
  line-height: 1.35;
}

.source-list {
  margin: 14px 0;
  padding-left: 1.2rem;
}

.source-list li {
  margin-block: 6px;
  font-size: 0.84rem;
}

.source-list a {
  overflow-wrap: anywhere;
}

.course-reference-layout {
  display: grid;
  grid-template-columns: minmax(230px, 0.65fr) minmax(0, 1.5fr);
  align-items: start;
  gap: clamp(30px, 5vw, 64px);
}

.course-reference-layout-single {
  grid-template-columns: minmax(0, 960px);
  justify-content: center;
}

.source-panel {
  padding-right: clamp(26px, 3vw, 42px);
  border-right: 1px solid var(--line-strong);
}

.faq-section details {
  border-top: 1px solid var(--line);
}

.faq-section details:last-child {
  border-bottom: 1px solid var(--line);
}

.faq-section summary {
  padding: 15px 38px 15px 0;
  color: var(--navy);
  cursor: pointer;
  font-size: 0.94rem;
  font-weight: 780;
}

.faq-section details p {
  max-width: 72ch;
  margin: -2px 0 17px;
}

.final-cta {
  padding-block: clamp(36px, 4vw, 50px);
  background: var(--navy-deep);
  color: #ffffff;
  text-align: left;
}

.final-cta-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 36px;
}

.final-cta h2 {
  margin-bottom: 8px;
  color: #ffffff;
  font-size: clamp(1.45rem, 2vw, 2rem);
}

.final-cta p {
  max-width: 58ch;
  margin: 0;
  color: #d8e6ed;
  font-size: 0.9rem;
}

.final-cta .button {
  white-space: nowrap;
}

.subject-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-block: 1px solid var(--line-strong);
}

.subject-cell {
  min-height: 225px;
  padding: 27px 24px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}

.subject-cell:nth-child(3n) {
  border-right: 0;
}

.subject-cell span {
  color: var(--teal-dark);
  font-size: 0.75rem;
  font-weight: 820;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.subject-cell h3 {
  margin: 38px 0 10px;
  font-size: 1.3rem;
}

.subject-cell p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.subject-cell:hover,
.subject-cell:focus-visible {
  background: var(--tint);
}

.catalog-tools {
  display: grid;
  grid-template-columns: minmax(230px, 1.4fr) repeat(2, minmax(155px, 0.72fr)) auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  gap: 12px;
  background: var(--paper);
}

.catalog-tools label {
  display: grid;
  gap: 5px;
}

.catalog-tools label > span {
  color: var(--ink-soft);
  font-size: 0.72rem;
  font-weight: 760;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.catalog-tools input,
.catalog-tools select,
.reset-button {
  min-width: 0;
  min-height: 45px;
  padding: 9px 11px;
  border: 1px solid var(--line-strong);
  border-radius: calc(var(--radius) - 4px);
  background: var(--paper);
}

.reset-button {
  align-self: end;
  color: var(--teal-dark);
  cursor: pointer;
  font-weight: 760;
}

.reset-button:hover {
  border-color: var(--teal-dark);
  background: var(--tint);
}

.result-count {
  min-height: 24px;
  margin: 13px 0 20px;
  color: var(--ink-soft);
  font-size: 0.87rem;
}

.course-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line-strong);
  border-left: 1px solid var(--line-strong);
}

.course-card {
  display: flex;
  min-width: 0;
  min-height: 285px;
  padding: 22px 19px 19px;
  border-right: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
  flex-direction: column;
  background: var(--paper);
}

.course-card:hover {
  position: relative;
  z-index: 1;
  background: var(--tint);
  box-shadow: inset 0 0 0 2px var(--teal-dark);
}

.course-card h3 {
  margin: 18px 0 10px;
  font-size: 1.06rem;
  overflow-wrap: anywhere;
}

.course-card h3 a {
  text-decoration: none;
}

.course-card > p:not(.card-meta) {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 0.87rem;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
}

.card-meta {
  margin: 0;
  text-transform: none;
}

/* The first sort a parent makes is "test or project?". Four kinds, four
   colours, one word each, sitting above the age line where the eye lands
   first. The full sentence is on the chip's title attribute. */
.card-meta .course-kind,
.course-kind {
  display: inline-block;
  margin: 0 8px 6px 0;
  padding: 2px 9px;
  border: 1px solid currentColor;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.course-kind-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 10px;
  color: var(--ink-soft);
  font-size: 0.87rem;
}

.course-kind-line .course-kind {
  margin: 0;
}

.card-meta .course-kind-exam,
.course-kind-exam {
  color: #8a4b16;
  background: #fdf1e3;
}

.card-meta .course-kind-research,
.course-kind-research {
  color: var(--teal-dark);
  background: var(--tint);
}

.card-meta .course-kind-competition,
.course-kind-competition {
  color: #7a2f5c;
  background: #fbecf4;
}

.card-meta .course-kind-early,
.course-kind-early {
  color: #3f5a86;
  background: #eef2fb;
}

.card-meta span {
  display: block;
  margin-top: 3px;
  color: var(--teal-dark);
}

.card-link {
  display: flex;
  margin-top: auto;
  padding-top: 18px;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.83rem;
}

.empty-state {
  padding: 48px 24px;
  border: 1px solid var(--line);
  text-align: center;
}

.related-subjects {
  display: flex;
  padding-block: 28px;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 13px 25px;
  border-top: 1px solid var(--line);
}

.related-subjects a {
  color: var(--teal-dark);
}

.site-footer {
  display: grid;
  grid-template-columns: 0.7fr 1.2fr 1fr;
  padding: 48px max(20px, calc((100% - 1320px) / 2));
  border-top: 1px solid var(--line);
  align-items: start;
  gap: 30px;
  background: var(--canvas);
}

.site-footer p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.86rem;
}

.site-footer-meta {
  display: grid;
  gap: 10px;
}

.site-footer address {
  color: var(--ink-soft);
  font-size: 0.82rem;
  font-style: normal;
  line-height: 1.55;
}

.site-footer address a {
  color: var(--teal-dark);
}

.site-footer address a[href^="tel:"] {
  white-space: nowrap;
}

@media (min-width: 1420px) {
  .course-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .catalog-hero,
  .course-hero {
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
    gap: 34px;
  }

  .answer-band .course-summary-grid,
  .course-decision-grid,
  .curriculum-evidence-grid {
    grid-template-columns: 1fr;
  }

  .research-bridge {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .research-pill-list {
    justify-content: flex-start;
  }

  .university-source-rail-answer {
    justify-items: start;
  }

  .university-source-rail-answer .university-source-list {
    justify-content: flex-start;
  }

  .student-recommendation,
  .outline-panel {
    padding-right: 0;
    padding-bottom: 30px;
    border-right: 0;
    border-bottom: 1px solid var(--line-strong);
  }

  .compact-evidence {
    grid-template-columns: minmax(220px, 0.55fr) minmax(0, 1fr);
  }

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

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

  .reset-button {
    align-self: stretch;
  }
}

@media (max-width: 760px) {
  :root {
    --shell: min(100% - 28px, 680px);
  }

  .nav-shell {
    min-height: 62px;
    gap: 12px;
  }

  .wordmark span,
  .nav-links > a:first-child {
    display: none;
  }

  .nav-links {
    gap: 12px;
    font-size: 0.79rem;
  }

  .nav-links .nav-cta {
    padding: 7px 10px;
  }

  .catalog-hero,
  .course-hero {
    grid-template-columns: 1fr;
    min-height: 0;
    padding-block: 45px;
  }

  .course-hero {
    padding-block: 28px;
    gap: 24px;
  }

  h1,
  .catalog-hero h1 {
    max-width: 17ch;
    font-size: clamp(2.25rem, 11vw, 3.7rem);
  }

  .course-hero h1 {
    max-width: none;
    font-size: clamp(1.8rem, 7.5vw, 2.6rem);
  }

  .course-hero .hero-media img {
    max-height: 280px;
    aspect-ratio: 16 / 9;
  }

  .course-hero .hero-actions .button {
    font-size: 0.84rem;
    white-space: nowrap;
  }

  .answer-band .shell,
  .section-heading,
  .two-column,
  .evidence-layout,
  .evidence-summary {
    grid-template-columns: 1fr;
  }

  .answer-band .shell,
  .section-heading,
  .two-column,
  .evidence-layout,
  .evidence-summary {
    gap: 20px;
  }

  .answer-band .course-summary-grid {
    padding-block: 24px;
  }

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

  .course-fact-grid > div,
  .course-fact-grid > div:nth-last-child(-n + 3) {
    padding: 10px 12px;
    border-bottom: 1px solid rgb(255 255 255 / 0.16);
  }

  .course-fact-grid > div:nth-last-child(-n + 2) {
    border-bottom: 0;
  }

  .fit-learning-grid,
  .compact-evidence,
  .course-reference-layout,
  .final-cta-grid {
    grid-template-columns: 1fr;
  }

  .fit-panel {
    padding-right: 0;
    padding-bottom: 24px;
  }

  .learning-panel {
    padding-top: 24px;
    padding-left: 0;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .compact-evidence .support-media img {
    min-height: 0;
    aspect-ratio: 16 / 9;
  }

  .source-panel {
    padding-right: 0;
    padding-bottom: 26px;
    border-right: 0;
    border-bottom: 1px solid var(--line-strong);
  }

  .final-cta-grid {
    justify-items: start;
    gap: 20px;
  }

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

  .course-outline {
    grid-template-columns: 1fr;
  }

  .course-outline li,
  .course-outline li:nth-child(2n) {
    min-height: 0;
    border-right: 0;
  }

  .flow-grid article:nth-child(2) {
    border-right: 0;
  }

  .flow-grid article:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

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

  .fact-grid article:nth-child(3n),
  .subject-cell:nth-child(3n) {
    border-right: 1px solid var(--line);
  }

  .fact-grid article:nth-child(2n),
  .subject-cell:nth-child(2n) {
    border-right: 0;
  }

  .catalog-tools {
    grid-template-columns: 1fr 1fr;
    padding: 13px;
  }

  .catalog-tools label:first-child {
    grid-column: 1 / -1;
  }

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

  .course-card {
    min-height: 188px;
    padding: 13px 8px 11px;
  }

  .course-card h3 {
    margin: 12px 0;
    font-size: clamp(0.79rem, 3vw, 0.96rem);
    line-height: 1.2;
  }

  .course-card > p:not(.card-meta),
  .card-meta span {
    display: none;
  }

  .card-meta {
    font-size: 0.65rem;
    line-height: 1.25;
  }

  .card-link {
    font-size: 0.69rem;
    line-height: 1.2;
  }

  .subject-cell {
    min-height: 195px;
    padding: 22px 17px;
  }

  .subject-cell h3 {
    margin-top: 26px;
    font-size: 1.08rem;
  }

  .subject-cell p {
    font-size: 0.82rem;
  }

  .site-footer {
    grid-template-columns: 1fr;
    padding-inline: 20px;
    gap: 17px;
  }
}

@media (max-width: 370px) {
  .course-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .catalog-tools,
  .fact-grid,
  .subject-grid {
    grid-template-columns: 1fr;
  }

  .catalog-tools label:first-child {
    grid-column: auto;
  }

  .fact-grid article,
  .subject-cell,
  .fact-grid article:nth-child(2n),
  .subject-cell:nth-child(2n) {
    border-right: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

/* The research chip is built from --teal-dark/--tint and flips on its own; the
   other three are fixed hues, so they need the same flip stated. Without this
   one chip went dark-on-dark while its three neighbours stayed light pills. */
@media (prefers-color-scheme: dark) {
  .card-meta .course-kind-exam,
  .course-kind-exam {
    color: #f0c08a;
    background: #3a2a17;
  }

  .card-meta .course-kind-competition,
  .course-kind-competition {
    color: #eeaed2;
    background: #3a1f30;
  }

  .card-meta .course-kind-early,
  .course-kind-early {
    color: #b6c8ec;
    background: #1e2a41;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --ink: #e9f0f3;
    --ink-soft: #adc0c9;
    --navy: #eff8fb;
    --navy-deep: #071a29;
    --teal: #56cbc7;
    --teal-dark: #78d9d4;
    --paper: #0b1d2a;
    --canvas: #102633;
    --tint: #16343e;
    --line: #2d4b57;
    --line-strong: #43636e;
    --shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
  }

  .answer-band,
  .final-cta,
  .nav-links .nav-cta {
    background: var(--navy-deep);
  }

  .answer-band strong,
  .text-link,
  .card-link,
  .subject-cell span,
  .related-subjects a,
  .eyebrow,
  .reset-button {
    color: var(--teal-dark);
  }

  .button {
    background: #096d70;
    border-color: #78d9d4;
  }

  .button.button-course-access {
    background: #096d70;
    border-color: #78d9d4;
  }

  .button-secondary {
    background: transparent;
    color: var(--ink);
  }
}

@media print {
  .site-header,
  .hero-actions,
  .catalog-tools,
  .result-count,
  .final-cta,
  .site-footer {
    display: none;
  }

  .section,
  .catalog-hero,
  .course-hero {
    padding-block: 24px;
  }

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

/* Conversion and answer-first layer: trust strip, quick answer, consented parent
   quote beside each call to action, start-timing panel, and the Naver/Kakao
   channels Korean families check before they open a form. */
.trust-strip {
  margin-top: 18px;
}

.trust-strip ul {
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  gap: 6px 14px;
  list-style: none;
}

.trust-strip li {
  position: relative;
  color: var(--ink-soft);
  font-size: 0.82rem;
  font-weight: 640;
  line-height: 1.35;
}

.trust-strip li + li::before {
  position: absolute;
  left: -9px;
  color: var(--line-strong);
  content: "\00b7";
}

.quick-answer-question {
  margin: 9px 0 0;
  color: #ffffff;
  font-size: clamp(1.06rem, 1.6vw, 1.3rem);
  line-height: 1.35;
}

.answer-copy > p.course-quick-answer {
  max-width: 64ch;
  margin-top: 9px;
  color: #ffffff;
  font-size: 0.97rem;
  line-height: 1.6;
}

.parent-proof {
  margin: 0;
}

.parent-proof blockquote {
  margin: 0;
  padding-left: 13px;
  border-left: 3px solid var(--teal);
  font-size: 0.9rem;
  line-height: 1.55;
}

.parent-proof figcaption {
  display: flex;
  flex-wrap: wrap;
  margin-top: 7px;
  padding-left: 16px;
  gap: 4px 12px;
  align-items: baseline;
  font-size: 0.74rem;
}

.parent-proof figcaption b {
  font-weight: 780;
}

.parent-proof-answer {
  margin-top: 18px;
}

.parent-proof-answer blockquote {
  border-left-color: #9ee4df;
  color: #f0f6f8;
}

.parent-proof-answer figcaption {
  color: #cfe2ea;
}

.parent-proof-answer figcaption .text-link {
  color: #9ee4df;
}

.parent-proof-decide blockquote {
  color: var(--ink);
}

.parent-proof-decide figcaption {
  color: var(--ink-soft);
}

.decide-band {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) minmax(0, 0.65fr);
  gap: clamp(24px, 3vw, 44px);
  align-items: start;
}

.timing-panel h2 {
  margin: 0 0 9px;
  font-size: clamp(1.2rem, 1.7vw, 1.5rem);
}

.timing-panel p {
  max-width: 54ch;
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.portal-links h3 {
  margin: 0 0 8px;
  font-size: 0.78rem;
  font-weight: 820;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.portal-links ul {
  display: grid;
  margin: 0;
  padding: 0;
  gap: 5px;
  list-style: none;
}

.portal-links a {
  font-size: 0.87rem;
  font-weight: 640;
  text-decoration: underline;
}

.final-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.final-cta .button-secondary {
  background: transparent;
  border-color: rgb(255 255 255 / 0.45);
  color: #ffffff;
}

.protected-intent-links {
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding-block: 22px;
  align-items: stretch;
}

.protected-intent-heading,
.protected-intent-links > a {
  display: flex;
  min-width: 0;
  padding: 15px 17px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  flex-direction: column;
  justify-content: center;
}

.protected-intent-heading {
  background: var(--navy);
  color: #ffffff;
}

.protected-intent-heading strong,
.protected-intent-links > a strong {
  font-size: 0.9rem;
  line-height: 1.4;
}

.protected-intent-heading span,
.protected-intent-links > a small {
  margin-top: 4px;
  color: var(--ink-soft);
  font-size: 0.76rem;
  line-height: 1.5;
}

.protected-intent-heading span {
  color: #cfe2ea;
}

.protected-intent-links > a {
  color: var(--ink);
  text-decoration: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.protected-intent-links > a:hover {
  border-color: var(--teal);
  box-shadow: 0 10px 24px rgb(11 43 73 / 0.08);
  transform: translateY(-1px);
}

.protected-intent-index {
  margin-bottom: 5px;
  color: var(--teal-dark);
  font-size: 0.7rem;
  font-weight: 820;
  letter-spacing: 0.08em;
}

@media (max-width: 980px) {
  .decide-band {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .protected-intent-links {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (prefers-color-scheme: dark) {
  .parent-proof-answer blockquote {
    border-left-color: var(--teal-dark);
  }

  .final-cta .button-secondary {
    color: #ffffff;
  }
}

@media print {
  .portal-links,
  .trust-strip,
  .protected-intent-links {
    display: none;
  }
}

/* Institution provenance pills.
   Three kinds carry three different claims, so they are told apart by colour and
   never by the word alone: basis (built on it), tool (uses their tool),
   reference (draws on their research). Data: tools/curriculum/course-institutions.json */
.source-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
}

.source-pill {
  font-size: 0.74rem;
  line-height: 1.35;
  font-weight: 600;
  padding: 0.22rem 0.6rem;
  border-radius: 999px;
  border: 1px solid var(--line, #cddade);
  color: var(--ink-soft, #516579);
  background: var(--paper, #fff);
}

.source-pill a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

.source-pill-basis {
  border-color: var(--teal, #007f82);
  color: var(--teal-dark, #006467);
  background: var(--tint, #eaf3f2);
}

.source-pill-tool {
  border-color: var(--line-strong, #9db3ba);
  color: var(--navy, #0b2b49);
}

.course-sources-label {
  display: block;
  margin: 0.9rem 0 0;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft, #516579);
}

.source-pills-note {
  margin: 0.6rem 0 0;
  font-size: 0.78rem;
  line-height: 1.6;
  color: var(--ink-soft, #516579);
  max-width: 62ch;
}
