:root {
    --bg-main: #0b0e14;
    --surface-card: #121824;
    --surface-hover: #182234;
    --surface-sub: #0e131d;
    --emby-accent: #52b788;
    --emby-glow: rgba(82, 183, 136, 0.35);
    --danger: #ef4444;
    --warning: #f59e0b;
    --text-primary: #f8fafc;
    --text-muted: #94a3b8;
    --border: rgba(255, 255, 255, 0.08);
    --border-active: rgba(82, 183, 136, 0.45);
    --radius-lg: 14px;
    --radius-md: 8px;
}

* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif; }
body { background: var(--bg-main); color: var(--text-primary); min-height: 100vh; }

/* Connexion */
.login-overlay { position: fixed; inset: 0; z-index: 10000; display: flex; flex-direction: column; justify-content: space-between; align-items: center; background: #000; overflow-y: auto; padding: 24px; }
.login-backdrop { position: absolute; inset: 0; background: radial-gradient(circle at 50% 30%, rgba(82, 183, 136, 0.18) 0%, transparent 65%), #0b0e14; z-index: 1; }
.login-header { position: relative; z-index: 2; width: 100%; max-width: 1100px; }
.login-box-wrapper { position: relative; z-index: 2; width: 100%; display: flex; justify-content: center; margin: auto 0; }
.login-card { width: 100%; max-width: 440px; background: rgba(18, 24, 36, 0.95); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 36px 30px; box-shadow: 0 20px 40px rgba(0, 0, 0, 0.8); }
.login-card h2 { font-size: 1.8em; margin-bottom: 6px; }
.login-subtitle { color: var(--text-muted); font-size: 0.85em; margin-bottom: 22px; }
.login-error-msg { display: none; background: rgba(239, 68, 68, 0.15); border: 1px solid var(--danger); color: #fca5a5; padding: 10px; border-radius: var(--radius-md); font-size: 0.85em; margin-bottom: 16px; }
.input-floating { position: relative; margin-bottom: 16px; }
.input-floating input { width: 100%; height: 52px; padding: 18px 14px 6px 14px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border); border-radius: var(--radius-md); color: #fff; font-size: 0.95em; outline: none; }
.input-floating input:focus { border-color: var(--emby-accent); }
.input-floating label { position: absolute; top: 16px; left: 14px; color: var(--text-muted); font-size: 0.9em; pointer-events: none; transition: 0.2s; }
.input-floating input:focus ~ label, .input-floating input:not(:placeholder-shown) ~ label { top: 6px; font-size: 0.7em; color: var(--emby-accent); }
.btn-netflix-submit { width: 100%; height: 48px; background: var(--emby-accent); border: none; border-radius: var(--radius-md); color: #0b0e14; font-weight: 800; font-size: 1em; cursor: pointer; }
.login-extra { display: flex; justify-content: space-between; margin-top: 14px; font-size: 0.8em; color: var(--text-muted); }

/* Navigation */
.portal-container { min-height: 100vh; display: flex; flex-direction: column; }
.navbar { display: flex; justify-content: space-between; align-items: center; padding: 12px 20px; background: rgba(11, 14, 20, 0.95); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 500; }
.brand { display: flex; align-items: center; gap: 8px; }
.brand-title { font-weight: 800; font-size: 1.15em; color: var(--emby-accent); }
.brand-sub { font-size: 0.7em; color: var(--text-muted); }
.nav-links { display: flex; gap: 6px; }
.nav-btn { background: transparent; border: 1px solid transparent; color: var(--text-muted); padding: 6px 14px; border-radius: 999px; font-weight: 700; font-size: 0.82em; cursor: pointer; }
.nav-btn:hover { color: #fff; background: rgba(255, 255, 255, 0.05); }
.nav-btn.active { background: rgba(82, 183, 136, 0.16); border-color: var(--emby-accent); color: var(--emby-accent); }
.nav-btn.report-btn.active { background: rgba(239, 68, 68, 0.16); border-color: var(--danger); color: var(--danger); }
.user-badge { background: rgba(255, 255, 255, 0.06); border: 1px solid var(--border); padding: 4px 10px; border-radius: 6px; font-size: 0.78em; font-weight: 700; }
.btn-logout { background: transparent; border: 1px solid var(--border); color: var(--text-muted); padding: 4px 8px; border-radius: 6px; font-size: 0.75em; cursor: pointer; }

.main-container { max-width: 1000px; width: 100%; margin: 24px auto; padding: 0 16px; flex: 1; }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* Hero & Guides */
.hero-banner { background: var(--surface-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 30px 20px; text-align: center; margin-bottom: 24px; }
.server-status-pill { display: inline-flex; align-items: center; gap: 8px; background: rgba(82, 183, 136, 0.12); border: 1px solid var(--emby-accent); color: var(--emby-accent); padding: 5px 14px; border-radius: 999px; font-weight: 700; font-size: 0.8em; margin-top: 14px; }
.pulse-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--emby-accent); }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.feature-card { background: var(--surface-card); border: 1px solid var(--border); padding: 20px; border-radius: var(--radius-lg); }

.platform-tabs { display: flex; justify-content: center; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; }
.plat-btn { background: var(--surface-card); border: 1px solid var(--border); color: var(--text-muted); padding: 8px 16px; border-radius: var(--radius-md); font-weight: 700; font-size: 0.82em; cursor: pointer; }
.plat-btn.active { background: var(--emby-accent); color: #0b0e14; border-color: var(--emby-accent); }
.guide-block { display: none; flex-direction: column; gap: 10px; max-width: 700px; margin: 0 auto; }
.guide-block.active { display: flex; }
.step-card { display: flex; gap: 14px; background: var(--surface-card); border: 1px solid var(--border); padding: 14px 18px; border-radius: var(--radius-md); align-items: flex-start; }
.step-num { width: 28px; height: 28px; border-radius: 50%; background: rgba(82, 183, 136, 0.15); border: 1px solid var(--emby-accent); color: var(--emby-accent); font-weight: 800; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }

/* ========================================= */
/* CATALOGUE : LISTE AVEC ARBORESCENCE       */
/* ========================================= */
.catalog-controls { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
#catalog-search { width: 100%; background: var(--surface-card); border: 1px solid var(--border); padding: 14px 18px; border-radius: var(--radius-md); color: #fff; font-size: 0.95em; outline: none; transition: border-color 0.2s; }
#catalog-search:focus { border-color: var(--emby-accent); box-shadow: 0 0 10px var(--emby-glow); }

.filters-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { background: var(--surface-card); border: 1px solid var(--border); color: var(--text-muted); padding: 6px 14px; border-radius: 999px; font-size: 0.8em; font-weight: 700; cursor: pointer; }
.chip.active { background: var(--emby-accent); color: #0b0e14; border-color: var(--emby-accent); }

.list-meta-bar { display: flex; justify-content: flex-end; font-size: 0.78em; color: var(--text-muted); margin-bottom: 8px; padding: 0 4px; }
.media-list-container { display: flex; flex-direction: column; gap: 8px; }

.list-group {
    background: var(--surface-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: border-color 0.2s ease;
}
.list-group.is-open {
    border-color: var(--border-active);
}

.list-row {
    padding: 13px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    background: var(--surface-card);
    transition: background 0.15s;
}
.list-row.is-clickable {
    cursor: pointer;
}
.list-row.is-clickable:hover {
    background: var(--surface-hover);
}

.list-row-left { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 1; }
.list-icon { font-size: 1.25em; flex-shrink: 0; }
.list-title-wrap { display: flex; align-items: center; gap: 8px; min-width: 0; flex-wrap: wrap; }
.list-title { font-weight: 700; font-size: 0.95em; color: #fff; word-break: break-word; }
.badge-new-inline { background: linear-gradient(135deg, #f59e0b, #d97706); color: #000; font-size: 0.65em; font-weight: 800; padding: 2px 6px; border-radius: 4px; flex-shrink: 0; }

.list-row-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

.list-children-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(82, 183, 136, 0.12);
    border: 1px solid rgba(82, 183, 136, 0.35);
    color: var(--emby-accent);
    font-size: 0.75em;
    font-weight: 800;
    padding: 3px 8px;
    border-radius: 6px;
}

.list-chevron {
    font-size: 0.7em;
    transition: transform 0.2s ease;
}
.list-chevron.open {
    transform: rotate(180deg);
}

.list-type-tag { background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border); color: var(--text-muted); font-size: 0.75em; font-weight: 700; padding: 4px 8px; border-radius: 6px; }
.list-year { background: rgba(255, 255, 255, 0.08); border: 1px solid var(--border); color: var(--text-primary); font-size: 0.8em; font-weight: 800; padding: 4px 10px; border-radius: 6px; white-space: nowrap; }
.list-year-empty { color: var(--text-muted); font-size: 0.85em; padding: 0 4px; }

/* Sous-éléments dépliés */
.list-sub-items {
    background: var(--surface-sub);
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.sub-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 16px 10px 38px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    gap: 12px;
}
.sub-item-row:last-child {
    border-bottom: none;
}
.sub-item-row:hover {
    background: rgba(255, 255, 255, 0.02);
}

.sub-item-title-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.sub-item-branch {
    color: var(--emby-accent);
    font-weight: 700;
    font-size: 1em;
}
.sub-item-title {
    color: #e2e8f0;
    font-size: 0.88em;
    font-weight: 600;
    word-break: break-word;
}
.sub-item-year {
    color: var(--text-muted);
    font-size: 0.78em;
    font-weight: 700;
    white-space: nowrap;
}

/* Formulaires */
.form-container { max-width: 600px; margin: 0 auto 24px auto; background: var(--surface-card); border: 1px solid var(--border); padding: 20px; border-radius: var(--radius-lg); }
.form-container.warning-border { border-color: rgba(239, 68, 68, 0.35); }
.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
label { font-size: 0.8em; font-weight: 700; color: var(--text-muted); }
input, select, textarea { width: 100%; background: #07090e; border: 1px solid var(--border); padding: 10px; border-radius: 6px; color: #fff; font-size: 0.88em; outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--emby-accent); }
textarea { resize: vertical; min-height: 60px; }
.submit-btn { width: 100%; background: var(--emby-accent); color: #0b0e14; border: none; padding: 10px; border-radius: 6px; font-weight: 800; font-size: 0.9em; cursor: pointer; }
.submit-btn.btn-danger { background: var(--danger); color: #fff; }
.recent-requests { max-width: 600px; margin: 0 auto; }
.recent-requests h3 { font-size: 1em; margin-bottom: 10px; }
.requests-list { display: flex; flex-direction: column; gap: 8px; }
.request-item { background: var(--surface-card); border: 1px solid var(--border); border-radius: 6px; padding: 10px 14px; display: flex; justify-content: space-between; align-items: center; }
.req-status { font-size: 0.72em; font-weight: 800; padding: 2px 8px; border-radius: 999px; }
.req-status.demande { background: rgba(56, 189, 248, 0.15); color: #38bdf8; }
.req-status.attente { background: rgba(245, 158, 11, 0.15); color: var(--warning); }

@media (max-width: 650px) {
    .navbar { flex-wrap: wrap; gap: 8px; }
    .brand-sub { display: none; }
    .nav-links { order: 3; width: 100%; overflow-x: auto; }
    .list-row { flex-direction: column; align-items: flex-start; gap: 8px; }
    .list-row-right { width: 100%; justify-content: space-between; }
    .sub-item-row { padding-left: 20px; }
    .form-row { grid-template-columns: 1fr; }
}

/* Style Médias Sur Demande */
.badge-ondemand {
    background: rgba(168, 85, 247, 0.18);
    border: 1px solid rgba(168, 85, 247, 0.5);
    color: #c084fc;
    font-size: 0.65em;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

.list-group.is-ondemand {
    border-color: rgba(168, 85, 247, 0.2);
}
.list-group.is-ondemand:hover {
    border-color: rgba(168, 85, 247, 0.45);
}

.btn-action-ondemand {
    background: rgba(168, 85, 247, 0.15);
    border: 1px solid rgba(168, 85, 247, 0.4);
    color: #e9d5ff;
    font-size: 0.75em;
    font-weight: 800;
    padding: 5px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.btn-action-ondemand:hover {
    background: #9333ea;
    color: #fff;
    border-color: #a855f7;
    box-shadow: 0 0 10px rgba(168, 85, 247, 0.4);
}

/* ==========================================================================
   NOUVEAU DESIGN DE L'ESPACE ADMINISTRATEUR
   ========================================================================== */

.admin-header-panel {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.4), rgba(15, 23, 42, 0.7));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
}

.kpi-grid {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.kpi-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 10px 18px;
    min-width: 110px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}
.kpi-card:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
}
.kpi-label {
    font-size: 0.75em;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}
.kpi-value {
    font-size: 1.6em;
    font-weight: 800;
    color: #fff;
    margin-top: 2px;
}
.kpi-card.kpi-purple .kpi-value { color: #c084fc; }
.kpi-card.kpi-cyan .kpi-value { color: #38bdf8; }
.kpi-card.kpi-red .kpi-value { color: #f87171; }

/* Navigation segmentée */
.admin-segmented-nav {
    display: flex;
    gap: 10px;
    background: rgba(15, 23, 42, 0.6);
    padding: 6px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    margin-bottom: 25px;
}
.admin-segment-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 18px;
    border-radius: 9px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-weight: 700;
    font-size: 0.95em;
    cursor: pointer;
    transition: all 0.2s ease;
}
.admin-segment-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}
.admin-segment-btn.active {
    background: var(--emby-accent);
    color: #fff;
    box-shadow: 0 4px 15px rgba(82, 181, 75, 0.35);
}
.admin-segment-btn .icon {
    font-size: 1.15em;
}

.pill-badge {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 0.75em;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 700;
}
.pill-badge.red {
    background: #ef4444;
}

/* Grille Utilisateurs */
.admin-two-cols {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 24px;
}
@media (max-width: 900px) {
    .admin-two-cols { grid-template-columns: 1fr; }
}

.glass-card {
    background: rgba(30, 41, 59, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 16px;
    padding: 22px;
}
.card-title-bar {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding-bottom: 14px;
}
.card-title-bar h3 {
    font-size: 1.05em;
    font-weight: 700;
    color: #f1f5f9;
}

/* Roster Utilisateurs */
.users-roster {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
    max-height: 520px;
    overflow-y: auto;
    padding-right: 4px;
}
.user-row-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 12px 16px;
    transition: 0.2s;
}
.user-row-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}
.user-row-left {
    display: flex;
    align-items: center;
    gap: 14px;
}
.user-avatar-initials {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9em;
    color: white;
    text-transform: uppercase;
}
.user-avatar-initials.admin {
    background: linear-gradient(135deg, #eab308, #ca8a04);
}
.user-info-text strong {
    font-size: 0.95em;
    color: #f8fafc;
}
.user-info-text small {
    display: block;
    color: var(--text-muted);
    font-size: 0.8em;
}

/* Filtres de la section Demandes */
.sub-filter-strip {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}
.strip-left {
    display: flex;
    gap: 8px;
}
.strip-chip {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-muted);
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.85em;
    font-weight: 600;
    transition: 0.2s;
}
.strip-chip.active {
    background: #fff;
    color: #0f172a;
    border-color: #fff;
}
.strip-chip.purple.active {
    background: #a855f7;
    color: #fff;
    border-color: #a855f7;
}
.strip-chip.cyan.active {
    background: #06b6d4;
    color: #fff;
    border-color: #06b6d4;
}
.strip-legend {
    font-size: 0.8em;
    color: var(--text-muted);
    display: flex;
    align-items: center;
}
.legend-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
}
.legend-dot.purple { background: #a855f7; }
.legend-dot.cyan { background: #06b6d4; }

/* Cartes des Demandes */
.demandes-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 16px;
}
.demande-ticket {
    background: rgba(30, 41, 59, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 14px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    border-left: 4px solid #64748b;
    transition: transform 0.2s;
}
.demande-ticket:hover {
    transform: translateY(-2px);
    background: rgba(30, 41, 59, 0.6);
}
.demande-ticket.is-ondemand {
    border-left-color: #a855f7;
}
.demande-ticket.is-custom {
    border-left-color: #06b6d4;
}
.ticket-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 10px;
}
.ticket-title {
    font-size: 1.05em;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}
.ticket-meta {
    font-size: 0.8em;
    color: var(--text-muted);
    margin-bottom: 12px;
}
.ticket-notes {
    font-size: 0.82em;
    background: rgba(0, 0, 0, 0.25);
    padding: 8px 10px;
    border-radius: 6px;
    color: #cbd5e1;
    margin-bottom: 14px;
    font-style: italic;
}
.ticket-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 12px;
}

/* Module Bugs (Tickets d'incidents) */
.bugs-feed {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.bug-ticket {
    background: rgba(30, 41, 59, 0.45);
    border: 1px solid rgba(239, 68, 68, 0.25);
    border-left: 4px solid #ef4444;
    border-radius: 14px;
    padding: 18px 22px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    flex-wrap: wrap;
}
.bug-ticket.resolu {
    border-color: rgba(255, 255, 255, 0.08);
    border-left-color: var(--emby-accent);
    opacity: 0.65;
}
.bug-ticket-content {
    flex: 1;
    min-width: 260px;
}
.bug-badge {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    font-size: 0.75em;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    text-transform: uppercase;
}
.bug-details-box {
    margin-top: 10px;
    background: rgba(0, 0, 0, 0.3);
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 0.88em;
    color: #e2e8f0;
}
.bug-ticket-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    align-self: center;
}

.empty-state {
    text-align: center;
    color: var(--text-muted);
    padding: 35px 0;
    font-size: 0.9em;
}

/* ================= BANDEAU ET ONGLETS ADMIN ================= */
.admin-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.5), rgba(15, 23, 42, 0.8));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 18px 22px;
    margin-bottom: 22px;
}
.admin-tabs-nav {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.admin-nav-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.88em;
    transition: 0.2s;
}
.admin-nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}
.admin-nav-item.active {
    background: var(--emby-accent);
    color: #fff;
    border-color: var(--emby-accent);
    box-shadow: 0 4px 12px rgba(82, 181, 75, 0.3);
}

/* ================= BANDEAU ET ONGLETS ADMIN ================= */
.admin-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.5), rgba(15, 23, 42, 0.8));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 18px 22px;
    margin-bottom: 22px;
}
.admin-tabs-nav {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.admin-nav-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.88em;
    transition: 0.2s;
}
.admin-nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}
.admin-nav-item.active {
    background: var(--emby-accent);
    color: #fff;
    border-color: var(--emby-accent);
    box-shadow: 0 4px 12px rgba(82, 181, 75, 0.3);
}

/* ================= BLOC NOUVEAUTÉS SUR L'ACCUEIL ================= */
.home-news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
    margin-bottom: 25px;
}
.news-column {
    background: rgba(30, 41, 59, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px;
    display: flex;
    flex-direction: column;
}
.news-col-title {
    font-size: 1.05em;
    font-weight: 700;
    color: #fff;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 12px;
}
.news-cards-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.news-card-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 9px;
    padding: 10px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: 0.2s;
}
.news-card-item:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.12);
}
.news-item-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow: hidden;
}
.news-item-title {
    font-size: 0.9em;
    font-weight: 700;
    color: #f1f5f9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.news-item-sub {
    font-size: 0.78em;
    color: var(--text-muted);
}
.news-item-date {
    font-size: 0.72em;
    color: var(--emby-accent);
    font-weight: 700;
    background: rgba(82, 181, 75, 0.12);
    border: 1px solid rgba(82, 181, 75, 0.25);
    padding: 3px 8px;
    border-radius: 6px;
    white-space: nowrap;
    margin-left: 8px;
}

