/*
 * Noteworthy News V2 — Component Styles
 */

/* ═══════════════════════════════════════════════════
   TOP RULE (broadcast channel stripe)
   ═══════════════════════════════════════════════════ */

.top-rule {
  height: 3px;
  background: linear-gradient(90deg, var(--color-live), var(--color-accent) 40%, var(--color-accent) 60%, var(--color-live));
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: calc(var(--z-sticky) + 1);
}


/* ═══════════════════════════════════════════════════
   SCROLL REVEAL
   ═══════════════════════════════════════════════════ */

[data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity var(--duration-slow) var(--ease-out),
    transform var(--duration-slow) var(--ease-out);
}

[data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
}


/* ═══════════════════════════════════════════════════
   SITE HEADER / NAVIGATION
   ═══════════════════════════════════════════════════ */

.site-header {
  position: sticky;
  top: 3px;
  z-index: var(--z-sticky);
  height: var(--header-height);
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid var(--glass-border);
  transition: box-shadow var(--duration-normal) var(--ease-out);
}

.site-header.scrolled {
  box-shadow: var(--shadow-md);
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: var(--weight-bold);
  color: var(--color-text);
  text-decoration: none;
  letter-spacing: var(--tracking-tight);
  transition: opacity var(--duration-fast) var(--ease-out);
  flex-shrink: 0;
}

.site-logo:hover {
  color: var(--color-text);
  opacity: 0.8;
}

.site-logo-icon {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

/* Nav toggle (mobile) */
.nav-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  transition: color var(--duration-fast) var(--ease-out),
              background var(--duration-fast) var(--ease-out);
}

.nav-toggle:hover {
  color: var(--color-text);
  background: var(--color-accent-muted);
}

.nav-toggle-icon {
  width: 1.125rem;
  height: 1.125rem;
}

/* Nav menu */
.nav-menu {
  position: fixed;
  inset: calc(var(--header-height) + 3px) 0 0 0;
  background: var(--color-bg);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  padding: var(--space-lg) var(--space-md);
  gap: 2px;
  transform: translateX(100%);
  transition: transform var(--duration-slow) var(--ease-out);
  z-index: var(--z-overlay);
}

.nav-menu.open {
  transform: translateX(0);
}

.nav-link {
  display: block;
  padding: 0.625rem var(--space-md);
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  min-height: 2.75rem;
  display: flex;
  align-items: center;
  transition: color var(--duration-fast) var(--ease-out),
              background var(--duration-fast) var(--ease-out);
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-text);
  background: var(--color-accent-muted);
}

/* Desktop nav */
@media (min-width: 768px) {
  .nav-toggle {
    display: none;
  }

  .nav-menu {
    position: static;
    inset: auto;
    background: none;
    transform: none;
    flex-direction: row;
    padding: 0;
    gap: 2px;
    align-items: center;
  }

  .nav-link {
    font-size: var(--text-2xs);
    padding: var(--space-xs) 0.625rem;
    min-height: auto;
  }
}

/* Auth nav items */
.nav-auth {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.nav-auth[hidden] {
  display: none;
}

.nav-user-name {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--color-success);
  padding: var(--space-xs) var(--space-sm);
}

.nav-separator {
  width: 1px;
  height: 1rem;
  background: var(--color-border);
  margin: 0 var(--space-xs);
}

@media (max-width: 767px) {
  .nav-separator {
    display: none;
  }

  .nav-auth {
    flex-direction: column;
    width: 100%;
    padding-top: var(--space-md);
    border-top: 1px solid var(--color-border);
    margin-top: var(--space-md);
  }
}


/* ═══════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  font-family: var(--font-ui);
  font-weight: var(--weight-semibold);
  font-size: var(--text-sm);
  line-height: 1;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius-md);
  text-decoration: none;
  cursor: pointer;
  transition: all var(--duration-normal) var(--ease-out);
  white-space: nowrap;
  border: 1px solid transparent;
}

.btn:focus-visible {
  outline: 2px solid var(--color-border-focus);
  outline-offset: 2px;
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-white-pure);
  border-color: var(--color-accent);
}

.btn-primary:hover {
  background: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
  color: var(--color-white-pure);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0) scale(0.98);
  box-shadow: none;
}

.btn-secondary {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-border-hover);
}

.btn-secondary:hover {
  color: var(--color-text);
  border-color: var(--color-accent);
  background: var(--color-accent-muted);
}

.btn-ghost {
  background: transparent;
  color: var(--color-text-secondary);
  border-color: transparent;
  padding: 0.5rem 0.75rem;
}

.btn-ghost:hover {
  color: var(--color-text);
  background: var(--color-accent-muted);
}

.btn-sm {
  font-size: var(--text-xs);
  padding: 0.375rem 0.75rem;
  border-radius: var(--radius-sm);
}

.btn-lg {
  font-size: var(--text-base);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-lg);
}


/* ═══════════════════════════════════════════════════
   HERO — Broadcast banner style
   ═══════════════════════════════════════════════════ */

