@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Libre+Franklin:wght@500;600;700&display=swap');

:root {
  --navy: #0d3158;
  --navy-deep: #082642;
  --blue: #2b6f9f;
  --blue-soft: #dcecf5;
  --ink: #142232;
  --muted: #5d6a78;
  --paper: #f7f9fb;
  --white: #ffffff;
  --line: #dce3e9;
  --line-dark: #c7d1da;
  --tag: #eef4f8;
  --shadow: 0 18px 50px rgba(13, 49, 88, 0.08);
  --shell: min(1120px, calc(100% - 40px));
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

a { color: inherit; }

a:focus-visible {
  outline: 3px solid #eab464;
  outline-offset: 4px;
  border-radius: 3px;
}

.site-header {
  width: var(--shell);
  height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  color: var(--navy);
  font-family: "Libre Franklin", sans-serif;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.brand span {
  margin-left: 7px;
  padding-left: 9px;
  color: var(--muted);
  border-left: 1px solid var(--line-dark);
  font-weight: 500;
}

.header-note,
.back-link {
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.back-link:hover { color: var(--navy); }

.home-hero,
.course-hero {
  position: relative;
  overflow: hidden;
  color: var(--white);
  background:
    radial-gradient(circle at 85% 25%, rgba(112, 181, 217, 0.25), transparent 27%),
    linear-gradient(128deg, var(--navy-deep), var(--navy) 63%, #16537c);
}

.home-hero::after,
.course-hero::after {
  position: absolute;
  right: -120px;
  bottom: -210px;
  width: 520px;
  height: 520px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 50%;
  content: "";
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: var(--shell);
  margin: 0 auto;
  padding: 78px 0 82px;
}

.course-hero .hero-inner { padding: 66px 0 70px; }

.eyebrow,
.section-kicker,
.note-label {
  margin: 0 0 14px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.eyebrow { color: #b9ddf1; }

.home-hero h1,
.course-hero h1 {
  max-width: 780px;
  margin: 0;
  font-family: "Libre Franklin", sans-serif;
  font-size: clamp(42px, 6vw, 68px);
  line-height: 1.04;
  letter-spacing: -0.045em;
}

.course-hero h1 { font-size: clamp(38px, 5vw, 58px); }

.hero-description {
  max-width: 720px;
  margin: 24px 0 0;
  color: #dceaf2;
  font-size: 18px;
  line-height: 1.65;
}

.archive-stats,
.course-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 30px;
  margin-top: 36px;
  color: #dceaf2;
  font-size: 14px;
}

.archive-stats strong {
  margin-right: 5px;
  color: var(--white);
  font-size: 19px;
}

.course-meta span + span::before,
.archive-stats span + span::before {
  margin-right: 30px;
  color: rgba(255, 255, 255, 0.35);
  content: "/";
}

.courses-shell,
.page-shell {
  width: var(--shell);
  margin: 0 auto;
}

.courses-shell { padding: 72px 0 90px; }

.courses-heading { margin-bottom: 30px; }

.section-kicker { color: var(--blue); }

.courses-heading h2,
.section-heading h2 {
  margin: 0;
  color: var(--navy-deep);
  font-family: "Libre Franklin", sans-serif;
  letter-spacing: -0.025em;
}

.courses-heading h2 { font-size: 30px; }

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

.course-card {
  display: flex;
  min-height: 390px;
  padding: 34px;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-top: 5px solid var(--blue);
  border-radius: 7px;
  box-shadow: var(--shadow);
}

.card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--blue);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.course-card h2 {
  margin: 31px 0 15px;
  color: var(--navy-deep);
  font-family: "Libre Franklin", sans-serif;
  font-size: 30px;
  line-height: 1.2;
  letter-spacing: -0.035em;
}

.course-card > p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.card-stats {
  display: flex;
  gap: 24px;
  margin: 28px 0;
  color: var(--muted);
  font-size: 13px;
}

.card-stats strong { color: var(--navy); }

.card-link {
  display: flex;
  margin-top: auto;
  padding-top: 21px;
  align-items: center;
  justify-content: space-between;
  color: var(--navy);
  border-top: 1px solid var(--line);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.card-link span { transition: transform 160ms ease; }
.card-link:hover span { transform: translateX(4px); }

.section-nav {
  position: sticky;
  z-index: 10;
  top: 0;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.section-nav > div {
  width: var(--shell);
  margin: 0 auto;
  display: flex;
  gap: 30px;
  overflow-x: auto;
  scrollbar-width: none;
}

.section-nav a {
  padding: 18px 0 16px;
  color: var(--muted);
  border-bottom: 2px solid transparent;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.section-nav a:hover {
  color: var(--navy);
  border-bottom-color: var(--blue);
}

.page-shell { padding: 64px 0 90px; }

.materials-section {
  scroll-margin-top: 76px;
  margin-bottom: 72px;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(280px, 0.8fr) minmax(300px, 1.2fr);
  gap: 50px;
  margin-bottom: 24px;
  align-items: end;
}

.section-heading h2 { font-size: 29px; }

.section-heading > p {
  margin: 0 0 2px;
  color: var(--muted);
  font-size: 14px;
}

.resource-list {
  margin: 0;
  padding: 0;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 7px;
  box-shadow: 0 10px 32px rgba(13, 49, 88, 0.05);
  list-style: none;
}

.resource-row {
  display: flex;
  min-height: 90px;
  padding: 19px 22px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.resource-row + .resource-row { border-top: 1px solid var(--line); }

.resource-title-line {
  display: flex;
  align-items: center;
  gap: 10px;
}

.resource-row h3 {
  margin: 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
}

.resource-row p {
  margin: 6px 0 0;
  color: #7a8691;
  font-size: 12px;
}

.tag {
  padding: 3px 7px;
  color: var(--blue);
  background: var(--tag);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.open-link {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 9px 12px;
  color: var(--navy);
  border: 1px solid var(--line-dark);
  border-radius: 5px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

.open-link:hover {
  color: var(--white);
  background: var(--navy);
  border-color: var(--navy);
}

.use-note {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 30px;
  padding: 27px 30px;
  background: var(--blue-soft);
  border-left: 4px solid var(--blue);
  border-radius: 5px;
}

.use-note p { margin: 0; }
.use-note .note-label { color: var(--navy); }
.use-note p:last-child { color: #3f596d; font-size: 14px; }

.site-footer {
  width: var(--shell);
  margin: 0 auto;
  padding: 30px 0 38px;
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  border-top: 1px solid var(--line);
  font-size: 12px;
}

.site-footer p { margin: 0; }
.site-footer a { text-decoration: none; font-weight: 600; }

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

  .site-header { height: 66px; }
  .header-note { display: none; }
  .hero-inner { padding: 58px 0 62px; }
  .course-hero .hero-inner { padding: 50px 0 54px; }
  .home-hero h1, .course-hero h1 { font-size: 39px; }
  .hero-description { font-size: 16px; }
  .archive-stats, .course-meta { gap: 10px 17px; }
  .course-meta span + span::before,
  .archive-stats span + span::before { margin-right: 17px; }

  .courses-shell { padding: 54px 0 66px; }
  .course-grid { grid-template-columns: 1fr; }
  .course-card { min-height: 350px; padding: 27px; }
  .course-card h2 { font-size: 27px; }

  .section-nav > div { gap: 24px; }
  .page-shell { padding: 48px 0 68px; }
  .materials-section { margin-bottom: 58px; }
  .section-heading { display: block; }
  .section-heading > p { margin-top: 10px; }

  .resource-row { padding: 17px; gap: 15px; }
  .resource-title-line { display: block; }
  .tag { display: inline-block; margin-top: 6px; }
  .open-link { padding: 8px 9px; font-size: 0; }
  .open-link span { font-size: 17px; }

  .use-note { display: block; padding: 24px; }
  .use-note p:last-child { margin-top: 8px; }
  .site-footer { gap: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
