/* ============================================================
   PREMIUM ECOLOGICA
   BOARD 4 PDP V2B3
   PURCHASE EXPERIENCE
   ============================================================ */

body.catalog-product-view {
    --pe-green: #168846;
    --pe-green-dark: #0d703b;
    --pe-green-soft: #f1f8f3;

    --pe-text: #103f2d;
    --pe-muted: #6d7973;

    --pe-border: #dce7e0;
}


/* ============================================================
   1. COLUNA DE DECISAO MAIS COMPACTA
   ============================================================ */

body.catalog-product-view
.product-info-main {
    padding-top: 2px !important;
}


/*
 * Remove espaços herdados desnecessários.
 */
body.catalog-product-view
.product-info-main
> * {
    box-sizing: border-box;
}


body.catalog-product-view
.product-info-main
.product-info-price {
    margin-bottom: 0 !important;
}


body.catalog-product-view
.product-info-main
.product-options-wrapper {
    margin-top: 12px !important;
    padding-top: 0 !important;

    clear: none !important;
}


body.catalog-product-view
.product-info-main
.product-options-bottom {
    margin-top: 4px !important;
    padding-top: 0 !important;
}


/* ============================================================
   2. PRECO / CONDICOES
   ============================================================ */

body.catalog-product-view
.product-info-main
.price-box
.price {
    color: var(--pe-text) !important;

    font-size: 37px !important;
    line-height: 1 !important;

    font-weight: 700 !important;
}


body.catalog-product-view
.product-info-main
.product-info-price {
    padding-bottom: 12px !important;

    border-bottom: 1px solid #e3ebe6 !important;
}


/*
 * Parcelamento.
 */
body.catalog-product-view
.product-info-main
.price-box
+ div,
body.catalog-product-view
.product-info-main
.price-box
~ div {
    margin-top: 4px;
}


/*
 * PIX
 */
body.catalog-product-view
.product-info-main
#preco-a-vista-mm {
    display: block !important;

    margin: 6px 0 0 !important;
}


body.catalog-product-view
.product-info-main
#preco-a-vista-mm
p {
    display: inline-flex !important;

    align-items: center !important;

    min-height: 30px !important;

    margin: 0 !important;
    padding: 5px 9px !important;

    background: #edf8f0 !important;

    border: 1px solid #d4eadb !important;
    border-radius: 6px !important;

    color: #087c3d !important;

    font-size: 12px !important;
    font-weight: 700 !important;
}


/* ============================================================
   3. VOLTAGEM
   ============================================================ */

body.catalog-product-view
.product-info-main
.product-options-wrapper
.field {
    margin-bottom: 7px !important;
}


body.catalog-product-view
.product-info-main
.product-options-wrapper
.label {
    margin-bottom: 6px !important;

    color: var(--pe-text) !important;

    font-size: 13px !important;
    font-weight: 700 !important;
}


body.catalog-product-view
.product-info-main
.premium-pdp-option-pills {
    gap: 8px !important;

    margin-top: 3px !important;
    margin-bottom: 3px !important;
}


body.catalog-product-view
.product-info-main
.premium-pdp-option-pill {
    display: inline-flex !important;

    align-items: center !important;
    justify-content: center !important;

    min-width: 92px !important;
    min-height: 42px !important;

    padding: 8px 17px !important;

    background: #fff !important;

    border: 1px solid #bdd7c6 !important;
    border-radius: 23px !important;

    color: var(--pe-text) !important;

    font-size: 13px !important;
    font-weight: 700 !important;

    cursor: pointer !important;
}


body.catalog-product-view
.product-info-main
.premium-pdp-option-pill:hover {
    border-color: var(--pe-green) !important;
}


body.catalog-product-view
.product-info-main
.premium-pdp-option-pill.is-selected {
    background: #eaf7ee !important;

    border-color: var(--pe-green) !important;

    color: #08743b !important;

    box-shadow:
        inset 0 0 0 1px var(--pe-green) !important;
}


/* hint */
body.catalog-product-view
.product-info-main
.premium-pdp-option-hint {
    margin: 3px 0 5px !important;

    color: var(--pe-muted) !important;

    font-size: 10px !important;
}


/* ============================================================
   4. QUANTIDADE
   ============================================================ */

body.catalog-product-view
.product-info-main
.box-tocart
.fieldset {
    display: grid !important;

    grid-template-columns:
        74px
        minmax(0, 1fr) !important;

    align-items: end !important;

    gap: 10px !important;
}


body.catalog-product-view
.product-info-main
.box-tocart
.field.qty {
    position: relative !important;

    width: 74px !important;

    margin: 0 !important;
}


body.catalog-product-view
.product-info-main
.box-tocart
.field.qty
.label {
    display: block !important;

    margin: 0 0 5px !important;

    color: var(--pe-text) !important;

    font-size: 12px !important;
    font-weight: 700 !important;
}


