/*
Theme Name: Juan de la Madre Child
Theme URI: https://juandelamadre.com
Description: Tema hijo personalizado para la web de Juan de la Madre.
Author: Manuel
Author URI: https://maswp.net
Version: 1.0.0
Text Domain: amfissa-child
Template: amfissa
*/
body .qodef-woo-product-list.qodef-item-layout--info-below .qodef-woo-ratings {
    display:none;
}


@media only screen and (max-width: 680px) {
    body #qodef-page-mobile-header-inner {
        padding: 0 20px;
    }
}

body .qodef-woo-product-list.qodef-item-layout--info-below .qodef-woo-product-title a {
	padding-bottom: 20px;
}
.qodef-woo-product-content .jdlm-product-short-description {
    margin: 8px auto 12px;
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    line-height: 1.55;
    font-weight: 300;
    color: #5F5A50;
    text-align: center;
}

.qodef-woo-product-content .qodef-woo-product-title {
    margin-bottom: 0 !important;
}

.qodef-woo-product-content .qodef-woo-ratings {
    display: none !important;
}

.qodef-woo-product-content .qodef-woo-product-price {
    margin-top: 6px;
}

/* Iconos circulares de Elementor siempre redondos */
.elementor-widget-icon-box.elementor-view-stacked.elementor-shape-circle .elementor-icon,
.elementor-widget-icon.elementor-view-stacked.elementor-shape-circle .elementor-icon {
    width: 2em !important;
    height: 2em !important;
    min-width: 2em !important;
    min-height: 2em !important;
    padding: 0 !important;
    border-radius: 50% !important;
    box-sizing: border-box !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* El SVG se adapta dentro del círculo */
.elementor-widget-icon-box.elementor-view-stacked.elementor-shape-circle .elementor-icon svg,
.elementor-widget-icon.elementor-view-stacked.elementor-shape-circle .elementor-icon svg {
    width: 0.85em !important;
    height: 0.85em !important;
    max-width: 0.85em !important;
    max-height: 0.85em !important;
    display: block;
}

/* Oculta visualmente las etiquetas, pero las mantiene para accesibilidad */
.jdlm-contacto .jdlm-sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Separación entre campos */
.jdlm-contacto .jdlm-campo {
    margin-bottom: 2px;
}

/* Inputs y textarea */
.jdlm-contacto input[type="text"],
.jdlm-contacto input[type="email"],
.jdlm-contacto input[type="tel"],
.jdlm-contacto textarea {
    display: block;
    width: 100% !important;
    margin: 0 !important;
    padding: 14px 18px !important;
    background: #FAF7F0 !important;
    color: #26352A !important;
    border: 1px solid rgba(38, 53, 42, 0.2) !important;
    border-radius: 8px !important;
    box-shadow: none !important;
    font-family: "Inter", sans-serif !important;
    font-size: 15px !important;
    line-height: 1.4 !important;
}

.jdlm-contacto input[type="text"],
.jdlm-contacto input[type="email"],
.jdlm-contacto input[type="tel"] {
    min-height: 54px;
}

.jdlm-contacto textarea {
    min-height: 190px;
    resize: vertical;
}

/* Placeholder */
.jdlm-contacto ::placeholder {
    color: #696E60 !important;
    opacity: 1;
}

/* Campo activo */
.jdlm-contacto input:focus,
.jdlm-contacto textarea:focus {
    border-color: #26352A !important;
    outline: none !important;
}

/* Privacidad */
.jdlm-contacto .jdlm-aceptacion {
    margin: 6px 0 22px;
    color: #FAF7F0;
    font-size: 14px;
    line-height: 1.5;
}

.jdlm-contacto .wpcf7-list-item {
    margin: 0 !important;
}

.jdlm-contacto .wpcf7-acceptance label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
}

.jdlm-contacto .wpcf7-acceptance input[type="checkbox"] {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px;
    margin: 2px 0 0 !important;
    accent-color: #26352A;
}

.jdlm-contacto .jdlm-aceptacion a {
    color: #FFFFFF;
    text-decoration: underline;
}

