/* MEDIA AI NETWORK — interface compacte, contrastée et technologique. */
.live-mode-switch{display:inline-flex;gap:4px;margin-top:9px;padding:4px;border:1px solid #34506d;border-radius:999px;background:#0b1726}
.live-mode-switch a{display:inline-flex;align-items:center;justify-content:center;min-height:34px;padding:6px 14px;border:1px solid transparent;border-radius:999px;color:#c7d7e8;text-decoration:none;font-size:12px;font-weight:750;transition:background .15s ease,border-color .15s ease,color .15s ease}
.live-mode-switch a:hover{border-color:#4bd7f2;color:#fff}
.live-mode-switch a[aria-current="true"]{border-color:#2f94ae;background:linear-gradient(110deg,#087b89,#155e9a);color:#fff;box-shadow:0 3px 12px #0004}
.header-brand-copy .live-mode-switch{margin-top:10px}
html[data-site-mode="internet"] body{background:#252a30!important;color:#e4e7eb!important}
html[data-site-mode="internet"] .app-global-nav{background:#191e23!important;border-color:#444b53!important;box-shadow:0 5px 18px #0005!important}
html[data-site-mode="internet"] .app-global-nav .app-nav-links>a{background:linear-gradient(145deg,#383e45,#2c3238)!important;border-color:#4b535c!important;color:#e2e5e9!important}
html[data-site-mode="internet"] .app-nav-channels{background:#292f35!important;border-color:#485059!important}
html[data-site-mode="internet"] .app-nav-channels .app-channel-link{background:#363c43!important;border-color:#515962!important;color:#e3e6e9!important}
html[data-site-mode="internet"] main .card,html[data-site-mode="internet"] main .panel,html[data-site-mode="internet"] main .live-card,html[data-site-mode="internet"] main .summary-card,html[data-site-mode="internet"] main .dashboard-calendar,html[data-site-mode="internet"] main .calendar-panel{background:#32383f!important;border-color:#4d555e!important;color:#e3e6e9!important;box-shadow:0 8px 24px #0003!important}
html[data-site-mode="internet"] main h1,html[data-site-mode="internet"] main h2,html[data-site-mode="internet"] main h3,html[data-site-mode="internet"] main .section-title{color:#f0f2f4!important}
html[data-site-mode="internet"] main p,html[data-site-mode="internet"] main label,html[data-site-mode="internet"] main .description{color:#c2c8ce}
html[data-site-mode="internet"] .live-mode-switch{background:#1c2228;border-color:#505860}
html[data-site-mode="internet"] .live-mode-switch a{color:#e0e4e8}
html[data-site-mode="internet"] .live-mode-switch a[aria-current="true"]{background:#59616a;border-color:#747d86;color:#fff;box-shadow:0 2px 8px #0004}
:root {
    color-scheme: dark;
    --tech-bg: #08111f;
    --tech-panel: #142238;
    --tech-panel-raised: #1a2c45;
    --tech-border: #2e4968;
    --tech-cyan: #4bd7f2;
    --tech-blue: #438cff;
    --tech-violet: #a78bfa;
    --tech-text: #e7f0ff;
    --tech-muted: #a8bad1;
}

html { scroll-behavior: smooth; }
body {
    color: var(--tech-text) !important;
    font-family: "Segoe UI", Arial, sans-serif !important;
    background-color: var(--tech-bg) !important;
    background-image:
        radial-gradient(ellipse at 15% 0%, rgba(37, 99, 235, .16), transparent 40%),
        radial-gradient(ellipse at 90% 12%, rgba(20, 184, 166, .10), transparent 36%),
        linear-gradient(rgba(75, 215, 242, .025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(75, 215, 242, .025) 1px, transparent 1px) !important;
    background-size: auto, auto, 36px 36px, 36px 36px !important;
    background-attachment: fixed !important;
}

.app-global-nav {
    gap: 5px !important;
    padding: 6px max(12px, calc((100vw - 1500px) / 2)) !important;
    border-bottom: 1px solid rgba(75, 215, 242, .28) !important;
    background: rgba(11, 22, 39, .96) !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .24), 0 1px rgba(75, 215, 242, .08) inset !important;
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
}
.app-nav-links { gap: 5px !important; }
.app-global-nav .app-nav-links > a {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    min-height: 31px;
    padding: 5px 8px !important;
    border-color: #304a68 !important;
    border-radius: 7px !important;
    background: linear-gradient(145deg, #192a41, #122037) !important;
    color: #dceaff !important;
    font-size: 11px !important;
    line-height: 1.1;
    transition: border-color .16s ease, color .16s ease, transform .16s ease, box-shadow .16s ease;
}
.app-global-nav .app-nav-links > a:hover,
.app-global-nav .app-nav-links > a:focus-visible {
    color: #fff !important;
    border-color: var(--tech-cyan) !important;
    box-shadow: 0 0 13px rgba(75, 215, 242, .16);
    transform: translateY(-1px);
}
.app-global-nav .nav-icon {
    display: inline-grid;
    place-items: center;
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
    border: 1px solid rgba(75, 215, 242, .28);
    border-radius: 5px;
    background: rgba(28, 94, 133, .24);
    color: var(--tech-cyan);
    font: 600 12px/1 "Segoe UI Symbol", "Segoe UI", sans-serif;
}
.app-nav-right { gap: 5px 10px !important; }
.app-nav-channels {
    gap: 4px !important;
    padding: 3px 5px !important;
    border-color: rgba(75, 215, 242, .22) !important;
    border-radius: 9px !important;
    background: linear-gradient(135deg, rgba(18, 63, 91, .5), rgba(20, 44, 68, .66)) !important;
    box-shadow: none !important;
}
.app-global-nav .app-nav-channels .app-channel-link,
.app-global-nav .app-nav-channels a.app-channel-link,
.app-global-nav .app-nav-channels button.app-channel-link {
    min-height: 30px !important;
    gap: 5px !important;
    padding: 3px 7px !important;
    border-color: rgba(75, 215, 242, .25) !important;
    border-radius: 7px !important;
    background: linear-gradient(145deg, #173a48, #152e42) !important;
    color: #e4fbff !important;
    font-size: 11px !important;
    box-shadow: none !important;
}
.app-nav-channels .app-channel-link img {
    width: 22px !important;
    height: 22px !important;
    flex-basis: 22px !important;
    border-radius: 5px !important;
}
.app-nav-account { gap: 5px 9px !important; font-size: 11px !important; }
.app-global-nav .app-nav-account > span { white-space: nowrap; }

/* Compacte les commandes et les champs sans masquer ni supprimer de contrôle. */
button, input, select, textarea {
    font-family: inherit;
}
button, input[type="button"], input[type="submit"], input[type="reset"] {
    min-height: 32px;
    padding: 6px 10px;
    border-radius: 6px;
    transition: filter .14s ease, box-shadow .14s ease, transform .14s ease;
}
button:hover, input[type="submit"]:hover { filter: brightness(1.09); }
button:active, input[type="submit"]:active { transform: translateY(1px); }
input:not([type="checkbox"]):not([type="radio"]):not([type="file"]), select {
    min-height: 32px;
    padding: 6px 9px;
    border-radius: 6px;
}
textarea { padding: 8px 9px; border-radius: 6px; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--tech-cyan); }
:focus-visible { outline-color: var(--tech-cyan) !important; outline-offset: 2px; }

/* Cartes plus denses, avec relief léger et accents colorés cohérents. */
:where(.panel, .card, .program-card, .live-card, .bulk-retirement, .batch-transcode, .notice, .backup-status) {
    border-radius: 9px;
    box-shadow: 0 5px 16px rgba(0, 0, 0, .12), inset 0 1px rgba(219, 242, 255, .025);
}
.panel, .card, .program-card, .live-card, .bulk-retirement, .batch-transcode {
    border-color: var(--tech-border);
}
.panel, .card, .bulk-retirement, .batch-transcode { padding: 13px; }
.program-card { padding: 11px 13px; }
.live-card { padding: 8px 11px; }
.panel h1, .card h1, .bulk-retirement h1, .batch-transcode h1,
.panel h2, .card h2, .bulk-retirement h2, .batch-transcode h2,
.panel h3, .card h3, .bulk-retirement h3, .batch-transcode h3,
.panel h4, .card h4, .bulk-retirement h4, .batch-transcode h4 {
    letter-spacing: .01em;
}
.panel h2::after, .card h2::after, .bulk-retirement h2::after, .batch-transcode h2::after {
    content: "";
    display: block;
    width: min(68px, 22%);
    height: 2px;
    margin-top: 5px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--tech-cyan), rgba(67, 140, 255, .18));
    opacity: .72;
}
h1, header h1 { font-size: clamp(1.35rem, 2vw, 1.8rem); }
h2 { font-size: 1.12rem; }
h3 { font-size: 1rem; }
label, .help, .muted, small { line-height: 1.4; }
table th, table td { padding: 7px 9px; }
details > summary { cursor: pointer; }
progress { accent-color: var(--tech-cyan); }
.messages, .notice, [role="alert"] { border-radius: 7px; }
.radioboss-playlist {
    margin: 9px 0;
    padding: 10px;
    overflow: hidden;
    border: 1px solid rgba(75, 215, 242, .32);
    border-radius: 9px;
    background: linear-gradient(145deg, rgba(17, 40, 62, .94), rgba(14, 27, 46, .96));
    box-shadow: inset 0 1px rgba(220, 250, 255, .04), 0 5px 15px rgba(0, 0, 0, .16);
}
.radioboss-playlist-head { display:flex; align-items:center; gap:9px; }
.radioboss-live-icon { display:grid; place-items:center; width:27px; height:27px; flex:0 0 27px; border:1px solid rgba(75, 215, 242, .35); border-radius:8px; background:rgba(20, 105, 127, .22); color:var(--tech-cyan); font-size:17px; }
.radioboss-playlist-heading { display:grid; gap:2px; min-width:0; }
.radioboss-playlist-heading strong { color:#e7f7ff; font-size:12px; }
.radioboss-playlist-heading small,.radioboss-playlist-footnote { color:var(--tech-muted); font-size:10px; }
.radioboss-live-badge { display:inline-flex; align-items:center; gap:5px; flex:0 0 auto; margin-left:auto; padding:4px 7px; border:1px solid rgba(52, 211, 153, .32); border-radius:999px; background:rgba(6, 78, 59, .4); color:#a7f3d0; font-size:9px; font-weight:700; letter-spacing:.04em; }
.radioboss-live-badge span { width:6px; height:6px; border-radius:50%; background:#34d399; box-shadow:0 0 8px rgba(52, 211, 153, .7); }
.radioboss-playlist-count { margin:7px 0 3px; color:var(--tech-cyan); font-size:10px; font-weight:600; }
.radioboss-playlist-status { margin:3px 0 7px; color:#9fb4cb; font-size:10px; }
.radioboss-playlist-status.is-error { color:#fca5a5; }
.radioboss-playlist-scroll { max-height:255px; overflow:auto; border:1px solid rgba(75, 215, 242, .13); border-radius:6px; scrollbar-color:#365875 #0d192a; }
.radioboss-playlist-table { width:100%; border-collapse:collapse; font-size:10px; }
.radioboss-playlist-table th { position:sticky; top:0; z-index:1; padding:6px 7px; background:#172a41; color:#a9c7dc; text-align:left; font-size:9px; letter-spacing:.04em; text-transform:uppercase; }
.radioboss-playlist-table td { padding:5px 7px; border-top:1px solid rgba(74, 105, 137, .22); color:#dbe8f7; }
.radioboss-playlist-table td:first-child,.radioboss-playlist-table td:last-child { white-space:nowrap; color:#9dcaf0; font-variant-numeric:tabular-nums; }
.radioboss-playlist-table td:nth-child(2) { overflow-wrap:anywhere; }
.radioboss-playlist-table tr.is-current td { background:linear-gradient(90deg,rgba(0,230,118,.16),rgba(0,230,118,.06)); color:#effff5; }
.radioboss-playlist-table tr.is-current td { font-weight:800; }
.radioboss-playlist-table tr.is-current td:first-child { box-shadow:inset 3px 0 #00e676; color:#78ffad; }
.radioboss-track-progress { height:4px; margin-top:4px; overflow:hidden; border:1px solid rgba(65,255,151,.55); border-radius:99px; background:#10271a; }
.radioboss-track-progress > span { display:block; width:0; height:100%; border-radius:inherit; background:linear-gradient(90deg,#00c853,#76ffad); box-shadow:0 0 8px rgba(0,230,118,.55); transition:width .8s linear; }
.radioboss-current-badge { display:inline-flex; align-items:center; padding:2px 6px; border:1px solid #20c875; border-radius:999px; background:#07502d; color:#a6ffd0; font-size:9px; font-weight:800; letter-spacing:.04em; white-space:nowrap; }
.radioboss-playlist-table tr.is-past td { background:#252d38; color:#8993a1; }
.radioboss-playlist-table tr.is-past td:first-child { box-shadow:inset 3px 0 #727d8c; color:#a0a9b5; }
.radioboss-playlist-table tr.is-upcoming td:first-child { font-weight:750; }
.radioboss-playlist-table tr.upcoming-color-0 td { background:rgba(36,126,196,.14); }
.radioboss-playlist-table tr.upcoming-color-0 td:first-child { box-shadow:inset 3px 0 #42b7ff; color:#9cddff; }
.radioboss-playlist-table tr.upcoming-color-1 td { background:rgba(148,91,220,.14); }
.radioboss-playlist-table tr.upcoming-color-1 td:first-child { box-shadow:inset 3px 0 #b68cff; color:#d0b7ff; }
.radioboss-playlist-table tr.upcoming-color-2 td { background:rgba(224,143,46,.14); }
.radioboss-playlist-table tr.upcoming-color-2 td:first-child { box-shadow:inset 3px 0 #ffc46b; color:#ffdda4; }
.radioboss-playlist-table tr.upcoming-color-3 td { background:rgba(37,169,157,.14); }
.radioboss-playlist-table tr.upcoming-color-3 td:first-child { box-shadow:inset 3px 0 #4dd0c8; color:#a1fff8; }
.radioboss-playlist-table tr.upcoming-color-4 td { background:rgba(201,92,133,.14); }
.radioboss-playlist-table tr.upcoming-color-4 td:first-child { box-shadow:inset 3px 0 #f48fb1; color:#ffc1d5; }
.radioboss-playlist-table tr.upcoming-color-5 td { background:rgba(133,164,68,.14); }
.radioboss-playlist-table tr.upcoming-color-5 td:first-child { box-shadow:inset 3px 0 #b9dc69; color:#e0f99c; }
.radioboss-playlist-footnote { display:block; margin-top:6px; line-height:1.35; }
dialog, [role="dialog"], .modal, .popup {
    border-radius: 10px;
    border-color: var(--tech-border);
    box-shadow: 0 18px 55px rgba(0, 0, 0, .4), 0 0 24px rgba(67, 140, 255, .1);
}

@media (max-width: 700px) {
    .app-global-nav { padding: 5px 8px !important; max-height: 38vh !important; }
    .app-global-nav .app-nav-links > a { min-height: 29px; padding: 5px 7px !important; }
    .app-nav-channels .app-channel-link img { width: 20px !important; height: 20px !important; flex-basis: 20px !important; }
    .panel, .card, .bulk-retirement, .batch-transcode { padding: 10px; }
    .program-card { padding: 9px 10px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}

/* Accent de marque par chaîne, partagé entre la navigation et les cartes. */
:root {
    --brand-lcr-tv:#29c77a;
    --brand-m24-tv:#ef5364;
    --brand-universal-tv:#e6c64b;
    --brand-lcr-radio:#31cf91;
    --brand-m24-radio:#ef5364;
    --brand-indi-radio:#b27bff;
}
.app-nav-channels form:has(input[name="chaine"][value="LCR_TV"]) .app-channel-link,
.app-nav-channels a[aria-label$="LCR TV"] { border-color:color-mix(in srgb,var(--brand-lcr-tv) 62%,#39536d) !important; background:linear-gradient(145deg,color-mix(in srgb,var(--brand-lcr-tv) 24%,#14243a),#152a3c) !important; box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--brand-lcr-tv) 12%,transparent),0 0 10px color-mix(in srgb,var(--brand-lcr-tv) 12%,transparent) !important; }
.app-nav-channels form:has(input[name="chaine"][value="M24_TV"]) .app-channel-link,
.app-nav-channels a[aria-label$="M24 TV"] { border-color:color-mix(in srgb,var(--brand-m24-tv) 62%,#39536d) !important; background:linear-gradient(145deg,color-mix(in srgb,var(--brand-m24-tv) 23%,#14243a),#152a3c) !important; }
.app-nav-channels form:has(input[name="chaine"][value="UTV"]) .app-channel-link,
.app-nav-channels a[aria-label$="Universal TV"] { border-color:color-mix(in srgb,var(--brand-universal-tv) 65%,#39536d) !important; background:linear-gradient(145deg,color-mix(in srgb,var(--brand-universal-tv) 24%,#14243a),#152a3c) !important; }
.app-nav-channels form:has(input[name="chaine"][value="RADIO_LCR"]) .app-channel-link,
.app-nav-channels a[aria-label$="LCR Radio"] { border-color:color-mix(in srgb,var(--brand-lcr-radio) 62%,#39536d) !important; background:linear-gradient(145deg,color-mix(in srgb,var(--brand-lcr-radio) 22%,#14243a),#152a3c) !important; }
.app-nav-channels form:has(input[name="chaine"][value="RADIO_M24"]) .app-channel-link,
.app-nav-channels a[aria-label$="M24 Radio"] { border-color:color-mix(in srgb,var(--brand-m24-radio) 62%,#39536d) !important; background:linear-gradient(145deg,color-mix(in srgb,var(--brand-m24-radio) 23%,#14243a),#152a3c) !important; }
.app-nav-channels form:has(input[name="chaine"][value="INDI_RADIO"]) .app-channel-link,
.app-nav-channels a[aria-label$="Indi Radio"] { border-color:color-mix(in srgb,var(--brand-indi-radio) 65%,#39536d) !important; background:linear-gradient(145deg,color-mix(in srgb,var(--brand-indi-radio) 24%,#14243a),#152a3c) !important; }
.app-nav-channels form:has(input[name="chaine"][value="LCR_TV"]) .app-channel-link:hover,.app-nav-channels a[aria-label$="LCR TV"]:hover { border-color:var(--brand-lcr-tv) !important;background:linear-gradient(145deg,#236d4d,#173c35) !important;box-shadow:0 0 14px color-mix(in srgb,var(--brand-lcr-tv) 32%,transparent) !important; }
.app-nav-channels form:has(input[name="chaine"][value="M24_TV"]) .app-channel-link:hover,.app-nav-channels a[aria-label$="M24 TV"]:hover,.app-nav-channels form:has(input[name="chaine"][value="RADIO_M24"]) .app-channel-link:hover,.app-nav-channels a[aria-label$="M24 Radio"]:hover { border-color:var(--brand-m24-tv) !important;background:linear-gradient(145deg,#713544,#3c2632) !important;box-shadow:0 0 14px color-mix(in srgb,var(--brand-m24-tv) 32%,transparent) !important; }
.app-nav-channels form:has(input[name="chaine"][value="UTV"]) .app-channel-link:hover,.app-nav-channels a[aria-label$="Universal TV"]:hover { border-color:var(--brand-universal-tv) !important;background:linear-gradient(145deg,#665828,#3b3525) !important;box-shadow:0 0 14px color-mix(in srgb,var(--brand-universal-tv) 32%,transparent) !important; }
.app-nav-channels form:has(input[name="chaine"][value="RADIO_LCR"]) .app-channel-link:hover,.app-nav-channels a[aria-label$="LCR Radio"]:hover { border-color:var(--brand-lcr-radio) !important;background:linear-gradient(145deg,#236d54,#173b3c) !important;box-shadow:0 0 14px color-mix(in srgb,var(--brand-lcr-radio) 32%,transparent) !important; }
.app-nav-channels form:has(input[name="chaine"][value="INDI_RADIO"]) .app-channel-link:hover,.app-nav-channels a[aria-label$="Indi Radio"]:hover { border-color:var(--brand-indi-radio) !important;background:linear-gradient(145deg,#58377b,#33274f) !important;box-shadow:0 0 14px color-mix(in srgb,var(--brand-indi-radio) 32%,transparent) !important; }
.live-card[data-channel="LCR_TV"],.dashboard-calendar[data-channel="LCR_TV"] { --channel-accent:var(--brand-lcr-tv); }
.live-card[data-channel="M24_TV"],.dashboard-calendar[data-channel="M24_TV"] { --channel-accent:var(--brand-m24-tv); }
.live-card[data-channel="UTV"],.dashboard-calendar[data-channel="UTV"] { --channel-accent:var(--brand-universal-tv); }
.live-card[data-channel="RADIO_LCR"],.dashboard-calendar[data-channel="RADIO_LCR"],.radio-calendar-card[data-channel="RADIO_LCR"],#calendrier[data-channel="RADIO_LCR"] { --channel-accent:var(--brand-lcr-radio); }
.live-card[data-channel="RADIO_M24"],.dashboard-calendar[data-channel="RADIO_M24"],.radio-calendar-card[data-channel="RADIO_M24"],#calendrier[data-channel="RADIO_M24"] { --channel-accent:var(--brand-m24-radio); }
.live-card[data-channel="INDI_RADIO"],.dashboard-calendar[data-channel="INDI_RADIO"],.radio-calendar-card[data-channel="INDI_RADIO"],#calendrier[data-channel="INDI_RADIO"] { --channel-accent:var(--brand-indi-radio); }
.live-card[data-channel],.dashboard-calendar[data-channel],.radio-calendar-card[data-channel],#calendrier[data-channel] { border-color:color-mix(in srgb,var(--channel-accent) 48%,#344963); box-shadow:inset 3px 0 var(--channel-accent),0 0 16px color-mix(in srgb,var(--channel-accent) 8%,transparent),0 10px 24px rgba(0,0,0,.16); }
.live-card[data-channel] h3,.dashboard-calendar[data-channel] .dashboard-calendar-head h3,.radio-calendar-card[data-channel] h2 { text-decoration-color:var(--channel-accent); text-decoration-line:underline; text-decoration-thickness:2px; text-underline-offset:6px; }
