/* ================================================================
   Podcast Intel — User Frontend Styles
   ================================================================ */

/* --- CSS Variables --- */
:root {
  --accent: #7c3aed;
  --accent-hover: #6d28d9;
  --accent-light: #ede9fe;
  --accent-text: #5b21b6;
  --bg: #fafaf9;
  --bg-card: #ffffff;
  --text: #1c1917;
  --text-secondary: #78716c;
  --text-tertiary: #a8a29e;
  --border: #e7e5e4;
  --border-light: #f5f5f4;
  --success: #16a34a;
  --success-bg: #dcfce7;
  --error: #dc2626;
  --error-bg: #fef2f2;
  --warning: #b45309;
  --shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.1), 0 4px 10px rgba(0,0,0,0.06);
  --shadow-glow: 0 0 40px rgba(124,58,237,0.15);
  /* Dark hero palette */
  --hero-bg: #0f0a1e;
  --hero-text: #f5f5f4;
  --hero-text-secondary: #a8a0bf;
  --hero-glow: radial-gradient(ellipse 50% 60% at 50% 30%, rgba(124,58,237,0.2) 0%, transparent 70%);
  --gradient-text: linear-gradient(135deg, #7c3aed 0%, #a78bfa 50%, #c4b5fd 100%);
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --radius: 10px;
  --radius-sm: 6px;
  --radius-full: 9999px;
  --max-width: 960px;
  --nav-height: 60px;
  --tab-bar-height: 56px;
  /* Dark nav palette */
  --nav-bg: #0f0a1e;
  --nav-text: rgba(255,255,255,0.7);
  --nav-text-hover: #ffffff;
  --nav-text-active: #ffffff;
  --nav-active-bg: rgba(255,255,255,0.1);
  --nav-border: rgba(255,255,255,0.08);
  --nav-signout-border: rgba(255,255,255,0.15);
  /* Elevated cards */
  --shadow-card: 0 1px 3px rgba(0,0,0,0.04), 0 4px 12px rgba(0,0,0,0.06);
  --shadow-card-hover: 0 8px 24px rgba(0,0,0,0.1), 0 2px 8px rgba(0,0,0,0.06);
  --transition-lift: transform 0.25s var(--ease-out-expo), box-shadow 0.25s var(--ease-out-expo);
}

/* Settings sign-out button */
.settings-signout-btn {
  width: 100%;
  color: var(--text-secondary);
  border-color: var(--border);
}
.settings-signout-btn:hover {
  color: #dc2626;
  border-color: #dc2626;
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 15px; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
body { font-family: 'Inter', system-ui, -apple-system, sans-serif; background: var(--bg); color: var(--text); line-height: 1.5; overflow-wrap: break-word; padding-bottom: env(safe-area-inset-bottom, 0px); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
a, button, [role="button"] { -webkit-tap-highlight-color: transparent; }
button, input, select, textarea { font-family: inherit; font-size: inherit; }

/* --- Top Navigation --- */
.topnav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--nav-bg);
  border-bottom: 1px solid var(--nav-border);
  height: var(--nav-height);
  padding-top: env(safe-area-inset-top, 0px);
}
.topnav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  height: 100%;
  gap: 32px;
}
.topnav-brand { display: flex; align-items: center; flex-shrink: 0; }
.topnav-brand:hover { text-decoration: none; }
.topnav-brand img { }
.logo-mark-text { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; text-decoration: none; }
.logo-mark-text svg { flex-shrink: 0; }
.logo-mark-text .logo-wordmark { font-family: 'Space Grotesk', system-ui, sans-serif; font-weight: 600; letter-spacing: -0.02em; line-height: 1; }
.logo-mark-text .logo-w1 { color: #fff; }
.logo-mark-text .logo-w2 { color: #c4b5fd; }
.logo-mark-text.logo-light .logo-w1 { color: #1c1917; }
.logo-mark-text.logo-light .logo-w2 { color: #7c3aed; }
.topnav nav { display: flex; gap: 4px; }
.topnav nav a {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  color: var(--nav-text);
  font-weight: 500;
  font-size: 14px;
  transition: all 0.15s;
}
.topnav nav a:hover { background: var(--nav-active-bg); color: var(--nav-text-hover); text-decoration: none; }
.topnav nav a.active { background: var(--nav-active-bg); color: var(--nav-text-active); }
.nav-signout {
  margin-left: auto;
  font-size: 13px;
  font-weight: 500;
  color: var(--nav-text);
  padding: 6px 14px;
  border: 1px solid var(--nav-signout-border);
  border-radius: var(--radius-sm);
  transition: all 0.15s;
  white-space: nowrap;
}
.nav-signout:hover { color: #fca5a5; border-color: rgba(252,165,165,0.4); background: rgba(220,38,38,0.15); text-decoration: none; }
.nav-signout-mobile {
  display: none;
  color: var(--nav-text);
  font-weight: 500;
  font-size: 14px;
  padding: 10px 14px;
  border-top: 1px solid var(--nav-border);
  margin-top: 4px;
}
.nav-signout-mobile:hover { color: #fca5a5; background: rgba(220,38,38,0.15); text-decoration: none; }

.hamburger {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--nav-text-hover);
  padding: 4px;
  margin-left: auto;
}

/* --- Gear icon (mobile settings, hidden on desktop) --- */
.topnav-gear {
  display: none;
  margin-left: auto;
  color: var(--nav-text);
  padding: 8px;
  border-radius: var(--radius-sm);
  transition: all 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.topnav-gear:hover { color: var(--nav-text-hover); background: var(--nav-active-bg); text-decoration: none; }
.topnav-gear.active { color: var(--accent); }
.topnav-gear svg { display: block; }

/* --- Bottom Tab Bar (mobile only) --- */
.tab-bar { display: none; }
.tab-bar-hidden { display: none !important; }
.tab-bar-item {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  flex: 1; gap: 2px; color: var(--nav-text); font-size: 10px; font-weight: 500;
  text-decoration: none; transition: color 0.15s; padding: 6px 0;
  -webkit-tap-highlight-color: transparent;
}
.tab-bar-item:hover { text-decoration: none; }
.tab-bar-item.active { color: var(--accent); }
.tab-bar-item span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tab-bar-item svg { width: 22px; height: 22px; }
.tab-bar-item.active svg { stroke: var(--accent); }

/* --- Main Content Area --- */
main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 24px 20px 60px;
  min-height: calc(100vh - var(--nav-height));
  overflow-x: hidden;
}

/* Full-bleed for landing page */
main.full-bleed {
  max-width: none;
  padding: 0;
}

/* --- Loading --- */
.loading {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-secondary);
  font-size: 14px;
}
.loading::after {
  content: '';
  display: block;
  width: 24px;
  height: 24px;
  margin: 12px auto 0;
  border: 2px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* --- Scroll Reveal --- */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s var(--ease-out-expo), transform 0.7s var(--ease-out-expo);
}
.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .reveal-delay-1,
  .reveal-delay-2,
  .reveal-delay-3,
  .reveal-delay-4 { transition-delay: 0s; }
  .stat-card, .featured-card, .btn-primary, .card { transition: none; }
  .stat-card:hover, .featured-card:hover { transform: none; }
}

/* --- Toasts --- */
.toast-container { position: fixed; top: calc(var(--nav-height) + 12px); right: 20px; z-index: 1000; display: flex; flex-direction: column; gap: 8px; }
.toast {
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  animation: slideIn 0.2s ease-out;
  box-shadow: var(--shadow-md);
  max-width: min(400px, calc(100vw - 40px));
  overflow-wrap: break-word;
}
.toast-success { background: var(--accent-light); color: var(--accent-text); }
.toast-error { background: var(--error-bg); color: var(--error); }
.toast-info { background: #f0f4f8; color: #334155; }
@keyframes slideIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }

/* --- Cards --- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.25s var(--ease-out-expo);
}
.card + .card { margin-top: 16px; }
.card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.card-header .label { font-weight: 600; font-size: 16px; }
.card-empty { text-align: center; padding: 32px; color: var(--text-secondary); }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary { background: var(--accent); color: white; transition: all 0.15s, transform 0.25s var(--ease-out-expo), box-shadow 0.25s var(--ease-out-expo); }
.btn-primary:hover:not(:disabled) { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 0 20px rgba(124,58,237,0.25); }
.btn-lg { padding: 14px 32px; font-size: 16px; border-radius: var(--radius); }
.btn-ghost { background: transparent; color: var(--text-secondary); border: 1px solid var(--border); }
.btn-ghost:hover:not(:disabled) { background: var(--border-light); color: var(--text); }
.btn-outline { background: transparent; color: var(--accent); border: 1.5px solid var(--accent); }
.btn-outline:hover:not(:disabled) { background: var(--accent); color: white; }
.btn-danger { background: var(--error); color: white; }
.btn-danger:hover:not(:disabled) { background: #b91c1c; }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-subscribe { background: var(--accent); color: white; min-width: 100px; }
.btn-subscribed { background: var(--success-bg); color: var(--success); min-width: 100px; pointer-events: none; }
.btn-unsub { background: var(--success-bg); color: var(--success); min-width: 100px; cursor: pointer; transition: all 0.15s; }
.btn-unsub:hover { background: var(--error-bg); color: var(--error); }

/* --- Inputs --- */
input[type="text"], input[type="email"], input[type="password"], select {
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 16px;
  background: var(--bg-card);
  color: var(--text);
  transition: border-color 0.15s;
  width: 100%;
}
input[type="text"]:focus, input[type="email"]:focus, input[type="password"]:focus, select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.15);
}
label { font-weight: 500; font-size: 14px; color: var(--text-secondary); display: block; margin-bottom: 6px; }

/* --- Guest Tags (pill badges) --- */
.guest-tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  background: var(--accent-light);
  color: var(--accent-text);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}
