/**
 * Somnium – Estilos del plugin
 *
 * Hoja de estilos principal cargada en el frontend.
 * Añadir aquí todos los estilos personalizados del plugin.
 *
 * @package Somnium
 * @version 1.0.0
 */

.search-table .search-field input[type="text"],
.wp-block-search .wp-block-search__input,
.woocommerce-product-search .search-field {
    border-color: #000;
    color: #000;
}


.ts-banner .banner-wrapper {
    position: relative;
    overflow: hidden;
}

.ts-banner .background-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    z-index: 1;
}

.ts-banner .banner-bg {
    position: relative;
    z-index: 0;
}

.ts-banner .banner-bg img {
    display: block;
    width: 100%;
    height: auto;
}

.ts-banner .box-content {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.ts-banner .box-content h2,
.ts-banner .box-content .description,
.ts-banner .ts-banner-button .button {
    color: #fff;
}

.box-content h2 {
    max-width: inherit !important;
    width: 100%;
}

.box-content .content-text {
    max-width: inherit !important;
}


.ts-banner .banner-bg img {
    height: 350px;
    object-fit: cover;
}


.woocommerce .products .product-wrapper {
    padding: 20px !important;
    border: 1px solid #ccc;
    background: #fff;
    border-radius: 6px;
    box-shadow: 6px 6px 6px rgba(0, 0, 0, .12);
}


.product-label-v1.woocommerce .product .product-label,
.product-label-v1 .woocommerce .product .product-label {
    inset: 10px auto auto 10px !important;

}

:where(.cross-sells, .upsells, .related) .products.swiper .product,
.ts-product:not(.ts-product-categories).ts-slider .products.swiper .product {
    padding: 10px;
}


.product .product-brands a,
.products .product .product-categories a,
.woocommerce .products .product .product-categories a,
.widget-container ul li .product-categories a {
    text-decoration: none !important;
    color: var(--ts-primary-color) !important;
    font-weight: bold !important;
}

.product .product-brands a {
    font-size: 15px !important;
}

/* ───────────────────────────────────────────────
   Firmeza / Transpirabilidad (barras cuadradas)
   ─────────────────────────────────────────────── */
.somnium-firmeza-wrapper {
    display: flex;
    align-items: center;
    justify-content: left;
    gap: 8px;
    margin-top: 5px;
    margin-bottom: 5px;
}

.somnium-firmeza-dots {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    line-height: 0;
}

.somnium-firmeza-dots .dot {
    display: block;
    flex-shrink: 0;
    width: 10px;
    height: 14px;
    border-radius: 2px;
    background: #e0e0e0;
    box-sizing: border-box;
    transition: background .2s ease;
}

.somnium-firmeza-dots .dot.filled {
    background: #555;
}

/* Wrapper para firmeza + transpirabilidad en ficha */
.somnium-attributes-wrapper {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 14px 0;
}

.somnium-single-attr-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.somnium-single-attr-row strong {
    font-size: 13px;
    color: #333;
    white-space: nowrap;
    min-width: 115px;
}

/* Transpirabilidad: barras en azul para distinguir de firmeza */
.somnium-transp-dots .dot.filled {
    background: #1a8cba;
}

/* ───────────────────────────────────────────────
   Trust Badges (ficha de producto)
   ─────────────────────────────────────────────── */
.somnium-trust-badges {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    margin: 18px 0 6px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    overflow: hidden;
    background: #fafafa;
}

.somnium-trust-badge {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 14px 16px;
    border-right: 1px solid #e5e5e5;
    transition: background .2s ease;
}

.somnium-trust-badge:last-child {
    border-right: none;
}

.somnium-trust-badge:hover {
    background: #f0f0f0;
}

.somnium-trust-icon {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    color: #cc0000;
    margin-top: 2px;
}

.somnium-trust-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.somnium-trust-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.somnium-trust-text strong {
    font-size: 13px;
    font-weight: 700;
    color: #222;
    line-height: 1.3;
}

.somnium-trust-text span {
    font-size: 11.5px;
    color: #666;
    line-height: 1.4;
}

@media (max-width: 768px) {
    .somnium-trust-badges {
        grid-template-columns: 1fr;
    }

    .somnium-trust-badge {
        border-right: none;
        border-bottom: 1px solid #e5e5e5;
    }

    .somnium-trust-badge:last-child {
        border-bottom: none;
    }
}

/* Ocultar descripción y estrellas en el grid de ofertas */
.somnium-ofertas-grid .short-description,
.somnium-ofertas-grid .rating-wrapper,
.somnium-ofertas-grid .star-rating {
    display: none !important;
}

/* Grid de ofertas: productos centrados con ancho fijo */
.somnium-ofertas-grid ul.products {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
}

.somnium-ofertas-grid ul.products section.product {
    flex: 0 0 375px !important;
    width: 375px !important;
    max-width: 375px !important;
    float: none !important;
    margin: 10px !important;
}

@media (max-width: 767px) {
    .somnium-ofertas-grid ul.products section.product {
        flex: 0 0 100% !important;
        width: 100% !important;
        max-width: 100% !important;
    }
}

/* ═══════════════════════════════════════════
   Tiendas - Tarjetas (Slider y Grid)
   ═══════════════════════════════════════════ */

/* Card base */
.sts-card,
.somnium-tienda-card {
    background: #fff !important;
    border: 1px solid #eeeeee !important;
    border-radius: 8px;
    overflow: hidden;
    display: flex !important;
    flex-direction: column;
    height: 100%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .06);
    transition: transform .25s ease, box-shadow .25s ease;
    color: #0d0d0d !important;
}

