body {
    font-family: Arial, sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    background-color: #f9f9f9;
    width: 100%;
}

header {
    background-color: #003366;
    color: white;
    width: 100%;
    text-align: center;
}

.left-section {
    display: flex; /* Utilisez flex pour le conteneur */
    align-items: center; /* Centre les images verticalement */
    gap: 10px; /* Espace entre les images */
    display: flex;
    position: absolute;
    left: 20px;
    top: 10px;
    
}
#ire_logo {
    height: 30px;
}

#ramses_logo {
    height: 50px;
}

.center-section {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 70px;
}

#station_name {
    font-size: 2rem;
    font-weight: bold;
    color: #FFF;
    font-family: 'Ubuntu', sans-serif;
    font-style: normal;
}

#datetime_station {
    font-size: 1.5rem;
    color: #FFF;
    font-family: 'Ubuntu', sans-serif;
    font-style: italic;
}

.header-data {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 20px;
    background-color: #f0f0f0;
}

.header-data .date-info {
    font-size: 1rem;
    color: #333;
}

.header-data .badge-container {
    display: flex;
    gap: 10px;
}


.badge {
    padding: 5px 10px;
    border-radius: 15px;
    color: white;
    font-weight: bold;
}

.btn-header {
    padding: 8px 15px;
    border: none;
    border-radius: 5px;
    background-color: white;
    color: #004d99;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.3s ease;
    margin: 2px;
}
.text-header {
    padding: 8px 15px;
    border: none;
    border-radius: 5px;
    background-color: white;
    color: #004d99;
    font-size: 0.9rem;
    transition: background-color 0.3s ease;
    margin: 2px;
    font-weight: bold;
    text-transform: uppercase;
}

.btn-header:hover {
    background-color: #b6c101;
}

.badge.grey {
    background-color: #AAA;
}

.badge.green {
    background-color: #28a745;
}
.badge.blue {
    background-color: #086bd4;
}

.badge.yellow {
    background-color: #ffc107;
}

.badge.red {
    background-color: #dc3545;
}
.badge.white {
    background-color: #FFF;
    color: #000;
}

.blink-yellow {
    animation: blink-yellow-effect 2s infinite;
}

@keyframes blink-yellow-effect {
    0%, 100% {
        background-color: #fff; /* blanc */
    }
    50% {
        background-color: #ffc107; /* jaune */
    }
}

.blink-red {
    animation: blink-red-effect 2s infinite;
}

@keyframes blink-red-effect {
    0%, 100% {
        background-color: #fff; /* blanc */
    }
    50% {
        background-color: #dc3545; /* rouge Bootstrap */
    }
}


.error-message {
    display: none;
    font-weight: bold;
    font-size: large;
}

td.background-green {
    background-color: #d4edda; /* Vert clair */
    height: 100%;
    width: 100%;
}

td.background-yellow {
    background-color: #fff3cd; /* Jaune clair */
    height: 100%;
    width: 100%;
}

td.background-red {
    background-color: #f8d7da; /* Rouge clair */
    height: 100%;
    width: 100%;
}

td.background-grey {
    background-color: #e2e3e5; /* Gris clair */
    height: 100%;
    width: 100%;
}


.card {
    width: 90%;
    padding: 20px;
    margin-bottom: 20px;
    background-color: #f0f0f0;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

#myChart {
    height: 30vh;
}

.system-card-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 20px;
}

.system-card {
    flex: 1 1 calc(33.33% - 20px);
    padding: 15px;
    background-color: #f0f0f0;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    min-width: 300px;
}

#toggle-menu {
    display: none;
}

.menu-buttons {
    display: flex;
    position: absolute;
    right: 20px;
    top: 15px;
}

.btn-header {
    display: flex;
    align-items: center;
    padding: 8px 15px;
    border: none;
    border-radius: 5px;
    background-color: white;
    color: #004d99;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.3s ease;
}

.btn-header span {
    margin-left: 8px;
    /* Add space between icon and text */
}

.btn-header-right {
    margin-left: auto;
    display: flex;
    gap: 5px; 
}