body.catalog-product-view
.product-info-main
#qty {
    width: 74px !important;
    height: 48px !important;

    margin: 0 !important;

    border: 1px solid #d0ddd5 !important;
    border-radius: 8px !important;

    background: #fff !important;

    text-align: center !important;

    box-shadow: none !important;
}


/*
 * Remove os controles quebrados herdados do tema.
 */
body.catalog-product-view
.product-info-main
.qty-changer,
body.catalog-product-view
.product-info-main
.field.qty
.qty-wrapper
> a,
body.catalog-product-view
.product-info-main
.field.qty
.control
> a {
    display: none !important;
}


/* ============================================================
   5. CTA PRINCIPAL
   ============================================================ */

body.catalog-product-view
.product-info-main
.box-tocart
.actions {
    width: 100% !important;

    margin: 0 !important;
}


body.catalog-product-view
.product-info-main
#product-addtocart-button {
    display: flex !important;

    align-items: center !important;
    justify-content: center !important;

    width: 100% !important;
    min-height: 50px !important;

    margin: 0 !important;
    padding: 10px 18px !important;

    border-radius: 8px !important;

    font-size: 15px !important;
    line-height: 1.2 !important;
    font-weight: 700 !important;

    box-shadow: none !important;

    transition:
        background-color .15s ease,
        border-color .15s ease,
        color .15s ease !important;
}


/* Sem voltagem selecionada */
body.catalog-product-view
.product-info-main
#product-addtocart-button[disabled] {
    background: #edf5ef !important;

    border: 1px solid #c8ddd0 !important;

    color: #48705b !important;

    opacity: 1 !important;

    cursor: not-allowed !important;
}


/* Pronto para comprar */
body.catalog-product-view
.product-info-main
#product-addtocart-button:not([disabled]) {
    background: var(--pe-green) !important;

    border: 1px solid var(--pe-green) !important;

    color: #fff !important;
}


body.catalog-product-view
.product-info-main
#product-addtocart-button:not([disabled]):hover {
    background: var(--pe-green-dark) !important;

    border-color: var(--pe-green-dark) !important;
}


/* ============================================================
   6. TRUST ATUAL - MAIS LEVE
   ============================================================ */

body.catalog-product-view
.product-info-main
.premium-board4-trust {
    margin-top: 15px !important;

    grid-template-columns:
        repeat(2, minmax(0, 1fr)) !important;

    gap: 8px !important;
}


body.catalog-product-view
.product-info-main
.premium-board4-trust__item {
    min-height: 62px !important;

    padding: 10px 11px !important;

    background: #fff !important;

    border: 1px solid var(--pe-border) !important;
    border-radius: 8px !important;

    box-shadow: none !important;
}


/* ============================================================
   7. FRETE ATUAL - COMPACTO
   V2B4 MOVERA PELO XML.
   ============================================================ */

body.catalog-product-view
.product-info-main
#simularFrete {
    margin-top: 12px !important;
    padding: 12px !important;

    background: #f8fbf9 !important;

    border: 1px solid var(--pe-border) !important;
    border-radius: 9px !important;

    box-shadow: none !important;
}


body.catalog-product-view
.product-info-main
#simularFrete
#cep {
    min-height: 42px !important;

    border-radius: 7px !important;
}


body.catalog-product-view
.product-info-main
#simularFrete
#sendFrete {
    min-height: 42px !important;

    border-radius: 7px !important;
}


/* ============================================================
   8. DESKTOP
   ============================================================ */

@media (min-width: 1024px) {

    /*
     * Ajusta levemente o palco.
     * Não altera a lógica Fotorama.
     */
    body.catalog-product-view
    .product.media
    .fotorama__stage,

    body.catalog-product-view
    .product.media
    .fotorama__stage__shaft,

    body.catalog-product-view
    .product.media
    .fotorama__stage__frame {
        height: 500px !important;
        min-height: 500px !important;
        max-height: 500px !important;
    }


    body.catalog-product-view
    .product.media
    .fotorama__stage
    .fotorama__img {
        max-width: 99% !important;
        max-height: 98% !important;

        object-fit: contain !important;
    }

}


/* ============================================================
   9. MOBILE
   ============================================================ */

@media (max-width: 767px) {

    body.catalog-product-view
    .product-info-main
    .box-tocart
    .fieldset {
        grid-template-columns:
            68px
            minmax(0, 1fr) !important;
    }


    body.catalog-product-view
    .product-info-main
    .field.qty,

    body.catalog-product-view
    .product-info-main
    #qty {
        width: 68px !important;
    }


    body.catalog-product-view
    .product-info-main
    #product-addtocart-button {
        min-height: 52px !important;
    }

}

