/* APS News — Concept D stylesheet (v1)
   Cherry Velvet #A7131A / Cherry Bright #D21C32 / Midnight Navy #25324E / Glacier White #FAFAFA
   Headlines: thin Didone serif (Playfair Display Light). Labels: bold condensed sans (Oswald). */

:root {
  --cherry: #A7131A;
  --cherry-bright: #D21C32;
  --navy: #25324E;
  --white: #FAFAFA;
  --ink: #1d2438;
  --muted: #6b7280;
  --line: #e5e1d8;
  --card: #ffffff;
  --shadow: 0 2px 14px rgba(37, 50, 78, 0.08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

/* ---------- Masthead ---------- */
.masthead {
  background: linear-gradient(135deg, var(--white) 55%, #f3ecec 100%);
  border-bottom: 4px solid var(--cherry);
  padding: 1.2rem 1rem 1rem;
  position: relative;
  overflow: hidden;
}
.masthead::after { /* diagonal red block accent */
  content: "";
  position: absolute; top: -40px; right: -60px;
  width: 220px; height: 300px;
  background: linear-gradient(160deg, var(--cherry-bright), var(--cherry));
  transform: skewX(-18deg);
  opacity: 0.14;
  pointer-events: none;
}
.masthead-inner {
  max-width: 1180px; margin: 0 auto;
  display: flex; align-items: center; gap: 1rem;
}
.brand-badge {
  width: 64px; height: 64px; border-radius: 16px; flex: 0 0 auto;
  background: linear-gradient(150deg, var(--cherry-bright), var(--cherry) 70%);
  color: #fff; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  font-family: "Playfair Display", Didot, serif; font-weight: 300;
  font-size: 0.72rem; letter-spacing: 0.14em; line-height: 1.25;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.35), var(--shadow);
}
.brand-badge span { border-bottom: 1px solid rgba(255,255,255,.8); padding-bottom: 2px; }
.masthead h1 {
  font-family: "Playfair Display", Didot, serif; font-weight: 300;
  color: var(--navy); font-size: 2rem; margin: 0; letter-spacing: 0.02em;
}
.kicker {
  font-family: "Oswald", "Arial Narrow", sans-serif;
  color: var(--cherry); letter-spacing: 0.28em; font-size: 0.72rem;
  text-transform: uppercase; margin: 0 0 0.15rem;
}
.tagline {
  font-family: "Playfair Display", Didot, serif; font-style: italic;
  color: var(--muted); margin: 0.1rem 0 0; font-size: 0.95rem;
}
.mainnav {
  max-width: 1180px; margin: 0 auto; padding: 0.55rem 1rem;
  display: flex; gap: 1.4rem; flex-wrap: wrap;
  font-family: "Oswald", sans-serif; font-size: 0.85rem;
  letter-spacing: 0.12em; text-transform: uppercase;
}
.mainnav a { color: var(--navy); text-decoration: none; }
.mainnav a:hover { color: var(--cherry); }

/* ---------- Layout ---------- */
.wrap { max-width: 1180px; margin: 0 auto; padding: 1.5rem 1rem 3rem; }
.section-head {
  display: flex; align-items: baseline; gap: 0.8rem;
  border-bottom: 2px solid var(--line); margin: 2.2rem 0 1.1rem; padding-bottom: 0.4rem;
}
.section-head h2 {
  font-family: "Playfair Display", Didot, serif; font-weight: 300;
  color: var(--navy); font-size: 1.6rem; margin: 0;
}
.section-head .bug {
  font-family: "Oswald", sans-serif; background: var(--cherry); color: #fff;
  font-size: 0.68rem; letter-spacing: 0.2em; padding: 0.2rem 0.6rem;
  border-radius: 3px; text-transform: uppercase;
}

/* ---------- Category windows ---------- */
.cat-grid {
  display: grid; gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}
.cat-window {
  background: var(--card); border: 1px solid var(--line); border-radius: 10px;
  padding: 1rem 1rem 0.9rem; box-shadow: var(--shadow);
  border-top: 4px solid var(--cherry);
  display: flex; flex-direction: column; min-height: 150px;
  transition: transform .15s ease;
}
.cat-window:hover { transform: translateY(-2px); }
.cat-window h3 {
  font-family: "Playfair Display", Didot, serif; font-weight: 400;
  color: var(--navy); font-size: 1.05rem; margin: 0 0 0.35rem;
}
.cat-window p { color: var(--muted); font-size: 0.86rem; margin: 0 0 0.6rem; flex: 1; }
.cat-window .count {
  font-family: "Oswald", sans-serif; font-size: 0.72rem; letter-spacing: 0.14em;
  color: var(--cherry); text-transform: uppercase;
}
.cat-window.empty { border-top-color: var(--line); opacity: 0.75; }

/* ---------- Headlines ---------- */
.headline-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.9rem; }
.headline-list li {
  background: var(--card); border: 1px solid var(--line); border-radius: 8px;
  padding: 0.85rem 1rem; box-shadow: var(--shadow);
}
.headline-list .meta {
  font-family: "Oswald", sans-serif; font-size: 0.7rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--cherry); margin-bottom: 0.25rem;
}
.headline-list p { margin: 0; }
.headline-list a { color: var(--navy); }
.article-body a { color: var(--cherry); }

