/**
 * TikTok-Style Audio Feed - Production Grade
 * Mobile-first (375px), zero chrome, audio spectrum aesthetic
 */

/* All variables live in reasonspring.css — single source of truth */

/* ============================================
   BASE - Reset & Container
   ============================================ */

* {
  -webkit-tap-highlight-color: transparent;
}

/* ============================================
   NAVIGATION - Minimal Top Bar
   ============================================ */

/* ── Announcement Banner ── */
.announce-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--announce-h);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--navy);
  color: var(--white);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  z-index: calc(var(--z-nav) + 1);
}

.has-announce .top-nav {
  top: var(--announce-h);
}

body.has-announce main {
  padding-top: calc(var(--nav-h) + var(--announce-h) + 8px);
}

.top-nav__wordmark {
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: var(--font-weight-bold);
  letter-spacing: -0.01em;
}

.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  max-width: none;
  height: var(--nav-h);
  background: var(--nav-bg);
  z-index: var(--z-nav);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  margin: 0;
}

.top-nav__logo {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--nav-text);
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
}

.top-nav__logo:hover {
  color: var(--nav-text);
  text-decoration: none;
}

.top-nav__logo svg {
  stroke: var(--nav-text);
  flex-shrink: 0;
}

.top-nav__link {
  color: var(--nav-text-muted);
  text-decoration: none;
  font-size: 14px;
  padding: 6px 10px;
  border-radius: 8px;
  transition: color 150ms, background 150ms;
}

.top-nav__link:hover {
  color: var(--nav-text);
  background: var(--nav-hover-bg);
}

.top-nav__tabs {
  display: flex;
  gap: 4px;
  align-items: center;
}

.top-nav__tab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 10px;
  color: var(--nav-text-dim);
  text-decoration: none;
  font-size: 13px;
  font-weight: var(--font-weight-medium);
  transition: color 150ms, background 150ms;
  white-space: nowrap;
}

.top-nav__tab svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.top-nav__tab-label {
  line-height: 1;
}

.top-nav__tab:hover {
  color: var(--nav-text);
  background: var(--nav-hover-bg);
}

.top-nav__tab--active {
  color: var(--nav-text);
  background: var(--nav-active-bg);
  font-weight: var(--font-weight-semibold);
}

.top-nav__tab--active:hover {
  color: var(--nav-text);
}

/* Mobile: hide tab labels, icon-only */
@media (max-width: 480px) {
  .top-nav__tab-label { display: none; }
  .top-nav__tab { padding: 8px; }
}

/* Mobile-only tabs (e.g. Chat) — hidden on desktop */
@media (min-width: 481px) {
  .top-nav__tab--mobile-only { display: none; }
}

.top-nav__actions {
  display: flex;
  gap: 8px;
  align-items: center;
  position: relative;
}

.top-nav__hamburger {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: none;
  background: none;
  color: var(--nav-text-muted);
  cursor: pointer;
  transition: color 150ms, background 150ms;
}

.top-nav__hamburger:hover {
  color: var(--nav-text);
  background: var(--nav-hover-bg);
}

.top-nav__menu {
  display: none;
  position: absolute;
  top: 48px;
  right: 0;
  min-width: 160px;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  border: 1px solid var(--cloud);
  border-radius: 12px;
  padding: 6px;
  box-shadow: var(--shadow-lg);
  z-index: var(--z-nav);
}

/* Admin gear — just a normal .top-nav__tab, no size overrides */
.admin-gear {
  color: var(--nav-text-dim);
}

.top-nav__menu.active {
  display: block;
}

.top-nav__menu-item {
  display: block;
  width: 100%;
  padding: 10px 14px;
  border-radius: 8px;
  border: none;
  background: none;
  color: var(--charcoal);
  font-size: 14px;
  font-family: inherit;
  text-decoration: none;
  text-align: left;
  cursor: pointer;
  transition: background 150ms;
}

.top-nav__menu-item:hover {
  background: var(--pearl);
}

.top-nav__menu-item--danger {
  color: var(--coral);
}

.top-nav__btn {
  background: var(--nav-hover-bg);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: var(--nav-text);
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 150ms;
  white-space: nowrap;
  text-decoration: none;
}

.top-nav__btn:active {
  transform: scale(0.97);
}

.top-nav__btn--primary {
  background: var(--gradient-primary);
  color: white;
  border: none;
  box-shadow: 0 4px 12px rgba(var(--rgb-primary), 0.3);
}

.top-nav__btn--primary:hover {
  box-shadow: 0 6px 16px rgba(var(--rgb-primary), 0.4);
}

/* Talk button — mic icon in top nav */
.top-nav__talk {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: var(--gradient-primary);
  color: var(--text-primary);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 58, 112, 0.35);
  transition: box-shadow 0.2s, transform 0.1s;
  flex-shrink: 0;
}

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

.top-nav__talk svg {
  stroke: var(--text-primary);
  fill: none;
}

.top-nav__talk.connecting {
  animation: top-talk-spin 1s linear infinite;
}

