/* ==============================================
   View Toggle — Grid / List přepínač
   ============================================== */

/* --- Toggle bar --- */
.view-toggle {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 3px;
    border-radius: 10px;
    background: var(--t-glass-bg, rgba(255, 255, 255, 0.06));
    border: 1px solid var(--t-glass-border, rgba(255, 255, 255, 0.08));
    backdrop-filter: blur(12px) saturate(140%);
    -webkit-backdrop-filter: blur(12px) saturate(140%);
}

.view-toggle__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 30px;
    border: none;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--t-text-muted, rgba(255, 255, 255, 0.4));
    cursor: pointer;
    transition: background 0.25s ease, color 0.25s ease;
    padding: 0;
}

.view-toggle__btn.active {
    background: var(--t-accent-muted, rgba(100, 120, 200, 0.2));
    color: var(--t-accent-solid, #6478c8);
}

/* SVG icons inside toggle */
.view-toggle__btn svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

/* --- Filter toolbar (contains toggle + optional label) --- */
.filter-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 16px;
}

.filter-toolbar__label {
    font-family: var(--font-mono, ui-monospace, monospace);
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--t-text-muted, rgba(255, 255, 255, 0.4));
}


/* ==============================================
   Compact Grid Mode — menší karty, více sloupců
   ============================================== */

/* Grid override for compact mode */
.editorial-grid--compact {
    gap: 10px;
    grid-template-columns: repeat(2, 1fr) !important;
}

.editorial-grid--compact .ed-card__image-wrap {
    aspect-ratio: 4 / 3;
}

.editorial-grid--compact .ed-card__body {
    padding: 10px 12px 12px;
}

.editorial-grid--compact .ed-card__title {
    font-size: 0.8rem;
    -webkit-line-clamp: 2;
}

.editorial-grid--compact .ed-card--featured .ed-card__title {
    font-size: 0.8rem;
}

.editorial-grid--compact .ed-card__excerpt {
    display: none;
}

.editorial-grid--compact .ed-card__date {
    padding-top: 6px;
    font-size: 0.55rem;
}

.editorial-grid--compact .ed-card__badges {
    gap: 4px;
}

.editorial-grid--compact .ed-card__badge {
    padding: 3px 7px;
    font-size: 0.55rem;
}

.editorial-grid--compact .ed-card {
    --ac-radius: 12px;
}

/* Tablet — 3 columns */
@media (min-width: 640px) {
    .editorial-grid--compact {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

/* Desktop — 4 columns */
@media (min-width: 1024px) {
    .editorial-grid--compact {
        grid-template-columns: repeat(4, 1fr) !important;
    }
}


/* ==============================================
   Playlist List View — horizontální karty
   ============================================== */

/* --- Grid override for list mode --- */
.editorial-grid--list {
    grid-template-columns: 1fr !important;
    gap: 8px;
}

/* --- Wrapper (card + expand) = jedna glass karta --- */
.pl-list__wrapper {
    border-radius: 12px;
    overflow: hidden;
    background: var(--t-glass-bg, rgba(255, 255, 255, 0.04));
    backdrop-filter: blur(12px) saturate(140%);
    -webkit-backdrop-filter: blur(12px) saturate(140%);
    border: 1px solid var(--t-glass-border, rgba(255, 255, 255, 0.08));
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.pl-list__wrapper--expanded .pl-list__card {
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.pl-list__wrapper--expanded .pl-list__chevron {
    transform: rotate(180deg);
}

/* --- Chevron indicator --- */
.pl-list__chevron {
    display: flex;
    align-items: center;
    padding: 0 4px;
    color: var(--t-text-muted, rgba(255, 255, 255, 0.3));
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.pl-list__chevron svg {
    width: 14px;
    height: 14px;
}

/* --- Expand panel --- */
.pl-list__expand {
    display: none;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
}

.pl-list__expand-content {
    padding: 0;
}

/* Tracklist uvnitř expand — bez vlastního glass rámečku */
.pl-list__expand-content .tracklist {
    margin-top: 0;
    padding: 0.75rem 1rem 1rem;
    background: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: none;
    box-shadow: none;
    border-radius: 0;
}

.pl-list__expand-content .tracklist::before {
    display: none;
}

.pl-list__expand-content .tracklist__item {
    margin-inline: 0;
    padding: 0.625rem 0.5rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.02);
}

.pl-list__expand-content .tracklist__item+.tracklist__item {
    margin-top: 2px;
    border-top: none;
}

.pl-list__expand-content .tracklist__header {
    padding-inline: 0;
}

.pl-list__expand-loading {
    padding: 16px;
    text-align: center;
    font-size: 0.75rem;
    color: var(--t-text-muted, rgba(255, 255, 255, 0.4));
}

/* ==============================================
   Compact Radio Card (v expand panelu)
   Premium Liquid Glass — matches modal radio-card
   ============================================== */
.pl-radio-compact {
    overflow: hidden;
    margin-bottom: 0;
    background: none;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

/* --- Banner (modal radio-card style — full width) --- */
.pl-radio-compact__banner {
    position: relative;
    height: 120px;
    overflow: hidden;
}

.pl-radio-compact__banner img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.3);
    filter: brightness(0.75) contrast(1.1) saturate(1.15);
}

.pl-radio-compact__banner::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom,
            transparent 20%,
            rgba(0, 0, 0, 0.85) 100%);
    pointer-events: none;
}

/* --- Body --- */
.pl-radio-compact__body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 16px;
}