.hero {
  padding-top: var(--space-2xl);
  padding-bottom: var(--space-xl);
  position: relative;
  border-bottom: 1px solid var(--color-rule);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -40%;
  left: -20%;
  width: 60%;
  height: 140%;
  background: var(--gradient-glow);
  animation: heroGlow 6s ease-in-out infinite alternate;
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  right: -10%;
  width: 50%;
  height: 120%;
  background: radial-gradient(ellipse, rgba(var(--color-accent-rgb), 0.05) 0%, transparent 70%);
  animation: heroGlow 8s ease-in-out infinite alternate-reverse;
  pointer-events: none;
}

@keyframes heroGlow {
  0%   { opacity: 0.4; transform: translate(0, 0) scale(1); }
  100% { opacity: 1; transform: translate(5%, -3%) scale(1.1); }
}

.hero-content {
  max-width: 700px;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.hero-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-live);
  background: var(--color-live-muted);
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.hero-live-dot {
  width: 6px;
  height: 6px;
  border-radius: var(--radius-full);
  background: var(--color-live);
  animation: livePulse 2s ease-in-out infinite;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.hero-timestamp {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
}

.hero-title {
  font-size: var(--text-3xl);
  font-weight: var(--weight-black);
  line-height: var(--leading-none);
  letter-spacing: var(--tracking-tight);
  margin-bottom: var(--space-md);
  text-transform: uppercase;
}

.hero-accent {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
  max-width: 52ch;
  margin-bottom: var(--space-lg);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

@media (min-width: 768px) {
  .hero {
    padding-top: var(--space-3xl);
    padding-bottom: var(--space-xl);
  }

  .hero-title {
    font-size: var(--text-4xl);
  }

  .hero-subtitle {
    font-size: var(--text-lg);
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: var(--text-5xl);
  }
}


/* ── Featured Story Skeleton ──────────────────────── */

.featured-skeleton {
  display: grid;
  grid-template-columns: 1fr;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 200px;
}

.featured-skeleton-image {
  aspect-ratio: 16 / 9;
  background: var(--color-bg-surface);
  position: relative;
  overflow: hidden;
}

.featured-skeleton-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, var(--color-accent-subtle) 50%, transparent 100%);
  background-size: 200% 100%;
  animation: shimmer 2s ease-in-out infinite;
}

.featured-skeleton-body {
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.featured-skeleton-badge {
  width: 72px;
  height: 20px;
  border-radius: var(--radius-xs);
  background: var(--color-bg-surface);
}

.featured-skeleton-title {
  height: 20px;
  border-radius: var(--radius-xs);
  background: var(--color-bg-surface);
  width: 90%;
}

.featured-skeleton-title.short { width: 60%; }

.featured-skeleton-text {
  height: 14px;
  border-radius: var(--radius-xs);
  background: var(--color-bg-surface);
  width: 100%;
  opacity: 0.6;
}

.featured-skeleton-text.short { width: 45%; }

.feed-loaded .featured-skeleton { display: none; }

@media (min-width: 768px) {
  .featured-skeleton {
    grid-template-columns: 1fr 1fr;
  }
  .featured-skeleton-image { aspect-ratio: auto; min-height: 280px; }
  .featured-skeleton-body { padding: var(--space-xl); justify-content: center; }
}


/* ═══════════════════════════════════════════════════
   HEADLINE TICKER
   ═══════════════════════════════════════════════════ */

.ticker-bar {
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-secondary);
  overflow: hidden;
  position: relative;
  height: 36px;
}

.ticker-bar::before,
.ticker-bar::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: 48px;
  z-index: 2;
  pointer-events: none;
}