@keyframes top-talk-spin {
  to { transform: rotate(360deg); }
}

.top-nav__talk.connected {
  background: linear-gradient(135deg, var(--color-success), var(--color-success));
  box-shadow: 0 0 0 0 rgba(var(--rgb-success), 0.6);
  animation: top-talk-pulse 2s ease-in-out infinite;
}

@keyframes top-talk-pulse {
  0%, 100% { box-shadow: 0 2px 8px rgba(var(--rgb-success), 0.4); }
  50% { box-shadow: 0 2px 8px rgba(var(--rgb-success), 0.4), 0 0 16px rgba(var(--rgb-success), 0.3); }
}

body {
  font-family: var(--font-body);
  background: var(--deep-space);
  color: var(--text-primary);
  overflow-x: hidden;
  overscroll-behavior: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  position: relative;
}

/* Offset main content below fixed nav — only when top nav is present (unauthenticated) */
body.has-top-nav main {
  padding-top: 64px;
}

/* Noise Texture Overlay */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: 0.4;
}

/* Shared content container — horizontal padding + max-width */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-4);
}

.feed-container {
  max-width: 100%;
  margin: 0 auto;
  padding: var(--space-4);
  padding-top: 16px;
  padding-bottom: 16px;
}

/* Tab header (Library, Profile) */
.tab-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.tab-header__title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.tab-header__count {
  font-size: 13px;
  color: var(--text-muted);
}

/* ── Finder Table (Library) ─────────────────────────────────────────── */
.finder-table {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
}

.finder-table__header {
  display: grid;
  grid-template-columns: 32px 1fr 80px 90px 72px 70px;
  gap: 0;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0 12px;
}

.finder-col {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 4px;
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semibold);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: none;
  border: none;
  cursor: pointer;
  user-select: none;
}

.finder-col:hover {
  color: var(--text-primary);
}

.finder-col--active {
  color: var(--text-secondary);
}

.finder-col__arrow {
  opacity: 0;
  transition: opacity var(--transition-fast), transform var(--transition-fast);
}

.finder-col--active .finder-col__arrow { opacity: 1; }
.finder-col--desc .finder-col__arrow { transform: rotate(180deg); }

/* Finder section groups */
.finder-section {
  border-bottom: 1px solid var(--border-subtle);
}

.finder-section:last-child {
  border-bottom: none;
}

