/* ========================================
   FEED — Cinematic Streaming Platform
   Design System v2.0
   ======================================== */

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

/* --- Keyframe Animations --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes glowPulse {
  0%, 100% {
    text-shadow: 0 0 20px rgba(255, 45, 45, 0.6),
                 0 0 60px rgba(255, 45, 45, 0.3),
                 0 0 100px rgba(255, 45, 45, 0.15);
  }
  50% {
    text-shadow: 0 0 30px rgba(255, 45, 45, 0.8),
                 0 0 80px rgba(255, 45, 45, 0.45),
                 0 0 120px rgba(255, 45, 45, 0.2);
  }
}

@keyframes activeIndicatorPulse {
  0%, 100% {
    box-shadow: 0 0 6px var(--red-glow);
  }
  50% {
    box-shadow: 0 0 14px var(--red-glow), 0 0 24px var(--red-glow-subtle);
  }
}

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

@keyframes subtlePulse {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* --- Stagger animation helpers --- */
.stagger-1 { animation-delay: 0.05s; }
.stagger-2 { animation-delay: 0.12s; }
.stagger-3 { animation-delay: 0.2s; }
.stagger-4 { animation-delay: 0.28s; }
.stagger-5 { animation-delay: 0.36s; }
.stagger-6 { animation-delay: 0.44s; }

.animate-in {
  animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* --- Theme Tokens --- */
:root {
  --font-heading: 'Anton', sans-serif;
  --font-body: 'Inter', sans-serif;

  --transition-speed: 0.35s;
  --transition-ease: cubic-bezier(0.4, 0, 0.2, 1);

  --sidebar-width: 230px;

  --red: #ff2d2d;
  --red-dark: #cc2222;
  --red-glow: rgba(255, 45, 45, 0.5);
  --red-glow-subtle: rgba(255, 45, 45, 0.15);
}

/* ========================================
   Dark Mode (default)
   ======================================== */
[data-theme="dark"] {
  --bg: #000000;
  --bg-raised: #0a0a0a;
  --bg-card: #111111;
  --bg-card-hover: #1a1a1a;
  --text-primary: #ffffff;
  --text-secondary: #888888;
  --text-tertiary: #555555;
  --logo-color: var(--red);
  --glow-color: rgba(255, 45, 45, 0.85);
  --glow-spread: 0 0 20px rgba(255, 45, 45, 0.6),
                 0 0 60px rgba(255, 45, 45, 0.3),
                 0 0 100px rgba(255, 45, 45, 0.15);
  --toggle-bg: #1a1a1a;
  --toggle-border: #333333;
  --toggle-hover: #2a2a2a;

  /* Sidebar */
  --sidebar-bg: rgba(8, 8, 8, 0.85);
  --sidebar-border: rgba(255, 255, 255, 0.06);
  --sidebar-shadow: 0 8px 40px rgba(0, 0, 0, 0.6);
  --sidebar-item-color: #999999;
  --sidebar-item-hover: #ffffff;
  --sidebar-item-active-color: var(--red);
  --sidebar-item-active-bg: rgba(255, 45, 45, 0.08);

  /* Cards */
  --card-thumb-bg: #141414;
  --card-border: rgba(255, 255, 255, 0.04);
  --card-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
  --card-hover-shadow: 0 12px 44px rgba(255, 45, 45, 0.2), 0 10px 36px rgba(0, 0, 0, 0.55);
  --card-hover-border: rgba(255, 45, 45, 0.25);

  /* Dividers */
  --divider: rgba(255, 255, 255, 0.06);

  /* Hero */
  --hero-gradient: linear-gradient(to top, #000000 0%, rgba(0,0,0,0.88) 25%, rgba(0,0,0,0.5) 55%, rgba(0,0,0,0.2) 80%, transparent 100%);
  --hero-gradient-side: linear-gradient(to right, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 25%, transparent 55%);
}

/* ========================================
   Light Mode
   ======================================== */
[data-theme="light"] {
  --bg: #f5f5f5;
  --bg-raised: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #fafafa;
  --text-primary: #0a0a0a;
  --text-secondary: #666666;
  --text-tertiary: #999999;
  --logo-color: #d42020;
  --glow-color: rgba(212, 32, 32, 0.5);
  --glow-spread: 0 0 10px rgba(212, 32, 32, 0.2),
                 0 0 30px rgba(212, 32, 32, 0.08);
  --toggle-bg: #f0f0f0;
  --toggle-border: #e0e0e0;
  --toggle-hover: #e8e8e8;

  /* Sidebar */
  --sidebar-bg: rgba(255, 255, 255, 0.88);
  --sidebar-border: rgba(0, 0, 0, 0.06);
  --sidebar-shadow: 0 8px 40px rgba(0, 0, 0, 0.08);
  --sidebar-item-color: #666666;
  --sidebar-item-hover: #0a0a0a;
  --sidebar-item-active-color: #d42020;
  --sidebar-item-active-bg: rgba(212, 32, 32, 0.06);

  /* Cards */
  --card-thumb-bg: #eeeeee;
  --card-border: rgba(0, 0, 0, 0.06);
  --card-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  --card-hover-shadow: 0 12px 36px rgba(212, 32, 32, 0.12), 0 6px 24px rgba(0, 0, 0, 0.1);
  --card-hover-border: rgba(212, 32, 32, 0.25);

  /* Dividers */
  --divider: rgba(0, 0, 0, 0.08);

  /* Hero */
  --hero-gradient: linear-gradient(to top, #f5f5f5 0%, rgba(245,245,245,0.88) 25%, rgba(245,245,245,0.5) 55%, rgba(245,245,245,0.2) 80%, transparent 100%);
  --hero-gradient-side: linear-gradient(to right, rgba(245,245,245,0.85) 0%, rgba(245,245,245,0.5) 25%, transparent 55%);
}

/* --- Base --- */
html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg);
  color: var(--text-primary);
  min-height: 100vh;
  transition: background-color var(--transition-speed) var(--transition-ease),
              color var(--transition-speed) var(--transition-ease);
  overflow-x: hidden;
}

/* --- 🌌 Background Depth (Anti-Flat) --- */
[data-theme="dark"] body {
  background: radial-gradient(ellipse at 50% 0%, #111111 0%, #080808 35%, #000000 65%);
}

[data-theme="light"] body {
  background: radial-gradient(ellipse at 50% 0%, #fafafa 0%, #f5f5f5 50%);
}

/* ========================================
   Sidebar
   ======================================== */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--sidebar-width);
  z-index: 100;

  /* Glassmorphism */
  background: var(--sidebar-bg);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-right: 1px solid var(--sidebar-border);
  box-shadow: var(--sidebar-shadow);

  display: flex;
  flex-direction: column;
  padding: 0;

  transition: background var(--transition-speed) var(--transition-ease),
              border-color var(--transition-speed) var(--transition-ease),
              box-shadow var(--transition-speed) var(--transition-ease);
}

/* --- Sidebar Logo --- */
.sidebar-logo {
  padding: 2rem 1.5rem 2.5rem;
  border-bottom: 1px solid var(--divider);
}

.sidebar-logo-text {
  font-family: var(--font-heading);
  font-size: 2rem;
  letter-spacing: 0.06em;
  color: var(--logo-color);
  text-shadow: var(--glow-spread);
  line-height: 1;
  user-select: none;
  transition: color var(--transition-speed) var(--transition-ease),
              text-shadow var(--transition-speed) var(--transition-ease);
}

.sidebar-logo-tagline {
  font-family: var(--font-body);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-top: 0.35rem;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* --- Sidebar Nav --- */
.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 1.5rem 0.75rem;
  flex: 1;
}

.sidebar-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.8rem 1rem;
  border-radius: 12px;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--sidebar-item-color);
  text-decoration: none;
  transition: color 0.25s ease,
              background 0.25s ease,
              transform 0.2s ease;
  -webkit-tap-highlight-color: transparent;
  overflow: hidden;
}

