* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    color: white;
    transition: background 1s ease;
    background: linear-gradient(to bottom right, #1e3a8a, #0f172a);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Styles */
header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 30px;
    padding: 20px 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 10px;
}

.logo-icon {
    font-size: 2.5rem;
    background: rgba(255, 255, 255, 0.2);
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

.logo-text {
    text-align: center;
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(to right, #ffffff, #a5b4fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 5px;
}

.tagline {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
}

.search-container {
    display: flex;
    width: 100%;
    max-width: 500px;
    margin-top: 20px;
}

.search-input {
    flex: 1;
    padding: 15px 20px;
    border: none;
    border-radius: 50px 0 0 50px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    color: white;
    font-size: 1rem;
    outline: none;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.search-btn {
    padding: 15px 25px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 0 50px 50px 0;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Main Content Styles */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 300px;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top: 4px solid white;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.error {
    background: rgba(220, 38, 38, 0.2);
    padding: 20px;
    border-radius: 15px;
    text-align: center;
    margin-bottom: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(220, 38, 38, 0.3);
}

.weather-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

/* Current Weather Card */
.current-weather {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.current-weather:hover {
    transform: translateY(-5px);
}

.current-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.location h2 {
    font-size: 2rem;
    margin-bottom: 5px;
}

.condition {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
}

.current-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.temperature {
    font-size: 5rem;
    font-weight: 700;
}

.weather-icon {
    font-size: 6rem;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
}

.current-details {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.detail-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 15px;
    text-align: center;
}

.detail-card .label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 5px;
}

.detail-card .value {
    font-size: 1.5rem;
    font-weight: 600;
}

/* Forecast Styles */
.forecast {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.forecast:hover {
    transform: translateY(-5px);
}

.section-title {
    font-size: 1.5rem;
    margin-bottom: 20px;
    font-weight: 600;
}

.forecast-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
}

.forecast-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 15px;
    text-align: center;
    transition: transform 0.3s ease;
}

.forecast-card:hover {
    transform: translateY(-3px);
}

.forecast-day {
    font-weight: 600;
    margin-bottom: 10px;
}

.forecast-icon {
    font-size: 2.5rem;
    margin: 10px 0;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.3));
}

.forecast-temp {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.forecast-high {
    font-weight: 600;
}

.forecast-low {
    color: rgba(255, 255, 255, 0.7);
}

/* Insights Styles */
.insights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.insight-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.insight-card:hover {
    transform: translateY(-5px);
}

.insight-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.insight-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    font-size: 1.5rem;
}

.insight-title {
    font-size: 1.3rem;
    font-weight: 600;
}

.insight-content {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.5;
}

/* Footer Styles */
footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

/* Responsive Design */
@media (min-width: 768px) {
    header {
        flex-direction: row;
        justify-content: space-between;
    }
    
    .search-container {
        margin-top: 0;
        width: auto;
    }
    
    .weather-grid {
        grid-template-columns: 2fr 1fr;
    }
    
    .current-weather {
        grid-column: 1 / -1;
    }
}

@media (min-width: 1024px) {
    .weather-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .current-weather {
        grid-column: 1 / -1;
    }
    
    .forecast {
        grid-column: 1 / -1;
    }
}

/* Animation for content appearance */
.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}