/* ============================================================
   AirWire — Premium Dark Editorial Stylesheet
   ============================================================ */

/* ----- CSS Custom Properties ----- */
:root {
  /* Dark theme (default) */
  --bg-primary: #030712;
  --bg-secondary: #0a0f1e;
  --bg-card: #0d1220;
  --bg-card-hover: #111827;
  --border-subtle: rgba(255,255,255,0.08);
  --border-hover: rgba(0,170,250,0.3);
  --text-primary: #f0f0f0;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
  --accent-cyan: #00AAFA;
  --accent-cyan-glow: rgba(0,170,250,0.15);
  --accent-cyan-dim: rgba(0,170,250,0.08);
  --accent-amber: #F5A623;
  --accent-pink: #EC4899;
  --accent-blue: #3B82F6;
  --accent-gray: #6B7280;
  --accent-gradient: linear-gradient(135deg, #00AAFA, #00B4D8);
  --radius-card: 16px;
  --radius-pill: 9999px;
  --radius-input: 12px;
  --shadow-card: 0 1px 3px rgba(0,0,0,0.4);
  --shadow-card-hover: 0 8px 30px rgba(0,170,250,0.08);
  --shadow-glow: 0 0 20px rgba(0,170,250,0.12);
  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --header-height: 108px;
  --max-width: 1280px;
  --transition-fast: 150ms ease;
  --transition-base: 300ms ease;
  --transition-slow: 500ms ease;
}

/* Light theme */
[data-theme="light"] {
  --bg-primary: #f8f9fa;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f3f4f6;
  --border-subtle: rgba(0,0,0,0.1);
  --border-hover: rgba(0,136,204,0.4);
  --text-primary: #111827;
  --text-secondary: #4b5563;
  --text-muted: #9ca3af;
  --shadow-card: 0 1px 4px rgba(0,0,0,0.06), 0 0 0 1px rgba(0,0,0,0.04);
  --shadow-card-hover: 0 12px 36px rgba(0,136,204,0.1), 0 0 0 1px rgba(0,136,204,0.15);
  --shadow-glow: 0 0 20px rgba(0,136,204,0.08);
  --accent-cyan-glow: rgba(0,136,204,0.12);
  --accent-cyan-dim: rgba(0,136,204,0.06);
}

/* ----- Reset & Base ----- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  min-height: 100vh;
  overflow-x: hidden;
  transition: background-color var(--transition-base), color var(--transition-base);
}

a {
  color: var(--accent-cyan);
  text-decoration: none;
  transition: color var(--transition-fast);
}
a:hover {
  color: #33ffe0;
}

img { max-width: 100%; display: block; }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

::selection {
  background: rgba(0,170,250,0.25);
  color: var(--text-primary);
}

/* ----- Utility Classes ----- */
.gradient-text {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border-width: 0;
}

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: auto;
  min-height: var(--header-height);
  background: rgba(3,7,18,0.85);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-bottom: 1px solid var(--border-subtle);
  transition: background var(--transition-base), border-color var(--transition-base);
}

[data-theme="light"] .site-header {
  background: rgba(248,249,250,0.88);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: var(--header-height);
  display: flex;
  align-items: center;
  gap: 16px;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  flex-shrink: 0;
}

.header-logo-img {
  height: 88px;
  width: auto;
  border-radius: 6px;
}

/* Both logo files are opaque JPGs, so each one only disappears into a surface
   of its own tone. The dark-background artwork blends on the dark header with
   `lighten`; the white-background artwork blends on the light header with
   `multiply`. Showing the correct file per theme is what removes the dark pill
   that used to sit behind the mark in light mode. */
.header-logo-on-dark {
  display: block;
  mix-blend-mode: lighten;
}

.header-logo-on-light {
  display: none;
  mix-blend-mode: multiply;
}

[data-theme="light"] .header-logo-on-dark {
  display: none;
}

[data-theme="light"] .header-logo-on-light {
  display: block;
}

.logo-text {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1;
}

.logo-event {
  color: var(--text-primary);
  -webkit-text-fill-color: var(--text-primary);
}

.logo-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-cyan);
  box-shadow: 0 0 8px var(--accent-cyan), 0 0 16px rgba(0,170,250,0.3);
  animation: pulse-dot 2s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; box-shadow: 0 0 8px var(--accent-cyan), 0 0 16px rgba(0,170,250,0.3); }
  50% { opacity: 0.6; box-shadow: 0 0 4px var(--accent-cyan), 0 0 8px rgba(0,170,250,0.15); }
}

.header-tagline {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  display: none;
}

@media (min-width: 768px) {
  .header-tagline { display: block; }
}

/* Nav */
.header-nav {
  display: none;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

@media (min-width: 768px) {
  .header-nav { display: flex; }
}

.nav-link {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  transition: color var(--transition-fast), background var(--transition-fast);
  text-decoration: none;
}

.nav-link:hover {
  color: var(--text-primary);
  background: var(--accent-cyan-dim);
}

.nav-link.active {
  color: var(--accent-cyan);
  background: var(--accent-cyan-dim);
}

/* Header Actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

@media (min-width: 768px) {
  .header-actions { margin-left: 8px; }
}

.theme-toggle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: color var(--transition-fast), background var(--transition-fast);
}

.theme-toggle:hover {
  color: var(--accent-cyan);
  background: var(--accent-cyan-dim);
}

[data-theme="dark"] .icon-sun { display: block; }
[data-theme="dark"] .icon-moon { display: none; }
[data-theme="light"] .icon-sun { display: none; }
[data-theme="light"] .icon-moon { display: block; }

/* Mobile Menu Button */
.mobile-menu-btn {
  width: 36px;
  height: 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.mobile-menu-btn span {
  width: 20px;
  height: 2px;
  background: var(--text-secondary);
  border-radius: 2px;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.mobile-menu-btn.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.mobile-menu-btn.active span:nth-child(2) {
  opacity: 0;
}
.mobile-menu-btn.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (min-width: 768px) {
  .mobile-menu-btn { display: none; }
}

/* Mobile Nav */
.mobile-nav {
  display: none;
  flex-direction: column;
  padding: 8px 24px 16px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-nav.open {
  display: flex;
}

@media (min-width: 768px) {
  .mobile-nav { display: none !important; }
}

.mobile-nav .nav-link {
  padding: 10px 0;
  font-size: 16px;
}

/* ============================================================
   MAIN CONTENT
   ============================================================ */
.main-content {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  padding-top: 8px;
  min-height: calc(100vh - var(--header-height) - 200px);
}

/* Page visibility */
.page { display: none; }
.page.active { display: block; }

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero {
  position: relative;
  padding: 64px 0 48px;
  overflow: hidden;
}

@media (min-width: 768px) {
  .hero { padding: 80px 0 56px; }
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 720px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px 6px 10px;
  background: var(--accent-cyan-dim);
  border: 1px solid rgba(0,170,250,0.15);
  border-radius: var(--radius-pill);
  margin-bottom: 24px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-cyan);
  animation: pulse-dot 2s ease-in-out infinite;
  box-shadow: 0 0 6px var(--accent-cyan);
}

.hero-badge-text {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--accent-cyan);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero-heading {
  font-family: var(--font-display);
  font-size: clamp(40px, 7vw, 72px);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.hero-subtitle {
  font-size: 17px;
  line-height: 1.65;
  color: var(--text-secondary);
  max-width: 560px;
  margin-bottom: 36px;
}

/* Decorative wires */
.hero-wires {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 50%;
  pointer-events: none;
  overflow: hidden;
}

.wire {
  position: absolute;
  height: 2px;
  right: -10%;
  opacity: 0.2;
}

.wire-1 {
  top: 30%;
  width: 60%;
  background: linear-gradient(90deg, transparent, var(--accent-cyan), transparent);
  animation: wire-slide 6s ease-in-out infinite;
}
.wire-2 {
  top: 50%;
  width: 45%;
  background: linear-gradient(90deg, transparent, var(--accent-amber), transparent);
  animation: wire-slide 8s ease-in-out infinite 2s;
}
.wire-3 {
  top: 70%;
  width: 55%;
  background: linear-gradient(90deg, transparent, var(--accent-cyan), transparent);
  animation: wire-slide 7s ease-in-out infinite 4s;
}

@keyframes wire-slide {
  0%, 100% { transform: translateX(0); opacity: 0.12; }
  50% { transform: translateX(-20px); opacity: 0.28; }
}

/* ============================================================
   EMAIL CAPTURE
   ============================================================ */
.email-capture {
  max-width: 520px;
}

.email-capture-form {
  display: flex;
  gap: 8px;
  align-items: stretch;
}

@media (max-width: 520px) {
  .email-capture-form {
    flex-direction: column;
  }
}

.email-input-wrap {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
}

.email-icon {
  position: absolute;
  left: 14px;
  color: var(--text-muted);
  pointer-events: none;
  flex-shrink: 0;
}

.email-input {
  width: 100%;
  padding: 12px 14px 12px 42px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-input);
  color: var(--text-primary);
  font-size: 15px;
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.email-input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px var(--accent-cyan-glow), var(--shadow-glow);
}

.email-input::placeholder {
  color: var(--text-muted);
}

.email-submit-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--accent-gradient);
  color: #030712;
  font-weight: 600;
  font-size: 14px;
  border-radius: var(--radius-input);
  white-space: nowrap;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), opacity var(--transition-fast);
  flex-shrink: 0;
}

.email-submit-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(0,170,250,0.25);
}

.email-submit-btn:active {
  transform: translateY(0);
}

.email-success {
  display: none;
  margin-top: 12px;
  padding: 12px 16px;
  background: var(--accent-cyan-dim);
  border: 1px solid rgba(0,170,250,0.2);
  border-radius: var(--radius-input);
  color: var(--accent-cyan);
  font-size: 14px;
  font-weight: 500;
}

.email-success.show {
  display: block;
  animation: fadeSlideUp 0.3s ease;
}

.email-note {
  margin-top: 10px;
  font-size: 12px;
  color: var(--text-muted);
}

/* Subscribe choice (Daily / Weekly / Both) — used in hero, newsletter page, and WW page */
.subscribe-choice {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 14px;
}

.subscribe-choice-option {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
  user-select: none;
}

.subscribe-choice-option:hover {
  border-color: var(--accent-cyan);
  background: var(--bg-card);
}

.subscribe-choice-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.subscribe-choice-option span {
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
}

.subscribe-choice-option small {
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.3;
}

.subscribe-choice-option:has(input:checked) {
  border-color: var(--accent-cyan);
  background: var(--accent-cyan-dim);
  box-shadow: 0 0 0 1px var(--accent-cyan) inset;
}

.subscribe-choice-option:has(input:checked) span {
  color: var(--accent-cyan);
}

@media (max-width: 520px) {
  .subscribe-choice { grid-template-columns: 1fr; }
  .subscribe-choice-option { padding: 10px 12px; }
}

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

/* ============================================================
   FILTER SECTION
   ============================================================ */
.filter-section {
  padding: 0 0 16px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 16px;
}

.filter-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.filter-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding-top: 7px;
  flex-shrink: 0;
  min-width: 72px;
}

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.filter-pill {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-subtle);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.filter-pill:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
  background: var(--accent-cyan-dim);
}

.filter-pill.active {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  background: var(--accent-cyan-dim);
}

/* Category-specific pill colors.
   v6.4: rebuilt on Steve Watts' category tree. The block that stood here keyed
   off Gear Launches, Tours & Shows, People Moves, Training & Tips and Industry
   News, inherited from the sister property. None of them has existed on
   AirWire since the Sep 4 rewrite, so every one of those selectors was dead.
   Values mirror CATEGORY_COLORS in app.js. */
.filter-pill[data-category="General Helicopters"].active {
  border-color: #00AAFA;
  color: #00AAFA;
  background: rgba(0,170,250,0.1);
}
.filter-pill[data-category="Defence & Government"].active {
  border-color: #8B5CF6;
  color: #8B5CF6;
  background: rgba(139,92,246,0.1);
}
.filter-pill[data-category="Operators & Fleet"].active {
  border-color: #3B82F6;
  color: #3B82F6;
  background: rgba(59,130,246,0.1);
}
.filter-pill[data-category="Emergency & Public Service"].active {
  border-color: #EF4444;
  color: #EF4444;
  background: rgba(239,68,68,0.1);
}
.filter-pill[data-category="Business & Industry"].active {
  border-color: #F5A623;
  color: #F5A623;
  background: rgba(245,166,35,0.1);
}
.filter-pill[data-category="eVTOL"].active {
  border-color: #A855F7;
  color: #A855F7;
  background: rgba(168,85,247,0.1);
}
.filter-pill[data-category="Unmanned"].active {
  border-color: #10B981;
  color: #10B981;
  background: rgba(16,185,129,0.1);
}
.filter-pill[data-category="Technology"].active {
  border-color: #EC4899;
  color: #EC4899;
  background: rgba(236,72,153,0.1);
}
.filter-pill[data-category="Safety & Training"].active {
  border-color: #14B8A6;
  color: #14B8A6;
  background: rgba(20,184,166,0.1);
}
.filter-pill[data-category="Airshows & Expos"].active {
  border-color: #F97316;
  color: #F97316;
  background: rgba(249,115,22,0.1);
}
.filter-pill[data-category="Certification & Regulation"].active {
  border-color: #F59E0B;
  color: #F59E0B;
  background: rgba(245,158,11,0.1);
}
.filter-pill[data-category="Investigations"].active {
  border-color: #DC2626;
  color: #DC2626;
  background: rgba(220,38,38,0.1);
}
.filter-pill[data-category="Directory"].active {
  border-color: #64748B;
  color: #64748B;
  background: rgba(100,116,139,0.1);
}
.filter-pill[data-category="Community"].active {
  border-color: #00AAFA;
  color: #00AAFA;
  background: rgba(0,170,250,0.1);
}
.filter-pill[data-category="Breaking News"].active {
  border-color: #EF4444;
  color: #EF4444;
  background: rgba(239,68,68,0.1);
}
.filter-pill[data-category="Podcasts"].active {
  border-color: #6366F1;
  color: #6366F1;
  background: rgba(99,102,241,0.1);
}