/* ================= BANDEAU NOTIFICATION ACCUEIL ================= */
.home-notif-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.85));
    border: 1px solid rgba(82, 181, 75, 0.35);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35), 0 0 15px rgba(82, 181, 75, 0.15);
    border-radius: 14px;
    padding: 16px 20px;
    margin-top: 24px;
}
.notif-icon-bubble {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(82, 181, 75, 0.15);
    border: 1px solid rgba(82, 181, 75, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35em;
    flex-shrink: 0;
}
.notif-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.notif-header {
    display: flex;
    align-items: center;
    gap: 10px;
}
.notif-badge {
    background: var(--emby-accent);
    color: #fff;
    font-size: 0.72em;
    font-weight: 800;
    text-transform: uppercase;
    padding: 3px 8px;
    border-radius: 6px;
    letter-spacing: 0.5px;
}
.notif-time {
    font-size: 0.78em;
    color: var(--text-muted);
}
.notif-items {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}
.notif-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.88em;
    color: #cbd5e1;
}
.notif-chip strong {
    color: #fff;
}
.notif-chip .notif-chip-date {
    font-size: 0.78em;
    color: var(--emby-accent);
    background: rgba(82, 181, 75, 0.15);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
}

/* Style distinctif pour l'onglet Annonce dans le menu admin */
.admin-nav-item.notif-tab {
    border-color: rgba(234, 179, 8, 0.4);
    color: #facc15;
}
.admin-nav-item.notif-tab.active {
    background: #eab308 !important;
    color: #0f172a !important;
    border-color: #eab308 !important;
    font-weight: 800;
}

