/* Homepage styles — merged for single HTTP request */

/* --- home-banner.css --- */
/**
 * Homepage hero banner — full-bleed image, content aligned to container (96rem)
 */

.home-banner-slider {
    --bb-banner-accent: #eb7d1e;
    --bb-banner-accent-hover: #c96a18;
    --bb-banner-text: #ffffff;
    --bb-banner-cta-text: #333333;

    width: 100vw;
    max-width: 100vw;
    margin-inline: calc(50% - 50vw);
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.home-banner-slider__slide {
    position: relative;
    width: 100%;
    min-height: clamp(320px, 40vw, 500px);
}

.home-banner-slider__media {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: block;
    width: 100%;
    height: 100%;
    line-height: 0;
}

.home-banner-slider__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.home-banner-slider__content {
    position: absolute;
    z-index: 1;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    width: 100%;
    color: var(--bb-banner-text);
    pointer-events: none;
}

.home-banner-slider__container {
    pointer-events: auto;
    width: 100%;
    margin-inline: auto;

    box-sizing: border-box;
}

.home-banner-slider__inner {
    max-width: 36rem;
    /* padding-inline: 0.5rem; */
}

.home-banner-slider__title {
    margin: 0 0 0.75rem;
    font-size: clamp(1.5rem, 4vw, 3.125rem);
    font-weight: 700;
    line-height: 1.15;
}

.home-banner-slider__text {
    margin: 0 0 1rem;
    font-size: clamp(0.875rem, 1.5vw, 1.125rem);
    line-height: 1.5;
}

.home-banner-slider__cta {
    display: inline-block;
    margin-top: 0.5rem;
    padding: 0.625rem 1.875rem;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.25;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--bb-banner-text);
    background: var(--bb-banner-accent);
    border-radius: 2px;
}

.home-banner-slider__cta:focus-visible {
    outline: 2px solid var(--bb-banner-text);
    outline-offset: 2px;
}

@media (max-width: 576px) {
    .home-banner-slider__slide {
        min-height: clamp(340px, 65vw, 360px);
    }

    .home-banner-slider__inner {
        max-width: none;
    }
}

/* --- home-features.css --- */
/**
 * Homepage feature bar — overlaps hero banner by 40px
 */

.home-features {
    --bb-features-accent: #eb7d1e;
    --bb-features-overlap: 40px;
    --bb-features-container-max: 96rem;

    position: relative;
    z-index: 2;
    margin-top: calc(-1 * var(--bb-features-overlap));
    padding-bottom: 3.5rem;
}

.home-features__container {
    width: 100%;
    max-width: var(--bb-features-container-max);
    margin-inline: auto;
    padding-inline: 0;
    box-sizing: border-box;
}

.home-features__grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
}

.home-features__item {
    margin: 0;
    padding: 0;
}

.home-features__card {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    height: 100%;
    padding: 1rem 1.125rem;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgb(15 23 42 / 0.1);
}

.home-features__icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
}

.home-features__icon img,
.home-features__icon svg {
    display: block;
    width: 100%;
    height: auto;
    max-height: 3rem;
    object-fit: contain;
}

.home-features__icon svg {
    max-width: 3rem;
}

.home-features__body {
    min-width: 0;
}

.home-features__title {
    margin: 0 0 0.25rem;
    font-size: 0.9375rem;
    font-weight: 700;
    line-height: 1.3;
    color: #1f2937;
}

.home-features__text {
    margin: 0;
    font-size: 0.8125rem;
    line-height: 1.45;
    color: #6b7280;
}

@media (max-width: 991px) {
    .home-features__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 576px) {
    .home-features {
        --bb-features-overlap: 24px;
    }

    .home-features__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.75rem;
    }

    .home-features__card {
        padding: 0.875rem 1rem;
        flex-direction: column;
        align-items: flex-start;
    }


    .home-features__title {
        font-size: 0.875rem;
    }

    .home-features__text {
        font-size: 0.75rem;
    }
}

/* --- home-product-tabs.css --- */
/**
 * Homepage — Featured product tabs (hot categories / brands)
 */