/* Search */
.search-row {
  margin-top: 4px;
}

.search-wrap {
  position: relative;
  max-width: 360px;
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 9px 14px 9px 40px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-input);
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.search-input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px var(--accent-cyan-glow);
}

.search-input::placeholder {
  color: var(--text-muted);
}

/* ============================================================
   KEYWORD FILTER
   v6.4: replaced the auto-generated company pill row. It sits in the filter
   bar where those pills were, so it reads as part of the category controls
   rather than as a second site search. Deliberately narrower than the search
   box below it, to signal the smaller scope.
   ============================================================ */
/* v6.5: Marcel asked for a blue box around the filter so it stands out from
   the category pills above it. The panel is tinted and bordered in AirWire
   blue rather than a flat fill, so it reads as emphasis in both themes without
   competing with the active category pill, which is solid blue. Both the tint
   and the border are rgba over whatever sits behind them, which is why this
   needs no separate dark-mode rule. */
.keyword-filter-row.keyword-filter-row {
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  padding: 10px 14px;
  background: rgba(0, 170, 250, 0.06);
  border: 1px solid rgba(0, 170, 250, 0.45);
  border-radius: 10px;
}

/* The label is the thing that names the box, so it carries the blue rather
   than staying muted grey like the Category label above. */
.keyword-filter-row .filter-label {
  color: #00AAFA;
  font-weight: 600;
}

/* Inside a tinted panel the input's own subtle border disappears, so give it
   a slightly firmer edge and a plain surface to sit on. */
.keyword-filter-row .keyword-filter-input {
  background: var(--bg-primary);
  border-color: rgba(0, 170, 250, 0.35);
}

/* On a narrow screen the row stacks, and a full width input inside the panel
   looks better than one pinned to 320px with dead tinted space beside it. */
@media (max-width: 640px) {
  .keyword-filter-row.keyword-filter-row {
    align-items: stretch;
    gap: 6px;
  }
  .keyword-filter-row .keyword-filter-wrap {
    flex: 1 1 auto;
    max-width: none;
  }
}

.keyword-filter-wrap {
  position: relative;
  flex: 0 1 300px;
  min-width: 200px;
  max-width: 320px;
}

.keyword-filter-input {
  width: 100%;
  padding: 7px 32px 7px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-input);
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.keyword-filter-input:focus {
  /* Explicit AirWire blue. The glow variable is the same blue; this focus
     ring stays a literal so the keyword box does not drift if the token moves. */
  border-color: #00AAFA;
  box-shadow: 0 0 0 3px rgba(0,170,250,0.15);
}

.keyword-filter-input::placeholder {
  color: var(--text-muted);
}

/* Clear button. Hidden via the [hidden] attribute from JS whenever the box is
   empty, so the attribute needs to beat the flex display below. */
.keyword-filter-clear {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--text-muted);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  transition: color var(--transition-fast), background var(--transition-fast);
}

.keyword-filter-clear:hover {
  color: var(--text-primary);
  background: var(--bg-tertiary, rgba(255,255,255,0.06));
}

.keyword-filter-clear[hidden] {
  display: none;
}

.keyword-filter-hint {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 640px) {
  .keyword-filter-wrap {
    flex: 1 1 100%;
    max-width: none;
  }
  .keyword-filter-hint {
    flex: 1 1 100%;
    white-space: normal;
  }
}

/* ============================================================
   STATS ROW
   ============================================================ */
.stats-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 0;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
}

.stat-value {
  color: var(--text-secondary);
  font-weight: 500;
}

.stat-divider {
  color: var(--border-subtle);
}

/* ============================================================
   LAYOUT SWITCHER
   ============================================================ */
.layout-switcher {
  display: flex;
  gap: 4px;
  padding: 4px;
  background: var(--bg-secondary);
  border-radius: var(--radius-input);
  border: 1px solid var(--border-subtle);
  margin-bottom: 24px;
  width: fit-content;
}

.layout-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  transition: all var(--transition-fast);
}

.layout-btn:hover {
  color: var(--text-secondary);
}

.layout-btn.active {
  color: var(--text-primary);
  background: var(--bg-card);
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

[data-theme="light"] .layout-btn.active {
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.layout-btn svg {
  flex-shrink: 0;
}

/* ============================================================
   CONTENT AREA — Layouts
   ============================================================ */
.content-area {
  padding-bottom: 64px;
}

.news-new-stories-wrap {
  position: sticky;
  top: calc(var(--header-height) + 8px);
  z-index: 30;
  display: flex;
  justify-content: center;
  height: 0;
  overflow: visible;
  pointer-events: none;
}

.news-new-stories-wrap[hidden] {
  display: none;
}

.news-new-stories {
  pointer-events: auto;
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border: 0;
  border-radius: 999px;
  background: #00AAFA;
  color: #041018;
  font-family: var(--font-body, inherit);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 170, 250, 0.28);
}

.news-new-stories[hidden] {
  display: none;
}

.story-card[data-settled="1"],
.wire-item[data-settled="1"] {
  animation: none;
}

.layout-cards,
.layout-wire,
.layout-dashboard {
  display: none;
}

.layout-cards.active,
.layout-wire.active,
.layout-dashboard.active {
  display: block;
}

/* ============================================================
   CARDS LAYOUT
   ============================================================ */
.cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 640px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .cards-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Story Card */
.story-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 24px;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  transition: transform var(--transition-base), box-shadow var(--transition-base), border-color var(--transition-base);
  position: relative;
  overflow: hidden;
}

.story-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent-gradient);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.story-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
}

.story-card:hover::before {
  opacity: 1;
}

.card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.card-category {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  line-height: 1.4;
}

/* v6.4: rebuilt on Steve's tree. These selectors previously keyed off the
   sister property's categories, so no AirWire story has matched one since the
   Sep 4 rewrite and every category badge rendered with no colour at all. */
.card-category[data-cat="General Helicopters"] {
  color: #00AAFA;
  background: rgba(0,170,250,0.1);
  border: 1px solid rgba(0,170,250,0.2);
}
.card-category[data-cat="Defence & Government"] {
  color: #8B5CF6;
  background: rgba(139,92,246,0.1);
  border: 1px solid rgba(139,92,246,0.2);
}
.card-category[data-cat="Operators & Fleet"] {
  color: #3B82F6;
  background: rgba(59,130,246,0.1);
  border: 1px solid rgba(59,130,246,0.2);
}
.card-category[data-cat="Emergency & Public Service"] {
  color: #EF4444;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.2);
}
.card-category[data-cat="Business & Industry"] {
  color: #F5A623;
  background: rgba(245,166,35,0.1);
  border: 1px solid rgba(245,166,35,0.2);
}
.card-category[data-cat="eVTOL"] {
  color: #A855F7;
  background: rgba(168,85,247,0.1);
  border: 1px solid rgba(168,85,247,0.2);
}
.card-category[data-cat="Unmanned"] {
  color: #10B981;
  background: rgba(16,185,129,0.1);
  border: 1px solid rgba(16,185,129,0.2);
}
.card-category[data-cat="Technology"] {
  color: #EC4899;
  background: rgba(236,72,153,0.1);
  border: 1px solid rgba(236,72,153,0.2);
}
.card-category[data-cat="Safety & Training"] {
  color: #14B8A6;
  background: rgba(20,184,166,0.1);
  border: 1px solid rgba(20,184,166,0.2);
}
.card-category[data-cat="Airshows & Expos"] {
  color: #F97316;
  background: rgba(249,115,22,0.1);
  border: 1px solid rgba(249,115,22,0.2);
}
.card-category[data-cat="Certification & Regulation"] {
  color: #F59E0B;
  background: rgba(245,158,11,0.1);
  border: 1px solid rgba(245,158,11,0.2);
}
.card-category[data-cat="Investigations"] {
  color: #DC2626;
  background: rgba(220,38,38,0.1);
  border: 1px solid rgba(220,38,38,0.2);
}
.card-category[data-cat="Directory"] {
  color: #64748B;
  background: rgba(100,116,139,0.1);
  border: 1px solid rgba(100,116,139,0.2);
}
.card-category[data-cat="Community"] {
  color: #00AAFA;
  background: rgba(0,170,250,0.1);
  border: 1px solid rgba(0,170,250,0.2);
}
.card-category[data-cat="Breaking News"] {
  color: #EF4444;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.2);
}
.card-category[data-cat="Podcasts"] {
  color: #6366F1;
  background: rgba(99,102,241,0.1);
  border: 1px solid rgba(99,102,241,0.2);
}

.card-time {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
}

.card-title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  letter-spacing: -0.01em;
}

.card-excerpt {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 16px;
  flex: 1;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
}

.card-source {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
}

/* YouTube cards link out to the watch page. The thumbnail is a ytimg URL,
   not a downloaded video. */
.card-video-flag {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  color: #f8fafc;
  background: #dc2626;
  line-height: 1.4;
}

.story-card-video .story-card-media {
  height: 168px;
  margin: 0 0 14px;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
  background: rgba(15, 23, 42, 0.08);
}

.story-card-video .story-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.story-card-video .story-card-media::after {
  content: "YouTube";
  position: absolute;
  left: 10px;
  bottom: 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(220, 38, 38, 0.92);
  border-radius: 4px;
  padding: 3px 7px;
}

.card-tags {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.card-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  background: var(--accent-cyan-dim);
  color: var(--text-muted);
  text-transform: lowercase;
  transition: color var(--transition-fast), background var(--transition-fast);
}

.story-card:hover .card-tag {
  color: var(--accent-cyan);
  background: rgba(0,170,250,0.12);
}

/* ============================================================
   WIRE LAYOUT
   ============================================================ */
.wire-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .wire-container {
    grid-template-columns: 1fr 260px;
  }
}

.wire-feed {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* Wire Item */
.wire-item {
  padding: 12px 16px;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast);
}

.wire-item:hover {
  background: var(--bg-card);
  border-color: var(--border-subtle);
}

.wire-item.expanded {
  background: var(--bg-card);
  border-color: var(--border-subtle);
}

.wire-item-header {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.wire-item-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-cyan);
  margin-top: 7px;
  flex-shrink: 0;
}