/* Botón */
.jdlm-contacto input[type="submit"].jdlm-boton-enviar {
    display: inline-block !important;
    width: auto !important;
    min-height: 50px;
    margin: 0 !important;
    padding: 0 34px !important;
    background: #26352A !important;
    color: #FFFFFF !important;
    border: 1px solid #26352A !important;
    border-radius: 2px !important;
    box-shadow: none !important;
    font-family: "Inter", sans-serif !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    letter-spacing: 1.5px !important;
    line-height: 48px !important;
    text-transform: uppercase !important;
    cursor: pointer;
}

.jdlm-contacto input[type="submit"].jdlm-boton-enviar:hover {
    background: #F4EFE5 !important;
    color: #26352A !important;
    border-color: #F4EFE5 !important;
}

/* Mensajes de error */
.jdlm-contacto .wpcf7-not-valid-tip {
    margin-top: 6px;
    color: #ffc1c1;
    font-size: 13px;
}

.jdlm-contacto .wpcf7-response-output {
    margin: 20px 0 0 !important;
    padding: 12px 16px !important;
    border-width: 1px !important;
}

/* =====================================================
   BOTÓN DE ENVÍO - CONTACT FORM 7
===================================================== */

.jdlm-contacto button.wpcf7-submit {
    position: relative !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    width: auto !important;
    min-width: 150px;
    min-height: 52px;

    margin: 0 !important;
    padding: 14px 32px !important;

    background: #26352A !important;
    color: #FFFFFF !important;

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

    box-shadow: none !important;
    overflow: hidden !important;

    font-family: "Inter", sans-serif !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    letter-spacing: 1.5px !important;
    text-transform: uppercase !important;

    cursor: pointer !important;
    transition:
        background-color 0.25s ease,
        color 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease !important;
}

/* Texto interno añadido por el tema */
.jdlm-contacto button.wpcf7-submit .qodef-m-text {
    position: relative !important;
    z-index: 2 !important;
    color: inherit !important;
}

/* Desactiva la animación interna de Amfissa */
.jdlm-contacto button.wpcf7-submit .qodef-btn-fill-color {
    display: none !important;
}

/* Hover */
.jdlm-contacto button.wpcf7-submit:hover,
.jdlm-contacto button.wpcf7-submit:focus {
    background: #F4EFE5 !important;
    color: #26352A !important;
    border-color: #F4EFE5 !important;
    transform: translateY(-2px);
}

/* Botón mientras se está enviando */
.jdlm-contacto form.submitting button.wpcf7-submit {
    opacity: 0.7;
    cursor: wait !important;
    transform: none;
}

/* Spinner de Contact Form 7 */
.jdlm-contacto .wpcf7-spinner {
    margin: 0 0 0 12px !important;
    background-color: #26352A !important;
}



/* =====================================================
   MENSAJES GENERALES DEL FORMULARIO
===================================================== */

.jdlm-contacto .wpcf7-response-output {
    margin: 22px 0 0 !important;
    padding: 15px 18px !important;

    border: 1px solid transparent !important;
    border-radius: 8px !important;

    font-family: "Inter", sans-serif !important;
    font-size: 14px !important;
    line-height: 1.55 !important;

    box-shadow: none !important;
}

/* Envío realizado correctamente */
.jdlm-contacto form.sent .wpcf7-response-output {
    background: #E8F1E4 !important;
    color: #244526 !important;
    border-color: #A9C6A2 !important;
}

/* Campos incorrectos o sin rellenar */
.jdlm-contacto form.invalid .wpcf7-response-output,
.jdlm-contacto form.unaccepted .wpcf7-response-output {
    background: #FFF4E5 !important;
    color: #704B16 !important;
    border-color: #D8B46A !important;
}

/* Error de envío, servidor o correo */
.jdlm-contacto form.failed .wpcf7-response-output,
.jdlm-contacto form.aborted .wpcf7-response-output,
.jdlm-contacto form.spam .wpcf7-response-output {
    background: #F9E7E7 !important;
    color: #7A2929 !important;
    border-color: #D8A1A1 !important;
}

/* =====================================================
   ERRORES INDIVIDUALES
===================================================== */

