/* Style pour les dropdowns en mode sombre */
.Select-menu-outer {
    background-color: #333 !important;
    color: white !important;
}

.Select-option {
    background-color: #333 !important;
    color: white !important;
}

.Select-option.is-focused {
    background-color: #555 !important;
}

/* Pour le texte dans le dropdown */
.VirtualizedSelectOption {
    color: white !important;
}

/* Pour le texte sélectionné */
.Select-value-label {
    color: white !important;
}

/* Fix pour les dropdowns Dash Core Components */
#gdop-receiver-type {
    background-color: white !important;
}

#gdop-receiver-type .Select-control {
    background-color: white !important;
}

#gdop-receiver-type .Select-value-label,
#gdop-receiver-type .Select-placeholder {
    color: #212529 !important;
}

/* Fix pour le menu déroulant du récepteur GDOP */
.Select--single > .Select-control .Select-value {
    color: #212529 !important;
}

.VirtualizedSelectOption {
    background-color: white !important;
    color: #212529 !important;
}

.VirtualizedSelectFocusedOption {
    background-color: #e9ecef !important;
    color: #212529 !important;
}

/* Navigation */
.navbar {
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    margin-bottom: 20px;
}

.nav-link {
    margin: 0 10px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    background-color: rgba(255,255,255,0.1);
    border-radius: 5px;
}

.nav-link.active {
    font-weight: bold;
    border-bottom: 2px solid white;
}

/* Conteneurs de section */
.section-container {
    background-color: #252525;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.dash-graph {
  width: 100% !important;
  min-width: 100% !important;
  box-sizing: border-box !important;
}

.js-plotly-plot {
  width: 100% !important;
}

.progress-sm {
    height: 0.5rem !important;
}

.progress-xs {
    height: 0.25rem !important;
}

.progress-lg {
    height: 1.25rem !important;
}

/* Styles pour les barres de progression GNSS */
.gnss-progress {
    height: 0.5rem;
    border-radius: 0.25rem;
}

.gnss-progress-mini {
    height: 0.3rem;
    border-radius: 0.15rem;
}

/* Animations pour les barres de progression temps réel */
.gnss-progress-animated {
    background-image: linear-gradient(45deg, rgba(255,255,255,.15) 25%, transparent 25%, transparent 50%, rgba(255,255,255,.15) 50%, rgba(255,255,255,.15) 75%, transparent 75%, transparent);
    background-size: 1rem 1rem;
    animation: progress-bar-stripes 1s linear infinite;
}

@keyframes progress-bar-stripes {
    0% {
        background-position: 1rem 0;
    }
    100% {
        background-position: 0 0;
    }
}

/* NOAA Scales Forecast Table Styles */
#noaa-scales-forecast-tbody {
    table-layout: fixed;
}

#noaa-scales-forecast-tbody td {
    padding: 16px 20px;
    vertical-align: middle;
}

#noaa-scales-forecast-tbody td:first-child {
    text-align: left;
    width: 19%;
}

#noaa-scales-forecast-tbody td:nth-child(2) {
    width: 37%;
}

#noaa-scales-forecast-tbody td:nth-child(3) {
    width: 24%;
}

#noaa-scales-forecast-tbody td:nth-child(4) {
    width: 20%;
}

#noaa-scales-forecast-tbody td:not(:first-child) {
    text-align: center;
}

/* NOAA forecast chips */
.noaa-forecast-column {
    display: flex;
    flex-direction: column;
    gap: 14px;
    justify-content: center;
    align-items: center;
}

.noaa-forecast-row {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    justify-content: center;
}

.noaa-forecast-segment {
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
    box-shadow: inset 0 0 25px rgba(0, 0, 0, 0.2);
}

.noaa-forecast-row .noaa-forecast-segment {
    flex: 1 1 150px;
    max-width: 220px;
}

.noaa-level-badge {
    display: inline-block;
    padding: 4px 16px;
    border-radius: 999px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 0.9rem;
    background: rgba(255, 255, 255, 0.08);
}

