/*
Theme Name: RUHS Anesthesiology
Theme URI: https://ruhealth.org
Author: RUHS Department of Anesthesiology
Description: Custom WordPress theme for RUHS Anesthesiology residency program. Editable via Carbon Fields.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPLv2 or later
Text Domain: ruhs-anesthesiology
*/

/* ==============================================
   RUHS Anesthesiology — Stylesheet
   ==============================================

   TABLE OF CONTENTS
   -----------------
   1.  Variables & Reset
   2.  Typography
   3.  Buttons
   4.  Navigation
   5.  Hero (Home & Page)
   6.  Stats Strip
   7.  Sections & Layout
   8.  Grid System
   9.  Cards — Flip, Regular, Benefit, Flat
   10. Split / Welcome Layout
   11. Testimonial
   12. Person Cards (generic)
   13. Faculty Cards (tiered)
   14. Residents Slider
   15. Alumni Cards
   16. Year Slider, Tabs & Progress
   17. Timeline
   18. Info Block
   19. Protected Learning Time
   20. Pills
   21. Publications
   22. Case Volume Bars
   23. Logo Marquee
   24. Checklist
   25. Code Badge
   26. Contact Card & Form
   27. FAQ Accordion
   28. CTA Banner
   29. Footer
   30. Resources Page
   31. Scroll Animations
   32. Responsive Overrides

   NOTE: Component-specific responsive rules live with
   their component. Global breakpoints are at the end.
   ============================================== */


/* ──────────────────────────────────────────────
   1. VARIABLES & RESET
   ────────────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Ink scale — navy base derived from RUHS logo */
  --ink:         #0c1f3f;
  --ink-80:      #1a3056;
  --ink-60:      #34506e;
  --ink-40:      #6b7f9b;
  --ink-20:      #9badc4;
  --ink-10:      #c7d3e3;
  --ink-05:      #e8edf4;
  --ink-02:      #f4f6f9;
  --white:       #ffffff;

  /* Accent palette — green (primary), navy, orange, purple */
  --accent:      #1a6b4b;
  --accent-dark: #135239;
  --accent-light:#e8f5ef;
  --navy:        #0c1f3f;
  --orange:      #d4742c;
  --orange-light:#fdf3ea;
  --purple:      #5b3a8c;
  --purple-light:#f3eef9;

  /* Borders */
  --border:      #dde3eb;
  --border-dark: #c8d0dc;

  /* Fonts */
  --font-body:   'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-head:   'Libre Baskerville', 'Georgia', serif;

  /* Layout */
  --max-w:       1180px;
  --nav-h:       64px;

  /* Elevation */
  --shadow-xs:   0 1px 2px rgba(10,22,40,0.04);
  --shadow-sm:   0 1px 3px rgba(10,22,40,0.06), 0 1px 2px rgba(10,22,40,0.04);
  --shadow-md:   0 4px 12px rgba(10,22,40,0.08);
  --shadow-lg:   0 12px 32px rgba(10,22,40,0.1);

  /* Motion & Radii */
  --ease:        cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --r-sm:        6px;
  --r-md:        8px;
  --r-lg:        12px;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--ink-80);
  background: var(--white);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; transition: color 0.2s var(--ease); }
ul, ol { list-style: none; }

.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* ──────────────────────────────────────────────
   2. TYPOGRAPHY
   ────────────────────────────────────────────── */
h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.25;
  font-weight: 400;
}
h1 { font-size: clamp(2.25rem, 4.5vw, 3.25rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.625rem, 3vw, 2.25rem); }
h3 { font-size: clamp(1.125rem, 2vw, 1.375rem); }
h4 { font-size: 1.0625rem; font-family: var(--font-body); font-weight: 600; color: var(--ink-80); }

.overline {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.lead {
  font-size: 1.125rem;
  color: var(--ink-40);
  line-height: 1.7;
}

/* ──────────────────────────────────────────────
   3. BUTTONS
   ────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  border-radius: var(--r-sm);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: all 0.25s var(--ease);
}
.btn-primary {
  background: var(--accent);
  color: var(--white);
  border-color: var(--accent);
}
.btn-primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  box-shadow: var(--shadow-md);
}
.btn-nav-outline {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}
.btn-nav-outline:hover,
.btn-nav-outline:active,
.btn-nav-outline.active {
  background: var(--accent);
  color: var(--white);
  border-color: var(--accent);
}
.btn-outline {
  display: inline-flex;
  align-items: center;
  padding: 10px 20px;
  border: 1.5px solid var(--accent);
  border-radius: var(--r-md);
  background: var(--white);
  color: var(--accent);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.btn-outline:hover {
  background: var(--accent);
  color: var(--white);
}
.btn-white {
  background: var(--white);
  color: var(--ink);
  border-color: var(--white);
}
.btn-white:hover {
  background: var(--ink-02);
  box-shadow: var(--shadow-md);
}
.btn-ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,0.35);
}
.btn-ghost:hover {
  border-color: var(--white);
  background: rgba(255,255,255,0.08);
}
.btn svg { width: 16px; height: 16px; }

/* ──────────────────────────────────────────────
   4. NAVIGATION
   ────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  height: var(--nav-h);
}
.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-brand {
  display: flex;
  align-items: center;
  flex-shrink: 1;
  min-width: 0;
}
.nav-logo-img {
  max-height: 29px;
  width: auto;
  height: auto;
  display: block;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}
.nav-links a {
  padding: 8px 11px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--ink-60);
  border-radius: var(--r-sm);
  transition: all 0.2s var(--ease);
}
.nav-links a:hover { color: var(--ink); background: var(--ink-02); }
.nav-links a.active { color: var(--accent); background: var(--accent-light); }
.nav-links .btn { margin-left: 8px; padding: 8px 20px; font-size: 0.8125rem; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--ink);
}
.nav-toggle svg { width: 22px; height: 22px; stroke: currentColor; stroke-width: 2; fill: none; }

/* ──────────────────────────────────────────────
   5. HERO SECTIONS (Home & Page)
   ────────────────────────────────────────────── */
.hero-home {
  position: relative;
  padding: 120px 0 140px;
  background: var(--ink);
  color: var(--white);
  overflow: hidden;
  min-height: 520px;
}
.hero-home::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(135deg, rgba(26,107,75,0.18) 0%, transparent 50%),
    linear-gradient(180deg, rgba(12,31,63,0.55) 0%, rgba(12,31,63,0.7) 50%, rgba(12,31,63,0.85) 100%);
  pointer-events: none;
}
.hero-home .wrap { position: relative; z-index: 2; }