/* v6.4: rebuilt on Steve's tree, same dead-selector problem as above. */
.wire-item-dot[data-cat="General Helicopters"] { background: #00AAFA; }
.wire-item-dot[data-cat="Defence & Government"] { background: #8B5CF6; }
.wire-item-dot[data-cat="Operators & Fleet"] { background: #3B82F6; }
.wire-item-dot[data-cat="Emergency & Public Service"] { background: #EF4444; }
.wire-item-dot[data-cat="Business & Industry"] { background: #F5A623; }
.wire-item-dot[data-cat="eVTOL"] { background: #A855F7; }
.wire-item-dot[data-cat="Unmanned"] { background: #10B981; }
.wire-item-dot[data-cat="Technology"] { background: #EC4899; }
.wire-item-dot[data-cat="Safety & Training"] { background: #14B8A6; }
.wire-item-dot[data-cat="Airshows & Expos"] { background: #F97316; }
.wire-item-dot[data-cat="Certification & Regulation"] { background: #F59E0B; }
.wire-item-dot[data-cat="Investigations"] { background: #DC2626; }
.wire-item-dot[data-cat="Directory"] { background: #64748B; }
.wire-item-dot[data-cat="Community"] { background: #00AAFA; }
.wire-item-dot[data-cat="Breaking News"] { background: #EF4444; }
.wire-item-dot[data-cat="Podcasts"] { background: #6366F1; }

.wire-item-content {
  flex: 1;
  min-width: 0;
}

.wire-item-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
  margin-bottom: 2px;
}

.wire-item-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  display: flex;
  gap: 8px;
  align-items: center;
}

.wire-item-meta .meta-sep {
  color: var(--border-subtle);
}

.wire-item-body {
  display: none;
  padding: 12px 0 4px 18px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
}

.wire-item.expanded .wire-item-body {
  display: block;
  animation: fadeSlideUp 0.2s ease;
}

.wire-item-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent-cyan);
  margin-top: 8px;
}

.wire-item-link:hover {
  text-decoration: underline;
}

.wire-item-time {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
  padding-top: 2px;
}

/* Wire Sidebar */
.wire-sidebar {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 20px;
  position: sticky;
  top: calc(var(--header-height) + 24px);
  max-height: calc(100vh - var(--header-height) - 48px);
  overflow-y: auto;
}

.sidebar-title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.source-list {
  list-style: none;
}

.source-list li {
  padding: 6px 0;
  font-size: 13px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 8px;
}

.source-list li:last-child {
  border-bottom: none;
}

.source-list li::before {
  content: '';
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent-cyan);
  flex-shrink: 0;
  opacity: 0.5;
}

/* ============================================================
   DASHBOARD LAYOUT
   ============================================================ */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 640px) {
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .dashboard-grid { grid-template-columns: repeat(3, 1fr); }
}

.dashboard-column {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  overflow: hidden;
}

.dashboard-column-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.dashboard-column-title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.dashboard-column-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.dashboard-column-count {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  padding: 2px 8px;
  background: var(--accent-cyan-dim);
  border-radius: var(--radius-pill);
}

.dashboard-items {
  padding: 8px;
  max-height: 400px;
  overflow-y: auto;
}

.dashboard-item {
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.dashboard-item:hover {
  background: var(--bg-card-hover);
}

.dashboard-item-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
  line-height: 1.4;
}

.dashboard-item-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
}

.dashboard-item-body {
  display: none;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-secondary);
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border-subtle);
}

.dashboard-item.expanded .dashboard-item-body {
  display: block;
  animation: fadeSlideUp 0.2s ease;
}

.dashboard-item-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 500;
  color: var(--accent-cyan);
  margin-top: 6px;
}

/* ============================================================
   SKELETON LOADING
   ============================================================ */
@keyframes skeleton-pulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.15; }
}

.skeleton {
  background: var(--border-subtle);
  border-radius: 6px;
  animation: skeleton-pulse 1.8s ease-in-out infinite;
}

/* Card Skeleton */
.skeleton-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 24px;
}

.skeleton-pill {
  width: 80px;
  height: 22px;
  border-radius: var(--radius-pill);
  margin-bottom: 14px;
}

.skeleton-title {
  height: 18px;
  width: 90%;
  margin-bottom: 8px;
}

.skeleton-title-short {
  height: 18px;
  width: 60%;
  margin-bottom: 14px;
}

.skeleton-line {
  height: 14px;
  width: 100%;
  margin-bottom: 6px;
}

.skeleton-line-short {
  height: 14px;
  width: 75%;
  margin-bottom: 16px;
}

.skeleton-footer {
  height: 12px;
  width: 40%;
  margin-top: auto;
  padding-top: 12px;
}

/* Wire Skeleton */
.skeleton-wire-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
}

.skeleton-wire-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.skeleton-wire-content {
  flex: 1;
}

.skeleton-wire-title {
  height: 16px;
  width: 70%;
  margin-bottom: 4px;
}

.skeleton-wire-meta {
  height: 12px;
  width: 35%;
}

.skeleton-wire-time {
  width: 50px;
  height: 12px;
  flex-shrink: 0;
}

/* ============================================================
   ABOUT PAGE
   ============================================================ */
.page-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 48px 0 64px;
}

@media (min-width: 768px) {
  .page-content { padding: 64px 0 80px; }
}

.page-header {
  margin-bottom: 48px;
}

.page-heading {
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 16px;
}

.page-header-wire {
  width: 80px;
  height: 2px;
  background: var(--accent-gradient);
  border-radius: 2px;
}

.about-grid {
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.about-section h2 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
  letter-spacing: -0.01em;
}

.about-section p {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 12px;
}

.about-section p:last-child {
  margin-bottom: 0;
}

/* How It Works */
.how-it-works {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 20px;
}

.how-step {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.step-number {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 500;
  color: var(--accent-cyan);
  opacity: 0.3;
  line-height: 1;
  flex-shrink: 0;
  min-width: 48px;
}

.step-content h3 {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.step-content p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Sources Grid */
.sources-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 16px;
}

@media (min-width: 640px) {
  .sources-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 768px) {
  .sources-grid { grid-template-columns: repeat(4, 1fr); }
}

.source-card {
  padding: 12px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: border-color var(--transition-fast), background var(--transition-fast);
}

.source-card:hover {
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
}

.source-card::before {
  content: '';
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent-cyan);
  flex-shrink: 0;
}

/* Community-submitted sources get a slightly different indicator */
.source-card.source-community::before {
  background: #F5A623;
}
.source-card.source-community {
  border-color: rgba(245, 166, 35, 0.15);
}

/* Owner Badge */
.about-owner {
  text-align: center;
  padding: 48px 32px;
  background: #0a0e1a;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  position: relative;
  overflow: hidden;
}

.about-owner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
}

[data-theme="light"] .about-owner {
  background: #111827;
}

.owner-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.gmg-logo-img {
  max-width: 320px;
  width: 100%;
  height: auto;
  border-radius: 8px;
  mix-blend-mode: lighten;
}

.owner-label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.owner-name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
}

.about-owner p {
  max-width: 440px;
  margin: 0 auto;
  font-size: 14px;
  color: #9ca3af;
  line-height: 1.7;
}

/* ============================================================
   NEWSLETTER PAGE
   ============================================================ */
.newsletter-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

@media (min-width: 768px) {
  .newsletter-grid {
    grid-template-columns: 1fr 1fr;
    gap: 56px;
    align-items: start;
  }
}

.newsletter-info h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 14px;
}

.newsletter-info p {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 24px;
}

.newsletter-features {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.nl-feature {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-secondary);
}

.nl-feature svg {
  flex-shrink: 0;
}

/* Newsletter Form Card */
.newsletter-form-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 32px;
}

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.form-group .required {
  color: var(--accent-cyan);
}

.form-group .optional {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 12px;
}

.form-group input[type="email"],
.form-group input[type="text"] {
  width: 100%;
  padding: 10px 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-input);
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-group input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px var(--accent-cyan-glow);
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 4px;
}

.checkbox-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
}

.checkbox-item input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent-cyan);
  cursor: pointer;
}

.newsletter-submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 28px;
  background: var(--accent-gradient);
  color: #030712;
  font-weight: 600;
  font-size: 15px;
  border-radius: var(--radius-input);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  width: 100%;
}

.newsletter-submit-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(0,170,250,0.25);
}

.newsletter-submit-btn:active {
  transform: translateY(0);
}

.newsletter-success {
  display: none;
  margin-top: 16px;
  padding: 14px 18px;
  background: var(--accent-cyan-dim);
  border: 1px solid rgba(0,170,250,0.2);
  border-radius: var(--radius-input);
  color: var(--accent-cyan);
  font-size: 14px;
  font-weight: 500;
  text-align: center;
}

.newsletter-success.show {
  display: block;
  animation: fadeSlideUp 0.3s ease;
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
  margin-top: 48px;
}

[data-theme="light"] .site-footer {
  background: #111827;
  border-top-color: rgba(255,255,255,0.05);
}

[data-theme="light"] .site-footer .footer-copy,
[data-theme="light"] .site-footer .footer-rss,
[data-theme="light"] .site-footer .footer-owner {
  color: #6b7280;
}

[data-theme="light"] .site-footer .footer-links a {
  color: #9ca3af;
}

[data-theme="light"] .site-footer .footer-links a:hover {
  color: var(--accent-cyan);
}

[data-theme="light"] .site-footer .footer-divider {
  background: rgba(255,255,255,0.08);
}

[data-theme="light"] .footer-logo-img,
[data-theme="light"] .footer-gmg-logo {
  mix-blend-mode: lighten;
  background: transparent;
  padding: 0;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 40px 24px 32px;
}

.footer-top {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: flex-start;
}

@media (min-width: 640px) {
  .footer-top {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.footer-logo-img {
  height: 32px;
  width: auto;
  display: block;
  border-radius: 4px;
  mix-blend-mode: lighten;
}

/* No light-theme override here on purpose. The footer keeps its dark surface
   in both themes (see [data-theme="light"] .site-footer above), so the
   dark-background logo already blends with `lighten`. The navy pill that used
   to be declared here was painting a box on an equally dark background. The
   shared rule near .site-footer resets these two logos for light mode. */

.footer-gmg {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.footer-gmg-logo {
  height: 40px;
  width: auto;
  border-radius: 4px;
  mix-blend-mode: lighten;
}

/* Same reasoning as .footer-logo-img: the footer is dark in both themes, so
   the Geezer Media mark needs no pill and keeps its `lighten` blend. */

.footer-wordmark {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.footer-wordmark .logo-event {
  color: var(--text-primary);
}

.footer-owner {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 6px;
}

.footer-links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 13px;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--accent-cyan);
}

.footer-divider {
  height: 1px;
  background: var(--border-subtle);
  margin: 24px 0;
}

/* Footer Social Links */
.footer-socials {
  text-align: center;
  margin-top: 28px;
}

.footer-socials-label {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
  margin-bottom: 16px;
}

.footer-socials-icons {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.footer-socials-icons a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  color: var(--text-secondary);
  transition: all 180ms cubic-bezier(0.16, 1, 0.3, 1);
}

.footer-socials-icons a:hover {
  background: var(--accent-cyan-dim);
  color: var(--accent-cyan);
  transform: translateY(-2px);
}

[data-theme="light"] .footer-socials-icons a {
  background: rgba(255,255,255,0.1);
  color: #9ca3af;
}

[data-theme="light"] .footer-socials-icons a:hover {
  background: rgba(0,170,250,0.15);
  color: var(--accent-cyan);
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

@media (min-width: 640px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

.footer-copy {
  font-size: 12px;
  color: var(--text-muted);
}

.footer-rss {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

/* ============================================================
   SUBMIT NEWS PAGE
   ============================================================ */
.submit-intro {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 680px;
  margin-bottom: 40px;
}

.submit-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 48px;
}

@media (min-width: 768px) {
  .submit-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}

.submit-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 32px;
  position: relative;
}

.submit-card-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--accent-cyan-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.submit-card:last-child .submit-card-icon {
  background: rgba(245,166,35,0.08);
}

.submit-card h2 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.submit-card-desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.submit-form .form-group {
  margin-bottom: 16px;
}

.submit-form label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.submit-form input,
.submit-form textarea,
.submit-form select {
  width: 100%;
  padding: 10px 14px;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-primary);
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-input);
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.submit-form input:focus,
.submit-form textarea:focus,
.submit-form select:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px var(--accent-cyan-glow);
}

.submit-form textarea {
  resize: vertical;
  min-height: 72px;
}

.submit-form select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.submit-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: var(--accent-gradient);
  color: #030712;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  margin-top: 8px;
}

.submit-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0,170,250,0.3);
}

.submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.submit-btn-amber {
  background: linear-gradient(135deg, #F5A623, #E8930C);
}

.submit-btn-amber:hover {
  box-shadow: 0 4px 16px rgba(245,166,35,0.3);
}

.submit-success {
  display: none;
  font-size: 14px;
  color: var(--accent-cyan);
  padding: 16px;
  border: 1px solid rgba(0,170,250,0.2);
  border-radius: var(--radius-input);
  background: rgba(0,170,250,0.05);
  text-align: center;
  margin-top: 16px;
}

.submit-success.show {
  display: block;
  animation: fadeIn 0.4s ease;
}

.submit-guidelines {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 32px;
}

.submit-guidelines h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.submit-guidelines ul {
  list-style: none;
  padding: 0;
}

.submit-guidelines li {
  position: relative;
  padding-left: 20px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.submit-guidelines li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 10px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-cyan);
}

.submit-guidelines li:last-child {
  margin-bottom: 0;
}

/* --- Article Type Toggle --- */
.article-type-toggle {
  display: flex;
  gap: 0;
  margin-bottom: 20px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
}
.toggle-btn {
  flex: 1;
  padding: 10px 16px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: 'DM Sans', sans-serif;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}
.toggle-btn.active {
  background: var(--accent-cyan);
  color: #000;
}
.toggle-btn:not(.active):hover {
  background: rgba(0, 170, 250, 0.1);
  color: var(--text-primary);
}

/* --- PDF Dropzone --- */
.pdf-dropzone {
  border: 2px dashed var(--border);
  border-radius: 10px;
  padding: 32px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}
.pdf-dropzone:hover,
.pdf-dropzone.drag-over {
  border-color: var(--accent-cyan);
  background: rgba(0, 170, 250, 0.05);
}
.pdf-dropzone svg {
  margin-bottom: 12px;
  opacity: 0.5;
}
.pdf-dropzone.drag-over svg {
  opacity: 1;
  stroke: var(--accent-cyan);
}
.dropzone-text {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}
.dropzone-browse {
  color: var(--accent-cyan);
  text-decoration: underline;
  cursor: pointer;
}
.dropzone-hint {
  font-size: 12px;
  color: var(--text-muted);
}

/* --- PDF File Info --- */
.pdf-file-info {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: rgba(0, 170, 250, 0.08);
  border: 1px solid rgba(0, 170, 250, 0.2);
  border-radius: 8px;
  margin-top: 8px;
}
.pdf-file-name {
  flex: 1;
  font-size: 14px;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pdf-remove-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 20px;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
  transition: color 0.2s;
}
.pdf-remove-btn:hover {
  color: #ef4444;
}
.pdf-extract-status {
  font-size: 13px;
  color: var(--accent-cyan);
  margin-top: 8px;
  padding: 8px 12px;
  background: rgba(0, 170, 250, 0.05);
  border-radius: 6px;
}

/* ============================================================
   EMPTY STATE / NO RESULTS
   ============================================================ */
