* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, Helvetica, sans-serif;
}

body {
    background-image: url("https://loremflickr.com/1600/900/weather,landscape");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
}

/* ===== CONTAINER PRINCIPAL ===== */
.caixa-maior {
    background-color: rgba(0, 0, 0, 0.9);
    width: 100%;
    max-width: 420px;
    padding: 18px;
    border-radius: 16px;
}

/* ===== BARRA DE BUSCA ===== */
.barra-busca {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
}

/* INPUT */
.input-cidade {
    flex: 1;
    min-width: 0; /* 🔥 EVITA VAZAMENTO */
    border: none;
    outline: none;
    border-radius: 20px;
    padding: 12px 14px;
    background-color: #7c7c7c2b;
    color: #fff;
    font-size: 16px;
}

.input-cidade::placeholder {
    color: #ccc;
}

/* BOTÕES */
.botao {
    flex-shrink: 0; /* 🔥 IMPEDE ESPREMER OU VAZAR */
    width: 42px;
    height: 42px;
    border: none;
    background-color: #7c7c7c2b;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: 0.25s;
}

.botao:hover {
    background-color: #7c7c7c;
    transform: scale(1.08);
}

.img-botao {
    width: 20px;
    height: 20px;
}

/* ===== CONTEÚDO ===== */
.caixa-media {
    margin-top: 20px;
    text-align: center;
}

.cidade {
    font-size: 18px;
    color: #fff;
}

.temp {
    font-size: 30px;
    color: #fff;
    margin: 8px 0;
    font-weight: bold;
}

.umidade {
    color: #fff;
    margin-top: 6px;
    font-size: 14px;
}

/* ===== BOTÃO IA ===== */
.botao-ia {
    border-radius: 10px;
    width: 100%;
    margin-top: 18px;
    padding: 14px;
    font-size: 15px;
    color: #fff;
    background-color: rgb(14, 121, 252);
    border: none;
    cursor: pointer;
    transition: 0.25s;
}

.botao-ia:hover {
    background-color: rgb(101, 153, 216);
}

.botao-ia:active {
    transform: scale(0.97);
}

/* ===== TEXTO IA ===== */
.resposta-ia {
    color: #fff;
    margin-top: 14px;
    font-size: 14px;
    line-height: 1.6;
}

/* ===== TABLET ===== */
@media (min-width: 768px) {
    .temp {
        font-size: 34px;
    }
}

/* ===== DESKTOP ===== */
@media (min-width: 1024px) {
    .caixa-maior {
        max-width: 450px;
    }

    .temp {
        font-size: 38px;
    }
}