.sts-card:hover,
.somnium-tienda-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, .12);
}

/* Image */
.sts-image-link {
    display: block;
    overflow: hidden;
}

.sts-image {
    width: 100%;
    overflow: hidden;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sts-image img,
.somnium-tienda-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .35s ease;
}

.sts-card:hover .sts-image img,
.somnium-tienda-card:hover .somnium-tienda-image img {
    transform: scale(1.04);
}

/* Body */
.sts-body,
.somnium-tienda-content {
    padding: 16px 18px 18px !important;
    display: flex !important;
    flex-direction: column;
    flex: 1;
}

/* Title */
.sts-title,
.somnium-tienda-title {
    margin: 0 0 10px !important;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.35;
    color: #0d0d0d !important;
}

.sts-title a,
.somnium-tienda-title a {
    color: #0d0d0d !important;
    text-decoration: none;
}

.sts-title a:hover,
.somnium-tienda-title a:hover {
    color: #cc0000 !important;
}

/* Meta */
.sts-meta,
.somnium-tienda-meta {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 14px;
    font-size: 13px;
    color: #555 !important;
    line-height: 1.5;
}

.sts-meta p {
    margin: 0;
}

.sts-meta a,
.somnium-tienda-meta a {
    color: #0d0d0d !important;
    text-decoration: none;
}

.sts-meta a:hover,
.somnium-tienda-meta a:hover {
    color: #cc0000 !important;
}