.sidebar-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%) scaleY(0);
  width: 3px;
  height: 60%;
  border-radius: 0 3px 3px 0;
  background: var(--red);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 0 8px var(--red-glow);
}

.sidebar-item.active::before {
  animation: activeIndicatorPulse 2.5s ease-in-out infinite;
}

.sidebar-item:hover {
  color: var(--sidebar-item-hover);
  background: var(--sidebar-item-active-bg);
  transform: translateX(2px);
}

.sidebar-item.active {
  color: var(--sidebar-item-active-color);
  background: var(--sidebar-item-active-bg);
}

.sidebar-item.active::before {
  transform: translateY(-50%) scaleY(1);
}

.sidebar-item-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  opacity: 0.7;
  transition: opacity 0.25s ease;
}

.sidebar-item:hover .sidebar-item-icon,
.sidebar-item.active .sidebar-item-icon {
  opacity: 1;
}

/* --- Sidebar Footer (mobile theme toggle) --- */
.sidebar-footer {
  position: absolute;
  bottom: 1.5rem;
  left: 0;
  right: 0;
  padding: 0 0.75rem;
  display: none;
}

.sidebar-theme-toggle {
  width: 100%;
  justify-content: flex-start;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  font-size: 0.8rem;
}

.sidebar-toggle-label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--sidebar-item-color);
  transition: color 0.25s ease;
}

/* ========================================
   Sidebar Overlay (mobile)
   ======================================== */
.sidebar-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(0, 0, 0, 0);
  pointer-events: none;
  transition: background 0.35s var(--transition-ease);
}

.sidebar-overlay.visible {
  background: rgba(0, 0, 0, 0.65);
  pointer-events: auto;
}

/* ========================================
   Main Content
   ======================================== */
.main-wrapper {
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  transition: margin-left var(--transition-speed) var(--transition-ease);
}

/* --- Header --- */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.75rem clamp(1.5rem, 4vw, 4rem);
  width: 100%;
  position: relative;
}

.header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: clamp(1.5rem, 4vw, 4rem);
  right: clamp(1.5rem, 4vw, 4rem);
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--red), transparent);
  opacity: 0.4;
}

/* --- Hamburger Menu (mobile only) --- */
.menu-btn {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 12px;
  background: transparent;
  color: var(--text-primary);
  cursor: pointer;
  transition: color var(--transition-speed) var(--transition-ease),
              transform 0.15s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.menu-btn:active {
  transform: scale(0.9);
}

/* --- Logo / Heading --- */
.logo-link {
  text-decoration: none;
  color: inherit;
  outline: none;
  -webkit-tap-highlight-color: transparent;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.logo {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  font-weight: 400;
  letter-spacing: 0.06em;
  line-height: 1;
  color: var(--logo-color);
  text-shadow: var(--glow-spread);
  animation: glowPulse 4s ease-in-out infinite;
  transition: color var(--transition-speed) var(--transition-ease);
  user-select: none;
}

.logo-tagline {
  font-family: var(--font-body);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  transition: color var(--transition-speed) var(--transition-ease);
}

/* --- Theme Toggle (header — desktop) --- */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--divider);
  border-radius: 12px;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.25s ease,
              border-color 0.25s ease,
              transform 0.15s ease,
              background 0.25s ease,
              filter 0.25s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.theme-toggle:hover {
  color: var(--text-primary);
  border-color: var(--red);
  background: var(--sidebar-item-active-bg);
  transform: scale(1.08);
  filter: brightness(1.1);
}

.theme-toggle:active {
  transform: scale(0.97);
}

/* Icon visibility */
[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; }

/* ========================================
   Page Section Visibility
   ======================================== */
.page-section {
  display: none;
}

.page-section.active {
  display: block;
  animation: fadeIn 0.4s ease both;
}

/* ========================================
   Page Content
   ======================================== */
.page-content {
  padding: 0 clamp(1.5rem, 4vw, 4rem) 4rem;
}

/* ========================================
   HERO SECTION (Home + Featured)
   ======================================== */
.hero-section {
  position: relative;
  width: 100%;
  aspect-ratio: 21 / 9;
  max-height: 520px;
  min-height: 280px;
  overflow: hidden;
  cursor: pointer;
  margin-bottom: 2.5rem;
  border-radius: 0 0 0 0;
}

.hero-bg {
  position: absolute;
  inset: -8px;
  background-size: cover;
  background-position: center top;
  transform: scale(1.02);
  transition: transform 8s ease;
  filter: brightness(0.85);
}

.hero-section:hover .hero-bg {
  transform: scale(1.06);
}

/* 🎬 Hero depth blur layer */
.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  pointer-events: none;
  opacity: 0.4;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: var(--hero-gradient);
  z-index: 2;
}

.hero-overlay-side {
  position: absolute;
  inset: 0;
  background: var(--hero-gradient-side);
  z-index: 2;
}

.hero-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2.5rem clamp(1.5rem, 4vw, 4rem);
  z-index: 3;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  background: var(--red);
  color: #ffffff;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-radius: 4px;
  width: fit-content;
  box-shadow: 0 2px 12px rgba(255, 45, 45, 0.4);
}

.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 400;
  letter-spacing: 0.03em;
  color: #ffffff;
  line-height: 1.1;
  max-width: 600px;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.7), 0 1px 4px rgba(0,0,0,0.5);
}

[data-theme="light"] .hero-title {
  color: #0a0a0a;
  text-shadow: none;
}

.hero-meta {
  font-family: var(--font-body);
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.7);
}

