:root {
    --purple: #5423d7;
    --purple-dark: #32108f;
    --purple-light: #ede8ff;

    --mint: #bfffc7;

    --background: #f5f6f8;
    --card: #ffffff;

    --text: #15131a;
    --muted: #73717b;

    --border: #e8e8ec;

    --radius: 18px;
}


* {
    box-sizing: border-box;
}


html {
    scroll-behavior: smooth;
}


body {
    margin: 0;

    font-family: "Inter", sans-serif;

    background:
        radial-gradient(
            circle at top right,
            rgba(84, 35, 215, .08),
            transparent 30%
        ),
        var(--background);

    color: var(--text);
}


/* HEADER */

.topbar {
    background: var(--purple);
    min-height: 86px;

    display: flex;
    align-items: center;

    box-shadow: 0 2px 15px rgba(0,0,0,.12);
}


.topbar-inner {
    width: min(1400px, calc(100% - 48px));

    margin: auto;

    display: flex;
    align-items: center;
    justify-content: space-between;
}


.brand {
    display: flex;
    align-items: center;
}


.brand-logo {
    width: 205px;
    max-height: 52px;
}


.archive-label {
    color: white;

    font-size: 14px;
    font-weight: 600;

    display: flex;
    align-items: center;
    gap: 9px;

    padding: 10px 16px;

    border: 1px solid rgba(255,255,255,.22);

    border-radius: 100px;

    background: rgba(255,255,255,.08);
}


.archive-dot {
    width: 8px;
    height: 8px;

    background: var(--mint);

    border-radius: 50%;

    box-shadow: 0 0 0 5px rgba(191,255,199,.12);
}


/* PAGE */

.main-container {
    width: min(1400px, calc(100% - 48px));

    margin: auto;
}


/* HERO */

.hero {
    padding: 75px 0 55px;
}


.eyebrow {
    color: var(--purple);

    font-size: 12px;
    font-weight: 800;

    letter-spacing: 1.8px;

    margin-bottom: 12px;
}


.hero h1,
.station-header h1 {
    margin: 0;

    font-size: clamp(38px, 5vw, 64px);

    letter-spacing: -2.5px;

    line-height: 1.02;
}


.hero-copy {
    max-width: 650px;

    margin: 18px 0 30px;

    color: var(--muted);

    font-size: 17px;
    line-height: 1.7;
}


.hero-stats {
    display: flex;

    gap: 45px;
}


.hero-stats div {
    display: flex;
    flex-direction: column;

    gap: 4px;
}


.hero-stats strong {
    font-size: 21px;
}


.hero-stats span {
    color: var(--muted);

    font-size: 12px;
    font-weight: 600;

    text-transform: uppercase;

    letter-spacing: .6px;
}


/* CONTENT */

.content-section {
    padding-bottom: 80px;
}


.section-heading {
    margin-bottom: 25px;

    display: flex;
    align-items: flex-end;
    justify-content: space-between;
}


.section-heading h2 {
    margin: 0 0 6px;

    font-size: 27px;

    letter-spacing: -.8px;
}


.section-heading p {
    margin: 0;

    color: var(--muted);

    font-size: 14px;
}


/* STATIONS */

.station-grid {
    display: grid;

    grid-template-columns:
        repeat(auto-fit, minmax(300px, 1fr));

    gap: 20px;
}


.station-card {
    min-height: 220px;

    padding: 25px;

    display: flex;
    flex-direction: column;
    justify-content: space-between;

    text-decoration: none;

    color: var(--text);

    background: var(--card);

    border: 1px solid var(--border);

    border-radius: var(--radius);

    box-shadow:
        0 4px 20px rgba(20,15,40,.04);

    transition:
        transform .2s ease,
        box-shadow .2s ease,
        border-color .2s ease;
}


.station-card:hover {
    transform: translateY(-5px);

    border-color: rgba(84,35,215,.25);

    box-shadow:
        0 18px 40px rgba(48,25,110,.12);
}


.station-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}


.station-icon,
.station-header-icon {
    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: var(--purple-light);

    color: var(--purple);

    border-radius: 13px;
}


