/* =========================================================
   CHECKOUT SETIÉN Y MARÍN
   Diseño personalizado EDD
========================================================= */


/* =========================================================
   BASE
========================================================= */

body.edd-checkout {
    background: #fafaf8;
}


/* Contenedor general */

body.edd-checkout #edd_checkout_form_wrap {

    max-width: 1180px;
    margin: 45px auto 80px;
    padding: 0 25px;

}


/* =========================================================
   INFORMACIÓN DE CUENTA
========================================================= */

body.edd-checkout .edd-blocks__logged-in {

    background: #ffffff;

    border: 1px solid #eeeeee;
    border-radius: 16px;

    padding: 16px 22px;
    margin-bottom: 24px;

    box-shadow: 0 6px 20px rgba(0,0,0,.04);

    font-size: 14px;

}

body.edd-checkout .edd-blocks__logged-in strong {

    font-weight: 700;

}


/* =========================================================
   CARRITO
========================================================= */

body.edd-checkout .edd-blocks__cart {

    background: #ffffff;

    border: 1px solid #eeeeee;
    border-radius: 20px;

    padding: 28px;

    margin-bottom: 30px;

    box-shadow: 0 10px 30px rgba(0,0,0,.05);

}


/* =========================================================
   CABECERA DEL CARRITO
========================================================= */

body.edd-checkout .edd-blocks-cart__row-header {

    display: grid;
    grid-template-columns: 1fr 150px;

    align-items: center;

    padding: 0 0 16px;

    border-bottom: 1px solid #eeeeee;

    font-size: 14px;

    color: #777;

}

body.edd-checkout .edd_cart_item_price {

    text-align: right;

}


/* =========================================================
   PRODUCTO
========================================================= */

body.edd-checkout .edd-blocks-cart__row-item {

    display: grid;
    grid-template-columns: 1fr 150px;

    align-items: center;

    padding: 22px 0;

    border-bottom: 1px solid #eeeeee;

}


/* Nombre + imagen */

body.edd-checkout .edd_checkout_cart_item_title {

    display: flex;
    align-items: center;

    gap: 18px;

    font-size: 17px;
    font-weight: 700;

    color: #2b2b2b;

}


/* Imagen */

body.edd-checkout .edd_cart_item_image {

    flex: 0 0 auto;

}

body.edd-checkout .edd_cart_item_image img {

    width: 72px;
    height: 72px;

    object-fit: cover;

    border-radius: 14px;

    display: block;

}


/* Precio */

body.edd-checkout .edd-blocks-cart__row-item .edd_cart_item_price {

    font-size: 18px;
    font-weight: 800;

    color: #2b2b2b;

}


/* =========================================================
   BOTÓN ELIMINAR
========================================================= */

body.edd-checkout .edd_cart_actions {

    display: inline-flex;

    margin-left: 12px;

    vertical-align: middle;

}

body.edd-checkout .edd-blocks-cart__action-remove {

    display: inline-flex;

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

    width: 34px;
    height: 34px;

    border-radius: 50%;

    text-decoration: none;

    transition: .2s ease;

}


/* Creamos la papelera con CSS */

body.edd-checkout .edd-blocks-cart__action-remove::before {

    content: "×";

    font-size: 24px;
    line-height: 1;

    color: #999;

}

body.edd-checkout .edd-blocks-cart__action-remove:hover {

    background: #f5f5f5;

    transform: scale(1.08);

}

body.edd-checkout .edd-blocks-cart__action-remove:hover::before {

    color: #333;

}


/* =========================================================
   IVA Y TOTAL
========================================================= */

body.edd-checkout .edd_cart_tax_row {

    padding: 16px 0 5px;

    border: 0;

    color: #777;

    font-size: 14px;

}

body.edd-checkout .edd_cart_total {

    padding: 8px 0 0;

    font-size: 24px;

    font-weight: 800;

    color: #222;

}

body.edd-checkout .edd_cart_total .edd_cart_amount {

    margin-left: 5px;

}


/* =========================================================
   ZONA DE COMPRA
========================================================= */

body.edd-checkout .edd-blocks__purchase-form {

    background: #ffffff;

    border: 1px solid #eeeeee;

    border-radius: 20px;

    padding: 35px;

    box-shadow: 0 10px 30px rgba(0,0,0,.05);

}


/* =========================================================
   TÍTULOS
========================================================= */

body.edd-checkout #edd_cc_address legend,
body.edd-checkout #edd_payment_mode_select legend,
body.edd-checkout #edd_cc_fields legend {

    margin: 0 0 22px;

    padding: 0;

    font-size: 24px;

    line-height: 1.3;

    font-weight: 800;

    color: #222;

}


/* =========================================================
   CAMPOS
========================================================= */

body.edd-checkout .edd-label {

    display: block;

    margin-bottom: 7px;

    font-size: 14px;

    font-weight: 600;

    color: #333;

}


/* Inputs */

