/*
 * ps-news-style.css
 * Page-specific styles for news releases on the newspaper layout
 * (news/news_26/newspaper-release-template.html and every release copied from it),
 * built on the new cp-*-root.dwt template.
 *
 *   main-style.css   ->  site layout (section, subnav, eyebrow/title)
 *   THIS FILE        ->  page-specific design.  Every class below is `ps-`.
 *
 * Contents:
 *   1. Page tokens (:root)        5. Figures (photos)
 *   2. Sub-nav tokens             6. Side rail + signup button
 *   3. Nameplate                  7. English | Espanol switch + ADA notice
 *   4. Article: head + body       8. Print
 *
 * PHOTOS: each <figure class="ps-fig"> stands alone. Commenting out either
 * one (or both) never shifts the rest of the layout, because nothing here
 * is positioned relative to a sibling figure.
 */

/* ==========================================================================
   1. PAGE TOKENS  — City brand blue, newsprint rules, gold accent
   --------------------------------------------------------------------------
   Text-bearing colors pass WCAG AA (4.5:1) on white.
   ========================================================================== */
:root {
  --ps-blue:     var(--brand-blue, #2e5a93);
  --ps-blue-dk:  #0e1e46;
  --ps-gold:     var(--vims-accent, #f5a800);   /* the ONE yellow on the page (matches the nameplate border).
                                                  Never use it for text on white (2:1); pair it with
                                                  --ps-blue-dk text instead (9.9:1). */
  --ps-ink:      #23282f;
  --ps-muted:    #4d515f;
  --ps-rule:     #c9ced6;
  --ps-paper:    #f1f1f2;   /* light grey nameplate band */

  --font-display: 'Poppins', 'Segoe UI', Arial, sans-serif;
  --font-body:    'Source Sans 3', 'Lato', 'Helvetica Neue', Arial, sans-serif;
}

/* ==========================================================================
   2. SUB-NAV TOKENS  (main-style.css .subnav reads these)
   ========================================================================== */
:root {
  --alert-text-muted: #4d515f;
  --alert-blue:       var(--ps-blue);
  --alert-red:        var(--ps-blue-dk);
  --alert-amber:      var(--ps-gold);
  --alert-transition: 0.2s ease;
}

/* In-page jump targets sit below the sticky sub-nav */
[id] { scroll-margin-top: 90px; }
/* Keyboard focus is never hidden behind the sticky sub-nav (WCAG 2.4.11) */
html { scroll-padding-top: 90px; }

/* main-style.css .container only pads 5px; give the story real gutters
   below the 1400px max-width */
.ps-nameplate .container,
.ps-news .container { padding: 0 clamp(1.6rem, 3vw, 3.2rem); }

/* ==========================================================================
   3. NAMEPLATE  — the "front page" band above the sub-nav
   ========================================================================== */
.ps-nameplate {
  display: block;
  padding: 2rem 0 1.6rem;
  background: var(--ps-paper);
  border-top: 3px solid var(--ps-gold);
  text-align: center;
}
.ps-nameplate__meta {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.4rem 2rem;
  margin: 0 0 1rem; padding-bottom: 0.8rem;
  border-bottom: 1px solid var(--ps-ink);
  font-family: var(--font-body); font-size: 1.3rem; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--ps-muted);
}
.ps-nameplate__title {
  margin: 0;
  font-family: var(--font-body); font-weight: 700;
  font-size: clamp(3.8rem, 7vw, 6.4rem); line-height: 1;
  letter-spacing: -0.01em;
  color: var(--ps-blue-dk);
}
.ps-nameplate__tag {
  margin: 1rem 0 0; padding-top: 0.8rem;
  border-top: 4px double var(--ps-ink);
  font-family: var(--font-body); font-style: italic; font-size: 1.6rem;
  color: var(--ps-muted);
}

@media (max-width: 600px) {
  .ps-nameplate__meta { justify-content: center; }
}

/* ==========================================================================
   4. ARTICLE  — headline block, then the story in a single column
   ========================================================================== */
.ps-news { display: block; padding: 3.6rem 0 4rem; }

.ps-article__head {
  max-width: 980px;
  margin: 0 auto 2.8rem;
  text-align: center;
}
/* Topic label: gold badge with navy text (yellow text on white fails contrast) */
.ps-kicker {
  display: inline-block;
  margin: 0 0 1.4rem; padding: 0.4rem 1.2rem;
  background: var(--ps-gold);
  border-radius: 4px;
  font-family: var(--font-display); font-size: 1.4rem; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ps-blue-dk);
}
.ps-headline {
  margin: 0 0 1.4rem;
  font-family: var(--font-body); font-weight: 700;
  font-size: clamp(3rem, 4.4vw, 4.8rem); line-height: 1.12;
  letter-spacing: -0.01em; text-transform: none;
  color: var(--ps-blue-dk);
}
.ps-deck {
  max-width: 820px;
  margin: 0 auto 2rem;
  font-family: var(--font-body); font-size: clamp(1.8rem, 2vw, 2.1rem); line-height: 1.5;
  color: var(--ps-muted);
}
.ps-byline {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 0.6rem 2.4rem;
  margin: 0; padding: 1rem 0;
  border-top: 1px solid var(--ps-rule);
  border-bottom: 4px double var(--ps-ink);
  list-style: none;
  font-family: var(--font-body); font-size: 1.4rem; font-weight: 600;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--ps-muted);
}
.ps-byline li { margin: 0; }
.ps-byline i { margin-right: 0.5rem; color: var(--ps-blue); }