.ticker-bar::before {
  left: 0;
  background: linear-gradient(90deg, var(--color-bg-secondary), transparent);
}

.ticker-bar::after {
  right: 0;
  background: linear-gradient(270deg, var(--color-bg-secondary), transparent);
}

.ticker-bar[hidden] { display: none; }

.ticker-track {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
  white-space: nowrap;
  height: 100%;
  animation: tickerScroll 40s linear infinite;
  width: max-content;
}

.ticker-track:hover {
  animation-play-state: paused;
}

@keyframes tickerScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-secondary);
  letter-spacing: var(--tracking-wide);
  text-decoration: none;
  transition: color var(--duration-fast);
  flex-shrink: 0;
}

.ticker-item:hover {
  color: var(--color-text);
}

.ticker-category {
  color: var(--color-accent);
  text-transform: uppercase;
  font-weight: var(--weight-semibold);
}

.ticker-separator {
  color: var(--color-text-muted);
  opacity: 0.3;
}


/* ═══════════════════════════════════════════════════
   TRUST STRIP (Credibility metrics)
   ═══════════════════════════════════════════════════ */

.trust-strip {
  padding: var(--space-xl) 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-secondary);
}

.trust-strip-grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-lg);
  flex-wrap: wrap;
}

.trust-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  min-width: 100px;
  text-align: center;
}

.trust-stat-number {
  font-family: var(--font-heading);
  font-size: var(--text-2xl);
  font-weight: var(--weight-black);
  color: var(--color-text);
  letter-spacing: var(--tracking-tight);
  line-height: 1;
}

.trust-stat-label {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.trust-stat-divider {
  width: 1px;
  height: 32px;
  background: var(--color-border);
}

@media (max-width: 639px) {
  .trust-strip-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-lg);
  }

  .trust-stat-divider {
    display: none;
  }
}

@media (min-width: 768px) {
  .trust-stat-number {
    font-size: var(--text-3xl);
  }
}


/* ═══════════════════════════════════════════════════
   CARDS (About section — legacy)
   ═══════════════════════════════════════════════════ */

.card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  transition: border-color var(--duration-normal) var(--ease-out);
}

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

.card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-sm);
  background: var(--color-accent-muted);
  color: var(--color-accent);
  margin-bottom: var(--space-md);
}

.card-icon svg {
  width: 14px;
  height: 14px;
}

.card-title {
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: var(--weight-semibold);
  margin-bottom: var(--space-xs);
}

.card-text {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-snug);
}


/* ═══════════════════════════════════════════════════
   VALUE CARDS (Enhanced About section)
   ═══════════════════════════════════════════════════ */

.value-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-top: 3px solid var(--color-accent);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  transition: border-color var(--duration-normal) var(--ease-out),
              box-shadow var(--duration-normal) var(--ease-out),
              transform var(--duration-normal) var(--ease-out);
}

.value-card:hover {
  border-color: var(--color-border-hover);
  border-top-color: var(--color-accent-hover);
  box-shadow: var(--shadow-md), 0 -2px 16px -8px rgba(var(--color-accent-rgb), 0.15);
  transform: translateY(-2px);
}

.value-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: var(--color-accent-muted);
  color: var(--color-accent);
  margin-bottom: var(--space-md);
}

.value-card-title {
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
  margin-bottom: var(--space-xs);
}

.value-card-text {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
}


/* ═══════════════════════════════════════════════════
   NEWSLETTER FORM
   ═══════════════════════════════════════════════════ */

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  max-width: 440px;
  margin-left: auto;
  margin-right: auto;
}

.newsletter-input {
  width: 100%;
  padding: 0.75rem var(--space-md);
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  color: var(--color-text);
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: border-color var(--duration-normal) var(--ease-out),
              box-shadow var(--duration-normal) var(--ease-out);
}

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

.newsletter-input:focus {
  outline: none;
  border-color: var(--color-border-focus);
  box-shadow: 0 0 0 3px var(--color-accent-muted);
}

@media (min-width: 640px) {
  .newsletter-form {
    flex-direction: row;
  }

  .newsletter-input {
    flex: 1;
  }
}

.newsletter-hint {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  margin-top: var(--space-xs);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  transition: color var(--duration-normal) var(--ease-out);
}

.newsletter-hint.is-success {
  color: var(--color-success);
}

.newsletter-hint.is-error {
  color: var(--color-error);
}


