/* ============================================
   PAGE MÉTÉO MODERNE v2
   Design glassmorphism avec dégradés
   ============================================ */

/* Header sticky */
.header.glass {
    background: var(--bg-body);
}

[data-theme="light"] .header.glass {
    background: rgba(240, 244, 248, 0.95);
}

/* ============================================
   LOCALISATION
   ============================================ */
.meteo-location {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1rem;
    padding: 1.25rem;
    border-radius: 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
}

.meteo-location-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    border-radius: 14px;
    color: white;
}

.meteo-location-icon .material-icons {
    font-size: 1.5rem;
}

.meteo-location-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.meteo-city {
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--text-primary);
}

.meteo-region {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ============================================
   MÉTÉO ACTUELLE - Hero Card
   ============================================ */
.meteo-current {
    margin: 1rem;
    padding: 2rem;
    border-radius: 24px;
    background: linear-gradient(135deg, #1e1b4b 0%, #312e81 50%, #4338ca 100%);
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.meteo-current::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    pointer-events: none;
}

[data-theme="light"] .meteo-current {
    background: linear-gradient(135deg, #3b82f6 0%, #6366f1 50%, #8b5cf6 100%);
}

.meteo-current-main {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.meteo-current-icon {
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.3));
}

.meteo-current-temp {
    display: flex;
    align-items: flex-start;
}

.meteo-temp-value {
    font-size: 5rem;
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(180deg, #ffffff 0%, #e0e7ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.meteo-temp-unit {
    font-size: 2rem;
    font-weight: 500;
    margin-top: 0.5rem;
    opacity: 0.8;
}

.meteo-current-desc {
    font-size: 1.25rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    opacity: 0.95;
    position: relative;
    z-index: 1;
}

.meteo-current-details {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.meteo-detail {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    opacity: 0.9;
}

.meteo-detail .material-icons {
    font-size: 1.25rem;
    opacity: 0.8;
}

.meteo-detail strong {
    font-weight: 600;
}

/* ============================================
   LEVER/COUCHER DU SOLEIL
   ============================================ */
.meteo-sun {
    display: flex;
    align-items: center;
    margin: 1rem;
    padding: 1.25rem;
    border-radius: 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    gap: 1rem;
}

.meteo-sun-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.meteo-sun-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.meteo-sun-icon.sunrise {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: white;
}

.meteo-sun-icon.sunset {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: white;
}

.meteo-sun-icon .material-icons {
    font-size: 1.5rem;
}

.meteo-sun-info {
    display: flex;
    flex-direction: column;
}

.meteo-sun-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.meteo-sun-time {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.meteo-sun-progress {
    flex: 1;
    padding: 0 0.5rem;
}

.meteo-sun-bar {
    position: relative;
    height: 6px;
    background: var(--bg-elevated);
    border-radius: 3px;
    overflow: visible;
}

.meteo-sun-fill {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    background: linear-gradient(90deg, #fbbf24 0%, #f59e0b 50%, #6366f1 100%);
    border-radius: 3px;
    transition: width 0.5s ease;
}

.meteo-sun-position {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 16px;
    height: 16px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    border-radius: 50%;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.6);
    transition: left 0.5s ease;
    z-index: 2;
}

/* ============================================
   PRÉVISIONS 7 JOURS
   ============================================ */
.meteo-forecast {
    margin: 1rem;
    padding: 1.5rem;
    border-radius: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
}

.meteo-section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    color: var(--text-primary);
}

.meteo-section-title .icon-box {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    border-radius: 10px;
    color: white;
}

.meteo-section-title .icon-box .material-icons {
    font-size: 1.25rem;
}

.meteo-forecast-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.meteo-forecast-item {
    display: flex;
    align-items: center;
    padding: 1rem 1.25rem;
    background: var(--bg-elevated);
    border-radius: 16px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.meteo-forecast-item:hover {
    transform: translateX(4px);
    border-color: var(--primary-light);
}

.meteo-forecast-item.today {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(139, 92, 246, 0.1) 100%);
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.forecast-day {
    flex: 1;
    min-width: 0;
}

.forecast-day-name {
    display: block;
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-primary);
}

.forecast-day-date {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.forecast-day-desc {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 2px;
}

.forecast-icon {
    margin: 0 1rem;
}

.forecast-precip {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.8rem;
    color: #60a5fa;
    min-width: 50px;
    font-weight: 500;
}

.forecast-precip .material-icons {
    font-size: 1rem;
}

.forecast-temps {
    display: flex;
    gap: 0.75rem;
    min-width: 80px;
    justify-content: flex-end;
}

.forecast-temp-max {
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.forecast-temp-min {
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 500;
}

/* ============================================
   DÉTAILS SUPPLÉMENTAIRES
   ============================================ */
.meteo-extra {
    margin: 1rem;
    padding: 1.5rem;
    border-radius: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
}

.meteo-extra-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.meteo-extra-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.25rem;
    background: var(--bg-elevated);
    border-radius: 16px;
    text-align: center;
    transition: all 0.3s ease;
}

.meteo-extra-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.meteo-extra-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.1) 100%);
    border-radius: 14px;
    margin-bottom: 0.75rem;
}

.meteo-extra-icon .material-icons {
    font-size: 1.5rem;
    color: var(--primary-light);
}

.meteo-extra-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.meteo-extra-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* ============================================
   CHARGEMENT
   ============================================ */
.meteo-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 2rem;
    color: var(--text-muted);
}

.meteo-loading .material-icons {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ============================================
   FOOTER
   ============================================ */
.meteo-footer {
    margin: 1rem;
    padding: 1.25rem;
    border-radius: 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    text-align: center;
}

.meteo-footer p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 0;
}

.meteo-footer a {
    color: var(--primary-light);
    text-decoration: none;
    font-weight: 500;
}

.meteo-footer a:hover {
    text-decoration: underline;
}

.meteo-footer .footer-sub {
    font-size: 0.75rem;
    margin-top: 0.25rem;
    opacity: 0.7;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (min-width: 768px) {
    .meteo-location,
    .meteo-current,
    .meteo-sun,
    .meteo-forecast,
    .meteo-extra,
    .meteo-footer {
        max-width: 600px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .meteo-extra-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .meteo-temp-value {
        font-size: 6rem;
    }
}

/* ============================================
   MODE CLAIR
   ============================================ */
[data-theme="light"] .meteo-location,
[data-theme="light"] .meteo-sun,
[data-theme="light"] .meteo-forecast,
[data-theme="light"] .meteo-extra,
[data-theme="light"] .meteo-footer {
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .meteo-forecast-item {
    background: rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .meteo-forecast-item:hover {
    background: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .meteo-forecast-item.today {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1) 0%, rgba(99, 102, 241, 0.05) 100%);
}

[data-theme="light"] .meteo-extra-item {
    background: rgba(0, 0, 0, 0.03);
}

[data-theme="light"] .meteo-sun-bar {
    background: rgba(0, 0, 0, 0.08);
}

/* Bouton Accueil */
.home-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.2s;
}

.home-btn:hover {
    background: var(--primary-light);
    border-color: var(--primary-light);
    color: white;
}
