*::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ── DESIGN TOKENS (identical to index) ── */
:root {
  --blue-pale:      #D6EAF8;
  --blue-mid:       #5DADE2;
  --blue-deep:      #1565C0;
  --blue-pure:      #0D47A1;
  --white:          #ffffff;
  --glass-border:   rgba(255, 255, 255, 0.38);
  --text-dark:      #0a2540;
  --text-mid:       #1a3a5c;
  --font-display:   'Poppins', sans-serif;
  --font-body:      'Inter', sans-serif;

  /* Section & card specific */
  --card-radius:    16px;
  --section-gap:    1.9rem; /* tightened from 3.5rem so more content is visible per scroll */
}

/* ── BASE ── */
*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  width: 100%;
  min-height: 100%;
}

/*
  Same gradient as index.html — pale blue top → pure blue bottom.
  background-attachment: fixed keeps the gradient steady as the
  user scrolls, so sections feel like they sit on one continuous canvas.
*/
/*
  ── PAGE BACKGROUND ──
  The real medical flat-lay photo sits as the base layer, with the
  original blue gradient laid back on top at partial opacity. That
  keeps the exact same colour story (deep blue top → pale blue
  bottom) so white headings/panel text stay just as readable as
  before, while the photo's syringes/pills/stethoscope add genuine
  texture instead of an abstract pattern. Both layers are pinned
  with background-attachment: fixed so they hold steady on scroll.
*/
body {
  font-family: var(--font-body);
  background-image:
    linear-gradient(
      180deg,
      rgba(13, 71, 161, 0.93) 0%,
      rgba(21, 101, 192, 0.88) 30%,
      rgba(93, 173, 226, 0.80) 65%,
      rgba(214, 234, 248, 0.72) 100%
    ),
    url("assets/medical-bg.jpg");
  background-repeat: no-repeat, no-repeat;
  background-position: center, center;
  background-size: cover, cover;
  background-attachment: fixed, fixed;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ── NAV ── */
/*
  Three-column grid keeps "Back to Home" pinned to the top-left corner
  while the FJHC monogram sits in the true visual centre of the bar,
  regardless of how long the back-link text is.
*/
nav {
  width: 100%;
  max-width: 1180px;
  padding: 1rem 1.5rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}

.nav-back {
  grid-column: 1;
  justify-self: start;
}

.nav-symbol {
  grid-column: 2;
  justify-self: center;
}

/* FJHC monogram — matches the updated index nav */
.nav-symbol {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: var(--blue-deep);
  background: rgba(255, 255, 255, 0.72);
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  border-radius: 8px;
  padding: 0.28rem 0.7rem;
  transition:
    color        0.25s ease,
    background   0.25s ease,
    border-color 0.25s ease,
    box-shadow   0.25s ease,
    transform    0.2s  ease;
  cursor: default;
}

.nav-symbol:hover {
  color: hsl(45, 100%, 50%);
  background: rgba(13, 71, 161, 0.88);
  border-color: rgba(255, 200, 0, 0.6);
  transform: translateY(-1px);
  box-shadow:
    0 0 10px rgba(255, 200, 0,   0.45),
    0 0 24px rgba(13,  71, 161,  0.55),
    0 4px 12px rgba(0,  0,   0,  0.18);
  text-shadow:
    0 0 8px  rgba(255, 215, 0,  0.80),
    0 0 18px rgba(255, 180, 0,  0.45);
}

/* Back link — subtle, white/transparent pill */
.nav-back {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-mid);
  background: rgba(255, 255, 255, 0.45);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 0.28rem 0.9rem;
  text-decoration: none;
  letter-spacing: 0.03em;
  transition: background 0.15s ease;
}

.nav-back:hover {
  background: rgba(255, 255, 255, 0.62);
}

/* ── PAGE HEADER ── */
/*
  Centre-aligned, mirrors the hero style from index.
  Margin pulled way up so the Explore section is visible with
  minimal scrolling on load.
*/
.page-header {
  text-align: center;
  margin-top: 0.6rem;
  padding: 0 1.5rem;
  width: 100%;
}

