:root {
  color-scheme: light dark;
  --bg: #f5efe4;
  --paper: #fffaf2;
  --ink: #182127;
  --muted: #59676e;
  --line: rgb(24 33 39 / 14%);
  --accent: #0d8f86;
  --accent-deep: #0a5c69;
  --accent-soft: rgb(13 143 134 / 11%);
  --gold: #bd8721;
  --source: #7a3527;
  --source-soft: #f2ded5;
  --shadow: 0 24px 70px rgb(25 40 48 / 10%);
  font-family: "Avenir Next", "Segoe UI Variable", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: radial-gradient(circle at 8% 4%, var(--accent-soft), transparent 28rem), var(--bg); color: var(--ink); font-size: 16px; line-height: 1.6; }
a { color: inherit; text-underline-offset: .2em; }
.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 20; padding: .7rem 1rem; background: var(--ink); color: var(--paper); }
.skip-link:focus { top: 1rem; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.site-header, main, footer { width: min(1160px, calc(100% - 2rem)); margin-inline: auto; }
.site-header { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--line); }
.site-header nav, footer nav { display: flex; flex-wrap: wrap; gap: 1rem; }
.site-header nav a { min-height: 44px; display: inline-flex; align-items: center; }
.site-header nav a[aria-current="page"] { color: var(--accent-deep); font-weight: 750; }
.brand { font: 700 1.18rem/1.2 Georgia, "Times New Roman", serif; text-decoration: none; }
.directory-intro { max-width: 850px; padding: clamp(3rem, 9vw, 7.5rem) 0 clamp(3rem, 7vw, 5.5rem); }
.eyebrow, .card-type { color: var(--accent-deep); font-size: .75rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.eyebrow { margin: 0 0 .75rem; }
h1, h2, h3 { font-family: Georgia, "Times New Roman", serif; }
h1 { margin: 0; font-size: clamp(3rem, 8vw, 6.7rem); font-weight: 500; letter-spacing: -.055em; line-height: .96; }
.directory-intro > p:last-child { max-width: 720px; margin: 1.6rem 0 0; color: var(--muted); font: 1.25rem/1.65 Georgia, "Times New Roman", serif; }
.directory-section { padding: clamp(2.5rem, 6vw, 5rem) 0; border-top: 1px solid var(--line); }
.section-heading { display: grid; grid-template-columns: 72px minmax(0, 700px); gap: 1rem; margin-bottom: 2rem; }
.section-number { margin: .45rem 0 0; color: var(--gold); font-weight: 800; letter-spacing: .12em; }
.section-heading h2 { margin: 0; font-size: clamp(2rem, 4vw, 3.25rem); font-weight: 500; letter-spacing: -.035em; }
.section-heading p:last-child { max-width: 650px; margin: .55rem 0 0; color: var(--muted); }
.guided-route { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; margin: 0 0 1rem; padding: 1rem 1.25rem; border-left: 3px solid var(--gold); background: color-mix(in srgb, var(--paper) 58%, transparent); }
.guided-route p { margin: 0; color: var(--muted); }
.guided-route strong { color: var(--ink); }
.guided-route a { flex: 0 0 auto; color: var(--accent-deep); font-weight: 800; text-decoration-thickness: 1px; }
.card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.directory-card { min-height: 280px; display: flex; flex-direction: column; padding: clamp(1.35rem, 3vw, 2rem); border: 1px solid var(--line); border-radius: 16px; background: color-mix(in srgb, var(--paper) 88%, transparent); box-shadow: 0 12px 32px transparent; text-decoration: none; transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.directory-card:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); box-shadow: var(--shadow); }
.directory-card h3, .featured-source h3, .series-card h3 { margin: .7rem 0 .65rem; font-size: clamp(1.55rem, 3vw, 2.25rem); font-weight: 500; letter-spacing: -.025em; }
.directory-card p, .featured-source p, .series-card p { margin: 0; color: var(--muted); }
.card-action { display: inline-flex; align-items: center; gap: .45rem; margin-top: auto; padding-top: 1.5rem; color: var(--accent-deep); font-weight: 800; }
.source-section { position: relative; }
.featured-source { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1.5rem 3rem; padding: clamp(1.5rem, 4vw, 3rem); border: 1px solid color-mix(in srgb, var(--source) 30%, var(--line)); border-radius: 18px; background: linear-gradient(135deg, var(--paper), var(--source-soft)); text-decoration: none; box-shadow: var(--shadow); }
.featured-source .card-type { color: var(--source); }
.featured-source .card-action { align-self: end; color: var(--source); }
.source-meta { min-width: 105px; align-self: start; padding-left: 1.5rem; border-left: 1px solid color-mix(in srgb, var(--source) 28%, transparent); color: var(--source); }
.source-meta strong { display: block; font: 500 clamp(2.75rem, 6vw, 4.5rem)/1 Georgia, "Times New Roman", serif; }
.series-card { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, .8fr); gap: 2rem 4rem; padding: clamp(1.5rem, 4vw, 3rem); border: 1px solid rgb(111 224 213 / 38%); border-radius: 18px; background: linear-gradient(135deg, #123e48, #0a202a 68%, #07171f); color: #f7fbfa; box-shadow: var(--shadow); }
.series-card .card-type { color: #8aeee4; }
.series-card p { color: color-mix(in srgb, var(--paper) 74%, transparent); }
.series-start { min-height: 44px; display: inline-flex; align-items: center; gap: .45rem; margin-top: 1.35rem; padding: .65rem 1rem; border-radius: 999px; background: #8aeee4; color: #09242b; font-weight: 800; text-decoration: none; }
.series-start:hover { background: #b4f5ee; }
.series-meta { min-width: 190px; align-self: center; display: flex; align-items: center; justify-content: center; gap: 1rem; padding: 1.25rem; border: 1px solid rgb(255 255 255 / 18%); border-radius: 12px; background: rgb(0 0 0 / 14%); color: rgb(247 251 250 / 78%); }
.series-meta strong { color: #8aeee4; font: 500 clamp(3.5rem, 8vw, 6rem)/.9 Georgia, "Times New Roman", serif; }
.series-meta span { font-weight: 700; line-height: 1.35; }
footer { display: flex; justify-content: space-between; gap: 2rem; padding: 2rem 0 4rem; border-top: 1px solid var(--line); color: var(--muted); }
footer p { max-width: 580px; margin: 0; }

@media (prefers-color-scheme: dark) {
  :root { --bg: #09131b; --paper: #142832; --ink: #edf5f3; --muted: #b6c7c8; --line: rgb(237 245 243 / 14%); --accent: #4dd3c6; --accent-deep: #8cded6; --accent-soft: rgb(77 211 198 / 12%); --gold: #ebbf68; --source: #eda98e; --source-soft: #503126; --shadow: 0 24px 70px rgb(0 0 0 / 32%); }
  .series-card { background: linear-gradient(135deg, #123e48, #081a22 68%, #040c11); }
}

@media (max-width: 700px) {
  .site-header { align-items: center; }
  .guided-route { align-items: flex-start; flex-direction: column; gap: .65rem; }
  .card-grid, .featured-source, .series-card { grid-template-columns: 1fr; }
  .directory-card { min-height: 240px; }
  .section-heading { grid-template-columns: 44px minmax(0, 1fr); }
  .source-meta { padding: 1rem 0 0; border-left: 0; border-top: 1px solid color-mix(in srgb, var(--source) 28%, transparent); }
  footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .directory-card { transition: none; }
}
