@import url("https://fonts.googleapis.com/css2?family=Inter:wght@900&display=swap");

/* ==========================================================================
   CATEGORY PAGE
   ========================================================================== */
   div#content-wrapper {
    flex-direction: column;
    display: flex;
   }

#category .block-category .page-title-section {
    font-size: var(--font-size-xl);
    font-family: "Inter", sans-serif;
    font-weight: 900 !important;
}

@media (max-width: 991px) {
    #category .block-category,
    #category .block-category .page-title-section {
        padding-left: 0;
        padding-right: 0;
        margin-left: 0;
        margin-right: 0;
    }
}
.layout-left-column .products-selections-filters {
    align-items: center;
    justify-content: end;
}

/* ==========================================================================
   CATEGORY TOOLBAR (HSN layout)
   ========================================================================== */
.weu-category-toolbar {
    margin-bottom: var(--weu-spacing-md);
}

.weu-category-toolbar__row--top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--weu-spacing-sm);
    margin-bottom: var(--weu-spacing-sm);
}

.weu-category-toolbar__count {
    font-size: var(--font-size-base);
    color: var(--weu-color-dark);
}

.weu-category-toolbar__count strong {
    font-weight: 700;
}

.weu-category-toolbar__sort {
    flex-shrink: 0;
}

.weu-category-sort {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.weu-category-sort__label {
    color: var(--weu-color-dark);
    font-size: var(--font-size-base);
    white-space: nowrap;
}

.weu-category-sort__btn {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--weu-border-color);
    border-radius: var(--weu-radius-default);
    background-color: var(--weu-white);
    color: var(--weu-color-dark);
    font-size: var(--font-size-base);
    line-height: 1.2;
}

.weu-category-sort__btn strong {
    font-weight: 700;
}

.weu-category-sort__btn .material-icons {
    font-size: 20px;
}

.weu-category-sort .weu-dropdown-menu {
    min-width: 100%;
}

#category .weu-category-toolbar .products-selection {
    margin-bottom: 0;
}

#category .weu-category-toolbar .select-title {
    width: auto;
    min-width: 180px;
    border-radius: var(--weu-radius-default);
    background-color: var(--weu-white);
    border: 1px solid var(--weu-border-color);
}

.facet-products-grid.row {
    display: flex;
    gap: var(--weu-spacing-md);
    width: 100%;
    margin-left: 0;
    margin-right: 0;
}

.layout-left-column #left-column {
    padding-right: 0 !important;
}

#category .facet-products-grid.row > #left-column,
#category .facet-products-grid.row > #content-wrapper {
    max-width: none;
}

@media (min-width: 768px) and (max-width: 991.98px) {
    #category .facet-products-grid.row {
        flex-wrap: nowrap;
    }

    #category .facet-products-grid.row > #left-column {
        flex: 0 0 260px;
        width: 260px;
        max-width: 260px;
    }

    #category .facet-products-grid.row > #content-wrapper {
        flex: 1 1 0;
        width: auto;
        min-width: 0;
    }
}

@media(min-width: 992px) {
    .facet-products-grid.row {
        display: flex;
        gap: var(--weu-spacing-md);
        flex-wrap: nowrap;
    }

    .layout-left-column #left-column,
    #category .facet-products-grid.row > #left-column {
        width: 300px;
        max-width: 300px;
        flex: 0 0 300px;
        flex-shrink: 0;
        flex-grow: 0;
    }

    body:not(#manufacturer) div#content-wrapper,
    #category .facet-products-grid.row > #content-wrapper {
        flex: 1 1 0;
        width: auto;
        min-width: 0;
        max-width: none;
    }
}
.rich-text .h2,
.rich-text h2 {
    font-size: var(--font-size-lg);
}

.rich-text .h3,
.rich-text h3 {
    font-size: var(--font-size-md);
}

.rich-text .h4,
.rich-text h4 {
    font-size: var(--font-size-base);
}