body.edd-checkout input[type="text"],
body.edd-checkout input[type="email"],
body.edd-checkout input[type="tel"],
body.edd-checkout input[type="number"],
body.edd-checkout select {

    width: 100%;

    min-height: 48px;

    padding: 11px 14px;

    border: 1px solid #dddddd;

    border-radius: 10px;

    background: #ffffff;

    color: #333;

    font-size: 15px;

    box-sizing: border-box;

    transition: .2s ease;

}


/* Dirección */

body.edd-checkout #edd-card-address-wrap {

    margin-bottom: 18px;

}


/* Campos */

body.edd-checkout .edd-blocks-form__group {

    margin-bottom: 18px;

}


/* Foco */

body.edd-checkout input:focus,
body.edd-checkout select:focus {

    border-color: #90c6bb;

    outline: none;

    box-shadow: 0 0 0 3px rgba(144,198,187,.15);

}


/* =========================================================
   MÉTODO DE PAGO
========================================================= */

body.edd-checkout #edd_payment_mode_select {

    margin-top: 35px;

}


/* Opciones */

body.edd-checkout .edd-gateway-option {

    display: flex;

    align-items: center;

    gap: 10px;

    padding: 15px 17px;

    margin-bottom: 10px;

    border: 1px solid #e3e3e3;

    border-radius: 12px;

    background: #ffffff;

    cursor: pointer;

    transition: .2s ease;

}


/* Opción seleccionada */

body.edd-checkout .edd-gateway-option-selected {

    border-color: #90c6bb;

    background: #f8fcfb;

}


/* Iconos */

body.edd-checkout .edd-payment-icons {

    margin-left: auto;

    display: flex;

    align-items: center;

    gap: 4px;

}


/* =========================================================
   INFORMACIÓN DE PAGO
========================================================= */

body.edd-checkout #edd_purchase_form_wrap {

    margin-top: 30px;

}

body.edd-checkout #edd_secure_site_wrapper {

    display: flex;

    align-items: center;

    gap: 10px;

    margin-bottom: 18px;

    padding: 12px 15px;

    border-radius: 10px;

    background: #f7f7f7;

    color: #666;

    font-size: 13px;

}


/* =========================================================
   STRIPE
========================================================= */

body.edd-checkout #edd-stripe-payment-element {

    border-radius: 12px;

}


/* =========================================================
   TÉRMINOS Y PRIVACIDAD
========================================================= */

body.edd-checkout #edd_terms_agreement,
body.edd-checkout #edd-privacy-policy-agreement {

    margin-top: 25px;

    padding-top: 20px;

    border-top: 1px solid #eeeeee;

}

body.edd-checkout .edd-terms-agreement,
body.edd-checkout .edd-privacy-policy-agreement {

    display: flex;

    align-items: flex-start;

    gap: 9px;

    font-size: 13px;

    line-height: 1.5;

}

body.edd-checkout .edd-terms-agreement input,
body.edd-checkout .edd-privacy-policy-agreement input {

    margin-top: 3px;

    flex: 0 0 auto;

}


/* Enlaces */

body.edd-checkout .edd_terms_links {

    color: #555;

    font-size: 13px;

}


/* =========================================================
   BOTÓN FINALIZAR COMPRA
========================================================= */

body.edd-checkout #edd-purchase-button {

    display: block;

    width: 100%;

    margin-top: 30px;

    padding: 17px 30px !important;

    border: 0 !important;

    border-radius: 999px !important;

    background: #FFCB5B !important;

    color: #ffffff !important;

    font-size: 18px !important;

    font-weight: 800 !important;

    line-height: 1.2;

    cursor: pointer;

    transition: .2s ease;

}

body.edd-checkout #edd-purchase-button:not(:disabled):hover {

    transform: translateY(-2px);

    box-shadow: 0 8px 20px rgba(255,203,91,.25);

}

body.edd-checkout #edd-purchase-button:disabled {

    opacity: .55;

    cursor: not-allowed;

}


/* =========================================================
   AVISO CAMPOS OBLIGATORIOS
========================================================= */

body.edd-checkout .edd-required-fields-notice {

    margin-bottom: 25px;

    color: #777;

    font-size: 13px;

}


/* =========================================================
   OCULTAR CABECERA DEL TEMA
========================================================= */

.single-download .wh-header,
.single-download .header-mobile {

    display: none !important;

}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 900px) {

    body.edd-checkout #edd_checkout_form_wrap {

        margin: 30px auto 60px;

        padding: 0 18px;

    }

    body.edd-checkout .edd-blocks__cart,
    body.edd-checkout .edd-blocks__purchase-form {

        padding: 25px;

    }

}


