/* ==========================================================================
   style.css - Charte Graphique Lumineuse & Premium (MultiStream12)
   ========================================================================== */

/* --- 1. VARIABLES GLOBALES (Thème Clair) --- */
:root {
    --bg-main: #F8F9FA;
    --bg-card: #FFFFFF;
    --accent: #FF9900;
    --accent-hover: #E68A00;
    --text-main: #1A1D20;
    --text-muted: #6C757D;
    --border-light: #E9ECEF;
    --shadow-premium: 0 12px 40px rgba(0, 0, 0, 0.04);
    --shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.06);
    --live-color: #00E676;
    --error-bg: #F8D7DA;
    --error-text: #721C24;
    --success-bg: #D4EDDA;
    --success-text: #155724;
}

/* --- 2. RÉINITIALISATION & BASES --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

/* --- 3. BOUTONS COMPOSANTS --- */
.btn-premium {
    background-color: var(--accent);
    color: #FFFFFF;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    box-shadow: 0 4px 14px rgba(255, 153, 0, 0.25);
    cursor: pointer;
    display: inline-block;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.btn-premium:hover {
    background-color: var(--accent-hover);
}

.btn-premium:active {
    transform: scale(0.98);
}

.btn-secondary {
    background: #FFFFFF;
    border: 1px solid var(--border-light);
    color: var(--text-main);
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: inline-block;
    transition: background-color 0.2s ease;
}

.btn-secondary:hover {
    background: #F8F9FA;
}

/* --- 4. STRUCTURE DE LA PAGE D'ACCUEIL --- */

/* Top Bar (Contacts & Liens rapides) */
.top-bar {
    background-color: #FFFFFF;
    font-size: 13px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-light);
    color: var(--text-muted);
}
.top-bar-container {
    display: flex;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
.top-bar-left a {
    margin-right: 20px;
}
.top-bar-left a:hover {
    color: var(--accent);
}
.top-bar-right a {
    margin-left: 15px;
    font-weight: 500;
}
.top-bar-right a.logout {
    color: #DC3545;
}

/* Navbar Transparente Floutée */
.navbar {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-light);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}
.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
.nav-logo {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.5px;
}
.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
    font-weight: 500;
    color: var(--text-muted);
}
.nav-links a:hover {
    color: var(--text-main);
}

/* Zone Héro */
.hero {
    padding: 90px 20px;
    text-align: center;
    background: radial-gradient(circle at top, rgba(255,153,0,0.05) 0%, rgba(255,255,255,0) 70%);
}
.hero-container {
    max-width: 800px;
    margin: 0 auto;
}
.hero h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.15;
    letter-spacing: -1px;
}
.hero h1 span {
    color: var(--accent);
}
.hero p {
    font-size: 18px;
    color: var(--text-muted);
    margin-bottom: 35px;
}
.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

/* Grille et Cartes des Sessions */
.sessions-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
}
.section-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.grid-meetings {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.card-meeting {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-premium);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.card-meeting:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(255, 153, 0, 0.3);
}

.card-banner {
    position: relative;
    height: 180px;
    background-color: #E9ECEF;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}
.card-banner svg {
    opacity: 0.5;
}

.badge-live {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(0, 230, 118, 0.9);
    color: #FFFFFF;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 5px;
    text-transform: uppercase;
}
.dot-live {
    width: 6px;
    height: 6px;
    background-color: #FFFFFF;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}
.badge-vignettes {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

.card-body {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.card-body h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}
.card-organizer {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 20px;
}
.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-light);
    padding-top: 15px;
}
.card-price {
    font-size: 20px;
    font-weight: 700;
}
.card-price span {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-muted);
}

.no-meeting {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px;
    color: var(--text-muted);
    background: var(--bg-card);
    border: 1px dashed var(--border-light);
    border-radius: 12px;
}

/* --- 5. INTERFACES CONNEXION / INSCRIPTION --- */
.auth-body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: var(--bg-main);
}

.auth-container {
    background: var(--bg-card);
    padding: 40px;
    border-radius: 16px;
    box-shadow: var(--shadow-premium);
    width: 100%;
    max-width: 400px;
    border: 1px solid var(--border-light);
}
.auth-container h2 {
    margin-bottom: 25px;
    font-weight: 700;
    font-size: 24px;
    text-align: center;
    letter-spacing: -0.5px;
}