/* ---------- County article ---------- */
.article-body h3 {
  font-family: "Playfair Display", Didot, serif; font-weight: 400;
  color: var(--navy); font-size: 1.25rem;
  border-bottom: 2px solid var(--cherry); display: inline-block;
  padding-bottom: 0.15rem; margin: 1.6rem 0 0.6rem;
}
.article-body ul { margin: 0.4rem 0 0; padding-left: 1.2rem; }
.article-body li { margin-bottom: 0.55rem; }
.county-grid {
  display: grid; gap: 0.8rem;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  margin: 1rem 0 2rem;
}
.county-grid a {
  background: var(--card); border: 1px solid var(--line); border-radius: 8px;
  padding: 0.7rem 0.9rem; color: var(--navy); text-decoration: none;
  font-family: "Playfair Display", serif; box-shadow: var(--shadow);
}
.county-grid a:hover { border-color: var(--cherry); color: var(--cherry); }

/* ---------- Weather ---------- */
.weather-card {
  background: linear-gradient(150deg, #fff, #f6f1f1);
  border: 1px solid var(--line); border-left: 5px solid var(--cherry);
  border-radius: 10px; padding: 1rem 1.2rem; box-shadow: var(--shadow);
}
.weather-card .wrow { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.weather-card .wday strong {
  font-family: "Oswald", sans-serif; letter-spacing: 0.14em; font-size: 0.75rem;
  color: var(--cherry); text-transform: uppercase; display: block;
}
.weather-src { font-size: 0.75rem; color: var(--muted); margin-top: 0.5rem; }

/* ---------- Video embeds ---------- */
.video-grid { display: grid; gap: 1.2rem; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.embed-16x9 { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; border-radius: 10px; box-shadow: var(--shadow); background: #111; }
.embed-16x9 iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }
.video-slot { border: 2px dashed var(--line); border-radius: 10px; padding: 2rem 1rem; text-align: center; color: var(--muted); }
.video-cap { font-size: 0.85rem; color: var(--muted); margin-top: 0.4rem; }

/* ---------- Ads (placeholders) ---------- */
.ad-slot {
  background: #f4f2ee; border: 1px dashed #c9c2b4; border-radius: 6px;
  color: #a09a8c; text-align: center; font-size: 0.75rem;
  letter-spacing: 0.18em; text-transform: uppercase;
  display: flex; align-items: center; justify-content: center;
  font-family: "Oswald", sans-serif; margin: 1.2rem 0;
}
.ad-leaderboard { min-height: 90px; }
.ad-sidebar { min-height: 250px; }
.ad-inarticle { min-height: 120px; }

/* ---------- Affiliate ---------- */
.affiliate-block {
  border: 1px solid var(--line); border-left: 5px solid var(--cherry-bright);
  background: #fffdf8; border-radius: 8px; padding: 0.9rem 1.1rem; margin: 1.2rem 0;
}
.affiliate-block .aff-label {
  font-family: "Oswald", sans-serif; font-size: 0.68rem; letter-spacing: 0.2em;
  color: var(--muted); text-transform: uppercase;
}
.affiliate-block a.aff-link { color: var(--cherry); font-weight: 600; }

/* ---------- Newsletter side tab ---------- */
.news-tab {
  position: fixed; right: 0; top: 38%; z-index: 60;
  background: linear-gradient(160deg, var(--cherry-bright), var(--cherry));
  color: #fff; border: 0; border-radius: 8px 0 0 8px;
  font-family: "Oswald", sans-serif; letter-spacing: 0.16em; text-transform: uppercase;
  font-size: 0.78rem; padding: 0.9rem 0.55rem; cursor: pointer;
  writing-mode: vertical-rl; box-shadow: var(--shadow);
}
.news-panel {
  position: fixed; right: 0; top: 0; height: 100%; width: min(360px, 92vw); z-index: 61;
  background: #fff; box-shadow: -6px 0 24px rgba(37,50,78,.18);
  transform: translateX(105%); transition: transform .28s ease;
  padding: 1.6rem 1.4rem; overflow-y: auto;
}
.news-panel.open { transform: none; }
.news-panel h2 { font-family: "Playfair Display", serif; font-weight: 300; color: var(--navy); margin-top: 0; }
.news-panel label { font-size: 0.85rem; display: block; margin: 0.7rem 0 0.25rem; }
.news-panel input {
  width: 100%; padding: 0.6rem 0.7rem; border: 1px solid var(--line);
  border-radius: 6px; font-size: 1rem;
}
.btn {
  display: inline-block; margin-top: 1rem; border: 0; cursor: pointer;
  background: linear-gradient(160deg, var(--cherry-bright), var(--cherry));
  color: #fff; font-family: "Oswald", sans-serif; letter-spacing: 0.14em;
  text-transform: uppercase; font-size: 0.85rem; padding: 0.7rem 1.4rem; border-radius: 6px;
}
.news-close { background: none; border: 0; font-size: 1.4rem; float: right; cursor: pointer; color: var(--muted); }
.news-note { font-size: 0.78rem; color: var(--muted); margin-top: 0.8rem; }

/* ---------- Footer ---------- */
footer {
  background: var(--navy); color: #dfe3ec; margin-top: 3rem;
  padding: 2rem 1rem; font-size: 0.9rem;
}
footer .wrap { padding: 0 1rem; }
footer a { color: #fff; }
footer .signoff { font-family: "Playfair Display", serif; font-style: italic; color: #aeb6c9; }

@media (max-width: 640px) {
  .masthead h1 { font-size: 1.45rem; }
  .section-head h2 { font-size: 1.25rem; }
}

/* ---------- 3D forecast widget (forecast-3d.js) ---------- */
.f3d {
  position: relative; border-radius: 14px; overflow: hidden;
  margin-top: 1rem; background: #101a30; box-shadow: var(--shadow);
}
.f3d-bgimg {
  position: absolute; inset: 0; pointer-events: none;
  background-color: #16213c; /* fallback gradient base under the image */
  background-size: cover; background-position: center;
  opacity: 0.45;
}
.f3d-shade {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(10,18,36,.74), rgba(10,18,36,.36) 46%, rgba(10,18,36,.68));
}
.f3d-head {
  position: relative; z-index: 2; display: flex; align-items: center; gap: 0.6rem;
  padding: 0.9rem 1.1rem 0.1rem; color: #fff;
}
.f3d-head .bug {
  font-family: "Oswald", sans-serif; background: var(--cherry); color: #fff;
  font-size: 0.66rem; letter-spacing: 0.2em; padding: 0.2rem 0.6rem;
  border-radius: 3px; text-transform: uppercase; flex: 0 0 auto;
}
.f3d-head h3 {
  font-family: "Playfair Display", Didot, serif; font-weight: 300;
  margin: 0; color: #fff; font-size: 1.3rem;
  text-shadow: 0 1px 10px rgba(0,0,0,.55);
}
.f3d-place {
  margin-left: auto; font-family: "Oswald", sans-serif; font-size: 0.7rem;
  letter-spacing: 0.14em; text-transform: uppercase; color: #ffd9dc;
  text-shadow: 0 1px 6px rgba(0,0,0,.6); white-space: nowrap;
}
.f3d-viewport {
  position: relative; z-index: 2; overflow-x: auto;
  padding: 0.7rem 1.1rem 0.9rem; scrollbar-width: thin;
}
.f3d-track {
  position: relative; display: flex; gap: 0.6rem;
  width: max-content; min-width: 100%;
}
.f3d-gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.f3d-card {
  position: relative; z-index: 1; width: 106px; flex: 0 0 auto;
  background: rgba(250,250,250,.95); border-radius: 10px;
  padding: 0.45rem 0.4rem 0.55rem; text-align: center;
  box-shadow: 0 2px 10px rgba(0,0,0,.28);
}
.f3d.compact .f3d-card { width: 94px; }
.f3d-view { height: 88px; border-radius: 6px; overflow: hidden; }
.f3d.compact .f3d-view { height: 72px; }
.f3d-view svg { width: 100%; height: 100%; display: block; }
.f3d-day {
  font-family: "Oswald", sans-serif; font-size: 0.7rem; letter-spacing: 0.16em;
  color: var(--navy); margin-top: 0.35rem; text-transform: uppercase;
}
.f3d-temps { font-weight: 600; font-size: 0.95rem; margin: 0.1rem 0; color: var(--ink); }
.f3d-temps .hi { color: var(--cherry); }
.f3d-temps .lo { color: var(--muted); margin-left: 0.4rem; font-weight: 400; }
.f3d-cond {
  font-size: 0.72rem; color: var(--ink); line-height: 1.25;
  min-height: 2.2em; overflow: hidden;
}
.f3d-status {
  position: relative; z-index: 2; margin: 0; padding: 0 1.1rem 0.9rem;
  font-size: 0.72rem; color: #dbe2f0; text-shadow: 0 1px 6px rgba(0,0,0,.65);
}
@media (max-width: 640px) {
  .f3d-card { width: 96px; }
  .f3d-head h3 { font-size: 1.1rem; }
  .f3d-place { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .f3d { background: linear-gradient(160deg, #16213c, #25324E); }
}

/* ---------- Leading Headlines hero ---------- */
.hero-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); margin: 0.5rem 0 0.5rem; }
.hero-card {
  background: var(--card); border: 1px solid var(--line); border-top: 4px solid var(--cherry);
  border-radius: 8px; padding: 1rem 1.15rem; box-shadow: var(--shadow);
  display: flex; flex-direction: column;
}
.hero-card.lead { grid-column: 1 / -1; border-top-width: 5px; padding: 1.3rem 1.4rem; }
.hero-card .meta {
  font-family: "Oswald", sans-serif; font-size: 0.68rem; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--cherry); margin-bottom: 0.35rem;
}
.hero-card h3 {
  font-family: "Playfair Display", Didot, serif; font-weight: 300;
  font-size: 1.3rem; line-height: 1.32; color: var(--navy); margin: 0 0 0.5rem;
}
.hero-card.lead h3 { font-size: 1.9rem; line-height: 1.25; }
.hero-card h3 a { color: inherit; text-decoration: none; }
.hero-card h3 a:hover { color: var(--cherry); }
.hero-card p { margin: 0; color: var(--muted); font-size: 0.9rem; flex: 1; }
.hero-card .hero-link { margin-top: 0.6rem; font-weight: 600; color: var(--cherry); font-size: 0.88rem; }

/* ---------- Archive callout (county pages) ---------- */
.archive-callout {
  border: 1px solid var(--line); border-left: 5px solid var(--cherry);
  background: linear-gradient(150deg, #fff, #faf5f5);
  border-radius: 8px; padding: 1.1rem 1.3rem; margin: 2rem 0 1rem;
  box-shadow: var(--shadow);
}
.archive-callout h3 {
  font-family: "Oswald", sans-serif; font-size: 0.8rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--cherry); margin: 0 0 0.4rem;
}
.archive-callout p { margin: 0.3rem 0; font-size: 0.92rem; color: var(--ink); }
.archive-callout a { color: var(--cherry); font-weight: 600; }

/* ---------- County selector (homepage weather) ---------- */
.wx-select-row {
  display: flex; align-items: center; gap: 0.7rem; flex-wrap: wrap;
  margin: 0 0 0.9rem;
}
.wx-select-row label {
  font-family: "Oswald", sans-serif; font-size: 0.72rem; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--cherry);
}
.wx-select {
  font-family: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  font-size: 0.95rem; color: var(--navy);
  background: #fff; border: 2px solid var(--navy); border-radius: 8px;
  padding: 0.45rem 2rem 0.45rem 0.8rem; max-width: 100%;
  appearance: none; -webkit-appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23A7131A' stroke-width='2'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 0.7rem center;
  box-shadow: var(--shadow);
}
.wx-select:hover { border-color: var(--cherry); }
.wx-select:focus { outline: 2px solid var(--cherry-bright); outline-offset: 1px; }

/* ---------- Article reader modal ---------- */
.reader-overlay {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(29, 36, 56, 0.62);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 4vh 1rem;
  overflow-y: auto;
}
.reader-overlay[hidden] { display: none; }
.reader-card {
  position: relative;
  background: var(--white);
  color: var(--ink);
  max-width: 44rem; width: 100%;
  border-radius: 14px;
  border-top: 5px solid var(--cherry);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.35);
  padding: 2.2rem 2.4rem 2rem;
  max-height: 92vh; overflow-y: auto;
}
.reader-close {
  position: absolute; top: 0.7rem; right: 0.9rem;
  border: 0; background: none; cursor: pointer;
  font-size: 2rem; line-height: 1; color: var(--muted);
}
.reader-close:hover { color: var(--cherry); }
.reader-eyebrow {
  font-family: "Oswald", sans-serif; font-size: 0.72rem;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--cherry); margin: 0 0 0.6rem;
}
.reader-title {
  font-family: "Playfair Display", Didot, serif; font-weight: 300;
  font-size: clamp(1.7rem, 4.5vw, 2.6rem);
  line-height: 1.18; color: var(--navy);
  margin: 0 0 0.7rem;
}
.reader-byline {
  font-size: 0.85rem; color: var(--muted);
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.9rem; margin: 0 0 1.2rem;
}
.reader-body {
  font-family: "Playfair Display", Didot, Georgia, serif;
  font-size: 1.13rem; line-height: 1.75; color: var(--ink);
  font-weight: 700; /* owner: bold article text for easy reading/engagement */
}
.reader-body p { margin: 0 0 1.1rem; max-width: 38rem; }
.reader-body h4 {
  font-family: "Oswald", sans-serif; font-size: 0.95rem;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--navy); margin: 1.6rem 0 0.5rem;
  border-left: 3px solid var(--cherry); padding-left: 0.6rem;
}
.reader-sources {
  margin-top: 1.8rem; padding-top: 0.8rem;
  border-top: 1px solid var(--line);
}