.home-product-tabs {
    --bb-tabs-accent: #eb7d1e;
    --bb-tabs-container-max: 96rem;
    padding: clamp(2rem, 4vw, 3rem) 0;
    background: #f9fafb;
}

.home-product-tabs__container {
    width: 100%;
    max-width: var(--bb-tabs-container-max);
    margin-inline: auto;
    padding-inline: 0;
    box-sizing: border-box;
}

.home-product-tabs__header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.home-product-tabs__title {
    margin: 0 0 0.5rem;
    font-size: clamp(1.375rem, 2.5vw, 1.75rem);
    font-weight: 700;
    line-height: 1.2;
    color: #1f2937;
}

.home-product-tabs__intro {
    margin: 0;
    font-size: 0.9375rem;
    line-height: 1.6;
    color: #6b7280;
}

.home-product-tabs__nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1.75rem;
    padding-bottom: 0.25rem;
    border-bottom: 1px solid #e5e7eb;
}

.home-product-tabs__tab {
    appearance: none;
    margin: 0;
    padding: 0.625rem 1.125rem;
    font: inherit;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.25;
    color: #4b5563;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    cursor: pointer;
}

.home-product-tabs__tab.is-active {
    color: var(--bb-tabs-accent);
    border-bottom-color: var(--bb-tabs-accent);
}

.home-product-tabs__panels {
    min-height: 12rem;
}

.home-product-tabs__loading,
.home-product-tabs__empty {
    margin: 0;
    padding: 2rem 1rem;
    text-align: center;
    font-size: 0.9375rem;
    color: #6b7280;
}

.home-product-tabs__panel[aria-hidden="true"] {
    display: none;
}

.home-product-tabs__grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1.25rem;
}

@media (max-width: 1300px) {
    .home-product-tabs__grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .home-product-tabs__nav {
        justify-content: flex-start;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        padding-bottom: 0.75rem;
    }

    .home-product-tabs__tab {
        flex-shrink: 0;
    }
}
@media (max-width: 991px) {
    .home-product-tabs__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .home-product-tabs__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1rem;
    }
}
@media (max-width: 480px) {
    .home-product-tabs__grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

/* Defer paint for below-fold product cards — scoped per column count */
.home-product-tabs__item {
    content-visibility: visible;
}

@media (min-width: 1024px) and (max-width: 1279px) {
    .home-product-tabs__item:nth-child(n + 4) {
        content-visibility: auto;
        contain-intrinsic-size: auto 22rem;
    }
}

@media (min-width: 1280px) {
    .home-product-tabs__item:nth-child(n + 6) {
        content-visibility: auto;
        contain-intrinsic-size: auto 22rem;
    }
}

@media (min-width: 640px) and (max-width: 1023px) {
    .home-product-tabs__item:nth-child(n + 3) {
        content-visibility: auto;
        contain-intrinsic-size: auto 22rem;
    }
}

/* --- product-card.css --- */
/**
 * BulkDevices product card - shared across homepage, sliders, and catalog lists.
 */

.bb-product-card,
.home-product-tabs__card {
    --bb-card-accent: #eb7d1e;
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
}

.bb-product-card__media,
.home-product-tabs__media {
    display: block;
    width: 100%;
    max-width: 100%;
    flex: 0 0 auto;
    align-self: stretch;
    min-height: 0;
    padding: 0;
    overflow: hidden;
    background: #ffffff;
    box-sizing: border-box;
    text-decoration: none;
    color: inherit;
}

/* Square frame lives outside flex item padding quirks (iOS WebKit safe). */
.bb-product-card__media-frame {
    display: block;
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #ffffff;
}

.bb-product-card__media-frame::before {
    content: "";
    display: block;
    width: 100%;
    padding-bottom: 100%;
}

.bb-product-card__img,
.home-product-tabs__img {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    right: auto !important;
    bottom: auto !important;
    width: auto !important;
    height: auto !important;
    max-width: calc(100% - 2rem) !important;
    max-height: calc(100% - 2rem) !important;
    margin: 0 !important;
    transform: translate(-50%, -50%);
    object-fit: contain !important;
    object-position: center;
    display: block !important;
}

.bb-product-card__body,
.home-product-tabs__body {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 0.5rem;
    padding: 1rem 1rem 1.125rem;
}

.bb-product-card__name,
.home-product-tabs__name {
    margin: 0;
    font-size: 0.9375rem;
    font-weight: 700;
    line-height: 1.3;
}

.bb-product-card__name a,
.home-product-tabs__name a {
    color: #1f2937;
    text-decoration: none;
}

.bb-product-card__desc,
.home-product-tabs__desc {
    margin: 0;
    flex: 1;
    font-size: 0.8125rem;
    line-height: 1.5;
    color: #6b7280;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.bb-product-card__price,
.home-product-tabs__price {
    margin: 0;
    font-size: 1.0625rem;
    font-weight: 700;
    color: #1f2937;
    text-align: center;
}

.bb-product-card__price-label,
.home-product-tabs__price-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: #9ca3af;
    margin-right: 0.25rem;
}

.bb-product-card__atc-form {
    margin: 0;
    margin-top: 0.25rem;
}

.bb-product-card__actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
    margin-top: 0.25rem;
}

