/* Copyright João Saidler 2022 - Atualizado 2026 */
.phone, .state {
    display: flex;
}

.phone label:first-of-type {
    max-width: 25%;
    min-width: 50px;
    margin-right: 10px;
}

.state label:last-of-type {
    max-width: 25%;
    min-width: 50px;
    margin-left: 10px;
}

.form-row, .form-controls {
    display: grid;
    grid-gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.form-controls {
    justify-items: end;
}

label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    display: block;
    width: 100%;
    position: relative;
}

select, select option, select:focus, input, textarea, textarea:focus {
    padding: 5px;
    background-color: rgba(0, 0, 0, 0.015);
    border: none;
    border-bottom: 2px solid #005D97;
    font-size: 1rem;
    letter-spacing: 0.05rem;
    margin: 0 0 0.8rem 0;
    outline: none;
    width: 100%;
    resize: none;
    transition: 0.3s ease-in;
    font-display: swap;
    text-transform: capitalize;
    font-weight: 400;
    color: #3d3d3d;
}

input::placeholder {
    opacity: 0.8;
    color: rgb(99, 99, 99);
    font-style: italic;
}

select {
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-repeat: no-repeat;
    background-size: 0.5em auto;
    background-position: right 0.25em center;
    padding-right: 1em;
    background-image: url("data:image/svg+xml; charset=utf-8, <svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 40'> <polygon points='0,0 60,0 30,40'style='fill:slategrey;'/></svg>");
}

select:hover, select:focus {
    background-color: whitesmoke;
}

select option {
    background: whitesmoke;
}

select::-ms-expand {
    display: none;
}

textarea, textarea:focus {
    line-height: 4ch;
    border: none;
    padding: 0 5px;
}

.input-group {
    display: flex;
    position: relative;
    width: 100%;
}

.input-group .label {
    font-size: 0.7rem;
    position: absolute;
    bottom: -18%;
    left: 0.5rem;
}

.input-group .text-label {
    bottom: -10%;
}

.error, .success {
    font-size: 0.8rem;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 25px;
}

button {
    border: none;
    background-color: transparent;
}

button:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

/* ============================
   BOTÃO CALCULAR — novo estilo
   ============================ */
.button {
    cursor: pointer;
    user-select: none;
    padding: 13px 25px 13px 25px;
    color: #ffffff;
    background-color: #017bb4;
    border-radius: 7px;
    border: none;
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.2em;
    letter-spacing: 0;
    text-transform: none;
    width: fit-content;
    margin-top: 1rem;
    transition: transform 0.3s ease, background-color 0.3s ease;
    display: inline-block;
}

.button:hover {
    transform: scale(0.93); /* shrink animation */
    background-color: #017bb4;
}

.button:active {
    transform: scale(0.90);
}

.invalid {
    border-color: darkred;
}

.invalid+.validate-icon {
    content: url('../img/error_white_24dp.svg');
    position: absolute;
    margin: 5px;
    right: 0;
    opacity: 1;
    z-index: -1;
}

.valid {
    border-color: #008c00;
}