.pl-radio-compact__info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* --- Badge (Live Radio — orange glow) --- */
.pl-radio-compact__badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono, ui-monospace, monospace);
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(249, 115, 22, 0.85);
}

.pl-radio-compact__badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #F97316;
    box-shadow: 0 0 8px rgba(249, 115, 22, 0.5);
    animation: pl-pulse 2s ease-in-out infinite;
}

@keyframes pl-pulse {

    0%,
    100% {
        opacity: 1;
        box-shadow: 0 0 8px rgba(249, 115, 22, 0.5);
    }

    50% {
        opacity: 0.5;
        box-shadow: 0 0 16px rgba(249, 115, 22, 0.8);
    }
}

/* --- Radio name --- */
.pl-radio-compact__name {
    font-size: clamp(1rem, 0.9rem + 0.5vw, 1.2rem);
    font-weight: 700;
    color: var(--t-text-strong, #f3f4f6);
    line-height: 1.2;
    letter-spacing: -0.015em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- Host row (circle icon + name + voice badge) --- */
.pl-radio-compact__host {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pl-radio-compact__host-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(249, 115, 22, 0.1);
    border: 1px solid rgba(249, 115, 22, 0.2);
    color: #F97316;
    flex-shrink: 0;
}

.pl-radio-compact__host-icon svg {
    width: 14px;
    height: 14px;
}

.pl-radio-compact__host-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--t-text-strong, #f3f4f6);
}

/* --- Voice badge (orange tint) --- */
.pl-radio-compact__voice {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 100px;
    background: rgba(249, 115, 22, 0.1);
    border: 1px solid rgba(249, 115, 22, 0.2);
    color: #F97316;
    font-family: var(--font-mono, ui-monospace, monospace);
    font-size: 0.6rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* --- Broadcast pill button (orange gradient + glow) --- */
.pl-radio-compact__broadcast {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border: none;
    border-radius: 100px;
    background: linear-gradient(135deg, #F97316, #EA580C);
    color: #fff;
    font-family: var(--font-mono, ui-monospace, monospace);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    flex-shrink: 0;
    box-shadow: 0 4px 16px rgba(249, 115, 22, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.pl-radio-compact__broadcast:active {
    transform: scale(0.95);
}

/* --- List card (header row) --- */
.pl-list__card {
    display: flex;
    align-items: stretch;
    gap: 0;
    padding: 0;
    background: none;
    border: none;
    cursor: pointer;
    overflow: hidden;
    min-height: 72px;
}

/* --- Image --- */
.pl-list__image-wrap {
    position: relative;
    width: 72px;
    min-width: 72px;
    flex-shrink: 0;
    overflow: hidden;
}

.pl-list__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Play overlay on image --- */
.pl-list__play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    cursor: pointer;
    color: #fff;
    padding: 0;
    transition: background 0.2s ease, transform 0.2s ease;
}

.pl-list__play-overlay svg {
    width: 24px;
    height: 24px;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.5));
    margin-left: 2px;
}

/* --- Content (title + meta) --- */
.pl-list__content {
    flex: 1;
    min-width: 0;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
}

.pl-list__title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--t-card-title, #fff);
    line-height: 1.25;
    letter-spacing: -0.01em;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- Meta chips row --- */
.pl-list__meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
    overflow: hidden;
}

.pl-list__meta-chip {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-family: var(--font-mono, ui-monospace, monospace);
    font-size: 0.575rem;
    font-weight: 600;
    color: var(--t-text-muted, rgba(255, 255, 255, 0.45));
    white-space: nowrap;
    letter-spacing: 0.03em;
}

.pl-list__meta-chip svg {
    flex-shrink: 0;
    opacity: 0.6;
}

.pl-list__meta-chip--voice {
    padding: 1px 6px;
    border-radius: 100px;
    background: var(--t-accent-muted, rgba(100, 120, 200, 0.15));
    color: var(--t-accent-solid, #6478c8);
    font-size: 0.55rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

/* --- Action buttons --- */
.pl-list__actions {
    display: flex;
    align-items: center;
    gap: 6px;
    padding-right: 10px;
    flex-shrink: 0;
}

.pl-list__action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
    padding: 0;
    flex-shrink: 0;
}

.pl-list__action-btn--broadcast {
    background: linear-gradient(135deg, #F97316, #EA580C);
    color: #fff;
    box-shadow: 0 2px 8px rgba(249, 115, 22, 0.25);
}

.pl-list__action-btn--loading {
    opacity: 0.5;
    pointer-events: none;
}

.pl-list__action-btn:active {
    transform: scale(0.9);
}

/* ==============================================
   Desktop hover (non-touch)
   ============================================== */
@media (hover: hover) {
    .pl-list__card:hover {
        border-color: rgba(255, 255, 255, 0.14);
        box-shadow: 0 6px 24px rgba(0, 0, 0, 0.2);
    }

    .pl-list__play-overlay:hover {
        background: rgba(0, 0, 0, 0.6);
        transform: translate(-50%, -50%) scale(1.1);
    }

    .pl-list__action-btn--broadcast:hover {
        background: linear-gradient(135deg, #FB923C, #F97316);
        transform: scale(1.08);
        box-shadow: 0 4px 14px rgba(249, 115, 22, 0.4);
    }
}

/* ==============================================
   Responsive
   ============================================== */

/* Tablet+ */
@media (min-width: 640px) {
    .pl-list__image-wrap {
        width: 88px;
        min-width: 88px;
    }

    .pl-list__card {
        min-height: 80px;
    }

    .pl-list__title {
        font-size: 1.2rem;
    }

    .pl-list__meta-chip {
        font-size: 0.625rem;
    }

    .pl-list__action-btn {
        width: 38px;
        height: 38px;
    }
}

/* ==============================================
   Article List View — horizontální karty pro články
   ============================================== */
.al-list__card {
    display: flex;
    align-items: stretch;
    gap: 0;
    padding: 0;
    border-radius: 12px;
    background: var(--t-glass-bg, rgba(255, 255, 255, 0.04));
    backdrop-filter: blur(12px) saturate(140%);
    -webkit-backdrop-filter: blur(12px) saturate(140%);
    border: 1px solid var(--t-glass-border, rgba(255, 255, 255, 0.08));
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    overflow: hidden;
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
    min-height: 72px;
}

/* --- Image --- */
.al-list__image-wrap {
    width: 72px;
    min-width: 72px;
    flex-shrink: 0;
    overflow: hidden;
}

.al-list__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Content --- */
.al-list__content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    padding: 10px 14px;
}

.al-list__title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--t-card-title, #fff);
    line-height: 1.25;
    letter-spacing: -0.01em;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- Meta --- */
.al-list__meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
    overflow: hidden;
}

.al-list__meta-chip {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-family: var(--font-mono, ui-monospace, monospace);
    font-size: 0.6rem;
    font-weight: 500;
    color: var(--t-text-muted, rgba(255, 255, 255, 0.45));
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.al-list__meta-chip svg {
    flex-shrink: 0;
    opacity: 0.5;
}

/* --- Tablet+ --- */
@media (min-width: 640px) {
    .al-list__image-wrap {
        width: 88px;
        min-width: 88px;
    }

    .al-list__title {
        font-size: 1.2rem;
    }
}

/* --- Desktop hover --- */
@media (hover: hover) {
    .al-list__card:hover {
        border-color: var(--t-glass-hover-border, rgba(255, 255, 255, 0.14));
        box-shadow: 0 6px 24px rgba(0, 0, 0, 0.2);
    }
}

/* ==============================================
   Reduced motion
   ============================================== */
@media (prefers-reduced-motion: reduce) {

    .view-toggle__btn,
    .pl-list__card,
    .pl-list__action-btn,
    .al-list__card {
        transition: none;
    }
}