/* Video background */
.hero-video-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  opacity: 0;
  transition: opacity 1.2s ease;
}
.hero-video-wrap.is-ready { opacity: 1; }
.hero-video-wrap.is-ready.is-looping { opacity: 0; transition: opacity 1.3s ease-out; }
.hero-video-wrap.is-ready:not(.is-looping) { transition: opacity 1.0s ease-in; }
.hero-video-wrap iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100vw;
  height: 56.25vw; /* 16:9 ratio */
  min-height: 100%;
  min-width: 177.78vh; /* 100 * 16/9 */
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.hero-home-content {
  max-width: 640px;
}
.hero-home h1 { color: var(--white); margin-bottom: 20px; }
.hero-home .lead { color: rgba(255,255,255,0.75); margin-bottom: 36px; }
.hero-home .overline { color: rgba(255,255,255,0.55); margin-bottom: 16px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Page hero (inner pages) */
.hero-page {
  padding: 72px 0 56px;
  background: var(--ink-02);
  border-bottom: 1px solid var(--border);
}
.hero-page .overline { margin-bottom: 12px; }
.hero-page h1 { margin-bottom: 16px; }
.hero-page .lead { max-width: 640px; }

/* ──────────────────────────────────────────────
   6. STATS STRIP
   ────────────────────────────────────────────── */
.stats-strip {
  padding: 0;
  margin-top: -48px;
  position: relative;
  z-index: 10;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--white);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.stat {
  padding: 32px 24px;
  text-align: center;
  border-right: 1px solid var(--border);
}
.stat:last-child { border-right: none; }
.stat-num {
  font-family: var(--font-head);
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  color: var(--ink);
  line-height: 1;
  margin-bottom: 6px;
}
.stat-label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-40);
}

/* ──────────────────────────────────────────────
   7. SECTIONS & LAYOUT
   ────────────────────────────────────────────── */
.section { padding: 80px 0; }
.section-sm { padding: 56px 0; }
.section-lg { padding: 100px 0; }
.section-tint { background: var(--ink-02); }
.section-accent { background: var(--accent-light); }
.section-dark { background: var(--ink); color: var(--white); }
.section-dark h2, .section-dark h3, .section-dark h4 { color: var(--white); }
.section-dark p, .section-dark .lead { color: rgba(255,255,255,0.65); }
.section-dark .overline { color: var(--ink-20); }

.section-head {
  margin-bottom: 48px;
}
.section-head-center {
  text-align: center;
  max-width: 620px;
  margin-left: auto;
  margin-right: auto;
}
.section-head .overline { margin-bottom: 12px; }
.section-head h2 { margin-bottom: 12px; }
.section-head p { color: var(--ink-40); font-size: 1rem; }

/* ──────────────────────────────────────────────
   8. GRID SYSTEM
   ────────────────────────────────────────────── */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.gap-lg { gap: 32px; }
.gap-xl { gap: 48px; }

/* ──────────────────────────────────────────────
   9. CARDS — Flip, Regular, Benefit, Flat
   ────────────────────────────────────────────── */

/* Flip cards (hover-to-reveal on home page) */
.flip-card {
  perspective: 800px;
  cursor: pointer;
}
.flip-card-inner {
  display: grid;
  height: 100%;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}