/* ================= STYLES DU GUIDE D'INSTALLATION DÉTAILLÉ ================= */
.server-info-box {
    display: flex;
    align-items: center;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 16px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.85));
    border: 1px solid rgba(82, 181, 75, 0.35);
    border-radius: 14px;
    padding: 18px 24px;
    margin-bottom: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}
.server-info-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-align: center;
}
.server-info-label {
    font-size: 0.75em;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}
.server-info-value {
    font-size: 1.1em;
    color: #fff;
    font-family: monospace;
}
.server-info-divider {
    width: 1px;
    height: 35px;
    background: rgba(255, 255, 255, 0.1);
}
@media (max-width: 600px) {
    .server-info-divider { display: none; }
}

.guide-tip {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(56, 189, 248, 0.08);
    border: 1px solid rgba(56, 189, 248, 0.25);
    border-radius: 10px;
    padding: 12px 16px;
    margin-bottom: 18px;
    font-size: 0.9em;
    color: #e0f2fe;
}
.tip-icon {
    font-size: 1.3em;
}

.step-card.highlight-step {
    border-left: 4px solid #f59e0b;
    background: rgba(245, 158, 11, 0.06);
}
.step-card.highlight-step .step-num {
    background: #f59e0b;
}

.code-pill-group {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 10px;
}
.code-pill {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    padding: 6px 12px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88em;
    color: var(--text-muted);
}
.code-pill code {
    color: #a3e635;
    font-family: monospace;
    font-weight: 700;
    font-size: 1.05em;
}