.jdlm-contacto .wpcf7-not-valid-tip {
    display: block;
    margin-top: 6px !important;

    color: #7A2929 !important;

    font-family: "Inter", sans-serif !important;
    font-size: 13px !important;
    line-height: 1.4 !important;
}

/* Campos con error */
.jdlm-contacto input.wpcf7-not-valid,
.jdlm-contacto textarea.wpcf7-not-valid {
    border-color: #B75B5B !important;
    background-color: #FFF8F8 !important;
}


/* Igualar y organizar solo las cajas que contienen el enlace */
.elementor-widget-icon-box:has(.jm-enlace-ayuda),
.elementor-widget-icon-box:has(.jm-enlace-ayuda) > .elementor-widget-container,
.elementor-widget-icon-box:has(.jm-enlace-ayuda) .elementor-icon-box-wrapper {
    height: 100%;
}

.elementor-widget-icon-box:has(.jm-enlace-ayuda) .elementor-icon-box-wrapper,
.elementor-widget-icon-box:has(.jm-enlace-ayuda) .elementor-icon-box-content,
.elementor-widget-icon-box:has(.jm-enlace-ayuda) .elementor-icon-box-description {
    display: flex;
    flex-direction: column;
}

.elementor-widget-icon-box:has(.jm-enlace-ayuda) .elementor-icon-box-content,
.elementor-widget-icon-box:has(.jm-enlace-ayuda) .elementor-icon-box-description {
    flex: 1;
}

/* Botón */
.jm-enlace-ayuda {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: center;

    margin-top: auto;
    padding: 10px 18px;

    border: 1px solid #3f5f35;
    background-color: transparent;
    color: #3f5f35;

    font-size: 12px;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    text-decoration: none;

    transition: all 0.25s ease;
	margin-top: 20px;
}

.jm-enlace-ayuda:hover {
    background-color: #3f5f35;
    border-color: #3f5f35;
    color: #faf7f0;
}


/* =====================================================
   FOOTER JUAN DE LA MADRE
===================================================== */

/* Zona superior más compacta */
#qodef-page-footer-top-area {
    border-top: 1px solid rgba(63, 95, 53, 0.12);
}

#qodef-page-footer-top-area .qodef-content-grid {
    padding-top: 48px !important;
    padding-bottom: 42px !important;
}

/* Títulos */
#qodef-page-footer-top-area .qodef-widget-title {
    margin: 0 0 17px !important;
    color: #26352a;
    font-size: 21px;
    font-weight: 500;
    line-height: 1.2;
}

/* Texto general */
#qodef-page-footer-top-area p,
#qodef-page-footer-top-area li,
#qodef-page-footer-top-area a {
    font-size: 15px;
    line-height: 1.65;
}

/* Logo */
#qodef-page-footer-top-area .widget_media_image img {
    display: block;
    width: auto;
    max-width: 165px;
    margin-bottom: 17px;
}

/* Texto de marca */
.jm-footer-descripcion {
    max-width: 270px;
    margin: 0 0 11px;
}

.jm-footer-frase {
    max-width: 270px;
    margin: 0;
    color: #7a7b6d;
    font-style: italic;
}

/* Menús sin viñetas */
#qodef-page-footer-top-area .widget_nav_menu ul {
    margin: 0;
    padding: 0;
    list-style: none !important;
}

#qodef-page-footer-top-area .widget_nav_menu li {
    margin: 0 0 7px !important;
    padding: 0 !important;
    list-style: none !important;
}

#qodef-page-footer-top-area .widget_nav_menu li::before,
#qodef-page-footer-top-area .widget_nav_menu li::after {
    display: none !important;
    content: none !important;
}

#qodef-page-footer-top-area .widget_nav_menu li::marker {
    content: "";
}

/* Enlaces */
#qodef-page-footer a {
    color: #4f594d;
    text-decoration: none;
    transition: color 0.2s ease;
}

#qodef-page-footer a:hover {
    color: #3f5f35;
}

/* Contacto */
.jm-footer-contacto p {
    margin: 0 0 9px;
}