.flip-card.is-flipped .flip-card-inner {
  transform: rotateY(180deg);
}
.flip-card-front,
.flip-card-back {
  grid-area: 1 / 1;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 32px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.flip-card:not(.is-flipped):hover .flip-card-front {
  border-color: var(--border-dark);
  box-shadow: var(--shadow-md);
}
.flip-card-front {
  align-items: flex-start;
}
.flip-card-back {
  transform: rotateY(180deg);
}
.flip-card.is-flipped .flip-card-back {
  box-shadow: var(--shadow-md);
  border-color: var(--border-dark);
}
/* Ensure outer grid stretches flip-cards equally */
.grid-3 > .flip-card,
.grid-4 > .flip-card { align-self: stretch; }

/* Blurred description teaser on front face */
.flip-blurred {
  font-size: 0.9375rem;
  color: var(--ink-40);
  filter: blur(4px);
  -webkit-filter: blur(4px);
  user-select: none;
  pointer-events: none;
  line-height: 1.5;
}

/* Flip hint — more prominent */
.flip-hint {
  margin-top: auto;
  padding-top: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  opacity: 0.7;
  transition: opacity 0.3s var(--ease);
}
.flip-card:hover .flip-hint {
  opacity: 1;
}
.flip-hint-text {
  animation: flipHintFade 2.5s ease-in-out infinite;
}
.flip-hint svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  animation: flipHintBounce 2s ease-in-out infinite;
}
@keyframes flipHintBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}
@keyframes flipHintFade {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

/* Regular cards (non-flip, with hover lift) */
.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 32px;
  transition: all 0.3s var(--ease);
}
.card:hover {
  border-color: var(--border-dark);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.card-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--r-sm);
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--accent);
}
.card-icon svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 2; fill: none; }
/* Accent color rotation: navy, orange, purple, green (default) */
.card-icon.icon-navy   { background: #e8edf4; color: var(--navy); }
.card-icon.icon-orange { background: var(--orange-light); color: var(--orange); }
.card-icon.icon-purple { background: var(--purple-light); color: var(--purple); }
.card h3, .flip-card h3 { margin-bottom: 8px; }
.card p, .flip-card p { font-size: 0.9375rem; color: var(--ink-40); }

/* Benefit cards (square, icon-centered — program page) */
.benefit-card {
  aspect-ratio: 1;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.benefit-card:hover {
  border-color: var(--border-dark);
  box-shadow: var(--shadow-md);
}
.benefit-card .card-icon {
  margin: 0 0 16px;
}
.benefit-card h3 {
  margin-bottom: 8px;
}
.benefit-card p {
  font-size: 0.8125rem;
  color: var(--ink-40);
  line-height: 1.5;
}

/* Flat cards (no hover lift — used on tinted backgrounds) */
.card-flat {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 28px;
}
.card-flat h4 { margin-bottom: 8px; }
.card-flat p { font-size: 0.875rem; color: var(--ink-40); }

/* ──────────────────────────────────────────────
   10. SPLIT / WELCOME LAYOUT
   ────────────────────────────────────────────── */
.split {
  display: grid;
  grid-template-columns: 5fr 6fr;
  gap: 64px;
  align-items: center;
}
.split-img {
  border-radius: var(--r-lg);
  overflow: hidden;
  aspect-ratio: 1;
  background: var(--ink-05);
  box-shadow: var(--shadow-md);
}
.split-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--ink-20);
  font-size: 0.75rem;
}
.split-body .overline { margin-bottom: 12px; }
.split-body h2 { margin-bottom: 8px; }
.split-name { font-size: 0.9375rem; font-weight: 600; color: var(--accent); margin-bottom: 2px; }
.split-role { font-size: 0.8125rem; color: var(--ink-40); margin-bottom: 20px; }
.split-body blockquote {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--ink-60);
}

/* ──────────────────────────────────────────────
   11. TESTIMONIAL
   ────────────────────────────────────────────── */
.testimonial {
  max-width: 700px;
  margin: 0 auto;
  text-align: center;
}
.testimonial-mark {
  font-family: var(--font-head);
  font-size: 4rem;
  color: var(--accent);
  opacity: 0.25;
  line-height: 1;
  margin-bottom: -16px;
}
.testimonial blockquote {
  font-family: var(--font-head);
  font-size: 1.25rem;
  font-style: italic;
  color: var(--ink-60);
  line-height: 1.7;
  margin-bottom: 24px;
}
.testimonial-author { font-size: 0.875rem; font-weight: 600; color: var(--ink); }
.testimonial-meta { font-size: 0.8125rem; color: var(--ink-40); }

/* ──────────────────────────────────────────────
   12. PERSON CARDS (generic)
   ────────────────────────────────────────────── */
.person {
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--white);
  transition: all 0.3s var(--ease);
}
.person:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.person-photo {
  aspect-ratio: 1;
  background: var(--ink-05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-10);
}
.person-photo img { width: 100%; height: 100%; object-fit: cover; }
.person-body { padding: 20px; text-align: center; }
.person-body h4 { font-size: 0.9375rem; margin-bottom: 2px; }
.person-body .person-title { font-size: 0.75rem; color: var(--accent); font-weight: 500; margin-bottom: 6px; }
.person-body .person-school { font-size: 0.75rem; color: var(--ink-40); line-height: 1.4; }
.person-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.tag {
  font-size: 0.625rem;
  padding: 2px 8px;
  background: var(--ink-02);
  color: var(--ink-40);
  border-radius: 100px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* ──────────────────────────────────────────────
   13. FACULTY CARDS (tiered layout)
   ────────────────────────────────────────────── */
.fac-grid {
  display: grid;
  gap: 24px;
}
.fac-grid-1 {
  max-width: 520px;
  margin: 0 auto;
}
.fac-grid-2 {
  grid-template-columns: repeat(2, 1fr);
  max-width: 840px;
  margin: 0 auto;
}
.fac-grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

.fac-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  text-align: center;
  transition: all 0.3s var(--ease);
}
.fac-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.fac-card--featured {
  border-color: var(--border);
  border-width: 1px;
}