/* ---------- Sources footer (inline lists + reader) ---------- */
p.sources {
  font-size: 0.72rem; color: #9aa1b2; margin: 0.35rem 0 1.1rem;
  letter-spacing: 0.02em;
}

/* ---------- Tappable news items ---------- */
.news-item { cursor: pointer; }
.headline-list .news-item:hover p,
.hero-card:hover .hero-title { color: var(--cherry); }
.hero-card { cursor: pointer; }
.cat-window.tappable { cursor: pointer; }
.cat-window.tappable:hover { border-color: var(--cherry); }
.article-body li.news-item { cursor: pointer; }
.article-body li.news-item:hover { color: var(--cherry); }

@media (max-width: 560px) {
  .reader-card { padding: 1.6rem 1.2rem 1.4rem; }
  .reader-body { font-size: 1.05rem; }
}

/* ---------- Tappable affordances + reader extras ---------- */
.headline-list .meta {
  font-family: "Oswald", sans-serif; font-size: 0.7rem;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--cherry); margin: 0 0 0.4rem;
}

/* ---------- Reader internal link ---------- */
.reader-more { margin-top: 1.4rem; font-size: 0.95rem; }
.reader-more a { color: var(--cherry); font-weight: 600; }

/* ---------- Masthead logo-loop video background ---------- */
.masthead-video {
  position: absolute; inset: -3.5%; width: 107%; height: 107%;
  object-fit: cover; z-index: 0; pointer-events: none;
  will-change: transform;
}
.masthead-veil {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(115deg,
    rgba(13, 22, 41, 0.88) 0%,
    rgba(37, 50, 78, 0.62) 55%,
    rgba(120, 15, 25, 0.45) 100%);
}
.masthead.has-video .masthead-inner { position: relative; z-index: 2; }
.masthead.has-video { border-bottom-color: var(--cherry-bright); }
.masthead.has-video::after { opacity: 0.07; }
.masthead.has-video h1 {
  color: #fff; font-weight: 700;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.65);
}
.masthead.has-video .kicker {
  color: #ff5c6e; font-weight: 700;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.6);
}
.masthead.has-video .tagline {
  color: #f2f4fa; font-weight: 600;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.6);
}
.masthead.has-video .brand-badge {
  box-shadow: inset 0 1px 0 rgba(255,255,255,.35), 0 4px 18px rgba(0,0,0,.45);
}
@media (prefers-reduced-motion: reduce) {
  /* Static brand badge instead of video; masthead falls back to light theme. */
  .masthead-video, .masthead-veil { display: none; }
  .masthead.has-video h1 { color: var(--navy); text-shadow: none; }
  .masthead.has-video .kicker { color: var(--cherry); text-shadow: none; }
  .masthead.has-video .tagline { color: var(--muted); text-shadow: none; }
  .masthead.has-video::after { opacity: 0.14; }
}