/* Font Awesome icons in tiendas cards */
.sts-icon,
.somnium-tienda-icon {
    color: #aaa;
    font-size: 13px;
    width: 16px;
    text-align: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.sts-meta p,
.somnium-tienda-address,
.somnium-tienda-phone {
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

/* Schedule */
.sts-schedule {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13px;
    color: #555;
}

.sts-schedule-rows {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sts-schedule-row {
    display: block;
}

/* Button */
.sts-btn {
    display: inline-block;
    align-self: flex-start;
    margin-top: auto;
    color: var(--ts-btn-border) !important;
    text-decoration: none;
    transition: background-color .2s, color .2s;
}

.sts-btn:visited {
    color: var(--ts-btn-border) !important;
}

.sts-btn:hover {
    color: #fff !important;
}

/* Splide arrows/dots */
.somnium-tiendas-slider-wrap {
    padding: 0 48px;
}

/* Make room for arrows outside cards */
.somnium-tiendas-slider-wrap .splide__arrow {
    background: #cc0000;
    opacity: 1;
    width: 36px;
    height: 36px;
}

.somnium-tiendas-slider-wrap .splide__arrow--prev {
    left: 0;
}

.somnium-tiendas-slider-wrap .splide__arrow--next {
    right: 0;
}

.somnium-tiendas-slider-wrap .splide__arrow svg {
    fill: #fff;
}

.somnium-tiendas-slider-wrap .splide__arrow:hover {
    background: #aa0000;
}

.somnium-tiendas-slider-wrap .splide__pagination__page.is-active {
    background: #cc0000;
}

@media (max-width: 768px) {

    .sts-title,
    .somnium-tienda-title {
        font-size: 15px;
    }

    .sts-body,
    .somnium-tienda-content {
        padding: 12px 14px 14px !important;
    }
}

/* ═══════════════════════════════════════════
   Google Stars Badge (tiendas cards)
   ═══════════════════════════════════════════ */
.somnium-stars-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin: 2px 0 8px 0;
    padding: 0;
    font-size: 13px;
    line-height: 1;
}

.somnium-stars-rating {
    font-weight: 700;
    color: #E8A100;
    font-size: 14px;
}

.somnium-stars-icons {
    display: inline-flex;
    align-items: center;
    gap: 0;
}

.somnium-star {
    font-size: 16px;
    line-height: 1;
}

.somnium-star--full {
    color: #FBBC04;
}

.somnium-star--half {
    color: #FBBC04;
    opacity: 0.55;
}

.somnium-star--empty {
    color: #DAD9D6;
}

.somnium-stars-total {
    color: #70757a;
    font-size: 12px;
    font-weight: 400;
    margin-left: 2px;
}

/* ═══════════════════════════════════════════
   Widget: Enlaces SEO Somnium
   ═══════════════════════════════════════════ */

/* Título del bloque */
.ssl-block-title {
    font-weight: 700;
    font-size: 1em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 12px;
    color: #222;
}

/* Título de grupo */
.ssl-group-title {
    font-weight: 600;
    font-size: 0.95em;
    color: #555;
    margin: 18px 0 6px;
    padding-bottom: 4px;
    border-bottom: 1px solid #eee;
}

.ssl-group-title:first-of-type {
    margin-top: 0;
}

/* Lista vertical */
.ssl-list {
    list-style: none !important;
    list-style-type: none !important;
    padding: 0 !important;
    margin: 0 0 8px !important;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* Eliminar puntos/viñetas con máxima especificidad */
.ssl-list li,
ul.ssl-list li,
.somnium-seo-links-wrap ul li,
.somnium-seo-links-wrap .ssl-list li {
    list-style: none !important;
    list-style-type: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.ssl-list li::before,
.ssl-list li::after,
ul.ssl-list li::before,
ul.ssl-list li::after {
    content: none !important;
    display: none !important;
}

.ssl-link {
    text-decoration: none;
    color: #333;
    font-size: 0.9em;
    transition: color .2s;
    display: inline-block;
    line-height: 1.8;
}

.ssl-link:hover {
    color: #cc0000;
}

/* Layout Columnas */
.ssl-cols-2 .ssl-list {
    columns: 2;
    display: block;
}

.ssl-cols-3 .ssl-list {
    columns: 3;
    display: block;
}

.ssl-cols-2 .ssl-list li,
.ssl-cols-3 .ssl-list li {
    break-inside: avoid;
}

/* Pills */
.ssl-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
}

.ssl-pill {
    display: inline-flex;
    align-items: center;
    padding: 6px 16px;
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
    border-radius: 50px;
    font-size: 0.88em;
    font-weight: 500;
    color: #333;
    transition: all .25s ease;
    text-decoration: none;
}

.ssl-pill:hover {
    background: #cc0000;
    border-color: #cc0000;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(204, 0, 0, .2);
}

@media (max-width: 767px) {

    .ssl-cols-2 .ssl-list,
    .ssl-cols-3 .ssl-list {
        columns: 1;
    }
}


ol li:last-child,
ul li:last-child {
    padding-bottom: inherit !important;
}

/* ═══════════════════════════════════════════
   Widget: Banner Slider (somnium_banner_slider)
   ═══════════════════════════════════════════ */

.sbs-wrap {
    width: 100%;
    position: relative;
    overflow: hidden;
}

/* Forzar que el li de Splide ocupe el alto del track */
.sbs-wrap .splide__slide {
    height: 100%;
}

/* Slide */
.sbs-slide {
    position: relative;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    overflow: hidden;
    height: 520px;  /* sobreescrito por Elementor selector si se configura */
}

/* Overlay */
.sbs-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
}

/* Frame: capa que ocupa todo el slide y posiciona el box */
.sbs-frame {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    padding: 40px 60px 40px 100px;
    box-sizing: border-box;
    align-items: center;
    /* vertical: top/center/bottom  → set inline */
    justify-content: center;
    /* horizontal: left/center/right → set inline */
}

/* Box: contenedor centrado de ancho limitado */
.sbs-box {
    max-width: 760px;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 14px;
    text-align: center;
    /* overridden per-slide inline */
    align-items: center;
    /* overridden per-slide inline */
}

/* Pre-title tag */
.sbs-tag {
    display: inline-block;
    padding: 4px 16px;
    border-radius: 50px;
    font-size: 0.72em;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    background-color: #cc0000;
    color: #fff;
}

/* Title */
.sbs-title {
    margin: 0;
    font-size: clamp(1.6rem, 4vw, 3rem);
    font-weight: 800;
    line-height: 1.2;
    color: #fff;
}

/* Subtitle */
.sbs-subtitle {
    margin: 0;
    font-size: clamp(0.9rem, 2vw, 1.15rem);
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.55;
}

/* CTA Button */
.sbs-btn {
    display: inline-block;
    padding: 12px 28px;
    background-color: #cc0000;
    color: #fff !important;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.95em;
    transition: background-color .25s ease, transform .2s ease;
    align-self: auto;
    /* respects .sbs-box align-items */
}

.sbs-btn:hover {
    background-color: #aa0000;
    transform: translateY(-2px);
    color: #fff !important;
}

/* ── Arrows ── */
.sbs-wrap .splide__arrow {
    background: rgba(0, 0, 0, 0.45);
    opacity: 1;
    width: 44px;
    height: 44px;
}

.sbs-wrap .splide__arrow svg {
    fill: #fff;
}

.sbs-wrap .splide__arrow:hover {
    background: #cc0000;
}

/* ── Pagination (dots) — reset de viñetas del tema ── */
.sbs-wrap .splide__pagination {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
    bottom: 16px;
}

.sbs-wrap .splide__pagination li {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 3px !important;
}

.sbs-wrap .splide__pagination li::before,
.sbs-wrap .splide__pagination li::after {
    content: none !important;
    display: none !important;
}

.sbs-wrap .splide__pagination__page {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.45);
    opacity: 1;
    transition: background .25s, transform .25s;
}

.sbs-wrap .splide__pagination__page.is-active {
    background: #fff;
    transform: scale(1.35);
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .sbs-frame {
        padding: 24px 20px;
    }

    .sbs-box {
        max-width: 100%;
    }
}