.fac-photo {
  aspect-ratio: 1;
  background: var(--ink-05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-10);
}
.fac-photo svg { width: 48px; height: 48px; }
.fac-photo--sm svg { width: 40px; height: 40px; }
.fac-photo img { width: 100%; height: 100%; object-fit: cover; }

.fac-info { padding: 20px 16px 24px; }

.fac-name {
  font-size: 1rem;
  color: var(--ink);
  margin-bottom: 2px;
}
.fac-card--featured .fac-name { font-size: 1.25rem; }
.fac-grid-4 .fac-name { font-size: 0.9375rem; }

.fac-rank {
  font-size: 0.8125rem;
  color: var(--ink-40);
  margin-bottom: 8px;
}

.fac-director-titles {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 12px;
}
.fac-director {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent);
}

.fac-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  justify-content: center;
}

@media (max-width: 1024px) {
  .fac-grid-4 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
  .fac-grid-2 { grid-template-columns: 1fr; max-width: 400px; }
  .fac-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .fac-info { padding: 16px 12px 20px; }
  .fac-name { font-size: 0.875rem; }
  .fac-card--featured .fac-name { font-size: 1.0625rem; }
}

/* ──────────────────────────────────────────────
   14. RESIDENTS SLIDER
   ────────────────────────────────────────────── */
.res-slider { max-width: 1080px; }
.res-panel-inner {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 32px 36px;
}
.res-panel-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--ink-02);
}
.res-panel-count {
  font-size: 0.8125rem;
  color: var(--ink-40);
  font-weight: 500;
}
.res-panel-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.res-card {
  display: flex;
  flex-direction: column;
  text-align: center;
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: box-shadow 0.2s var(--ease), transform 0.2s var(--ease);
}
.res-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.res-card-photo {
  width: 100%;
  aspect-ratio: 1;
  background: var(--ink-05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-10);
}
.res-card-info { padding: 16px; min-width: 0; }
.res-card-name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 4px;
  line-height: 1.3;
}
.res-card-role {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 2px;
}
.res-card-school {
  font-size: 0.75rem;
  color: var(--ink-40);
  line-height: 1.4;
}

/* ──────────────────────────────────────────────
   15. ALUMNI CARDS
   ────────────────────────────────────────────── */
.alumni-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.alumni-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}
.alumni-card:last-child {
  border-bottom: none;
}
.alumni-card-body {
  min-width: 0;
  flex: 1;
}
.alumni-card-name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 2px;
  line-height: 1.3;
}
.alumni-card-position {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1.4;
}
.alumni-card-inst {
  font-size: 0.75rem;
  color: var(--ink-40);
  line-height: 1.3;
  margin-top: 2px;
}
.alumni-inst-logo {
  flex-shrink: 0;
  max-width: 120px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  filter: grayscale(100%);
  opacity: 0.4;
  transition: filter 0.3s var(--ease), opacity 0.3s var(--ease);
}
.alumni-inst-logo img {
  max-width: 120px;
  max-height: 48px;
  width: auto;
  height: auto;
  object-fit: contain;
}
.alumni-card:hover .alumni-inst-logo {
  filter: grayscale(0%);
  opacity: 1;
}

/* ──────────────────────────────────────────────
   16. YEAR SLIDER, TABS & PROGRESS
   Shared component: curriculum, residents, alumni.
   Mode 1 (progress bar): residents & curriculum
   Mode 2 (sliding indicator): alumni
   ────────────────────────────────────────────── */
.yr-slider { max-width: 800px; margin: 0 auto; }

.yr-tabs {
  display: flex;
  justify-content: center;
  gap: 0;
  position: relative;
  margin-bottom: 32px;
}
/* When a .yr-progress bar follows tabs, hide the duplicate grey track */
.yr-tabs:has(+ .yr-progress) { margin-bottom: 0; }
.yr-tabs:has(+ .yr-progress) .yr-tabs-track { display: none; }
.yr-tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 12px 16px 20px;
  background: none;
  border: none;
  cursor: pointer;
  position: relative;
  transition: all 0.3s var(--ease);
  opacity: 0.45;
}
.yr-tab:hover { opacity: 0.7; }
.yr-tab--active { opacity: 1; }
.yr-tab-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--ink-10) !important;
  transition: background 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.yr-tab--active .yr-tab-dot {
  background: var(--tab-color) !important;
  box-shadow: 0 0 0 4px rgba(0,0,0,0.06);
}
.yr-tab-label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.yr-tabs-track {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--border);
}
.yr-tabs-indicator {
  position: absolute;
  bottom: 0;
  height: 3px;
  z-index: 1;
  transition: left 0.4s var(--ease), width 0.4s var(--ease), background-color 0.4s var(--ease);
}

/* Progress bar — fills left-to-right (residents & curriculum) */
.yr-progress {
  height: 2px;
  background: var(--border);
  position: relative;
  margin-bottom: 40px;
}
.yr-progress-bar {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 25%;
  background: var(--ink);
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.5s var(--ease);
}