.guest-tag:hover { background: var(--accent); color: white; text-decoration: none; }

/* --- Source Badges --- */
.source-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.source-itunes { background: #fee2e2; color: #991b1b; }
.source-youtube { background: #fef3c7; color: #92400e; }
.source-db { background: #e0e7ff; color: #3730a3; }

/* --- Podcast Artwork --- */
.podcast-art {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: var(--shadow);
  flex-shrink: 0;
}
.podcast-art-sm {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
}
.podcast-art-lg {
  width: 80px;
  height: 80px;
  border-radius: 10px;
  object-fit: cover;
  box-shadow: var(--shadow-md);
  flex-shrink: 0;
}

/* --- Artwork Placeholder (no image) --- */
.art-placeholder {
  background: var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  font-size: 20px;
}
.art-placeholder-md { font-size: 28px; }
.art-placeholder-lg { font-size: 32px; }

/* --- Episode Row Artwork (48px thumbnail) --- */
.ep-art {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}
.ep-art-placeholder {
  background: var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  font-size: 18px;
}
.podcast-card-placeholder {
  width: 140px;
  height: 140px;
  border-radius: 10px;
  margin-bottom: 8px;
  font-size: 40px;
}

/* --- Podcast Header (Episodes view) --- */
.podcast-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 16px;
  margin-bottom: 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}
.podcast-header .ph-info { flex: 1; min-width: 0; }
.podcast-header .ph-title-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.podcast-header .ph-title { font-size: 20px; font-weight: 600; margin: 0; }
.podcast-header .ph-meta { font-size: 13px; color: var(--text-secondary); margin-top: 4px; }
.podcast-header .ph-desc { font-size: 13px; color: var(--text-secondary); margin-top: 8px; line-height: 1.5; }
.podcast-header .ph-desc-clamped { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.podcast-header .ph-desc-toggle { background: none; border: none; padding: 0; cursor: pointer; color: var(--accent); font-size: 12px; margin-top: 4px; font-weight: 500; }
.podcast-header .ph-desc-toggle:hover { text-decoration: underline; }

/* Backfill action button — soft accent, turns solid on hover */
.btn-backfill { background: var(--accent-light); color: var(--accent-text); border: 1px solid transparent; }
.btn-backfill:hover:not(:disabled) { background: var(--accent); color: #fff; }
.btn-backfill:disabled { opacity: 0.6; cursor: default; }

/* Button group in podcast header */
.ph-actions { display: flex; gap: 8px; align-items: center; flex-shrink: 0; }

/* Ghost unsubscribe button */
.btn-unsub-ghost { color: var(--text-secondary); }
.btn-unsub-ghost:hover:not(:disabled) { color: var(--error); border-color: var(--error); background: var(--error-bg); }

/* --- Stat Cards --- */
.stats-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin-bottom: 24px; }
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
  box-shadow: var(--shadow-card);
  transition: var(--transition-lift), border-color 0.25s;
}
@media (hover: hover) { .stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-card-hover); border-color: rgba(124,58,237,0.2); } }
.stat-card .stat-value { font-size: 28px; font-weight: 700; color: var(--accent); }
.stat-card .stat-label { font-size: 12px; color: var(--text-secondary); margin-top: 2px; text-transform: uppercase; letter-spacing: 0.5px; }

/* --- Section Headers --- */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}
.section-header h2 { font-size: 18px; font-weight: 600; }
.section-header a { font-size: 13px; font-weight: 500; }

/* --- Horizontal Scroll Container --- */
.h-scroll {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 8px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}
.h-scroll::-webkit-scrollbar { height: 4px; }
.h-scroll::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

/* --- Podcast Card (Dashboard) --- */
.podcast-card {
  flex-shrink: 0;
  width: 140px;
  text-align: center;
  cursor: pointer;
  transition: transform 0.2s ease, filter 0.2s ease;
  color: inherit;
  text-decoration: none;
}
.podcast-card:hover { text-decoration: none; }
.podcast-card img { width: 140px; height: 140px; border-radius: 10px; object-fit: cover; box-shadow: var(--shadow-card); margin-bottom: 8px; transition: box-shadow 0.25s var(--ease-out-expo); }
@media (hover: hover) {
  .podcast-card:hover { transform: translateY(-4px); }
  .podcast-card:hover img { box-shadow: var(--shadow-card-hover); }
}
.podcast-card .pc-title { font-size: 13px; font-weight: 500; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.podcast-card .pc-badge { display: inline-block; margin-top: 4px; padding: 2px 8px; border-radius: var(--radius-full); background: var(--accent); color: white; font-size: 11px; font-weight: 600; }
.podcast-card .pc-badge-parsing { background: var(--accent-light); color: var(--accent-text); animation: pulse 1.5s ease-in-out infinite; }
.podcast-card .pc-badge-warning { background: #fef3c7; color: #92400e; }
.podcast-card .pc-badge-delayed { background: #fef3c7; color: #92400e; }
.podcast-card .pc-badge-failed { background: #fee2e2; color: #991b1b; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

/* --- Episode Row --- */
.episode-row {
  display: flex;
  gap: 12px;
  padding: 14px 8px;
  margin: 0 -8px;
  border-bottom: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  align-items: flex-start;
  transition: background 0.15s ease;
}
@media (hover: hover) { .episode-row:hover { background: var(--border-light); } }
.episode-row:last-child { border-bottom: none; }
.episode-info { flex: 1; min-width: 0; }
.episode-title { font-weight: 500; font-size: 14px; margin-bottom: 2px; }
.episode-title a { color: var(--text); }
.episode-title a:hover { color: var(--accent); }
.episode-meta { font-size: 12px; color: var(--text-secondary); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.episode-meta .divider { color: var(--text-tertiary); }
/* --- Episode AI Summary (expand/collapse) --- */
.episode-summary-wrap {
  margin-top: 6px;
  cursor: pointer;
  user-select: none;
}
.episode-summary-preview {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: 12.5px;
  color: var(--text-secondary);
}
.summary-icon {
  flex-shrink: 0;
  color: var(--accent);
  font-size: 11px;
}
.summary-text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.summary-more {
  flex-shrink: 0;
  color: var(--accent);
  font-size: 11.5px;
  font-weight: 500;
}
.episode-summary-full {
  display: none;
  font-size: 12.5px;
  color: var(--text-secondary);
  margin: 4px 0 0 16px;
  padding: 0;
  line-height: 1.6;
}
.episode-summary-full li { margin-bottom: 2px; }
.episode-summary-wrap.expanded .episode-summary-preview { display: none; }
.episode-summary-wrap.expanded .episode-summary-full { display: block; }
.episode-guests { margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px; }

/* --- Guest Row (Guests page) --- */
.guest-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 8px;
  margin: 0 -8px;
  border-bottom: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  transition: background 0.15s ease;
}
@media (hover: hover) { .guest-row:hover { background: var(--border-light); } }
.guest-row:last-child { border-bottom: none; }
.guest-name { font-weight: 500; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; flex: 1; min-width: 0; }
.guest-name a { color: var(--text); }
.guest-name a:hover { color: var(--accent); }
.guest-cross-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: var(--accent-light);
  color: var(--accent-text);
  font-size: 11px;
  font-weight: 600;
}
.guest-stats { font-size: 13px; color: var(--text-secondary); display: flex; gap: 16px; align-items: center; }
.guest-row-detail {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 2px;
  width: 100%;
}

/* --- Trending Section (Guests page) --- */
.trending-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 12px 16px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-card);
}
.trending-header {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-tertiary);
  margin-bottom: 8px;
}
.trending-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
}
.trending-item {
  font-size: 13px;
  color: var(--text);
}
.trending-item a {
  font-weight: 500;
}
.trending-item .trending-count {
  color: var(--text-tertiary);
  font-size: 12px;
}

/* --- Guest Detail Page --- */
.back-link { font-size: 13px; display: inline-block; margin-bottom: 16px; }
.guest-detail-header { margin-bottom: 20px; }
.guest-detail-title-row { display: flex; align-items: center; gap: 14px; margin-bottom: 4px; }
.guest-detail-title-row h2 { margin-bottom: 0; }
.guest-detail-dates { font-size: 14px; color: var(--text-secondary); }
.guest-detail-subtitle { font-size: 14px; color: var(--text-secondary); margin-top: 2px; }

