:root {
    --primary: #2c3e50;
    --secondary: #3498db;
    --secondary-h: #2980b9;
    --save: #007bff;
    --save-h: #065bb8;
    --accent: #e74c3c;
    --light: #ecf0f1;
    --dark: #2c3e50;
    --gray: gray;
    --silver: silver;
    --success: #27ae60;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
    --y: yellow;
    --y-h: #d9cb09;

}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', Arial, sans-serif;
}

body {

    margin-top: 20px;
    background: #f6f7f8;
}

.loader {

}

.title1 {
    border-radius: 5px;
    border: 1px solid;
    color: var(--dark);
    margin-top: 5px;
    margin-bottom: 5px;
    padding: 5px;
    border-color: var(--silver);
}

.btn {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 600;
    width: 100%;
}
.save{
    background-color: var(--save);
    color: white;
}
.save:hover{
    background-color: var(--save-h);
}
.add-to-cart{
    background-color: var(--secondary);
    color: white;
}
.add-to-cart:hover {
    background-color: var(--secondary-h);
}
.ia{
    background-color: var(--y);
    color: black;
}
.ia:hover{
    background-color: var(--y-h);
}
.btn1 {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid #cfd4d9;
    */ background: #fff;
    cursor: pointer;
    font-size: 14px;

    /* color: #111; */

    color: white;
}

.btn3 {
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #ddd;
    background: #fff;
    color: #111;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

.btn3:hover {
    background: #f3f4f6
}

.headbtns {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 12px;
}


.wrap {
    max-width: 900px;
    margin: 0 auto;
    justify-content: center; /* centraliza horizontalmente */
    background-color: silver;
    display: grid;
}

.box {
    background: #fff;
    margin: 12px;
    padding: 16px;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    margin-bottom: 12px;
    min-width: 700px;
    width: 100%; /* ocupa até 500px e se adapta no mobile */
}


.tar {
    text-align: right;
}

.tal {
    text-align: left;
}

.tac {
    text-align: center;
}

.d1 {
    border: solid 1px silver;
    border-radius: 12px;
    width: 100%;
}

.box1 {
    display: block;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 12px;
    background: #fff
}

.inp1 {
    padding: 10px;
    text-align: right;
    color: red !important;
    width: 100%;
    border: 0;
    outline: none;
    background: transparent;
}

@media (max-width: 768px) {
    .wrap {
        max-width: 100%;
        margin: 0;
        padding: 0 8px;
        justify-content: stretch;
    }

    .box {
        min-width: 0; /* remove o “travamento” de 500px */
        width: 100%;
        margin: 8px 0;
        padding: 12px;
    }
}

/* ===== Modal overlay global ===== */
.modal_loading {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0, 0, 0, .45);
    display: none; /* JS liga/desliga */
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal_loading.is_on {
    display: flex;
}

.modal_loading .modal_box {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 14px 16px;
    min-width: 220px;
    max-width: 92vw;
    display: flex;
    gap: 12px;
    align-items: center;
}

.modal_loading .modal_text {
    font-size: 14px;
    color: #111;
}

/* ===== Loader (div class="loader") ===== */
.loader {
    width: 18px;
    height: 18px;
    border: 3px solid #e5e7eb;
    border-top-color: #111;
    border-radius: 50%;
    animation: wcspin 0.9s linear infinite;
}

@keyframes wcspin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}