/* Slide panels with directional animation */
.yr-panels { position: relative; overflow: hidden; }
.yr-panel {
  display: none;
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
}
.yr-panel--active {
  display: block;
  opacity: 1;
  transform: translateX(0);
}
.yr-panel--animating {
  display: block;
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.yr-panel-inner {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}
.year-badge {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 100px;
  font-size: 0.6875rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 16px;
  letter-spacing: 0.04em;
}
.yr-panel-header h3 { margin-bottom: 10px; }
.yr-panel-desc { font-size: 0.9375rem; color: var(--ink-40); line-height: 1.7; }
.yr-panel-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.yr-panel-list li {
  font-size: 0.875rem;
  color: var(--ink-60);
  padding: 10px 0 10px 24px;
  position: relative;
  border-bottom: 1px solid var(--ink-02);
  line-height: 1.5;
}
.yr-panel-list li:last-child { border-bottom: none; }
.yr-panel-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--dot-color, var(--accent));
}

/* Prev / Next navigation arrows */
.yr-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-top: 32px;
}
.yr-nav-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  background: var(--white);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  transition: all 0.2s var(--ease);
}
.yr-nav-btn:hover:not(:disabled) {
  border-color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.yr-nav-btn:disabled {
  opacity: 0.3;
  cursor: default;
}
.yr-nav-btn svg { width: 18px; height: 18px; }
.yr-nav-counter {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-40);
  letter-spacing: 0.05em;
  min-width: 40px;
  text-align: center;
}

/* Responsive */
@media (max-width: 768px) {
  .yr-panel-inner {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 28px 24px;
  }
  .yr-tab-label { font-size: 0.625rem; }
  .yr-panels { min-height: auto; }
  .res-panel-inner { padding: 24px 20px; }
  .res-panel-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .res-card { padding: 14px 8px; }
  .res-card-photo { width: 72px; height: 72px; }
}

/* ──────────────────────────────────────────────
   17. TIMELINE (apply page — key dates)
   ────────────────────────────────────────────── */
.timeline { position: relative; padding-left: 40px; }
.timeline::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 4px;
  bottom: 4px;
  width: 1.5px;
  background: var(--border-dark);
}
.tl-item { padding-bottom: 28px; position: relative; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: '';
  position: absolute;
  left: -40px;
  top: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background: var(--white);
  box-sizing: border-box;
}
.tl-date {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 2px;
}
.tl-text { font-size: 0.9375rem; color: var(--ink-60); }

/* ──────────────────────────────────────────────
   18. INFO BLOCK
   ────────────────────────────────────────────── */
.info-block {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 28px 32px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
}
.info-block-icon {
  min-width: 40px;
  height: 40px;
  border-radius: var(--r-sm);
  background: var(--ink-02);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-40);
  box-shadow: var(--shadow-xs);
}
.info-block-icon svg { width: 18px; height: 18px; stroke: currentColor; stroke-width: 2; fill: none; }
.info-block h4 { margin-bottom: 4px; color: var(--ink); }
.info-block p { font-size: 0.875rem; color: var(--ink-40); }

/* ──────────────────────────────────────────────
   19. PROTECTED LEARNING TIME (dark section)
   ────────────────────────────────────────────── */
.plt-section {
  padding: 80px 0;
  background: var(--ink);
  color: var(--white);
}
.plt {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}
.plt-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.15);
  margin-bottom: 24px;
  color: var(--white);
  opacity: 0.6;
}
.plt-icon svg { width: 28px; height: 28px; }
.plt-overline {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  margin-bottom: 12px;
}
.plt-title {
  font-family: var(--heading);
  font-size: 2.25rem;
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 24px;
  color: var(--white);
}
.plt-desc {
  font-size: 1.125rem;
  line-height: 1.7;
  color: rgba(255,255,255,0.7);
  max-width: 680px;
  margin: 0 auto;
}

/* ──────────────────────────────────────────────
   20. PILLS (tags for specialties, conferences)
   ────────────────────────────────────────────── */
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill {
  padding: 6px 16px;
  background: var(--ink-02);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--ink-40);
}

/* ──────────────────────────────────────────────
   21. PUBLICATIONS (PubMed cards)
   ────────────────────────────────────────────── */
.pub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 12px;
}
.pub-count {
  font-size: 0.9375rem;
  color: var(--ink-40);
}
.btn-sm {
  padding: 8px 20px;
  font-size: 0.8125rem;
}

.pub-fade-wrap {
  position: relative;
}
.pub-fade {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 220px;
  background: linear-gradient(to bottom, transparent 0%, var(--ink-02) 100%);
  pointer-events: none;
  z-index: 1;
  transition: opacity 0.4s var(--ease);
}
.pub-fade-wrap--done .pub-fade {
  opacity: 0;
}

.pub-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.pub-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 24px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  text-decoration: none;
  color: inherit;
  transition: all 0.25s var(--ease);
}
.pub-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.pub-card-num {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--ink-02);
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--ink-40);
}

.pub-card-body {
  flex: 1;
  min-width: 0;
}

.pub-card-title {
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.45;
  margin-bottom: 4px;
}
.pub-card:hover .pub-card-title {
  color: var(--accent);
}