/* --- Guest Episode Filters --- */
.guest-ep-filters {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.guest-ep-filters select {
  width: auto;
  min-width: 160px;
  padding: 6px 32px 6px 12px;
  font-size: 13px;
  border-radius: var(--radius-full);
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  cursor: pointer;
}
.guest-ep-count { font-size: 13px; color: var(--text-secondary); }

/* --- Guest Show More --- */
.guest-show-more { text-align: center; padding: 12px 0 4px; }
.guest-ep-hidden { display: none; }

/* --- Breakdown Row Artwork + Badge --- */
.bd-row { gap: 10px; }
.bd-art {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: var(--shadow);
}
.bd-subscribed-badge {
  display: inline-block;
  margin-left: 8px;
  padding: 1px 7px;
  border-radius: var(--radius-full);
  background: var(--success-bg);
  color: var(--success);
  font-size: 11px;
  font-weight: 600;
}

/* --- Follow Button --- */
.follow-btn {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
  border-radius: var(--radius-full);
  transition: all 0.15s;
  white-space: nowrap;
}
.follow-btn:hover:not(:disabled) { background: var(--accent); color: white; }
.follow-btn.following {
  background: var(--accent-light);
  color: var(--accent-text);
  border-color: var(--accent-light);
}
.follow-btn.following:hover:not(:disabled) {
  background: var(--error-bg);
  color: transparent;
  border-color: var(--error-bg);
  position: relative;
}
.follow-btn.following:hover:not(:disabled)::after {
  content: "Unfollow";
  color: var(--error);
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Following section: always show "Unfollow" instead of "Following" */
#following-section .follow-btn.following {
  color: transparent;
  position: relative;
}
#following-section .follow-btn.following::after {
  content: "Unfollow";
  color: var(--accent-text);
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
#following-section .follow-btn.following:hover:not(:disabled)::after {
  color: var(--error);
}

/* --- Follow Button (inline / xs variant) --- */
.follow-btn-xs { padding: 4px 10px; font-size: 12px; line-height: 1; }

/* --- Guest Search (global dropdown) --- */
.guest-search-wrap { position: relative; margin-bottom: 16px; z-index: 10; }
.guest-search-wrap input { width: 100%; font-size: 16px; padding: 12px 16px; }
.guest-search-dropdown {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 50;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-md); max-height: 400px; overflow-y: auto; margin-top: 4px;
}
.guest-dropdown-header {
  padding: 10px 16px 6px; font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.5px; color: var(--text-tertiary);
}
.guest-dropdown-row {
  display: flex; align-items: center; gap: 12px; padding: 10px 16px;
  transition: background 0.1s;
}
.guest-dropdown-row:hover { background: var(--bg-page); }
.guest-dropdown-info { flex: 1; min-width: 0; text-decoration: none; color: inherit; }
.guest-dropdown-name { font-weight: 600; font-size: 14px; }
.guest-dropdown-meta { font-size: 12px; color: var(--text-secondary); margin-top: 1px; }

/* --- Following Section (Guests page) — Intel Cards --- */
.following-section { margin-bottom: 16px; }
.following-card {
  flex-shrink: 0;
  width: 260px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  cursor: default;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
@media (hover: hover) { .following-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-card-hover); } }
.following-card-header { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.following-card-name { flex: 1; min-width: 0; font-weight: 600; font-size: 14px; color: var(--text); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.following-card-name:hover { color: var(--accent); }
.following-card-meta { font-size: 12px; color: var(--text-secondary); margin-bottom: 8px; white-space: nowrap; }
.following-card-podcasts { display: flex; gap: 6px; margin-bottom: 8px; }
.following-card-art { width: 32px; height: 32px; border-radius: 6px; object-fit: cover; box-shadow: var(--shadow-card); }
.following-card-latest { font-size: 12px; color: var(--text-tertiary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.following-empty-icon { font-size: 28px; margin-bottom: 8px; }
.following-empty-hint { font-size: 12px; color: var(--text-tertiary); margin-top: 4px; }

/* --- Search Results (Onboarding / Modal) --- */
.search-result {
  display: flex;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  align-items: center;
  margin-bottom: 8px;
  transition: border-color 0.15s, box-shadow 0.25s var(--ease-out-expo);
}
.search-result:hover { border-color: var(--accent); box-shadow: 0 2px 12px rgba(124,58,237,0.1); }
.search-result-info { flex: 1; min-width: 0; }
.search-result-name { font-weight: 600; font-size: 14px; }
.search-result-meta { font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.search-result-desc {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
}

/* --- Subscription Thumbnails (Onboarding) --- */
.sub-thumbs { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.sub-thumb { width: 48px; height: 48px; border-radius: 8px; object-fit: cover; box-shadow: var(--shadow); }

/* --- Settings Subscription Item --- */
.sub-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 8px;
  margin: 0 -8px;
  border-bottom: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  transition: background 0.15s ease;
}
@media (hover: hover) { .sub-item:hover { background: var(--border-light); } }
.sub-item:last-child { border-bottom: none; }
.sub-item-info { flex: 1; min-width: 0; }
.sub-item-title { font-weight: 500; font-size: 14px; }

/* --- Filters Bar --- */
.filters {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.filters select, .filters input { width: auto; min-width: 120px; }
.filters select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 32px;
  border-radius: var(--radius-full);
  cursor: pointer;
}
#ep-search { max-width: 200px; }
.filter-toggle {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: var(--bg-card);
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all 0.15s;
}
.filter-toggle:hover { border-color: var(--accent); color: var(--accent); box-shadow: 0 0 0 3px rgba(124,58,237,0.08); }
.filter-toggle.active { background: var(--accent-light); color: var(--accent-text); border-color: var(--accent-light); }

/* --- Confirm Modal --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 20px;
}
.modal {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 24px;
  width: 100%;
  max-width: 480px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
}
.modal h3 { margin-bottom: 8px; font-size: 18px; }
.modal p { color: var(--text-secondary); font-size: 14px; margin-bottom: 20px; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; }

/* --- Search Modal --- */
.search-modal { max-width: 560px; max-height: 80vh; overflow-y: auto; }
.search-modal input { margin-bottom: 12px; }
.search-modal-results { max-height: 400px; overflow-y: auto; }

/* ================================================================
   LANDING PAGE
   ================================================================ */
.landing {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* --- Section Kicker (reusable) --- */
.section-kicker {
  display: block;
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--accent);
  margin-bottom: 12px;
}
.section-subtitle {
  text-align: center;
  font-size: 16px;
  color: var(--text-secondary);
  max-width: 480px;
  margin: -24px auto 40px;
  line-height: 1.6;
}

/* --- Top Bar (transparent over dark hero) --- */
.landing-topbar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: transparent;
  border-bottom: none;
  padding: 0 24px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.landing-topbar img { height: 28px; }
.landing-topbar-right { display: flex; align-items: center; gap: 16px; }
.landing-topbar-right a {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  transition: color 0.15s;
}
.landing-topbar-right a:hover { color: #fff; text-decoration: none; }
.landing-topbar-right .btn {
  padding: 8px 20px;
  font-size: 14px;
  color: #fff;
  background: rgba(124,58,237,0.4);
  border: 1px solid rgba(124,58,237,0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.landing-topbar-right .btn:hover {
  background: rgba(124,58,237,0.6);
  color: #fff;
  text-decoration: none;
}

/* --- Hero (dark with gradient glow) --- */
.landing-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 140px 20px 80px;
  background: var(--hero-bg);
  overflow: hidden;
}
.landing-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--hero-glow);
  pointer-events: none;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  background: rgba(124,58,237,0.15);
  border: 1px solid rgba(124,58,237,0.25);
  font-size: 13px;
  font-weight: 500;
  color: var(--hero-text-secondary);
  margin-bottom: 24px;
  position: relative;
}
.hero-badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
}
.landing h1 {
  font-size: 56px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.025em;
  max-width: 720px;
  margin-bottom: 16px;
  color: var(--hero-text);
  position: relative;
}
.landing h1 .gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.landing .subhead {
  font-size: 18px;
  color: var(--hero-text-secondary);
  max-width: 520px;
  margin-bottom: 36px;
  line-height: 1.6;
  position: relative;
}
.hero-ctas {
  display: flex;
  gap: 12px;
  align-items: center;
  position: relative;
}
.hero-ctas .btn-primary {
  padding: 14px 32px;
  font-size: 16px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-glow);
}
.hero-ctas .btn-outline-white {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 32px;
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--radius);
  background: transparent;
  color: rgba(255,255,255,0.85);
  border: 1.5px solid rgba(255,255,255,0.25);
  cursor: pointer;
  transition: all 0.15s;
  text-decoration: none;
}
.hero-ctas .btn-outline-white:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.4);
  color: #fff;
  text-decoration: none;
}

/* --- Section Fade (dark → light transition) --- */
.section-fade {
  height: 120px;
  background: linear-gradient(to bottom, var(--hero-bg), var(--bg));
  pointer-events: none;
}

.login-switch {
  margin-top: 16px;
  font-size: 14px;
  color: var(--text-secondary);
  text-align: center;
}
.login-switch a { color: var(--accent); text-decoration: none; font-weight: 500; }
.login-switch a:hover { text-decoration: underline; }
.auth-logo { display: block; text-align: center; margin-bottom: 24px; }
.auth-logo:hover { opacity: 0.8; }
.google-auth-loading {
  position: absolute;
  inset: 0;
  background: rgba(24, 24, 27, 0.92);
  border-radius: inherit;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

/* --- Features (2x2 grid with hover) --- */
.landing-features {
  padding: 60px 20px 80px;
  background: var(--bg);
}
.landing-features h2 {
  text-align: center;
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 40px;
  color: var(--text);
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  max-width: 800px;
  margin: 0 auto;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: left;
  transition: transform 0.25s var(--ease-out-expo), box-shadow 0.25s var(--ease-out-expo), border-color 0.25s;
}
@media (hover: hover) {
  .feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(124,58,237,0.25);
  }
}
.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin-bottom: 16px;
  transition: background 0.25s;
}
@media (hover: hover) {
  .feature-card:hover .feature-icon {
    background: rgba(124,58,237,0.15);
  }
}
.feature-card h3 { font-size: 18px; font-weight: 600; margin-bottom: 8px; color: var(--text); }
.feature-card p { font-size: 15px; color: var(--text-secondary); line-height: 1.65; }