/* Enlaces en la descripción SEO de categoría (footer) */
#category #js-product-list-footer a {
    color: var(--weu-color-primary);
    font-weight: 600;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: opacity 0.2s ease;
}

#category #js-product-list-footer a:hover,
#category #js-product-list-footer a:focus-visible {
    color: var(--weu-color-primary);
    opacity: 0.85;
    text-decoration-thickness: 2px;
}

@media(max-width: 991px) {
    .facet-products-grid.row {
        flex-direction: column-reverse;
    }
}

/* ==========================================================================
   CATEGORY TREE
   ========================================================================== */
.ps_categorytree.category-tree.left-block {
    /* padding: 8px; */
    background: white;
    padding: 1.5rem;
    border-radius: .5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .1);
    margin: 0 0 var(--weu-spacing-lg) 0;
}

.ps_categorytree .left-block__title {
    padding: .25rem 0;
    margin-bottom: 0;
}

.category-tree__child .category-tree__list {
    row-gap: 0;
}

.ps_categorytree a {
    min-height: 32px;
    line-height: 1.5;
    display: block;
    border-bottom: 1px solid var(--weu-color-grey);
    width: 100%;
    display: flex;
    align-items: center;
    font-size: var(--font-size-base);
}

.ps_categorytree .left-block__title__link {
    text-transform: uppercase;
    font-weight: 600;
}

.ps_categorytree .category-tree__child .category-tree__item__link {
    text-transform: lowercase;
    font-weight: 400 !important;
    font-size: var(--font-size-base);
    display: block;
}

.ps_categorytree .category-tree__child .category-tree__item__link:hover {
    color: var(--weu-color-primary);
    transition: color .3s ease;
}

.ps_categorytree .category-tree__child .category-tree__item__link::first-letter {
    text-transform: uppercase;
}

/* ==========================================================================
   PRODUCTS
   ========================================================================== */

#products .total-products p {
    width: fit-content;
    display: inline-block;
    padding: .25rem 0;
}

.layout-left-column .products-selection .select-title {
    border-radius: var(--weu-radius-default);
    background-color: var(--weu-color-grey);
    width: 300px;
    border: none;
}

.products-sort-order .weu-dropdown-menu {
    min-width: 100%;
}

.pagination-container {
    flex-direction: column;
    margin-top: var(--weu-spacing-lg);
    margin-bottom: var(--weu-spacing-md);
}

.pagination--custom {
    margin-top: var(--weu-spacing-md);
    margin-bottom: var(--weu-spacing-md);
}

.page-link.disabled[rel="prev"] {
    display: none;
}

.disabled>.page-link,
.page-link.disabled {
    background-color: transparent;
}

.page-link.disabled {
    color: var(--weu-color-primary);
}

.page-link {
    border: none;
    color: #000;
    min-height: 36px;
}

.page-link:hover {
    background-color: transparent;
    border-color: transparent;
    color: var(--weu-color-primary);
}

.page-link:focus {
    box-shadow: none;
    background-color: transparent;
}

#js-product-list-footer {
    padding-top: var(--weu-spacing-lg);
    border-top: 1px solid var(--weu-color-grey);
}

@media(max-width: 767px) {

    .products-sort-order,
    .layout-left-column .products-selection .select-title {
        width: 100%;
    }

    .products-sort-order {
        margin-right: 0!important;
    }

    .total-products {
        text-align: center;
        margin-bottom: var(--weu-spacing-sm);
    }

    .pagination--custom .page-item:has(.next), .pagination--custom .page-item:has(.previous){
        position: unset;
    }
}

/* ==========================================================================
   SUBCATEGORIES SLIDER
   ========================================================================== */
.weu-subcategories-list {
    background-color: var(--weu-color-grey);
    padding: 10px 16px;
    margin-bottom: var(--weu-spacing-sm);
    border-radius: var(--weu-radius-default);
}

.weu-subcategories-list .splide__track {
    overflow: hidden;
    cursor: grab;
}