/* ═══════════════════════════════════════════════════
   FILTER CHIPS
   ═══════════════════════════════════════════════════ */

.filter-chips {
  display: flex;
  gap: var(--space-xs);
  margin-bottom: var(--space-lg);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: var(--space-xs);
}

.filter-chips::-webkit-scrollbar { display: none; }

.filter-chips:empty { display: none; }

.filter-chip {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--color-text-muted);
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  padding: 6px 14px;
  white-space: nowrap;
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out);
  flex-shrink: 0;
}

.filter-chip:hover {
  color: var(--color-text-secondary);
  border-color: var(--color-border-hover);
}

.filter-chip.is-active {
  color: var(--color-accent);
  border-color: var(--color-accent);
  background: var(--color-accent-muted);
}

.filter-chip:focus-visible {
  outline: 2px solid var(--color-border-focus);
  outline-offset: 2px;
}


/* ═══════════════════════════════════════════════════
   FEED — Grid, Cards, Loading, Empty, Error
   ═══════════════════════════════════════════════════ */

.feed-placeholder,
.feed-grid {
  display: grid;
  gap: var(--space-md);
}

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

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

/* Loading skeleton */
.feed-skeleton {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.skeleton-image {
  aspect-ratio: 16 / 9;
  background: var(--color-bg-surface);
  position: relative;
  overflow: hidden;
}

.skeleton-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, var(--color-accent-subtle) 50%, transparent 100%);
  background-size: 200% 100%;
  animation: shimmer 2s ease-in-out infinite;
}

.skeleton-body {
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.skeleton-line {
  height: 12px;
  border-radius: var(--radius-xs);
  background: var(--color-bg-surface);
}

.skeleton-line.w90 { width: 90%; }
.skeleton-line.w60 { width: 60%; }
.skeleton-line.w40 { width: 40%; }

@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

@media (max-width: 639px) {
  .feed-skeleton:nth-child(n+4) {
    display: none;
  }
}

/* Entrance animation */
.feed-loaded .post-card {
  animation: feedFadeIn var(--duration-slow) var(--ease-out) both;
}

.feed-loaded .post-card:nth-child(2)  { animation-delay: 30ms; }
.feed-loaded .post-card:nth-child(3)  { animation-delay: 60ms; }
.feed-loaded .post-card:nth-child(4)  { animation-delay: 80ms; }
.feed-loaded .post-card:nth-child(5)  { animation-delay: 100ms; }
.feed-loaded .post-card:nth-child(6)  { animation-delay: 120ms; }
.feed-loaded .post-card:nth-child(7)  { animation-delay: 140ms; }
.feed-loaded .post-card:nth-child(8)  { animation-delay: 155ms; }
.feed-loaded .post-card:nth-child(9)  { animation-delay: 170ms; }
.feed-loaded .post-card:nth-child(n+10) { animation-delay: 185ms; }

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

/* Post card */
.post-card {
  display: flex;
  flex-direction: column;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: border-color var(--duration-normal) var(--ease-out),
              box-shadow var(--duration-normal) var(--ease-out),
              transform var(--duration-normal) var(--ease-out);
}

.post-card:hover {
  border-color: var(--color-border-hover);
  box-shadow: var(--shadow-lg), 0 0 24px -8px rgba(var(--color-accent-rgb), 0.08);
  color: inherit;
  transform: translateY(-2px);
}

.post-card:active {
  transform: translateY(0);
  box-shadow: var(--shadow-sm);
}

.post-card:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.post-card-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--color-bg-surface);
  border-bottom: 1px solid var(--color-border);
}

.post-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--duration-slow) var(--ease-out);
}

.post-card:hover .post-card-image img {
  transform: scale(1.04);
}

.post-card-body {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  padding: var(--space-md);
  flex: 1;
}

.post-card-body .badge {
  align-self: flex-start;
}

.post-card-title {
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
  color: var(--color-text);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 0;
}

@media (min-width: 768px) {
  .post-card-title {
    font-size: var(--text-lg);
  }
}

.post-card-excerpt {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-snug);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 0;
}

.post-card-meta {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-top: auto;
  padding-top: var(--space-xs);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
}

.post-card-source {
  font-weight: var(--weight-medium);
  color: var(--color-text-secondary);
}

.post-card-date {
  color: var(--color-text-muted);
}