/* --- How It Works (timeline with connecting line) --- */
.landing-how-it-works {
  padding: 60px 20px 80px;
}
.landing-how-it-works h2 {
  text-align: center;
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 40px;
  color: var(--text);
}
.how-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  max-width: 860px;
  margin: 0 auto;
  position: relative;
}
/* Connecting line behind circles */
.how-steps::before {
  content: '';
  position: absolute;
  top: 20px;
  left: calc(16.67% + 20px);
  right: calc(16.67% + 20px);
  height: 2px;
  background: linear-gradient(90deg, var(--accent-light), var(--accent), var(--accent-light));
  z-index: 0;
}
.how-step {
  text-align: center;
  position: relative;
}
.how-step-number-wrap {
  position: relative;
  z-index: 1;
  display: inline-block;
  background: var(--bg);
  border-radius: var(--radius-full);
  padding: 4px;
  margin-bottom: 16px;
}
.how-step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--accent);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  box-shadow: 0 0 0 4px var(--accent-light);
  transition: box-shadow 0.3s var(--ease-out-expo);
}
@media (hover: hover) {
  .how-step:hover .how-step-number {
    box-shadow: 0 0 0 8px var(--accent-light);
  }
}
.how-step h3 { font-size: 17px; font-weight: 600; margin-bottom: 8px; color: var(--text); }
.how-step p { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }

/* --- Social Proof --- */
.landing-social-proof {
  padding: 48px 20px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.social-proof-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 48px;
  max-width: 680px;
  margin: 0 auto;
}
.social-proof-stat {
  text-align: center;
}
.social-proof-stat .sp-value {
  font-size: 32px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}
.social-proof-stat .sp-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
}
.social-proof-divider {
  width: 1px;
  height: 48px;
  background: var(--border);
  flex-shrink: 0;
}

/* --- Pricing Preview --- */
.landing-pricing {
  padding: 60px 20px 80px;
  background: var(--bg);
}
.landing-pricing h2 {
  text-align: center;
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text);
}
.pricing-badge {
  text-align: center;
  font-size: 14px;
  color: var(--accent-text);
  background: var(--accent-light);
  display: inline-block;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  margin: 0 auto 40px;
}
.pricing-badge-wrap { text-align: center; }
.pricing-cards {
  display: flex;
  gap: 24px;
  max-width: 680px;
  margin: 0 auto;
  justify-content: center;
}
.pricing-card {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 32px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform 0.25s var(--ease-out-expo), box-shadow 0.25s var(--ease-out-expo);
}
@media (hover: hover) {
  .pricing-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
  }
}
.pricing-card-highlight {
  border: 2px solid var(--accent);
  box-shadow: var(--shadow-md);
}
.pricing-popular {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: var(--radius-full);
  white-space: nowrap;
}
.pricing-card h3 { font-size: 20px; font-weight: 700; margin-bottom: 4px; color: var(--text); }
.pricing-card .pricing-label { font-size: 13px; color: var(--text-secondary); margin-bottom: 20px; }
.pricing-card ul {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  flex: 1;
}
.pricing-card ul li {
  font-size: 14px;
  color: var(--text);
  padding: 6px 0;
  line-height: 1.5;
}
.pricing-card ul li::before {
  content: "\2713";
  color: var(--success);
  font-weight: 700;
  margin-right: 8px;
}
.pricing-card-highlight ul li::before {
  color: var(--accent);
}
.pricing-card .btn { width: 100%; text-align: center; justify-content: center; }
.pricing-card .btn-ghost { background: transparent; color: var(--text-secondary); border: 1px solid var(--border); }
.pricing-card .btn-ghost:hover { background: var(--border-light); color: var(--text); }
.pricing-card-highlight .btn-primary {
  box-shadow: var(--shadow-glow);
}

/* --- FAQ Accordion --- */
.landing-faq {
  padding: 60px 20px 80px;
}
.landing-faq h2 {
  text-align: center;
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 40px;
  color: var(--text);
}
.faq-list {
  max-width: 680px;
  margin: 0 auto;
}
.faq-item {
  border-bottom: 1px solid var(--border);
}
.faq-item:first-child {
  border-top: 1px solid var(--border);
}
.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  transition: color 0.15s;
  font-family: inherit;
}
.faq-question:hover {
  color: var(--accent);
}
.faq-icon {
  font-size: 20px;
  font-weight: 300;
  color: var(--text-tertiary);
  transition: transform 0.3s var(--ease-out-expo);
  flex-shrink: 0;
  line-height: 1;
}
.faq-item.open .faq-icon {
  transform: rotate(45deg);
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s var(--ease-out-expo);
}
.faq-answer-inner {
  padding: 0 0 20px;
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* --- Bottom CTA (dark, mirrors hero) --- */
.landing-bottom-cta {
  text-align: center;
  padding: 80px 20px;
  background: var(--hero-bg);
  position: relative;
  overflow: hidden;
}
.landing-bottom-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 60% at 50% 70%, rgba(124,58,237,0.15) 0%, transparent 70%);
  pointer-events: none;
}
.landing-bottom-cta h2 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--hero-text);
  position: relative;
}
.landing-bottom-cta .cta-subtitle {
  font-size: 16px;
  color: var(--hero-text-secondary);
  margin-bottom: 32px;
  position: relative;
}
.landing-bottom-cta .btn-primary {
  position: relative;
  box-shadow: var(--shadow-glow);
}

/* --- Footer (on dark background) --- */
.landing-footer {
  text-align: center;
  padding: 32px 20px;
  background: var(--hero-bg);
  border-top: 1px solid rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.35);
  font-size: 13px;
}
.landing-footer img {
  height: 24px;
  display: block;
  margin: 0 auto 8px;
  opacity: 0.4;
}
.landing-footer-links {
  margin-top: 12px;
}
.landing-footer-links a {
  color: rgba(255,255,255,0.5);
  text-decoration: none;
  font-size: 12px;
  transition: color 0.15s;
}
.landing-footer-links a:hover {
  color: rgba(255,255,255,0.7);
}
.landing-footer-sep {
  margin: 0 8px;
  color: rgba(255,255,255,0.2);
}

/* ================================================================
   LEGAL PAGES (Terms of Service / Privacy Policy)
   ================================================================ */
.legal-page {
  min-height: 100vh;
  background: var(--bg);
}
.legal-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
}
.legal-topbar img {
  height: 28px;
}
.legal-topbar-home {
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-tertiary);
  transition: color 0.15s;
}
.legal-topbar-home:hover {
  color: var(--accent);
}

.legal-tabs {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin: 40px auto 0;
  max-width: 680px;
  padding: 0 24px;
}
.legal-tab {
  padding: 10px 24px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  color: var(--text-secondary);
  border: 1px solid var(--border);
  background: transparent;
}
.legal-tab:hover {
  background: var(--border-light);
  color: var(--text);
}
.legal-tab.active {
  background: var(--accent);
  color: #ffffff;
  border-color: transparent;
}

.legal-body {
  max-width: 680px;
  margin: 0 auto;
  padding: 40px 24px 60px;
}
.legal-body h1 {
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}
.legal-effective {
  font-size: 13px;
  color: var(--text-tertiary);
  margin-bottom: 32px;
}

.legal-callout {
  background: var(--accent-light);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 20px 24px;
  margin-bottom: 32px;
}
.legal-callout-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}
.legal-callout p {
  font-size: 14px;
  line-height: 1.7;
  color: var(--accent-text);
  margin: 0;
}

.legal-section {
  margin-top: 40px;
}
.legal-body h2 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 16px;
}
.legal-body h2 span {
  color: var(--accent);
  margin-right: 8px;
}
.legal-body p {
  font-size: 15px;
  line-height: 1.75;
  color: var(--text-secondary);
  margin-bottom: 14px;
}
.legal-body ul {
  padding-left: 24px;
  margin-bottom: 16px;
}
.legal-body li {
  font-size: 15px;
  line-height: 1.75;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.legal-body li::marker {
  color: var(--accent);
}
.legal-body a {
  color: var(--accent);
  text-decoration: none;
}
.legal-body a:hover {
  text-decoration: underline;
}

.legal-contact {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.legal-contact p {
  font-size: 14px;
  color: var(--text-secondary);
}
.legal-contact a {
  color: var(--accent);
  font-weight: 500;
}

.legal-footer {
  text-align: center;
  padding: 24px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-tertiary);
  margin-top: 20px;
}
.legal-footer a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s;
}
.legal-footer a:hover {
  color: var(--accent);
}
.legal-footer span {
  margin: 0 8px;
}

