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

body, * {
    font-family: 'Poppins', sans-serif;
}

:root {
    --colorDark1: #112D4E;
    --colorDark2: #3F72AF;
    --colorLight1: #DBE2EF;
    --colorLight2: #f9f7f7;
}

.wrapper{
    width: 100vw;
    min-height: 100vh;
    color: var(--colorLight2);
    background-image: linear-gradient(160deg, #000000, #434343);
    animation: gradientMove 15s ease infinite;
    background-repeat: no-repeat;
    background-size: cover;
    overflow: hidden;
}
@keyframes gradientMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
h1 {
    text-align: center;
    text-transform: uppercase;
    padding-top: 20px;
}

.tab-container {
    width: 90%;
    max-width: 550px;
    display: flex;
    justify-content: space-between;
    margin: 0 auto;
    margin-top: 4rem;

}

.tab {
    cursor: pointer;
    font-size: 0.875rem;
    letter-spacing: 1.75px;
    padding: 5px 8px;
}

.tab.current-tab {
    background-color: rgba(219,226,239,0.5);
    border-radius: 5px;
}

.weather-container {
    /* display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center; */
    margin-block: 4rem;
}

.btn {
    cursor: pointer;
    text-transform: uppercase;
    font-size: 0.85rem;
    border-radius: 5px;
    background-color: var(--colorDark2);
    border: none;
    padding: 10px 30px;
    color: var(--colorLight2);
}

.sub-container {
    display: flex;
    flex-direction: column;
    align-items: center;
} 

.grant-location-container {
    display: none ;
}
.grant-location-container.active {
    display: flex;
}
.grant-location-container img {
    margin-bottom: 2rem;
}

.grant-location-container p:first-of-type {
    font-size: 1.75rem;
    font-weight: 600;
}
.grant-location-container p:last-of-type {
    font-size: 0.85rem;
    font-weight: 500;
    margin-top: 0.75rem;
    margin-bottom: 1.75rem;
    letter-spacing: 0.75px;
}


.loading-container {
    display: none;
}

.loading-container.active {
    display: flex;
}

.loading-container p{
    text-transform: uppercase;
}


.user-info-container {
    display: none;
}

.user-info-container.active {
    display: flex;
}

.name {
    display: flex;
    align-items: center;
    gap: 0 0.5rem;
    margin-bottom: 1rem;
}
.user-info-container p {
    font-size: 1.5rem;
    font-weight: 200;
}

.user-info-container img {
    width: 90px;
    height: 90px;
}

.name p {
    font-size: 2rem;
}
.name img {
    width: 30px;
    height: 30px;
    object-fit: contain;
}

.user-info-container p[data-temp] {
    font-size: 2.75rem;
    font-weight: 700;
}

.parameter-container {
    display: flex;
    gap:10px 20px;
    justify-content: center;
    align-items: center;
    margin: 2rem;
}

.parameter {
    display: flex;
    flex-direction: column;
    min-width: 150px;
    max-width: 250px;
    background-color: rgba(219,226,239,0.5);
    border-radius: 5px;
    padding: 1rem;
    gap: 5px 0;

}

.parameter img {
    width: 50px;
    height: 50px;
}

.parameter p:first-of-type {
    text-transform: uppercase;
    font-size: 1.15rem;
    font-weight: 600;
}

.parameter p:last-of-type {
    font-size: 1rem;
    font-weight: 200;
}

.form-container {
    /* display: none; */
    display: flex;
    align-items: center;
    width: 90%;
    max-width: 550px;
    margin: 0 auto;
    gap: 0 10px;
    margin-bottom: 3rem;
}

.form-container.active {
    display: flex;
    /* justify-content: center;
    align-items: center; */
}

.form-container input {
    width: calc(100% - 80px);
    height: 40px;
    padding: 0 20px;
    background-color: rgba(219, 226, 239, 0.5);
    border-radius: 10px;
    border: none; 
    caret-color: #000000;
}

.form-container input::placeholder {
    color: rgba(255,255,255,0.7);
}


.form-container input:focus {
    outline: 3px solid rgba(255,255,255,0.7);
}

.form-container button {
    padding: unset;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1px;
}


/* ================= SIMPLE ANIMATIONS ================= */

/* Fade-in */
.fade-in {
  opacity: 0;
  animation: fadeIn 0.8s ease forwards;
}
@keyframes fadeIn {
  to { opacity: 1; }
}

/* Hover lift */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.hover-lift:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.4);
}

/* Gentle temperature glow */
.temp {
  animation: glow 3s ease-in-out infinite alternate;
}
@keyframes glow {
  from { text-shadow: 0 0 5px #00d4ff; }
  to   { text-shadow: 0 0 15px #00d4ff; }
}



/* ---------- MEDIA QUERIES ---------- */

/* Large tablets (≤1024px) */
@media (max-width: 1024px) {
    .parameter-container {
        gap: 15px;
    }
    .parameter {
        min-width: 160px;
        max-width: 220px;
        padding: 1.2rem;
    }
    .parameter img {
        width: 55px;
        height: 55px;
    }
}

/* Tablets (≤768px) */
@media (max-width: 768px) {
    .parameter-container {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }
    .parameter {
        flex: 1 1 45%;   /* 2 cards per row */
        max-width: 300px;
    }
}

/* Phones (≤480px) */
@media (max-width: 480px) {
    .parameter-container {
        flex-direction: column;
        align-items: center;
    }
    .parameter {
        width: 90%;       /* full width */
        max-width: none;  /* remove restriction */
    }
    .parameter img {
        width: 50px;
        height: 50px;
    }
    .parameter p:first-of-type {
        font-size: 1.1rem;
    }
    .parameter p:last-of-type {
        font-size: 1rem;
    }
}