[data-theme="light"] .hero-meta {
  color: var(--text-secondary);
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.25rem;
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.6rem;
  border: none;
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

.hero-btn-primary {
  background: var(--red);
  color: #ffffff;
  box-shadow: 0 4px 20px rgba(255, 45, 45, 0.4);
}

.hero-btn-primary:hover {
  background: #e82828;
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(255, 45, 45, 0.5);
}

.hero-btn-primary:active {
  transform: scale(0.97);
}

.hero-btn-icon {
  display: flex;
  align-items: center;
}

/* ========================================
   Topic Section
   ======================================== */
.topic-section {
  margin-bottom: 3rem;
  animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.topic-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
  padding: 0;
}

.topic-title {
  font-family: var(--font-heading);
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  transition: color var(--transition-speed) var(--transition-ease);
}

.topic-see-all {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  text-decoration: none;
  margin-left: 0.5rem;
  transition: color 0.25s ease;
}

.topic-see-all:hover {
  color: var(--red);
}

/* --- Scroll Arrows --- */
.scroll-arrows {
  display: flex;
  gap: 0.35rem;
  margin-left: auto;
}

.scroll-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--divider);
  border-radius: 8px;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.2s ease,
              border-color 0.2s ease,
              background 0.2s ease,
              transform 0.15s ease,
              filter 0.2s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.scroll-arrow:hover {
  color: var(--text-primary);
  border-color: var(--red);
  background: var(--sidebar-item-active-bg);
  transform: scale(1.1);
  filter: brightness(1.15);
}

.scroll-arrow:active {
  transform: scale(0.97);
}

/* ========================================
   Card Row (Horizontal Scroll)
   ======================================== */
.card-row {
  position: relative;
  overflow: hidden;
}

/* 🌫️ Cinematic row fade edges — dual gradient masking */
.card-row-track {
  -webkit-mask-image: linear-gradient(to right, transparent, black 1.5%, black 98.5%, transparent);
  mask-image: linear-gradient(to right, transparent, black 1.5%, black 98.5%, transparent);
}

/* Right fade overlay for additional depth */
.card-row::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 40px;
  background: linear-gradient(to left, var(--bg), transparent);
  z-index: 2;
  pointer-events: none;
  transition: background var(--transition-speed) var(--transition-ease);
}

/* Left fade overlay */
.card-row::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 8px;
  background: linear-gradient(to right, var(--bg), transparent);
  z-index: 2;
  pointer-events: none;
  transition: background var(--transition-speed) var(--transition-ease);
}

.card-row-track {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x proximity;
  padding-bottom: 0.75rem;
  padding-right: 3rem;

  /* Hide scrollbar */
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.card-row-track::-webkit-scrollbar {
  display: none;
}

/* ========================================
   Video Card (Reusable Component)
   ======================================== */
.video-card {
  flex: 0 0 auto;
  width: clamp(200px, 20vw, 280px);
  text-decoration: none;
  color: inherit;
  border-radius: 10px;
  overflow: hidden;
  scroll-snap-align: start;
  box-shadow: var(--card-shadow);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.35s ease,
              opacity 0.3s ease;
  -webkit-tap-highlight-color: transparent;
  will-change: transform;
}

.video-card:hover {
  transform: translateY(-4px) scale(1.05);
  box-shadow: var(--card-hover-shadow);
  z-index: 10;
}

/* 🎯 Focus dimming — sibling cards dim when one is hovered */
.card-row-track:hover .video-card {
  opacity: 0.55;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.35s ease,
              opacity 0.3s ease;
}

.card-row-track:hover .video-card:hover {
  opacity: 1;
}

/* Thumbnail */
.card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--card-thumb-bg);
  border-radius: 10px;
  overflow: hidden;
  transition: background var(--transition-speed) var(--transition-ease);
}

/* Gradient overlay on thumbnail */
.card-thumb::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.5) 0%, transparent 50%);
  z-index: 1;
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: 10px;
}

.video-card:hover .card-thumb::before {
  opacity: 1;
}

/* Play button overlay */
.card-thumb::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  width: 40px;
  height: 40px;
  background: rgba(255, 45, 45, 0.9);
  border-radius: 50%;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  /* Triangle play icon via borders */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 18px;
  box-shadow: 0 4px 16px rgba(255, 45, 45, 0.4);
}

.video-card:hover .card-thumb::after {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

/* Card info */
.card-info {
  padding: 0.6rem 0.2rem 0;
}

.card-title {
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
  margin-bottom: 0.2rem;
  transition: color var(--transition-speed) var(--transition-ease);

  /* Clamp to 2 lines */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-tertiary);
  transition: color var(--transition-speed) var(--transition-ease);
}

/* ========================================
   Placeholder Card ("Coming Soon")
   ======================================== */
.placeholder-card {
  pointer-events: none;
  opacity: 0.35;
  cursor: default;
}

.placeholder-card .card-thumb {
  background: var(--card-thumb-bg);
  /* Subtle shimmer animation */
  background-image: linear-gradient(
    90deg,
    var(--card-thumb-bg) 0%,
    var(--bg-card-hover) 50%,
    var(--card-thumb-bg) 100%
  );
  background-size: 200% 100%;
  animation: shimmer 2.5s ease-in-out infinite;
}

/* Disable hover effects on placeholders */
.placeholder-card:hover {
  transform: none;
  box-shadow: var(--card-shadow);
}

.placeholder-card:hover .card-thumb::before,
.placeholder-card:hover .card-thumb::after {
  opacity: 0;
}

/* Prevent dimming siblings for placeholder-only rows */
.card-row-track:hover .placeholder-card {
  opacity: 0.35;
}

/* ========================================
   THE PROCESS — Page Styles
   ======================================== */

/* Page heading container */
.process-heading-wrapper {
  position: relative;
  display: inline-block;
  margin-bottom: 2.5rem;
}

.process-heading {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  line-height: 1;
  cursor: default;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* Hover tooltip card */
.process-tooltip {
  position: absolute;
  top: calc(100% + 0.75rem);
  left: 0;
  width: max-content;
  max-width: 380px;
  padding: 1.1rem 1.4rem;
  border-radius: 14px;

  /* Glassmorphism */
  background: rgba(14, 14, 14, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5),
              0 0 0 1px rgba(255, 255, 255, 0.04);

  /* Hidden by default */
  opacity: 0;
  transform: translateY(6px) scale(0.97);
  pointer-events: none;

  transition: opacity 0.3s var(--transition-ease),
              transform 0.3s var(--transition-ease);
  z-index: 20;
}

[data-theme="light"] .process-tooltip {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1),
              0 0 0 1px rgba(0, 0, 0, 0.04);
}

.process-tooltip p {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 400;
  line-height: 1.55;
  color: var(--text-secondary);
  margin: 0;
}