/* --- Landing responsive (768px) --- */
@media (max-width: 768px) {
  .landing h1 { font-size: 36px; }
  .landing .subhead { font-size: 16px; }
  .landing-hero { padding: 120px 20px 60px; }
  .hero-ctas { flex-direction: column; width: 100%; max-width: 340px; }
  .hero-ctas .btn-primary,
  .hero-ctas .btn-outline-white { width: 100%; justify-content: center; }
  .section-fade { height: 80px; }
  .features-grid { grid-template-columns: 1fr; max-width: 440px; }
  .how-steps { grid-template-columns: 1fr; gap: 24px; max-width: 400px; }
  .how-steps::before { display: none; }
  .how-step-number-wrap { background: var(--bg-card); }
  .pricing-cards { flex-direction: column; max-width: 400px; margin: 0 auto; }
  .social-proof-row { flex-direction: column; gap: 24px; }
  .social-proof-divider { width: 48px; height: 1px; }
  .section-subtitle { margin-bottom: 32px; }
  .landing-features h2,
  .landing-how-it-works h2,
  .landing-pricing h2,
  .landing-bottom-cta h2,
  .landing-faq h2 { font-size: 28px; }

  /* Legal pages */
  .legal-body { padding: 32px 16px 48px; }
  .legal-body h1 { font-size: 24px; }
  .legal-tabs { margin-top: 24px; }
  .legal-tab { padding: 8px 20px; font-size: 13px; }
}

/* ================================================================
   SIGNUP PAGE
   ================================================================ */
.signup-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 40px);
  padding: 20px;
}
.signup-card {
  width: 100%;
  max-width: 420px;
}
.signup-card h2 { text-align: center; margin-bottom: 4px; }
.signup-card .subtitle { text-align: center; color: var(--text-secondary); font-size: 14px; margin-bottom: 24px; }
.signup-card .form-group { margin-bottom: 16px; }
.signup-card .btn { width: 100%; margin-top: 8px; }
.signup-card .login-link { text-align: center; margin-top: 16px; font-size: 13px; color: var(--text-secondary); }

/* --- Password Toggle (show/hide eye icon) --- */
.form-group-password { position: relative; }
.form-group-password input { padding-right: 40px; }
.password-toggle { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); background: none; border: none; color: var(--text-tertiary); cursor: pointer; padding: 4px; font-size: 16px; line-height: 1; }
.password-toggle:hover { color: var(--text-secondary); }

/* Reserve space for Google Sign-In to prevent layout shift (CLS) */
.google-signin-placeholder { min-height: 96px; }

/* --- Auth Divider + Google Button --- */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--text-tertiary);
  font-size: 13px;
}
.auth-divider::before, .auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.btn-google {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.15s;
  background: var(--bg-card);
  color: var(--text);
}
.btn-google:hover:not(:disabled) { background: var(--border-light); border-color: var(--text-tertiary); }
.btn-google:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-google svg { flex-shrink: 0; }

/* ================================================================
   ONBOARDING PAGE
   ================================================================ */
.onboarding-step {
  text-align: center;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  background: var(--accent-light);
  color: var(--accent-text);
  font-size: 12px;
  font-weight: 600;
  display: inline-block;
  margin-bottom: 16px;
}
.onboarding-header { text-align: center; margin-bottom: 24px; }
.onboarding-header h2 { margin-bottom: 4px; }
.onboarding-header p { color: var(--text-secondary); font-size: 14px; }
.onboarding-subscribed { margin-top: 20px; }
.onboarding-subscribed h4 { font-size: 13px; color: var(--text-secondary); margin-bottom: 8px; }
.onboarding-continue { text-align: center; margin-top: 24px; }