.client-title {
    margin: 0;
    font-size: 1.2em;
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    min-width: 300px;
    max-width: 90%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}
.modal2 {
    /* Positionnement */
    position: fixed;
    top: 50%;
    right: 2%; /* Légèrement plus proche du bord pour un meilleur rendu */
    transform: translateY(-50%); /* Seule translation verticale nécessaire */

    /* Dimensions */
    width: 80%;
    max-width: 1000px;
    min-width: 300px;
    height: 90vh;

    /* Style */
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;

    /* Défilement */
    overflow-y: auto;
    overflow-x: hidden;

    /* Transition pour une ouverture/fermeture fluide */
    transition: all 0.3s ease;
}
.action-alarm,
.action-default {
    /* Héritage des propriétés de base de Grid.js */
    padding: 8px 12px; /* Même padding que les td de Grid.js */
    text-align: center; /* Alignement centré comme dans Grid.js */
    vertical-align: middle; /* Alignement vertical centré */
    border: 1px solid #dee2e6; /* Bordure légère comme dans les tableaux */
    font-size: inherit; /* Héritage de la taille de police */
    color: inherit; /* Héritage de la couleur de texte */
    background-color: transparent; /* Fond transparent par défaut */

    /* Comportement au survol */
    transition: background-color 0.2s ease; /* Transition fluide */
    cursor: pointer; /* Curseur "main" pour indiquer que c'est cliquable */
}
/* Cible uniquement les tableaux dans .action-tableau */
.action-tableau .gridjs-tr {
    transition: background-color 0.2s ease;
}

/* Survol normal pour les lignes non-acquittées */
.action-tableau .gridjs-tr:not([style*="rgba(40, 167, 69)"]):hover {
    background-color: rgba(0, 51, 102, 0.3) !important;
}

/* Survol pour les lignes acquittées */
.action-tableau .gridjs-tr[style*="rgba(40, 167, 69)"]:hover {
    background-color: rgba(0, 51, 102, 0.5) !important;
}

/* Style pour les cellules cliquables */
.action-tableau .action-alarm,
.action-tableau .action-default {
    cursor: pointer;
}

.active-tab {
    border-bottom: 3px solid #28a745 !important; /* Vert Bootstrap */
}