.page-eyebrow {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 0.5rem;
}

.page-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4.4vw, 2.9rem);
  font-weight: 800;
  color: var(--text-dark);
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin-bottom: 0.4rem;
}

.page-subtitle {
  font-family: var(--font-body);
  font-size: 0.96rem;
  color: var(--text-mid);
  line-height: 1.5;
}

/* ── GOLDEN DIVIDER ── */
/*
  Sits just below the page subtitle. Draws itself from right to left
  on load (transform-origin: right + scaleX animation).
*/
.golden-divider {
  width: 220px;
  max-width: 55%;
  height: 2px;
  margin: 0.9rem auto 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    hsl(45, 95%, 55%) 50%,
    transparent 100%
  );
  transform-origin: right center;
  transform: scaleX(0);
  animation: drawLineRTL 1.1s ease-out forwards;
  box-shadow: 0 0 10px rgba(255, 200, 0, 0.45);
}

@keyframes drawLineRTL {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

@media (prefers-reduced-motion: reduce) {
  .golden-divider {
    animation: none;
    transform: scaleX(1);
  }
}

/* ── SECTION SHARED STYLES ── */
/*
  Each section has consistent top margin and a wider column cap so
  the panels make better use of available screen width — that means
  less vertical stacking and less scrolling overall.
*/
.content-section,
.week-section {
  width: 100%;
  max-width: 1080px;
  padding: 0 1.5rem;
  margin-top: var(--section-gap);
}

/*
  section-topic: the section name displayed as a bold heading above content.
  Acts as the visual topic label, not just an accessible heading.
  Underline accent in deep blue marks where each section begins.
*/
.section-topic {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2.6vw, 1.6rem);
  font-weight: 700;
  color: var(--white);
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid rgba(255, 255, 255, 0.25);
  display: inline-block;
}

/* ── SECTION PANEL ── */
/*
  One wide glassmorphism container per section.
  Stretches to fill the section's max-width column so content
  reads as a unified block rather than scattered cards.
*/
.section-panel {
  width: 100%;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 20px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  overflow: hidden;
}

/* ── PANEL ITEM ── */
/*
  Each topic sits in its own row inside the panel.
  Lead row: icon + title + tag side by side.
  Body text flows full-width below the lead.
*/
.panel-item {
  padding: 1.15rem 1.7rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  transition: background 0.18s ease;
}

.panel-item:hover {
  background: rgba(255, 255, 255, 0.10);
}

