/* ═══════════════════════════════════════════
   EarningsBeat.ai — Global Styles
   ═══════════════════════════════════════════ */

:root {
  --cyan: #00D4FF;
  --cyan-dim: rgba(0, 212, 255, 0.15);
  --cyan-glow: rgba(0, 212, 255, 0.4);
  --bg: #0a0a0a;
  --card-bg: #111113;
  --card-border: rgba(255,255,255,0.07);
  --text-primary: #fff;
  --text-muted: #999;
  --text-dim: #555;

  /* Show accent colors */
  --earnings-debate: #00D4FF;
  --company-spotlight: #FF6B6B;
  --inside-business: #7EE787;
  --tech-radar: #D2A8FF;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }

/* ── Navigation ── */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--card-border);
}

.nav-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 1.25em;
  font-weight: 700;
  color: var(--cyan);
  letter-spacing: 0.02em;
}

.nav-logo-beat { color: #fff; }
.nav-logo-ai { color: var(--cyan); opacity: 0.7; font-weight: 400; }

.nav-links {
  display: flex;
  gap: 24px;
}

.nav-links a {
  font-size: 0.9em;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--text-primary); }

/* ── Hero (Homepage) ── */

.hero {
  position: relative;
  width: 100%;
  height: 400px;
  background: url('/images/banners/banner.jpg') center center/cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.3), rgba(10,10,10,0.95));
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 700px;
  padding: 0 20px;
  animation: fadeUp 0.6s ease both;
}

.hero h1 {
  font-size: 3.8em;
  font-weight: 700;
  color: var(--cyan);
  letter-spacing: 0.03em;
  line-height: 1.05;
  margin-bottom: 16px;
  text-shadow: 0 0 40px var(--cyan-glow);
}

.hero h1 .beat {
  color: #fff;
  text-shadow: 0 0 40px rgba(255,255,255,0.25);
}

.hero h1 .dot-ai {
  color: var(--cyan);
  opacity: 0.7;
  font-weight: 400;
}

.hero .tagline {
  font-family: 'Instrument Serif', serif;
  font-style: italic;
  font-size: 1.35em;
  color: rgba(255,255,255,0.6);
}