.finder-section__header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semibold);
  color: var(--text-muted);
  background: var(--bg-secondary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.finder-section__count {
  margin-left: auto;
  font-weight: var(--font-weight-normal);
  color: var(--text-dim);
}

/* Individual content rows */
.finder-row {
  display: grid;
  grid-template-columns: 32px 1fr 80px 90px 72px 70px;
  gap: 0;
  padding: 8px 12px;
  text-decoration: none;
  color: var(--text-primary);
  border-bottom: 1px solid rgba(var(--rgb-black), 0.04);
  transition: background var(--transition-fast);
  cursor: pointer;
}

.finder-row:last-child {
  border-bottom: none;
}

.finder-row:hover {
  background: var(--bg-elevated);
  text-decoration: none;
  color: var(--text-primary);
}

.finder-row--generating {
  opacity: 0.7;
}

.finder-row__cell {
  display: flex;
  align-items: center;
  font-size: var(--text-sm);
  min-width: 0;
}

.finder-row__cell--title {
  gap: 8px;
  overflow: hidden;
}

.finder-row__title {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: var(--font-weight-medium);
}

.finder-row__icon {
  width: 24px;
  height: 24px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.finder-row__icon--notebook {
  background: var(--sage-light);
  color: var(--sage);
}

.finder-row__icon--podcast {
  background: var(--badge-intent-bg);
  color: var(--navy);
  overflow: hidden;
}

.finder-row__icon--podcast img {
  width: 24px;
  height: 24px;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

.finder-row__icon--unified {
  background: var(--gold-light);
  color: var(--gold);
}

/* Type badges */
.finder-type-badge {
  font-size: 11px;
  padding: 2px 6px;
  border-radius: var(--radius-full);
  font-weight: var(--font-weight-medium);
}

.finder-type-badge--notebook {
  background: var(--sage-light);
  color: var(--sage);
}

.finder-type-badge--podcast {
  background: var(--badge-intent-bg);
  color: var(--navy);
}

.finder-type-badge--unified {
  background: var(--gold-light);
  color: var(--gold);
}

/* Status indicators */
.finder-status {
  font-size: 11px;
  font-weight: var(--font-weight-medium);
  color: var(--text-dim);
}

.finder-status--ready {
  color: var(--sage);
}

.finder-status--generating {
  color: var(--navy-light);
}

.finder-status--error {
  color: var(--coral);
}

.finder-row__cell--date {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.finder-row__cell--vis {
  justify-content: flex-start;
}

/* Visibility toggle badge */
.vis-badge {
  display: inline-flex;
  align-items: center;
  font-size: 10px;
  font-weight: var(--font-weight-semibold);
  padding: 2px 7px;
  border-radius: var(--radius-full);
  border: none;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  transition: opacity var(--transition-fast);
}

.vis-badge:hover {
  opacity: 0.75;
}

.vis-badge--private {
  background: var(--bg-elevated);
  color: var(--text-muted);
}

.vis-badge--public {
  background: color-mix(in srgb, var(--sage) 15%, transparent);
  color: var(--sage);
}

.vis-badge--team {
  background: var(--badge-intent-bg);
  color: var(--navy);
}

/* Checkbox column */
.finder-col--check,
.finder-row__cell--check {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.finder-row-check {
  width: 14px;
  height: 14px;
  accent-color: var(--primary);
  cursor: pointer;
}

/* Category divider rows */
.finder-category-divider {
  display: flex;
  align-items: center;
  padding: 6px 12px 4px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
}

.finder-category-divider__label {
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semibold);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Action buttons in tab header */
.library-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semibold);
  color: var(--text-secondary);
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.library-action-btn:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}

/* Delete button in tab header */
.library-delete-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semibold);
  color: var(--error, #e05252);
  background: color-mix(in srgb, var(--error, #e05252) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--error, #e05252) 30%, transparent);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.library-delete-btn:hover {
  background: color-mix(in srgb, var(--error, #e05252) 20%, transparent);
}

/* Responsive: stack on narrow viewports */
@media (max-width: 480px) {
  .finder-table__header {
    grid-template-columns: 32px 1fr 72px 60px;
  }

  .finder-col--type,
  .finder-col--status {
    display: none;
  }

  .finder-col--vis {
    display: flex;
  }

  .finder-row {
    grid-template-columns: 32px 1fr 72px 60px;
  }

  .finder-row__cell--type,
  .finder-row__cell--status {
    display: none;
  }

  .finder-row__cell--vis {
    display: flex;
  }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 3px;
}

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

::-webkit-scrollbar-thumb {
  background: rgba(var(--rgb-primary), 0.3);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(var(--rgb-primary), 0.5);
}

/* ============================================
   LIBRARY CARDS - Compact Horizontal Layout
   ============================================ */

.lib-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  margin-bottom: 8px;
  border-radius: 14px;
  background: var(--card-glass);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: transform 0.15s var(--ease-smooth),
              border-color 0.15s var(--ease-smooth),
              box-shadow 0.15s var(--ease-smooth);
}

.lib-card:hover {
  transform: var(--hover-lift-sm, translateY(-2px));
  border-color: rgba(var(--rgb-primary), 0.25);
  box-shadow: var(--glow-accent, 0 0 20px rgba(var(--rgb-primary), 0.15));
}

.lib-card:active {
  transform: scale(0.98);
}

.lib-card__art {
  width: 72px;
  height: 72px;
  border-radius: 10px;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
  background: linear-gradient(135deg, var(--bg-card) 0%, var(--deep-space) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.lib-card__art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lib-card__art-icon {
  color: rgba(var(--rgb-white), 0.2);
}

.lib-card__play-btn {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(var(--rgb-black), 0.4);
  border: none;
  color: white;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.15s;
  border-radius: 10px;
}

.lib-card:hover .lib-card__play-btn {
  opacity: 1;
}

@media (hover: none) {
  .lib-card__play-btn {
    opacity: 0;
  }
}

.lib-card__body {
  flex: 1;
  min-width: 0;
}

.lib-card__title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 2px;
}

.lib-card__meta {
  font-size: 12px;
  color: rgba(var(--rgb-white), 0.4);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lib-card__actions {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex-shrink: 0;
}

.lib-card__action {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: none;
  background: rgba(var(--rgb-white), 0.05);
  color: rgba(var(--rgb-white), 0.5);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
}

.lib-card__action:hover {
  background: rgba(var(--rgb-white), 0.1);
  color: rgba(var(--rgb-white), 0.9);
}

.lib-card__action--danger:hover {
  background: rgba(var(--rgb-primary), 0.15);
  color: var(--color-primary);
}

/* Generating state */
.lib-card--generating {
  border-color: rgba(var(--rgb-primary), 0.3);
}

.lib-card__art--generating {
  background: var(--gradient-primary);
}

.lib-card__spinner {
  animation: spin 1.2s linear infinite;
}

.lib-card__progress {
  height: 3px;
  background: rgba(var(--rgb-white), 0.1);
  border-radius: 2px;
  margin-top: 6px;
  overflow: hidden;
}

.lib-card__progress-fill {
  height: 100%;
  background: var(--gradient-primary);
  transition: width 0.3s ease-out;
  box-shadow: 0 0 6px rgba(var(--rgb-primary), 0.5);
}

@media (max-width: 768px) {
  .lib-card {
    padding: 8px;
    gap: 10px;
  }

  .lib-card__art {
    width: 64px;
    height: 64px;
  }

  .lib-card__title {
    font-size: 13px;
  }

  .lib-card__actions {
    flex-direction: row;
    gap: 4px;
  }

  .lib-card__action {
    width: 32px;
    height: 32px;
  }
}

/* ============================================
   PODCAST CARDS - Audio Spectrum Style
   ============================================ */

.podcast-card {
  position: relative;
  background: var(--card-glass);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: var(--space-5);
  margin-bottom: var(--space-4);
  border: 0.5px solid var(--border-subtle);
  box-shadow: var(--shadow-card);
  cursor: pointer;
  transition: transform var(--duration-fast) var(--ease-smooth),
              box-shadow var(--duration-fast) var(--ease-smooth),
              border-color var(--duration-fast) var(--ease-smooth);
  overflow: hidden;
}

/* Video preview / poster — small thumbnail */
.podcast-card .card-video {
  width: 56px;
  height: 56px;
  object-fit: cover;
  border-radius: 12px;
  flex-shrink: 0;
  display: none;
}

.podcast-card:hover {
  transform: translateY(-2px);
  border-color: rgba(var(--rgb-primary), 0.3);
  box-shadow: 0 12px 40px rgba(var(--rgb-black), 0.5), 0 4px 12px rgba(var(--rgb-primary), 0.2);
}

.podcast-card:active {
  transform: translateY(0);
}

/* Gradient Border Effect */
.podcast-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 20px;
  padding: 1px;
  background: var(--gradient-primary);
  -webkit-mask: linear-gradient(var(--text-primary) 0 0) content-box, linear-gradient(var(--text-primary) 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity var(--duration-fast) var(--ease-smooth);
  pointer-events: none;
}

.podcast-card:active {
  transform: scale(0.98);
}

.podcast-card:hover::before {
  opacity: 0.4;
}

.podcast-header {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
}

.podcast-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(var(--rgb-primary), 0.3);
}

/* Spinning icon for generating state */
.podcast-icon--spin svg {
  animation: spin 1.2s linear infinite;
}

.podcast-meta {
  flex: 1;
  min-width: 0;
}

.podcast-title {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  margin-bottom: 2px;
  color: var(--text-primary);
}

.podcast-info {
  font-size: 13px;
  color: rgba(var(--rgb-white), 0.5);
  font-weight: 400;
  letter-spacing: 0.2px;
}

.podcast-owner-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--magenta);
  background: rgba(var(--rgb-magenta), 0.12);
  padding: 2px 8px;
  border-radius: 10px;
  margin-right: 6px;
}

.podcast-card.shared {
  border-color: rgba(var(--rgb-magenta), 0.3);
}

.podcast-card.shared:hover {
  border-color: rgba(var(--rgb-magenta), 0.5);
  box-shadow: 0 12px 40px rgba(var(--rgb-black), 0.5), 0 4px 12px rgba(var(--rgb-magenta), 0.15);
}

/* Failed State */
.podcast-card.failed {
  border-color: rgba(var(--rgb-error), 0.4);
  opacity: 0.75;
  cursor: pointer;
}

.podcast-card.failed::before {
  opacity: 1;
  background: linear-gradient(135deg, rgba(var(--rgb-error), 0.15), rgba(var(--rgb-error-bright), 0.08));
}

.podcast-card.failed:hover {
  opacity: 1;
  border-color: rgba(var(--rgb-error), 0.6);
  box-shadow: 0 12px 40px rgba(var(--rgb-black), 0.5), 0 4px 12px rgba(var(--rgb-error), 0.15);
}

.podcast-card.failed .podcast-info {
  color: rgba(var(--rgb-error), 0.8);
  font-size: 12px;
}

/* Generating State - Animated Gradient */
.podcast-card.generating {
  border-color: rgba(var(--rgb-primary), 0.4);
}

.podcast-card.generating::before {
  opacity: 1;
  background: var(--gradient-generating);
  background-size: 200% 100%;
  animation: gradientShift 3s linear infinite;
}

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

.progress-bar {
  height: 2px;
  background: rgba(var(--rgb-white), 0.1);
  border-radius: 2px;
  overflow: hidden;
  margin-top: var(--space-3);
}

.progress-fill {
  height: 100%;
  background: var(--gradient-primary);
  width: 0%;
  transition: width 0.3s ease-out;
  box-shadow: 0 0 8px rgba(var(--rgb-primary), 0.6);
}

.progress-log {
  margin-top: 16px;
  max-height: 200px;
  overflow-y: auto;
  font-size: 11px;
  line-height: 1.4;
  color: rgba(var(--rgb-white), 0.6);
  font-family: var(--font-mono);
  background: rgba(var(--rgb-black), 0.2);
  border-radius: 12px;
  padding: 8px;
}

.progress-log::-webkit-scrollbar {
  width: 4px;
}

.progress-log::-webkit-scrollbar-track {
  background: rgba(var(--rgb-white), 0.05);
  border-radius: 2px;
}

.progress-log::-webkit-scrollbar-thumb {
  background: rgba(var(--rgb-primary), 0.3);
  border-radius: 2px;
}

.progress-log::-webkit-scrollbar-thumb:hover {
  background: rgba(var(--rgb-primary), 0.5);
}

/* ============================================
   MODAL - Slide Up with Glassmorphism
   ============================================ */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(var(--rgb-black), 0.75);
  backdrop-filter: blur(12px);
  z-index: var(--z-modal-backdrop);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-modal) var(--ease-smooth);
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-width: 100%;
  margin: 0 auto;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(40px);
  border-radius: 28px 28px 0 0;
  padding: var(--space-6);
  padding-bottom: calc(var(--space-6) + env(safe-area-inset-bottom));
  box-shadow: var(--shadow-modal);
  border: 1px solid var(--cloud);
  border-bottom: none;
  transform: translateY(100%);
  transition: transform var(--duration-modal) var(--ease-smooth);
}

.modal-overlay.active .modal-content {
  transform: translateY(0);
}

/* Modal Handle */
.modal-handle {
  width: 40px;
  height: 4px;
  background: var(--cloud);
  border-radius: 2px;
  margin: 0 auto var(--space-5);
}

/* Modal form */
.modal-content form {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}

.modal-content textarea {
  width: 100%;
  flex: 1;
  min-height: 120px;
  background: var(--pearl);
  border: 1px solid var(--cloud);
  border-radius: 16px;
  padding: var(--space-4);
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--text-primary);
  resize: none;
  margin-bottom: var(--space-4);
  transition: border-color var(--duration-fast) var(--ease-smooth),
              box-shadow var(--duration-fast) var(--ease-smooth);
}

.modal-content textarea::placeholder {
  color: var(--silver);
}

.modal-content textarea:focus {
  outline: none;
  border-color: rgba(var(--rgb-primary), 0.5);
  box-shadow: 0 0 0 3px rgba(var(--rgb-primary), 0.1);
}

.refinement-label {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: rgba(var(--rgb-white), 0.5);
  margin-bottom: 16px;
  margin-top: 24px;
}

.chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: var(--space-5);
  padding: 12px 0;
}