.jm-footer-contacto a {
    overflow-wrap: anywhere;
}

.jm-footer-social {
    margin-top: 15px !important;
}

/* =====================================================
   FRANJA INFERIOR
===================================================== */

#qodef-page-footer-bottom-area {
    border-top: 1px solid rgba(63, 95, 53, 0.16);
}

#qodef-page-footer-bottom-area .qodef-content-grid {
    padding-top: 14px !important;
    padding-bottom: 14px !important;
}

.jm-footer-copyright {
    margin: 0;
    color: #77796f;
    font-size: 12px;
    line-height: 1.4;
}

/* Pago seguro */
.jm-footer-pagos {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 13px;
}

.jm-footer-pagos-texto {
    color: #667061;
    font-size: 12px;
    font-weight: 500;
    line-height: 1;
    white-space: nowrap;
}

.jm-footer-pagos img {
    display: block;
    width: auto;
    max-width: 180px;
    max-height: 28px;
    margin: 0;
}
#qodef-page-footer .widget_nav_menu li a {
    font-size: 15px;
}
/* Tablet */
@media (max-width: 1024px) {
    #qodef-page-footer-top-area .qodef-content-grid {
        padding-top: 42px !important;
        padding-bottom: 25px !important;
    }

    #qodef-page-footer-top-area .qodef-grid-item {
        margin-bottom: 30px;
    }
}

/* Móvil */
@media (max-width: 767px) {
    #qodef-page-footer-top-area .qodef-content-grid {
        padding-top: 38px !important;
        padding-bottom: 15px !important;
    }

    #qodef-page-footer-top-area .qodef-grid-item {
        margin-bottom: 30px;
    }

    #qodef-page-footer-top-area .widget_media_image img {
        max-width: 150px;
    }

    .jm-footer-descripcion,
    .jm-footer-frase {
        max-width: 100%;
    }

    #qodef-page-footer-bottom-area .qodef-content-grid {
        padding-top: 17px !important;
        padding-bottom: 18px !important;
    }

    .jm-footer-copyright {
        margin-bottom: 14px;
    }

    .jm-footer-pagos {
        justify-content: flex-start;
        flex-wrap: wrap;
        gap: 10px;
    }

    .jm-footer-pagos img {
        max-width: 165px;
    }
}

#qodef-page-footer #qodef-page-footer-bottom-area .qodef-flex-line {
    height: 0;
}

.single-product .related.products .jdlm-product-short-description {
    max-width: 360px;
    margin: 14px auto 12px;
    color: #777168;
    font-size: 14px;
    line-height: 1.55;
    text-align: center;
}

@media (min-width: 1025px) {
    .single-product .related.products .jdlm-product-short-description {
        min-height: 44px;
    }
}

.qodef-page-title {
    display: none !important;
}
.single-product .product_meta .posted_in .qodef-woo-meta-label {
    font-size: 0;
}

.single-product .product_meta .posted_in .qodef-woo-meta-label::after {
    content: "Categoría:";
    font-size: 16px;
}

/* =====================================================
   ICONOS DE CUENTA Y CARRITO EN CABECERA MÓVIL
===================================================== */

