/* Inside Radio — Broadcast Studio Design System */

:root {
    --brand: #E6322E;
    --brand-hover: #ff4438;
    --brand-dim: rgba(230, 50, 46, 0.15);
    --bg: #09090b;
    --surface: #18181b;
    --surface-hover: #1f1f23;
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.14);
    --text: #fafafa;
    --text-muted: #a1a1aa;
    --text-dim: #71717a;
}

body {
    font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    -webkit-font-smoothing: antialiased;
}

/* Brand typography — echoes 2015 italic wordmark */
.font-display { font-family: 'Barlow Condensed', sans-serif; }
.ir-wordmark { transform: skewX(-6deg); letter-spacing: -0.02em; }
.text-brand { color: var(--brand); }
.text-muted { color: var(--text-muted); }
.text-dim { color: var(--text-dim); }

/* Surfaces */
.surface {
    background: var(--surface);
    border: 1px solid var(--border);
}
.surface-hover:hover {
    background: var(--surface-hover);
    border-color: var(--border-strong);
}

.glass-panel {
    background: rgba(24, 24, 27, 0.92);
    backdrop-filter: blur(16px);
    border: 1px solid var(--border);
}

/* Labels — broadcast style, not monospace */
.label {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-dim);
}

/* Live indicator */
.live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--brand);
    box-shadow: 0 0 0 0 rgba(230, 50, 46, 0.5);
    animation: livePulse 2s ease-in-out infinite;
}
@keyframes livePulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(230, 50, 46, 0.45); }
    50% { box-shadow: 0 0 0 6px rgba(230, 50, 46, 0); }
}

.live-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--brand);
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #fff;
    background: var(--brand);
    border-radius: 0.5rem;
    transition: background 0.15s ease, transform 0.15s ease;
}
.btn-primary:hover { background: var(--brand-hover); transform: translateY(-1px); }

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text);
    background: transparent;
    border: 1px solid var(--border-strong);
    border-radius: 0.5rem;
    transition: border-color 0.15s ease, background 0.15s ease;
}
.btn-secondary:hover { border-color: rgba(255,255,255,0.3); background: rgba(255,255,255,0.04); }

.btn-ghost {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    transition: color 0.15s ease;
}
.btn-ghost:hover { color: var(--text); }

/* Cards */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
    border-color: var(--border-strong);
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}
.card-show:hover { border-color: rgba(230, 50, 46, 0.35); }

.card-art {
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: 0.625rem;
    background: var(--bg);
}