.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 14px;
}
.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-light);
    border-radius: 8px;
    font-size: 15px;
    outline: none;
    background-color: #FFFFFF;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.form-group input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(255, 153, 0, 0.1);
}

.btn-auth {
    width: 100%;
    background: var(--accent);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    margin-top: 10px;
    box-shadow: 0 4px 12px rgba(255, 153, 0, 0.2);
    transition: background-color 0.2s ease;
}
.btn-auth:hover {
    background: var(--accent-hover);
}

.switch-auth {
    text-align: center;
    margin-top: 20px;
    font-size: 14px;
    color: var(--text-muted);
}
.switch-auth a {
    color: var(--accent);
    font-weight: 600;
}
.switch-auth a:hover {
    color: var(--accent-hover);
}

/* --- 6. MESSAGES D'ALERTE SYSTEME --- */
.error-msg {
    background: var(--error-bg);
    color: var(--error-text);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    text-align: center;
    border: 1px solid rgba(114, 28, 36, 0.1);
}

.success-msg {
    background: var(--success-bg);
    color: var(--success-text);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    text-align: center;
    border: 1px solid rgba(21, 87, 36, 0.1);
}

/* --- 7. WIDGET DE CHAT FLOTTANT --- */
.chat-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 2000;
}
.chat-button {
    width: 56px;
    height: 56px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(255, 153, 0, 0.3);
    transition: transform 0.2s ease, background-color 0.2s ease;
}
.chat-button:hover {
    transform: scale(1.05);
    background-color: var(--accent-hover);
}

/* --- 8. KEYFRAMES & ANIMATIONS --- */
@keyframes pulse {
    0% { opacity: 0.4; }
    50% { opacity: 1; }
    100% { opacity: 0.4; }
}

/* --- 9. ADAPTATION ÉCRANS MOBILES --- */
@media (max-width: 768px) {
    .nav-links, .top-bar-left {
        display: none;
    }
    .hero h1 {
        font-size: 32px;
    }
    .grid-meetings {
        grid-template-columns: 1fr;
    }
    .auth-container {
        padding: 25px;
        margin: 20px;
    }
}
/* --- AJOUTS POUR LE DIAPORAMA ET LE PIED DE PAGE (style.css) --- */
.carousel-section { max-width: 1200px; margin: 40px auto 0 auto; padding: 0 20px; }
.main-carousel { position: relative; width: 100%; height: 350px; background: #E9ECEF; border-radius: 16px; overflow: hidden; box-shadow: var(--shadow-premium); display: flex; align-items: center; justify-content: center; color: var(--text-muted); }
.carousel-placeholder { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 15px; }
.carousel-caption-box { position: absolute; bottom: 0; left: 0; right: 0; background: linear-gradient(transparent, rgba(0,0,0,0.85)); color: #FFFFFF; padding: 30px 25px; }
.carousel-caption-box h2 { font-size: 24px; font-weight: 700; margin-bottom: 5px; }
.carousel-caption-box p { font-size: 14px; opacity: 0.8; }

.footer { background-color: #FFFFFF; border-top: 1px solid var(--border-light); margin-top: 80px; padding: 40px 0 20px 0; font-size: 14px; color: var(--text-muted); }
.footer-container { max-width: 1200px; margin: 0 auto; padding: 0 20px; display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 40px; }
.footer-column h4 { color: var(--text-main); font-weight: 600; margin-bottom: 15px; }
.footer-column ul { list-style: none; }
.footer-column ul li { margin-bottom: 10px; }
.footer-column ul li a:hover { color: var(--accent); }
.footer-bottom { max-width: 1200px; margin: 40px auto 0 auto; padding: 20px 20px 0 20px; border-top: 1px solid var(--border-light); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 15px; font-size: 13px; }
@media (max-width: 768px) { .main-carousel { height: 220px; } .footer-bottom { flex-direction: column; text-align: center; } }


/* --- AJOUTS POUR LA PAGE CONTACT (style.css) --- */
.contact-container { max-width: 800px; margin: 60px auto; padding: 0 20px; }
.contact-card { background: var(--bg-card); border: 1px solid var(--border-light); border-radius: 16px; padding: 40px; box-shadow: var(--shadow-premium); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-group textarea { width: 100%; padding: 12px; border: 1px solid var(--border-light); border-radius: 8px; font-size: 15px; outline: none; background-color: #FFFFFF; font-family: inherit; resize: vertical; min-height: 120px; transition: border-color 0.2s ease, box-shadow 0.2s ease; }
.form-group textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255, 153, 0, 0.1); }
@media (max-width: 600px) { .contact-grid { grid-template-columns: 1fr; } .contact-card { padding: 25px; } }



/* ==========================================================================
   CHARTE GRAPHIQUE COMPLÈTE DU DASHBOARD ADMIN (Sidebar + Graphiques)
   ========================================================================== */
.admin-layout {
    display: flex;
    min-height: 100vh;
    background-color: var(--bg-main);
}

/* --- SIDEBAR (MENU LATÉRAL) --- */
.sidebar {
    width: 260px;
    background: #1A1D20;
    color: #FFFFFF;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1010;
    transition: all 0.3s ease;
}
.sidebar-brand {
    padding: 24px;
    font-size: 20px;
    font-weight: 700;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    letter-spacing: -0.5px;
}
.sidebar-menu {
    list-style: none;
    padding: 20px 0;
    flex-grow: 1;
}
.sidebar-menu li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 24px;
    color: #A0AEC0;
    font-weight: 500;
    font-size: 15px;
    transition: all 0.2s ease;
}
.sidebar-menu li a:hover, .sidebar-menu li.active a {
    color: #FFFFFF;
    background: rgba(255, 153, 0, 0.15);
    border-left: 4px solid var(--accent);
}
.sidebar-footer {
    padding: 20px 24px;
    border-top: 1px solid rgba(255,255,255,0.08);
}

/* --- CONTENEUR PRINCIPAL (Ajusté pour la Sidebar) --- */
.admin-main-content {
    flex-grow: 1;
    margin-left: 260px;
    padding: 40px;
    transition: all 0.3s ease;
}

/* --- GRILLES DU DASHBOARD --- */
.dashboard-kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    margin-bottom: 35px;
}
.kpi-card {
    background: #FFFFFF;
    border: 1px solid var(--border-light);
    border-radius: 14px;
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-premium);
}
.kpi-data h3 { font-size: 14px; color: var(--text-muted); text-transform: uppercase; margin-bottom: 6px; font-weight: 600; letter-spacing: 0.5px; }
.kpi-data .kpi-value { font-size: 28px; font-weight: 700; color: var(--text-main); }
.kpi-icon { width: 48px; height: 48px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 20px; }