.pub-card-authors {
  font-size: 0.8125rem;
  color: var(--ink-40);
  margin-bottom: 8px;
}

.pub-card-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.pub-card-journal {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-60);
  font-style: italic;
}
.pub-card-date {
  font-size: 0.8125rem;
  color: var(--ink-40);
  white-space: nowrap;
}

.pub-card-badge {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--ink-40);
  white-space: nowrap;
}
.pub-card-badge svg {
  width: 14px;
  height: 14px;
}

@media (max-width: 768px) {
  .pub-card {
    flex-direction: column;
    gap: 8px;
    padding: 16px;
  }
  .pub-card-num {
    width: 24px;
    height: 24px;
    font-size: 0.6875rem;
  }
  .pub-card-badge {
    align-self: flex-start;
  }
  .pub-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ──────────────────────────────────────────────
   22. CASE VOLUME BARS (RUHS vs ACGME chart)
   ────────────────────────────────────────────── */
.case-bars {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.case-bar-row {
  display: flex;
  flex-direction: column;
}
.case-bar-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 6px;
}
.case-bar-chart {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.case-bar {
  height: 28px;
  border-radius: 4px;
  width: 0;
  min-width: 8px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  transition: width 4s cubic-bezier(0.22, 0.61, 0.36, 1);
  transition-delay: calc(var(--row-idx, 0) * 0.2s);
}
.case-bars.visible .case-bar {
  width: var(--bar-pct);
}
.case-bar--acgme {
  background: var(--ink-10);
}
.case-bar--ruhs {
  background: var(--accent);
}
.case-bar-val {
  font-size: 0.75rem;
  font-weight: 700;
  padding-right: 10px;
  color: #fff;
  white-space: nowrap;
}
.case-bar--acgme .case-bar-val {
  color: var(--ink-40);
}
.case-bar-legend {
  display: flex;
  justify-content: center;
  gap: 28px;
  margin-top: 12px;
  padding: 20px 24px 0;
  border-top: 1px solid var(--border);
}
.case-bar-legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8125rem;
  color: var(--ink-40);
  font-weight: 500;
}
.case-bar-dot {
  width: 12px;
  height: 12px;
  border-radius: 6px;
  flex-shrink: 0;
}
.case-bar-dot--acgme { background: var(--ink-10); }
.case-bar-dot--ruhs { background: var(--accent); }
@media (max-width: 768px) {
  .case-bar { height: 24px; }
}

/* ──────────────────────────────────────────────
   23. LOGO MARQUEE (conference logos — research page)
   ────────────────────────────────────────────── */
.logo-marquee {
  overflow: hidden;
  width: 100%;
  mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
  padding: 8px 0 0;
}
.logo-marquee-track {
  display: flex;
  width: max-content;
  animation: marquee-scroll 40s linear infinite;
}
.logo-marquee-item {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 240px;
  margin: 0 40px;
}
.logo-marquee-img {
  width: 180px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}
.logo-marquee-img img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.5;
  transition: filter 0.3s var(--ease), opacity 0.3s var(--ease);
}
.logo-marquee-item:hover .logo-marquee-img img {
  filter: grayscale(0%);
  opacity: 1;
}
.logo-marquee-label {
  font-size: 0.75rem;
  color: var(--ink-40);
  line-height: 1.4;
  max-width: 180px;
}
@keyframes marquee-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.logo-marquee:hover .logo-marquee-track {
  animation-play-state: paused;
}
@media (max-width: 768px) {
  .logo-marquee-item { width: 180px; margin: 0 24px; }
  .logo-marquee-img { width: 120px; height: 100px; }
}

/* ──────────────────────────────────────────────
   24. CHECKLIST (green checkmarks)
   ────────────────────────────────────────────── */
.checklist li {
  font-size: 0.9375rem;
  color: var(--ink-60);
  padding: 8px 0 8px 32px;
  position: relative;
}
.checklist li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 12px;
  width: 18px;
  height: 18px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%231a6b4b'%3E%3Cpath fill-rule='evenodd' d='M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z'/%3E%3C/svg%3E") no-repeat center;
  background-size: contain;
}
.checklist-2col { columns: 2; column-gap: 48px; }

/* ──────────────────────────────────────────────
   25. CODE BADGE (NRMP code on apply page)
   ────────────────────────────────────────────── */
.code-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--ink-02);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-60);
}

/* ──────────────────────────────────────────────
   26. CONTACT CARD & FORM
   ────────────────────────────────────────────── */
.contact-card {
  background: var(--ink);
  border-radius: var(--r-lg);
  padding: 48px;
  text-align: center;
  color: var(--white);
}
.contact-card h3 { color: var(--white); margin-bottom: 8px; font-size: 1.5rem; }
.contact-card p { color: rgba(255,255,255,0.6); margin-bottom: 24px; }
.contact-card a { color: var(--ink-20); font-weight: 600; }
.contact-card a:hover { color: var(--white); }

