/* Ficha de producto · experiencia de compra clara y rápida */
body.single-product {
    --aco-product-green: #173f2b;
    --aco-product-green-dark: #0d2c1c;
    --aco-product-gold: #b69750;
    --aco-product-soft: #f6f8f2;
    --aco-product-line: #dfe6da;
    --aco-product-ink: #263128;
}

body.single-product .site-content {
    background: linear-gradient(180deg, #fff 0, #fafbf8 720px);
}

body.single-product div.product .summary {
    box-sizing: border-box;
    padding: 30px 32px 28px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent;
    box-shadow: none !important;
}

body.single-product div.product .woocommerce-product-gallery,
body.single-product div.product .woocommerce-product-gallery .flex-viewport,
body.single-product div.product .woocommerce-product-gallery__wrapper,
body.single-product div.product .woocommerce-product-gallery__image,
body.single-product div.product .woocommerce-product-gallery__image > a,
body.single-product div.product .woocommerce-product-gallery__image img {
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

body.single-product div.product .woocommerce-product-gallery__wrapper {
    margin: 0 !important;
    padding: 0 !important;
}

body.single-product div.product .woocommerce-product-gallery__trigger {
    display: none !important;
}

body.single-product .product_title {
    margin-bottom: 14px !important;
    color: var(--aco-product-green) !important;
    font-size: clamp(27px, 2.2vw, 38px) !important;
    line-height: 1.12 !important;
    text-wrap: balance;
}

body.single-product .ast-product-navigation-wrapper {
    display: none !important;
}

body.single-product .summary .woocommerce-product-rating {
    margin-bottom: 12px !important;
}

body.single-product .summary .price {
    margin: 10px 0 8px !important;
    color: var(--aco-product-green) !important;
    font-size: 27px !important;
    font-weight: 800 !important;
}

body.single-product .summary .stock {
    display: inline-flex;
    align-items: center;
    margin: 10px 0 18px !important;
    padding: 7px 12px;
    border-radius: 999px;
    background: #edf6e8;
    color: #376c25 !important;
    font-size: 14px;
    font-weight: 700;
}

body.single-product .summary .stock::before {
    content: "✓";
    margin-right: 7px;
}

body.single-product form.cart {
    display: grid !important;
    grid-template-columns: minmax(150px, 176px) minmax(220px, 1fr) !important;
    gap: 16px !important;
    align-items: stretch !important;
    width: 100% !important;
    margin: 8px 0 0 !important;
    padding: 20px 0 0 !important;
    border-top: 1px solid var(--aco-product-line);
}

body.single-product form.cart .quantity {
    display: grid !important;
    grid-column: 1 !important;
    grid-row: 1 !important;
    grid-template-columns: 48px 1fr 48px !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 56px !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden;
    border: 1px solid #cbd7c4 !important;
    border-radius: 14px !important;
    background: var(--aco-product-soft) !important;
    box-shadow: none !important;
}

body.single-product form.cart .quantity .minus,
body.single-product form.cart .quantity .plus,
body.single-product form.cart .quantity .qty {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    height: 54px !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

body.single-product form.cart .quantity .minus,
body.single-product form.cart .quantity .plus {
    color: var(--aco-product-green) !important;
    font-size: 21px !important;
    font-weight: 800 !important;
}

body.single-product form.cart .quantity .qty {
    justify-self: stretch !important;
    padding: 0 !important;
    text-align: center !important;
}

body.single-product.woocommerce div.product form.cart button.single_add_to_cart_button.button.alt {
    display: inline-flex !important;
    grid-column: 2 !important;
    grid-row: 1 !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    max-width: none !important;
    min-height: 56px !important;
    height: 56px !important;
    margin: 0 !important;
    padding: 13px 24px !important;
    border: 1px solid var(--aco-product-green) !important;
    border-radius: 14px !important;
    background: var(--aco-product-green) !important;
    color: #fff !important;
    box-shadow: 0 10px 24px rgba(23, 63, 43, .2) !important;
    font-size: 16px !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
    letter-spacing: .01em;
    text-transform: none !important;
}

body.single-product.woocommerce div.product form.cart button.single_add_to_cart_button.button.alt:hover {
    border-color: var(--aco-product-green-dark) !important;
    background: var(--aco-product-green-dark) !important;
    transform: translateY(-1px);
}

.aco-product-benefits {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-top: 16px;
}

.aco-product-benefit {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    padding: 12px;
    border: 1px solid var(--aco-product-line);
    border-radius: 12px;
    background: var(--aco-product-soft);
}

.aco-product-benefit > span {
    grid-row: 1 / 3;
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--aco-product-green);
    color: #fff;
    font-weight: 800;
}

.aco-product-benefit strong {
    color: var(--aco-product-ink);
    font-size: 13px;
    line-height: 1.25;
}

.aco-product-benefit small {
    margin-top: 2px;
    color: #667068;
    font-size: 11px;
    line-height: 1.25;
}

.aco-mobile-buybar {
    display: none;
}

@media (max-width: 767px) {
    body.single-product .woocommerce-breadcrumb {
        display: none !important;
    }

    body.single-product div.product .woocommerce-product-gallery {
        width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 0 20px !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: #fff !important;
        box-shadow: none !important;
    }

    body.single-product div.product .woocommerce-product-gallery #ast-gallery-thumbnails,
    body.single-product div.product .woocommerce-product-gallery .ast-vertical-navigation-wrapper {
        display: none !important;
    }

    body.single-product div.product .woocommerce-product-gallery .flex-viewport {
        width: 100% !important;
        height: 240px !important;
        margin: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: #fff !important;
        box-shadow: none !important;
    }

    body.single-product div.product .woocommerce-product-gallery .woocommerce-product-gallery__image {
        height: 240px !important;
    }

    body.single-product div.product .woocommerce-product-gallery .woocommerce-product-gallery__image > a {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        height: 240px !important;
    }

    body.single-product div.product .woocommerce-product-gallery .woocommerce-product-gallery__image img {
        width: 100% !important;
        height: 240px !important;
        max-height: 240px !important;
        padding: 12px !important;
        object-fit: contain !important;
    }

    body.single-product div.product .summary {
        width: 100% !important;
        margin: 0 !important;
        padding: 18px 20px 24px !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: #fff !important;
        box-shadow: none !important;
    }

    body.single-product .product_title {
        font-size: 26px !important;
        line-height: 1.16 !important;
    }

    body.single-product .summary .price {
        font-size: 24px !important;
    }

    body.single-product form.cart {
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 12px !important;
    }

    body.single-product form.cart .quantity,
    body.single-product form.cart .single_add_to_cart_button {
        width: 100% !important;
        max-width: none !important;
    }

    body.single-product form.cart .quantity {
        grid-column: 1 !important;
        grid-row: 1 !important;
    }

    body.single-product.woocommerce div.product form.cart button.single_add_to_cart_button.button.alt {
        grid-column: 1 !important;
        grid-row: 2 !important;
    }

    .aco-product-benefits {
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 8px;
    }

    .aco-product-benefit {
        grid-template-columns: 34px minmax(0, 1fr);
        padding: 10px 12px;
    }

    body.single-product #review_form_wrapper,
    body.single-product #review_form,
    body.single-product #reviews #respond,
    body.single-product #reviews #commentform {
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: none !important;
    }

    body.single-product #reviews #respond {
        margin: 20px 0 0 !important;
        padding: 20px !important;
        border: 1px solid var(--aco-product-line) !important;
        border-radius: 16px !important;
        background: #fff !important;
        box-shadow: 0 10px 28px rgba(23, 63, 43, .08) !important;
    }

    body.single-product #reviews #reply-title {
        display: block;
        margin: 0 0 10px !important;
        color: var(--aco-product-green) !important;
        font-size: 22px !important;
        line-height: 1.2 !important;
    }

    body.single-product #reviews #commentform > p,
    body.single-product #reviews #commentform .comment-form-rating {
        width: 100% !important;
        margin: 0 0 16px !important;
    }

    body.single-product #reviews #commentform .comment-form-rating {
        display: block !important;
        height: auto !important;
    }

    body.single-product #reviews #commentform label {
        display: block !important;
        margin: 0 0 7px !important;
        color: var(--aco-product-ink) !important;
        font-size: 16px !important;
        font-weight: 700 !important;
        line-height: 1.3 !important;
    }

    body.single-product #reviews #commentform p.stars {
        display: flex !important;
        flex-wrap: nowrap !important;
        justify-content: flex-start !important;
        gap: 7px !important;
        width: 100% !important;
        height: auto !important;
        margin: 8px 0 0 !important;
    }

    body.single-product #reviews #commentform p.stars a {
        flex: 0 0 36px !important;
        width: 36px !important;
        height: 36px !important;
        margin: 0 !important;
    }

    body.single-product #reviews #commentform textarea,
    body.single-product #reviews #commentform input[type="text"],
    body.single-product #reviews #commentform input[type="email"] {
        box-sizing: border-box !important;
        width: 100% !important;
        max-width: none !important;
        min-height: 52px;
        padding: 12px 14px !important;
        border: 1px solid #cbd7c4 !important;
        border-radius: 12px !important;
        background: #fff !important;
        box-shadow: none !important;
    }

    body.single-product #reviews #commentform textarea {
        min-height: 120px;
        resize: vertical;
    }

    body.single-product #reviews #commentform .comment-form-cookies-consent {
        display: grid !important;
        grid-template-columns: 22px minmax(0, 1fr);
        gap: 10px;
        align-items: start;
    }

    body.single-product #reviews #commentform .comment-form-cookies-consent input {
        width: 18px !important;
        height: 18px !important;
        margin: 3px 0 0 !important;
    }

    body.single-product #reviews #commentform .comment-form-cookies-consent label {
        margin: 0 !important;
        font-size: 14px !important;
        font-weight: 500 !important;
    }

    body.single-product #reviews #submit {
        width: 100% !important;
        min-height: 50px;
        border-radius: 12px !important;
        background: var(--aco-product-green) !important;
        color: #fff !important;
        font-weight: 800 !important;
    }

    .aco-mobile-buybar {
        position: fixed;
        right: 10px;
        bottom: calc(10px + env(safe-area-inset-bottom, 0px));
        left: 10px;
        z-index: 9998;
        display: grid;
        grid-template-columns: minmax(90px, auto) minmax(160px, 1fr);
        gap: 10px;
        align-items: center;
        padding: 10px;
        border: 1px solid rgba(23, 63, 43, .15);
        border-radius: 16px;
        background: rgba(255, 255, 255, .97);
        box-shadow: 0 12px 34px rgba(13, 44, 28, .24);
        opacity: 0;
        pointer-events: none;
        transform: translateY(130%);
        transition: opacity .2s ease, transform .2s ease;
        backdrop-filter: blur(10px);
    }

    .aco-mobile-buybar.aco-visible {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .aco-mobile-buybar-price {
        color: var(--aco-product-green);
        font-size: 18px;
        font-weight: 800;
        line-height: 1.15;
        text-align: center;
    }

    .aco-mobile-buybar-price small,
    .aco-mobile-buybar-price .woocommerce-Price-currencySymbol + span {
        font-size: 12px;
    }

    .aco-mobile-buybar-button {
        min-height: 50px;
        padding: 10px 16px;
        border: 0;
        border-radius: 12px;
        background: var(--aco-product-green);
        color: #fff;
        font-size: 15px;
        font-weight: 800;
    }

    body.single-product.aco-buybar-active #gt_float_wrapper {
        bottom: calc(96px + env(safe-area-inset-bottom, 0px)) !important;
    }

    body.single-product.aco-buybar-active .qlwapp__container.qlwapp__container--bottom-right {
        right: 10px !important;
        bottom: calc(96px + env(safe-area-inset-bottom, 0px)) !important;
        left: auto !important;
        width: auto !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    body.single-product.aco-buybar-active .qlwapp__container.qlwapp__container--bottom-right .qlwapp__button {
        margin: 0 !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .aco-mobile-buybar,
    body.single-product form.cart .single_add_to_cart_button {
        transition: none !important;
    }
}