/* Icon + title + tag row */
.item-lead {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.item-icon {
  font-size: 1.9rem;
  line-height: 1;
  flex-shrink: 0;
}

.item-meta {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.item-title {
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1.2;
}

.item-body {
  font-family: var(--font-body);
  font-size: 0.92rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.80);
  /* slight indent to align under the title, past the icon */
  padding-left: calc(1.9rem + 1rem); /* icon width + gap */
}

/* ── READ MORE BUTTON ── */
.read-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.1rem;
  margin-left: calc(1.9rem + 1rem); /* aligns under the title */
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: hsl(45, 95%, 62%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.1rem 0;
  transition: color 0.18s ease, letter-spacing 0.18s ease;
}

.read-more-btn:hover {
  color: hsl(45, 100%, 75%);
  letter-spacing: 0.07em;
}

.rm-chevron {
  font-size: 1rem;
  line-height: 1;
  display: inline-block;
  transition: transform 0.22s ease;
}

/* ── EXPAND PANEL ── */
/*
  display: flow-root contains the floated video card without
  needing a manual clearfix, while still letting the text below
  wrap around it naturally.
*/
.item-expand {
  margin-top: 0.75rem;
  display: flow-root;
  animation: expandIn 0.25s ease;
}

@keyframes expandIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Content sits to the RIGHT of the video; once the text runs
   longer than the video's height, it naturally continues at
   full width underneath (standard float-wrap behaviour). */
.item-expand .video-card {
  float: left;
  margin: 0 1.2rem 0.8rem 0;
}

.item-expand .item-body {
  padding-left: 0; /* the float's margin handles spacing, not the icon indent */
  max-height: 4.9rem; /* roughly 3 lines — clamps long write-ups */
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.item-expand .item-body.expanded {
  max-height: none;
}

/* ── SEE MORE BUTTON ── */
/*
  Only shown (via JS) when an item-body is actually being clamped.
  Sits right after the paragraph it controls.
*/
.see-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.5rem;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: hsl(45, 95%, 62%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: color 0.18s ease, letter-spacing 0.18s ease;
}

.see-more-btn:hover {
  color: hsl(45, 100%, 75%);
  letter-spacing: 0.06em;
}

/* ── VIDEO CARD ── */
/*
  Presentable video preview: thumbnail + dark gradient + play button +
  caption row, all wrapped in one clickable card that opens the video
  in a new tab. Replaces the old plain "Watch on YouTube" pill link.
  Sits at the TOP of the expand panel — the write-up text follows below it.
*/
.video-card {
  position: relative;
  display: block;
  width: 100%;
  max-width: 320px;
  border-radius: 14px;
  overflow: hidden;
  text-decoration: none;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.25);
  transition:
    transform    0.2s ease,
    box-shadow   0.2s ease,
    border-color 0.2s ease;
}

.video-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.38);
  border-color: rgba(255, 255, 255, 0.5);
}

.video-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
  background-color: rgba(255, 255, 255, 0.08); /* fallback if thumb fails */
}

.video-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0)    35%,
    rgba(0, 0, 0, 0.78) 100%
  );
}

.video-card-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 0, 0, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow:
    0 0 0 5px rgba(255, 255, 255, 0.12),
    0 4px 16px rgba(0, 0, 0, 0.45);
  transition: transform 0.2s ease, background 0.2s ease;
}

.video-card:hover .video-card-play {
  transform: translate(-50%, -50%) scale(1.08);
  background: rgba(255, 20, 20, 1);
}

.video-card-play-icon {
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 7px 0 7px 12px;
  border-color: transparent transparent transparent #fff;
  margin-left: 2px;
}

.video-card-caption {
  position: absolute;
  left: 0.6rem;
  right: 0.6rem;
  bottom: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.video-card-label {
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: 0.01em;
  text-shadow: 0 1px 5px rgba(0, 0, 0, 0.65);
  /* keep label from overlapping the badge on narrow widths */
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.video-card-badge {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-family: var(--font-body);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(255, 0, 0, 0.88);
  border-radius: 20px;
  padding: 0.16rem 0.5rem;
}

/* Subtle hairline between items */
.panel-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.18);
  margin: 0 1.7rem;
}

/* Category tag — adjusted for dark panel context */
.card-tag {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.90);
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 20px;
  padding: 0.18rem 0.6rem;
  align-self: flex-start;
}

/* ── HEALTH THIS WEEK — topic heading + teaser only ── */
/*
  No enclosed card — the section name functions purely as a topic heading,
  with a teaser line and a highlighted badge for the current week's title.
*/
.week-section {
  margin-bottom: 1.6rem;
}

.week-topic {
  color: hwb(72 95% 3%);
}

.week-lead {
  font-family: var(--font-body);
  font-size: 1.05rem;
  color: lch(19.98% 90.67 305.78 / 0.966);
  margin-bottom: 0.9rem;
  line-height: 1.55;
}

/*
  The week badge highlights the current week's topic title.
  Glass treatment so it sits on the gradient without feeling heavy.
*/
.week-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 12px;
  padding: 0.75rem 1.1rem;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.week-label {
  font-family: var(--font-body);
  font-size: 1.20rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: lch(35.19% 71.08 37.28 / 0.847);
  white-space: nowrap;
}

