/* =========================================================================
 * Module Channels — frontend public (YouTube-like)
 * ========================================================================= */

.channels-page {
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px 16px 64px;
}

.channels-page .muted { color: var(--bzk-dm-text-muted, #888); }

/* ----------- Toolbar / tabs / search ----------- */
.channels-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.channels-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.channels-tabs a {
    padding: 8px 16px;
    background: var(--bzk-dm-surface-2, #f1f3f5);
    border-radius: 999px;
    color: var(--bzk-dm-text, #333);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all .15s;
}
.channels-tabs a:hover { background: var(--bzk-dm-surface-3, #e0e3e6); }
.channels-tabs a.active { background: #111; color: #fff; }

.channels-search {
    display: flex;
    align-items: center;
    background: var(--bzk-dm-surface-2, #f1f3f5);
    border-radius: 999px;
    padding: 4px 4px 4px 16px;
}
.channels-search input {
    background: transparent;
    border: 0;
    outline: 0;
    padding: 8px 0;
    width: 240px;
    font-size: 14px;
}
.channels-search button {
    background: var(--bzk-dm-surface, #fff);
    border: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
}
.channels-search.big {
    margin: 24px auto 32px;
    max-width: 600px;
    padding: 8px 8px 8px 20px;
}
.channels-search.big input { width: 100%; font-size: 16px; padding: 12px 0; }

/* ----------- Sections ----------- */
.channels-section { margin: 32px 0 48px; }
.channels-section h2 { font-size: 20px; margin-bottom: 16px; font-weight: 600; }

/* ----------- Grid de cartes ----------- */
.channels-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.media-card { display: block; color: inherit; text-decoration: none; }
.media-card:hover { text-decoration: none; }
.media-card-thumb {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
}
.media-card-thumb img,
.media-card-thumb-placeholder {
    width: 100%; height: 100%; object-fit: cover; display: block;
}
.media-card-thumb-placeholder {
    background: linear-gradient(135deg, #2c3e50, #4ca1af);
    display: flex; align-items: center; justify-content: center;
}
.media-card-thumb-placeholder i { color: #fff; font-size: 3rem; opacity: .6; }
.media-card-duration {
    position: absolute;
    bottom: 8px; right: 8px;
    background: rgba(0,0,0,.8);
    color: #fff;
    font-size: 12px;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 500;
}
.media-card-premium {
    position: absolute;
    top: 8px; left: 8px;
    background: #ffc107;
    color: #000;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    font-weight: 700;
}
.media-card-type {
    position: absolute;
    top: 8px; right: 8px;
    background: rgba(0,0,0,.7);
    color: #fff;
    width: 28px; height: 28px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    font-size: 14px;
}
.media-card-body { padding: 12px 4px 0; }
.media-card-title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
    margin: 0 0 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.media-card-channel { font-size: 13px; color: var(--bzk-dm-text-2, #555); margin-bottom: 2px; }
.media-card-meta { font-size: 12px; color: var(--bzk-dm-text-muted, #888); }

/* ----------- Channel pills ----------- */
.channels-row-channels {
    display: flex; gap: 16px; overflow-x: auto; padding-bottom: 8px;
}
.channel-pill {
    flex: 0 0 160px;
    text-align: center;
    text-decoration: none;
    color: inherit;
}
.channel-pill img,
.channel-pill-placeholder {
    width: 96px; height: 96px;
    border-radius: 50%;
    margin: 0 auto 8px;
    object-fit: cover;
    display: block;
    background: linear-gradient(135deg, #6e7e93, #4ca1af);
    color: #fff;
    font-size: 36px;
    font-weight: 700;
    line-height: 96px;
    text-align: center;
}
.channel-pill-title { display: block; font-weight: 600; font-size: 14px; }
.channel-pill-subs { display: block; color: var(--bzk-dm-text-muted, #888); font-size: 12px; }

/* ----------- Page chaîne ----------- */
.channel-banner {
    height: 200px;
    background-size: cover;
    background-position: center;
    border-radius: 12px;
    margin-bottom: 24px;
}
.channel-header {
    display: flex; gap: 24px; align-items: flex-start; margin-bottom: 24px;
    flex-wrap: wrap;
}
.channel-header-cover img,
.cover-placeholder {
    width: 120px; height: 120px; border-radius: 50%; object-fit: cover;
    background: linear-gradient(135deg, #6e7e93, #4ca1af);
    color: #fff; display: flex; align-items: center; justify-content: center;
    font-size: 48px; font-weight: 700;
}
.channel-header-meta { flex: 1; min-width: 240px; }
.channel-header-meta h1 { margin: 0 0 4px; font-size: 28px; }
.channel-stats { color: var(--bzk-dm-text-muted, #888); margin: 0 0 12px; }
.channel-description { color: var(--bzk-dm-text-2, #444); max-width: 720px; }

.btn-subscribe {
    background: #111; color: #fff;
    border: 0;
    padding: 10px 24px;
    border-radius: 999px;
    font-weight: 600;
    cursor: pointer;
    transition: all .15s;
}
.btn-subscribe:hover { background: #333; }
.btn-subscribe.subscribed { background: var(--bzk-dm-surface-3, #e9ecef); color: var(--bzk-dm-text, #111); }

.channel-tabs {
    display: flex; gap: 24px;
    border-bottom: 1px solid var(--bzk-dm-border, #e9ecef);
    margin-bottom: 24px;
}
.channel-tabs a {
    padding: 12px 0;
    color: var(--bzk-dm-text-2, #555);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 2px solid transparent;
}
.channel-tabs a.active { color: var(--bzk-dm-text, #111); border-bottom-color: #111; }

/* ----------- Page Watch ----------- */
.watch-page {
    max-width: 1600px; margin: 0 auto;
    padding: 16px;
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 24px;
}
@media (max-width: 1100px) { .watch-page { grid-template-columns: 1fr; } }

.watch-player-wrap {
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    position: relative;
}
.watch-player-wrap video,
.watch-player-wrap audio {
    width: 100%; height: 100%; display: block;
}
.audio-player-cover { position: absolute; inset: 0; }
.audio-player-cover img { width: 100%; height: 100%; object-fit: cover; }

.watch-title { font-size: 22px; margin: 16px 0 8px; }
.watch-meta { color: var(--bzk-dm-text-muted, #888); font-size: 14px; margin-bottom: 16px; }
.watch-actions {
    display: flex; gap: 12px; align-items: center;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--bzk-dm-border, #e9ecef);
    padding-bottom: 20px;
}
.btn-like, .btn-share {
    background: var(--bzk-dm-surface-2, #f1f3f5);
    border: 0;
    padding: 8px 18px;
    border-radius: 999px;
    cursor: pointer;
    font-size: 14px;
    display: inline-flex; align-items: center; gap: 8px;
}
.btn-like.liked { background: var(--bzk-dm-surface-2, #e7f5ff); color: #1971c2; }
.btn-like:hover, .btn-share:hover { background: var(--bzk-dm-surface-3, #e0e3e6); }

.watch-channel {
    display: flex; align-items: center; justify-content: space-between;
    padding: 16px 0;
    border-bottom: 1px solid var(--bzk-dm-border, #e9ecef);
    margin-bottom: 20px;
}
.watch-channel-link { display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.watch-channel-link img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.watch-channel-link strong { display: block; }
.watch-channel-link small { color: var(--bzk-dm-text-muted, #888); }

.watch-event-cta {
    background: linear-gradient(135deg, #ff6a00, #ee0979);
    color: #fff;
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
}
.watch-event-cta i { font-size: 22px; }
.watch-event-cta .btn-buy {
    margin-left: auto;
    background: var(--bzk-dm-surface, #fff); color: var(--bzk-dm-text, #000);
    padding: 8px 20px; border-radius: 999px; font-weight: 700;
    text-decoration: none;
}

.watch-description {
    background: var(--bzk-dm-surface-2, #f8f9fa);
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    white-space: pre-wrap;
}

.watch-comments h3 { font-size: 16px; margin-bottom: 12px; }
#comment-form {
    display: flex; flex-direction: column; gap: 8px;
    margin-bottom: 24px;
}
#comment-form textarea {
    border: 1px solid var(--bzk-dm-border, #ddd); padding: 8px 12px; border-radius: 8px;
    font-family: inherit; resize: vertical; min-height: 60px;
}
#comment-form button {
    align-self: flex-end;
    background: #111; color: #fff; border: 0; padding: 8px 18px;
    border-radius: 999px; cursor: pointer; font-weight: 600;
}

.comment { padding: 12px 0; border-bottom: 1px solid var(--bzk-dm-border, #f1f3f5); }
.comment-meta { color: var(--bzk-dm-text-muted, #888); font-size: 12px; margin-bottom: 4px; }

/* Sidebar related */
.watch-sidebar h3 { font-size: 16px; margin-bottom: 12px; }
.related-card {
    display: flex; gap: 8px;
    margin-bottom: 12px;
    text-decoration: none; color: inherit;
}
.related-card img,
.related-card-thumb-empty {
    flex: 0 0 168px;
    aspect-ratio: 16/9;
    object-fit: cover;
    border-radius: 8px;
    background: #ddd;
}
.related-card-info h4 {
    font-size: 14px; font-weight: 600;
    margin: 0 0 2px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
    overflow: hidden;
}
.related-card-info small { display: block; color: var(--bzk-dm-text-muted, #888); font-size: 12px; }

/* Playlist row */
.channels-row-playlists {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}
.playlist-card {
    display: block;
    text-decoration: none; color: inherit;
    background: var(--bzk-dm-surface-2, #f8f9fa);
    border-radius: 12px;
    overflow: hidden;
}
.playlist-card img { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; }
.playlist-card h4 { padding: 12px; margin: 0; font-size: 14px; }

/* Playlist header */
.playlist-header {
    display: flex; gap: 24px; margin-bottom: 32px; flex-wrap: wrap;
}
.playlist-cover {
    width: 240px; aspect-ratio: 16/9;
    object-fit: cover; border-radius: 12px;
}

/* Library section header */
.library-section-header {
    display: flex; align-items: baseline; justify-content: space-between;
    margin-bottom: 16px;
}
.library-section-header a {
    font-size: 14px; color: #1971c2; text-decoration: none;
}

/* Subscription rows */
.subscriptions-list { display: grid; gap: 8px; max-width: 720px; }
.subscription-row {
    display: flex; align-items: center; gap: 16px;
    padding: 12px; border: 1px solid var(--bzk-dm-border, #e9ecef); border-radius: 12px;
    text-decoration: none; color: inherit;
}
.subscription-row:hover { background: var(--bzk-dm-surface-2, #f8f9fa); }
.subscription-row img,
.subscription-row .cover-placeholder.small {
    width: 56px; height: 56px;
    border-radius: 50%; object-fit: cover;
    font-size: 20px; line-height: 56px;
}
.subscription-row strong { display: block; }
.subscription-row small { color: var(--bzk-dm-text-muted, #888); }

/* Misc */
.btn-link-danger {
    background: none; border: 0; color: #c92a2a; cursor: pointer; font-size: 14px;
}
.btn-link-danger:hover { text-decoration: underline; }

/* =========================================================================
 * Hero — landing /play
 * ========================================================================= */
.play-hero {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    margin: 0 0 28px;
    color: #fff;
    isolation: isolate;
}
.play-hero-bg {
    position: absolute; inset: 0;
    background:
        radial-gradient(ellipse at top left, rgba(255,106,0,.35) 0%, transparent 55%),
        radial-gradient(ellipse at bottom right, rgba(127,0,255,.35) 0%, transparent 55%),
        linear-gradient(135deg, #0f1117 0%, #1a1d29 100%);
    z-index: -1;
}
.play-hero-bg::after {
    content: "";
    position: absolute; inset: 0;
    background-image:
        radial-gradient(circle at 25% 30%, rgba(255,255,255,.06) 1px, transparent 1px),
        radial-gradient(circle at 70% 60%, rgba(255,255,255,.04) 1px, transparent 1px);
    background-size: 80px 80px, 60px 60px;
    opacity: .8;
}
.play-hero-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 56px 48px;
    flex-wrap: wrap;
}
.play-hero-text { flex: 1; min-width: 280px; max-width: 640px; }
.play-hero-eyebrow {
    display: inline-flex; align-items: center; gap: 6px;
    background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.15);
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .3px;
    color: #fbe1b3;
    margin-bottom: 14px;
}
.play-hero-eyebrow i { color: #ff9a3c; font-size: 14px; }
.play-hero h1 {
    font-size: 56px;
    font-weight: 800;
    line-height: 1;
    margin: 0 0 12px;
    letter-spacing: -1px;
}
.play-hero-accent {
    background: linear-gradient(135deg, #ff6a00, #ee0979 50%, #7f00ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.play-hero-tagline {
    font-size: 18px;
    color: rgba(255,255,255,.78);
    max-width: 540px;
    margin: 0 0 24px;
    line-height: 1.5;
}
.play-hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.play-hero .btn-subscribe {
    background: var(--bzk-dm-surface, #fff); color: var(--bzk-dm-text, #111);
    padding: 12px 26px;
}
.play-hero .btn-subscribe:hover { background: var(--bzk-dm-surface-2, #f1f3f5); }
.play-hero .btn-share {
    background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.2);
    color: #fff;
    padding: 11px 24px;
    border-radius: 999px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex; align-items: center; gap: 8px;
}
.play-hero .btn-share:hover { background: rgba(255,255,255,.18); }

/* Visuel hero — petites cartes flottantes décoratives */
.play-hero-visual {
    position: relative;
    width: 240px; height: 240px;
    flex-shrink: 0;
    display: none;
}
@media (min-width: 900px) { .play-hero-visual { display: block; } }
.play-hero-card {
    position: absolute;
    width: 96px; height: 96px;
    border-radius: 20px;
    display: flex; align-items: center; justify-content: center;
    font-size: 36px;
    color: #fff;
    box-shadow: 0 12px 30px rgba(0,0,0,.4);
    animation: play-float 6s ease-in-out infinite;
}
.play-hero-card-1 { top: 0; left: 40px; background: linear-gradient(135deg,#ff6a00,#ee0979); }
.play-hero-card-2 { top: 60px; right: 0; background: linear-gradient(135deg,#7f00ff,#e100ff); animation-delay: -2s; }
.play-hero-card-3 { bottom: 0; left: 20px; background: linear-gradient(135deg,#00b09b,#96c93d); animation-delay: -4s; }
@keyframes play-float {
    0%, 100% { transform: translateY(0) rotate(-3deg); }
    50%      { transform: translateY(-12px) rotate(3deg); }
}

@media (max-width: 700px) {
    .play-hero-inner { padding: 36px 24px; }
    .play-hero h1 { font-size: 40px; }
    .play-hero-tagline { font-size: 16px; }
}

/* =========================================================================
 * Section header (h2 + lien droite)
 * ========================================================================= */
.channels-section-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 16px;
    gap: 12px;
    flex-wrap: wrap;
}
.channels-section-header h2 { margin: 0; }
.channels-section-link {
    font-size: 14px;
    color: var(--bzk-dm-text-2, #555);
    text-decoration: none;
    font-weight: 600;
    transition: color .15s;
}
.channels-section-link:hover { color: #ee0979; }

/* =========================================================================
 * Card hover polish — applique aussi aux mockups
 * ========================================================================= */
.media-card {
    transition: transform .18s ease, box-shadow .18s ease;
    cursor: pointer;
}
.media-card:hover { transform: translateY(-3px); }
.media-card:hover .media-card-thumb { box-shadow: 0 10px 30px rgba(0,0,0,.18); }
.media-card-thumb { transition: box-shadow .18s ease; }

.channel-pill {
    transition: transform .15s ease;
    cursor: pointer;
}
.channel-pill:hover { transform: translateY(-2px); }
.channel-pill:hover .channel-pill-title { color: #ee0979; }

/* Badge "EN DIRECT" sur la durée */
.media-card-duration.is-live {
    background: #e03131;
    text-transform: uppercase;
    letter-spacing: .5px;
    font-weight: 700;
}
.media-card-duration.is-live::before {
    content: ""; display: inline-block;
    width: 6px; height: 6px;
    background: var(--bzk-dm-surface, #fff);
    border-radius: 50%;
    margin-right: 4px;
    vertical-align: middle;
    animation: play-pulse 1.4s ease-in-out infinite;
}
@keyframes play-pulse { 0%,100%{opacity:.4;} 50%{opacity:1;} }

/* =========================================================================
 * Empty state — bannière + mockups + CTA finale
 * ========================================================================= */
.play-empty-banner {
    display: flex;
    align-items: center;
    gap: 24px;
    background: linear-gradient(135deg, #fff8e1 0%, #fff1f8 100%);
    border: 1px solid #ffe0b2;
    border-radius: 16px;
    padding: 28px 32px;
    margin-bottom: 36px;
    flex-wrap: wrap;
}
.play-empty-banner .play-empty-icon {
    width: 72px; height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff6a00, #ee0979);
    color: #fff;
    font-size: 32px;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 8px 22px rgba(238,9,121,.3);
    flex-shrink: 0;
}
.play-empty-body { flex: 1; min-width: 260px; }
.play-empty-body h2 { margin: 0 0 6px; font-size: 24px; font-weight: 700; }
.play-empty-body p { margin: 0 0 16px; color: var(--bzk-dm-text-2, #555); font-size: 15px; line-height: 1.5; }
.play-empty-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.play-empty-banner .btn-share {
    background: var(--bzk-dm-surface, #fff);
    border: 1px solid var(--bzk-dm-border, #ddd);
    color: var(--bzk-dm-text-2, #555);
    padding: 9px 22px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex; align-items: center; gap: 8px;
}
.play-empty-banner .btn-share:hover { background: var(--bzk-dm-surface-2, #f8f9fa); color: var(--bzk-dm-text, #111); }

/* Sections mockup — badge + look "aperçu" légèrement plus pâle */
.play-mock-section h2 {
    display: inline-flex; align-items: center; gap: 10px;
}
.play-mock-badge {
    display: inline-flex; align-items: center; gap: 4px;
    background: linear-gradient(135deg, #fff3cd, #ffe0b2);
    color: #b45309;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 999px;
    letter-spacing: .3px;
    text-transform: uppercase;
}
.play-mock-badge i { font-size: 12px; }

/* Cartes mock : cliquables visuellement mais inertes — un peu désaturées */
.play-mock-card {
    position: relative;
    opacity: .96;
    cursor: default !important;
}
.play-mock-card::after {
    content: "";
    position: absolute; inset: 0;
    background: transparent;
    pointer-events: none;
}
.play-mock-card:hover { transform: none; }
.play-mock-card .channel-pill-placeholder { line-height: 96px; }

/* CTA finale après les mockups */
.play-empty-cta {
    background: linear-gradient(135deg, #0f1117 0%, #1a1d29 100%);
    color: #fff;
    border-radius: 18px;
    padding: 40px 32px;
    text-align: center;
    margin-top: 48px;
}
.play-empty-cta h3 {
    font-size: 26px;
    font-weight: 700;
    margin: 0 0 10px;
}
.play-empty-cta p {
    color: rgba(255,255,255,.75);
    margin: 0 0 22px;
    font-size: 15px;
    max-width: 540px;
    margin-left: auto; margin-right: auto;
    line-height: 1.5;
}
.play-empty-cta .btn-subscribe {
    background: linear-gradient(135deg, #ff6a00, #ee0979);
    padding: 12px 28px;
    font-size: 15px;
    box-shadow: 0 6px 18px rgba(238,9,121,.4);
}
.play-empty-cta .btn-subscribe:hover { background: linear-gradient(135deg, #ff7a1a, #f2289a); }