.title-modal-alm0,
.title-modal-alm1,
.title-modal-alm2 {
    padding: 12px 20px;
    border-radius: 6px;
    color: white;
    font-weight: bold;
    text-align: center;
    margin: 0 auto 20px;
    display: block;
    font-size: 16px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.title-modal-alm0 {
    background-color: #28a745;
}
.title-modal-alm1 {
    background-color: #ffc107; 
}
.title-modal-alm2 {
    background-color: #dc3545; 
}



.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

.button-cancel {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
    color: #003366;
    background-color: white;
    border: 2px solid #003366;
    margin-left: 10px;
}
.button-cancel:hover {
    background-color: #00336698;
}

.button-style {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
    background-color: #003366;
    color: white;border: 2px solid #003366;
    
}

.button-style:hover {
    background-color: #004d99;
}

.close-modal {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

#title-spectrum {
    display: flex;
    align-items: center;
}

.calibration-inputs {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px; /* Space between the formula and input groups */
}

.input-group-container {
    display: flex;
    gap: 20px; /* Space between input groups */
}

.input-group {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px; 
}

.input-group label {
    font-weight: bold;
    margin-bottom: 5px; /* Space below the label */
}

.input-group input {
    width: 100px;
    padding: 5px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
    text-align: center;
}

.input-group input:focus {
    border-color: #004d99;
    outline: none;
}
.new-energy-input {
    width: 100px;
    padding: 5px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
    text-align: center;
}

.swal2-timer-progress-bar {
    height: 6px !important; /* Hauteur de la barre */
    background-color: blue !important; /* Couleur de la barre */
}



.calibration-text-long {
    display: inline;
}

.calibration-text-short {
    display: none;
}
.responsive-text {
    font-size: 15px;
}

@media (max-width: 1100px) {
    
    #calibration-params > div:first-child {
        flex-direction: column;
        align-items: flex-start;
    }
    
    #myChart {
        height: 20vh;
    }
    
    
    .header-data {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
        
    }
    
    .header-data {
        font-size: 0.8rem;
    }
    
    .header-data .badge {
        font-size: 0.8rem;
    }
    
    .header-data .date-info {
        text-align: center;
        margin-bottom: 10px;
    }
    
    .header-data .time-info {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 5px;
    }
    
    .header-data .badge-container {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 10px;
        margin-top: 10px;
        font-size: 0.8rem;
        
    }
    
    .header-data .time-info span,
    .header-data .badge-container div {
        text-align: center;
    }
    
    .text-btn-header {
        display: none;
    }
    
    .input-group {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px; 
    }
    .calibration-text-long {
        display: none;
    }
    .calibration-text-short {
        display: inline;
    }
}
@media (max-width: 700px) {
    
    #ire_logo {
        height: 30px;
    }
    
    #ramses_logo {
        height: 40px;
        display: none;
    }
    
    .left-section {
        display: flex; /* Utilisez flex pour le conteneur */
        gap: 10px; /* Espace entre les images */
        display: flex;
        flex-direction: column;
        position: absolute;
        left: 20px;
        top: 20px;
        
    }
    .header-data {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    
    .system-card {
        flex: 1 1 100%;
    }
    
    #toggle-menu {
        display: flex;
        position: absolute;
        right: 20px;
        top: 15px;
        
    }
    
    .menu-buttons {
        display: none;
    }
    
    .btn-header-start-stop span {
        display: none;
    }
    
    .client-title {
        margin: 0;
        font-size: 0.8em;
    }
    
    .gridjs {
        font-size: 0.8em;
        max-width: 90%;
    }
    
    #title-spectrum {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
    }
    
    #title-spectrum span {
        font-size: 0.7em;
    }
    
    .date-info-txt {
        display: none;
    }
    
    .client-title {
        text-align: center;
    }
    
    #menu-container {
        position: fixed;
        top: 0;
        right: -250px;
        /* Position initiale hors de l'écran à droite */
        width: 250px;
        height: 100%;
        background-color: #333;
        color: white;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: flex-start;
        padding-top: 20px;
        gap: 15px;
        transition: right 0.3s ease;
        /* Animation pour le décalage */
        z-index: 1000;
        /* Assurez-vous que le menu est au-dessus des autres éléments */
    }
    
    #menu-container.open {
        right: 0;
        /* Position du menu lorsqu'il est ouvert */
    }
    
    #menu-container button {
        background: none;
        border: none;
        color: white;
        font-size: 18px;
        padding: 10px;
        width: 100%;
        text-align: right;
        /* Alignement du texte à droite */
        cursor: pointer;
    }
    
    #menu-container button:hover {
        background-color: #555;
        /* Changement de couleur au survol */
    }
    
    .toggle-menu {
        position: inherit;
        /* Positionnement relatif au conteneur parent (header) */
        font-size: 24px;
        cursor: pointer;
        color: #FFF;
        z-index: 1001;
        /* Doit être au-dessus du menu lorsqu'il est fermé */
    }
    .text-btn-header {
        display: block;
    }
    
    
    .responsive-text {
        font-size: 12px;
    }
    .button-style {
        padding: 5px 10px;
        border: none;
        border-radius: 5px;
        cursor: pointer;
        font-size: 12px;
        transition: background-color 0.3s;
        background-color: #003366;
        color: white;border: 2px solid #003366;
        
    }            
    .button-style:hover {
        background-color: #004d99;
    }
    .button-cancel {
        padding: 5px 10px;
        border: none;
        border-radius: 5px;
        cursor: pointer;
        font-size: 12px;
        transition: background-color 0.3s;
        color: #003366;
        background-color: white;
        border: 2px solid #003366;
        margin-left: 10px;
    }
    .button-cancel:hover {
        background-color: #00336698;
    }
    
    
}