/* --- SECTION GRAPHIQUES --- */
.charts-row {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    margin-bottom: 35px;
}
.chart-box {
    background: #FFFFFF;
    border: 1px solid var(--border-light);
    border-radius: 14px;
    padding: 24px;
    box-shadow: var(--shadow-premium);
}
.chart-box h3 { font-size: 16px; font-weight: 600; margin-bottom: 20px; color: var(--text-main); }

/* --- RESPONSIVE MOBILE --- */
@media (max-width: 992px) {
    .sidebar { left: -260px; }
    .admin-main-content { margin-left: 0; padding: 20px; }
    .charts-row { grid-template-columns: 1fr; }
    .sidebar.open { left: 0; }
}


/* --- COMPOSANTS DE CONFIGURATION & PAYMENTS (style.css) --- */
.tab-content { display: none; }
.tab-content.active { display: block; }
.badge-status { padding: 4px 8px; border-radius: 6px; font-size: 12px; font-weight: 600; text-transform: uppercase; }
.badge-status.completed { background: rgba(0, 230, 118, 0.15); color: #00E676; }
.badge-status.pending { background: rgba(255, 153, 0, 0.15); color: var(--accent); }
.api-box-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 30px; }
.api-vendor-card { background: var(--bg-main); border: 1px solid var(--border-light); padding: 20px; border-radius: 12px; }
.api-vendor-card h4 { display: flex; align-items: center; gap: 10px; margin-bottom: 15px; font-size: 15px; color: var(--text-main); }
@media (max-width: 768px) { .api-box-grid { grid-template-columns: 1fr; } }



/* Container de la grille */
.stream-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Carte de stream */
.stream-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.2s;
    border-top: 5px solid #CBD5E0; /* Couleur par défaut */
}

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