@media (max-width: 700px) {

    body.edd-checkout #edd_checkout_form_wrap {

        margin: 20px auto 50px;

        padding: 0 12px;

    }


    /* Carrito */

    body.edd-checkout .edd-blocks__cart {

        padding: 18px;

        border-radius: 16px;

    }


    body.edd-checkout .edd-blocks-cart__row-header {

        grid-template-columns: 1fr 100px;

    }


    body.edd-checkout .edd-blocks-cart__row-item {

        grid-template-columns: 1fr 100px;

        padding: 18px 0;

    }


    body.edd-checkout .edd_checkout_cart_item_title {

        gap: 10px;

        font-size: 15px;

    }


    body.edd-checkout .edd_cart_item_image img {

        width: 58px;
        height: 58px;

        border-radius: 10px;

    }


    body.edd-checkout .edd-blocks__purchase-form {

        padding: 22px 18px;

        border-radius: 16px;

    }


    body.edd-checkout #edd_cc_address legend,
    body.edd-checkout #edd_payment_mode_select legend,
    body.edd-checkout #edd_cc_fields legend {

        font-size: 21px;

    }


    body.edd-checkout .edd-payment-icons {

        display: none;

    }

}

/* =========================================
   CHECKOUT — DISTRIBUCIÓN FINAL
   CARRITO 50% + COMPRA 50%
========================================= */

@media (min-width: 901px) {

    /* CONTENEDOR PRINCIPAL */

    body.edd-checkout #edd_checkout_form_wrap {

        max-width: 1200px;
        margin: 50px auto 80px;
        padding: 0 20px;

        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 35px;

        align-items: start;

        box-sizing: border-box;

    }


    /* USUARIO LOGUEADO */

    body.edd-checkout #edd_checkout_form_wrap > .edd-blocks__logged-in {

        grid-column: 1 / -1;

    }


    /* CARRITO */

    body.edd-checkout #edd_checkout_form_wrap > .edd-blocks__cart {

        grid-column: 1;
        grid-row: 2;

        width: 100%;

        box-sizing: border-box;

    }


    /* FORMULARIO */

    body.edd-checkout #edd_checkout_form_wrap > .edd-blocks__purchase-form {

        grid-column: 2;
        grid-row: 2;

        width: 100%;

        box-sizing: border-box;

        background: #ffffff;

        border-radius: 20px;

        padding: 30px;

        box-shadow: 0 10px 30px rgba(0,0,0,.05);

    }


    /* EVITAR QUE CAMPOS SE SALGAN */

    body.edd-checkout .edd-blocks__purchase-form *,
    body.edd-checkout .edd-blocks__purchase-form {

        box-sizing: border-box;
        max-width: 100%;

    }


    body.edd-checkout .edd-blocks__purchase-form input,
    body.edd-checkout .edd-blocks__purchase-form select {

        width: 100%;

    }


}


/* =========================================
   TABLET Y MÓVIL
========================================= */

@media (max-width: 900px) {


    body.edd-checkout #edd_checkout_form_wrap {

        display: block;

        width: 100%;

        padding: 0 15px;

    }


    body.edd-checkout .edd-blocks__cart,
    body.edd-checkout .edd-blocks__purchase-form {

        width: 100%;

        margin-bottom: 25px;

    }


    body.edd-checkout .edd-blocks__purchase-form {

        padding: 22px;

        border-radius: 16px;

    }


}

/* =========================================
   CHECKOUT - TÉRMINOS Y PRIVACIDAD
========================================= */


body.edd-checkout #edd_terms_agreement,
body.edd-checkout #edd-privacy-policy-agreement {

    display: block;

}


body.edd-checkout .edd-terms-agreement,
body.edd-checkout .edd-privacy-policy-agreement {

    display: flex;

    align-items: flex-start;

    gap: 10px;

    width: 100%;

    line-height: 1.5;

}


body.edd-checkout .edd-terms-agreement input,
body.edd-checkout .edd-privacy-policy-agreement input {

    width: auto !important;

    min-width: 16px;

    height: 16px;

    margin: 3px 0 0 0;

    flex: 0 0 auto;

}


body.edd-checkout .edd-terms-agreement label,
body.edd-checkout .edd-privacy-policy-agreement label {

    display: block;

    flex: 1;

    margin: 0;

}

/* =========================================
   FORZAR CHECKOUT A DOS COLUMNAS REALES
========================================= */

@media (min-width: 901px) {

    body.edd-checkout .edd-blocks__checkout {

        display: grid !important;

        grid-template-columns: 1fr 1fr !important;

        gap: 35px !important;

        width: 100% !important;

    }


    body.edd-checkout .edd-blocks__cart {

        grid-column: 1 !important;

        width: 100% !important;

    }


    body.edd-checkout .edd-blocks__purchase-form {

        grid-column: 2 !important;

        width: 100% !important;

    }

}

/* ==========================================
   CHECKOUT - ELIMINAR SIDEBAR DEL TEMA
   ========================================== */

body.edd-checkout .cbp-row.wh-content {
    width: 100%;
}

body.edd-checkout .cbp-row.wh-content .cbp-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}


body.edd-checkout .cbp-row.wh-content .three.fourths {
    width: 100% !important;
    float: none !important;
}


body.edd-checkout .cbp-row.wh-content .wh-sidebar {
    display: none !important;
}