/* Weather Widget Styles */

.weather-widget {
    position: relative;
    display: flex;
    align-items: center;
    padding: 5px 15px;
    border-radius: 25px;
    overflow: hidden;
    min-width: 180px;
    height: 36px;
    transition: all 0.3s ease;
}

/* Weather Type Backgrounds */
.weather-clear {
    background: linear-gradient(135deg, #74b9ff 0%, #a29bfe 100%);
}

.weather-sunny, .weather-hot {
    background: linear-gradient(135deg, #fdcb6e 0%, #e17055 100%);
}

.weather-cloudy {
    background: linear-gradient(135deg, #b2bec3 0%, #636e72 100%);
}

.weather-rain {
    background: linear-gradient(135deg, #636e72 0%, #2d3436 100%);
}

.weather-thunderstorm {
    background: linear-gradient(135deg, #2d3436 0%, #1a1a2e 100%);
}

.weather-snow, .weather-cold {
    background: linear-gradient(135deg, #dfe6e9 0%, #b2bec3 100%);
}

.weather-fog {
    background: linear-gradient(135deg, #b2bec3 0%, #dfe6e9 100%);
}

/* Weather Info */
.weather-info {
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    z-index: 10;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.weather-icon {
    font-size: 20px;
    filter: drop-shadow(0 1px 2px rgba(0,0,0,0.3));
}

.weather-temp {
    font-weight: 700;
    font-size: 15px;
}

.weather-desc {
    font-size: 11px;
    opacity: 0.9;
    max-width: 80px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-transform: capitalize;
}

.weather-city {
    font-size: 10px;
    opacity: 0.7;
    display: none;
}

/* Animation Container */
.weather-animation {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    pointer-events: none;
}

/* Rain Animation */
.rain-drop {
    position: absolute;
    top: -10px;
    width: 2px;
    height: 10px;
    background: linear-gradient(to bottom, transparent, rgba(255,255,255,0.6));
    border-radius: 0 0 2px 2px;
    animation: rainFall 0.6s linear infinite;
}

@keyframes rainFall {
    0% {
        transform: translateY(-10px);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateY(50px);
        opacity: 0;
    }
}

/* Thunderstorm */
.lightning {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: transparent;
    transition: background 0.1s;
}

.lightning.flash {
    background: rgba(255, 255, 255, 0.8);
}

.cloud-dark {
    position: absolute;
    top: 2px;
    left: 10%;
    width: 30px;
    height: 12px;
    background: #2d3436;
    border-radius: 10px;
    opacity: 0.7;
}

.cloud-dark::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 5px;
    width: 15px;
    height: 15px;
    background: #2d3436;
    border-radius: 50%;
}

/* Snow Animation */
.snowflake {
    position: absolute;
    top: -10px;
    background: white;
    border-radius: 50%;
    opacity: 0.8;
    animation: snowFall 3s linear infinite;
}

@keyframes snowFall {
    0% {
        transform: translateY(-10px) rotate(0deg);
        opacity: 0;
    }
    20% {
        opacity: 1;
    }
    100% {
        transform: translateY(50px) rotate(360deg);
        opacity: 0;
    }
}

/* Sun Animation */
.sunny .sun, .hot .sun {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
}

.sun-core {
    width: 20px;
    height: 20px;
    background: #ffeaa7;
    border-radius: 50%;
    box-shadow: 0 0 10px #fdcb6e, 0 0 20px #f39c12;
    animation: sunPulse 2s ease-in-out infinite;
}

@keyframes sunPulse {
    0%, 100% {
        box-shadow: 0 0 10px #fdcb6e, 0 0 20px #f39c12;
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 15px #fdcb6e, 0 0 30px #f39c12;
        transform: scale(1.1);
    }
}

.sun-rays {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    transform: translate(-50%, -50%);
    animation: raysSpin 10s linear infinite;
}

.sun-rays::before,
.sun-rays::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 2px;
    height: 30px;
    background: linear-gradient(to bottom, #ffeaa7, transparent);
    transform-origin: center;
}

.sun-rays::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.sun-rays::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

@keyframes raysSpin {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

.heat-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, transparent, rgba(255,200,100,0.3), transparent);
    animation: heatWave 2s ease-in-out infinite;
}

@keyframes heatWave {
    0%, 100% {
        transform: translateX(-100%);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(100%);
    }
}

/* Cloud Animation */
.cloud {
    position: absolute;
    background: rgba(255,255,255,0.8);
    border-radius: 20px;
    animation: cloudFloat 8s ease-in-out infinite;
}

.cloud::before,
.cloud::after {
    content: '';
    position: absolute;
    background: rgba(255,255,255,0.8);
    border-radius: 50%;
}

.cloud-1 {
    width: 25px;
    height: 10px;
    top: 8px;
    left: -5px;
    animation-delay: 0s;
}

.cloud-1::before {
    width: 12px;
    height: 12px;
    top: -6px;
    left: 3px;
}

.cloud-1::after {
    width: 10px;
    height: 10px;
    top: -4px;
    left: 12px;
}

.cloud-2 {
    width: 20px;
    height: 8px;
    top: 5px;
    left: 30px;
    animation-delay: 2s;
    opacity: 0.6;
}

.cloud-2::before {
    width: 10px;
    height: 10px;
    top: -5px;
    left: 2px;
}

.cloud-3 {
    width: 15px;
    height: 6px;
    top: 12px;
    right: 20px;
    animation-delay: 4s;
    opacity: 0.4;
}

@keyframes cloudFloat {
    0%, 100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(10px);
    }
}

/* Fog Animation */
.fog-layer {
    position: absolute;
    left: -100%;
    width: 200%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: fogMove 6s linear infinite;
}

.fog-1 { animation-delay: 0s; top: 0; }
.fog-2 { animation-delay: 2s; top: 10px; opacity: 0.7; }
.fog-3 { animation-delay: 4s; top: 20px; opacity: 0.5; }

@keyframes fogMove {
    0% { transform: translateX(0); }
    100% { transform: translateX(50%); }
}

/* Clear Day */
.clear .sun-small {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    background: #ffeaa7;
    border-radius: 50%;
    box-shadow: 0 0 8px #fdcb6e;
    animation: sunPulse 3s ease-in-out infinite;
}

.clear .cloud-small {
    position: absolute;
    right: 25px;
    top: 8px;
    width: 15px;
    height: 6px;
    background: rgba(255,255,255,0.7);
    border-radius: 10px;
    animation: cloudFloat 5s ease-in-out infinite;
}

.clear .cloud-small::before {
    content: '';
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(255,255,255,0.7);
    border-radius: 50%;
    top: -4px;
    left: 2px;
}

/* Cold Animation */
.cold-particle {
    position: absolute;
    top: -10px;
    font-size: 8px;
    color: #74b9ff;
    animation: coldFall 2.5s linear infinite;
    text-shadow: 0 0 3px rgba(116, 185, 255, 0.8);
}

@keyframes coldFall {
    0% {
        transform: translateY(-10px) rotate(0deg);
        opacity: 0;
    }
    30% {
        opacity: 1;
    }
    100% {
        transform: translateY(40px) rotate(180deg);
        opacity: 0;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .weather-widget {
        min-width: 120px;
        padding: 5px 10px;
    }
    
    .weather-desc {
        display: none;
    }
    
    .weather-temp {
        font-size: 13px;
    }
}

/* Dark mode adjustments */
.weather-snow .weather-info,
.weather-cold .weather-info,
.weather-fog .weather-info {
    color: #2d3436;
    text-shadow: 0 1px 2px rgba(255,255,255,0.5);
}