.post-card-meta .post-card-source + .post-card-date::before {
  content: '/';
  margin-right: var(--space-sm);
  color: var(--color-text-muted);
  opacity: 0.5;
}

/* Feed states */
.feed-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--space-2xl) var(--space-md);
}

.feed-state-title {
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
  color: var(--color-text);
  margin-bottom: var(--space-xs);
}

.feed-state-text {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  max-width: 36ch;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: var(--space-md);
}

.feed-retry-btn {
  margin: 0 auto;
}


/* ═══════════════════════════════════════════════════
   BADGE
   ═══════════════════════════════════════════════════ */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  border-radius: var(--radius-xs);
  border: 1px solid;
}

.badge-accent {
  background: var(--color-accent-muted);
  color: var(--color-accent);
  border-color: var(--color-accent-border);
}

.badge-success {
  background: var(--color-success-muted);
  color: var(--color-success);
  border-color: var(--color-success-border);
}

.badge-warning {
  background: var(--color-warning-muted);
  color: var(--color-warning);
  border-color: var(--color-warning-border);
}

.badge-live {
  background: var(--color-live-muted);
  color: var(--color-live);
  border-color: rgba(239, 68, 68, 0.2);
}


/* ═══════════════════════════════════════════════════
   SITE FOOTER
   ═══════════════════════════════════════════════════ */

.site-footer {
  border-top: none;
  padding-top: var(--space-2xl);
  padding-bottom: var(--space-xl);
  background: var(--color-bg);
  position: relative;
}

.site-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--color-accent), transparent);
  opacity: 0.3;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.footer-brand {
  max-width: 280px;
}

.footer-brand-name {
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: var(--weight-bold);
  color: var(--color-text);
  margin-bottom: var(--space-xs);
}

.footer-brand-tagline {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-snug);
}

.footer-nav-title {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: var(--space-sm);
}

.footer-nav-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.footer-nav-link {
  font-family: var(--font-ui);
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  transition: color var(--duration-fast) var(--ease-out);
}

.footer-nav-link:hover {
  color: var(--color-text);
}

.footer-bottom {
  padding-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer-copyright {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
}

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

  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}


/* ═══════════════════════════════════════════════════
   EMAIL PREVIEW (Newsletter sample)
   ═══════════════════════════════════════════════════ */

.email-preview {
  margin-top: var(--space-2xl);
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
  perspective: 1200px;
}

.email-preview-label {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: var(--space-sm);
  text-align: left;
}

.email-preview-window {
  border: 1px solid var(--color-border-hover);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--color-bg-elevated);
  box-shadow:
    var(--shadow-xl),
    0 0 60px -20px rgba(59, 139, 242, 0.12);
  transform: rotateX(2deg) rotateY(-1deg);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
}

.email-preview-window:hover {
  transform: rotateX(0) rotateY(0);
  box-shadow:
    var(--shadow-xl),
    0 0 80px -20px rgba(59, 139, 242, 0.18);
}

/* Chrome bar */
.email-preview-chrome {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: 8px 12px;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
}

.email-preview-dots {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.email-preview-dots .dot-red {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  background: #EF4444;
}

.email-preview-dots .dot-yellow {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  background: #EAB308;
}

.email-preview-dots .dot-green {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  background: #22C55E;
}

.email-preview-chrome-tabs {
  display: flex;
  gap: 2px;
}

.email-preview-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
}

.email-preview-tab.is-active {
  color: var(--color-text);
  background: var(--color-bg-card);
}

.email-preview-unread {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  font-size: 9px;
  font-weight: var(--weight-bold);
  color: var(--color-white-pure);
  background: var(--color-accent);
  border-radius: var(--radius-full);
  letter-spacing: 0;
  text-transform: none;
}

/* Meta rows (From, Subject, Date) */
.email-preview-meta {
  padding: 10px 16px;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-card);
}

.email-preview-meta-row {
  display: flex;
  gap: var(--space-sm);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-secondary);
  line-height: 1.7;
  letter-spacing: var(--tracking-wide);
}

.email-preview-meta-label {
  color: var(--color-text-muted);
  min-width: 3.5rem;
  text-transform: uppercase;
  flex-shrink: 0;
}

.email-preview-subject {
  color: var(--color-text);
  font-weight: var(--weight-semibold);
}