/* --- Featured Grid (Onboarding) --- */
.onboarding-wrap { max-width: 800px; margin: 0 auto; padding-bottom: 100px; }
.onboarding-search-wrap { position: relative; margin-bottom: 24px; }
.onboarding-search-results {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 50;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-md); max-height: 400px; overflow-y: auto; margin-top: 4px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.featured-section { margin-bottom: 28px; }
.featured-section-label {
  font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px;
  color: var(--text-secondary); margin-bottom: 12px; display: flex; align-items: center; gap: 8px;
}
.featured-section-emoji { font-size: 18px; }
.featured-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px;
}
.featured-card {
  position: relative; border: 2px solid var(--border); border-radius: var(--radius);
  padding: 12px; text-align: center; cursor: pointer; transition: var(--transition-lift), border-color 0.25s;
  background: var(--bg-card); min-width: 0; overflow: hidden;
}
@media (hover: hover) { .featured-card:hover { border-color: var(--accent); transform: translateY(-3px); box-shadow: 0 8px 24px rgba(124,58,237,0.12); } }
.featured-card.selected {
  border-color: var(--accent); background: var(--accent-light);
}
.featured-card-check {
  position: absolute; top: 8px; right: 8px; width: 24px; height: 24px;
  border-radius: 50%; background: var(--accent); color: white;
  display: none; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 700; line-height: 1;
}
.featured-card.selected .featured-card-check { display: flex; }
.featured-card-art {
  width: 100%; aspect-ratio: 1; border-radius: 10px; object-fit: cover;
  box-shadow: var(--shadow); margin-bottom: 8px; background: var(--border-light);
}
.featured-card-name {
  font-size: 12px; font-weight: 600; line-height: 1.3;
  overflow: hidden; text-overflow: ellipsis; display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.featured-card-author {
  font-size: 11px; color: var(--text-tertiary); margin-top: 2px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* Skeleton shimmer */
.skeleton { position: relative; overflow: hidden; background: var(--border-light); border-radius: var(--radius); }
.skeleton::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
  animation: shimmer 1.5s infinite;
}
@keyframes shimmer { 0% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
.skeleton-card { height: 200px; }
.skeleton-label { height: 16px; width: 120px; margin-bottom: 12px; border-radius: 4px; }

/* Progress bar (sticky bottom) */
.onboarding-progress {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
  background: var(--bg-card); border-top: 1px solid var(--border);
  padding: 16px 20px; box-shadow: 0 -4px 16px rgba(0,0,0,0.08);
}
.onboarding-progress-inner { max-width: 800px; margin: 0 auto; display: flex; align-items: center; gap: 16px; }
.progress-text { font-size: 14px; font-weight: 600; white-space: nowrap; color: var(--text-secondary); }
.progress-bar { flex: 1; height: 8px; background: var(--border-light); border-radius: 4px; overflow: hidden; }
.progress-fill {
  height: 100%; background: var(--accent); border-radius: 4px;
  transition: width 0.3s ease;
  box-shadow: 0 0 8px rgba(124,58,237,0.3);
}
.progress-btn { min-width: 180px; }
.progress-skip { font-size: 13px; color: var(--text-tertiary); white-space: nowrap; }

.onboarding-subscribing {
  display: flex; align-items: center; gap: 14px; width: 100%; justify-content: center;
}
.onboarding-subscribing-text { display: flex; flex-direction: column; gap: 2px; }
.onboarding-subscribing-text strong { font-size: 15px; color: var(--text-primary); }
.onboarding-subscribing-text span { font-size: 13px; color: var(--text-secondary); }

@media (max-width: 768px) {
  .onboarding-wrap { padding-bottom: 120px; }
  .onboarding-progress-inner { flex-wrap: wrap; gap: 10px; }
  .progress-bar { order: 3; width: 100%; flex: none; }
  .progress-btn { flex: 1; }
}

/* ================================================================
   DASHBOARD PAGE
   ================================================================ */
.greeting { font-size: 24px; font-weight: 600; margin-bottom: 24px; }

/* Dashboard section spacing — breathing room between content blocks */
.h-scroll + .section-header { margin-top: 28px; }
.card + .section-header { margin-top: 28px; }

/* Parsing banner (shown after onboarding while feeds are processing) */
.parsing-banner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--accent-light);
  border: 1px solid #c4b5fd;
  border-radius: var(--radius);
  margin-bottom: 24px;
  box-shadow: var(--shadow-card);
}
.parsing-spinner {
  width: 28px;
  height: 28px;
  border: 3px solid #c4b5fd;
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  flex-shrink: 0;
}
.parsing-text { display: flex; flex-direction: column; gap: 2px; }
.parsing-text strong { font-size: 14px; color: var(--accent-text); }
.parsing-text span { font-size: 13px; color: var(--text-secondary); }
.parsing-banner-info { background: #fef3c7; border: 1px solid #fbbf24; border-left: 3px solid #f59e0b; }
.parsing-banner-info .parsing-text strong { color: #92400e; }
.parsing-banner-error { background: #fef2f2; border: 1px solid #fca5a5; border-left: 3px solid #ef4444; }
.parsing-banner-error .parsing-text strong { color: #991b1b; }
.parsing-banner-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; flex-shrink: 0; }
.btn-retry-banner { background: #991b1b; color: white; border: none; padding: 6px 16px; border-radius: var(--radius-sm); font-size: 13px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.btn-retry-banner:hover { background: #7f1d1d; }
.btn-retry-banner:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-dismiss-banner { background: none; border: none; color: #991b1b; font-size: 20px; cursor: pointer; padding: 0 4px; line-height: 1; opacity: 0.6; }
.btn-dismiss-banner:hover { opacity: 1; }
.btn-retry-inline { margin-top: 12px; background: var(--accent); color: white; border: none; padding: 6px 16px; border-radius: var(--radius-sm); font-size: 13px; font-weight: 600; cursor: pointer; }
.btn-retry-inline:hover { background: var(--accent-hover); }
.btn-retry-inline:disabled { opacity: 0.6; cursor: not-allowed; }

/* ================================================================
   SETTINGS PAGE
   ================================================================ */
.settings-section { margin-bottom: 24px; }
.settings-section h3 { font-size: 16px; font-weight: 600; margin-bottom: 12px; }
.settings-info { display: grid; grid-template-columns: 100px 1fr; gap: 8px; font-size: 14px; }
.settings-info dt { color: var(--text-secondary); font-weight: 500; }
.settings-info dd { color: var(--text); }
.settings-heading { margin-bottom: 24px; }

/* --- Security section --- */
.settings-security-hint {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 16px;
}
.settings-security .form-group { margin-bottom: 16px; }
.settings-security .form-group:last-of-type { margin-bottom: 0; }
.settings-pw-requirements {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 4px;
}
.settings-divider {
  height: 1px;
  background: var(--border-light);
  margin: 16px 0;
}
.settings-pw-error {
  display: none;
  color: var(--error);
  font-size: 13px;
  margin-top: 16px;
  margin-bottom: 4px;
}
.settings-pw-submit {
  margin-top: 20px;
}

/* --- Danger Zone --- */
.settings-danger { margin-top: 40px; }
.settings-danger h3 { color: var(--red, #e74c3c); }
.settings-danger-card {
  border: 1px solid var(--red, #e74c3c);
  border-radius: 12px;
}
.settings-danger-desc {
  margin: 0 0 12px;
  font-size: 14px;
  opacity: 0.75;
}

/* ================================================================
   EMAIL REPORTS (Settings)
   ================================================================ */
.email-setup-card {
  text-align: center;
  padding: 32px 24px;
}
.email-setup-card p {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 20px;
  line-height: 1.6;
}

/* --- Email: Top zone (status + send) --- */
.email-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.email-top-left { display: flex; flex-direction: column; gap: 4px; }
.email-status {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}
.email-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.email-dot-on { background: var(--success); }
.email-dot-off { background: var(--text-tertiary); }
.email-status-toggle {
  width: auto;
  min-width: 0;
  padding: 2px 8px;
  font-size: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  background: var(--bg);
  margin-left: 4px;
}
.email-meta {
  font-size: 12px;
  color: var(--text-tertiary);
}
.email-divider {
  height: 1px;
  background: var(--border-light);
  margin: 16px 0;
}

/* --- Email: Schedule zone --- */
.email-section-label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  margin-bottom: 10px;
}
.email-schedule-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.email-schedule-row select { width: auto; min-width: 110px; }
.email-tz { font-size: 12px; color: var(--text-tertiary); }

/* --- Slack teaser --- */
.digest-slack-teaser {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-tertiary);
  opacity: 0.6;
}
.digest-slack-icon { font-size: 18px; }
.badge-coming-soon {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 8px;
  border-radius: 10px;
  background: var(--border-light);
  color: var(--text-tertiary);
}

/* --- Email: Include zone --- */
.email-checkboxes-row {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
.email-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 14px;
  color: var(--text);
}
.email-checkbox input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
  cursor: pointer;
}

/* --- Email: Bottom actions --- */
.email-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

@media (max-width: 768px) {
  .email-top { flex-direction: column; align-items: flex-start; }
  .email-top .btn { width: 100%; }
  .email-checkboxes-row { flex-direction: column; gap: 10px; }
}

/* Email preview modal */
.preview-modal { max-width: 680px; max-height: 85vh; overflow: hidden; display: flex; flex-direction: column; }
.preview-modal h3 { margin-bottom: 4px; }
.preview-modal .preview-subject { font-size: 13px; color: var(--text-secondary); margin-bottom: 12px; }
.preview-frame-wrap {
  flex: 1;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fafaf9;
}
.preview-frame-wrap iframe {
  width: 100%;
  height: 600px;
  border: none;
}

/* Dashboard email nudge */
.email-nudge {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--accent-light);
  border: 1px solid #c4b5fd;
  border-radius: var(--radius);
  margin-bottom: 24px;
  box-shadow: var(--shadow-card);
}
.email-nudge-icon { font-size: 28px; flex-shrink: 0; }
.email-nudge-text { flex: 1; }
.email-nudge-text strong { font-size: 14px; color: var(--accent-text); display: block; margin-bottom: 2px; }
.email-nudge-text span { font-size: 13px; color: var(--text-secondary); }
.email-nudge-actions { display: flex; gap: 8px; flex-shrink: 0; }

/* ================================================================
   DIGEST PAGE
   ================================================================ */
.digest-setup-card {
  max-width: 480px;
  margin: 0 auto;
  text-align: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px 32px;
  box-shadow: var(--shadow-card);
}
.digest-setup-icon { font-size: 40px; margin-bottom: 16px; }
.digest-setup-card h3 { font-size: 20px; font-weight: 600; margin-bottom: 8px; }
.digest-setup-card p {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 24px;
}
.digest-setup-freq {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}
.digest-setup-freq select { width: auto; min-width: 120px; }
.digest-setup-freq label { margin-bottom: 0; }

.digest-controls {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: start;
}
.digest-controls-left { min-width: 0; }
.digest-controls-right { min-width: 0; }
.digest-actions {
  display: flex;
  justify-content: flex-end;
}
.digest-preview-frame {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fafaf9;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
.digest-preview-frame iframe {
  width: 100%;
  height: 500px;
  border: none;
  display: block;
}
.digest-preview-subject {
  padding: 8px 12px;
  font-size: 13px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-light);
  background: var(--bg-card);
}

/* ================================================================
   AHA MOMENT (Dashboard)
   ================================================================ */
.aha-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-card);
  animation: slideIn 0.2s ease-out;
}
.aha-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}
.aha-header strong {
  font-size: 14px;
  color: var(--text);
  font-weight: 600;
}
.aha-dismiss {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-tertiary);
  font-size: 18px;
  line-height: 1;
  padding: 4px;
  border-radius: 4px;
  transition: color 0.15s, background 0.15s;
}
.aha-dismiss:hover { color: var(--text-secondary); background: var(--border-light); }
.aha-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.aha-col-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-tertiary);
  margin-bottom: 6px;
}
.aha-guests-row { }
.aha-guest-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.aha-guest-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: var(--bg-page);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.aha-guest-chip:hover {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}
.aha-guest-chip a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: inherit;
}
.aha-guest-chip strong {
  font-size: 13px;
  font-weight: 600;
}
.aha-guest-chip span {
  font-size: 11px;
  color: var(--text-tertiary);
}
.aha-col { min-width: 0; }
.aha-col .episode-row {
  padding: 8px 0;
  margin: 0;
}
.aha-col .episode-row:first-of-type { padding-top: 0; }
.aha-col .episode-row:last-child { border-bottom: none; }
.aha-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-light);
}
.aha-footer span {
  font-size: 13px;
  color: var(--text-secondary);
}
.aha-analyzing-body {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 8px 0;
}
.aha-analyzing-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.aha-analyzing-text strong {
  font-size: 14px;
  color: var(--text);
}
.aha-analyzing-text span {
  font-size: 13px;
  color: var(--text-secondary);
}

/* ================================================================
   FOLLOWED GUEST ACTIVITY (Dashboard hero section)
   ================================================================ */
.followed-activity {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-card);
  animation: slideIn 0.2s ease-out;
}
.fa-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.fa-header strong { font-size: 14px; color: var(--text); font-weight: 600; }
.fa-header a { font-size: 13px; color: var(--accent); text-decoration: none; }
.fa-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border-light);
}
.fa-row:last-of-type { border-bottom: none; }
.fa-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  letter-spacing: -0.3px;
}
.fa-avatar-img {
  border-radius: 50%;
  object-fit: cover;
  object-position: center 20%;
  flex-shrink: 0;
  display: block;
}
.fa-row-body { min-width: 0; flex: 1; }
.fa-row-top {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 2px;
}
.fa-guest-name { font-size: 14px; font-weight: 600; color: var(--text); text-decoration: none; }
.fa-guest-name:hover { color: var(--accent); }
.fa-guest-stats { font-size: 12px; color: var(--text-tertiary); }
.fa-row-podcast {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 2px;
}
.fa-row-date {
  font-weight: 400;
  color: var(--text-tertiary);
}
.fa-row-episode {
  font-size: 13px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 1px;
}
.fa-row-episode a { color: inherit; text-decoration: none; }
.fa-row-episode a:hover { color: var(--accent); }
.fa-row-summary {
  display: flex;
  align-items: baseline;
  gap: 5px;
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 4px;
  overflow: hidden;
}
.fa-summary-icon {
  flex-shrink: 0;
  color: var(--accent);
  font-size: 10px;
}
.fa-summary-text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fa-row-seeall {
  margin-top: 4px;
}
.fa-row-seeall a {
  font-size: 12px;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
}
.fa-row-seeall a:hover { text-decoration: underline; }
.fa-suggestions {
  border-top: 1px dashed var(--border-light);
  margin-top: 14px;
  padding-top: 12px;
}
.fa-suggestions-label {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-bottom: 8px;
  font-weight: 500;
}
.fa-suggestion-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.fa-suggestion-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px 6px 12px;
  background: var(--bg-page);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: border-color 0.15s;
}
.fa-suggestion-chip:hover { border-color: var(--accent); }
.fa-suggestion-name { font-size: 13px; color: var(--text); font-weight: 500; }
.fa-suggestion-name a { color: inherit; text-decoration: none; }
.fa-suggestion-name a:hover { color: var(--accent); }
.fa-suggestion-stats { font-size: 11px; color: var(--text-tertiary); }