.process-heading-wrapper:hover .process-tooltip {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

/* --- Page heading bar (used across pages) --- */
.page-heading-bar {
  padding: 2.5rem 0 2rem;
  margin-bottom: 0.5rem;
  border-bottom: 1px solid var(--divider);
  animation: fadeInUp 0.5s ease both;
}

.page-heading {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  line-height: 1;
  transition: color var(--transition-speed) var(--transition-ease);
}

.page-heading-accent {
  color: var(--red);
}

.page-tagline {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--text-secondary);
  margin-top: 0.6rem;
  letter-spacing: 0.02em;
  line-height: 1.5;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* Season description (always visible) */
.season-description {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 400;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 560px;
  margin-bottom: 2rem;
  opacity: 0.8;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* Season block */
.season-block {
  margin-bottom: 3rem;
  animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.season-label {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 0.35rem;
  padding: 0.2rem 0.6rem;
  background: rgba(255, 45, 45, 0.08);
  border-radius: 4px;
  transition: color var(--transition-speed) var(--transition-ease);
}

[data-theme="light"] .season-label {
  background: rgba(212, 32, 32, 0.06);
}

.season-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 400;
  letter-spacing: 0.03em;
  color: var(--text-primary);
  margin-bottom: 2rem;
  line-height: 1.1;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* Episode header row (label + arrows) */
.episode-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.episode-section-label {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color var(--transition-speed) var(--transition-ease);
}

/* Episode card — slightly larger than home cards */
.episode-card {
  width: clamp(240px, 24vw, 340px);
}

/* Latest episode highlight */
.episode-card.latest-episode {
  width: clamp(300px, 32vw, 440px);
}

.episode-card.latest-episode .card-thumb {
  border: 1px solid rgba(255, 45, 45, 0.2);
  box-shadow: 0 0 20px rgba(255, 45, 45, 0.1);
}

.episode-card.latest-episode .episode-number {
  color: rgba(255, 45, 45, 0.4);
  font-size: 2rem;
}

/* Episode thumbnail overlay number */
.episode-thumb {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
}

.episode-number {
  position: absolute;
  bottom: 0.6rem;
  left: 0.7rem;
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.12);
  line-height: 1;
  user-select: none;
  z-index: 2;
  transition: color 0.25s ease;
}

.episode-card:hover .episode-number {
  color: rgba(255, 255, 255, 0.3);
}

/* ========================================
   FEATURED — Page Styles
   ======================================== */

/* Hero section */
.featured-hero {
  margin-bottom: 2.5rem;
  animation: fadeInUp 0.5s ease both;
}

.featured-hero-card {
  display: block;
  text-decoration: none;
  color: inherit;
  border-radius: 14px;
  overflow: hidden;
  transition: transform 0.3s ease,
              box-shadow 0.3s ease;
  -webkit-tap-highlight-color: transparent;
  max-width: 100%;
  position: relative;
}

.featured-hero-card:hover {
  transform: translateY(-4px) scale(1.005);
  box-shadow: 0 12px 48px rgba(255, 45, 45, 0.12), 0 8px 30px rgba(0, 0, 0, 0.3);
}

/* Hero thumbnail */
.featured-hero-thumb {
  width: 100%;
  aspect-ratio: 21 / 9;
  background: var(--card-thumb-bg);
  border-radius: 14px;
  position: relative;
  overflow: hidden;
  transition: background var(--transition-speed) var(--transition-ease);
}

/* Gradient overlay on featured hero */
.featured-hero-thumb::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.2) 40%, transparent 70%);
  z-index: 1;
}

[data-theme="light"] .featured-hero-thumb::before {
  background: linear-gradient(to top, rgba(245,245,245,0.8) 0%, rgba(245,245,245,0.3) 40%, transparent 70%);
}

/* Play button on featured hero */
.featured-hero-thumb::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  width: 56px;
  height: 56px;
  background: rgba(255, 45, 45, 0.9);
  border-radius: 50%;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 22px;
  box-shadow: 0 4px 24px rgba(255, 45, 45, 0.5);
}

.featured-hero-card:hover .featured-hero-thumb::after {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

/* "Watch this first" badge */
.featured-hero-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.3rem 0.8rem;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #ffffff;
  background: var(--red);
  border-radius: 4px;
  user-select: none;
  z-index: 3;
  box-shadow: 0 2px 12px rgba(255, 45, 45, 0.4);
  transition: background var(--transition-speed) var(--transition-ease);
}

/* Hero card info */
.featured-hero-info {
  padding: 1rem 0.25rem 0;
}

.featured-hero-title {
  font-family: var(--font-heading);
  font-size: clamp(1.1rem, 2.5vw, 1.6rem);
  font-weight: 400;
  letter-spacing: 0.03em;
  color: var(--text-primary);
  line-height: 1.2;
  margin-bottom: 0.3rem;
  transition: color var(--transition-speed) var(--transition-ease);
}

.featured-hero-meta {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-tertiary);
  transition: color var(--transition-speed) var(--transition-ease);
}

/* ========================================
   ACTIVITIES — Page Styles
   ======================================== */

.activities-subtitle {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  letter-spacing: 0.02em;
  line-height: 1.5;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* ========================================
   CATEGORIES — Grid Page
   ======================================== */

.category-subtitle {
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  letter-spacing: 0.02em;
  transition: color var(--transition-speed) var(--transition-ease);
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.category-grid-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 2rem 1.75rem;
  border-radius: 14px;
  background: var(--bg-card);
  border: 1px solid var(--card-border);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.3s ease,
              border-color 0.3s ease,
              background 0.3s ease;
  -webkit-tap-highlight-color: transparent;
}

/* Subtle gradient overlay on hover */
.category-grid-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 45, 45, 0.04) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: 14px;
}

.category-grid-card:hover::before {
  opacity: 1;
}

.category-grid-card:hover {
  transform: translateY(-6px) scale(1.01);
  border-color: var(--card-hover-border);
  box-shadow: var(--card-hover-shadow);
}

.category-grid-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(255, 45, 45, 0.12) 0%, rgba(255, 45, 45, 0.04) 100%);
  color: var(--red);
  margin-bottom: 1.25rem;
  transition: background 0.25s ease,
              transform 0.3s ease;
}

[data-theme="light"] .category-grid-card-icon {
  background: linear-gradient(135deg, rgba(212, 32, 32, 0.1) 0%, rgba(212, 32, 32, 0.03) 100%);
  color: var(--logo-color);
}

.category-grid-card:hover .category-grid-card-icon {
  transform: scale(1.08);
  background: linear-gradient(135deg, rgba(255, 45, 45, 0.18) 0%, rgba(255, 45, 45, 0.06) 100%);
}

.category-grid-card-label {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
  line-height: 1.1;
  transition: color var(--transition-speed) var(--transition-ease);
}

.category-grid-card-desc {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 400;
  color: var(--text-secondary);
  line-height: 1.45;
  transition: color var(--transition-speed) var(--transition-ease);
}