/* Email body */
.email-preview-body {
  padding: 20px 16px;
  text-align: left;
}

.email-preview-header {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
}

.email-preview-logo {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-sm);
}

.email-preview-brand {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  color: var(--color-text);
  line-height: 1.2;
  margin-bottom: 0;
}

.email-preview-tagline {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-accent);
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  margin-bottom: 0;
}

.email-preview-rule {
  height: 1px;
  background: var(--color-accent);
  margin-bottom: var(--space-md);
  opacity: 0.3;
}

.email-preview-greeting {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text);
  margin-bottom: var(--space-sm);
}

.email-preview-text {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-md);
}

.email-preview-thresholds {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: var(--space-lg);
}

.email-threshold {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-bold);
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  border: 1px solid;
  letter-spacing: var(--tracking-wide);
}

.email-threshold-green {
  color: #22c55e;
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.1);
}

.email-threshold-yellow {
  color: #eab308;
  border-color: #eab308;
  background: rgba(234, 179, 8, 0.1);
}

.email-threshold-blue {
  color: var(--color-accent);
  border-color: var(--color-accent);
  background: var(--color-accent-muted);
}

.email-threshold-red {
  color: var(--color-live);
  border-color: var(--color-live);
  background: var(--color-live-muted);
}

/* Alert card inside email preview */
.email-preview-alert {
  border: 1px solid var(--color-border-hover);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-bg-card);
  margin-bottom: var(--space-lg);
}

.email-alert-header {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 10px 12px;
  border-bottom: 1px solid var(--color-border);
}

.email-alert-badge {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--weight-bold);
  color: #22c55e;
  background: rgba(34, 197, 94, 0.12);
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  border: 1px solid rgba(34, 197, 94, 0.2);
  letter-spacing: var(--tracking-wide);
  flex-shrink: 0;
}

.email-alert-title {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--color-text);
  margin-bottom: 0;
  line-height: 1.3;
}

.email-alert-location {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  margin-bottom: 0;
  letter-spacing: var(--tracking-wide);
}

.email-alert-map {
  padding: 8px;
}

.email-alert-map img {
  width: 100%;
  border-radius: var(--radius-sm);
  display: block;
}

.email-preview-sign {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
}

.email-preview-sign span {
  font-weight: var(--weight-normal);
  color: var(--color-text-muted);
  font-size: var(--text-xs);
}


/* ═══════════════════════════════════════════════════
   FEATURED STORY (hero card)
   ═══════════════════════════════════════════════════ */

.featured-story-wrap {
  margin-top: var(--space-xl);
}

.featured-story {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: border-color var(--duration-normal) var(--ease-out),
              box-shadow var(--duration-normal) var(--ease-out);
}

.featured-story:hover {
  border-color: var(--color-accent);
  box-shadow: var(--shadow-lg);
}

.featured-story-image {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--color-bg-secondary);
}