/* "New" badge on recent guest activity */
.fa-new-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #fff;
  background: var(--accent);
  padding: 1px 6px;
  border-radius: 4px;
  margin-left: 6px;
  vertical-align: middle;
}

/* Quiet section (collapsed toggle + compact rows) */
.fa-quiet-section {
  border-top: 1px dashed var(--border);
  margin-top: 12px;
  padding-top: 8px;
}
.fa-quiet-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 0;
  font-size: 13px;
  color: var(--text-secondary);
  width: 100%;
}
.fa-quiet-toggle:hover { color: var(--text); }
.fa-quiet-count {
  font-size: 11px;
  background: var(--bg-page);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1px 7px;
  color: var(--text-tertiary);
}
.fa-quiet-arrow {
  margin-left: auto;
  transition: transform 0.2s;
  font-size: 11px;
  color: var(--text-tertiary);
}
.fa-quiet-open .fa-quiet-arrow { transform: rotate(180deg); }
.fa-quiet-list {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.2s ease;
}
.fa-quiet-open .fa-quiet-list { max-height: 500px; }

/* Compact rows inside quiet section */
.fa-row-quiet {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
}
.fa-row-quiet .guest-avatar { width: 28px; height: 28px; font-size: 11px; flex-shrink: 0; }
.fa-row-quiet .guest-avatar img { width: 28px; height: 28px; }
.fa-quiet-body {
  display: flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
  flex: 1;
}
.fa-quiet-body a { color: var(--text); text-decoration: none; font-size: 13px; font-weight: 500; white-space: nowrap; }
.fa-quiet-body a:hover { color: var(--accent); }
.fa-quiet-meta {
  font-size: 12px;
  color: var(--text-tertiary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* All-quiet empty state */
.fa-all-quiet {
  text-align: center;
  padding: 20px 12px;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
}

.fa-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-light);
}
.fa-footer span { font-size: 13px; color: var(--text-secondary); }

/* Hamburger backdrop overlay */
.topnav nav.open::before {
  content: '';
  position: fixed;
  inset: 0;
  top: var(--nav-height);
  background: rgba(0,0,0,0.3);
  z-index: -1;
}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 768px) {
  /* Hide hamburger + dropdown — replaced by tab bar + gear */
  .hamburger { display: none; }
  .topnav nav { display: none !important; }
  .nav-signout { display: none; }
  .nav-signout-mobile { display: none; }

  /* Show gear icon in top bar */
  .topnav-gear { display: flex; align-items: center; }

  /* Show bottom tab bar */
  .tab-bar:not(.tab-bar-hidden) {
    display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
    background: var(--nav-bg); border-top: 1px solid var(--nav-border);
    height: calc(var(--tab-bar-height) + env(safe-area-inset-bottom, 0px));
    padding-bottom: env(safe-area-inset-bottom, 0px);
    flex-direction: row; align-items: stretch; justify-content: space-around;
  }

  /* Content padding so nothing hides behind tab bar */
  main { padding-bottom: calc(var(--tab-bar-height) + env(safe-area-inset-bottom, 0px) + 16px); }

  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .filters { flex-direction: column; }
  .filters select, .filters input { width: 100%; }
  #ep-search { max-width: none; }

  .episode-row { flex-direction: column; align-items: stretch; }
  .episode-row:has(.ep-art) { flex-direction: row; align-items: flex-start; }
  .podcast-art-sm { display: none; }

  /* Digest page — single column on tablet */
  .digest-controls { grid-template-columns: 1fr; }
  .digest-actions { flex-direction: column; }
  .digest-actions .btn { width: 100%; }
  .digest-preview-frame iframe { height: 400px; }
}

@media (max-width: 480px) {
  main { padding: 16px 12px calc(var(--tab-bar-height) + env(safe-area-inset-bottom, 0px) + 16px); }
  .card { padding: 16px; }
  .stats-row { grid-template-columns: 1fr 1fr; gap: 8px; }
  .stat-card .stat-value { font-size: 20px; }

  /* Typography — scale down */
  .landing h1 { font-size: 28px; }
  .landing-hero { padding: 100px 16px 48px; }
  .hero-badge { font-size: 12px; padding: 5px 12px; }
  .section-fade { height: 60px; }
  .landing-features,
  .landing-how-it-works,
  .landing-pricing,
  .landing-bottom-cta,
  .landing-faq { padding: 48px 16px; }
  .feature-card { padding: 20px 16px; }
  .pricing-card { padding: 24px 20px; }
  .landing-topbar { padding: 0 16px; }
  .landing-topbar-right { gap: 10px; }
  .landing-topbar-right .btn { padding: 6px 14px; font-size: 13px; }
  .landing-topbar-right a { font-size: 13px; }
  .faq-question { font-size: 15px; }
  .legal-callout { padding: 16px 18px; }
  .landing-features h2,
  .landing-how-it-works h2,
  .landing-pricing h2,
  .landing-bottom-cta h2,
  .landing-faq h2 { font-size: 24px; }
  .section-subtitle { font-size: 14px; margin-bottom: 28px; }
  .greeting { font-size: 20px; }
  .onboarding-header h2 { font-size: 22px; }

  /* Podcast cards — shrink */
  .podcast-card { width: 100px; }
  .podcast-card img { width: 100px; height: 100px; border-radius: 8px; }
  .pc-title { font-size: 11px; }
  .pc-badge { font-size: 10px; }

  /* Featured grid — tighter */
  .featured-grid { gap: 8px; }
  .featured-card { padding: 8px; }
  .featured-card-art { border-radius: 8px; margin-bottom: 4px; }
  .featured-card-name { font-size: 11px; }
  .featured-card-author { font-size: 10px; }

  /* Spacing — tighter */
  .section-header { gap: 8px; }
  .h-scroll { gap: 8px; }

  /* Episode artwork — shrink */
  .ep-art { width: 40px; height: 40px; }

  /* Touch targets — 44px minimum */
  .btn { padding: 12px 20px; }
  .btn-sm { padding: 10px 14px; }
  .follow-btn-xs { padding: 8px 12px; }
  .hamburger { padding: 10px; }
  .topnav nav a { padding: 14px; }
  .guest-tag { padding: 6px 12px; }
  .filter-toggle { padding: 10px 16px; }

  /* Navigation — better hamburger UX */
  .topnav-inner { gap: 16px; }

  /* Modals — prevent viewport overflow */
  .modal { padding: 16px; max-width: calc(100vw - 24px); }
  .search-modal { max-width: calc(100vw - 24px); }
  .preview-modal { max-width: calc(100vw - 24px); }
  .preview-frame-wrap iframe { height: min(600px, 60vh); }

  /* Toasts — reposition to bottom on mobile, above tab bar */
  .toast-container {
    top: auto;
    bottom: calc(var(--tab-bar-height) + env(safe-area-inset-bottom, 0px) + 12px);
    left: 12px;
    right: 12px;
  }
  .toast { text-align: center; }

  /* Onboarding progress — full-width controls */
  .progress-btn { width: 100%; }
  .progress-skip { width: 100%; text-align: center; }
  .progress-text { width: 100%; text-align: center; }

  /* Search results dropdown — limit height (dvh accounts for mobile keyboard) */
  .onboarding-search-results { max-height: 50vh; max-height: 50dvh; }
  .guest-search-dropdown { max-height: 50vh; max-height: 50dvh; }

  /* Guest rows — stack on small screens */
  .guest-row { flex-direction: column; align-items: stretch; gap: 4px; }
  .guest-row-detail { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }

  /* Artwork placeholders — shrink with cards */
  .podcast-card-placeholder { width: 100px; height: 100px; border-radius: 8px; font-size: 32px; }

  /* Following cards — shrink on mobile */
  .following-card { width: 220px; padding: 12px; }

  /* Podcast header — stack artwork above info on mobile */
  .podcast-header { flex-direction: column; }
  .podcast-header .podcast-art-lg { width: 64px; height: 64px; }
  .podcast-header .ph-title-row { flex-direction: column; align-items: flex-start; gap: 8px; }
  .ph-actions { align-self: stretch; }
  .ph-actions .btn { flex: 1; }

  /* Trending — wrap on mobile */
  .trending-list { gap: 4px 12px; }
  .trending-item { font-size: 12px; }

  /* AI summaries — smaller on mobile */
  .episode-summary-preview { font-size: 11.5px; }
  .episode-summary-full { font-size: 11.5px; }
  .summary-more { font-size: 10.5px; }

  /* Aha section — mobile tweaks */
  .aha-guest-chips { flex-direction: column; }
  .aha-guest-chip { display: flex; }
  .aha-guest-chip .follow-btn { margin-left: auto; }
  .aha-footer { flex-direction: column; align-items: flex-start; }

  /* Followed activity — mobile tweaks */
  .fa-footer { flex-direction: column; align-items: flex-start; }
  .fa-suggestion-chips { flex-direction: column; }
  .fa-suggestion-chip { display: flex; }
  .fa-avatar { width: 36px; height: 36px; font-size: 13px; }
  .fa-row-summary { font-size: 11px; }

  /* Guest profile — mobile tweaks */
  .guest-ep-filters { flex-direction: column; align-items: stretch; gap: 8px; }
  .guest-ep-filters select { width: 100%; }
  .guest-detail-subtitle { font-size: 13px; }
  .bd-row { flex-wrap: wrap; }
  .bd-art { width: 28px; height: 28px; }

  /* Settings security — full-width button on mobile */
  .settings-pw-submit { width: 100%; }

  /* Settings subscriptions — stack unsubscribe buttons */
  .sub-item { gap: 8px; }

  /* Email nudge — stack on mobile */
  .email-nudge { flex-direction: column; text-align: center; }
  .email-nudge-actions { width: 100%; justify-content: center; }
  .email-nudge-actions .btn { flex: 1; }

  /* Digest preview — shorter on mobile */
  .digest-preview-frame iframe { height: min(400px, 50vh); }
  .digest-setup-card { padding: 24px 16px; }
}