.empty-state {
  text-align: center;
  padding: 64px 20px;
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.3;
}

.empty-state h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.empty-state p {
  font-size: 14px;
  color: var(--text-muted);
}

/* ============================================================
   SCROLL BAR
   ============================================================ */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--border-subtle);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

.story-card {
  animation: staggerFadeIn 0.4s ease backwards;
}

.story-card:nth-child(1) { animation-delay: 0ms; }
.story-card:nth-child(2) { animation-delay: 50ms; }
.story-card:nth-child(3) { animation-delay: 100ms; }
.story-card:nth-child(4) { animation-delay: 150ms; }
.story-card:nth-child(5) { animation-delay: 200ms; }
.story-card:nth-child(6) { animation-delay: 250ms; }
.story-card:nth-child(7) { animation-delay: 300ms; }
.story-card:nth-child(8) { animation-delay: 350ms; }
.story-card:nth-child(9) { animation-delay: 400ms; }

.wire-item {
  animation: staggerFadeIn 0.3s ease backwards;
}

/* ============================================================
   RESPONSIVE REFINEMENTS
   ============================================================ */
@media (max-width: 767px) {
  .hero { padding: 40px 0 32px; }
  .hero-heading { margin-bottom: 14px; }
  .hero-subtitle { font-size: 15px; margin-bottom: 28px; }
  .hero-wires { display: none; }
  .filter-label { min-width: 60px; font-size: 10px; }
  .stats-row { font-size: 11px; }
  .layout-btn span { display: none; }
  .layout-btn { padding: 7px 12px; }
  .page-content { padding: 32px 0 48px; }
  .newsletter-form-card { padding: 24px; }
  .wire-sidebar { display: none; }
}

@media (max-width: 480px) {
  .header-inner { padding: 0 16px; }
  .main-content { padding: 0 16px; }
  .footer-inner { padding: 32px 16px 24px; }
  .hero-heading { font-size: 36px; }
  .filter-row { gap: 8px; }
  .filter-pills { gap: 4px; }
  .filter-pill { font-size: 12px; padding: 4px 10px; }
  .cards-grid { gap: 14px; }
  .story-card { padding: 18px; }
}

/* ============================================================
   SIGNAL PULSE SVG (Header animation)
   ============================================================ */
.signal-pulse {
  position: absolute;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0.15;
}

/* Focus visible for accessibility */
*:focus-visible {
  outline: 2px solid var(--accent-cyan);
  outline-offset: 2px;
}

/* Print */
@media print {
  .site-header, .filter-section, .layout-switcher, .email-capture, .hero-wires,
  .wire-sidebar, .site-footer { display: none; }
  body { background: white; color: black; }
  .story-card { break-inside: avoid; border: 1px solid #ddd; }
}

/* ============================================================
   BRIEFING PLAYER
   ============================================================ */
.briefing-player {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-top: none;
  border-radius: 0;
  padding: 12px 24px;
  margin: 0 auto;
  position: relative;
  z-index: 99;
  transition: border-color var(--transition-base), box-shadow var(--transition-base), background var(--transition-base);
  overflow: hidden;
}



/* Today's episode — glowing left border + subtle gradient bg */
.briefing-player.briefing-today {
  border-left: 3px solid var(--accent-cyan);
  background: linear-gradient(135deg, rgba(0,170,250,0.06) 0%, transparent 60%);
  box-shadow: 0 0 20px rgba(0,170,250,0.08);
}

/* Older episode — muted style */
.briefing-player.briefing-old {
  opacity: 0.75;
  border-color: var(--border-subtle);
}
.briefing-player.briefing-old:hover {
  opacity: 1;
}

/* Collapsed state (yesterday) — compact but still playable */
.briefing-player.briefing-collapsed .briefing-progress {
  display: none;
}
.briefing-player.briefing-collapsed .briefing-speed-btn {
  display: none;
}
.briefing-player.briefing-collapsed .briefing-meta-row::after {
  content: ' — Tap to expand';
  color: var(--text-muted);
  font-size: 11px;
  font-style: italic;
}
.briefing-player.briefing-collapsed {
  cursor: pointer;
  padding: 12px 20px;
}

/* Active audio border highlight */
.briefing-player:has(#briefingAudio:not([src=''])) {
  border-color: rgba(0,170,250,0.15);
}

.briefing-player-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  max-width: var(--max-width);
  margin: 0 auto;
}

/* Info block: headphone icon + label/date */
.briefing-info {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.briefing-info svg {
  flex-shrink: 0;
  opacity: 0.85;
}

.briefing-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.briefing-label-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.briefing-label {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
  line-height: 1.2;
}

/* NEW badge */
.briefing-badge {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #030712;
  background: var(--accent-cyan);
  padding: 2px 7px;
  border-radius: var(--radius-pill);
  line-height: 1.4;
  animation: badge-pulse 2s ease-in-out infinite;
}

@keyframes badge-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,170,250,0.4); }
  50% { box-shadow: 0 0 0 4px rgba(0,170,250,0); }
}

.briefing-meta-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.briefing-date {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.briefing-story-count {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

/* Controls row */
.briefing-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
}

/* Play/Pause button */
.briefing-play-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent-cyan);
  color: #030712;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), opacity var(--transition-fast);
  box-shadow: 0 2px 10px rgba(0,170,250,0.2);
}

.briefing-play-btn:hover {
  transform: scale(1.07);
  box-shadow: 0 4px 18px rgba(0,170,250,0.35);
}

.briefing-play-btn:active {
  transform: scale(0.96);
}

.briefing-play-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}

/* Progress / scrubber row */
.briefing-progress {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.briefing-time {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 32px;
}

.briefing-time:last-child {
  text-align: right;
}

/* Custom range scrubber */
.briefing-scrubber {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 2px;
  background: var(--border-subtle);
  outline: none;
  cursor: pointer;
  transition: background var(--transition-fast);
  background-image: linear-gradient(var(--accent-cyan), var(--accent-cyan));
  background-size: 0% 100%;
  background-repeat: no-repeat;
}

.briefing-scrubber::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent-cyan);
  box-shadow: 0 0 6px rgba(0,170,250,0.4);
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.briefing-scrubber::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent-cyan);
  border: none;
  box-shadow: 0 0 6px rgba(0,170,250,0.4);
  cursor: pointer;
}

.briefing-scrubber:hover::-webkit-slider-thumb {
  transform: scale(1.2);
  box-shadow: 0 0 10px rgba(0,170,250,0.5);
}

.briefing-scrubber::-webkit-slider-track {
  border-radius: 2px;
  background: var(--border-subtle);
}

.briefing-scrubber::-moz-range-track {
  height: 4px;
  border-radius: 2px;
  background: var(--border-subtle);
}

/* Speed button */
.briefing-speed-btn {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  padding: 4px 10px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  background: transparent;
  white-space: nowrap;
  flex-shrink: 0;
  transition: color var(--transition-fast), border-color var(--transition-fast), background var(--transition-fast);
  letter-spacing: 0.03em;
}

.briefing-speed-btn:hover {
  color: var(--accent-cyan);
  border-color: rgba(0,170,250,0.3);
  background: var(--accent-cyan-dim);
}

/* Archive button */
.briefing-archive-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: color var(--transition-fast), border-color var(--transition-fast), background var(--transition-fast);
  cursor: pointer;
}

.briefing-archive-btn:hover {
  color: var(--accent-cyan);
  border-color: rgba(0,170,250,0.3);
  background: var(--accent-cyan-dim);
}

.briefing-archive-btn.active {
  color: var(--accent-cyan);
  border-color: var(--accent-cyan);
  background: var(--accent-cyan-dim);
}

/* Archive dropdown */
.briefing-archive-dropdown {
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  padding: 8px 20px 12px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.briefing-archive-header {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.briefing-archive-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.briefing-archive-item {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 5px 12px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  background: transparent;
  cursor: pointer;
  transition: color var(--transition-fast), border-color var(--transition-fast), background var(--transition-fast);
  white-space: nowrap;
}

.briefing-archive-item:hover {
  color: var(--accent-cyan);
  border-color: rgba(0,170,250,0.3);
  background: var(--accent-cyan-dim);
}

.briefing-archive-item.active {
  color: var(--accent-cyan);
  border-color: var(--accent-cyan);
  background: var(--accent-cyan-dim);
}

.briefing-archive-item .archive-stories {
  font-size: 10px;
  color: var(--text-muted);
  margin-left: 4px;
}

.briefing-archive-empty {
  font-size: 12px;
  color: var(--text-muted);
  font-style: italic;
}

/* Playing pulse animation on the player border */
@keyframes briefing-pulse-border {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,170,250,0); }
  50% { box-shadow: 0 0 0 3px rgba(0,170,250,0.12); }
}

.briefing-player.playing {
  border-color: rgba(0,170,250,0.25);
  animation: briefing-pulse-border 2.5s ease-in-out infinite;
}

/* Empty state */
.briefing-empty {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
  font-family: var(--font-body);
  padding: 4px 0;
  max-width: var(--max-width);
  margin: 0 auto;
}

.briefing-empty svg {
  flex-shrink: 0;
  opacity: 0.4;
}



/* Mobile responsive */
@media (max-width: 600px) {
  .briefing-player {
    padding: 10px 16px;
  }
  .briefing-player-inner {
    gap: 12px;
  }
  .briefing-info {
    width: 100%;
    justify-content: flex-start;
  }
  .briefing-controls {
    width: 100%;
    gap: 8px;
  }
  .briefing-play-btn {
    width: 36px;
    height: 36px;
  }
}


/* ============================================================
   Admin Mode & Community Badge
   ============================================================ */

/* Admin delete button */
.admin-delete-btn {
  display: none;
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #ef4444;
  font-size: 14px;
  cursor: pointer;
  z-index: 10;
  transition: all 0.2s;
  align-items: center;
  justify-content: center;
}
.admin-delete-btn:hover {
  background: rgba(239, 68, 68, 0.3);
  border-color: #ef4444;
  transform: scale(1.1);
}
body.admin-mode .admin-delete-btn {
  display: flex;
}

/* Ensure wire-item and dashboard-item have relative positioning for the delete button */
body.admin-mode .wire-item,
body.admin-mode .dashboard-item {
  position: relative;
}

/* Community badge */
.card-category[data-cat="Community"] {
  background: rgba(0, 170, 250, 0.15);
  color: #00AAFA;
  border-color: rgba(0, 170, 250, 0.3);
}

/* Admin mode indicator */
body.admin-mode::after {
  content: 'ADMIN MODE';
  position: fixed;
  bottom: 16px;
  right: 16px;
  background: rgba(239, 68, 68, 0.9);
  color: white;
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  z-index: 9999;
  pointer-events: none;
}

/* Delete fade animation */
@keyframes fadeOutDelete {
  to { opacity: 0; transform: scale(0.95); height: 0; margin: 0; padding: 0; overflow: hidden; }
}
.deleting {
  animation: fadeOutDelete 0.4s ease forwards;
}

/* Non-linked community cards */
.story-card-static {
  cursor: default;
}
.story-card-static:hover {
  transform: none;
  border-color: var(--border);
}

/* PDF expandable cards */
.story-card-pdf {
  cursor: pointer;
}
.story-card-pdf:hover {
  transform: translateY(-2px);
  border-color: var(--border-hover);
}
.card-pdf-hint {
  font-size: 12px;
  color: var(--accent-cyan);
  margin-top: 8px;
  font-weight: 500;
}
/* v121: legacy inline PDF preview styles kept for any cached HTML pre-deploy;
   the modal is the canonical view path now. */
.card-pdf-content {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
}
.card-pdf-text {
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-secondary);
  max-height: 400px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-break: break-word;
}
.story-card-pdf.expanded {
  grid-column: 1 / -1;
}

/* ============================================================
   v121: PDF text modal (overlay)
   Fetches extracted PDF text on-demand for community submissions
   that have no external link.
   ============================================================ */