.featured-story-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.featured-story-content {
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.featured-story-badges {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.featured-story-date {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
}

.featured-story-title {
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  font-weight: var(--weight-bold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--color-text);
  margin: 0;
}

.featured-story-excerpt {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.featured-story-cta {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  margin-top: var(--space-xs);
  transition: color var(--duration-fast);
}

.featured-story:hover .featured-story-cta {
  color: var(--color-accent-hover);
}

@media (min-width: 768px) {
  .featured-story {
    grid-template-columns: 1fr 1fr;
  }

  .featured-story-image {
    aspect-ratio: auto;
    min-height: 280px;
  }

  .featured-story-content {
    padding: var(--space-xl);
    justify-content: center;
  }

  .featured-story-title {
    font-size: var(--text-2xl);
  }
}

@media (min-width: 1024px) {
  .featured-story-title {
    font-size: var(--text-3xl);
  }

  .featured-story-content {
    padding: var(--space-2xl);
  }
}


/* ═══════════════════════════════════════════════════
   ALERT CARD VARIANT
   ═══════════════════════════════════════════════════ */

.post-card--alert {
  border-left: 3px solid var(--color-warning);
}

.post-card--alert .badge-warning {
  background: rgba(var(--color-warning-rgb, 234 179 8), 0.15);
}

.post-card--alert .badge-accent {
  background: rgba(var(--color-accent-rgb, 96 165 250), 0.15);
}


/* ── Large Card Variant (spans 2 cols on desktop) ── */

@media (min-width: 640px) {
  .post-card--large {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    flex-direction: row;
  }

  .post-card--large .post-card-image {
    aspect-ratio: auto;
    min-height: 200px;
    border-bottom: none;
    border-right: 1px solid var(--color-border);
  }

  .post-card--large .post-card-body {
    justify-content: center;
    padding: var(--space-lg);
  }

  .post-card--large .post-card-title {
    font-size: var(--text-xl);
    -webkit-line-clamp: 4;
  }
}

@media (min-width: 1024px) {
  .post-card--large {
    grid-column: 1 / span 2;
  }
}


/* ═══════════════════════════════════════════════════
   ENGAGEMENT STATS
   ═══════════════════════════════════════════════════ */

.post-stats {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-top: var(--space-xs);
}

.post-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  letter-spacing: var(--tracking-wide);
}

.post-stat svg {
  opacity: 0.5;
  flex-shrink: 0;
}


/* ═══════════════════════════════════════════════════
   CONTENT VISIBILITY (below-fold performance)
   ═══════════════════════════════════════════════════ */

#about,
#experiences,
#monitor-teaser,
#subscribe {
  content-visibility: auto;
  contain-intrinsic-size: auto 500px;
}


/* ═══════════════════════════════════════════════════
   EXPERIENCE CARDS (Games & Tools)
   ═══════════════════════════════════════════════════ */

.experience-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  padding: var(--space-lg);
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: inherit;
  transition: border-color var(--duration-normal) var(--ease-out),
              box-shadow var(--duration-normal) var(--ease-out),
              transform var(--duration-normal) var(--ease-out);
}

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

.experience-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(var(--color-accent-rgb, 96 165 250), 0.1);
  border-radius: var(--radius-md);
  color: var(--color-accent);
  flex-shrink: 0;
}

.experience-title {
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  color: var(--color-text);
  margin: 0;
}

.experience-text {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
  margin: 0;
  flex: 1;
}

.experience-cta {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  margin-top: var(--space-xs);
  transition: color var(--duration-fast);
}

.experience-card:hover .experience-cta {
  color: var(--color-accent-hover);
}


/* ═══════════════════════════════════════════════════
   MONITOR TEASER
   ═══════════════════════════════════════════════════ */

.monitor-teaser {
  position: relative;
  padding: var(--space-3xl) 0;
  background:
    linear-gradient(135deg, hsl(220 30% 6%) 0%, hsl(220 25% 10%) 50%, hsl(220 30% 6%) 100%);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  overflow: hidden;
}

.monitor-teaser::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      0deg,
      transparent 0,
      transparent 2px,
      rgba(255, 255, 255, 0.015) 2px,
      rgba(255, 255, 255, 0.015) 4px
    );
  pointer-events: none;
}

.radar-pulse {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 300px;
  height: 300px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 1px solid rgba(var(--color-accent-rgb), 0.08);
  animation: radarExpand 4s ease-out infinite;
  pointer-events: none;
}

.radar-pulse::before,
.radar-pulse::after {
  content: '';
  position: absolute;
  inset: -40px;
  border-radius: 50%;
  border: 1px solid rgba(var(--color-accent-rgb), 0.05);
  animation: radarExpand 4s ease-out infinite;
}

.radar-pulse::before { animation-delay: 1.3s; }
.radar-pulse::after { animation-delay: 2.6s; }

@keyframes radarExpand {
  0% {
    transform: translate(-50%, -50%) scale(0.3);
    opacity: 0.6;
  }
  100% {
    transform: translate(-50%, -50%) scale(2);
    opacity: 0;
  }
}

.monitor-teaser-content {
  text-align: center;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
}

.monitor-teaser-badge {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.monitor-teaser-count {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
}

.monitor-teaser-title {
  font-family: var(--font-heading);
  font-size: var(--text-3xl);
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-tight);
  color: var(--color-text);
  margin: 0;
}

.monitor-teaser-subtitle {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
  max-width: 48ch;
  margin: 0;
}

@media (min-width: 768px) {
  .monitor-teaser {
    padding: var(--space-4xl, 6rem) 0;
  }

  .monitor-teaser-title {
    font-size: clamp(var(--text-3xl), 4vw, 3.5rem);
  }
}


/* ═══════════════════════════════════════════════════
   AUDIO TOGGLE (header)
   ═══════════════════════════════════════════════════ */