.category-grid-card-arrow {
  position: absolute;
  top: 1.75rem;
  right: 1.5rem;
  color: var(--text-tertiary);
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity 0.25s ease,
              transform 0.25s ease,
              color 0.25s ease;
}

.category-grid-card:hover .category-grid-card-arrow {
  opacity: 1;
  transform: translateX(0);
  color: var(--red);
}

/* ========================================
   CATEGORY PAGE — Individual Pages
   ======================================== */

.category-page-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  padding: 2rem 0 1.5rem;
  border-bottom: 1px solid var(--divider);
  animation: fadeInUp 0.5s ease both;
}

.category-back-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--divider);
  border-radius: 12px;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  flex-shrink: 0;
  transition: color 0.25s ease,
              border-color 0.25s ease,
              transform 0.15s ease,
              background 0.25s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.category-back-btn:hover {
  color: var(--red);
  border-color: var(--red);
  background: rgba(255, 45, 45, 0.06);
  transform: translateX(-3px);
}

[data-theme="light"] .category-back-btn:hover {
  background: rgba(212, 32, 32, 0.05);
}

.category-back-btn:active {
  transform: scale(0.9);
}

.category-page-title {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  line-height: 1;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* ========================================
   Video Modal
   ======================================== */

/* Overlay */
.video-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
  pointer-events: none;
  transition: background 0.35s var(--transition-ease),
              backdrop-filter 0.35s var(--transition-ease),
              -webkit-backdrop-filter 0.35s var(--transition-ease);
}

.video-modal-overlay.active {
  background: rgba(0, 0, 0, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  pointer-events: auto;
}

/* Modal panel */
.video-modal {
  position: relative;
  width: 92vw;
  max-width: 920px;
  border-radius: 16px;
  overflow: hidden;

  /* Glassmorphism */
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7),
              0 0 0 1px rgba(255, 255, 255, 0.03),
              0 0 60px rgba(255, 45, 45, 0.08);

  /* Hidden state */
  opacity: 0;
  transform: scale(0.92) translateY(24px);
  transition: opacity 0.35s var(--transition-ease),
              transform 0.35s var(--transition-ease);
  padding: 0.6rem;
}

[data-theme="light"] .video-modal {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.2),
              0 0 0 1px rgba(0, 0, 0, 0.04);
}

.video-modal-overlay.active .video-modal {
  opacity: 1;
  transform: scale(1) translateY(0);
}

/* Close button */
.video-modal-close {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 45, 45, 0.15);
  color: var(--red);
  cursor: pointer;
  transition: color 0.2s ease,
              background 0.2s ease,
              transform 0.15s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.video-modal-close:hover {
  color: #ffffff;
  background: var(--red);
  transform: scale(1.1);
}

.video-modal-close:active {
  transform: scale(0.9);
}

/* 16:9 responsive iframe wrapper */
.video-modal-iframe-wrap {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 */
  border-radius: 12px;
  overflow: hidden;
  background: #000;
}

.video-modal-iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* ========================================
   PWA Install Banner
   ======================================== */
.install-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 8000;
  padding: 0;
  transform: translateY(100%);
  opacity: 0;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
              opacity 0.35s ease;
  pointer-events: none;
}

.install-banner.visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.install-banner-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1.25rem;
  margin: 0.75rem;
  border-radius: 14px;

  /* Glassmorphism */
  background: rgba(10, 10, 10, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.4),
              0 0 0 1px rgba(255, 255, 255, 0.03);
}

[data-theme="light"] .install-banner-content {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.08),
              0 0 0 1px rgba(0, 0, 0, 0.04);
}

.install-banner-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255, 45, 45, 0.1);
  color: var(--red);
  flex-shrink: 0;
}

.install-banner-text {
  flex: 1;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.3;
  letter-spacing: 0.01em;
}

.install-banner-btn {
  flex-shrink: 0;
  padding: 0.5rem 1.15rem;
  border: none;
  border-radius: 8px;
  background: var(--red);
  color: #ffffff;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 0.15s ease,
              box-shadow 0.25s ease,
              background 0.25s ease;
  -webkit-tap-highlight-color: transparent;
}

.install-banner-btn:hover {
  background: #e82828;
  box-shadow: 0 4px 16px rgba(255, 45, 45, 0.35);
  transform: scale(1.04);
}

.install-banner-btn:active {
  transform: scale(0.95);
}

.install-banner-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  flex-shrink: 0;
  transition: color 0.2s ease,
              transform 0.15s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.install-banner-close:hover {
  color: var(--text-primary);
}

.install-banner-close:active {
  transform: scale(0.85);
}

/* --- iOS Install Instruction Overlay --- */
.ios-install-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 1rem;
  background: rgba(0, 0, 0, 0);
  transition: background 0.3s ease;
}

.ios-install-overlay.visible {
  background: rgba(0, 0, 0, 0.6);
}

.ios-install-card {
  position: relative;
  width: 100%;
  max-width: 380px;
  padding: 2rem 1.75rem 2.25rem;
  border-radius: 20px;
  background: rgba(14, 14, 14, 0.95);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
  transform: translateY(30px);
  opacity: 0;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              opacity 0.3s ease;
}

[data-theme="light"] .ios-install-card {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.12);
}

.ios-install-overlay.visible .ios-install-card {
  transform: translateY(0);
  opacity: 1;
}

.ios-install-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.ios-install-close:hover {
  color: var(--red);
  background: rgba(255, 45, 45, 0.1);
}

.ios-install-title {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  margin-bottom: 1.25rem;
}

.ios-install-step {
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 400;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0.6rem;
}

.ios-install-step strong {
  color: var(--text-primary);
  font-weight: 600;
}

.ios-share-icon {
  display: inline-block;
  color: var(--red);
  font-size: 1rem;
}

/* ========================================
   WATCH HISTORY — Page Styles
   ======================================== */

/* Hero reuses .featured-hero-card styles — this wrapper adds spacing */
.history-hero {
  margin-bottom: 2.5rem;
  animation: fadeInUp 0.5s ease both;
}

/* --- Empty State --- */
.history-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5rem 2rem;
}

.history-empty-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255, 45, 45, 0.1) 0%, rgba(255, 45, 45, 0.03) 100%);
  color: var(--red);
  margin-bottom: 1.75rem;
  animation: subtlePulse 3s ease-in-out infinite;
}

[data-theme="light"] .history-empty-icon {
  background: linear-gradient(135deg, rgba(212, 32, 32, 0.08) 0%, rgba(212, 32, 32, 0.02) 100%);
  color: var(--logo-color);
}

.history-empty-title {
  font-family: var(--font-heading);
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  margin-bottom: 0.6rem;
  transition: color var(--transition-speed) var(--transition-ease);
}