.bb-product-card__qty-selector {
    display: inline-flex;
    align-items: stretch;
    align-self: center;
    width: auto;
    max-width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    overflow: hidden;
    background: #ffffff;
    box-sizing: border-box;
}

.bb-product-card__qty-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 2.25rem;
    width: 2.25rem;
    min-height: 2.25rem;
    margin: 0;
    padding: 0;
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1;
    color: #1f2937;
    background: #f9fafb;
    border: none;
    cursor: pointer;
    appearance: none;
}

.bb-product-card__qty-btn--decrement {
    border-right: 1px solid #d1d5db;
}

.bb-product-card__qty-btn--increment {
    border-left: 1px solid #d1d5db;
}

.bb-product-card__qty-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.bb-product-card__qty {
    flex: 0 0 2.75rem;
    width: 2.75rem;
    min-width: 2.75rem;
    margin: 0;
    padding: 0.375rem 0.25rem;
    font-size: 0.9375rem;
    font-weight: 600;
    line-height: 1.25;
    text-align: center;
    color: #1f2937;
    background: #ffffff;
    border: none;
    border-radius: 0;
    box-shadow: none;
    outline: none;
    box-sizing: border-box;
    appearance: textfield;
}

.bb-product-card__qty::-webkit-outer-spin-button,
.bb-product-card__qty::-webkit-inner-spin-button {
    margin: 0;
    appearance: none;
}

.bb-product-card__cta,
.home-product-tabs__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: 0.25rem;
    padding: 0.625rem 0.875rem;
    min-height: 2.5rem;
    font-size: 0.8125rem;
    font-weight: 600;
    font-family: inherit;
    line-height: 1.25;
    color: #ffffff !important;
    background: var(--bb-card-accent) !important;
    border: none;
    border-radius: 4px;
    text-decoration: none;
    cursor: pointer;
    box-sizing: border-box;
    appearance: none;
}

.bb-product-card__actions .bb-product-card__cta,
.bb-product-card__actions .home-product-tabs__cta {
    margin-top: 0;
}

.bb-product-card__atc-form .bb-product-card__cta,
.bb-product-card__atc-form .home-product-tabs__cta {
    margin-top: 0;
}

.bb-product-grid__item,
.home-product-tabs__item {
    margin: 0;
    padding: 0;
    list-style: none;
}

/* Shopper Approved rotating widget — override Hyvä svg { display: block } */
#SA_wrapper_default.SA__wrapper .SA__more_review {
    text-align: right !important;
    padding: 10px 50px 0 0 !important;
}

#SA_wrapper_default.SA__wrapper .SA__more_review a,
#SA_wrapper_default.SA__wrapper .SA__more_review .sa-bottom-logo,
#SA_wrapper_default.SA__wrapper .SA__more_review .sa-bottom-arrow {
    display: inline !important;
    vertical-align: middle !important;
}

#SA_wrapper_default.SA__wrapper .SA__more_review svg {
    display: inline !important;
    vertical-align: middle !important;
    width: auto !important;
    max-width: 25px !important;
    height: auto !important;
}