/* Couleurs selon le type */
.stream-card.public { border-top-color: #48BB78; } /* Vert */
.stream-card.vip    { border-top-color: #ECC94B; } /* Or */
.stream-card.formation { border-top-color: #667EEA; } /* Bleu */

/* Typographie et éléments */
.stream-card h3 { margin: 0 0 10px 0; font-size: 1.25rem; color: #2D3748; }
.stream-card .badge { 
    display: inline-block;
    padding: 4px 8px;
    background: #F7FAFC;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: bold;
    margin-bottom: 15px;
}

/* Boutons */
.stream-card button {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 15px;
}

.btn-watch { background: #4A5568; color: white; }
.btn-lock  { background: #E53E3E; color: white; cursor: not-allowed; }

/* Style de la modale */
.modal-overlay {
    display: none; 
    position: fixed; 
    top: 0; left: 0; 
    width: 100%; height: 100%; 
    background: rgba(26, 29, 32, 0.7); 
    backdrop-filter: blur(4px); /* Effet verre flou */
    z-index: 2000; 
    align-items: center; 
    justify-content: center;
}

.modal-content {
    background: #ffffff; 
    padding: 30px; 
    border-radius: 16px; 
    width: 100%; 
    max-width: 450px; 
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    border: 1px solid #e2e8f0;
}

.modal-content h3 { margin-bottom: 20px; color: #1a202c; font-size: 20px; }

.modal-input {
    width: 100%; 
    padding: 12px; 
    margin: 8px 0 20px 0; 
    border: 1px solid #cbd5e0; 
    border-radius: 8px; 
    font-family: 'Inter', sans-serif;
}

.btn-group { display: flex; gap: 10px; justify-content: flex-end; }

/* Style des tableaux */
.data-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
    margin-top: 20px;
}

.data-table thead { background: #f8f9fa; }
.data-table th, .data-table td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid #edf2f7;
    font-size: 14px;
}
.data-table th { color: #4a5568; font-weight: 600; text-transform: uppercase; font-size: 12px; letter-spacing: 0.05em; }

/* Badges */
.badge { padding: 6px 12px; border-radius: 20px; font-size: 12px; font-weight: 600; }
.badge-vip { background: #fff3e0; color: #f59e0b; }
.badge-public { background: #e0f2fe; color: #0284c7; }
.badge-success { background: #dcfce7; color: #16a34a; }

/* Boutons Actions */
.btn-action { 
    padding: 6px 10px; 
    border-radius: 6px; 
    font-size: 13px; 
    cursor: pointer;
    border: 1px solid #e2e8f0;
    background: #fff;
    margin-right: 5px;
    transition: 0.2s;
}
.btn-action:hover { background: #f1f5f9; }
.btn-danger { color: #e11d48; }


/* Dans watch.php, pour éviter le double titre */
@media screen {
    body { padding: 5px; } /* Moins de padding pour l'iframe */
}


/* Force le layout à occuper tout l'écran */
html, body {
    margin: 0; padding: 0; height: 100%; overflow: hidden;
}

.admin-layout {
    display: flex;
    height: 100vh;
}

/* Sidebar propre et aérée */
.sidebar {
    width: 260px;
    background: #0f172a;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

.sidebar-brand {
    padding: 24px;
    font-size: 1.2rem;
    font-weight: bold;
    color: #fff;
    border-bottom: 1px solid #1e293b;
}

.menu-section {
    padding: 20px 20px 10px 20px;
    font-size: 0.7rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
}

.nav-item {
    display: flex; /* Alignement icône + texte */
    align-items: center;
    padding: 14px 20px;
    margin: 4px 10px; /* Espace autour de chaque lien */
    border-radius: 8px; /* Coins arrondis */
    cursor: pointer;
    transition: all 0.2s;
    color: #cbd5e1;
}

.nav-item:hover {
    background: #1e293b;
    color: #ffffff;
}

.nav-item.active {
    background: #3b82f6; /* Bleu actif */
    color: white;
}
/* Contenu principal défilant à droite */
.admin-main-content {
    flex-grow: 1;
    overflow-y: auto;
    padding: 40px;
    background: #f8fafc;
}

/* Masquer tout par défaut */
.tab-content {
    display: none;
}

/* Afficher uniquement quand la classe .active est ajoutée */
.tab-content.active {
    display: block !important;
}