@media only screen and (max-width: 1024px) {

    #qodef-page-mobile-header-inner {
        display: flex;
        align-items: center;
    }

    /*
     * Logo a la izquierda.
     */
    #qodef-page-mobile-header-inner
    .qodef-mobile-header-logo-link {
        margin-right: auto;
    }

    /*
     * Contenedor de cuenta y carrito.
     */
    #qodef-page-mobile-header-inner
    .jm-mobile-header-actions {
        display: flex !important;
        align-items: center;
        gap: 13px;
        width: auto;
        height: 100%;
        margin: 0 13px 0 auto;
        padding: 0;
    }

    /*
     * Limpiar márgenes que añade el tema a los widgets.
     */
    #qodef-page-mobile-header-inner
    .jm-mobile-header-actions .widget {
        display: flex;
        align-items: center;
        justify-content: center;
        width: auto;
        margin: 0 !important;
        padding: 0 !important;
    }

    /*
     * Enlaces e iconos.
     */
    #qodef-page-mobile-header-inner
    .jm-mobile-header-actions a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 24px;
        min-height: 34px;
        margin: 0;
        color: #3f5f35;
        line-height: 1;
    }

    /*
     * Tamaño del icono de Mi cuenta.
     */
    #qodef-page-mobile-header-inner
    .jm-mobile-header-actions
    .qodef-icon-holder,
    #qodef-page-mobile-header-inner
    .jm-mobile-header-actions
    .qodef-icon-font {
        font-size: 20px;
        line-height: 1;
    }

    /*
     * Icono del carrito.
     */
    #qodef-page-mobile-header-inner
    .jm-mobile-header-actions
    .qodef-m-opener-icon {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /*
     * Número de productos del carrito.
     */
    #qodef-page-mobile-header-inner
    .jm-mobile-header-actions
    .qodef-m-opener-count {
        top: -3px;
        right: -7px;
    }

    /*
     * Hamburguesa después de los dos iconos.
     */
    #qodef-page-mobile-header-inner
    .qodef-side-area-mobile-header-opener {
        flex: 0 0 auto;
        margin-left: 0;
    }
}

@media only screen and (max-width: 480px) {

    #qodef-page-mobile-header-inner
    .jm-mobile-header-actions {
        gap: 10px;
        margin-right: 11px;
    }
}

/* Avisos de WooCommerce en móvil */
@media (max-width: 767px) {

    .woocommerce-error,
    .woocommerce-info,
    .woocommerce-message {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        justify-content: flex-start !important;
        gap: 14px;

        width: 100%;
        margin: 20px 0 28px !important;
        padding: 18px !important;

        border: 1px solid #b9b2a6;
        background-color: #faf7f0;

        color: #4f524a;
        font-size: 14px;
        line-height: 1.6;
        text-align: left;
    }

    .woocommerce-error .button,
    .woocommerce-info .button,
    .woocommerce-message .button {
        display: flex !important;
        align-items: center;
        justify-content: center;

        order: 2;
        float: none !important;
        width: 100%;
        min-height: 46px;
        margin: 0 !important;
        padding: 12px 18px !important;

        background-color: #26352a;
        color: #faf7f0;

        font-size: 12px;
        font-weight: 600;
        line-height: 1.2;
        letter-spacing: 1.3px;
        text-align: center;
        text-transform: uppercase;
        white-space: normal;
    }

    .woocommerce-error .button:hover,
    .woocommerce-info .button:hover,
    .woocommerce-message .button:hover {
        background-color: #3f5f35;
        color: #ffffff;
    }
}
/* =====================================================
   AÑADIR AL CARRITO SIEMPRE VISIBLE Y CENTRADO
   Mantiene el estilo original de Amfissa
===================================================== */

/* Contenedor de información del producto */
.qodef-woo-product-content {
    position: relative !important;
    padding-bottom: 46px !important;
    overflow: visible !important;
}

/* Enlace Añadir al carrito */
.qodef-woo-product-content > a.button.add_to_cart_button,
.qodef-woo-product-content > a.button.product_type_simple {
    position: absolute !important;

    top: auto !important;
    right: auto !important;
    bottom: 0 !important;
    left: 50% !important;

    display: inline-flex !important;
    align-items: center;
    justify-content: center;

    width: max-content !important;
    max-width: calc(100% - 20px);
    margin: 0 !important;

    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;

    transform: translateX(-50%) !important;

    /* Evita que Amfissa anime la posición */
    transition:
        color 0.25s ease,
        border-color 0.25s ease,
        opacity 0.25s ease !important;

    white-space: nowrap;
    z-index: 5;
}

/* Mantener exactamente la misma posición al hacer hover */
.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content > a.button.add_to_cart_button,

.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content > a.button.product_type_simple,

.woocommerce ul.products li.product:hover
.qodef-woo-product-content > a.button {
    top: auto !important;
    right: auto !important;
    bottom: 0 !important;
    left: 50% !important;

    margin: 0 !important;
    opacity: 1 !important;
    visibility: visible !important;

    transform: translateX(-50%) !important;
}