.direct-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--emby-accent);
    color: #fff !important;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95em;
    padding: 12px 20px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(82, 181, 75, 0.35);
    transition: transform 0.2s, background 0.2s;
}
.direct-link-btn:hover {
    transform: translateY(-2px);
    background: #469e40;
}

/* ================= SÉPARATION DES LISTES SUR DEMANDE ================= */
.ondemand-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(168, 85, 247, 0.12);
    border: 1px solid rgba(168, 85, 247, 0.3);
    border-radius: 10px;
    padding: 12px 18px;
    margin-bottom: 12px;
}
.ondemand-section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.05em;
    font-weight: 700;
    color: #f3e8ff;
}
.ondemand-badge-count {
    background: #a855f7;
    color: #fff;
    font-size: 0.78em;
    font-weight: 800;
    padding: 2px 10px;
    border-radius: 12px;
}

/* ================= SÉPARATION DES LISTES SUR DEMANDE ================= */
.ondemand-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(168, 85, 247, 0.12);
    border: 1px solid rgba(168, 85, 247, 0.3);
    border-radius: 10px;
    padding: 12px 18px;
    margin-bottom: 12px;
}
.ondemand-section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.05em;
    font-weight: 700;
    color: #f3e8ff;
}
.ondemand-badge-count {
    background: #a855f7;
    color: #fff;
    font-size: 0.78em;
    font-weight: 800;
    padding: 2px 10px;
    border-radius: 12px;
}