/* Contact form (apply page) */
.cform { display: flex; flex-direction: column; gap: 20px; }
.cform-hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }
.cform-group { display: flex; flex-direction: column; gap: 6px; }
.cform-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink);
}
.cform-req { color: var(--orange); }
.cform-input {
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  color: var(--ink);
  background: var(--white);
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  outline: none;
}
.cform-input::placeholder { color: var(--ink-20); }
.cform-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(26,107,75,0.1);
}
.cform-input.is-invalid {
  border-color: #c0392b;
  box-shadow: 0 0 0 3px rgba(192,57,43,0.08);
}
.cform-textarea { resize: vertical; min-height: 120px; }
.cform-error {
  font-size: 0.8125rem;
  color: #c0392b;
  min-height: 0;
  transition: all 0.2s var(--ease);
}
.cform-error:empty { display: none; }
.cform-error-global {
  font-size: 0.875rem;
  color: #c0392b;
  text-align: center;
  padding: 12px;
  background: rgba(192,57,43,0.06);
  border-radius: var(--r-sm);
}
.cform-error-global:empty { display: none; padding: 0; }
.cform-submit {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 160px;
  justify-content: center;
}
.cform-submit:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}
.cform-spinner {
  width: 18px;
  height: 18px;
  animation: cform-spin 0.8s linear infinite;
}
@keyframes cform-spin { to { transform: rotate(360deg); } }

/* Thank You state */
.cform-thanks {
  text-align: center;
  padding: 64px 24px;
  animation: cform-fadeIn 0.6s ease;
}
@keyframes cform-fadeIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
.cform-thanks-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
}
.cform-thanks-icon svg {
  width: 36px;
  height: 36px;
  stroke: var(--accent);
}
.cform-thanks-title {
  font-family: var(--font-head);
  font-size: 2.25rem;
  color: var(--ink);
  margin-bottom: 12px;
}
.cform-thanks-text {
  font-size: 1.125rem;
  color: var(--ink-40);
  max-width: 400px;
  margin: 0 auto;
  line-height: 1.6;
}

@media (max-width: 768px) {
  .cform-submit { width: 100%; }
  .cform-thanks-title { font-size: 1.75rem; }
}

/* ──────────────────────────────────────────────
   27. FAQ ACCORDION (home page)
   ────────────────────────────────────────────── */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.faq-item {
  border-bottom: 1px solid var(--border);
}
.faq-item:first-child {
  border-top: 1px solid var(--border);
}
.faq-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
}
.faq-question {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.4;
}
.faq-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  color: var(--ink-40);
  transition: transform 0.3s var(--ease), color 0.3s var(--ease);
}
.faq-icon svg {
  width: 24px;
  height: 24px;
}
.faq-item.open .faq-icon {
  transform: rotate(180deg);
  color: var(--accent);
}
.faq-toggle:hover .faq-question {
  color: var(--accent);
}
.faq-toggle:hover .faq-icon {
  color: var(--accent);
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s var(--ease), padding 0.35s var(--ease);
  padding: 0 0;
}
.faq-item.open .faq-answer {
  padding: 0 0 20px;
}
.faq-answer p {
  font-size: 0.9375rem;
  color: var(--ink-40);
  line-height: 1.65;
  margin: 0;
}
.faq-answer a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 600;
  transition: color 0.2s var(--ease);
}
.faq-answer a:hover {
  color: var(--accent-dark);
}

/* ──────────────────────────────────────────────
   28. CTA BANNER (dark call-to-action)
   ────────────────────────────────────────────── */
.cta {
  background: var(--ink);
  padding: 72px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(26,107,75,0.2) 0%, transparent 60%);
}
.cta .wrap { position: relative; z-index: 1; }
.cta h2 { color: var(--white); margin-bottom: 12px; }
.cta p { color: rgba(255,255,255,0.55); font-size: 1rem; margin-bottom: 32px; max-width: 460px; margin-left: auto; margin-right: auto; }
.cta-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ──────────────────────────────────────────────
   29. FOOTER
   ────────────────────────────────────────────── */
.footer {
  background: var(--ink);
  color: var(--ink-20);
  padding: 64px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2.5fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.footer-brand-text {
  font-weight: 700;
  font-size: 0.9375rem;
  color: var(--white);
  margin-bottom: 4px;
}
.footer-brand-sub { font-size: 0.75rem; color: var(--ink-40); margin-bottom: 16px; }
.footer-brand p { font-size: 0.8125rem; color: var(--ink-40); line-height: 1.6; }
.footer h5 {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-40);
  margin-bottom: 20px;
}
.footer-links a {
  display: block;
  font-size: 0.8125rem;
  color: var(--ink-20);
  padding: 4px 0;
  transition: color 0.2s var(--ease);
}
.footer-links a:hover { color: var(--white); }
.footer-bottom {
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  color: var(--ink-40);
}
.footer-social { display: flex; gap: 8px; }
.footer-social a {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--ink-40);
  transition: all 0.2s var(--ease);
}
.footer-social a:hover { border-color: var(--accent); color: var(--white); background: var(--accent); }
.footer-social svg { width: 14px; height: 14px; stroke: currentColor; stroke-width: 2; fill: none; }

/* ──────────────────────────────────────────────
   32. RESPONSIVE OVERRIDES (global breakpoints)
   Component-specific breakpoints live with
   their component above.
   ────────────────────────────────────────────── */

