/**
 * Styles pour la timeline TAF horizontale
 * Utilisé par les composants taf-timeline.php et taf-timeline-static.php
 */

/* Sections TAF */
.taf-section {
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #f9fafb;
    border-radius: 0.375rem;
}

.taf-timeline-container {
    background: #f9fafb;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
}

/* Tableau horizontal scrollable */
.taf-timeline-scroll {
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    overflow-x: auto;
}

.taf-timeline-table {
    width: auto;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.taf-timeline-table thead {
    background: #f3f4f6;
    border-bottom: 2px solid #d1d5db;
}

.taf-timeline-label {
    position: sticky;
    left: 0;
    background: #f3f4f6;
    font-weight: 600;
    color: #374151;
    padding: 0.75rem;
    text-align: left;
    min-width: 100px;
    max-width: 100px;
    width: 100px;
    border-right: 2px solid #d1d5db;
    z-index: 10;
    white-space: nowrap;
}

.taf-timeline-hour {
    text-align: center;
    padding: 0.75rem;
    min-width: 90px;
    max-width: 90px;
    width: 90px;
    border-left: 1px solid #e5e7eb;
    background: #f3f4f6;
    white-space: nowrap;
}

.hour-day {
    font-size: 0.7rem;
    color: #6b7280;
    text-transform: lowercase;
    margin-bottom: 0.25rem;
}

.hour-time {
    font-weight: 600;
    color: #111827;
    font-size: 0.85rem;
    margin-bottom: 0.25rem;
}

.hour-probability {
    font-size: 0.6rem;
    color: #ef4444;
    font-weight: 700;
}

.taf-timeline-cell {
    text-align: center;
    padding: 0.75rem;
    min-width: 90px;
    max-width: 90px;
    width: 90px;
    border-left: 1px solid #e5e7eb;
    border-top: 1px solid #e5e7eb;
    font-size: 0.75rem;
    background: white;
    white-space: nowrap;
}

.taf-timeline-table tbody tr:hover .taf-timeline-cell {
    background: #f9fafb;
}

/* Badge code VFR/IFR */
.cell-code {
    padding: 0.75rem;
}

.flight-rules-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 0.375rem;
    font-weight: 700;
    font-size: 10px;
    min-width: 40px;
}

.badge-vfr {
    background: #10b981;
    color: white;
}

.badge-mvfr {
    background: #3b82f6;
    color: white;
}

.badge-ifr {
    background: #ef4444;
    color: white;
}

.badge-lifr {
    background: #7c3aed;
    color: white;
}

/* Explications */
.taf-explanations {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.taf-explanation-item {
    padding: 1rem;
    background: #f9fafb;
    border-radius: 0.375rem;
    border-left: 4px solid #3b82f6;
    font-size: 0.875rem;
    line-height: 1.625;
}

/* TAF brut */
.taf-raw-box {
    background: #111827;
    border-radius: 0.375rem;
    padding: 1rem;
    margin-bottom: 1rem;
    border: 1px solid #374151;
}

.taf-raw-text {
    color: #10b981;
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    margin: 0;
    white-space: pre-wrap;
    word-break: break-all;
    line-height: 1.625;
}

.taf-metadata {
    font-size: 0.875rem;
    color: #6b7280;
    line-height: 1.625;
}

.taf-metadata p {
    margin: 0.5rem 0;
}

.taf-metadata strong {
    color: #111827;
}

/* Alert */
.alert {
    padding: 1rem;
    border-radius: 0.375rem;
    margin: 1rem 0;
}

.alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

/* Responsive */
@media (max-width: 768px) {
    .taf-timeline-container {
        padding: 0.5rem;
    }

    .taf-timeline-table {
        font-size: 0.75rem;
    }

    .taf-timeline-label {
        width: 80px;
        padding: 0.5rem;
    }

    .taf-timeline-hour {
        width: 70px;
        padding: 0.5rem;
    }

    .taf-timeline-cell {
        width: 70px;
        padding: 0.5rem;
    }

    .hour-day,
    .hour-time {
        font-size: 0.65rem;
    }
}