.chip {
  padding: 14px 20px;
  background: rgba(var(--rgb-white), 0.05);
  border: 0.5px solid rgba(var(--rgb-white), 0.15);
  border-radius: 24px;
  font-size: 15px;
  font-weight: 500;
  color: rgba(var(--rgb-white), 0.7);
  cursor: pointer;
  transition: all var(--duration-instant) var(--ease-smooth);
  user-select: none;
  line-height: 1.4;
}

.chip:active {
  transform: scale(0.95);
}

.chip.selected {
  background: var(--gradient-primary);
  border-color: transparent;
  color: var(--text-primary);
  box-shadow: 0 4px 12px rgba(var(--rgb-primary), 0.4);
}

.link-list {
  margin-bottom: var(--space-5);
}

.link-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3);
  background: rgba(var(--rgb-white), 0.03);
  border-radius: 12px;
  margin-bottom: var(--space-2);
  font-size: 13px;
  color: rgba(var(--rgb-white), 0.6);
}

.link-item input[type="checkbox"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

/* Buttons */
.modal-actions {
  display: flex;
  gap: var(--space-3);
}

.btn {
  flex: 1;
  padding: 16px;
  border: none;
  border-radius: 14px;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-smooth);
  letter-spacing: -0.2px;
}

.btn-secondary {
  background: rgba(var(--rgb-white), 0.08);
  color: rgba(var(--rgb-white), 0.7);
  border: 0.5px solid rgba(var(--rgb-white), 0.1);
}

