/**
 * NAVS - Styles pages météo (METAR/TAF)
 * Utilise le même design que airport pages
 */

.weather-page {
    overflow-y: auto;
    background: var(--background-light);
    color: var(--text-dark);
}

/* Weather Type Badge (METAR/TAF indicator) */
.weather-type-badge {
    display: inline-block;
    padding: 0.4rem 0.8rem;
    background: #e3f2fd;
    border: 2px solid #2a5298;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 700;
    font-family: var(--font-mono);
    color: #2a5298;
}

/* Weather Content uses content-grid from airport.css */

/* Active state for quick action buttons */
.quick-action-btn.active {
    background: #2a5298;
    color: white;
    border-color: #2a5298;
}

/* Weather Card Header */
.weather-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
    transition: all var(--transition-base);
}

.tab-link:hover {
    background: var(--background-dark-alt);
    border-color: var(--accent-gold);
    color: var(--accent-gold);
    transform: translateY(-2px);
}

.tab-link.active {
    background: var(--accent-gold);
    color: var(--accent-navy);
    border-color: var(--accent-gold);
}

/* Weather Card - Bootstrap Compatible */
.weather-card {
    background: var(--background-dark-alt);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(201, 184, 150, 0.15);
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    margin-bottom: 2rem;
    overflow: hidden;
    transition: all var(--transition-base);
}

.weather-card:hover {
    border-color: rgba(201, 184, 150, 0.3);
    transform: translateY(-2px);
}

.weather-card .card-header {
    background: linear-gradient(135deg, var(--background-dark-alt) 0%, var(--background-dark) 100%);
    color: var(--text-light-alt);
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--accent-gold);
}

.weather-card .card-header h2 {
    margin: 0;
    font-size: 1.5rem;
    font-family: var(--font-display);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: 300;
}

.auto-refresh {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.85rem;
    color: #666;
}

.refresh-btn {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    color: #2a5298;
    padding: 0.5rem;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.1rem;
    transition: all 0.2s;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.refresh-btn:hover {
    background: #2a5298;
    color: white;
    transform: rotate(180deg);
    border-color: #2a5298;
}

.card-body {
    padding: 0;
}

/* Weather Loader */
.weather-loader {
    text-align: center;
    padding: 3rem;
    color: #666;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #2a5298;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Raw METAR/TAF Section */
.weather-raw-section {
    margin-bottom: 1.5rem;
}

.weather-raw-section h3 {
    font-size: 1.05rem;
    color: #2a5298;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.weather-raw {
    font-family: var(--font-mono);
    background: #f8f9fa;
    padding: 1.25rem;
    border-radius: 6px;
    font-size: 0.95rem;
    line-height: 1.6;
    color: #333;
    word-wrap: break-word;
    border-left: 3px solid #2a5298;
}

.source-info {
    margin-top: 0.5rem;
    font-size: 0.8rem;
    color: #666;
}

/* Decoded Section */
.decoded-section h3 {
    font-size: 1.05rem;
    color: #2a5298;
    margin-bottom: 1rem;
    font-weight: 600;
}

.weather-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.weather-metric {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    overflow: hidden;
}

/* Weather content full width */
.weather-content-full {
    max-width: 100%;
}

.weather-content-full .main-column {
    width: 100%;
    max-width: 100%;
}

/* Additional info section (below main content) */
.weather-additional-info {
    margin-top: 2rem;
}

.info-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.25rem;
    margin-top: 1.25rem;
}

.runway-info {
    padding: 0.5rem 0;
    border-bottom: 1px solid #e0e0e0;
    font-size: 0.9rem;
}

.runway-info:last-child {
    border-bottom: none;
}

.taf-detailed-content {
    width: 100%;
    overflow-x: auto;
}

.taf-detailed-content table {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    display: block;
}

.taf-detailed-content table tbody {
    display: table;
    width: 100%;
}
    text-align: center;
    color: var(--text-light);
    transition: all var(--transition-base);
}

.weather-metric:hover {
    border-color: rgba(201, 184, 150, 0.3);
    transform: translateY(-2px);
}

.metric-header {
    padding: 1rem;
    font-weight: 700;
}

.metric-header.vfr {
    background: #28a745;
}

.metric-header.mvfr {
    background: #007bff;
}

.metric-header.ifr {
    background: #ffc107;
    color: #333;
}

.metric-header.lifr {
    background: #dc3545;
}

.metric-body {
    padding: 1rem;
    font-size: 0.9rem;
}

.metric-value {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* TAF Periods - NAVS Style */
.taf-periods h3 {
    font-size: 1.2rem;
    font-family: var(--font-display);
    color: var(--text-light-alt);
    margin-bottom: 1rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: 300;
}

.taf-period {
    background: var(--background-dark);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    border-left: 4px solid var(--accent-gold);
    border: 1px solid rgba(201, 184, 150, 0.15);
    transition: all var(--transition-base);
}

.taf-period:hover {
    border-color: rgba(201, 184, 150, 0.3);
}

.period-time {
    font-weight: 700;
    font-family: var(--font-mono);
    color: var(--accent-gold);
    margin-bottom: 0.5rem;
    letter-spacing: 0.05em;
}

.period-conditions {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    color: var(--text-light);
}

/* Error Message - NAVS Style */
.weather-error {
    background: rgba(251, 191, 36, 0.1);
    border: 1px solid var(--warning);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    color: var(--text-light);
    text-align: center;
}

/* Info Section - Bootstrap Compatible */
.info-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.info-card {
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(201, 184, 150, 0.15);
    transition: all var(--transition-base);
}

.info-card:hover {
    border-color: rgba(201, 184, 150, 0.3);
    transform: translateY(-2px);
}

.info-card h3 {
    font-size: 1.2rem;
    font-family: var(--font-display);
    margin-bottom: 1rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: 300;
}

.info-card p {
    line-height: 1.6;
    color: var(--text-light);
    margin: 0;
}

.link-btn {
    display: block;
    padding: 0.75rem 1rem;
    background: var(--background-dark);
    color: var(--accent-gold);
    text-decoration: none;
    border-radius: var(--radius-md);
    border: 1px solid rgba(201, 184, 150, 0.2);
    margin-bottom: 0.5rem;
    transition: all var(--transition-base);
    font-weight: 500;
    font-family: var(--font-mono);
    letter-spacing: 0.05em;
}

.link-btn:hover {
    background: var(--accent-gold);
    color: var(--accent-navy);
    border-color: var(--accent-gold);
    transform: translateX(4px);
}

.runway-info {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.runway-info:last-child {
    border-bottom: none;
}

/* Responsive */
@media (max-width: 768px) {
    .weather-title {
        font-size: 1.5rem;
    }

    .weather-tabs {
        overflow-x: auto;
        white-space: nowrap;
    }

    .weather-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }

    .card-body {
        padding: 1rem;
    }

    .info-section {
        grid-template-columns: 1fr;
    }
}