.audio-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: color var(--duration-fast), border-color var(--duration-fast),
              background var(--duration-fast);
  flex-shrink: 0;
}

.audio-toggle:hover {
  color: var(--color-text);
  border-color: var(--color-text-muted);
  background: var(--glass-bg);
}

.audio-toggle .audio-icon-on {
  display: none;
}

.audio-toggle.is-playing .audio-icon-off {
  display: none;
}

.audio-toggle.is-playing .audio-icon-on {
  display: block;
}

.audio-toggle.is-playing {
  color: var(--color-accent);
  border-color: rgba(var(--color-accent-rgb), 0.35);
}


/* ═══════════════════════════════════════════════════
   AUDIO VISUALIZER (fixed CRT waveform)
   ═══════════════════════════════════════════════════ */

.audio-visualizer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 48px;
  z-index: 50;
  pointer-events: none;
  opacity: 0.7;
}

.audio-visualizer::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    transparent 0,
    transparent 2px,
    rgba(0, 0, 0, 0.12) 2px,
    rgba(0, 0, 0, 0.12) 4px
  );
}

@media (prefers-reduced-motion: reduce) {
  .audio-visualizer {
    display: none;
  }
}


/* ═══════════════════════════════════════════════════
   SCROLL-TO-TOP BUTTON
   ═══════════════════════════════════════════════════ */

.scroll-top {
  position: fixed;
  bottom: var(--space-lg);
  right: var(--space-lg);
  z-index: var(--z-elevated);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--color-border-hover);
  border-radius: var(--radius-full);
  color: var(--color-text-secondary);
  cursor: pointer;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity var(--duration-normal) var(--ease-out),
              transform var(--duration-normal) var(--ease-out),
              color var(--duration-fast) var(--ease-out),
              border-color var(--duration-fast) var(--ease-out);
  box-shadow: var(--shadow-md);
}

.scroll-top[hidden] { display: none; }

.scroll-top.visible {
  opacity: 1;
  transform: translateY(0);
}

.scroll-top:hover {
  color: var(--color-text);
  border-color: var(--color-accent);
}

.scroll-top:active {
  transform: scale(0.92);
}

.scroll-top:focus-visible {
  outline: 2px solid var(--color-border-focus);
  outline-offset: 2px;
}


/* ═══════════════════════════════════════════════════
   MOBILE ENHANCEMENTS
   ═══════════════════════════════════════════════════ */

@media (max-width: 767px) {
  /* Hero: fluid title sizing */
  .hero-title {
    font-size: clamp(1.75rem, 6vw, var(--text-3xl));
  }

  .hero-subtitle {
    font-size: var(--text-sm);
  }

  .hero-actions {
    flex-direction: column;
  }

  .hero-actions .btn {
    width: 100%;
    justify-content: center;
  }

  /* Mobile nav: backdrop blur + smoother animation */
  .nav-menu {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
  }

  /* Mobile touch targets: minimum 44px */
  .nav-link {
    min-height: 44px;
    padding: var(--space-sm) var(--space-md);
  }

  .btn-sm {
    min-height: 36px;
  }

  /* Horizontal card layout for compact mobile feed */
  .post-card--alert {
    display: grid;
    grid-template-columns: 80px 1fr;
    border-left: 3px solid var(--color-warning);
  }

  .post-card--alert .post-card-image {
    aspect-ratio: 1;
    border-bottom: none;
    border-right: 1px solid var(--color-border);
  }

  .post-card--alert .post-card-body {
    padding: var(--space-sm);
  }

  .post-card--alert .post-card-title {
    font-size: var(--text-sm);
    -webkit-line-clamp: 2;
  }

  /* Full-width newsletter on mobile */
  .newsletter-form {
    max-width: 100%;
  }

  .newsletter-input {
    font-size: var(--text-base);
    padding: var(--space-md);
    min-height: 48px;
  }

  .newsletter-form .btn {
    min-height: 48px;
  }

  /* Ticker: smaller text on mobile */
  .ticker-bar {
    height: 32px;
  }

  .ticker-item {
    font-size: 10px;
  }

  /* Scroll-to-top: position above audio visualizer */
  .scroll-top {
    bottom: 68px;
  }

  /* Trust strip: tighter on mobile */
  .trust-stat-number {
    font-size: var(--text-xl);
  }
}