/* Audio meters — subtle, player only */
.audio-bar {
    transform-origin: bottom;
    transform: scaleY(0.1);
    transition: transform 0.06s ease-out;
    background: linear-gradient(to top, var(--brand), #ff8a80);
    border-radius: 1px;
}

/* Forms */
.input-field {
    font-size: 0.875rem;
    background: var(--bg);
    border: 1px solid var(--border-strong);
    border-radius: 0.5rem;
    padding: 0.625rem 1rem;
    color: var(--text);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.input-field::placeholder { color: var(--text-dim); }
.input-field:focus {
    outline: none;
    border-color: rgba(230, 50, 46, 0.5);
    box-shadow: 0 0 0 3px var(--brand-dim);
}

/* Nav */
.nav-link-active { color: var(--text) !important; font-weight: 600; }

#mobile-menu { max-height: 0; overflow: hidden; transition: max-height 0.25s ease; }
#mobile-menu.open { max-height: 18rem; }

/* Logo hover */
a:hover .ir-logo-mic { filter: drop-shadow(0 0 8px rgba(230, 50, 46, 0.25)); }

/* Line clamps */
.line-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

.episode-card { content-visibility: auto; contain-intrinsic-size: 320px; }

/* Favorites & share */
.fav-btn { transition: transform 0.15s ease, color 0.15s ease; color: var(--text-dim); }
.fav-btn:hover { transform: scale(1.08); color: var(--brand); }
.fav-btn.is-favorited { color: var(--brand); }
.fav-btn.is-favorited svg { fill: var(--brand); }

.share-btn { color: var(--text-dim); transition: color 0.15s ease; }
.share-btn:hover { color: var(--text); }

.share-toast {
    position: fixed;
    bottom: 6rem;
    left: 50%;
    transform: translateX(-50%) translateY(1rem);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 60;
}
.share-toast.visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Hero broadcast glow */
.hero-glow {
    background:
        radial-gradient(ellipse 80% 60% at 20% 30%, rgba(230, 50, 46, 0.12), transparent 60%),
        radial-gradient(ellipse 60% 50% at 80% 70%, rgba(230, 50, 46, 0.06), transparent 50%);
}

.home-now-playing {
    cursor: pointer;
}
.home-now-playing:focus-visible {
    outline: 2px solid var(--brand);
    outline-offset: 2px;
}

.home-now-playing__art {
    width: 5.5rem;
    height: 5.5rem;
    flex-shrink: 0;
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: var(--bg);
}

.home-headline {
    display: flex;
    gap: 0.75rem;
    transition: opacity 0.15s ease;
}
.home-headline:hover { opacity: 0.92; }
.home-headline__thumb {
    width: 4.5rem;
    height: 3.25rem;
    display: block;
    background: var(--surface);
}

.home-cta-band {
    background: linear-gradient(135deg, rgba(230, 50, 46, 0.08) 0%, rgba(24, 24, 27, 0.95) 55%);
}

/* Heritage strip */
.heritage-strip {
    border-left: 3px solid var(--brand);
    padding-left: 1.25rem;
}

/* Player bar accent when live */
#persistent-player.is-live { border-top-color: rgba(230, 50, 46, 0.4) !important; }

/* Legal prose */
.prose-legal h2 {
    font-family: 'Barlow Condensed', sans-serif;
    font-size: 1.375rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text);
    margin-top: 2rem;
    margin-bottom: 0.75rem;
}
.prose-legal h3 { font-size: 1rem; font-weight: 600; color: var(--text); margin-top: 1.5rem; margin-bottom: 0.5rem; }
.prose-legal p, .prose-legal li { color: var(--text-muted); line-height: 1.75; }
.prose-legal ul { list-style: disc; padding-left: 1.5rem; margin: 0.75rem 0; }
.prose-legal a { color: var(--brand); text-decoration: underline; }

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

/* Stat blocks */
.stat-value {
    font-family: 'Barlow Condensed', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    font-style: italic;
    line-height: 1;
    color: var(--text);
}
.stat-value.brand { color: var(--brand); }

.app-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: 9999px;
    transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}
.app-pill:hover {
    color: var(--text);
    border-color: rgba(230, 50, 46, 0.35);
    background: var(--brand-dim);
}

.status-badge {
    display: inline-block;
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0.2rem 0.5rem;
    border-radius: 0.25rem;
    margin-top: 0.25rem;
}
.status-soon {
    color: var(--text-dim);
    background: rgba(255, 255, 255, 0.06);
}
.status-beta {
    color: var(--brand);
    background: var(--brand-dim);
}

/* App promo hero card */
.app-promo-hero {
    box-shadow: 0 0 0 1px rgba(230, 50, 46, 0.12), 0 8px 32px rgba(0, 0, 0, 0.25);
}

/* Mobile app promo bottom sheet */
.app-promo-sheet {
    position: fixed;
    inset: 0;
    z-index: 55;
    pointer-events: none;
}
.app-promo-sheet:not(.hidden) {
    pointer-events: auto;
}
.app-promo-sheet-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.app-promo-sheet-panel {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 1.25rem 1.25rem calc(1.25rem + env(safe-area-inset-bottom, 0px));
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px));
    background: var(--surface);
    border-top: 1px solid var(--border-strong);
    border-radius: 1rem 1rem 0 0;
    box-shadow: 0 -8px 40px rgba(0, 0, 0, 0.45);
    transform: translateY(100%);
    transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
}
.app-promo-sheet.is-visible .app-promo-sheet-backdrop {
    opacity: 1;
}
.app-promo-sheet.is-visible .app-promo-sheet-panel {
    transform: translateY(0);
}
.app-promo-sheet-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.375rem;
    color: var(--text-dim);
    border-radius: 0.375rem;
    transition: color 0.15s ease;
}
.app-promo-sheet-close:hover {
    color: var(--text);
}
.app-promo-sheet-later {
    transition: color 0.15s ease;
}
.app-promo-sheet-later:hover {
    color: var(--text-muted);
}
body.app-promo-open {
    overflow: hidden;
}