.btn-secondary:active {
  transform: scale(0.97);
  background: rgba(var(--rgb-white), 0.05);
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--text-primary);
  box-shadow: 0 4px 16px rgba(var(--rgb-primary), 0.4);
}

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

.btn-primary:hover {
  box-shadow: 0 6px 20px rgba(var(--rgb-primary), 0.5);
}

/* HTMX Loading States */
.btn-spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(var(--rgb-white), 0.3);
  border-top-color: var(--text-primary);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  margin-left: 8px;
}

.htmx-request .btn-spinner {
  display: inline-block;
}

.htmx-request .btn-text {
  opacity: 0.7;
}

button[disabled] {
  opacity: 0.7;
  cursor: not-allowed;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.hidden {
  display: none !important;
}

/* Loading Shimmer Effect */
@keyframes shimmer {
  0% {
    background-position: -400px 0;
  }
  100% {
    background-position: 400px 0;
  }
}

.shimmer {
  background: linear-gradient(
    90deg,
    rgba(var(--rgb-white), 0.05) 0%,
    rgba(var(--rgb-white), 0.1) 50%,
    rgba(var(--rgb-white), 0.05) 100%
  );
  background-size: 400px 100%;
  animation: shimmer 1.5s infinite;
}

/* ============================================
   RESPONSIVE - Desktop & Tablet
   ============================================ */

/* Tablet (768px+) */
@media (min-width: 768px) {
  .container {
    padding: 0 24px;
  }

  .feed-container {
    max-width: 100%;
    padding: var(--space-6) 24px;
  }

  .modal-content {
    max-width: 600px;
    border-radius: 28px;
    height: 85vh;
  }

  .podcast-card {
    margin-bottom: var(--space-6);
  }

}

/* Desktop (1024px+) */
@media (min-width: 1024px) {
  .container {
    padding: 0 32px;
  }

  .feed-container {
    max-width: 100%;
    padding: var(--space-6) 32px;
  }

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

/* Large Desktop (1440px+) */
@media (min-width: 1440px) {
  .container {
    padding: 0 48px;
  }

  .feed-container {
    max-width: 100%;
    padding: var(--space-6) 48px;
  }

  .modal-content {
    max-width: 800px;
  }
}

/* ============================================
   VISIBILITY TOGGLE - Private/Public Selection
   ============================================ */

/* Refinement form */
.refinement-form {
  position: relative;
}

/* Visibility lock button (top-right corner) */
.visibility-lock {
  position: absolute;
  top: 0;
  right: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid rgba(var(--rgb-white), 0.15);
  background: rgba(var(--rgb-white), 0.05);
  color: rgba(var(--rgb-white), 0.5);
  cursor: pointer;
}

.visibility-lock:hover {
  background: rgba(var(--rgb-white), 0.1);
  color: rgba(var(--rgb-white), 0.8);
}

.visibility-lock.unlocked {
  background: rgba(var(--rgb-primary), 0.15);
  border-color: var(--color-primary);
  color: var(--color-primary);
}

/* Refinement outline */
.refinement-outline {
  margin-bottom: 12px;
  padding: 10px;
  background: rgba(var(--rgb-primary), 0.06);
  border: 0.5px solid rgba(var(--rgb-primary), 0.2);
  border-radius: 10px;
  max-height: 25vh;
  overflow-y: auto;
}

.refinement-outline__title {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 6px;
}

.refinement-outline__hook {
  font-size: 12px;
  color: rgba(var(--rgb-white), 0.6);
  font-style: italic;
  margin-bottom: 8px;
}

.refinement-outline__meta {
  font-size: 11px;
  color: rgba(var(--rgb-white), 0.4);
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.refinement-outline__section {
  padding: 2px 0 2px 10px;
  border-left: 2px solid rgba(var(--rgb-primary), 0.2);
  margin-bottom: 4px;
}

.refinement-outline__section-title {
  font-size: 12px;
  color: rgba(var(--rgb-white), 0.8);
}

.refinement-outline__duration {
  color: rgba(var(--rgb-white), 0.35);
  font-size: 11px;
}

/* Sticky actions bar */
.modal-actions--sticky {
  position: sticky;
  bottom: 0;
  padding: 12px 0 0;
  background: var(--bg-card, #1a1b2e);
}

.btn--wide {
  flex: 2;
}

.link-item__text {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Podcast Action Buttons */
.podcast-actions {
  display: flex;
  gap: 12px;
  padding: 16px 20px;
  border-top: 0.5px solid rgba(var(--rgb-white), 0.05);
  justify-content: flex-end;
  background: rgba(var(--rgb-black), 0.1);
}

.action-btn {
  background: rgba(var(--rgb-white), 0.05);
  border: 1px solid rgba(var(--rgb-white), 0.15);
  border-radius: 10px;
  padding: 10px 16px;
  color: rgba(var(--rgb-white), 0.7);
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
}

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

.action-btn:hover {
  background: rgba(var(--rgb-white), 0.12);
  border-color: rgba(var(--rgb-white), 0.3);
  color: rgba(var(--rgb-white), 0.95);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(var(--rgb-black), 0.3);
}

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

.action-btn-danger {
  border-color: rgba(var(--rgb-primary), 0.3);
}

.action-btn-danger:hover {
  background: rgba(var(--rgb-primary), 0.2);
  border-color: rgba(var(--rgb-primary), 0.6);
  color: var(--color-primary);
}

.vis-toggle {
  display: flex;
  gap: 6px;
}

.vis-chip {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  border-radius: 16px;
  border: 1px solid var(--cloud);
  background: transparent;
  color: var(--warm-gray);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
}

.vis-chip--active {
  border-color: rgba(var(--rgb-purple), 0.6);
  color: var(--purple);
  background: rgba(var(--rgb-purple), 0.1);
}

.vis-chip:hover {
  border-color: var(--silver);
  color: var(--charcoal);
}

.action-btn-vis {
  font-size: 11px;
  gap: 2px;
}

.action-btn-vis--private {
  border-color: rgba(var(--rgb-white), 0.15);
  color: rgba(var(--rgb-white), 0.4);
}

.action-btn-vis--public {
  border-color: rgba(var(--rgb-purple), 0.5);
  color: var(--purple);
}

.action-btn-vis--team {
  border-color: rgba(var(--rgb-warning), 0.5);
  color: var(--color-warning);
}

/* ============================================
   FAB — Floating Action Button
   ============================================ */

.fab {
  position: fixed;
  bottom: calc(var(--tabs-h) + var(--player-h) + 24px);
  right: 20px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--gradient-primary);
  box-shadow: 0 4px 12px rgba(0, 58, 112, 0.4);
  border: none;
  color: white;
  cursor: pointer;
  z-index: var(--z-fab);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s, box-shadow 0.15s;
}

.fab:active {
  transform: scale(0.92);
  box-shadow: 0 2px 8px rgba(var(--rgb-purple), 0.3);
}

/* ============================================
   MODE TOGGLE — Chat / Voice
   ============================================ */

.mode-toggle {
  display: flex;
  gap: 4px;
  padding: 4px;
  background: var(--pearl);
  border-radius: 12px;
  margin-bottom: 12px;
}

.mode-chip {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 0;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--warm-gray);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}

.mode-chip--active {
  background: rgba(var(--rgb-purple), 0.15);
  color: var(--purple);
}

/* ============================================
   VOICE PROMPT — in generate modal
   ============================================ */

.voice-prompt {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 32px 16px;
}

.voice-prompt__icon {
  opacity: 0.7;
}

.voice-prompt__text {
  color: var(--warm-gray);
  font-size: 14px;
  margin: 0;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}


/* Log Section */
.log-section {
  padding: 12px 16px;
  border-top: 0.5px solid rgba(var(--rgb-white), 0.05);
}

.log-toggle {
  background: transparent;
  border: none;
  color: rgba(var(--rgb-white), 0.6);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  padding: 8px 0;
  width: 100%;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.2s;
}

.log-toggle:hover {
  color: rgba(var(--rgb-white), 0.9);
}

/* Log Chevron - CSS triangle instead of emoji */
.log-chevron {
  display: inline-block;
  width: 0;
  height: 0;
  border-left: 5px solid currentColor;
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
  transition: transform 0.2s ease;
}

.log-chevron.expanded {
  transform: rotate(90deg);
}

.log-content {
  margin-top: 8px;
}

.log-output {
  width: 100%;
  height: 200px;
  font-family: var(--font-mono);
  font-size: 11px;
  background: rgba(var(--rgb-black), 0.3);
  border: 1px solid rgba(var(--rgb-white), 0.1);
  border-radius: 8px;
  padding: 12px;
  line-height: 1.4;
  white-space: pre-wrap;
  word-wrap: break-word;
  outline: none;
}

.log-output:focus {
  border-color: rgba(var(--rgb-primary), 0.4);
}

.log-output::selection {
  background: rgba(var(--rgb-primary), 0.3);
  color: white;
}

.podcast-cover {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(var(--rgb-black), 0.3);
}

/* ============================================
   ERROR MODAL
   ============================================ */

.error-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(var(--rgb-black), 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.error-modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.error-modal {
  background: var(--bg-card);
  border: 1px solid rgba(var(--rgb-primary), 0.4);
  border-radius: 16px;
  width: 100%;
  max-width: 560px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(var(--rgb-black), 0.6);
}

.error-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(var(--rgb-white), 0.08);
}

.error-modal__title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-primary);
}

.error-modal__close {
  background: none;
  border: none;
  color: rgba(var(--rgb-white), 0.5);
  font-size: 24px;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.error-modal__close:hover {
  color: white;
}

.error-modal__meta {
  padding: 12px 20px;
  font-size: 12px;
  font-family: var(--font-mono);
  color: rgba(var(--rgb-white), 0.5);
  border-bottom: 1px solid rgba(var(--rgb-white), 0.06);
}

.error-modal__body {
  flex: 1;
  overflow: auto;
  padding: 16px 20px;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.6;
  color: rgba(var(--rgb-white), 0.8);
  white-space: pre-wrap;
  word-break: break-word;
  background: rgba(var(--rgb-black), 0.2);
}

.error-modal__header .error-modal__icon {
  flex-shrink: 0;
}

.error-modal__actions {
  display: flex;
  gap: 8px;
  padding: 12px 20px;
  border-top: 1px solid rgba(var(--rgb-white), 0.08);
}

.error-modal__action-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid rgba(var(--rgb-white), 0.15);
  background: transparent;
  color: rgba(var(--rgb-white), 0.7);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s;
}

.error-modal__action-btn:hover {
  border-color: rgba(var(--rgb-white), 0.3);
  color: white;
}

.error-modal__action-btn--email {
  border-color: rgba(var(--rgb-purple), 0.4);
  color: var(--purple);
}

.error-modal__action-btn--email:hover {
  background: rgba(var(--rgb-purple), 0.1);
  border-color: rgba(var(--rgb-purple), 0.6);
}

.error-modal__action-btn--dismiss {
  margin-left: auto;
  border-color: rgba(var(--rgb-white), 0.1);
  color: rgba(var(--rgb-white), 0.4);
}

/* Feed Empty State */

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

.feed-empty-state__icon {
  margin-bottom: 16px;
}

.feed-empty-state__title {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
}

.feed-empty-state__sub {
  font-size: 13px;
  margin-top: 8px;
  color: var(--text-muted);
}

.feed-empty-state__cta {
  display: inline-block;
  margin-top: 20px;
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: var(--white);
  text-decoration: none;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 500;
  border: none;
  cursor: pointer;
}

/* ── Explore Onboarding (never-empty state) ─────────────────────────── */
.explore-onboard {
  padding: 20px 16px;
}

.explore-onboard__hero {
  text-align: center;
  padding: 40px 20px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  margin-bottom: 24px;
}

.explore-onboard__title {
  font-size: var(--text-xl);
  font-weight: var(--font-weight-semibold);
  color: var(--navy);
  margin: 16px 0 8px;
}

.explore-onboard__sub {
  font-size: var(--text-sm);
  color: var(--text-muted);
  max-width: 320px;
  margin: 0 auto 20px;
  line-height: 1.5;
}

.explore-onboard__cta {
  display: inline-block;
  padding: 12px 28px;
  background: var(--gradient-primary);
  color: var(--white);
  border: none;
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semibold);
  cursor: pointer;
  box-shadow: var(--shadow-fab);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.explore-onboard__cta:hover {
  transform: var(--hover-lift-sm);
  box-shadow: var(--shadow-lg);
}

.explore-featured {
  margin-top: 8px;
}

.explore-featured__heading {
  font-size: var(--text-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--text-secondary);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.explore-featured__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.explore-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.explore-chip:hover {
  background: var(--bg-elevated);
  border-color: var(--navy-light);
  color: var(--navy);
}

.explore-chip__icon {
  font-size: 14px;
}

/* Episode Detail — Next Prompt Card */

.next-prompt-card {
  margin-top: 24px;
  background: rgba(var(--rgb-white), 0.06);
  border: 1px solid rgba(var(--rgb-white), 0.12);
  border-radius: 12px;
  padding: 16px;
}

.next-prompt-label {
  font-size: 13px;
  color: rgba(var(--rgb-white), 0.5);
  margin-bottom: 8px;
}

.next-prompt-textarea {
  width: 100%;
  min-height: 60px;
  font-family: inherit;
  font-size: 14px;
  background: rgba(var(--rgb-black), 0.3);
  border: 1px solid rgba(var(--rgb-white), 0.15);
  border-radius: 8px;
  padding: 10px;
  color: rgba(var(--rgb-white), 0.9);
  resize: vertical;
}

.next-prompt-btn {
  margin-top: 10px;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: white;
  border: none;
  cursor: pointer;
  width: 100%;
}

.progress-fill--generating {
  width: 50%;
}

/* ── Create mode tabs (Auto-Generate / Voice Studio) ─────────── */
.create-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.create-tab {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid rgba(var(--rgb-white), 0.12);
  border-radius: 12px;
  background: rgba(var(--rgb-white), 0.04);
  color: rgba(var(--rgb-white), 0.55);
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.create-tab:hover {
  background: rgba(var(--rgb-white), 0.08);
  color: rgba(var(--rgb-white), 0.8);
}

.create-tab--active {
  background: var(--gradient-primary);
  border-color: transparent;
  color: var(--text-primary);
  box-shadow: 0 2px 12px rgba(var(--rgb-primary), 0.3);
}

/* ── Voice Studio teaser panel ───────────────────────────────── */
.voice-teaser {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 24px 16px 8px;
  text-align: center;
}

.voice-teaser__icon {
  font-size: 2.5rem;
  line-height: 1;
  filter: drop-shadow(0 0 16px rgba(var(--rgb-primary), 0.5));
}

.voice-teaser__title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.voice-teaser__desc {
  font-size: 0.85rem;
  color: rgba(var(--rgb-white), 0.55);
  line-height: 1.55;
  max-width: 280px;
}

.voice-teaser__btn {
  margin-top: 4px;
  width: 100%;
  text-align: center;
  text-decoration: none;
  display: block;
}

/* ── Activity Indicator (pulsing dot + task panel) ── */
.top-nav__activity {
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.activity-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  animation: activityPulse 1.5s ease-in-out infinite;
}
@keyframes activityPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(var(--rgb-primary), 0.5); }
  50% { box-shadow: 0 0 0 6px rgba(var(--rgb-primary), 0); }
}
.activity-panel {
  position: absolute;
  top: 48px;
  right: 12px;
  width: 280px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  box-shadow: var(--shadow-xl);
  z-index: var(--z-panel);
  overflow: hidden;
}
.activity-panel__header {
  padding: 12px 16px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-subtle);
}
.activity-panel__list {
  max-height: 240px;
  overflow-y: auto;
}
.activity-task {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-subtle);
}
.activity-task:last-child { border-bottom: none; }
.activity-task__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  animation: activityPulse 1.5s ease-in-out infinite;
}
.activity-task__info {
  flex: 1;
  min-width: 0;
}
.activity-task__label {
  font-size: 0.8rem;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.activity-task__elapsed {
  font-size: 0.7rem;
  color: var(--text-dim);
}