.noaa-level-description {
    display: block;
    margin-top: 6px;
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.noaa-probability-chip {
    margin-top: 10px;
    padding: 8px 14px;
    border-radius: 12px;
    display: inline-flex;
    flex-direction: column;
    gap: 2px;
    min-width: 130px;
    align-items: center;
}

.noaa-probability-value {
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.2;
}

.noaa-probability-label {
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    opacity: 0.85;
}

.noaa-probability-meter {
    width: 100%;
    height: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    margin-top: 10px;
    overflow: hidden;
}

.noaa-probability-meter-fill {
    height: 100%;
    border-radius: inherit;
    transition: width 0.35s ease;
}

.noaa-forecast-geomagnetic .noaa-level-description {
    margin-top: 10px;
    font-size: 1rem;
}

.noaa-forecast-empty {
    color: rgba(255, 255, 255, 0.7);
    font-style: italic;
}

/* Ensure table maintains structure */
.table {
    table-layout: fixed;
}

.table thead th {
    border-bottom: 2px solid #dee2e6;
    padding: 10px;
}

/* Main NOAA Scales Table Styles */
#r-scale-value, #r-scale-max-24h,
#s-scale-value, #s-scale-max-24h,
#g-scale-value, #g-scale-max-24h {
    text-align: center !important;
    vertical-align: middle !important;
    padding: 10px !important;
    font-size: 1.1em !important;
    font-weight: bold !important;
}

/* Ensure proper column widths for NOAA scales table */
.table-noaa-scales {
    table-layout: fixed !important;
    width: 100% !important;
    border-collapse: collapse !important;
}

/* Force table headers to behave properly */
.table-noaa-scales thead {
    display: table-header-group !important;
}

.table-noaa-scales tbody {
    display: table-row-group !important;
}

.table-noaa-scales tr {
    display: table-row !important;
}

.table-noaa-scales th,
.table-noaa-scales td {
    display: table-cell !important;
    border: 1px solid #dee2e6 !important;
    padding: 10px !important;
    vertical-align: middle !important;
}

/* First column width */
.table-noaa-scales th:first-child,
.table-noaa-scales td:first-child {
    width: 15% !important;
    text-align: left !important;
}

/* Data columns - equal width for all */
.table-noaa-scales thead tr:nth-child(2) th:nth-child(2),
.table-noaa-scales thead tr:nth-child(2) th:nth-child(3),
.table-noaa-scales tbody td:nth-child(2),
.table-noaa-scales tbody td:nth-child(3) {
    width: 14% !important;
    text-align: center !important;
}

.table-noaa-scales thead tr:nth-child(2) th:nth-child(4),
.table-noaa-scales thead tr:nth-child(2) th:nth-child(5),
.table-noaa-scales tbody td:nth-child(4),
.table-noaa-scales tbody td:nth-child(5) {
    width: 14% !important;
    text-align: center !important;
}

.table-noaa-scales thead tr:nth-child(2) th:nth-child(6),
.table-noaa-scales thead tr:nth-child(2) th:nth-child(7),
.table-noaa-scales tbody td:nth-child(6),
.table-noaa-scales tbody td:nth-child(7) {
    width: 14.5% !important;
    text-align: center !important;
}

/* Colspan headers - force proper display */
.table-noaa-scales thead tr:first-child th[colspan] {
    text-align: center !important;
    font-weight: bold !important;
    background-color: #375a7f !important;
    color: white !important;
}

/* Prevent text from wrapping */
.table-noaa-scales th,
.table-noaa-scales td {
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* NOAA Scales Guide Styles */
#noaa-guide-header {
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#noaa-guide-header:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

#noaa-guide-collapse .card {
    margin-bottom: 15px;
    background-color: rgba(52, 58, 64, 0.95);
    border: 1px solid #445;
}

#noaa-guide-collapse .card-header {
    background-color: rgba(52, 58, 64, 0.8);
    border-bottom: 1px solid #556;
}

#noaa-guide-collapse .badge {
    font-size: 1.2em;
    padding: 8px 16px;
    margin-right: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

#noaa-guide-collapse .card[style*="borderLeft"] {
    transition: transform 0.2s ease;
}

#noaa-guide-collapse .card[style*="borderLeft"]:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

/* Tab styling for NOAA guide */
#noaa-guide-tabs .nav-link {
    color: #aaa;
    background-color: transparent;
    border: 1px solid transparent;
}

#noaa-guide-tabs .nav-link:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}

#noaa-guide-tabs .nav-link.active {
    color: #fff;
    background-color: #375a7f;
    border-color: #375a7f;
}

/* Space Weather Dashboard Button Styling */
.space-weather-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease !important;
}

.space-weather-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255,107,107,0.6) !important;
    background: linear-gradient(135deg, #ff8787 0%, #ff6b6b 100%) !important;
}

.space-weather-btn:active {
    transform: translateY(-1px);
}

/* Pulse animation for critical alerts icon */
@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.fa-exclamation-triangle {
    animation: pulse 2s infinite;
}