@media (max-width: 1024px) {
  .nav-links a { padding: 8px 8px; font-size: 0.78125rem; }
  .nav-links .btn { padding: 7px 14px; font-size: 0.78125rem; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .hero-home { min-height: 420px; }
  .split { grid-template-columns: 1fr; gap: 40px; }
  .split-img { order: -1; aspect-ratio: 16/9; max-height: 320px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--white);
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    gap: 4px;
  }
  .nav-toggle { display: block; }

  .hero-home { padding: 64px 0 80px; min-height: 380px; }
  .hero-page { padding: 48px 0 40px; }
  .hero-actions { flex-direction: column; }

  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat { padding: 24px 16px; }
  .stat:nth-child(2) { border-right: none; }

  .section { padding: 56px 0; }
  .section-lg { padding: 72px 0; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }

  .checklist-2col { columns: 1; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
}

/* ──────────────────────────────────────────────
   31. SCROLL ANIMATIONS (IntersectionObserver)
   ────────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ──────────────────────────────────────────────
   30. RESOURCES PAGE (password-gated)
   ────────────────────────────────────────────── */

/* Password gate */
.res-gate {
  text-align: center;
  padding: 56px 40px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.res-gate-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 20px;
  color: var(--ink-40);
}
.res-gate-icon svg { width: 100%; height: 100%; }
.res-gate h3 {
  font-family: var(--font-head);
  font-size: 1.4rem;
  color: var(--ink);
  margin-bottom: 8px;
}
.res-gate p {
  color: var(--ink-60);
  margin-bottom: 28px;
  font-size: 0.95rem;
}
.res-gate-error {
  background: #fef2f2;
  color: #b91c1c;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 0.875rem;
  margin-bottom: 20px;
}
.res-gate-form {
  display: flex;
  gap: 10px;
  max-width: 340px;
  margin: 0 auto;
}
.res-gate-input {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: var(--font-body);
  background: var(--ink-02);
  color: var(--ink);
  transition: border-color 0.2s;
}
.res-gate-input:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--white);
}

/* Tab navigation */
.res-tabs {
  display: flex;
  gap: 4px;
  border-bottom: 2px solid var(--border);
  margin-bottom: 32px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  position: relative;
}
.res-tabs::-webkit-scrollbar { display: none; }

/* Sliding green indicator bar */
.res-tabs-indicator {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: var(--accent);
  border-radius: 2px 2px 0 0;
  transition: left 0.35s cubic-bezier(0.4, 0, 0.2, 1),
              width 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  z-index: 2;
}

.res-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  border: none;
  background: none;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-40);
  white-space: nowrap;
  margin-bottom: -2px;
  transition: color 0.25s var(--ease);
}
.res-tab svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  transition: color 0.25s var(--ease);
}
.res-tab:hover { color: var(--ink-60); }
.res-tab--active {
  color: var(--accent);
  font-weight: 600;
}

/* Tab panels */
.res-panel {
  display: none;
  animation: resFadeIn 0.3s var(--ease);
}
.res-panel--active { display: block; }

@keyframes resFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Action buttons (uses .btn-outline from §3) */
.res-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
}

/* Embedded iframes */
.res-embed {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--ink-02);
}
.res-embed iframe {
  display: block;
  width: calc(100% + 20px);   /* push internal scrollbar outside visible area */
  border: none;
  overflow: hidden;
}
.res-embed-loading {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--ink-40);
  font-size: 0.875rem;
  background: var(--ink-02);
  z-index: 1;
}
.res-spinner {
  width: 28px;
  height: 28px;
  border: 2.5px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: resSpin 0.8s linear infinite;
}
@keyframes resSpin { to { transform: rotate(360deg); } }

/* Resource sections & link cards */
.res-section {
  margin-top: 32px;
}
.res-section-heading {
  font-family: var(--font-head);
  font-size: 1.05rem;
  color: var(--ink);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.res-link-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 12px;
}
.res-link-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  text-decoration: none;
  color: var(--ink);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
}
.res-link-card:hover {
  border-color: var(--accent);
  box-shadow: 0 2px 12px rgba(26,107,75,0.08);
  transform: translateY(-1px);
}
.res-link-card-icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-light);
  border-radius: 8px;
  color: var(--accent);
}
.res-link-card-icon svg { width: 18px; height: 18px; }
.res-link-card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.res-link-card-name {
  font-weight: 600;
  font-size: 0.9rem;
  line-height: 1.3;
}
.res-link-card-code {
  font-size: 0.78rem;
  color: var(--ink-40);
  font-family: 'SF Mono', 'Fira Code', monospace;
  margin-top: 2px;
}
.res-link-card-desc {
  font-size: 0.8rem;
  color: var(--ink-40);
  margin-top: 2px;
}
.res-link-card-arrow {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--ink-20);
  transition: color 0.2s;
}
.res-link-card:hover .res-link-card-arrow { color: var(--accent); }

/* Resources — responsive */
@media (max-width: 768px) {
  .res-gate { padding: 40px 24px; }
  .res-gate-form { flex-direction: column; }
  .res-tabs { gap: 0; }
  .res-tab { padding: 12px 14px; font-size: 0.8rem; }
  .res-tab svg { display: none; }
  .res-link-grid { grid-template-columns: 1fr; }
  .res-embed iframe { min-height: 600px; }
}