.history-empty-desc {
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 400;
  color: var(--text-secondary);
  max-width: 340px;
  line-height: 1.55;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* --- Clear History Button --- */
.history-clear-wrap {
  display: flex;
  justify-content: center;
  margin-top: 2rem;
  padding-bottom: 2rem;
}

.history-clear-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.5rem;
  border: 1px solid var(--divider);
  border-radius: 10px;
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.25s ease,
              border-color 0.25s ease,
              background 0.25s ease,
              transform 0.15s ease,
              box-shadow 0.25s ease;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.history-clear-btn:hover {
  color: var(--red);
  border-color: var(--red);
  background: rgba(255, 45, 45, 0.06);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(255, 45, 45, 0.1);
}

[data-theme="light"] .history-clear-btn:hover {
  background: rgba(212, 32, 32, 0.05);
}

.history-clear-btn:active {
  transform: scale(0.96);
}

/* ========================================
   LOCK IN AUDIO — Page Styles
   ======================================== */

/* --- Hero --- */
.audio-hero {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 420px;
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 3rem;
  margin-top: 1rem;
}

.audio-hero-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 60%, rgba(255, 45, 45, 0.08) 0%, transparent 70%);
  z-index: 0;
}

.audio-hero-glow {
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 45, 45, 0.18) 0%, transparent 70%);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  filter: blur(60px);
  animation: audioGlowPulse 4s ease-in-out infinite;
}

.audio-hero-glow--secondary {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(255, 45, 45, 0.06) 0%, transparent 70%);
  filter: blur(100px);
  animation-delay: 2s;
}

@keyframes audioGlowPulse {
  0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
}

.audio-hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.6rem;
  padding: 2rem;
}

.audio-hero-badge {
  display: inline-block;
  padding: 0.3rem 0.9rem;
  font-family: var(--font-body);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--red);
  border: 1px solid rgba(255, 45, 45, 0.3);
  border-radius: 20px;
  background: rgba(255, 45, 45, 0.06);
  margin-bottom: 0.5rem;
}

.audio-hero-title {
  font-family: var(--font-heading);
  font-size: clamp(2.8rem, 7vw, 5rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  line-height: 1;
  transition: color var(--transition-speed) var(--transition-ease);
}

.audio-hero-title-accent {
  color: var(--red);
  text-shadow: 0 0 40px rgba(255, 45, 45, 0.4);
}

.audio-hero-subtitle {
  font-family: var(--font-body);
  font-size: clamp(0.95rem, 2vw, 1.2rem);
  font-weight: 400;
  color: var(--text-secondary);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-top: 0.2rem;
}

.audio-hero-recording {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-tertiary);
  margin-top: 0.5rem;
}

.audio-hero-recording-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red);
  animation: audioDotPulse 1.5s ease-in-out infinite;
  box-shadow: 0 0 8px rgba(255, 45, 45, 0.6);
}

@keyframes audioDotPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.7); }
}

.audio-hero-play {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 2px solid rgba(255, 45, 45, 0.25);
  background: rgba(255, 45, 45, 0.08);
  color: rgba(255, 45, 45, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1.5rem;
  cursor: not-allowed;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease, background 0.3s ease;
  position: relative;
}

.audio-hero-play::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid rgba(255, 45, 45, 0.1);
  animation: audioRingPulse 3s ease-in-out infinite;
}

@keyframes audioRingPulse {
  0%, 100% { transform: scale(1); opacity: 0.5; }
  50% { transform: scale(1.15); opacity: 0; }
}

.audio-hero-play:not(:disabled) {
  cursor: pointer;
  color: #fff;
  background: var(--red);
  border-color: var(--red);
  box-shadow: 0 4px 30px rgba(255, 45, 45, 0.4);
}

.audio-hero-play:not(:disabled):hover {
  transform: scale(1.1);
  box-shadow: 0 8px 40px rgba(255, 45, 45, 0.55);
}

/* --- Featured audiobook card --- */
.audio-featured {
  margin-bottom: 3rem;
}

.audio-featured-card {
  display: flex;
  gap: 2rem;
  padding: 2rem;
  border-radius: 18px;
  background: var(--bg-card);
  border: 1px solid var(--card-border);
  position: relative;
  overflow: hidden;
  opacity: 0.7;
  filter: grayscale(0.3) blur(0.3px);
  transition: opacity 0.4s ease, filter 0.4s ease,
              box-shadow 0.4s ease, border-color 0.4s ease;
}

.audio-featured-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 45, 45, 0.03) 0%, transparent 60%);
  pointer-events: none;
}

.audio-featured-card:hover {
  opacity: 0.85;
  filter: grayscale(0.15) blur(0px);
  border-color: rgba(255, 45, 45, 0.15);
  box-shadow: 0 8px 40px rgba(255, 45, 45, 0.08);
}

.audio-featured-visual {
  flex-shrink: 0;
  width: 140px;
  height: 140px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255, 45, 45, 0.1) 0%, rgba(255, 45, 45, 0.02) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  position: relative;
}

.audio-featured-icon {
  color: var(--red);
  opacity: 0.6;
}

.audio-featured-eq {
  display: flex;
  gap: 3px;
  align-items: flex-end;
  height: 20px;
}

.audio-featured-eq span {
  display: block;
  width: 3px;
  border-radius: 2px;
  background: var(--red);
  opacity: 0.3;
  animation: audioEqBounce 1.2s ease-in-out infinite;
}

.audio-featured-eq span:nth-child(1) { height: 6px; animation-delay: 0s; }
.audio-featured-eq span:nth-child(2) { height: 12px; animation-delay: 0.15s; }
.audio-featured-eq span:nth-child(3) { height: 18px; animation-delay: 0.3s; }
.audio-featured-eq span:nth-child(4) { height: 10px; animation-delay: 0.45s; }
.audio-featured-eq span:nth-child(5) { height: 14px; animation-delay: 0.6s; }
.audio-featured-eq span:nth-child(6) { height: 8px; animation-delay: 0.75s; }
.audio-featured-eq span:nth-child(7) { height: 16px; animation-delay: 0.9s; }

@keyframes audioEqBounce {
  0%, 100% { transform: scaleY(0.4); }
  50% { transform: scaleY(1); }
}

.audio-featured-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.4rem;
}

.audio-featured-title {
  font-family: var(--font-heading);
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  line-height: 1.1;
  transition: color var(--transition-speed) var(--transition-ease);
}

.audio-featured-subtitle {
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--red);
  opacity: 0.7;
}

.audio-featured-meta {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 400;
  color: var(--text-tertiary);
  margin-top: 0.2rem;
}

.audio-featured-play-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding: 0.6rem 1.4rem;
  border: 1px solid rgba(255, 45, 45, 0.2);
  border-radius: 8px;
  background: rgba(255, 45, 45, 0.06);
  color: rgba(255, 45, 45, 0.4);
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: not-allowed;
  width: fit-content;
  transition: all 0.25s ease;
}