.pdf-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: pdfModalFadeIn 160ms ease-out;
}
.pdf-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 8, 18, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  cursor: pointer;
}
.pdf-modal-panel {
  position: relative;
  z-index: 1;
  max-width: 780px;
  width: 100%;
  max-height: calc(100vh - 48px);
  background: var(--surface, #0d1524);
  border: 1px solid var(--border, rgba(255,255,255,0.08));
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0,0,0,0.55);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: pdfModalRise 200ms cubic-bezier(0.22, 1, 0.36, 1);
}
.pdf-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--text-secondary, #aab3c5);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 120ms ease, color 120ms ease, border-color 120ms ease;
}
.pdf-modal-close:hover {
  background: rgba(255,255,255,0.12);
  color: var(--text-primary, #fff);
  border-color: rgba(255,255,255,0.16);
}
.pdf-modal-header {
  padding: 24px 56px 12px 24px;
  border-bottom: 1px solid var(--border-subtle, rgba(255,255,255,0.06));
  flex: 0 0 auto;
}
.pdf-modal-source {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-cyan, #4dd0e1);
  margin-bottom: 6px;
}
.pdf-modal-title {
  font-size: 20px;
  line-height: 1.35;
  margin: 0;
  color: var(--text-primary, #fff);
  word-break: break-word;
}
.pdf-modal-body {
  padding: 20px 24px 24px;
  overflow-y: auto;
  flex: 1 1 auto;
}
.pdf-modal-text {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-secondary, #cbd3e0);
  white-space: pre-wrap;
  word-break: break-word;
}
.pdf-modal-loading,
.pdf-modal-empty,
.pdf-modal-error {
  font-size: 14px;
  color: var(--text-muted, #7f8896);
  padding: 24px 0;
  text-align: center;
}
.pdf-modal-error {
  color: #ff8a8a;
}
@keyframes pdfModalFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes pdfModalRise {
  from { opacity: 0; transform: translateY(8px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@media (max-width: 640px) {
  .pdf-modal { padding: 12px; }
  .pdf-modal-header { padding: 20px 52px 10px 18px; }
  .pdf-modal-title { font-size: 18px; }
  .pdf-modal-body { padding: 16px 18px 18px; }
  .pdf-modal-text { font-size: 14px; }
}

.wire-item-link-muted {
  color: var(--text-muted) !important;
  cursor: default;
}

/* ============================================================
   FOR BRANDS SECTION (About page)
   ============================================================ */
.about-for-brands {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
}
.brand-benefits {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin: 1.25rem 0;
}
.brand-benefit {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}
.brand-benefit svg {
  flex-shrink: 0;
  margin-top: 2px;
}
.brand-benefit span {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.5;
}
.brand-benefit strong {
  color: var(--text-primary);
}
.brand-cta {
  margin-top: 1rem;
  font-size: var(--text-sm);
  color: var(--text-secondary);
}
.brand-cta-link {
  color: var(--accent-cyan);
  text-decoration: none;
  font-weight: 600;
}
.brand-cta-link:hover {
  text-decoration: underline;
}

/* ============================================================
   BRAND CALLOUT BANNER (Submit page)
   ============================================================ */
.brand-callout {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  background: var(--surface-raised);
  border: 1px solid var(--accent-cyan);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  margin: 1.25rem 0 1.5rem;
}
.brand-callout-icon {
  flex-shrink: 0;
  margin-top: 2px;
}
.brand-callout-text {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.55;
}
.brand-callout-text strong {
  color: var(--text-primary);
}
@media (max-width: 600px) {
  .brand-callout {
    flex-direction: column;
    gap: 0.5rem;
  }
}

/* ============================================================
   BRAND PAGES — Nav Dropdowns, Company Page, Brands Listing
   ============================================================ */

/* ----- Nav Dropdown ----- */
.nav-dropdown-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 0;
  min-width: 280px;
  max-width: 320px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  box-shadow: 0 12px 40px rgba(0,0,0,0.5);
  z-index: 1000;
  overflow: hidden;
}

/* Invisible bridge above the dropdown so the cursor can travel from
   trigger to menu without triggering hover-out. */
.nav-dropdown::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 0;
  right: 0;
  height: 8px;
  background: transparent;
  pointer-events: auto;
}

.nav-dropdown-wrap:hover .nav-dropdown,
.nav-dropdown-wrap.open .nav-dropdown {
  display: block;
}

.nav-dropdown-search {
  position: sticky;
  top: 0;
  padding: 10px 12px 8px 12px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
  border-top-left-radius: var(--radius-card);
  border-top-right-radius: var(--radius-card);
  z-index: 2;
}

.nav-dropdown-search input {
  width: 100%;
  padding: 8px 12px;
  font-size: 13px;
  font-family: var(--font-body);
  background: var(--bg-card, var(--bg-primary));
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  outline: none;
  transition: border-color 0.15s;
}

.nav-dropdown-search input:focus {
  border-color: var(--accent-cyan);
}

.nav-dropdown-list {
  display: flex;
  flex-direction: column;
  max-height: 380px;
  overflow-y: auto;
  padding: 6px 0;
  scrollbar-width: thin;
  scrollbar-color: var(--border-subtle) transparent;
}

.nav-dropdown-list::-webkit-scrollbar {
  width: 8px;
}

.nav-dropdown-list::-webkit-scrollbar-track {
  background: transparent;
}

.nav-dropdown-list::-webkit-scrollbar-thumb {
  background: var(--border-subtle);
  border-radius: 4px;
}

.nav-dropdown-list::-webkit-scrollbar-thumb:hover {
  background: var(--accent-cyan-dim);
}

.nav-dropdown-empty {
  padding: 20px 16px;
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
}

.nav-dropdown-divider {
  height: 1px;
  background: var(--border-subtle);
  margin: 6px 12px;
}

.nav-dropdown-item-partner .nav-dropdown-name {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-dropdown-partner-pill {
  display: inline-flex;
  align-items: center;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent-cyan), var(--accent-cyan-2, var(--accent-cyan)));
  color: #0f172a;
  line-height: 1;
}

.nav-dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--text-secondary);
  text-decoration: none;
  transition: background var(--transition-fast), color var(--transition-fast);
  cursor: pointer;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
}

.nav-dropdown-item:hover {
  background: var(--accent-cyan-dim);
  color: var(--text-primary);
}

.nav-dropdown-item .dropdown-count {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.nav-dropdown-all {
  display: block;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-cyan);
  text-decoration: none;
  border-top: 1px solid var(--border-subtle);
  margin-top: 4px;
  text-align: center;
  transition: background var(--transition-fast);
}

.nav-dropdown-all:hover {
  background: var(--accent-cyan-dim);
}

/* Mobile: dropdowns not shown as hover menus */
@media (max-width: 767px) {
  .nav-dropdown { display: none !important; }
}

/* ----- Brands Listing Page ----- */
.brands-intro {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 24px;
  max-width: 640px;
}

.brands-search-row {
  margin-bottom: 24px;
  max-width: 400px;
}

.brands-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

.brand-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  cursor: pointer;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast), transform var(--transition-fast);
  text-decoration: none;
  color: var(--text-primary);
}

.brand-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.brand-card-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
}

.brand-card-count {
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  white-space: nowrap;
}

.brand-card .sponsor-badge-sm {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-cyan);
  background: var(--accent-cyan-dim);
  border: 1px solid rgba(0,170,250,0.2);
  border-radius: var(--radius-pill);
  padding: 2px 8px;
  margin-left: 8px;
  vertical-align: middle;
}

/* ----- Company Detail Page ----- */
.company-page .page-content {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 24px;
}

.company-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.company-info {
  flex: 1;
  min-width: 0;
}

.company-back-link {
  display: inline-block;
  font-size: 13px;
  color: var(--text-muted);
  text-decoration: none;
  margin-bottom: 8px;
  transition: color var(--transition-fast);
}

.company-back-link:hover {
  color: var(--accent-cyan);
}

.company-info h1 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.company-stats {
  font-size: 14px;
  color: var(--text-secondary);
}

.sponsor-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-cyan);
  background: var(--accent-cyan-dim);
  border: 1px solid rgba(0,170,250,0.25);
  border-radius: var(--radius-pill);
  padding: 4px 14px;
  margin-top: 8px;
}

.sponsor-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  min-width: 180px;
}

.sponsor-logo {
  max-width: 160px;
  max-height: 60px;
  object-fit: contain;
}

.sponsor-website {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-cyan);
  text-decoration: none;
  transition: opacity var(--transition-fast);
}

.sponsor-website:hover {
  opacity: 0.8;
}

.claim-cta {
  background: var(--bg-card);
  border: 1px dashed rgba(0,170,250,0.25);
  border-radius: var(--radius-card);
  padding: 16px 20px;
  margin-bottom: 24px;
}

.claim-cta p {
  font-size: 14px;
  color: var(--text-secondary);
  margin: 0;
}

.claim-cta a {
  color: var(--accent-cyan);
  text-decoration: none;
  font-weight: 600;
}

.claim-cta a:hover {
  text-decoration: underline;
}

/* Company articles reuse the existing cards-grid layout */
.company-page .cards-grid {
  margin-top: 0;
}