.weu-subcategories-list .splide__track:active {
    cursor: grabbing;
}

.weu-subcategories-list .splide__list {
    display: flex !important;
    flex-wrap: nowrap;
    align-items: center;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
}

.weu-subcategories-list .splide__slide,
.weu-subcategories-list__item {
    width: auto !important;
    flex-shrink: 0;
    margin: 0;
}

.weu-subcategories-list .subcategory {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    background-color: var(--weu-white);
    border: 1px solid var(--weu-border-color);
    border-radius: var(--weu-radius-default);
    transition: background-color 0.2s ease, border-color 0.2s ease;
    white-space: nowrap;
    text-decoration: none;
    color: var(--weu-color-dark);
}

.weu-subcategories-list .subcategory:hover {
    background-color: var(--weu-white);
    border-color: var(--weu-color-dark);
    color: var(--weu-color-black);
}

.weu-subcategories-list .subcategory__name {
    font-size: var(--font-size-base);
    font-weight: 500;
    text-transform: none;
    letter-spacing: normal;
    margin: 0;
}

.weu-subcategories-list .splide__arrows {
    display: none;
}

/* Evitar puntos de paginación de Splide (los "..."/dots) y FOUC durante la carga */
.weu-subcategories-list .splide__pagination {
    display: none !important;
}

.weu-subcategories-list:not(.is-initialized) .splide__track {
    overflow: hidden;
}

.weu-subcategories-list:not(.is-initialized) .splide__list {
    flex-wrap: nowrap;
}

@media (max-width: 767px) {
    .weu-category-toolbar__row--top {
        flex-direction: column;
        align-items: stretch;
    }

    .weu-category-toolbar__sort {
        width: 100%;
        justify-content: space-between;
    }

    .weu-category-sort {
        flex: 1 1 auto;
        justify-content: flex-end;
    }

    #category .weu-category-toolbar .select-title {
        width: 100%;
        min-width: 0;
    }
}

#search .container > .row {
    gap: var(--weu-spacing-md);
}


/********************************/
/*     MANUFACTURER PAGE     */
/********************************/
.brand-search {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    width: 100%;
    margin-bottom: var(--weu-spacing-md);
}

.brand-search__form {
    position: relative;
    width: 100%;
    max-width: 300px;
}

.brand-search__input {
    width: 100%;
    max-width: 300px;
    padding: 10px 36px 10px 15px;
    height: 45px;
    outline: none;
    background-color: var(--weu-white);
    border: 1px solid #ced4da !important;
    border-radius: var(--weu-radius-default);
    font-size: var(--font-size-sm);
    color: var(--weu-color-black);
}

.brand-search__input::placeholder {
    color: var(--weu-color-grey-dark);
}

.brand-search__submit {
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    padding: 0;
    border: none;
    background: transparent;
    color: var(--weu-color-black);
    cursor: pointer;
}

.brand-search__submit:hover,
.brand-search__submit:focus {
    color: var(--weu-color-primary);
}

.brand-search__icon {
    width: 24px;
    height: 24px;
    filter: none;
    background-size: auto 24px;
    mask-size: 24px;
    -webkit-mask-size: 24px;
    background-position: center;
    -webkit-mask-position: center;
    mask-position: center;
}

.brand-search__message {
    width: 100%;
    max-width: 200px;
    margin: var(--weu-spacing-xs) 0 0;
    font-size: var(--font-size-sm);
    color: var(--weu-color-primary);
    text-align: right;
}

.brand.card.is-search-target {
    scroll-margin-top: 120px;
    outline: 2px solid var(--weu-color-primary);
    outline-offset: 2px;
}

.brand__name {
    margin-bottom: var(--weu-spacing-sm);
}

.brand__name a {
    font-size: var(--font-size-md);
    font-weight: 600;
    text-decoration: none;
    color: var(--weu-color-black);
}