/* Enlace Ver carrito después de añadir */
.qodef-woo-product-content > a.added_to_cart {
    display: block !important;
    width: max-content;
    margin: 10px auto 0 !important;
    text-align: center;
}

/* Móvil */
@media only screen and (max-width: 767px) {

    .qodef-woo-product-content {
        padding-bottom: 50px !important;
    }

    .qodef-woo-product-content > a.button.add_to_cart_button,
    .qodef-woo-product-content > a.button.product_type_simple {
        max-width: calc(100% - 10px);
        white-space: normal;
        text-align: center;
    }
}

/* =====================================================
   MANTENER EL PRECIO VISIBLE AL HACER HOVER
===================================================== */

.qodef-woo-product-content .price,
.qodef-woo-product-content .qodef-woo-product-price,
.woocommerce ul.products li.product .price {
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    pointer-events: auto !important;
}

/* Anular específicamente el efecto hover de Amfissa */
.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content .price,

.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content .qodef-woo-product-price,

.woocommerce ul.products li.product:hover
.qodef-woo-product-content .price,

.woocommerce ul.products li.product:hover
.qodef-woo-product-content .qodef-woo-product-price {
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
}

/* Mantener estable el espacio ocupado por el precio */
.qodef-woo-product-content .price,
.qodef-woo-product-content .qodef-woo-product-price {
    min-height: 25px;
}

/* =====================================================
   VER CARRITO DESPUÉS DE AÑADIR EL PRODUCTO
===================================================== */