.week-title-text {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--white);
}

/* Health This Week has no leading icon, so its read-more/body
   shouldn't inherit the icon-width indent used elsewhere. */
.week-section .read-more-btn {
  margin-left: 0;
  margin-top: 0.8rem;
}

.week-section .item-expand {
  margin-top: 0.85rem;
}

.week-section .item-body {
  padding-left: 0;
}

/* ── FOOTER ── */
.footer-hint {
  margin-top: auto;
  padding: 1.8rem 1.5rem 1.4rem;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.55);
  text-align: center;
  font-family: var(--font-body);
  width: 100%;
  letter-spacing: 0.01em;
}

.blue-glow {
  color: hwb(209 2% 79%);
  font-weight: 300;
  display: inline-block;
  text-shadow:
    0 0 6px  #08118b8c,
    0 0 18px rgba(0, 100, 255, 0.30);
}

/* ── GOLD GLOW — designer credit & accents ── */
.gold-glow {
  color: hsl(45, 76%, 38%);
  font-weight: 400;
  display: inline-block;
  text-shadow:
    0 0 6px  #4237048c,
    0 0 18px #972c144d;
}

p{
  color: hwb(249 2% 71%);
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.6;
}

.gold-glow:hover {
  color: hsl(45, 100%, 68%);
  transform: translateY(-2px);
  text-shadow:
    0 0 8px  rgba(255, 220, 0,   0.90),
    0 0 22px rgba(255, 180, 0,   0.60),
    0 0 40px rgba(21,  101, 192, 0.35),
    0 0 60px rgba(13,   71, 161, 0.20);
}

/* ── RESPONSIVE ── */
@media (max-width: 600px) {
  nav {
    padding: 0.85rem 1rem;
    grid-template-columns: 1fr auto 1fr;
    row-gap: 0.5rem;
  }

  .page-header {
    margin-top: 0.4rem;
    padding: 0 1rem;
  }

  .page-title {
    font-size: clamp(1.5rem, 7.5vw, 2rem);
  }

  .page-subtitle {
    font-size: 0.88rem;
  }

  .content-section,
  .week-section {
    padding: 0 1rem;
    margin-top: 1.5rem;
  }

  .section-panel {
    border-radius: 16px;
  }

  .panel-item {
    padding: 1rem 1rem;
    gap: 0.5rem;
  }

  .item-body {
    padding-left: 0;
  }

  .item-expand .video-card {
    float: none;
    margin: 0 0 0.8rem 0;
    max-width: none;
  }

  .item-expand .item-body {
    max-height: 5.6rem; /* a touch taller on mobile's narrower lines */
  }

  .read-more-btn {
    margin-left: 0;
  }

  .panel-divider {
    margin: 0 1rem;
  }

  .video-card-play {
    width: 48px;
    height: 48px;
  }

  .video-card-label {
    font-size: 0.74rem;
  }

  .week-badge {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.3rem;
    width: 100%;
  }

  .footer-hint {
    padding: 1.4rem 1rem 1rem;
    font-size: 0.8rem;
  }

  body {
    /* keeps the photo legible/centred on tall narrow screens too */
    background-position: center top, center top;
  }
}

@media (max-width: 380px) {
  .section-topic {
    font-size: 1.1rem;
  }

  .nav-symbol {
    font-size: 0.75rem;
    padding: 0.2rem 0.5rem;
  }

  .nav-back {
    font-size: 0.7rem;
    padding: 0.22rem 0.7rem;
  }

  .video-card-badge {
    font-size: 0.6rem;
    padding: 0.16rem 0.5rem;
  }
}

/* ── ACCESSIBILITY ── */
@media (prefers-reduced-motion: reduce) {
  .panel-item   { transition: none; }
  .nav-back     { transition: none; }
  .nav-symbol   { transition: none; }
  .video-card   { transition: none; }
  .video-card-play { transition: none; }
}