/* ---------- Sticky translucent masthead ---------- */
.masthead.has-video {
  position: sticky; top: 0; z-index: 400;
  /* genuinely transparent — slight tint only, page content shows through */
  background: rgba(13, 22, 41, 0.32);
  -webkit-backdrop-filter: blur(10px) saturate(1.2);
  backdrop-filter: blur(10px) saturate(1.2);
  border-bottom: 2px solid rgba(210, 28, 50, 0.65);
}
.masthead.has-video .masthead-video { opacity: 0.55; }  /* video visible, text stays readable */
/* Veil removed — header is genuinely transparent now, no graded washout. */
.masthead.has-video .masthead-veil {
  background: linear-gradient(115deg,
    rgba(13, 22, 41, 0.18) 0%,
    rgba(37, 50, 78, 0.10) 55%,
    rgba(167, 19, 26, 0.12) 100%);
}
/* Anchor targets clear the sticky header (no covered jumps). */
section[id], article[id] { scroll-margin-top: 130px; }
@media (max-width: 640px) {
  section[id], article[id] { scroll-margin-top: 110px; }
}

/* ---------- Community Board + Submit a Story ---------- */
.community-wrap {
  display: grid; gap: 1.5rem;
  grid-template-columns: 1fr;
}
@media (min-width: 900px) {
  .community-wrap { grid-template-columns: 1.1fr 0.9fr; }
}
.board-list { display: grid; gap: 0.8rem; margin: 1rem 0; }
.board-msg {
  border: 1px solid var(--line); border-left: 4px solid var(--cherry-bright);
  border-radius: 8px; padding: 0.7rem 1rem; background: #fffdf8;
}
.board-msg p { margin: 0.25rem 0; }
.board-meta { font-size: 0.8rem; color: var(--muted); }
.board-meta strong { color: var(--navy); }
.board-review {
  font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--cherry); border: 1px solid var(--cherry); border-radius: 4px;
  padding: 0.05rem 0.35rem; margin-left: 0.4rem;
}
.board-empty { color: var(--muted); font-style: italic; }
.board-form label, .story-form label {
  font-size: 0.85rem; display: block; margin: 0.7rem 0 0.25rem; font-weight: 600;
}
.board-form input[type="text"], .story-form input[type="text"],
.story-form input[type="email"], .story-form select,
.board-form textarea, .story-form textarea {
  width: 100%; padding: 0.6rem 0.7rem; border: 1px solid var(--line);
  border-radius: 6px; font-size: 1rem; font-family: inherit; background: #fff;
}
.board-form textarea, .story-form textarea { min-height: 5rem; resize: vertical; }
.hp-field { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.board-status, .story-status { font-size: 0.85rem; color: var(--cherry); margin-top: 0.7rem; min-height: 1.2em; }
.story-note {
  font-size: 0.82rem; color: var(--muted); font-style: italic;
  border-left: 3px solid var(--cherry-bright); padding-left: 0.7rem; margin: 0.6rem 0 0;
}

/* ---------- Health monitor dot + panel ---------- */
.health-dot {
  display: inline-block; width: 10px; height: 10px; border-radius: 50%;
  margin-left: 0.6rem; vertical-align: baseline; background: #8a93a8;
}
.health-green { background: #2fae5f; box-shadow: 0 0 6px rgba(47,174,95,.7); }
.health-amber { background: #e8a13a; box-shadow: 0 0 6px rgba(232,161,58,.7); }
.health-red { background: #d21c32; box-shadow: 0 0 6px rgba(210,28,50,.8); }
.health-panel {
  position: fixed; inset: 0; z-index: 1200; background: rgba(13,22,41,.55);
  display: flex; align-items: center; justify-content: center; padding: 1rem;
}
.health-panel[hidden] { display: none; }
.health-card {
  background: #fff; border-radius: 10px; max-width: 520px; width: 100%;
  max-height: 80vh; overflow-y: auto; padding: 1.4rem 1.5rem; color: var(--ink);
  box-shadow: 0 12px 40px rgba(0,0,0,.3);
}
.health-card h3 { font-family: "Playfair Display", serif; color: var(--navy); margin: 0 0 0.6rem; }
.health-card h4 { font-family: "Oswald", sans-serif; font-size: 0.8rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin: 1rem 0 0.4rem; }
.health-card ul { margin: 0.3rem 0; padding-left: 1.1rem; font-size: 0.88rem; }
.health-pill {
  font-size: 0.68rem; letter-spacing: 0.06em; text-transform: uppercase;
  border-radius: 4px; padding: 0.1rem 0.4rem; color: #fff; margin-right: 0.3rem;
}
.health-pill.ok { background: #2fae5f; }
.health-pill.bad { background: #d21c32; }
.health-pill.skip { background: #8a93a8; }
.health-errors li { margin-bottom: 0.4rem; }
.health-src { color: var(--muted); font-size: 0.78rem; }
.health-note { font-size: 0.78rem; color: var(--muted); font-style: italic; margin-top: 1rem; }
.health-close { background: none; border: 0; font-size: 1.4rem; float: right; cursor: pointer; color: var(--muted); }