/* Rail on the left, story on the right. The rail follows the story in the
   HTML, so on tablets it simply drops below the story. */
.ps-article__layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 4rem;
  align-items: start;
}
.ps-article__layout > .ps-rail  { grid-column: 1; grid-row: 1; }
.ps-article__layout > .ps-story { grid-column: 2; grid-row: 1; }
@media (max-width: 1024px) {
  .ps-article__layout { grid-template-columns: minmax(0, 1fr); gap: 3rem; }
  .ps-article__layout > .ps-rail,
  .ps-article__layout > .ps-story { grid-column: auto; grid-row: auto; }
}

/* Story (photos + body copy) is capped at a comfortable line length.
   flow-root contains Photo 2's float, which either language's body wraps around. */
.ps-story { display: flow-root; max-width: 78rem; }

/* Body copy: one column */
.ps-body {
  font-family: var(--font-body); font-size: 1.8rem; line-height: 1.65;
  color: var(--ps-ink);
}
.ps-body p { margin: 0 0 1.6rem; }
.ps-body ul,
.ps-body ol { margin: 0 0 1.6rem 2.4rem; }
.ps-body ul { list-style: disc; }
.ps-body li { margin-bottom: 0.6rem; }
.ps-body a { text-decoration: underline; }

/* Opening line of the release: MORENO VALLEY, CA (date) */
.ps-dateline {
  font-family: var(--font-body); font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--ps-blue-dk);
}

/* Subheads inside the story (e.g. "About NATOA") */
.ps-subhead {
  margin: 2.4rem 0 0.8rem;
  font-family: var(--font-display); font-size: 1.7rem; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ps-blue);
}

/* End mark after the last paragraph, newspaper style */
.ps-end { text-align: center; font-family: var(--font-body); letter-spacing: 0.4em; color: var(--ps-muted); }

/* ==========================================================================
   5. FIGURES  — Photo 1 sits above the story, Photo 2 floats beside the
   opening paragraph on desktop. Each is self-contained; comment either out freely.
   ========================================================================== */
.ps-fig { margin: 0 0 2.4rem; }
.ps-fig img { display: block; width: 100%; height: auto; }
.ps-fig figcaption {
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--ps-rule);
  font-family: var(--font-body); font-size: 1.4rem; line-height: 1.45;
  color: var(--ps-muted);
}
.ps-credit {
  display: block;
  margin-top: 0.2rem;
  font-size: 1.2rem; letter-spacing: 0.06em; text-transform: uppercase;
}

.ps-fig--inline { margin: 0.4rem 0 2rem; }
@media (min-width: 768px) {
  .ps-fig--inline { float: right; width: 45%; margin: 0.4rem 0 1.6rem 2.8rem; }
}

/* ==========================================================================
   6. SIDE RAIL  — email signup, media contact, links
   ========================================================================== */
