* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #000000;
    min-height: 100vh;
    padding: 2rem;
    margin: 0;
}

.app-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    align-items: start;
    justify-items: center;
}

.search-modal {
    grid-column: 1 / -1;
    max-width: 500px;
    width: 100%;
    justify-self: center;
}

.forecast-modal {
    grid-column: 1 / -1;
    max-width: 500px;
    width: 100%;
    justify-self: center;
}

.radar-modal {
    grid-column: 1 / -1;
    max-width: 500px;
    width: 100%;
    justify-self: center;
}

.modal {
    background: #5B5B5B;
    border-radius: 8px;
    border: 2px solid #CC0000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.modal-header {
    background: #000000;
    color: #FFFFFF;
    padding: 1.5rem;
    text-align: center;
    border-bottom: 2px solid #FFF2CC;
}

.modal-header h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
}

.modal-content {
    padding: 2rem;
}

header {
    grid-column: 1 / -1;
    text-align: center;
    margin-bottom: 1rem;
}

header h1 {
    color: #FFFFFF;
    margin: 0;
    font-size: 2.5rem;
    font-weight: 700;
}

.input-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

#locationInput {
    width: 100%;
    padding: 1rem;
    border: 2px solid #5B5B5B;
    border-radius: 4px;
    font-size: 1rem;
    box-sizing: border-box;
    -webkit-appearance: none;
    background: #FFFFFF;
    color: #000000;
}

#locationInput:focus {
    outline: none;
    border-color: #FFF2CC;
    box-shadow: 0 0 0 2px rgba(255, 242, 204, 0.3);
}

#searchBtn {
    padding: 0.75rem 1.5rem;
    background: #000000;
    color: #FFFFFF;
    border: 2px solid #FFF2CC;
    border-radius: 4px;
    font-size: 1rem;
    cursor: pointer;
    box-sizing: border-box;
    -webkit-appearance: none;
    align-self: center;
}

#searchBtn:hover {
    background: #5B5B5B;
}

.weather-display {
}

.location-info h3 {
    color: #FFFFFF;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.location-info p {
    color: #FFFFFF;
    margin-bottom: 1.5rem;
}

.current-weather {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #5B5B5B;
    color: #FFFFFF;
    padding: 1.5rem;
    border-radius: 4px;
    margin: 1rem 0;
    border: 1px solid #000000;
}

.temperature {
    display: flex;
    align-items: center;
    gap: 1rem;
}

#temperature {
    font-size: 3rem;
    font-weight: bold;
}

#weatherIcon {
    font-size: 3rem;
}

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

.weather-details p {
    margin: 0.5rem 0;
    font-size: 1rem;
}

.hidden {
    display: none;
}

#radarMap {
    height: 400px;
    border-radius: 15px;
    overflow: hidden;
}

.forecast-container {
    background: #FFF2CC;
    border: 1px solid #5B5B5B;
    border-radius: 4px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 400px;
    overflow-y: auto;
}

.forecast-day {
    background: #FFFFFF;
    border: 1px solid #5B5B5B;
    border-radius: 4px;
    padding: 1rem 1.5rem;
    color: #000000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 60px;
}

.forecast-day:hover {
    background: #5B5B5B;
    color: #FFFFFF;
}

.forecast-day-left {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.forecast-day-name {
    font-weight: bold;
    font-size: 1rem;
    min-width: 50px;
}

.forecast-icon {
    font-size: 1.8rem;
    min-width: 40px;
    text-align: center;
}

.forecast-desc {
    font-size: 0.9rem;
    opacity: 0.95;
    flex: 1;
    text-align: left;
}

.forecast-temps {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
    font-weight: bold;
}

.forecast-high {
    font-weight: bold;
}

.forecast-low {
    opacity: 0.8;
    font-weight: normal;
}

.error {
    background: #CC0000;
    color: #FFFFFF;
    padding: 1rem;
    border-radius: 4px;
    margin-top: 1rem;
    border: 1px solid #000000;
}


@media (max-width: 768px) {
    body {
        padding: 1rem;
    }
    
    .app-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .modal-content {
        padding: 1.5rem;
    }
    
    .current-weather {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .weather-details {
        text-align: center;
    }
    
    #radarMap {
        height: 300px;
    }
    
    .forecast-container {
        padding: 0.75rem;
        gap: 0.5rem;
    }
    
    .forecast-day {
        padding: 0.75rem 1rem;
        min-height: 50px;
    }
    
    .forecast-day-left {
        gap: 0.75rem;
    }
    
    .forecast-day-name {
        min-width: 40px;
        font-size: 0.9rem;
    }
    
    .forecast-icon {
        font-size: 1.5rem;
        min-width: 35px;
    }
    
    .forecast-desc {
        font-size: 0.8rem;
    }
    
    .forecast-temps {
        font-size: 0.9rem;
    }
}