* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', sans-serif;
}

body {
    min-height: 100vh;
    background: linear-gradient(135deg, #4facfe, #00f2fe);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.app {
    width: 100%;
    max-width: 500px;
}

.card {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 25px 45px rgba(0, 0, 0, 0.2);
    color: white;
    animation: fadeIn 0.6s ease-in-out;
}

.top h1 {
    text-align: center;
    margin-bottom: 20px;
}

.search-box {
    display: flex;
    gap: 10px;
}

.search-box input {
    flex: 1;
    padding: 12px;
    border-radius: 10px;
    border: none;
    outline: none;
}

.search-box button {
    padding: 12px 16px;
    border-radius: 10px;
    border: none;
    background: #ffffff;
    color: #333;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.search-box button:hover {
    background: #f1f1f1;
}

.loading, .error {
    text-align: center;
    margin-top: 15px;
}

.error {
    color: #ffdddd;
}

.weather {
    margin-top: 25px;
    text-align: center;
}

.main-info img {
    width: 100px;
}

.temp {
    font-size: 48px;
    font-weight: bold;
    margin: 10px 0;
}

.desc {
    text-transform: capitalize;
    margin-bottom: 20px;
}

.details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.box {
    background: rgba(255, 255, 255, 0.25);
    padding: 15px;
    border-radius: 12px;
}

.box span {
    font-size: 14px;
    opacity: 0.8;
}

.box p {
    font-size: 18px;
    font-weight: 600;
    margin-top: 5px;
}

.hidden {
    display: none;
}

@media (max-width: 480px) {
    .temp {
        font-size: 36px;
    }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}