/* ------------------------------
   GLOBAL
------------------------------ */

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    margin: 0;
    padding: 0;
    background: #f3f4f6;
    color: #1f2937;
    line-height: 1.6;
}

/* ------------------------------
   HEADER FIXE
------------------------------ */

header {
    position: sticky;
    top: 0;
    background: #1f2937;
    color: #f9fafb;
    padding: 15px 20px;
    font-size: 1.3rem;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
    z-index: 1000;
}

/* ------------------------------
   CONTAINER
------------------------------ */

.container {
    max-width: 1100px;
    margin: 30px auto;
    padding: 0 20px;
}

/* ------------------------------
   CARDS
------------------------------ */

.card {
    background: white;
    padding: 25px;
    border-radius: 16px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.08);
    margin-bottom: 30px;
    transition: transform 0.2s ease;
}

.card:hover {
    transform: translateY(-3px);
}

/* ------------------------------
   TITRES
------------------------------ */

.card h2 {
    margin-top: 0;
    font-size: 1.4rem;
    font-weight: 700;
    color: #111827;
}


/* ==========================
   Stats dates
   ========================== */

table.dateStat {
    width: 85%;
    margin: 0 auto;
    border-collapse: collapse;
}

table.dateStat th {

    border-top: none;           /* supprime la ligne du haut */
    border-left: none;
    border-right: none;

    border-bottom: 2px solid #d7dde8;

    padding: 12px;

    font-size: 0.95rem;
    letter-spacing: 1px;
    text-transform: uppercase;

    color: #6b7280;
    background: transparent;
}

table.dateStat td {

    border-left: none;
    border-right: none;
    border-top: none;

    border-bottom: 1px solid #edf1f7;

    text-align: center;
    vertical-align: middle;

    padding: 15px;
}

table.dateStat tr:last-child td {
    border-bottom: none;
}

table.dateStat tr:hover {
    background: rgba(52, 152, 219, 0.05);
}

.dateStatNom {
    font-size: 1.5rem !important;

    font-weight: 800 !important;

    color: #243447;

    text-align: center;

    line-height: 1.3;
}

.dateStatDate {
    white-space: nowrap;
    color: #555;
}

.dateStatImage {
    width: 70px;
}

.dateStatImage img {
    width: 70px;
    height: 70px;
    object-fit: contain;
}

/*---------------------------------
FORMULAIRE VIDEO
----------------------------------*/
.videoMenu{
    width:600px;
    margin:20px auto;
}

.videoBloc{
    display:block;
    margin-bottom:15px;
    padding:20px;

    background:#f8f8f8;
    border:1px solid #ccc;
    border-radius:10px;

    text-decoration:none;
    color:#333;

    transition:0.2s;
}

.videoBloc:hover{
    background:#ececec;
    transform:translateY(-2px);
}

.videoBloc strong{
    font-size:1.2em;
}

.formCentre{
    display:flex;
    justify-content:center;
    margin:20px 0;
    gap:10px;
}

table.tableau {
    margin-left: auto !important;
    margin-right: auto !important;
}

/*---------------------------------
Stat Attente
----------------------------------*/
table.dateStatResume{
    width:70%;
    margin-left:auto;
    margin-right:auto;
    border-collapse:collapse;
}

table.dateStatResume td{
    border-left:none !important;
    border-right:none !important;
    border-top:none !important;

    border-bottom:1px solid #e5e7eb;

    padding:14px;

    text-align:center;

    font-weight:normal;
}

.dateStatLibelle{
    font-size:1rem;
    font-weight:600;
    color:#64748b;
}

.dateStatValeur{
    font-size:1.15rem;
    font-weight:normal !important;
}

.dateStatJeu{
    margin-top:8px;

    font-size:1.5rem;

    font-weight:700;

    color:#1e293b;
}

.dateStatNumber{
    font-weight:700;
    font-size:1.2em;
    color:#1e40af;
}
/* ------------------------------
   TABLEAUX
------------------------------ */

table.infoStat {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    background: white;
    border-radius: 12px;
    overflow: hidden;
}

table.infoStat td {
    padding: 12px 16px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 0.95rem;
}

table.infoStat tr:last-child td {
    border-bottom: none;
}

table.infoStat td:first-child {
    font-weight: 600;
    color: #374151;
}

/* ------------------------------
   SÉPARATEUR
------------------------------ */

.separator {
    height: 1px;
    background: #d1d5db;
    margin: 30px 0;
}

/* ------------------------------
   BOUTON REMONTER
------------------------------ */

#backToTop {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 55px;
    height: 55px;
    background: #2563eb;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 26px;
    cursor: pointer;
    border: none;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    transition: transform 0.2s ease, background 0.2s ease;
    z-index: 9999;
}

#backToTop:hover {
    background: #1e40af;
    transform: scale(1.12);
}

/* ------------------------------
   MODE SOMBRE
------------------------------ */

body.dark {
    background: #111827;
    color: #e5e7eb;
}

body.dark .card {
    background: #1f2937;
    box-shadow: 0 4px 18px rgba(0,0,0,0.6);
}

body.dark table.infoStat {
    background: #1f2937;
}

body.dark table.infoStat td {
    border-bottom: 1px solid #374151;
    color: #e5e7eb;
}

body.dark table.infoStat td:first-child {
    color: #93c5fd;
}

#backToTop {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 60px;
    height: 60px;
    cursor: pointer;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #ebad25;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    border: none;
    transition: transform 0.2s ease, background 0.2s ease;
}

#backToTop img {
    width: 60%;
    height: auto;
    pointer-events: none;
}

#backToTop:hover {
    background: #1e40af;
    transform: scale(1.12);
}


.card-title {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.4rem;
    font-weight: 700;
    color: #111827;
    border-left: 4px solid #2563eb;
    padding-left: 10px;
}

.card-subtitle {
    margin-top: -10px;
    margin-bottom: 20px;
    font-size: 0.95rem;
    font-style: italic;
    color: #6b7280; /* gris élégant */
}

/* Barre de menu */
.menu-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    padding: 15px 10px;
}

/* Boutons */
.menu-btn,
.menu-btn-active {
    padding: 8px 16px;
    border-radius: 999px;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    transition: background 0.2s ease, transform 0.2s ease;
}

/* Bouton normal */
.menu-btn {
    background: var(--jaune);
    color: var(--blanc);
}

.menu-btn:hover {
    background: #c78902;
    transform: scale(1.05);
}

/* Bouton actif */
.menu-btn-active {
    background: #c76502;
    color: var(--noir);
    transform: scale(1.08);
    box-shadow: 0 0 8px var(--ombre-hover);
}

/* Mode sombre */
body.dark .menu-btn {
    background: #3b82f6;
}

body.dark .menu-btn:hover {
    background: #1d4ed8;
}

body.dark .menu-btn-active {
    background: #fbbf24;
    color: #111;
}

/* Mobile */
@media (max-width: 700px) {
    .menu-btn,
    .menu-btn-active {
        padding: 10px 18px;
        font-size: 1rem;
    }
}

.card canvas {
    min-height: 400px;
}
