/* Structure générale */
body {
    margin: 0;
    padding: 0;
    font-family: sans-serif;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    background-color: #ccc;
}

.grid-layout {
    display: grid;
    grid-template-columns: repeat(18, 1fr); /* 18 colonnes comme ton schéma */
    grid-template-rows: 1fr; /* Une seule ligne nécessaire ici */
    gap: 10px;
    height: 100vh;
    padding: 10px;
    box-sizing: border-box;
}
.active-voie {
    background-color: rgba(0, 0, 255, 0.795) !important;
    color: white;
}

.anomalie-voie {
    background-color: rgba(255, 0, 0, 0.753) !important; /* orange/rouge */
    color: white;
}


/* Zone .voies : colonnes 1 à 3 */
.voies {
    grid-column: 1 / 3;
    grid-row: 1 / 5;
    overflow-y: auto;
    border-right: 1px solid #ccc;
    background-color: #f7f7f7;
    padding: 10px;
    box-sizing: border-box;
}

.voies h2 {
    margin-top: 0;
    font-size: 1.2rem;
    text-align: center;
}

.voies table {
    width: 100%;
    border-collapse: collapse;
}

.voies th, .voies td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.voies tr:hover {
    background-color: #e0e0e0;
    cursor: pointer;
}

/* Zone .graphs : colonnes 4 à 13 */
.graphs {
    grid-column: 3 / 16;
    grid-row: 1 / 7;
    padding: 1rem;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    height: 100%;
    overflow: hidden;
}

.chart-wrapper {
    position: relative;
    width: 95%;
    flex: 1 1 0;
    aspect-ratio: 16 / 5; /* ou 3/1, selon la forme que tu préfères */
    min-height: 0;
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 1rem;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    justify-content: center;
    align-items: center;
}


.chart-wrapper canvas {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain;
    display: block;
}

.exit{
  grid-column: 1 / 3;
  grid-row: 6 / 7;
  top: 10px;
  right: 10px;
  background-color: #f44336;
  color: white;
  border: none;
  padding: 10px;
  border-radius: 5px;
  cursor: pointer;
  z-index: 3;
}
.armement{
  grid-column: 1 / 3;
  grid-row: 5 / 6;
  top: 10px;
  right: 10px;
  background-color: #f44336;
  color: white;
  border: none;
  padding: 10px;
  border-radius: 5px;
  cursor: pointer;
  z-index: 3;
}

/* Zone .ano : colonnes 14 à 18 */
.ano {
    grid-column: 16 / 19;
    grid-row: 1 / 7;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
    padding: 1rem;
    box-sizing: border-box;
}

.anomalies-table {
    flex: 1;
    background-color: #f9f9f9;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow-y: auto;
}

.anomalies-table table {
    width: 100%;
    border-collapse: collapse;
}

.anomalies-table th, .anomalies-table td {
    padding: 8px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.anomalies-table h4 {
    font-size: 1rem;
    text-align: center;
    margin-bottom: 1rem;
}

.anomalies-table tr:hover {
    background-color: #e0e0e0;
    cursor: pointer;
}