/* News */
.news-cat-badge {
    display: inline-block;
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0.2rem 0.5rem;
    border-radius: 0.25rem;
}
.news-filter-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.4rem 0.875rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 9999px;
    border: 1px solid var(--border-strong);
    color: var(--text-muted);
    transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}
.news-filter-pill:hover {
    color: var(--text);
    border-color: rgba(255, 255, 255, 0.25);
}
.news-filter-pill.is-active {
    color: var(--text);
    background: var(--brand-dim);
    border-color: var(--pill-color, var(--brand));
}

/* Article reading experience */
.news-article-header { max-width: 46rem; }
.news-article-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1rem;
    font-size: 0.875rem;
    color: var(--text-dim);
}
.news-article-meta__source {
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}
.news-article-meta__full::before {
    content: '·';
    margin-right: 1rem;
    color: var(--text-dim);
}
.news-article-hero {
    margin: 0;
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--surface);
}
.news-article-hero__img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    object-position: center;
}
.news-article-content { max-width: 42rem; }
.news-article-lede {
    font-size: 1.3125rem;
    line-height: 1.65;
    color: #e4e4e7;
    font-weight: 500;
    margin: 0 0 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border);
}
.news-article-body {
    color: #d4d4d8;
    font-size: 1.125rem;
    line-height: 1.8;
    letter-spacing: 0.01em;
}
.news-article-body > *:first-child { margin-top: 0; }
.news-article-body > *:last-child { margin-bottom: 0; }
.news-article-body p {
    margin: 0 0 1.5rem;
    text-wrap: pretty;
}
.news-article-body p:first-of-type {
    font-size: 1.1875rem;
    line-height: 1.75;
    color: #e4e4e7;
}
.news-article-body h2,
.news-article-body h3,
.news-article-body h4 {
    font-family: 'Barlow Condensed', sans-serif;
    color: var(--text);
    font-weight: 800;
    letter-spacing: 0.01em;
    margin: 2.25rem 0 1rem;
    line-height: 1.15;
}
.news-article-body h2 { font-size: 1.625rem; }
.news-article-body h3 { font-size: 1.375rem; }
.news-article-body ul,
.news-article-body ol {
    margin: 0 0 1.5rem 1.25rem;
    padding: 0;
}
.news-article-body li {
    margin-bottom: 0.625rem;
    padding-left: 0.25rem;
}
.news-article-body a {
    color: var(--brand);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
}
.news-article-body a:hover { color: var(--brand-hover); }
.news-article-body figure {
    margin: 2rem 0;
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--surface);
}
.news-article-body .news-article-img,
.news-article-body img {
    display: block;
    width: 100%;
    height: auto;
    margin: 0;
    border: 0;
    border-radius: 0;
}
.news-article-body blockquote {
    margin: 2rem 0;
    padding: 1.125rem 1.25rem;
    border-left: 3px solid var(--brand);
    background: rgba(24, 24, 27, 0.8);
    border-radius: 0 0.5rem 0.5rem 0;
    color: #e4e4e7;
    font-size: 1.0625rem;
}
.news-article-note {
    max-width: 42rem;
    font-size: 0.875rem;
    color: var(--text-dim);
    margin: 2rem 0 0;
    padding: 1rem 1.125rem;
    background: var(--surface);
    border-radius: 0.5rem;
    border: 1px solid var(--border);
}
.news-article-footer {
    max-width: 42rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

@media (min-width: 768px) {
    .app-promo-sheet { display: none !important; }
}

@media (prefers-reduced-motion: reduce) {
    .live-dot, .animate-ping { animation: none !important; }
    .audio-bar { transition: none; }
    .card:hover { transform: none; }
}