.station-icon svg,
.station-header-icon svg,
.show-icon svg {
    width: 25px;
    height: 25px;

    fill: none;

    stroke: currentColor;

    stroke-width: 2;

    stroke-linecap: round;
}


.arrow {
    width: 37px;
    height: 37px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    color: var(--purple);

    background: #f5f2ff;

    font-size: 19px;

    transition: all .2s ease;
}


.station-card:hover .arrow {
    background: var(--purple);

    color: white;

    transform: translateX(3px);
}


.station-card h3 {
    margin: 0 0 17px;

    font-size: 27px;

    letter-spacing: -1px;
}


.station-meta {
    display: flex;

    gap: 24px;

    color: var(--text);

    font-size: 13px;

    font-weight: 700;
}


.station-meta span {
    display: flex;
    flex-direction: column;

    gap: 3px;
}


.station-meta small {
    color: var(--muted);

    font-size: 10px;

    font-weight: 500;

    text-transform: uppercase;

    letter-spacing: .5px;
}


/* BREADCRUMB */

.breadcrumb {
    padding-top: 32px;

    display: flex;
    gap: 10px;
    align-items: center;

    font-size: 13px;

    color: var(--muted);
}


.breadcrumb a {
    color: var(--purple);

    text-decoration: none;

    font-weight: 600;
}


/* STATION HEADER */

.station-header {
    padding: 55px 0 50px;

    display: flex;
    align-items: center;

    gap: 22px;
}


.station-header-icon {
    width: 72px;
    height: 72px;

    border-radius: 20px;
}


.station-header-icon svg {
    width: 35px;
    height: 35px;
}


.station-header p {
    margin: 12px 0 0;

    color: var(--muted);
}


/* SHOWS */

.show-grid {
    display: grid;

    grid-template-columns:
        repeat(auto-fit, minmax(380px, 1fr));

    gap: 14px;
}


.show-card {
    padding: 20px;

    display: flex;
    align-items: center;

    gap: 17px;

    background: white;

    border: 1px solid var(--border);

    border-radius: 15px;

    transition: .2s ease;
}


.show-card:hover {
    border-color: rgba(84,35,215,.28);

    box-shadow:
        0 10px 28px rgba(35,20,80,.08);

    transform: translateY(-2px);
}


.show-icon {
    flex: 0 0 43px;

    width: 43px;
    height: 43px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 11px;

    background: var(--purple-light);

    color: var(--purple);
}


.show-icon svg {
    width: 21px;
}


.show-content {
    flex: 1;

    min-width: 0;
}


.show-content h3 {
    margin: 0 0 8px;

    font-size: 15px;

    white-space: nowrap;

    overflow: hidden;

    text-overflow: ellipsis;
}


.show-details {
    display: flex;

    gap: 18px;

    color: var(--muted);

    font-size: 11px;
}


.show-details strong {
    color: var(--text);
}


.show-arrow {
    color: var(--purple);

    font-size: 20px;

    padding-right: 4px;
}


/* FOOTER */

footer {
    border-top: 1px solid var(--border);

    background: white;
}


.footer-inner {
    width: min(1400px, calc(100% - 48px));

    margin: auto;

    padding: 28px 0;

    color: var(--muted);

    font-size: 12px;
}


/* MOBILE */

@media (max-width: 700px) {

    .main-container,
    .topbar-inner,
    .footer-inner {
        width: calc(100% - 28px);
    }

    .topbar {
        min-height: 72px;
    }

    .brand-logo {
        width: 160px;
    }

    .archive-label {
        font-size: 11px;

        padding: 8px 11px;
    }

    .hero {
        padding: 50px 0 40px;
    }

    .hero-stats {
        gap: 25px;

        flex-wrap: wrap;
    }

    .station-grid,
    .show-grid {
        grid-template-columns: 1fr;
    }

    .station-header {
        padding: 40px 0;
    }

}

/* ================================
   SHOW / RECORDINGS
================================ */

.show-card {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.show-header {
    padding: 55px 0 45px;
    display: flex;
    align-items: center;
    gap: 22px;
}

.show-header-icon {
    width: 72px;
    height: 72px;
    flex: 0 0 72px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--purple);
    color: white;
    border-radius: 20px;
    box-shadow: 0 12px 30px rgba(84,35,215,.20);
}