body#manufacturer ul.row {
    --brand-list-gap: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: var(--brand-list-gap);
    margin-left: 0;
    margin-right: 0;
    padding-left: 0;
    list-style: none;
}

body#manufacturer .brand.card {
    text-align: center;
    flex: 0 0 calc((100% - var(--brand-list-gap)) / 2);
    width: calc((100% - var(--brand-list-gap)) / 2);
    max-width: calc((100% - var(--brand-list-gap)) / 2);
}

@media (min-width: 768px) {
    body#manufacturer .brand.card {
        flex: 0 0 calc((100% - (2 * var(--brand-list-gap))) / 3);
        width: calc((100% - (2 * var(--brand-list-gap))) / 3);
        max-width: calc((100% - (2 * var(--brand-list-gap))) / 3);
    }
}

@media (min-width: 992px) {
    body#manufacturer ul.row {
        --brand-list-gap: 24px;
    }

    body#manufacturer .brand.card {
        flex: 0 0 calc((100% - (3 * var(--brand-list-gap))) / 4);
        width: calc((100% - (3 * var(--brand-list-gap))) / 4);
        max-width: calc((100% - (3 * var(--brand-list-gap))) / 4);
    }
}

.brand__products a {
    display: block;
    border: none;
    border-top: 1px solid #ddd;
    border-radius: 0;
}

/********************************/
/*     BRAND MINIATURE          */
/********************************/

body#manufacturer .page-title-section {
    text-align: center;
    margin-bottom: var(--weu-spacing-sm);
}

.manufacturer-subtitle {
    border-bottom: 1px solid var(--weu-border-color);
    margin-bottom: 64px;
}

.manufacturer-subtitle p {
    margin-bottom: var(--weu-spacing-md);
    text-align: center;
}

.brand.card {
    background-color: var(--weu-color-grey);
    border: 0;
    padding: var(--weu-spacing-md);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--weu-spacing-sm);
    text-align: center;
}

.brand__img a {
    display: block;
}

.brand__img img {
    max-width: 100%;
    height: auto;
    mix-blend-mode: multiply;
    filter: contrast(1.1);
}

.brand__infos {
    flex: 1;
    width: 100%;
}

.brand__name {
    margin-bottom: var(--weu-spacing-xs);
}

.brand__link {
    font-weight: 600;
    text-decoration: none;
    color: var(--weu-color-black);
}

.brand__link:hover {
    color: var(--weu-color-primary);
}

.brand__description {
    margin: 0;
    font-size: var(--font-size-sm);
    color: var(--weu-color-grey-dark);
    line-height: 1.5;
}

.brand__description-text {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    text-overflow: ellipsis;
    word-break: break-word;
}

.brand__description-more {
    display: none;
    font-size: inherit;
    font-weight: inherit;
    color: inherit;
    line-height: inherit;
    text-decoration: none;
    white-space: nowrap;
}

a.brand__description-more.is-visible {
    margin-top: 8px;
    display: block;
}

.brand__description-more.is-visible {
    display: inline;
}

.brand__description-more::before {
    content: '\00a0';
}

.brand__description-more:hover,
.brand__description-more:focus {
    color: var(--weu-color-primary);
    text-decoration: underline;
}

.brand__products {
    margin-top: auto;
    width: 100%;
}

.brand__btn {
    display: inline-block;
    padding: var(--weu-spacing-xs) var(--weu-spacing-md);
    font-size: var(--font-size-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--weu-color-black);
    background-color: transparent;
    border: 1px solid var(--weu-color-black);
    border-radius: var(--weu-radius-default);
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.brand__btn:hover,
.brand__btn:focus {
    background-color: var(--weu-color-black);
    border-color: var(--weu-color-black);
    color: var(--weu-white);
}

@media (max-width: 767px) {
    .brand.card {
        padding-left: var(--weu-spacing-sm);
        padding-right: var(--weu-spacing-sm);
    }

    .brand-search__form {
        max-width: none;
    }
    
    .brand-search__input {
        max-width: none;
    }
}