/* ===== Neuroclimate site styles ===== */
:root {
  --ink: #1d2b2a;
  --ink-soft: #4a5b59;
  --bg: #fbfaf6;
  --surface: #ffffff;
  --line: #e2e6e1;
  --teal: #1f6f6b;
  --teal-dark: #144b48;
  --teal-tint: #e3f1ef;
  --amber: #e08a2c;
  --amber-tint: #fdf0e1;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(20, 50, 48, 0.08);
  --max: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Source Sans 3", "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: 18px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
}

img, svg, video { max-width: 100%; height: auto; display: block; }

h1, h2, h3 {
  font-family: "Fraunces", Georgia, serif;
  line-height: 1.2;
  color: var(--teal-dark);
  margin: 0 0 0.6em;
}
h1 { font-size: clamp(2rem, 4.5vw, 3.1rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }
a { color: var(--teal); }
a:hover { color: var(--teal-dark); }

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--teal-dark);
  color: #fff;
  padding: 8px 14px;
  border-radius: 8px;
  z-index: 100;
}
.skip-link:focus { left: 8px; }

/* ===== Header / navigation ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 250, 246, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
  gap: 16px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--teal-dark);
  font-family: "Fraunces", Georgia, serif;
  font-weight: 700;
  font-size: 1.2rem;
}
.brand-mark { width: 36px; height: 36px; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 1rem;
  color: var(--ink);
  cursor: pointer;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 4px;
  margin: 0;
  padding: 0;
  align-items: center;
}
.nav-links > li { position: relative; }
.nav-links a, .nav-links button {
  display: block;
  padding: 8px 14px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--ink);
  font: inherit;
  font-size: 0.98rem;
  background: none;
  border: 0;
  cursor: pointer;
}
.nav-links a:hover, .nav-links button:hover,
.nav-links a[aria-current="page"] {
  background: var(--teal-tint);
  color: var(--teal-dark);
}

.dropdown {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  min-width: 320px;
  list-style: none;
  margin: 0;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown,
.has-dropdown.open .dropdown { display: block; }

/* ===== Hero ===== */
.hero {
  padding: 64px 0 48px;
  background:
    radial-gradient(circle at 85% 20%, var(--amber-tint), transparent 45%),
    radial-gradient(circle at 10% 90%, var(--teal-tint), transparent 50%);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 48px;
  align-items: center;
}
.eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 12px;
}
.lead { font-size: 1.2rem; color: var(--ink-soft); }
.article-title { font-size: clamp(1.25rem, 2.4vw, 1.6rem); margin-bottom: 0.8em; }
.section-head h2 + .eyebrow { margin-top: 8px; }
.hero-art {
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--surface);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--teal);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  border: 2px solid var(--teal);
}
.btn:hover { background: var(--teal-dark); border-color: var(--teal-dark); color: #fff; }
.btn-outline { background: transparent; color: var(--teal); }
.btn-outline:hover { background: var(--teal-tint); color: var(--teal-dark); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }

/* ===== Sections ===== */
.section { padding: 56px 0; }
.section-alt { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 720px; margin-bottom: 32px; }

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}
.stat strong {
  display: block;
  font-family: "Fraunces", Georgia, serif;
  font-size: 2.2rem;
  color: var(--amber);
  line-height: 1.1;
  margin-bottom: 6px;
}
.stat span { color: var(--ink-soft); font-size: 0.98rem; }

/* Topic cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card img { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; background: var(--teal-tint); }
.card-body { padding: 20px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.card-num { font-size: 0.85rem; font-weight: 700; color: var(--amber); letter-spacing: 0.06em; }
.card h3 { margin: 4px 0 8px; }
.card p { color: var(--ink-soft); font-size: 0.98rem; flex: 1; }
.card .more { color: var(--teal); font-weight: 600; }

/* Video */
.video-wrap {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #0f2120;
}
.video-wrap video { width: 100%; aspect-ratio: 16 / 9; }
.video-note {
  margin-top: 12px;
  font-size: 0.92rem;
  color: var(--ink-soft);
}