.ps-rail {
  display: grid; gap: 2.4rem;
  font-family: var(--font-body); font-size: 1.6rem; line-height: 1.5;
}
@media (max-width: 1024px) {
  .ps-rail { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
}
.ps-rail__box {
  padding: 1.6rem 0 0;
  border-top: 4px solid var(--ps-blue-dk);
}
.ps-rail__title {
  margin: 0 0 1rem;
  font-family: var(--font-display); font-size: 1.5rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ps-blue-dk);
}
.ps-rail p { margin: 0 0 0.6rem; }
.ps-rail ul { list-style: none; margin: 0; padding: 0; }
.ps-rail li { margin: 0; padding: 0.7rem 0; border-bottom: 1px solid var(--ps-rule); }
.ps-rail li:first-child { padding-top: 0; }
.ps-rail i { width: 1.8rem; margin-right: 0.6rem; color: var(--ps-blue); text-align: center; }
.ps-rail a { text-decoration: underline; }

/* Email signup button (gold, dark text = 9.9:1) */
.ps-rail__signup { padding: 1.6rem; background: var(--ps-paper); border-top-color: var(--ps-gold); }
.ps-rail a.ps-btn,
.ps-rail a.ps-btn:visited {
  display: inline-flex; align-items: center; gap: 0.8rem;
  margin-top: 0.6rem; padding: 1rem 1.8rem;
  background: var(--ps-gold); color: var(--ps-blue-dk);
  border-radius: 8px;
  font-family: var(--font-display); font-size: 1.5rem; font-weight: 600;
  text-decoration: none;
  transition: background 0.2s ease;
}
.ps-rail a.ps-btn:hover,
.ps-rail a.ps-btn:focus { background: var(--ps-blue-dk); color: var(--ps-gold); }
.ps-rail a.ps-btn:focus-visible { outline: 3px solid var(--ps-blue-dk); outline-offset: 2px; }
.ps-rail .ps-btn i { width: auto; margin: 0; color: inherit; }

/* ==========================================================================
   7. ENGLISH | ESPANOL SWITCH + ADA NOTICE
   ========================================================================== */
/* Only the chosen language shows. Every translated part is a data-lang pair;
   the radios drive it with :has(), so it works even if the script fails. */
main:has(#ps-lang-en:checked) [data-lang="es"],
main:has(#ps-lang-es:checked) [data-lang="en"] { display: none; }

/* The switch: two radios styled as a segmented control */
.ps-lang-switch {
  position: relative;
  display: flex; justify-content: center;
  margin: 0 0 2.4rem; padding: 0; border: 0; min-width: 0;
}
.ps-lang-switch input {
  position: absolute; width: 1px; height: 1px; margin: 0;
  opacity: 0;   /* still focusable and announced as radio buttons */
}
.ps-lang-switch label {
  display: inline-flex; align-items: center; gap: 0.6rem;
  margin: 0; padding: 0.8rem 2.2rem;
  border: 2px solid var(--ps-blue-dk);
  background: #fff; color: var(--ps-blue-dk);
  font-family: var(--font-display); font-size: 1.5rem; font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}
.ps-lang-switch label:first-of-type { border-radius: 999px 0 0 999px; }
.ps-lang-switch label:last-of-type  { border-radius: 0 999px 999px 0; border-left: 0; }
.ps-lang-switch label:hover { background: var(--ps-paper); }
.ps-lang-switch input:checked + label { background: var(--ps-blue-dk); color: #fff; }
.ps-lang-switch input:focus-visible + label { outline: 3px solid var(--ps-blue-dk); outline-offset: 3px; }

/* ADA notice: sits under the story, same width, ruled off from the body */
.ps-ada {
  clear: both;
  margin-top: 3.2rem; padding-top: 2rem;
  border-top: 1px solid var(--ps-rule);
}
.ps-ada p {
  margin: 0 0 1.2rem;
  font-family: var(--font-body); font-size: 1.4rem; line-height: 1.55;
  color: var(--ps-muted);
}
.ps-ada a { text-decoration: underline; }

/* ==========================================================================
   8. PRINT  — drop site chrome
   ========================================================================== */
@media print {
  header, .subnav, .ps-rail, footer, citibot-chat { display: none !important; }
  .ps-article__layout { display: block; }
  .ps-nameplate { background: none; }
}
