/* Rediseño 2026: lo que las maquetas llevaban en un <style> embebido, más los widgets que
   el tema no cubre. Se carga después de swiper-bundle.min.css. */

/* --- Slider del hero --- */

.slider {
    position: relative;
    overflow: hidden;
    -webkit-box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.slider .swiper-wrapper {
    width: 100%;
}

.slider .swiper-slide {
    position: relative;
}

.slider .swiper-slide img {
    width: 100%;
    flex-shrink: 0;
    object-fit: cover;
}

/* Pisan el tamaño por defecto de h1/h2 */
.offline-heading-large {
    font-size: 24px;
    font-weight: 600;
}

.offline-heading-medium {
    font-size: 20px;
    font-weight: 600;
}

/* --- Flechas --- */

.arrow {
    position: absolute;
    top: 50%;
    -webkit-transform: translateY(-50%);
    transform: translateY(-50%);
    background: transparent;
    color: #fff;
    border: none;
    cursor: pointer;
    border-radius: 50%;
    width: 33px;
    height: 33px;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-transition: background 0.3s ease;
    transition: background 0.3s ease;
    z-index: 10;
}

.arrow:hover {
    background: rgba(0, 0, 0, 0.8);
}

/* Chevrons tipográficos en lugar del icono propio de Swiper */
.slider .swiper-button-prev::after,
.slider .swiper-button-next::after {
    font-size: 50px;
    color: #fff;
    height: 28px;
    width: 14px;
}

.slider .swiper-button-prev::after {
    content: '\2039';
}

.slider .swiper-button-next::after {
    content: '\203A';
}

.swiper-navigation-icon {
    display: none;
}

/* Neutraliza el margin-top negativo de Swiper para centrar de verdad */
.swiper-button-prev,
.swiper-button-next {
    top: 50% !important;
    margin-top: 0 !important;
    -webkit-transform: translateY(-50%) !important;
    transform: translateY(-50%) !important;
}

.swiper-button-prev {
    left: 16px !important;
}

.swiper-button-next {
    right: 16px !important;
}

/* --- Bullets --- */

.slider .swiper-pagination {
    position: absolute;
    bottom: 20px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.slider .swiper-pagination-bullet {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.6);
    opacity: 1;
    border-radius: 50%;
    -webkit-transition: background 0.3s ease;
    transition: background 0.3s ease;
}

.slider .swiper-pagination-bullet-active {
    background: #fff;
}

/* --- Responsive: el banner va a sangre completa, pero las flechas se alinean
   con el borde del .container de cada breakpoint de Bootstrap 3 --- */

@media (max-width: 425px) {

    .swiper-button-prev,
    .swiper-button-next {
        top: 48% !important;
    }
}

@media (min-width: 768px) {
    .swiper-button-prev {
        left: max(16px, calc((100vw - 750px) / 2 + 16px)) !important;
    }

    .swiper-button-next {
        right: max(16px, calc((100vw - 750px) / 2 + 16px)) !important;
    }
}

@media (min-width: 992px) {
    .swiper-button-prev {
        left: max(16px, calc((100vw - 970px) / 2 + 16px)) !important;
    }

    .swiper-button-next {
        right: max(16px, calc((100vw - 970px) / 2 + 16px)) !important;
    }

    .widget {
        text-align: start;
    }
}

@media (min-width: 1200px) {
    .swiper-button-prev {
        left: max(16px, calc((100vw - 1170px) / 2 + 16px)) !important;
    }

    .swiper-button-next {
        right: max(16px, calc((100vw - 1170px) / 2 + 16px)) !important;
    }
}

@media (min-width: 1280px) {
    .swiper-button-prev {
        left: max(16px, calc((100vw - 1200px) / 2 + 16px)) !important;
    }

    .swiper-button-next {
        right: max(16px, calc((100vw - 1200px) / 2 + 16px)) !important;
    }
}

/* --- select2 alineado con los inputs del tema ---
   El tema solo estiliza select[class="normal"], que deja de aplicar en cuanto select2 sustituye
   el <select> nativo por su propio marcado. */

.select2-container--default .select2-selection--single {
    height: 40px;
    border: 1px solid #e8e8e8;
    border-radius: 30px;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 38px;
    padding-left: 15px;
    color: #1D1D1B;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 38px;
    right: 8px;
}

/* ------------------------------------------------------------
   Grilla de beneficios (views/beneficios.html: ul#gridBeneficios.product-list-grid2).
   Mismo problema que .shop-grid: Bootstrap 3 flota las columnas, y una tarjeta más alta
   —basta con que el texto del descuento ocupe dos líneas— engancha a la siguiente y deja
   el hueco en blanco. Con flex-wrap cada fila arranca en el borde izquierdo.
   ------------------------------------------------------------ */
.product-list-grid2 {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
    -webkit-box-align: stretch;
    -ms-flex-align: stretch;
    align-items: stretch;
}

/* La tarjeta hereda el alto de la fila y todos los bordes inferiores quedan alineados */
.product-list-grid2 > .product-item {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
}

.product-list-grid2 > .product-item > .product-inner {
    -webkit-box-flex: 1;
    -ms-flex: 1 1 auto;
    flex: 1 1 auto;
}

/* El estado vacío no es una tarjeta: como ítem flex se quedaría sin ancho */
.product-list-grid2 > .mozaic-banners-wrapper {
    -ms-flex: 0 0 100%;
    flex: 0 0 100%;
    max-width: 100%;
}

/* col-sm-3 no define ancho bajo 768px: sin esto las tarjetas dejarían de apilarse */
@media (max-width: 767px) {
    .product-list-grid2 > .product-item {
        -ms-flex: 0 0 100%;
        flex: 0 0 100%;
        max-width: 100%;
    }
}

/* ------------------------------------------------------------
   Popup de producto y de favorito agregado (fragments-producto, fragments-wishlist)
   ------------------------------------------------------------ */

.popup-agregado .modal-header {
    padding: 25px 40px;
}

.popup-agregado .modal-body {
    padding: 30px 40px 40px;
}

/* inline-block: .close va después en el marcado y flotado a la derecha caería bajo un h4 en bloque */
.popup-agregado-titulo,
.popup-cupon-titulo {
    display: inline-block;
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.3;
    color: #222;
}

.popup-agregado-titulo .fa,
.popup-cupon-titulo .icon {
    margin-right: 10px;
    font-size: 26px;
    vertical-align: middle;
}

.popup-agregado .close,
.popup-cupon .close {
    margin-top: 3px;
    font-size: 26px;
    font-weight: 400;
    color: #c8c8c8;
    opacity: 1;
    filter: alpha(opacity=100);
}

.popup-agregado-item {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    padding-bottom: 30px;
    border-bottom: 1px solid #e5e5e5;
}

/* Ancho fijo: ancla la insignia aunque la imagen no haya cargado */
.popup-agregado-thumb {
    position: relative;
    -ms-flex: 0 0 120px;
    flex: 0 0 120px;
    width: 120px;
    margin-right: 30px;
}

.popup-agregado-thumb img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.popup-agregado-cantidad {
    position: absolute;
    top: -12px;
    right: -12px;
    min-width: 32px;
    height: 32px;
    padding: 0 6px;
    border-radius: 16px;
    background-color: #d20a11;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    line-height: 32px;
    text-align: center;
}

.popup-agregado-info {
    -ms-flex: 1 1 auto;
    flex: 1 1 auto;
    min-width: 0;
}

.popup-agregado-info p {
    margin: 0 0 4px;
}

.popup-agregado-marca {
    color: #8c8c8c;
    font-size: 13px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.popup-agregado-nombre {
    color: #222;
    font-size: 15px;
    font-weight: 600;
}

.popup-agregado-millas {
    color: #222;
    font-size: 18px;
    font-weight: 600;
}

.popup-agregado-subtotal {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    margin: 30px 0 0;
    color: #222;
    font-size: 18px;
    font-weight: 600;
}

/* Porcentaje y no space-between: el importe arranca a media caja, no en el borde derecho */
.popup-agregado-subtotal > span:first-child {
    -ms-flex: 0 0 52%;
    flex: 0 0 52%;
}

/* El hueco va aquí y no bajo el sub-total: el popup de favoritos no tiene esa fila */
.popup-agregado-acciones {
    margin-top: 35px;
    text-align: center;
}

.popup-agregado-acciones .button {
    min-width: 300px;
    padding: 16px 30px;
    font-size: 14px;
}

.popup-agregado-seguir {
    margin: 20px 0 0;
    font-size: 15px;
    color: #222;
}

.popup-agregado-seguir a {
    color: #222;
    text-decoration: underline;
    cursor: pointer;
}

@media (max-width: 480px) {
    .popup-agregado .modal-header {
        padding: 20px;
    }

    .popup-agregado .modal-body {
        padding: 20px 20px 30px;
    }

    .popup-agregado-thumb {
        -ms-flex: 0 0 90px;
        flex: 0 0 90px;
        width: 90px;
        margin-right: 20px;
    }

    .popup-agregado-acciones .button {
        min-width: 0;
        width: 100%;
    }
}

/* ------------------------------------------------------------
   Popup de generar cupón (views/beneficios-detalle)
   ------------------------------------------------------------ */

.popup-cupon .modal-header {
    padding: 20px 40px;
}

.popup-cupon .modal-body {
    padding: 30px 40px 40px;
}

.popup-cupon-gracias {
    margin-bottom: 15px;
}

.popup-cupon-cancelar {
    margin: 25px 0 0;
    font-size: 15px;
    color: #222;
}

.popup-cupon-cancelar a {
    color: #222;
    text-decoration: underline;
    cursor: pointer;
}

@media (max-width: 480px) {
    .popup-cupon .modal-header {
        padding: 20px;
    }

    .popup-cupon .modal-body {
        padding: 25px 20px 30px;
    }
}

/* Pisa el azul #2980b9 que style.css arrastra del tema. No se edita allí: ese archivo es copia
   literal del de la maqueta y se perdería al resincronizarlo. */
.style-10 {
    background-color: #D20A11;
}

/* ------------------------------------------------------------
   Filas de producto de tipo .traditional-cart-entry. El tema no define ninguna regla para esa
   clase ni para sus .title/.code, así que marca y nombre salían los dos con el tamaño y el
   color por defecto del body.
   ------------------------------------------------------------ */

.traditional-cart-entry .item-marca {
    color: #8c8c8c;
    font-size: 13px;
    line-height: 1.4;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* Bloque: el ancla es inline y el margen superior no le aplicaría */
.traditional-cart-entry .title {
    display: block;
    margin-top: 4px;
    color: #1D1D1B;
    font-size: 16px;
}

/* Sin esto los dos precios se ven como dos cifras sueltas: no hay un solo line-through en style.css */
.price-normal {
    text-decoration: line-through;
}

/* ------------------------------------------------------------
   Carrito flotante del header (fragments-carrito :: carritoPopupTemplate)
   ------------------------------------------------------------ */

.show-shopping-cart .title {
    font-size: 15px;
    font-weight: 600;
    color: #222;
    padding-bottom: 20px;
}

.show-shopping-cart .list-product .product-name {
    margin: 0;
    padding-right: 25px;
    font-size: 13px;
    font-weight: 600;
}

/* El tema no define .price dentro del popup: sin esto la línea de millas sale con el cuerpo por defecto */
.show-shopping-cart .list-product .price {
    display: block;
    margin-top: 12px;
    color: #222;
    font-size: 19px;
    font-weight: 600;
}

.show-shopping-cart .remove-item .fa {
    font-size: 17px;
}

.mini-cart .sub-total {
    padding: 20px 0 25px;
    color: #222;
    font-size: 17px;
}

.mini-cart .group-button .button-secundario,
.mini-cart .group-button .button-secundario:hover {
    background-color: #e5e5e5;
    color: #1D1D1B;
}

/* ------------------------------------------------------------
   Contador de cantidad: detalle de producto y carrito
   ------------------------------------------------------------ */

.qty-counter {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
}

.qty-counter .qty-down,
.qty-counter .qty-up {
    color: #1D1D1B;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.qty-counter .qty-val {
    min-width: 105px;
    margin: 0 20px;
    padding: 10px 15px;
    border: 1px solid #d8d8d8;
    border-radius: 30px;
    color: #1D1D1B;
    font-size: 18px;
    text-align: center;
}

/* .product-details-right .quantity (style.css) gana por especificidad a .qty-counter: display
   se repite aquí, y float y padding-right sobran en flex y descolocan el botón de abajo */
.product-details-right .qty-counter {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    float: none;
    padding: 0;
    margin: 25px 0 5px;
}

/* El text-align de la celda no lo centra: es un bloque flex que ocupa todo el ancho */
.shop_table.cart .qty-counter {
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
}

/* ------------------------------------------------------------
   Detalle de producto: canje y favorito
   ------------------------------------------------------------ */

/* Sólo el producto regular: los demás tipos usan .style-10 y en Primax el botón comparte fila
   con "Descargar detalle", que no cabría al lado de uno de 300px */
.product-details-right .button-add-cart {
    min-width: 300px;
}

@media (max-width: 480px) {
    .product-details-right .button-add-cart {
        min-width: 0;
        width: 100%;
    }
}

.product-details-right .detalle-acciones {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    margin: 20px -5px 0;
}

/* El aire va en el margen de cada hijo y no en flex-gap, que Safari sólo soporta desde la 14.1;
   el negativo del contenedor cancela el de los extremos. De paso pisa el margin-top propio de
   .button-add-cart y .favorito, que en la fila desalinea a los hermanos. */
.product-details-right .detalle-acciones > * {
    margin: 0 5px 10px;
}

/* Se estira en vez de llevar alto fijo: el botón de canje mide 56px en el producto regular y 42px
   en los demás tipos, que usan .style-10. El min-height es para cuando cae solo a otra línea. */
.product-details-right .detalle-acciones .favorito {
    -webkit-box-flex: 0;
    -ms-flex: 0 0 auto;
    flex: 0 0 auto;
    -ms-flex-item-align: stretch;
    align-self: stretch;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    width: 56px;
    min-height: 44px;
    padding: 0;
    border: 1px solid #d8d8d8;
    border-radius: 10px;
    font-size: 20px;
}

.product-details-right .detalle-acciones .favorito:hover {
    border-color: #1D1D1B;
}