.show-header-icon svg {
    width: 35px;
    height: 35px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
}

.show-header h1 {
    margin: 0;
    font-size: clamp(30px, 4vw, 48px);
    letter-spacing: -1.8px;
}

.show-summary {
    display: flex;
    gap: 22px;
    margin-top: 13px;
    color: var(--muted);
    font-size: 12px;
}

.show-summary strong {
    color: var(--text);
}

.recordings-section {
    padding-bottom: 80px;
}

.recordings-toolbar {
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 30px;
}

.recordings-toolbar h2 {
    margin: 0 0 5px;
    font-size: 26px;
    letter-spacing: -.7px;
}

.recordings-toolbar p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.search-box {
    width: min(390px, 100%);
    position: relative;
}

.search-box svg {
    width: 18px;
    height: 18px;
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    fill: none;
    stroke: var(--muted);
    stroke-width: 2;
}

.search-box input {
    width: 100%;
    padding: 14px 17px 14px 45px;
    font-family: inherit;
    font-size: 13px;
    background: white;
    border: 1px solid var(--border);
    border-radius: 12px;
    outline: none;
    transition: .2s ease;
}

.search-box input:focus {
    border-color: var(--purple);
    box-shadow: 0 0 0 3px rgba(84,35,215,.08);
}

.recordings-list {
    background: white;
    border: 1px solid var(--border);
    border-radius: 17px;
    overflow: hidden;
    box-shadow: 0 5px 25px rgba(30,20,60,.04);
}

.recording-row {
    min-height: 78px;
    padding: 13px 19px;
    display: flex;
    align-items: center;
    gap: 17px;
    border-bottom: 1px solid var(--border);
    transition: background .15s ease;
}

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

.recording-row:hover {
    background: #faf9ff;
}

.recording-play {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: var(--purple-light);
    color: var(--purple);
    cursor: pointer;
    transition: .2s ease;
}

.recording-play:hover {
    background: var(--purple);
    color: white;
    transform: scale(1.06);
}

.recording-play svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
    margin-left: 2px;
}

.recording-main {
    flex: 1;
    min-width: 0;
}