/* Callouts and lists */
.callout {
  background: var(--amber-tint);
  border-left: 5px solid var(--amber);
  border-radius: 10px;
  padding: 18px 22px;
  margin: 24px 0;
}
.callout p:last-child { margin-bottom: 0; }

.check-list { list-style: none; padding: 0; margin: 0 0 1em; }
.check-list li {
  position: relative;
  padding-left: 32px;
  margin-bottom: 10px;
}
.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.35em;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--teal-tint);
  border: 2px solid var(--teal);
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.info-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px;
}
.info-box h3 { color: var(--teal); }
.info-box p:last-child, .info-box ul:last-child { margin-bottom: 0; }
.info-box ul { padding-left: 1.2em; margin: 0; }

/* Page hero for subpages */
.page-hero {
  padding: 48px 0 40px;
  background: linear-gradient(180deg, var(--teal-tint), var(--bg));
}
.breadcrumb { font-size: 0.92rem; color: var(--ink-soft); margin-bottom: 14px; }
.breadcrumb a { color: var(--ink-soft); }

.figure { margin: 0; }
.figure img { border-radius: var(--radius); box-shadow: var(--shadow); background: var(--surface); }
.figure figcaption { font-size: 0.9rem; color: var(--ink-soft); margin-top: 10px; }

/* Worksheet download */
.worksheet {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 24px;
  align-items: center;
  background: var(--teal-dark);
  color: #fff;
  border-radius: 20px;
  padding: 28px 32px;
}
.worksheet h2, .worksheet h3 { color: #fff; margin-bottom: 6px; }
.worksheet p { margin: 0; color: #d5ebe8; }
.worksheet-icon { width: 64px; height: 64px; }
.worksheet .btn { background: var(--amber); border-color: var(--amber); color: #1d2b2a; }
.worksheet .btn:hover { background: #f0a24c; border-color: #f0a24c; }

.worksheet-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.worksheet-list a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
}
.worksheet-list a:hover { border-color: var(--teal); }
.worksheet-list .tag {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--teal);
  background: var(--teal-tint);
  padding: 3px 10px;
  border-radius: 999px;
  white-space: nowrap;
}

/* Prev / next */
.pager {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 8px;
}
.pager a {
  flex: 1 1 260px;
  padding: 16px 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  background: var(--surface);
  color: var(--ink);
}
.pager a:hover { border-color: var(--teal); }
.pager small { display: block; color: var(--ink-soft); }
.pager .next { text-align: right; }

.sources { font-size: 0.95rem; color: var(--ink-soft); }
.sources li { margin-bottom: 6px; }
.sources a { overflow-wrap: anywhere; }
.sources-subhead { margin: 20px 0 8px; font-size: 1rem; color: var(--teal-dark); }

/* Footer */
.site-footer {
  background: #12302e;
  color: #c9dedb;
  padding: 40px 0 28px;
  font-size: 0.95rem;
}
.site-footer a { color: #fff; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 32px;
}
.site-footer h3 { color: #fff; font-size: 1.05rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 6px; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  margin-top: 28px;
  padding-top: 18px;
  font-size: 0.85rem;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .hero-grid, .two-col, .footer-grid { grid-template-columns: 1fr; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-row { grid-template-columns: 1fr; }
  .hero-art { order: -1; }
}

@media (max-width: 760px) {
  body { font-size: 17px; }
  .container { padding: 0 16px; }
  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 68px;
    flex-direction: column;
    align-items: stretch;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    padding: 8px 16px 16px;
  }
  .nav-links.open { display: flex; }
  .dropdown {
    display: block;
    position: static;
    min-width: 0;
    box-shadow: none;
    border: 0;
    padding: 0 0 0 12px;
  }
  .has-dropdown > button { display: none; }
  .card-grid, .info-grid, .worksheet-list { grid-template-columns: 1fr; }
  .worksheet { grid-template-columns: 1fr; text-align: left; padding: 24px; }
  .section { padding: 40px 0; }
}

@media print {
  .site-header, .site-footer, .pager, .video-wrap { display: none; }
}