/* Very small phones (iPhone SE, Galaxy S) */
@media (max-width: 380px) {
  main { padding: 12px 8px calc(var(--tab-bar-height) + env(safe-area-inset-bottom, 0px) + 12px); }
  .card { padding: 12px; }
  .landing-topbar { padding: 0 12px; }
  .landing-topbar-right { gap: 8px; }
  .landing-topbar-right .btn { padding: 5px 10px; font-size: 12px; }

  .podcast-card { width: 80px; }
  .podcast-card img { width: 80px; height: 80px; border-radius: 6px; }
  .podcast-card-placeholder { width: 80px; height: 80px; border-radius: 6px; font-size: 28px; }

  /* Episode artwork — shrink further */
  .ep-art { width: 36px; height: 36px; border-radius: 6px; }

  /* Modals — tighter on tiny screens */
  .modal { padding: 14px; }
  .modal-actions { flex-direction: column; }
  .modal-actions .btn { width: 100%; }
  .preview-frame-wrap iframe { height: min(500px, 50vh); }

  /* Digest preview — cap height */
  .digest-preview-frame iframe { height: min(300px, 40vh); }
}

/* --- Usage Labels (subscription/follow limits) --- */
.usage-label { font-size: 13px; font-weight: 500; color: var(--text-secondary); }
.usage-label-warn { color: var(--warning); }
.usage-label-full { color: var(--error); font-weight: 600; }
.btn-limit-reached { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

/* --- Feedback --- */

/* Compose card */
.fb-compose-card {
  border: 1px solid var(--border); border-radius: 10px;
  background: var(--bg-card); overflow: hidden;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.fb-compose-card:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.08);
}
.fb-compose-input {
  width: 100%; border: none; padding: 14px 16px 8px;
  background: transparent; color: var(--text); font-size: 14px;
  font-family: inherit; resize: none; outline: none;
  line-height: 1.55; min-height: 44px;
}
.fb-compose-footer {
  display: flex; justify-content: flex-end; align-items: center; gap: 10px;
  padding: 6px 12px 10px;
}
.fb-char-count { font-size: 11px; font-weight: 500; }
.fb-success {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 18px; color: var(--success); font-weight: 500; font-size: 14px;
}

/* List header */
.fb-list-header {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 600; color: var(--text-secondary);
  text-transform: uppercase; letter-spacing: 0.04em;
  margin-top: 20px; margin-bottom: 10px; padding: 0 2px;
}
.fb-list-count {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 20px; height: 18px; padding: 0 6px;
  border-radius: 9px; font-size: 11px; font-weight: 600;
  background: var(--border-light); color: var(--text-secondary);
}

/* Item list */
.fb-list { display: flex; flex-direction: column; gap: 6px; }

.fb-item {
  padding: 12px 16px; border-radius: 10px; cursor: pointer;
  background: var(--bg-card); border: 1px solid var(--border);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.fb-item:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.fb-item.fb-expanded {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), var(--shadow);
}

/* Item row: status + replies left, time right */
.fb-item-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 6px; gap: 8px;
}
.fb-item-left { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-width: 0; }
.fb-item-time { font-size: 12px; color: var(--text-tertiary); white-space: nowrap; flex-shrink: 0; }

/* Status pills */
.fb-status {
  font-size: 11px; font-weight: 600; letter-spacing: 0.03em;
  padding: 2px 8px; border-radius: 10px; white-space: nowrap;
}
.fb-status-new { background: #dbeafe; color: #1e40af; }
.fb-status-in_progress { background: #fef3c7; color: #92400e; }
.fb-status-resolved { background: #dcfce7; color: #166534; }
.fb-status-wont_fix { background: #f3f4f6; color: #6b7280; }

/* Reply indicator */
.fb-reply-indicator { font-size: 12px; color: var(--accent); font-weight: 500; }

/* Message preview */
.fb-item-preview {
  font-size: 14px; color: var(--text); margin: 0; line-height: 1.45;
  overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.fb-expanded .fb-item-preview {
  -webkit-line-clamp: unset; white-space: pre-wrap;
}

/* Expanded detail area */
.fb-item-detail { }
.fb-item-detail:not(:empty) { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border-light); }

/* Conversation thread */
.fb-thread { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.fb-thread-msg { padding: 10px 12px; border-radius: 8px; font-size: 14px; }
.fb-thread-msg p { margin: 4px 0 0; line-height: 1.45; white-space: pre-wrap; }
.fb-thread-head { display: flex; justify-content: space-between; align-items: center; }
.fb-thread-head strong { font-size: 13px; color: var(--text); }
.fb-thread-head time { font-size: 11px; color: var(--text-tertiary); }
.fb-thread-user { background: var(--border-light); }
.fb-thread-admin {
  background: rgba(59,130,246,0.06); border-left: 3px solid #3b82f6;
}
.fb-thread-admin .fb-thread-head strong { color: #1d4ed8; }

/* Reply compose (inline) */
.fb-reply-compose {
  border: 1px solid var(--border); border-radius: 8px;
  overflow: hidden; background: var(--bg-card);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.fb-reply-compose:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(124,58,237,0.08);
}
.fb-reply-input {
  width: 100%; border: none; padding: 10px 12px 6px;
  background: transparent; color: var(--text); font-size: 14px;
  font-family: inherit; resize: none; outline: none;
  line-height: 1.5; min-height: 36px;
}
.fb-reply-bar {
  display: flex; justify-content: flex-end; padding: 4px 8px 8px;
}

/* Empty state */
.fb-empty-state {
  font-size: 14px; color: var(--text-secondary); padding: 12px 0;
  margin: 0; text-align: center;
}

.loading-sm { font-size: 13px; color: var(--text-secondary); padding: 8px 0; }

/* ================================================================
   PUSH NOTIFICATIONS (Settings)
   ================================================================ */
.push-toggle-disabled { opacity: 0.45; pointer-events: none; transition: opacity 0.2s; }
.push-install-hint { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; color: var(--text-tertiary); margin-top: 12px; }
.push-install-hint a { color: var(--accent); font-weight: 500; }

/* ================================================================
   EPISODE DETAIL PAGE
   ================================================================ */
.episode-detail-header {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 24px;
}
.episode-detail-art {
  width: 80px;
  height: 80px;
  border-radius: var(--radius);
  object-fit: cover;
  flex-shrink: 0;
}
.episode-detail-header-info { flex: 1; min-width: 0; }
.episode-detail-header-info h2 { margin-bottom: 4px; font-size: 20px; line-height: 1.3; }
.episode-detail-header-info .episode-meta { font-size: 13px; color: var(--text-secondary); }

.episode-detail-summary { margin-bottom: 16px; }
.episode-detail-summary .card-header .summary-icon { margin-right: 4px; }
.episode-detail-summary-list {
  list-style: none;
  padding: 0 16px 16px;
  margin: 0;
}
.episode-detail-summary-list li {
  padding: 6px 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
  position: relative;
  padding-left: 16px;
}
.episode-detail-summary-list li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: bold;
}
.episode-detail-generating {
  padding: 16px;
  font-size: 14px;
  color: var(--text-secondary);
  font-style: italic;
}

.episode-detail-guests { margin-bottom: 16px; }
.episode-detail-guest-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0 16px 16px;
}
.episode-detail-guest-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px 6px 6px;
  background: var(--border-light);
  border-radius: var(--radius-full);
  font-size: 14px;
  color: var(--text);
  text-decoration: none;
  transition: background 0.15s;
}
.episode-detail-guest-chip:hover { background: var(--border); }
.episode-detail-guest-chip .fa-avatar,
.episode-detail-guest-chip .fa-avatar-img { border-radius: 50%; }

.episode-detail-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

/* External link icon (shared across episode rows and detail) */
.ep-external-link {
  font-size: 14px;
  color: var(--text-tertiary);
  text-decoration: none;
  vertical-align: middle;
  margin-left: 2px;
}
.ep-external-link:hover { color: var(--accent); }

/* Mobile responsive */
@media (max-width: 600px) {
  .episode-detail-header { gap: 12px; }
  .episode-detail-art { width: 60px; height: 60px; }
  .episode-detail-header-info h2 { font-size: 17px; }
}