/* ===== SPONSOR LANDING PAGE ===== */
.sponsor-landing { max-width: 960px; margin: 0 auto; padding: 2rem 1rem; }
.sponsor-hero-title { font-size: 2.2rem; color: #fff; margin-bottom: 0.5rem; text-align: center; }
.sponsor-hero-sub { font-size: 1.1rem; color: #aaa; text-align: center; margin-bottom: 2rem; }
.sponsor-intro { max-width: 720px; margin: 0 auto 2.5rem; }
.sponsor-intro p { color: #ccc; line-height: 1.7; margin-bottom: 1rem; font-size: 1rem; }
.sponsor-section-title { font-size: 1.4rem; color: var(--accent-cyan); margin: 2rem 0 1rem; text-align: center; }
.sponsor-tiers { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; margin-bottom: 2rem; }
.sponsor-tier-card { background: #1a1a2e; border: 1px solid #333; border-radius: 12px; padding: 1.5rem; }
.sponsor-tier-card.featured { border-color: var(--accent-cyan); box-shadow: 0 0 20px rgba(0,212,255,0.15); }
.sponsor-tier-card h3 { font-size: 1.2rem; color: #fff; margin-bottom: 0.5rem; }
.sponsor-price { font-size: 2rem; font-weight: 800; color: var(--accent-cyan); }
.sponsor-price span { font-size: 0.9rem; font-weight: 400; color: #888; }
.sponsor-price-note { font-size: 0.8rem; color: #888; margin-bottom: 1rem; }
.sponsor-tier-card ul { list-style: none; padding: 0; }
.sponsor-tier-card li { color: #ccc; padding: 0.4rem 0; padding-left: 1.2rem; position: relative; font-size: 0.9rem; }
.sponsor-tier-card li::before { content: "✓"; position: absolute; left: 0; color: var(--accent-cyan); font-weight: 700; }
.sponsor-categories { display: flex; flex-wrap: wrap; gap: 0.8rem; justify-content: center; margin-bottom: 2rem; }
.sponsor-cat { background: #1a1a2e; border: 1px solid #333; border-radius: 8px; padding: 0.6rem 1.2rem; color: #fff; font-size: 0.9rem; }
.sponsor-cta-block { text-align: center; padding: 2rem; background: #1a1a2e; border-radius: 12px; border: 1px solid #333; }
.sponsor-cta-block h2 { color: #fff; margin-bottom: 0.5rem; }
.sponsor-cta-block p { color: #aaa; margin-bottom: 1.5rem; }
.sponsor-cta-btn { display: inline-block; background: var(--accent-cyan); color: #000; padding: 0.8rem 2rem; border-radius: 8px; text-decoration: none; font-weight: 700; font-size: 1rem; transition: background 0.2s; }
.sponsor-cta-btn:hover { background: #00b8d4; }

/* Sponsor bundle discount note */
.sponsor-bundle-note { text-align: center; padding: 1.2rem 1.5rem; background: var(--accent-cyan-dim); border: 1px solid var(--accent-cyan); border-radius: 10px; margin: 1.5rem auto; max-width: 680px; }
.sponsor-bundle-note p { color: #ccc; font-size: 0.95rem; margin: 0; line-height: 1.6; }
.sponsor-bundle-note strong { color: var(--accent-cyan); }

/* Sponsor tier CTA buttons */
.sponsor-tier-btn { display: block; text-align: center; background: var(--accent-cyan); color: #000; padding: 0.7rem 1.5rem; border-radius: 8px; text-decoration: none; font-weight: 700; font-size: 0.95rem; margin-top: auto; transition: background 0.2s, transform 0.1s; }
.sponsor-tier-btn:hover { background: #00c4b8; transform: translateY(-1px); }
.sponsor-tier-card { display: flex; flex-direction: column; }
.sponsor-tier-card ul { flex: 1; }

/* Add Your Brand form on Brands page */
.brands-add-row { margin-bottom: 1.5rem; }
.brands-add-form { display: flex; gap: 0.8rem; max-width: 500px; }
.brands-add-input { flex: 1; padding: 0.6rem 1rem; border-radius: 8px; border: 1px solid #333; background: #1a1a2e; color: #fff; font-size: 0.95rem; outline: none; transition: border-color 0.2s; }
.brands-add-input:focus { border-color: var(--accent-cyan); }
.brands-add-btn { padding: 0.6rem 1.2rem; border-radius: 8px; border: none; background: var(--accent-cyan); color: #000; font-weight: 700; font-size: 0.9rem; cursor: pointer; white-space: nowrap; transition: background 0.2s; }
.brands-add-btn:hover { background: #00c4b8; }
.brands-add-note { font-size: 0.85rem; margin-top: 0.5rem; color: #888; }
.brands-add-note.success { color: var(--accent-cyan); }
.brands-add-note.error { color: #f44; }

/* Brands pagination */
.brands-pagination { display: flex; align-items: center; justify-content: center; gap: 1rem; padding: 1.5rem 0; grid-column: 1 / -1; }
.brands-page-btn { background: var(--accent-cyan); color: #000; border: none; padding: 0.5rem 1.2rem; border-radius: 6px; font-weight: 700; font-size: 0.85rem; cursor: pointer; transition: background 0.2s; }
.brands-page-btn:hover { background: #00c4b8; }
.brands-page-info { color: #888; font-size: 0.85rem; }

/* ============================================================
   WATCHLIST
   ============================================================ */

.watchlist-intro {
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.7;
  max-width: 640px;
  margin-bottom: 2rem;
}

/* --- Setup Section --- */
.watchlist-setup {
  max-width: 640px;
}

.watchlist-keywords {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 1rem;
  min-height: 40px;
  align-items: center;
}

.watchlist-empty {
  color: var(--text-muted);
  font-size: 14px;
  font-style: italic;
}

.watchlist-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-cyan-dim);
  border: 1px solid var(--accent-cyan);
  color: var(--accent-cyan);
  padding: 6px 10px 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font-body);
  animation: watchlistPillIn 0.25s ease;
}

@keyframes watchlistPillIn {
  from { opacity: 0; transform: scale(0.85); }
  to   { opacity: 1; transform: scale(1); }
}

.watchlist-pill-text {
  white-space: nowrap;
}

.watchlist-pill-remove {
  background: none;
  border: none;
  color: var(--accent-cyan);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 0 2px;
  opacity: 0.7;
  transition: opacity var(--transition-fast);
}
.watchlist-pill-remove:hover {
  opacity: 1;
}

.watchlist-input-row {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}

.watchlist-input-wrap {
  flex: 1;
  position: relative;
}

.watchlist-input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.watchlist-input {
  width: 100%;
  padding: 10px 14px 10px 40px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-input);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition-fast);
}
.watchlist-input:focus {
  border-color: var(--accent-cyan);
}
.watchlist-input:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.watchlist-add-btn {
  padding: 10px 20px;
  background: var(--accent-cyan);
  color: #000;
  border: none;
  border-radius: var(--radius-input);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background var(--transition-fast);
  white-space: nowrap;
}
.watchlist-add-btn:hover {
  background: #00c4b8;
}

.watchlist-hint {
  color: var(--text-muted);
  font-size: 13px;
  margin-bottom: 1.5rem;
}

.watchlist-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 1rem;
}

.watchlist-apply-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--accent-cyan);
  color: #000;
  border: none;
  border-radius: var(--radius-input);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background var(--transition-fast), transform var(--transition-fast);
}
.watchlist-apply-btn:hover {
  background: #00c4b8;
  transform: translateY(-1px);
}

.watchlist-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-input);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
}
.watchlist-share-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.watchlist-clear-btn {
  padding: 10px 16px;
  background: transparent;
  color: var(--text-muted);
  border: none;
  font-family: var(--font-body);
  font-size: 13px;
  cursor: pointer;
  transition: color var(--transition-fast);
}
.watchlist-clear-btn:hover {
  color: #ef4444;
}

.watchlist-share-note {
  font-size: 13px;
  margin-top: 4px;
  color: var(--accent-cyan);
}

/* --- Active Watchlist Bar --- */
.watchlist-active-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 12px 20px;
  background: var(--accent-cyan-dim);
  border: 1px solid rgba(0,170,250,0.2);
  border-radius: var(--radius-card);
  margin-bottom: 1rem;
}

.watchlist-active-info {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--accent-cyan);
  font-size: 14px;
  font-weight: 500;
}
.watchlist-active-info svg {
  flex-shrink: 0;
}

.watchlist-active-keywords {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
}

.watchlist-active-pill {
  display: inline-block;
  background: rgba(0,170,250,0.15);
  border: 1px solid rgba(0,170,250,0.3);
  color: var(--accent-cyan);
  padding: 2px 10px;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 600;
}

.watchlist-active-actions {
  display: flex;
  gap: 8px;
}

.watchlist-edit-btn,
.watchlist-deactivate-btn {
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: 1px solid var(--border-subtle);
  background: transparent;
  color: var(--text-secondary);
}
.watchlist-edit-btn:hover,
.watchlist-deactivate-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.watchlist-match-count {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 1rem;
}

/* Keyword highlighting in cards */
.watchlist-highlight {
  background: rgba(0,170,250,0.2);
  color: var(--accent-cyan);
  border-radius: 3px;
  padding: 0 2px;
}

/* Light theme overrides */
[data-theme="light"] .watchlist-highlight {
  background: rgba(0,136,204,0.15);
  color: #007a6d;
}

/* Mobile */
@media (max-width: 768px) {
  .watchlist-input-row {
    flex-direction: column;
  }
  .watchlist-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .watchlist-apply-btn,
  .watchlist-share-btn {
    justify-content: center;
  }
  .watchlist-active-bar {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ============================================================
   SPONSOR BADGES
   ============================================================ */

.sponsor-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: linear-gradient(135deg, var(--accent-cyan), #0088CC);
  color: #001a18;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
  flex-shrink: 0;
}

.sponsor-badge::before {
  content: "";
  display: inline-block;
  width: 5px;
  height: 5px;
  background: currentColor;
  border-radius: 50%;
  opacity: 0.9;
}

[data-theme="light"] .sponsor-badge {
  background: linear-gradient(135deg, #0088CC, #00897b);
  color: #fff;
}

.sponsor-badge-sponsored {
  background: linear-gradient(135deg, #f59e0b, #fbbf24);
  color: #1a1100;
}

/* ============================================================
   PARTNERS PAGE
   ============================================================ */

.partners-hero {
  text-align: center;
  margin-bottom: 3rem;
  padding: 2rem 1rem;
}

.partners-hero h1 {
  font-size: 32px;
  margin-bottom: 12px;
}

.partners-hero p {
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 24px;
  font-size: 16px;
  line-height: 1.6;
}

.partners-cta-top {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--accent-cyan);
  color: #000;
  border-radius: var(--radius-pill);
  font-weight: 700;
  text-decoration: none;
  transition: filter var(--transition-fast);
}
.partners-cta-top:hover {
  filter: brightness(1.1);
  text-decoration: none;
}

.partners-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-bottom: 4rem;
}

.partner-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 24px;
  text-align: center;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  transition: all var(--transition-fast);
}

.partner-card:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-2px);
  text-decoration: none;
}

.partner-card-logo {
  width: 100%;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
}

.partner-card-logo img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* Theme-aware logo swapping. Default site theme is dark. */
.theme-logo { display: none; }
.theme-logo-dark { display: block; }
[data-theme="light"] .theme-logo-dark { display: none; }
[data-theme="light"] .theme-logo-light { display: block; }

.partner-card-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.partner-card-tagline {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.partner-card-tier {
  margin-top: auto;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent-cyan);
}

.partner-card-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.partner-card-logo-text {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 0.02em;
}

.partner-card-link {
  font-size: 12px;
  color: var(--accent-cyan);
  text-decoration: none;
  font-weight: 600;
  margin-top: 4px;
}

.partner-card-link:hover {
  text-decoration: underline;
}

.partners-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

.partners-bottom-cta {
  text-align: center;
  padding: 3rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  margin-bottom: 2rem;
}

.partners-bottom-cta h2 {
  font-size: 24px;
  margin-bottom: 12px;
}

.partners-bottom-cta p {
  color: var(--text-secondary);
  margin-bottom: 20px;
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================================
   BECOME A PARTNER PAGE
   ============================================================ */

.partner-info-hero {
  text-align: center;
  padding: 3rem 1rem;
  margin-bottom: 2rem;
}

.partner-info-hero h1 {
  font-size: 36px;
  margin-bottom: 12px;
}

.partner-info-hero p {
  color: var(--text-secondary);
  font-size: 16px;
  max-width: 720px;
  margin: 0 auto;
  line-height: 1.7;
}

.partner-info-tiers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin-bottom: 3rem;
}

.partner-tier-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 24px;
  display: flex;
  flex-direction: column;
}

.partner-tier-card.featured {
  border-color: var(--accent-cyan);
  background: linear-gradient(180deg, var(--bg-card) 0%, rgba(0, 170, 250, 0.04) 100%);
  position: relative;
}

.partner-tier-card.featured::before {
  content: "MOST POPULAR";
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent-cyan);
  color: #000;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.tier-name {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent-cyan);
  margin-bottom: 8px;
}

.tier-price {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 4px;
}

.tier-price-period {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.tier-features {
  list-style: none;
  padding: 0;
  margin: 0 0 24px 0;
  flex: 1;
}

.tier-features li {
  padding: 8px 0;
  color: var(--text-secondary);
  font-size: 14px;
  position: relative;
  padding-left: 22px;
}

.tier-features li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  width: 14px;
  height: 8px;
  border-left: 2px solid var(--accent-cyan);
  border-bottom: 2px solid var(--accent-cyan);
  transform: rotate(-45deg);
}

.tier-cta {
  display: block;
  text-align: center;
  padding: 12px 16px;
  background: var(--bg-input);
  border: 1px solid var(--accent-cyan);
  color: var(--accent-cyan);
  border-radius: var(--radius-input);
  font-weight: 700;
  text-decoration: none;
  transition: all var(--transition-fast);
}

.partner-tier-card.featured .tier-cta {
  background: var(--accent-cyan);
  color: #000;
}

.tier-cta:hover {
  filter: brightness(1.1);
  text-decoration: none;
}

.partner-info-talk {
  text-align: center;
  padding: 2rem 1rem;
  margin-bottom: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
}

.partner-info-talk a {
  font-weight: 600;
}

@media (max-width: 768px) {
  .partner-info-hero h1 { font-size: 28px; }
  .partners-hero h1 { font-size: 24px; }
}

/* ============================================================
   STANDALONE PAGE TOP BAR
   ============================================================
   The Weekly Wire and Privacy pages are rendered by the worker and do not
   carry the SPA header, so their only route back to the feed used to be a
   small text link below the archive list. On a phone that sat several
   screens down and read as a dead end. This bar puts a back link and
   the logo in reach from the moment the page opens. The link at the foot of
   those pages is still there for anyone who reaches the bottom.
   ============================================================ */
/* Deliberately not sticky. At the header's logo size the bar is around 105px,
   and parking that at the top of a phone screen for the whole episode costs
   more than the convenience is worth. It scrolls away with the page. */
.page-topbar {
  position: static;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
}

.page-topbar-inner {
  max-width: 780px;
  margin: 0 auto;
  padding: 10px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.page-topbar-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  /* Comfortable thumb target on a phone. */
  padding: 8px 4px;
  min-height: 44px;
}

.page-topbar-back svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.page-topbar-back:hover,
.page-topbar-back:focus-visible {
  color: var(--accent-cyan);
}

.page-topbar-logo {
  display: block;
  flex-shrink: 0;
  line-height: 0;
}

/* The bar reuses the site header's own logo classes (.header-logo-img and the
   two theme variants) so the mark is the identical file at the identical size
   in both places. A parallel set of rules here is exactly how the two would
   drift apart, so there is deliberately no .page-topbar-logo-img. */

@media (max-width: 480px) {
  .page-topbar-inner { padding: 8px 16px; }
}
/* ============================================================
   LISTEN HOMEPAGE
   Navy chrome (#0B1320), AirWire blue (#00AAFA).
   Headlines: Syne ExtraBold / Bold. Body and subtitles: Plus Jakarta Sans.
   Nav and controls: Inter. Photographic stage with a soft left white fade.
   No theme toggle. No display-font picker.
   ============================================================ */


html {
  --listen-display: 'Syne', sans-serif;
  --listen-body: 'Plus Jakarta Sans', 'Inter', sans-serif;
  --page-gutter: 24px;
  --listen-title-ink: 0.070em;
  --listen-stat-ink: 0.035em;
}

/* Cached shells may still include the removed preview picker. */
.display-picker { display: none !important; }

/* Interior hash routes stay on the Production dark surface even when a
   cached light stylesheet is still winning the cascade. */
html[data-surface="interior"] {
  --bg-primary: #030712 !important;
  --bg-secondary: #0a0f1e !important;
  --bg-card: #0d1220 !important;
  --bg-card-hover: #111827 !important;
  --text-primary: #f0f0f0 !important;
  --text-secondary: #9ca3af !important;
  --text-muted: #6b7280 !important;
  --border-subtle: rgba(255,255,255,0.08) !important;
  --font-display: 'Syne', sans-serif !important;
  --font-body: 'DM Sans', sans-serif !important;
}
html[data-surface="interior"] body,
body:not(:has(#page-home.active)) {
  background: #030712 !important;
  color: #f0f0f0 !important;
}
html[data-surface="interior"] .site-header,
html[data-surface="interior"] .mobile-nav,
body:not(:has(#page-home.active)) .site-header,
body:not(:has(#page-home.active)) .mobile-nav {
  background: #0B1320 !important;
}
html[data-surface="interior"] .page-heading,
html[data-surface="interior"] .about-section h2,
html[data-surface="interior"] .company-info h1,
html[data-surface="interior"] .newsletter-info h2,
html[data-surface="interior"] .submit-card h2,
html[data-surface="interior"] .step-content h3,
html[data-surface="interior"] .partners-hero h1 {
  font-family: 'Syne', sans-serif !important;
  color: #f0f0f0 !important;
}
html[data-surface="interior"] .gradient-text {
  background: linear-gradient(135deg, #00AAFA, #00B4D8) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  color: transparent !important;
}
html[data-surface="interior"] .brand-card,
html[data-surface="interior"] .story-card,
html[data-surface="interior"] .source-card,
html[data-surface="interior"] .about-owner,
html[data-surface="interior"] .newsletter-form-card,
html[data-surface="interior"] .submit-card,
body:not(:has(#page-home.active)) .brand-card,
body:not(:has(#page-home.active)) .story-card,
body:not(:has(#page-home.active)) .source-card,
body:not(:has(#page-home.active)) .about-owner,
body:not(:has(#page-home.active)) .newsletter-form-card,
body:not(:has(#page-home.active)) .submit-card {
  background: #0d1220 !important;
  border-color: rgba(255,255,255,0.08) !important;
}
html[data-surface="interior"] .brand-card,
html[data-surface="interior"] .story-card,
html[data-surface="interior"] .card-title {
  color: #f0f0f0 !important;
}
html[data-surface="interior"] .source-card { color: #9ca3af !important; }

body:has(#page-home.active) { background: #F8FAFC; }

.main-content:has(#page-home.active) {
  max-width: none;
  padding: 0;
}

.listen-hero {
  --font-display: 'Syne', sans-serif;
  position: relative;
  margin: 0;
  border-radius: 0;
  overflow: hidden;
  color: #0F172A;
  background: #F8FAFC;
  font-family: var(--listen-body);
  min-height: 0;
  scroll-margin-top: 72px;
}

.listen-hero-bg {
  position: absolute;
  inset: 0;
  background: #d5dbe3;
  pointer-events: none;
  overflow: hidden;
}

.listen-stage-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 68% 42%;
  display: block;
  filter: grayscale(1) contrast(1.06);
}

.listen-hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    #fff 0%,
    rgba(255,255,255,0.97) 16%,
    rgba(255,255,255,0.88) 32%,
    rgba(255,255,255,0.48) 50%,
    rgba(255,255,255,0.12) 68%,
    rgba(255,255,255,0) 84%);
}

.listen-hero-grid {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 380px);
  gap: 28px;
  padding: 32px var(--page-gutter) 28px;
  align-items: stretch;
  min-height: 0;
}

.listen-hero-main { max-width: 640px; padding-top: 4px; }

.listen-kicker {
  font-family: var(--listen-body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #6B7280;
  margin-bottom: 8px;
}

.listen-title {
  font-family: var(--listen-display);
  font-size: clamp(52px, 5.1vw, 72px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.12;
  margin: 0 0 16px;
  margin-left: calc(var(--listen-title-ink) * -1);
  color: #0F172A;
}

.listen-hero.is-weekly .listen-title {
  font-size: clamp(36px, 3.6vw, 52px);
  max-width: 11em;
}

.listen-date {
  font-family: var(--listen-body);
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: #334155;
  margin-bottom: 4px;
}

.listen-proposition {
  max-width: 380px;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.4;
  color: #334155;
  margin-bottom: 16px;
}

.listen-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, max-content));
  gap: 4px 36px;
  margin-bottom: 18px;
  min-height: 0;
}

.listen-stat {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.listen-stat strong {
  font-family: var(--listen-display);
  font-size: clamp(30px, 2.6vw, 40px);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: #0F172A;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  margin-left: calc(var(--listen-stat-ink) * -1);
}

.listen-stat span {
  font-size: 13px;
  font-weight: 400;
  color: #6B7280;
  white-space: nowrap;
}

.listen-transport {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 12px;
}

.listen-play-btn {
  height: 48px;
  padding: 0 18px 0 14px;
  border-radius: 999px;
  background: #00AAFA;
  color: #0B1320;
  display: inline-flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-shrink: 0;
  max-width: 100%;
  white-space: nowrap;
  box-shadow: 0 8px 18px rgba(0, 170, 250), 0.28);
  transition: transform var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast);
}

.listen-play-btn:hover { background: #0088C8; transform: translateY(-1px); }
.listen-play-btn:active { background: #0088C8; transform: scale(0.98); }

.listen-play-label {
  font-family: 'Inter', var(--font-body);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #0B1320;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.listen-file-duration {
  font-family: 'Inter', var(--font-body);
  font-size: 15px;
  font-weight: 500;
  color: #334155;
  font-variant-numeric: tabular-nums;
}

.listen-transport-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 0;
}

.listen-tool-btn {
  min-width: 42px;
  height: 42px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid #E5E7EB;
  background: rgba(255,255,255,0.86);
  color: #0F172A;
  font-family: 'Inter', var(--font-body);
  font-size: 13px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.listen-tool-btn:hover { border-color: #0088C8; color: #0B1320; }

.listen-skip { position: relative; width: 46px; padding: 0; }
.listen-skip span {
  position: absolute;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.listen-scrub {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 640px;
}

.listen-time {
  font-family: var(--font-mono);
  font-size: 12px;
  color: #374151;
  min-width: 36px;
}

.listen-hero .listen-scrubber {
  background-color: #E5E7EB;
}

.listen-scrubber,
.briefing-scrubber {
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  border-radius: 999px;
  background: rgba(255,255,255,0.22);
  background-image: linear-gradient(#00AAFA, #00AAFA);
  background-repeat: no-repeat;
  background-size: 0% 100%;
  cursor: pointer;
  flex: 1;
}

.listen-scrubber { width: 100%; }

.listen-scrubber::-webkit-slider-thumb,
.briefing-scrubber::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(0,170,250,0.35);
}

.listen-empty {
  margin-top: 8px;
  color: #374151;
  font-size: 14px;
}

.listen-hero .listen-scrubber::-webkit-slider-thumb {
  background: #0F172A;
  box-shadow: 0 0 0 3px rgba(0,170,250,0.35);
}

.listen-topics {
  background: rgba(3,7,18,0.85);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px;
  padding: 16px 16px 12px;
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  color: #fff;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 280px;
  box-shadow: 0 16px 40px rgba(11,19,32,0.28);
}

.listen-topics h2 {
  font-family: var(--listen-body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.78);
  margin-bottom: 4px;
}

.listen-topics-list { list-style: none; display: flex; flex-direction: column; }

.listen-topic {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  border-radius: 0;
  padding: 12px 2px;
  color: #fff;
}

.listen-topics-list li:last-child .listen-topic { border-bottom: 0; }

button.listen-topic { cursor: pointer; }
button.listen-topic:hover .listen-topic-title { color: #00AAFA; }

.listen-topic-art {
  width: 52px;
  height: 40px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  background: #1b2436;
}

.listen-topic-art:empty { display: none; }

.listen-topic-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.listen-topic-title {
  flex: 1;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.35;
}

.listen-topic-time {
  font-family: var(--font-mono);
  font-size: 13px;
  color: rgba(255,255,255,0.62);
  flex-shrink: 0;
}

.listen-topics-fallback {
  font-size: 15px;
  line-height: 1.5;
  color: rgba(255,255,255,0.82);
  margin: 18px 2px 12px;
  max-width: 34ch;
}

.listen-topics.is-empty .listen-topics-fallback {
  margin-top: 28px;
}

.listen-topics-all {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  padding-top: 16px;
  background: none;
  border: 0;
  color: #00AAFA;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}

.listen-topics-all::after {
  content: "\2192";
  font-size: 15px;
}

.listen-topics-all:hover { color: #fff; }

.listen-topic.is-extra { display: none; }
.listen-topics.is-expanded .listen-topic.is-extra { display: flex; }

/* Light story layer under the hero */
.listen-sheet {
  --font-display: 'Syne', sans-serif;
  --bg-primary: #F8FAFC;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #F1F5F9;
  --border-subtle: #E5E7EB;
  --border-hover: #E5E7EB;
  --text-primary: #0F172A;
  --text-secondary: #334155;
  --text-muted: #6B7280;
  --shadow-card: 0 1px 2px rgba(15,23,42,0.04);
  --shadow-card-hover: 0 12px 28px rgba(15,23,42,0.08);
  --accent-cyan-dim: rgba(0,170,250,0.12);
  --accent-cyan-glow: rgba(0,170,250,0.16);
  background: #F8FAFC;
  color: #334155;
  font-family: var(--listen-body);
  padding: 20px 0 56px;
}

.listen-sheet-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--page-gutter);
  display: flex;
  flex-direction: column;
}

.listen-sheet .listen-board { order: 0; }
.listen-sheet .brand-line {
  order: 1;
  margin-top: 28px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  justify-content: start;
  justify-items: stretch;
  align-items: start;
}
.listen-sheet .stories-section { order: 2; }

.listen-board.program-row,
.listen-board.program-row.weekly-dominant {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  margin-bottom: 8px;
  align-items: start;
}

@media (max-width: 767px) {
  .listen-board.program-row,
  .listen-board.program-row.weekly-dominant,
  .listen-sheet .brand-line {
    grid-template-columns: minmax(0, 1fr);
  }
}

.program-row.weekly-dominant .program-weekly { order: -1; }

.program-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  text-align: left;
  text-decoration: none;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 16px;
  padding: 16px 16px 14px;
  color: #334155;
  min-height: 0;
  box-shadow: 0 1px 2px rgba(15,23,42,0.04);
  transition: border-color var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
}

.listen-board .program-weekly,
.listen-board .program-daily {
  border-color: rgba(17,24,39,0.14);
  box-shadow: 0 10px 28px rgba(17,24,39,0.06);
  width: 100%;
}

.program-card[hidden] { display: none !important; }

.program-card:hover { border-color: #0088C8; transform: translateY(-1px); }

.program-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #F1F5F9;
  color: #0F172A;
  margin-bottom: 12px;
}

.program-icon[hidden] { display: none !important; }

.daily-sponsor-hero {
  display: block;
  height: 64px;
  width: auto;
  max-width: 168px;
  object-fit: contain;
  object-position: left center;
  margin: 0 0 10px;
}

#programDailyMark.sponsor-mark-card {
  height: 64px;
  max-width: 96px;
}

.daily-sponsor-hero[hidden] { display: none !important; }

.sponsor-mark {
  display: block;
  width: auto;
  height: 22px;
  object-fit: contain;
  object-position: left center;
}

.sponsor-mark[hidden] { display: none !important; }

.sponsor-mark-card {
  height: 28px;
  max-width: 168px;
  margin-bottom: 10px;
}

.sponsor-mark-hero {
  height: 28px;
  max-width: 180px;
  margin: 0 0 10px;
}

.episode-program .sponsor-mark {
  height: 12px;
  max-width: 64px;
  flex-shrink: 0;
}

.program-name {
  font-family: var(--listen-display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: #0F172A;
}

.program-cadence {
  font-family: var(--listen-body);
  font-size: 13px;
  font-weight: 500;
  color: #6B7280;
}

.program-blurb {
  font-size: 14px;
  font-weight: 400;
  color: #334155;
  line-height: 1.4;
}

.program-meta {
  display: block;
  font-family: var(--listen-body);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #0F172A;
}
.program-meta:empty { display: none; }

.program-play {
  margin-top: 12px;
  height: 40px;
  min-height: 40px;
  max-height: 40px;
  padding: 0 14px 0 12px;
  border-radius: 20px;
  background: #00AAFA;
  color: #0B1320;
  display: inline-flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  align-self: flex-start;
  justify-content: flex-start;
  gap: 8px;
  width: max-content;
  max-width: 100%;
  box-sizing: border-box;
  font-family: 'Inter', var(--font-body);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
}
.program-play svg {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  display: block;
}
.program-play-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.program-play:hover { background: #0088C8; }
.program-play[hidden] { display: none; }

.program-play-dur {
  flex: 0 0 auto;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.program-play-dur[hidden] { display: none; }

.program-open {
  margin-top: 10px;
  font-size: 13px;
  font-weight: 600;
  color: #0088C8;
  text-decoration: none;
}

.program-open:hover { color: #0F172A; }

.recent-briefings { margin: 0; display: flex; flex-direction: column; min-width: 0; }

.recent-briefings-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
  gap: 12px;
}

.recent-briefings-head h2 {
  font-family: var(--listen-display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: #0F172A;
}

.listen-sheet .stories-heading h2 {
  font-family: var(--listen-display);
  font-size: clamp(32px, 3.4vw, 44px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  color: #0F172A;
}

.recent-briefings-all {
  background: none;
  border: 0;
  font-family: 'Inter', sans-serif;
  color: #111827;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
}

.recent-briefings-all:hover { color: #0088C8; }

.recent-briefings-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }

.episode-row {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 14px;
  padding: 8px 12px;
  color: #0F172A;
  box-shadow: 0 1px 2px rgba(17,24,39,0.03);
}

.episode-row.is-active { border-color: rgba(0,136,200,0.55); }

.episode-row.is-extra { display: none; }
.recent-briefings.is-expanded .episode-row.is-extra { display: flex; }

.episode-play {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #00AAFA;
  color: #0B1320;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.episode-play:hover { transform: scale(1.05); }

.episode-copy {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1;
  min-width: 0;
}

.episode-program {
  font-family: var(--listen-body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0369A1;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.episode-row.is-weekly .episode-program { color: #1e3a8a; }

.episode-date {
  font-family: var(--listen-body);
  font-weight: 600;
  font-size: 14px;
  color: #0F172A;
  letter-spacing: -0.02em;
}

.episode-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--listen-body);
  font-size: 13px;
  color: #6b7280;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

.episode-dur { min-width: 36px; text-align: right; }

.recent-empty {
  color: #6b7280;
  font-size: 14px;
  padding: 8px 0;
}

.brand-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  justify-items: stretch;
  padding: 8px 0 22px;
  margin-bottom: 8px;
  border-top: 1px solid rgba(17,24,39,0.08);
  border-bottom: 1px solid rgba(17,24,39,0.08);
}

.brand-line-capture {
  grid-column: 1;
  margin: 0;
  width: 100%;
  max-width: none;
}
.brand-line-capture .email-capture-form { margin-bottom: 0; }
.brand-line-capture .email-note { margin-top: 8px; text-align: left; }

.brand-line-copy {
  grid-column: 2;
  margin: 0;
  align-self: center;
  font-size: 14px;
  font-weight: 400;
  color: #334155;
  line-height: 1.45;
  max-width: 42ch;
}

/* One column: form stays first because it is first in the DOM. */
@media (max-width: 767px) {
  .brand-line-capture,
  .brand-line-copy { grid-column: auto; }
}

.stories-section { scroll-margin-top: 84px; padding-top: 8px; }

.stories-heading { margin: 22px 0 12px; }
.stories-heading p {
  color: #334155;
  font-weight: 400;
  max-width: 760px;
  margin-top: 6px;
}

.listen-sheet .filter-pill {
  background: #fff;
  border-color: rgba(17,24,39,0.12);
  color: #374151;
  font-family: 'Inter', sans-serif;
}

.listen-sheet .filter-pill:hover {
  border-color: #111827;
  color: #111827;
  background: #fff;
}

.listen-sheet .filter-pill.active,
.listen-sheet .filter-pill[data-category].active {
  background: #111827;
  color: #fff;
  border-color: #111827;
}

.listen-sheet .story-card {
  padding: 0 0 16px;
  background: #fff;
  border: 1px solid #E5E7EB;
  box-shadow: 0 1px 2px rgba(15,23,42,0.04);
}

.listen-sheet .story-card-media {
  height: 168px;
  overflow: hidden;
  background: #d5dbe3;
  border-radius: 16px 16px 0 0;
}

.listen-sheet .story-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.listen-sheet .story-card .card-header,
.listen-sheet .story-card .card-title,
.listen-sheet .story-card .card-excerpt,
.listen-sheet .story-card .card-footer,
.listen-sheet .story-card .card-pdf-hint {
  padding-left: 18px;
  padding-right: 18px;
}

.listen-sheet .story-card .card-header { padding-top: 14px; margin-bottom: 8px; }
.listen-sheet .story-card:not(:has(.story-card-media)) .card-header { padding-top: 18px; }

.listen-sheet .search-input,
.listen-sheet .email-input {
  background: #fff;
  color: #111827;
  border-color: rgba(17,24,39,0.12);
}

.listen-sheet .layout-switcher { display: none; }

.listen-sheet .filter-section {
  border-bottom: 0;
  margin-bottom: 8px;
  padding-bottom: 4px;
}

.listen-sheet .filter-label,
.listen-sheet .stats-row,
.listen-sheet .filter-row:has(#tagFilters) { display: none; }

/* Story search stays on the Listen sheet. The header icon only focuses it. */
.listen-sheet .search-row,
.listen-sheet .search-row.is-open {
  display: flex;
  margin-top: 8px;
}

.listen-sheet .filter-pill {
  background: #fff;
  border-color: #E5E7EB;
  color: #334155;
  border-radius: 999px;
  font-weight: 500;
  padding: 7px 14px;
}
.listen-sheet .filter-pill.active,
.listen-sheet .filter-pill[data-category].active {
  background: #0F172A;
  color: #fff;
  border-color: #0F172A;
}

.listen-sheet .card-category,
.listen-sheet .card-category[data-cat] {
  font-family: var(--listen-body);
  background: none;
  border: 0;
  color: #6b7280;
  padding: 0;
  letter-spacing: 0.12em;
  font-size: 11px;
  font-weight: 500;
}

.listen-sheet .story-card .card-header { justify-content: space-between; }
.listen-sheet .card-time { margin-left: auto; color: #9ca3af; }
.listen-sheet .story-card .card-title {
  font-family: var(--listen-display);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
  color: #0F172A;
}
.listen-sheet .story-card .card-excerpt {
  color: #334155;
  font-weight: 400;
}
.card-read { display: none; }
.listen-sheet .card-read {
  display: inline-block;
  margin: 0;
  flex: 0 0 auto;
  color: #0088C8;
  font-weight: 600;
  font-size: 14px;
}
/* The Listen sheet used to hide this footer, which also hid the outlet.
   Keep it as the bottom row: the read CTA on the left, publication on the right. */
.listen-sheet .card-footer {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
  padding-top: 0;
  border-top: 0;
  min-width: 0;
}
.listen-sheet .card-footer .card-tags,
.listen-sheet .card-pdf-hint { display: none; }
.listen-sheet .card-footer .card-source {
  margin-left: auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: right;
}
.listen-sheet .story-card-media { height: 176px; border-radius: 18px 18px 0 0; }
.listen-sheet .story-card { border-radius: 18px; overflow: hidden; }

/* Sticky mini player */
.mini-player {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 120;
  font-family: 'Inter', var(--font-body);
  margin: 0;
  padding: 10px 18px calc(10px + env(safe-area-inset-bottom));
  background: #0B1320;
  color: #f5f7fb;
  border: 0;
  border-top: 1px solid rgba(255,255,255,0.08);
  border-left: 0 !important;
  border-radius: 0;
  box-shadow: 0 -12px 40px rgba(0,0,0,0.35);
  transform: translateY(110%);
  pointer-events: none;
  opacity: 0;
  overflow: visible;
  animation: none !important;
}

.mini-player.briefing-today {
  background: #0B1320;
  box-shadow: 0 -12px 40px rgba(0,0,0,0.35);
}

.mini-player .briefing-label,
.mini-player .briefing-date,
.mini-player .briefing-story-count,
.mini-player .briefing-file-dur,
.mini-player .briefing-time { color: rgba(255,255,255,0.72); }

.mini-player .briefing-label { color: #fff; font-size: 14px; }

.sponsor-mark-mini {
  height: 18px;
  width: auto;
  max-width: 96px;
  background: none;
  border-radius: 0;
  padding: 0;
  box-sizing: content-box;
  flex: 0 0 auto;
}
.mini-player .briefing-dot { color: rgba(255,255,255,0.45); font-size: 12px; }
.mini-player .briefing-label-row { gap: 6px; flex-wrap: wrap; }

.mini-player .briefing-meta-row { flex-wrap: wrap; }

body.player-live .mini-player {
  transform: translateY(0);
  pointer-events: auto;
  opacity: 1;
}

body.player-live { padding-bottom: 92px; }

.mini-art {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  flex-shrink: 0;
  background: #121826 url('./assets/hero-helicopter.jpg') center 35% / cover no-repeat;
}

.mini-player .briefing-player-inner {
  flex-wrap: nowrap;
  max-width: 1280px;
}

.mini-player .briefing-info { min-width: 180px; }

.briefing-skip-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.16);
  background: transparent;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
}

.mini-player .briefing-play-btn {
  width: 42px;
  height: 42px;
  background: #00AAFA;
  color: #0B1320;
}
.mini-player .briefing-play-btn:hover { background: #0088C8; }

.mini-player .briefing-archive-dropdown {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: calc(100% + 8px);
  background: #121826;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 10px 12px;
  max-width: none;
}

.now-playing-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  max-width: 280px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 6px 8px 6px 10px;
}

.now-playing-kicker {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #00AAFA;
}

.now-playing-title {
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 160px;
}

.now-playing-dismiss {
  background: none;
  border: 0;
  color: rgba(255,255,255,0.7);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}

.mini-player.playing { animation: none !important; }

@media (max-width: 1100px) {
  .listen-hero-grid { grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr); gap: 18px; padding: 28px var(--page-gutter) 24px; min-height: 0; }
  .listen-stats { gap: 8px 28px; }
}

@media (max-width: 860px) {
  .listen-hero { min-height: 0; }
  .listen-hero-grid { grid-template-columns: 1fr; padding: 20px var(--page-gutter) 16px; min-height: 0; }
  .listen-stage-photo { object-position: 78% 36%; }
  .listen-hero-bg::after {
    background: linear-gradient(90deg,
      #fff 0%,
      rgba(255,255,255,0.96) 28%,
      rgba(255,255,255,0.78) 52%,
      rgba(255,255,255,0.28) 74%,
      rgba(255,255,255,0) 100%);
  }
  .listen-title { font-size: 48px; margin-bottom: 10px; }
  .listen-hero.is-weekly .listen-title { font-size: 34px; }
  .listen-proposition { margin-bottom: 18px; }
  .listen-stats { margin-bottom: 18px; }
  .listen-topics { min-height: 220px; height: auto; }
  .listen-stats { gap: 8px 22px; }
  .listen-stat strong { font-size: 32px; }
  .now-playing-chip { display: none !important; }
  .mini-player .briefing-player-inner { gap: 8px; }
  body.player-live { padding-bottom: 88px; }
  .listen-sheet { padding-top: 18px; }
  .listen-sheet-inner { padding: 0 var(--page-gutter); }
  .program-card { min-height: 0; }
  /* The stacked header sits on the grayscale fade, which reads as a grey
     smudge. Wide screens keep the faded helicopter exactly as styled above. */
  .listen-hero-bg { background: #F8FAFC; }
  .listen-stage-photo { display: none; }
  .listen-hero-bg::after { content: none; }
}

@media (max-width: 720px) {
  .mini-player { padding: 14px 14px calc(10px + env(safe-area-inset-bottom)); }
  .mini-player .briefing-progress {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    gap: 0;
  }
  .mini-player .briefing-time { display: none; }
  .mini-player .briefing-scrubber { border-radius: 0; height: 3px; }
  .mini-player .briefing-skip-btn,
  .mini-player .briefing-speed-btn,
  .mini-player .briefing-archive-btn { display: none; }
  .mini-player .briefing-controls { width: auto; flex: 0 0 auto; }
  .mini-player .briefing-info { width: auto; flex: 1; min-width: 0; }
  .mini-player .briefing-player-inner { flex-wrap: nowrap; }
}

@media (max-width: 560px) {
  .listen-stat strong { font-size: 30px; }
  .listen-stat span { white-space: normal; font-size: 12px; }
  /* Equal shares for two slots or three. A fixed third column left a blank
     cell whenever key stories was omitted. */
  .listen-stats { display: flex; gap: 6px 12px; }
  .listen-stats .listen-stat { flex: 1 1 0; min-width: 0; }
  .listen-play-btn { height: 52px; padding: 0 18px 0 16px; }
  .listen-play-label { font-size: 15px; }
  .stories-heading h2,
  .listen-sheet .stories-heading h2 { font-size: 30px; }
  .recent-briefings-head h2 { font-size: 20px; }
  .program-card { min-height: 0; padding: 14px; }
  .program-name { font-size: 16px; }
  .program-blurb { font-size: 12px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .listen-hero-grid { padding: 22px var(--page-gutter) 20px; }
}

@media (max-width: 1280px) {
  .header-nav .nav-link { font-size: 12.5px; padding: 8px 6px; }
}

.header-search-btn { color: rgba(255,255,255,0.82); }



/* Shared top nav matches the Listen chrome on both surfaces. */
.site-header,
[data-theme="light"] .site-header,
html[data-surface="interior"] .site-header,
html[data-surface="listen"] .site-header {
  background: #0B1320 !important;
  font-family: 'Inter', var(--font-body);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.mobile-nav,
[data-theme="light"] .mobile-nav {
  background: #0B1320;
}
.header-nav .nav-link,
.mobile-nav .nav-link {
  font-family: 'Inter', var(--font-body);
}
.nav-link.active,
.header-nav .nav-link.active {
  color: #fff;
  background: transparent;
  box-shadow: inset 0 -2px 0 #00AAFA;
}
.mobile-nav .nav-link.active { box-shadow: none; color: #fff; }
/* Navy header uses the dark-background logo in both themes. */
.site-header .header-logo-on-light { display: none !important; }
.site-header .header-logo-on-dark { display: block !important; }
.theme-toggle { display: none !important; }
.header-search-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.82);
}
.header-search-btn:hover { color: #fff; }
/* AirWire keyword filter stays available under the category pills. */
.listen-sheet .keyword-filter-row { display: flex; }
.listen-sheet .keyword-filter-row .filter-label { display: block; }
.listen-sheet .keyword-filter-input {
  background: #fff;
  color: #111827;
}
.briefing-player.mini-player,
.briefing-player.mini-player.briefing-today,
.briefing-player.mini-player.briefing-old {
  opacity: 0;
  border: 0 !important;
  border-top: 1px solid rgba(255,255,255,0.08) !important;
  border-left: 0 !important;
  background: #0B1320 !important;
  box-shadow: 0 -12px 40px rgba(0,0,0,0.35) !important;
  padding: 10px 18px calc(10px + env(safe-area-inset-bottom));
}
body.player-live .briefing-player.mini-player { opacity: 1; }
@media (max-width: 640px) {
  html { --page-gutter: 16px; }
}

/* Phone search: keep the field under the header so the story grid sits in
   the space above the keyboard. Wider screens leave the row in normal flow. */
@media (max-width: 767px) {
  body.mobile-search-active .listen-sheet .search-row {
    position: fixed;
    left: 0;
    right: 0;
    z-index: 90;
    margin: 0;
    padding: 8px var(--page-gutter) 10px;
    background: #F8FAFC;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
  }
  body.mobile-search-active .listen-sheet .search-wrap {
    max-width: none;
  }
  /* The pinned field is z-index 90. Hide the new-story prompt while it is up
     so the pill does not sit on the search the reader is using. */
  body.mobile-search-active .news-new-stories-wrap {
    display: none;
  }
}