.audio-featured-play-btn:not(:disabled) {
  cursor: pointer;
  color: #fff;
  background: var(--red);
  border-color: var(--red);
  box-shadow: 0 4px 20px rgba(255, 45, 45, 0.3);
}

.audio-featured-play-btn:not(:disabled):hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(255, 45, 45, 0.45);
}

/* --- Audio sections (chapter rows) --- */
.audio-section {
  margin-bottom: 2.5rem;
}

.audio-section-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.audio-section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  transition: color var(--transition-speed) var(--transition-ease);
}

/* Card row — horizontal scroll */
.audio-card-row {
  position: relative;
  overflow: hidden;
}

.audio-card-row::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 80px;
  background: linear-gradient(to left, var(--bg), transparent);
  z-index: 2;
  pointer-events: none;
}

.audio-card-row::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(to right, var(--bg), transparent);
  z-index: 2;
  pointer-events: none;
}

.audio-card-row-track {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x proximity;
  padding-bottom: 0.75rem;
  padding-right: 3rem;
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-mask-image: linear-gradient(to right, transparent, black 4%, black 96%, transparent);
  mask-image: linear-gradient(to right, transparent, black 4%, black 96%, transparent);
}

.audio-card-row-track::-webkit-scrollbar {
  display: none;
}

/* --- Chapter card --- */
.audio-chapter-card {
  flex: 0 0 auto;
  width: clamp(180px, 18vw, 240px);
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  scroll-snap-align: start;
  background: var(--bg-card);
  border: 1px solid var(--card-border);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.35s ease,
              border-color 0.35s ease;
  animation: fadeInUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
  -webkit-tap-highlight-color: transparent;
}

.audio-chapter-card:hover {
  transform: translateY(-4px) scale(1.03);
  border-color: rgba(255, 45, 45, 0.2);
  box-shadow: 0 8px 32px rgba(255, 45, 45, 0.1), 0 4px 16px rgba(0, 0, 0, 0.2);
}

/* Focus dimming for sibling cards */
.audio-card-row-track:hover .audio-chapter-card {
  opacity: 0.55;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.35s ease,
              border-color 0.35s ease,
              opacity 0.3s ease;
}

.audio-card-row-track:hover .audio-chapter-card:hover {
  opacity: 1;
}

/* Thumbnail area */
.audio-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background: var(--card-thumb-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.audio-card-thumb-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  position: relative;
  z-index: 1;
}

.audio-card-chapter-num {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.07);
  user-select: none;
  transition: color 0.3s ease;
}

[data-theme="light"] .audio-card-chapter-num {
  color: rgba(0, 0, 0, 0.06);
}

.audio-chapter-card:hover .audio-card-chapter-num {
  color: rgba(255, 45, 45, 0.15);
}

.audio-card-lock {
  color: rgba(255, 255, 255, 0.15);
  transition: color 0.3s ease;
}

[data-theme="light"] .audio-card-lock {
  color: rgba(0, 0, 0, 0.12);
}

.audio-chapter-card:hover .audio-card-lock {
  color: rgba(255, 45, 45, 0.3);
}

/* Mini waveform in thumbnail */
.audio-card-waveform {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 2px;
  align-items: flex-end;
  height: 14px;
  z-index: 1;
}

.audio-card-waveform span {
  display: block;
  width: 2px;
  border-radius: 1px;
  background: var(--red);
  opacity: 0.15;
  animation: audioWaveIdle 2s ease-in-out infinite;
}

.audio-card-waveform span:nth-child(1) { height: 4px; animation-delay: 0s; }
.audio-card-waveform span:nth-child(2) { height: 8px; animation-delay: 0.2s; }
.audio-card-waveform span:nth-child(3) { height: 12px; animation-delay: 0.4s; }
.audio-card-waveform span:nth-child(4) { height: 6px; animation-delay: 0.6s; }
.audio-card-waveform span:nth-child(5) { height: 10px; animation-delay: 0.8s; }

@keyframes audioWaveIdle {
  0%, 100% { transform: scaleY(0.5); }
  50% { transform: scaleY(1); }
}

/* Card info */
.audio-card-info {
  padding: 0.65rem 0.75rem 0.75rem;
}

.audio-card-title {
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.35;
  margin-bottom: 0.35rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color var(--transition-speed) var(--transition-ease);
}

.audio-card-status {
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.06em;
}

.audio-card-status--recording {
  color: var(--text-tertiary);
  animation: subtlePulse 3s ease-in-out infinite;
}

.audio-card-status--ready {
  color: var(--red);
}

/* Unlocked card override — full color, playable */
.audio-chapter-card--unlocked {
  border-color: rgba(255, 45, 45, 0.15);
}

.audio-chapter-card--unlocked .audio-card-lock {
  display: none;
}

.audio-chapter-card--unlocked .audio-card-chapter-num {
  color: rgba(255, 45, 45, 0.2);
}

/* --- CTA: Read the Book --- */
.audio-cta {
  margin: 3rem 0;
}

.audio-cta-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 3rem 2rem;
  border-radius: 18px;
  background: var(--bg-card);
  border: 1px solid var(--card-border);
  position: relative;
  overflow: hidden;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.audio-cta-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(255, 45, 45, 0.05) 0%, transparent 60%);
  pointer-events: none;
}

.audio-cta-card:hover {
  border-color: rgba(255, 45, 45, 0.15);
  box-shadow: 0 4px 30px rgba(255, 45, 45, 0.06);
}

.audio-cta-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.audio-cta-title {
  font-family: var(--font-heading);
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  transition: color var(--transition-speed) var(--transition-ease);
}

.audio-cta-text {
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 400;
  color: var(--text-secondary);
  max-width: 400px;
  line-height: 1.55;
  margin-bottom: 1.5rem;
  transition: color var(--transition-speed) var(--transition-ease);
}

.audio-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 2rem;
  border: none;
  border-radius: 10px;
  background: var(--red);
  color: #ffffff;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.25s ease,
              background 0.25s ease;
  box-shadow: 0 4px 20px rgba(255, 45, 45, 0.35);
  -webkit-tap-highlight-color: transparent;
}

.audio-cta-btn:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 8px 32px rgba(255, 45, 45, 0.5);
  background: #e82828;
}

.audio-cta-btn:active {
  transform: scale(0.97);
}

.audio-cta-subtext {
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-tertiary);
  margin-top: 1rem;
  letter-spacing: 0.04em;
  transition: color var(--transition-speed) var(--transition-ease);
}

/* --- Toast notification --- */
.audio-toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  padding: 0.75rem 1.5rem;
  border-radius: 12px;
  background: rgba(10, 10, 10, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 45, 45, 0.15);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  z-index: 9000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(255, 45, 45, 0.1);
}

[data-theme="light"] .audio-toast {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(212, 32, 32, 0.15);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
  color: var(--text-primary);
}

