/*
 * Watford Time & Weather Widget Styles
 */

.watford-widget-container {
    margin-bottom: 2rem;
    animation: slideDown 0.6s ease-out;
}

.watford-widget {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(255, 240, 245, 0.9));
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 4px 20px rgba(189, 29, 58, 0.15);
    border: 1px solid rgba(189, 29, 58, 0.1);
    backdrop-filter: blur(10px);
    max-width: 400px;
    margin: 0 auto;
}

.widget-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(189, 29, 58, 0.1);
}

.location-icon {
    font-size: 1.2rem;
    margin-right: 0.5rem;
}

.location-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color, rgb(189, 29, 58));
}

.widget-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    align-items: center;
}

.time-section {
    text-align: center;
}

.current-time {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color, rgb(189, 29, 58));
    font-family: 'Courier New', monospace;
    margin-bottom: 0.25rem;
}

.current-date {
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
}

.weather-section {
    text-align: center;
}

.weather-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    color: #666;
}

.loading-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(189, 29, 58, 0.3);
    border-top: 2px solid var(--primary-color, rgb(189, 29, 58));
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 0.5rem;
}

.weather-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.weather-main {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.weather-icon {
    font-size: 2.5rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.weather-temp {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color, rgb(189, 29, 58));
}

.weather-details {
    text-align: center;
}

.weather-desc {
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.weather-wind {
    font-size: 0.8rem;
    color: #888;
}

.weather-source {
    font-size: 0.7em !important;
    opacity: 0.6 !important;
    color: #999 !important;
    margin-top: 0.25rem;
}

/* Animations */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .watford-widget {
        padding: 1.25rem;
        margin: 0 1rem 1.5rem 1rem;
    }

    .widget-content {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .current-time {
        font-size: 1.5rem;
    }

    .weather-icon {
        font-size: 2rem;
    }

    .weather-temp {
        font-size: 1.5rem;
    }

    .location-text {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .watford-widget {
        padding: 1rem;
        margin: 0 0.5rem 1rem 0.5rem;
    }

    .widget-header {
        margin-bottom: 0.75rem;
        padding-bottom: 0.5rem;
    }

    .current-time {
        font-size: 1.3rem;
    }

    .current-date {
        font-size: 0.8rem;
    }

    .weather-icon {
        font-size: 1.8rem;
    }

    .weather-temp {
        font-size: 1.3rem;
    }

    .weather-desc {
        font-size: 0.8rem;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .watford-widget {
        background: linear-gradient(135deg, rgba(30, 30, 30, 0.95), rgba(50, 30, 40, 0.9));
        border: 1px solid rgba(255, 255, 255, 0.1);
    }

    .location-text,
    .current-time,
    .weather-temp {
        color: #ff9fb5;
    }

    .current-date,
    .weather-desc,
    .weather-wind,
    .weather-loading {
        color: #ccc;
    }
}

/* High contrast support */
@media (prefers-contrast: high) {
    .watford-widget {
        border: 2px solid var(--primary-color, rgb(189, 29, 58));
    }

    .location-text,
    .current-time,
    .weather-temp {
        color: var(--primary-color, rgb(189, 29, 58));
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .watford-widget-container,
    .loading-spinner {
        animation: none;
    }

    .loading-spinner {
        border-top-color: var(--primary-color, rgb(189, 29, 58));
    }
}