.hero .subtitle {
  margin-top: 20px;
  font-size: 1.05em;
  color: rgba(255,255,255,0.7);
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

/* ── Show Cards Grid ── */

.shows-grid {
  max-width: 960px;
  margin: 0 auto;
  padding: 60px 24px 80px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.show-card {
  position: relative;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 24px 22px 24px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.show-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--accent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

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

.show-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px -10px color-mix(in srgb, var(--accent) 25%, transparent);
}

.show-card .show-number {
  font-size: 0.7em;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 14px;
  opacity: 0.8;
}

.show-card .show-art {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 16px;
  border: 1px solid rgba(255,255,255,0.06);
  transition: transform 0.3s ease;
}

.show-card:hover .show-art { transform: scale(1.02); }

.show-card h2 {
  font-size: 1.5em;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.show-card .show-desc {
  font-size: 0.9em;
  color: var(--text-muted);
  line-height: 1.6;
  flex-grow: 1;
}

.show-card .show-cta {
  margin-top: 18px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85em;
  font-weight: 600;
  color: var(--accent);
  opacity: 0.7;
  transition: opacity 0.2s;
}

.show-card:hover .show-cta { opacity: 1; }

.show-card .show-cta svg {
  width: 14px; height: 14px;
  fill: currentColor;
  transition: transform 0.2s;
}

.show-card:hover .show-cta svg { transform: translateY(2px); }

/* Per-show accent colors */
.show-card[data-show="earnings-debate"]   { --accent: #00D4FF; }
.show-card[data-show="company-spotlight"]  { --accent: #FF6B6B; }
.show-card[data-show="inside-business"]    { --accent: #7EE787; }
.show-card[data-show="tech-radar"]         { --accent: #D2A8FF; }

/* ── Animations ── */

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

.shows-grid .show-card:nth-child(1) { animation: fadeUp 0.5s ease 0.15s both; }
.shows-grid .show-card:nth-child(2) { animation: fadeUp 0.5s ease 0.25s both; }
.shows-grid .show-card:nth-child(3) { animation: fadeUp 0.5s ease 0.35s both; }
.shows-grid .show-card:nth-child(4) { animation: fadeUp 0.5s ease 0.45s both; }

/* ── Subscribe Links ── */

.subscribe-label {
  font-size: 0.82em;
  color: var(--text-dim);
  font-weight: 500;
  margin-right: 4px;
  white-space: nowrap;
}

.show-subscribe-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.sub-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  color: #ccc;
  text-decoration: none;
  font-size: 0.82em;
  font-weight: 500;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.sub-link:hover {
  background: var(--cyan-dim);
  border-color: rgba(0,212,255,0.3);
  color: var(--cyan);
}

.sub-link svg {
  width: 16px; height: 16px;
  flex-shrink: 0;
  fill: currentColor;
}

/* ── About Section ── */

.about-section {
  max-width: 960px;
  margin: 0 auto;
  padding: 20px 24px 0;
  margin-bottom: 40px;
}

.about-inner {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding-top: 48px;
  text-align: center;
}

.about-text {
  font-size: 1.05em;
  color: var(--text-muted);
  line-height: 1.75;
  max-width: 640px;
  margin: 0 auto 32px;
}

.about-social-label {
  font-size: 0.85em;
  color: var(--text-dim);
  margin-bottom: 12px;
}

.about-links {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.about-links a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  color: #ccc;
  text-decoration: none;
  font-size: 0.9em;
  font-weight: 500;
  transition: all 0.2s ease;
}

.about-links a:hover {
  background: var(--cyan-dim);
  border-color: rgba(0,212,255,0.3);
  color: var(--cyan);
}

.about-links a svg {
  width: 18px; height: 18px;
  fill: currentColor;
}

/* ── Footer ── */

.site-footer {
  border-top: 1px solid var(--card-border);
  padding: 32px 24px;
}

.footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-inner p {
  color: var(--text-dim);
  font-size: 0.85em;
}

.footer-social {
  color: var(--text-dim);
  transition: color 0.2s;
}

.footer-social:hover { color: var(--text-primary); }

/* ── Breadcrumbs ── */

.breadcrumb {
  max-width: 960px;
  margin: 0 auto;
  padding: 20px 24px 0;
  font-size: 0.85em;
  color: var(--text-dim);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.breadcrumb a {
  color: var(--text-muted);
  transition: color 0.2s;
}

.breadcrumb a:hover { color: var(--cyan); }

.breadcrumb-sep { color: var(--text-dim); }
.breadcrumb-current { color: var(--text-muted); }

/* ── Page Header (Index pages) ── */

.page-header {
  max-width: 960px;
  margin: 0 auto;
  padding: 48px 24px 0;
  text-align: center;
}

.page-header h1 {
  font-size: 2.4em;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.page-subtitle {
  color: var(--text-muted);
  font-size: 1.05em;
}

/* ── Section Title ── */

.section-title {
  font-size: 1.3em;
  font-weight: 600;
  margin-bottom: 20px;
  letter-spacing: -0.01em;
}

/* ── Show Badge (Color-coded pill) ── */

.show-badge {
  display: inline-block;
  font-size: 0.72em;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 4px;
  background: color-mix(in srgb, var(--badge-color) 15%, transparent);
  color: var(--badge-color);
  border: 1px solid color-mix(in srgb, var(--badge-color) 25%, transparent);
}

/* ── Episode Cards ── */

.episode-card-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.episode-card {
  display: block;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  transition: all 0.25s ease;
}

.episode-card:hover {
  border-color: rgba(255,255,255,0.15);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px -8px rgba(0,0,0,0.4);
}

.episode-card-inner {
  padding: 20px 24px;
}

.episode-card-company {
  font-size: 0.8em;
  font-weight: 600;
  color: var(--cyan);
  margin-top: 6px;
  margin-bottom: 2px;
}

.episode-card-title {
  font-size: 1.05em;
  font-weight: 600;
  line-height: 1.4;
  margin: 6px 0 8px;
  letter-spacing: -0.01em;
}

.episode-card-meta {
  font-size: 0.82em;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.meta-sep { color: var(--text-dim); }

.episode-card-tags {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* ── Topic Tags ── */

.topic-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
  clear: both;
}

.topic-tag {
  display: inline-block;
  font-size: 0.8em;
  padding: 5px 12px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  color: var(--text-muted);
  transition: all 0.2s ease;
}

a.topic-tag:hover {
  background: var(--cyan-dim);
  border-color: rgba(0,212,255,0.3);
  color: var(--cyan);
}

.topic-tag-sm {
  font-size: 0.72em;
  padding: 3px 8px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 4px;
  color: var(--text-dim);
}

/* ── Episode Page ── */

.episode-page {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px 60px;
}

.episode-header {
  padding: 32px 0 24px;
}

.episode-header .show-badge {
  margin-bottom: 12px;
}

.episode-header h1 {
  font-size: 1.8em;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.episode-meta {
  font-size: 0.9em;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ── Episode Artwork (floated right in body) ── */

.episode-body .episode-artwork-img {
  float: right;
  width: 300px;
  margin: 0 0 20px 28px;
  border-radius: 12px;
  border: 1px solid var(--card-border);
}

.episode-player {
  margin-bottom: 32px;
}

.episode-player iframe {
  border-radius: 12px;
  border: 1px solid var(--card-border);
}

.episode-body {
  margin-bottom: 32px;
}

.episode-description {
  font-size: 0.95em;
  color: var(--text-muted);
  line-height: 1.8;
}

.episode-description p {
  margin-bottom: 16px;
}

.episode-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--card-border);
}

.action-link {
  font-size: 0.9em;
  font-weight: 500;
  color: var(--cyan);
  transition: opacity 0.2s;
}

.action-link:hover { opacity: 0.8; }

/* ── Related Episodes ── */

.related-episodes {
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--card-border);
}

/* ── Company Page ── */

.company-page {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px 60px;
}

.company-header {
  padding: 32px 0 24px;
}

.company-header h1 {
  font-size: 2.2em;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.company-header .ticker {
  color: var(--cyan);
  font-weight: 500;
}

.company-summary {
  font-size: 0.95em;
  color: var(--text-muted);
}

.company-player {
  margin-bottom: 40px;
}

.company-player iframe {
  border-radius: 12px;
  border: 1px solid var(--card-border);
}

.company-episodes {
  margin-top: 8px;
}

/* ── Companies Index ── */

.companies-index {
  max-width: 960px;
  margin: 0 auto;
  padding: 32px 24px 60px;
}

.company-search-wrap {
  margin-bottom: 28px;
}

.company-search {
  width: 100%;
  padding: 14px 20px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95em;
  outline: none;
  transition: border-color 0.2s;
}

.company-search::placeholder { color: var(--text-dim); }
.company-search:focus { border-color: var(--cyan); }

.company-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.company-card {
  display: block;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  transition: all 0.25s ease;
}

.company-card:hover {
  border-color: rgba(255,255,255,0.15);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px -8px rgba(0,0,0,0.4);
}

.company-card-inner {
  padding: 20px;
}

.company-card-name {
  font-size: 1.05em;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 2px;
}

.company-card-ticker {
  font-size: 0.82em;
  font-weight: 600;
  color: var(--cyan);
  letter-spacing: 0.04em;
}

.company-card-meta {
  font-size: 0.78em;
  color: var(--text-muted);
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.company-card-shows {
  margin-top: 10px;
  display: flex;
  gap: 5px;
}

.show-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.no-results {
  text-align: center;
  color: var(--text-muted);
  padding: 40px 0;
  font-size: 0.95em;
}

/* ── Show Page ── */

.show-page {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px 60px;
}

.show-page-header {
  display: flex;
  gap: 32px;
  padding: 32px 0 40px;
  align-items: flex-start;
}

.show-page-art-wrap {
  flex-shrink: 0;
}

.show-page-art {
  width: 200px;
  height: 200px;
  border-radius: 14px;
  object-fit: cover;
  border: 1px solid rgba(255,255,255,0.06);
}

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

.show-page-info h1 {
  font-size: 2em;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.show-page-desc {
  font-size: 0.95em;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 20px;
}

.show-page-player {
  margin-bottom: 40px;
}

.show-page-player iframe {
  border-radius: 12px;
  border: 1px solid var(--card-border);
}

.show-page-episodes {
  margin-top: 8px;
}

/* ── Recent Episodes (Homepage) ── */

.recent-episodes {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px 60px;
}

.recent-episodes-inner {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding-top: 48px;
}

.recent-episodes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.recent-ep-card {
  display: block;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  transition: all 0.25s ease;
}

.recent-ep-card:hover {
  border-color: rgba(255,255,255,0.15);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px -8px rgba(0,0,0,0.4);
}

.recent-ep-card-inner {
  padding: 20px;
}

.recent-ep-card .show-badge {
  margin-bottom: 10px;
}

.recent-ep-card {
  cursor: pointer;
}

a.recent-ep-company {
  font-size: 0.82em;
  font-weight: 600;
  color: var(--cyan);
  margin-bottom: 4px;
  display: block;
  text-decoration: none;
  position: relative;
  z-index: 1;
}

a.recent-ep-company:hover {
  text-decoration: underline;
}

.recent-ep-title {
  font-size: 0.92em;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.recent-ep-meta {
  font-size: 0.78em;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.recent-episodes-more {
  text-align: center;
  margin-top: 32px;
}

.view-all-link {
  font-size: 0.95em;
  font-weight: 500;
  color: var(--cyan);
  transition: opacity 0.2s;
}

.view-all-link:hover { opacity: 0.8; }

/* ── Topics Index ── */

.topics-index {
  max-width: 960px;
  margin: 0 auto;
  padding: 32px 24px 60px;
}

.topic-search-wrap {
  margin-bottom: 28px;
}

.topic-search {
  width: 100%;
  padding: 14px 20px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95em;
  outline: none;
  transition: border-color 0.2s;
}

.topic-search::placeholder { color: var(--text-dim); }
.topic-search:focus { border-color: var(--cyan); }

.topic-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.topic-card {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 0.9em;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
}

.topic-card:hover {
  border-color: rgba(0, 212, 255, 0.3);
  background: var(--cyan-dim);
  color: var(--cyan);
}

.topic-card-count {
  font-size: 0.78em;
  font-weight: 600;
  color: var(--text-dim);
  background: rgba(255,255,255,0.06);
  padding: 2px 7px;
  border-radius: 4px;
}

.topic-card:hover .topic-card-count {
  color: var(--cyan);
  background: rgba(0,212,255,0.1);
}

/* ── Topic Page ── */

.topic-page {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px 60px;
}

.topic-page .page-header {
  padding: 32px 0 24px;
}

.episode-card-title-link {
  text-decoration: none;
  color: inherit;
}

.episode-card-title-link:hover .episode-card-title {
  color: var(--cyan);
}

.episode-card-company a {
  color: var(--cyan);
  text-decoration: none;
}

.episode-card-company a:hover {
  text-decoration: underline;
}

/* ── Responsive ── */

@media (max-width: 700px) {
  .hero { height: 300px; }
  .hero h1 { font-size: 2.5em; }
  .hero .tagline { font-size: 1.15em; }

  .shows-grid {
    grid-template-columns: 1fr;
    padding-bottom: 60px;
  }

  .show-card { padding: 20px 18px 20px; }
  .show-card .show-art { border-radius: 8px; }
  .show-card h2 { font-size: 1.3em; }

  .company-grid {
    grid-template-columns: 1fr;
  }

  .recent-episodes-grid {
    grid-template-columns: 1fr;
  }

  .show-page-header {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .show-page-art { width: 160px; height: 160px; }

  .show-subscribe-row {
    justify-content: center;
  }

  .episode-body .episode-artwork-img {
    float: none;
    width: 100%;
    max-width: 320px;
    margin: 0 auto 20px;
    display: block;
  }

  .episode-header h1 { font-size: 1.4em; }
  .company-header h1 { font-size: 1.6em; }

  .episode-actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-inner {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
}

@media (min-width: 701px) and (max-width: 900px) {
  .company-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .recent-episodes-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