.audio-toast--visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}



/* ========================================
   Responsive — Tablet
   ======================================== */
@media (max-width: 1024px) {
  .logo {
    font-size: clamp(2.2rem, 5vw, 3rem);
  }

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

  .hero-section {
    aspect-ratio: 16 / 9;
    max-height: 400px;
  }

  .featured-hero-thumb {
    aspect-ratio: 16 / 9;
  }

  /* AUDIO — Tablet */
  .audio-hero {
    min-height: 340px;
  }

  .audio-featured-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .audio-featured-info {
    align-items: center;
  }


}

/* ========================================
   Responsive — Mobile
   ======================================== */
@media (max-width: 768px) {


  /* Sidebar: off-screen by default */
  .sidebar {
    top: 0;
    left: 0;
    bottom: 0;
    width: 280px;
    border-radius: 0;
    border-right: 1px solid var(--sidebar-border);
    transform: translateX(-110%);
    transition: transform 0.35s var(--transition-ease),
                background var(--transition-speed) var(--transition-ease),
                border-color var(--transition-speed) var(--transition-ease);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  /* Show theme toggle inside sidebar on mobile */
  .sidebar-footer {
    display: block;
  }

  /* Main content: no sidebar offset */
  .main-wrapper {
    margin-left: 0;
  }

  /* Header layout */
  .header {
    justify-content: center;
    position: relative;
    padding: 1.5rem 1.25rem;
  }

  /* Show hamburger */
  .menu-btn {
    display: flex;
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
  }

  .menu-btn:active {
    transform: translateY(-50%) scale(0.9);
  }

  /* Hide header theme toggle on mobile */
  .header-theme-toggle {
    display: none;
  }

  /* Logo sizing */
  .logo {
    font-size: clamp(2rem, 9vw, 3rem);
  }

  .logo-tagline {
    text-align: center;
    font-size: 0.5rem;
    letter-spacing: 0.2em;
  }

  .logo-link {
    align-items: center;
  }

  /* Hero section */
  .hero-section {
    aspect-ratio: 16 / 9;
    max-height: 300px;
    min-height: 200px;
    margin-bottom: 1.5rem;
  }

  .hero-title {
    font-size: clamp(1.2rem, 5vw, 1.8rem);
  }

  .hero-content {
    padding: 1.5rem 1rem;
  }

  .hero-btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.72rem;
  }

  /* Card sizing */
  .video-card {
    width: clamp(150px, 42vw, 210px);
  }

  .card-row-track {
    gap: 0.75rem;
    scroll-snap-type: x mandatory;
  }

  /* Reduce card-row fade on mobile */
  .card-row::after {
    width: 20px;
  }

  .card-row::before {
    width: 4px;
  }

  .card-row-track {
    -webkit-mask-image: linear-gradient(to right, transparent, black 1%, black 99%, transparent);
    mask-image: linear-gradient(to right, transparent, black 1%, black 99%, transparent);
  }

  /* Disable focus dimming on mobile (touch) */
  .card-row-track:hover .video-card {
    opacity: 1;
  }

  /* Page content */
  .page-content {
    padding: 0 1rem 3rem;
  }

  /* Page heading */
  .page-heading-bar {
    padding: 1.5rem 0 1.25rem;
  }

  .page-heading {
    font-size: clamp(2rem, 8vw, 3rem);
  }

  /* THE PROCESS — Mobile */
  .process-heading-wrapper {
    margin-bottom: 1.5rem;
  }

  .process-heading {
    font-size: clamp(2rem, 8vw, 3rem);
  }

  .process-tooltip {
    max-width: calc(100vw - 3rem);
    width: auto;
  }

  .season-description {
    font-size: 0.82rem;
    margin-bottom: 1.5rem;
  }

  .season-title {
    font-size: clamp(1.5rem, 6vw, 2rem);
    margin-bottom: 1.5rem;
  }

  .episode-card {
    width: clamp(200px, 52vw, 280px);
  }

  .episode-card.latest-episode {
    width: clamp(260px, 65vw, 340px);
  }

  /* FEATURED — Mobile */
  .featured-hero-card {
    max-width: 100%;
    border-radius: 12px;
  }

  .featured-hero-thumb {
    border-radius: 12px;
    aspect-ratio: 16 / 9;
  }

  .featured-hero-badge {
    top: 0.75rem;
    left: 0.75rem;
    font-size: 0.6rem;
    padding: 0.25rem 0.6rem;
  }

  .featured-hero-title {
    font-size: 1rem;
  }

  /* CATEGORIES — Mobile */
  .category-grid {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }

  .category-grid-card {
    padding: 1.5rem 1.25rem;
    border-radius: 12px;
  }

  .category-grid-card-arrow {
    opacity: 1;
    transform: translateX(0);
  }

  .category-subtitle {
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
  }

  /* CATEGORY PAGE — Mobile */
  .category-page-header {
    margin-bottom: 1.5rem;
    gap: 0.75rem;
    padding: 1.25rem 0 1rem;
  }

  .category-page-title {
    font-size: clamp(2rem, 8vw, 3rem);
  }

  .category-back-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
  }

  /* Video Modal — Mobile */
  .video-modal {
    width: 96vw;
    padding: 0.4rem;
    border-radius: 12px;
  }

  .video-modal-iframe-wrap {
    border-radius: 10px;
  }

  .video-modal-close {
    width: 32px;
    height: 32px;
    top: 0.4rem;
    right: 0.4rem;
  }

  /* AUDIO — Mobile */
  .audio-hero {
    min-height: 300px;
    border-radius: 14px;
    margin-bottom: 2rem;
  }

  .audio-hero-title {
    font-size: clamp(2rem, 10vw, 3rem);
  }

  .audio-hero-play {
    width: 64px;
    height: 64px;
  }

  .audio-featured-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1.5rem;
  }

  .audio-featured-visual {
    width: 120px;
    height: 120px;
  }

  .audio-featured-info {
    align-items: center;
  }

  .audio-chapter-card {
    width: clamp(150px, 42vw, 200px);
  }

  .audio-card-row-track:hover .audio-chapter-card {
    opacity: 1;
  }

  .audio-card-row::after {
    width: 30px;
  }

  .audio-card-row::before {
    width: 10px;
  }

  .audio-cta-card {
    padding: 2rem 1.25rem;
  }
}

/* ========================================
   Landscape mode enhancements
   ======================================== */
@media (orientation: landscape) and (max-height: 500px) {
  .hero-section {
    aspect-ratio: auto;
    max-height: 90vh;
    min-height: 60vh;
  }

  .video-modal {
    width: 85vw;
    max-width: 95vh;
  }

  .header {
    padding: 1rem clamp(1rem, 3vw, 2rem);
  }

  .logo {
    font-size: 2rem;
  }
}