/* ================= LISTES ET SOUS-BOUTONS SUR DEMANDE ================= */
.ondemand-subfilter-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 22px;
    flex-wrap: wrap;
}
.ondemand-sub-chip {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(168, 85, 247, 0.3);
    color: #cbd5e1;
    padding: 7px 16px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.ondemand-sub-chip:hover {
    background: rgba(168, 85, 247, 0.2);
    color: #fff;
}
.ondemand-sub-chip.active {
    background: #a855f7;
    color: #fff;
    border-color: #a855f7;
    box-shadow: 0 4px 12px rgba(168, 85, 247, 0.35);
}
.btn-action-ondemand.sub-btn {
    padding: 3px 8px;
    font-size: 0.75em;
    margin-right: 8px;
}

/* ================= DEUX LISTES DISTINCTES SUR DEMANDE ================= */
.ondemand-subfilter-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.ondemand-sub-chip {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #cbd5e1;
    padding: 8px 18px;
    border-radius: 20px;
    font-size: 0.88em;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}
.ondemand-sub-chip:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}
.ondemand-sub-chip.active {
    background: #a855f7;
    color: #fff;
    border-color: #a855f7;
    box-shadow: 0 4px 15px rgba(168, 85, 247, 0.35);
}

.ondemand-two-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    align-items: start;
}
@media (max-width: 960px) {
    .ondemand-two-columns {
        grid-template-columns: 1fr;
    }
}

.ondemand-card-panel {
    background: rgba(15, 23, 42, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 18px;
    display: flex;
    flex-direction: column;
}
.ondemand-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 16px;
}
.ondemand-panel-header.film-theme {
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.15), rgba(15, 23, 42, 0.6));
    border: 1px solid rgba(56, 189, 248, 0.35);
}
.ondemand-panel-header.serie-theme {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.15), rgba(15, 23, 42, 0.6));
    border: 1px solid rgba(168, 85, 247, 0.35);
}
.panel-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}
.panel-icon {
    font-size: 1.5em;
}
.panel-title {
    font-size: 1.05em;
    font-weight: 800;
    color: #fff;
}
.panel-subtitle {
    font-size: 0.78em;
    color: var(--text-muted);
}
.ondemand-badge-count {
    font-size: 0.82em;
    font-weight: 800;
    padding: 3px 12px;
    border-radius: 14px;
}
.ondemand-badge-count.film {
    background: #0284c7;
    color: #fff;
}
.ondemand-badge-count.serie {
    background: #9333ea;
    color: #fff;
}

.ondemand-card-panel .media-list-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.btn-action-ondemand.sub-btn {
    padding: 3px 8px;
    font-size: 0.75em;
    margin-right: 8px;
}