.recording-title {
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 650;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.recording-meta {
    color: var(--muted);
    font-size: 11px;
}

.recording-duration,
.recording-size {
    min-width: 80px;
    color: var(--muted);
    font-size: 11px;
    text-align: right;
}

.recording-arrow {
    color: var(--purple);
    font-size: 23px;
    padding-left: 7px;
}

@media (max-width: 700px) {
    .recordings-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .search-box {
        width: 100%;
    }

    .recording-size {
        display: none;
    }

    .recording-duration {
        min-width: auto;
    }

    .show-header {
        align-items: flex-start;
    }
}

/* ================================
   AUDIO PLAYER + DATE FILTER
================================ */

.archive-filters {
    display: flex;
    align-items: center;
    gap: 12px;
}

.date-form {
    display: flex;
    align-items: center;
    gap: 8px;
}

.date-form input {
    padding: 13px 14px;
    font-family: inherit;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: white;
    outline: none;
}

.date-form input:focus {
    border-color: var(--purple);
}

.date-form button {
    padding: 13px 17px;
    border: 0;
    border-radius: 12px;
    background: var(--purple);
    color: white;
    font-family: inherit;
    font-weight: 700;
    cursor: pointer;
}

.date-form button:hover {
    background: var(--purple-dark);
}

.clear-date {
    color: var(--purple);
    text-decoration: none;
    font-size: 12px;
    font-weight: 700;
}

.audio-player {
    display: none;
    margin-bottom: 20px;
    padding: 24px 26px 20px;
    background: white;
    border: 1px solid rgba(84,35,215,.18);
    border-radius: 18px;
    box-shadow: 0 12px 35px rgba(50,16,143,.08);
}

.audio-player.visible {
    display: block;
}

.player-top {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.main-play-button {
    width: 50px;
    height: 50px;
    flex: 0 0 50px;
    border: 0;
    border-radius: 50%;
    background: var(--purple);
    color: white;
    font-size: 17px;
    cursor: pointer;
    box-shadow: 0 8px 22px rgba(84,35,215,.25);
}

.main-play-button:hover {
    transform: scale(1.04);
}

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

.player-label {
    margin-bottom: 5px;
    color: var(--purple);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.4px;
}

.player-title {
    font-size: 15px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-time {
    color: var(--muted);
    font-size: 12px;
    font-variant-numeric: tabular-nums;
}

#waveform {
    width: 100%;
    min-height: 92px;
}

.recording-row.active {
    background: #f5f1ff;
    box-shadow: inset 4px 0 0 var(--purple);
}

.no-recordings {
    padding: 55px 25px;
    text-align: center;
    background: white;
    border: 1px solid var(--border);
    border-radius: 17px;
}

.no-recordings h3 {
    margin: 0 0 8px;
}

.no-recordings p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

@media (max-width: 900px) {
    .recordings-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .archive-filters {
        align-items: stretch;
        flex-direction: column;
    }

    .date-form {
        flex-wrap: wrap;
    }

    .search-box {
        width: 100%;
    }
}

/* ================================
   ARCHIVE DATE NAVIGATOR
================================ */

.date-navigator {
    display: flex;
    align-items: center;
    gap: 7px;
}

.date-picker-button {
    height: 46px;
    min-width: 265px;
    padding: 0 17px;
    display: flex;
    align-items: center;
    gap: 10px;

    position: relative;

    background: white;
    border: 1px solid var(--border);
    border-radius: 13px;

    cursor: pointer;

    box-shadow: 0 3px 12px rgba(30,20,60,.035);

    transition:
        border-color .15s ease,
        box-shadow .15s ease,
        transform .15s ease;
}

.date-picker-button:hover {
    border-color: rgba(84,35,215,.35);
    box-shadow: 0 5px 18px rgba(84,35,215,.08);
}

.calendar-icon {
    color: var(--purple);
    font-size: 15px;
}

.date-picker-text {
    flex: 1;

    color: var(--text);

    font-size: 12px;
    font-weight: 700;

    white-space: nowrap;
}

.date-picker-button input {
    position: absolute;
    inset: 0;

    width: 100%;
    height: 100%;

    opacity: 0;
    cursor: pointer;
}

.date-nav-arrow {
    width: 46px;
    height: 46px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: white;

    border: 1px solid var(--border);
    border-radius: 13px;

    color: var(--purple);

    text-decoration: none;
    font-size: 18px;
    font-weight: 700;

    transition: .15s ease;
}

.date-nav-arrow:hover {
    color: white;
    background: var(--purple);
    border-color: var(--purple);
    transform: translateY(-1px);
}

.latest-button {
    height: 46px;
    padding: 0 17px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: var(--purple-light);

    border-radius: 13px;

    color: var(--purple);

    text-decoration: none;
    font-size: 11px;
    font-weight: 800;

    transition: .15s ease;
}

.latest-button:hover {
    background: var(--purple);
    color: white;
}

@media (max-width: 700px) {

    .date-navigator {
        width: 100%;
    }

    .date-picker-button {
        min-width: 0;
        flex: 1;
    }

    .latest-button {
        display: none;
    }

}

/* Date picker click fix */
.date-picker-button input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

/* ================================
   RELIABLE NATIVE DATE PICKER
================================ */

.real-date-picker {
    height: 46px;
    padding: 0 14px;

    display: flex;
    align-items: center;
    gap: 8px;

    background: #fff;
    border: 1px solid var(--border);
    border-radius: 13px;

    box-shadow: 0 3px 12px rgba(30,20,60,.035);
    transition: .15s ease;
}

.real-date-picker:hover {
    border-color: rgba(84,35,215,.4);
    box-shadow: 0 5px 18px rgba(84,35,215,.08);
}

.real-date-picker:focus-within {
    border-color: var(--purple);
    box-shadow: 0 0 0 3px rgba(84,35,215,.08);
}

.date-calendar-icon {
    font-size: 14px;
}

.real-date-picker input[type="date"] {
    position: static !important;
    width: 145px !important;
    height: auto !important;

    padding: 0 !important;
    margin: 0;

    opacity: 1 !important;
    pointer-events: auto !important;

    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;

    color: var(--text);
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;

    cursor: pointer;
}

.real-date-picker input[type="date"]::-webkit-calendar-picker-indicator {
    cursor: pointer;
}