/* Ocultar Añadir al carrito cuando el producto ya se ha añadido */
.qodef-woo-product-content > a.button.added {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

/* Colocar Ver carrito exactamente en el mismo lugar */
.qodef-woo-product-content > a.added_to_cart {
    position: absolute !important;

    top: auto !important;
    right: auto !important;
    bottom: 0 !important;
    left: 50% !important;

    display: inline-flex !important;
    align-items: center;
    justify-content: center;

    width: max-content !important;
    max-width: calc(100% - 20px);
    margin: 0 !important;
    padding: 5px 0 !important;

    opacity: 1 !important;
    visibility: visible !important;
    transform: translateX(-50%) !important;

    color: #3f5f35 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;

    font-size: 12px !important;
    font-weight: 500 !important;
    line-height: 1.3 !important;
    letter-spacing: 1.5px;
    text-align: center;
    text-transform: uppercase;
    text-decoration: none !important;
    white-space: nowrap;

    z-index: 6;
}

/* Línea fina al pasar el ratón */
.qodef-woo-product-content > a.added_to_cart:hover {
    color: #26352a !important;
    text-decoration: underline !important;
    text-underline-offset: 5px;
}

/* Evitar que Amfissa lo desplace */
.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content > a.added_to_cart,
.woocommerce ul.products li.product:hover
.qodef-woo-product-content > a.added_to_cart {
    right: auto !important;
    bottom: 0 !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
}

/* Móvil */
@media only screen and (max-width: 767px) {
    .qodef-woo-product-content > a.added_to_cart {
        max-width: calc(100% - 10px);
        white-space: normal;
    }
}

/* =====================================================
   PRODUCTOS: PRECIO Y COMPRA SIEMPRE VISIBLES
   Compatible con el efecto hover de Amfissa
===================================================== */

/* Reservar un espacio fijo debajo del precio */
.qodef-woo-product-content {
    position: relative !important;
    padding-bottom: 48px !important;
    overflow: visible !important;
}

/* Mantener siempre visible el precio */
.qodef-woo-product-content .qodef-woo-product-price,
.qodef-woo-product-content .price,
.woocommerce ul.products li.product .price {
    min-height: 24px;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
}

/* Botón normal: Añadir al carrito */
.qodef-woo-product-content
> a.button.add_to_cart_button:not(.added) {
    position: absolute !important;
    top: auto !important;
    right: auto !important;
    bottom: 0 !important;
    left: 50% !important;

    display: inline-flex !important;
    align-items: center;
    justify-content: center;

    width: max-content !important;
    max-width: calc(100% - 20px);
    margin: 0 !important;

    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translateX(-50%) !important;

    white-space: nowrap;
    z-index: 5;

    /* Evita la animación lateral del tema */
    transition: color 0.2s ease !important;
}

/* El botón original desaparece completamente tras añadir */
.qodef-woo-product-content
> a.button.add_to_cart_button.added {
    display: none !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

/* Ver carrito ocupa exactamente el lugar anterior */
.qodef-woo-product-content > a.added_to_cart.wc-forward {
    position: absolute !important;
    top: auto !important;
    right: auto !important;
    bottom: 0 !important;
    left: 50% !important;

    display: inline-flex !important;
    align-items: center;
    justify-content: center;

    width: max-content !important;
    max-width: calc(100% - 20px);
    margin: 0 !important;
    padding: 5px 0 !important;

    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translateX(-50%) !important;

    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #3f5f35 !important;

    font-size: 12px !important;
    font-weight: 500 !important;
    line-height: 1.3 !important;
    letter-spacing: 1.5px;
    text-align: center;
    text-transform: uppercase;
    text-decoration: none !important;
    white-space: nowrap;

    z-index: 6;
    transition: color 0.2s ease !important;
}

/* Anular cualquier desplazamiento aplicado por Amfissa al hacer hover */
.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content > a.button.add_to_cart_button:not(.added),

.woocommerce ul.products li.product:hover
.qodef-woo-product-content > a.button.add_to_cart_button:not(.added),

.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content > a.added_to_cart.wc-forward,

.woocommerce ul.products li.product:hover
.qodef-woo-product-content > a.added_to_cart.wc-forward {
    top: auto !important;
    right: auto !important;
    bottom: 0 !important;
    left: 50% !important;

    margin: 0 !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateX(-50%) !important;
}

/* Mantener también el precio durante el hover */
.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content .qodef-woo-product-price,

.qodef-woo-product-list .qodef-grid-item:hover
.qodef-woo-product-content .price,

.woocommerce ul.products li.product:hover
.qodef-woo-product-content .price {
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
}

/* Hover discreto de los enlaces */
.qodef-woo-product-content
> a.button.add_to_cart_button:not(.added):hover,

.qodef-woo-product-content
> a.added_to_cart.wc-forward:hover {
    color: #26352a !important;
}

/* Móvil */
@media only screen and (max-width: 767px) {

    .qodef-woo-product-content {
        padding-bottom: 52px !important;
    }

    .qodef-woo-product-content
    > a.button.add_to_cart_button:not(.added),

    .qodef-woo-product-content
    > a.added_to_cart.wc-forward {
        max-width: calc(100% - 12px);
        white-space: normal;
        text-align: center;
    }
}


/* =====================================================
   ERRORES DE VALIDACIÓN EN FINALIZAR COMPRA
===================================================== */

.woocommerce-checkout
.woocommerce-NoticeGroup-checkout {
    width: 100%;
    margin: 0 0 30px;
}

/* Convertir la lista horizontal del theme en una lista vertical */
.woocommerce-checkout
.woocommerce-NoticeGroup-checkout
ul.woocommerce-error {
    display: block !important;
    width: 100% !important;

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

    border: 1px solid #b8b0a3 !important;
    background-color: #faf7f0 !important;

    color: #3f5f35 !important;
    list-style: none !important;
}

/* Cada error en su propia línea */
.woocommerce-checkout
.woocommerce-NoticeGroup-checkout
ul.woocommerce-error > li {
    position: relative;
    display: block !important;

    width: 100% !important;
    margin: 0 !important;
    padding: 10px 0 10px 20px !important;

    border-bottom: 1px solid rgba(63, 95, 53, 0.14);

    color: #4f524a !important;
    font-size: 15px;
    line-height: 1.55;
}

/* Último error sin separador */
.woocommerce-checkout
.woocommerce-NoticeGroup-checkout
ul.woocommerce-error > li:last-child {
    border-bottom: 0;
}

/* Pequeño indicador delante de cada error */
.woocommerce-checkout
.woocommerce-NoticeGroup-checkout
ul.woocommerce-error > li::before {
    content: "";
    position: absolute;
    top: 19px;
    left: 0;

    width: 6px;
    height: 6px;

    border-radius: 50%;
    background-color: #a4553d;
}

/* Nombre del campo */
.woocommerce-checkout
.woocommerce-NoticeGroup-checkout
ul.woocommerce-error strong {
    color: #26352a;
    font-weight: 600;
}

/* Enlaces como términos y condiciones */
.woocommerce-checkout
.woocommerce-NoticeGroup-checkout
ul.woocommerce-error a {
    color: #3f5f35 !important;
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Móvil */
@media only screen and (max-width: 767px) {

    .woocommerce-checkout
    .woocommerce-NoticeGroup-checkout
    ul.woocommerce-error {
        padding: 14px 18px !important;
    }

    .woocommerce-checkout
    .woocommerce-NoticeGroup-checkout
    ul.woocommerce-error > li {
        padding: 10px 0 10px 18px !important;
        font-size: 14px;
    }
}
.widget_amfissa_core_woo_side_area_cart .qodef-widget-side-area-cart-inner .qodef-m-action.qodef-empty-cart-back-to-link {
   display: none !important;
}
body .woocommerce-price-suffix{
	padding-left:7px;
}

/* =====================================================
   COOKIEYES — COLORES JUAN DE LA MADRE
===================================================== */

:root {
    --jm-verde: #3f5f35;
    --jm-verde-hover: #2d4826;
    --jm-crema: #f4efe5;
    --jm-texto: #26352a;
}

/* Botón principal: Aceptar */
.cky-consent-container .cky-btn-accept,
.cky-modal .cky-btn-accept {
    color: #ffffff !important;
    background-color: var(--jm-verde) !important;
    border-color: var(--jm-verde) !important;
}

/* Hover del botón Aceptar */
.cky-consent-container .cky-btn-accept:hover,
.cky-modal .cky-btn-accept:hover {
    color: #ffffff !important;
    background-color: var(--jm-verde-hover) !important;
    border-color: var(--jm-verde-hover) !important;
}

/* Botones secundarios:
   Personalizar y Guardar mis preferencias */
.cky-consent-container .cky-btn-customize,
.cky-modal .cky-btn-preferences {
    color: var(--jm-verde) !important;
    background-color: transparent !important;
    border-color: var(--jm-verde) !important;
}

/* Hover de botones secundarios */
.cky-consent-container .cky-btn-customize:hover,
.cky-modal .cky-btn-preferences:hover {
    color: #ffffff !important;
    background-color: var(--jm-verde) !important;
    border-color: var(--jm-verde) !important;
}

/* Botón Rechazar, por si lo activas */
.cky-consent-container .cky-btn-reject,
.cky-modal .cky-btn-reject {
    color: var(--jm-verde) !important;
    background-color: transparent !important;
    border-color: var(--jm-verde) !important;
}

.cky-consent-container .cky-btn-reject:hover,
.cky-modal .cky-btn-reject:hover {
    color: #ffffff !important;
    background-color: var(--jm-verde) !important;
    border-color: var(--jm-verde) !important;
}

/* Enlaces: Política de cookies, Mostrar más, etc. */
.cky-consent-container .cky-policy,
.cky-modal .cky-policy,
.cky-modal .cky-show-desc-btn,
.cky-modal a {
    color: var(--jm-verde) !important;
}

/* Etiqueta "Siempre activas" */
.cky-modal .cky-always-active {
    color: var(--jm-verde) !important;
}

/* Interruptores de categorías cuando están activos */
.cky-modal input:checked + .cky-slider {
    background-color: var(--jm-verde) !important;
}

/* Bordes de enfoque accesibles */
.cky-consent-container .cky-btn:focus-visible,
.cky-modal .cky-btn:focus-visible,
.cky-modal button:focus-visible {
    outline: 2px solid var(--jm-verde) !important;
    outline-offset: 2px;
    box-shadow: none !important;
}

/* Ocultar el precio duplicado únicamente cuando funciona
   el cambio dinámico del precio principal */
.single-product
form.variations_form.jdlm-precio-dinamico-activo
.woocommerce-variation-price {
    display: none !important;
}