/* Узкие по высоте экраны — избегаем наложения на хедер */
@media (max-height: 900px) and (min-width: 1001px) {
    .product-hero-section {
        min-height: 85vh;
		margin-bottom: 50px;
    }

    .product-hero-slider-wrap {
        min-height: 85vh !important;
        max-height: 85vh !important;
    }

    .product-gallery {
        min-height: 85vh !important;
        max-height: 85vh !important;
    }

    .product-hero-info {
        width: 45% !important;
        min-height: 80vh !important;
    }

    .product-hero-info > div {
        max-width: 420px;
    }
}

.logged-in-as {
	display: none;
}

#w22-purchase-panel .variation-option.is-active,
#w22-purchase-panel .subscription-option.is-active {
	opacity: 1;
	font-weight: 700;
}

.w22-purchase-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
	align-items: center;
	justify-items: center;
	column-gap: 0.75rem;
	row-gap: 0.35rem;
	width: 100%;
	max-width: 16rem;
	margin-left: auto;
	margin-right: auto;
}

.w22-purchase-grid > .variation-option,
.w22-purchase-grid > .subscription-option {
	width: 100%;
	padding: 0.125rem 0.25rem;
	text-align: center;
	white-space: nowrap;
}

.w22-purchase-sep {
	color: #9ca3af;
	line-height: 1;
	user-select: none;
}

.w22-purchase-divider {
	grid-column: 1 / -1;
	border-top: 1px solid #d1d5db;
	width: 80%;
	margin: 0.65rem auto;
}
@media (max-height: 768px) and (min-width: 1001px) {
    .product-hero-section {
        min-height: 90vh;

    }

    .product-hero-slider-wrap {
        min-height: 90vh !important;
        max-height: 90vh !important;
    }

    .product-gallery {
        min-height: 90vh !important;
        max-height: 90vh !important;
    }

    .product-hero-info {
        margin-top: 100px;
        width: 50% !important;
        min-height: auto !important;
    }

    .product-hero-info > div {
        max-width: 460px;
        padding-top: 1.5rem;
        padding-bottom: 1.5rem;
    }
}

	/* <= 1000px */
    @media (max-width: 1000px) {


        .product-hero-section.flex {
            flex-direction: column !important;
        }
    
        .product-hero-slider-wrap {
            min-width: 100vw !important;
            max-width: 100vw !important;
            width: 100vw !important;
            min-height: 50vh !important;
            max-height: 50vh !important;
            height: 50vh !important;
        }
    
        .product-gallery {
            width: 100% !important;
            min-width: 100vw !important;
            min-height: 50vh !important;
            max-height: 50vh !important;
        }
    
        .product-gallery .swiper-slide {
            height: auto !important;
        }
    
        .product-gallery img {
            width: 100%;
            height: 100% !important;
            object-fit: cover;
        }
    
        section.flex > div:last-child {
            width: 100% !important;
            min-height: auto !important;
        }
    }
    
    @media (max-width: 600px) {
        .product-hero-slider-wrap {
            min-height: 40vh !important;
            max-height: 40vh !important;
            height: 40vh !important;
        }
        .product-gallery {
            min-height: 40vh !important;
            max-height: 40vh !important;
        }
    }

.yith-wcwl-add-to-wishlist-button__label {
        display: none;
    }

/* Produktinformationen: «?» + popover (desktop hover / mobile tap + backdrop) */
.product-pi-legal .pi-hint-anchor {
    position: relative;
    vertical-align: baseline;
}

.product-pi-legal .pi-hint-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9980;
    background: rgba(15, 23, 42, 0.45);
    -webkit-tap-highlight-color: transparent;
}

.product-pi-legal.has-open-hint .pi-hint-backdrop {
    display: block;
}

/* Мобилка: wishlist — следующий sibling в DOM, рисуется поверх fixed-popover; прячем, пока открыт PI */
@media (max-width: 767px) {
    .w22-product-info-card.w22-pi-overlay-open .wishlist-btn {
        z-index: 0 !important;
        pointer-events: none;
        visibility: hidden;
        opacity: 0;
        transition: opacity 0.12s ease, visibility 0.12s ease;
    }

    .product-pi-legal.has-open-hint .pi-hint-backdrop {
        z-index: 100000;
    }

    .product-pi-legal .pi-hint-popover.is-open {
        z-index: 100010 !important;
    }
}

/* Desktop: всплывашка у якоря */
.product-pi-legal .pi-hint-popover {
    position: absolute;
    z-index: 60;
    left: 0;
    top: calc(100% + 8px);
    width: min(90vw, 360px);
    max-width: calc(100vw - 2rem);
    max-height: min(70vh, 28rem);
    overflow-y: auto;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.15s ease, visibility 0.15s ease;
}

@media (hover: hover) and (pointer: fine) and (min-width: 768px) {
    .product-pi-legal .pi-hint-anchor:hover .pi-hint-popover,
    .product-pi-legal .pi-hint-anchor:focus-within .pi-hint-popover {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }
}

/* Мобилка: только .is-open, по центру экрана */
@media (max-width: 767px) {
    /*
     * Тач: после тапа на «?» остаётся :hover на якоре. Старый селектор без :not(.is-open)
     * давал opacity:0 !important и перебивал открытый popover → моргание.
     */
    .product-pi-legal .pi-hint-anchor:hover .pi-hint-popover:not(.is-open) {
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
    }

    /* Центр viewport: left+right+margin auto надёжнее, чем 50%+translate, если у предка transform (fixed «ломается») */
    .product-pi-legal .pi-hint-popover {
        position: fixed;
        left: 0;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        width: min(92vw, 400px);
        max-width: 400px;
        margin-left: auto;
        margin-right: auto;
        max-height: min(75vh, 32rem);
        z-index: 9990;
        box-sizing: border-box;
    }

    .product-pi-legal .pi-hint-popover.is-open {
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
    }
}

/* Клавиатура / тач-ноут: открытие классом на широком экране */
@media (min-width: 768px) {
    .product-pi-legal .pi-hint-popover.is-open {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }
}

/* Один «?» у заголовка товара: всплывашка вправо от кнопки, не вылезает за карточку */
@media (hover: hover) and (pointer: fine) and (min-width: 768px) {
    .product-pi-hero-hint-inline .pi-hint-popover {
        left: auto;
        right: 0;
        width: min(calc(100vw - 2rem), 380px);
        max-height: min(75vh, 32rem);
    }
}

.product-pi-hero-hint-inline {
    position: relative;
    z-index: 5;
}

/* Контейнер слайдера */
.info-slider-wrap {
    position: relative;
    overflow: hidden;
    max-width: 100%;
}

/* Длинная страница (блок PI выше): до reflow autoHeight мог дать 0 — не даём коллапсить */
#w22-vorteile-slider-wrap .w22-info-swiper {
    min-height: 4rem;
}

/* Внутренний контейнер текста — меньше паддинг на мобилках, чтобы не было overflow */
.slide-inner {
    padding-left: 50px;
    padding-right: 50px;
}
@media (min-width: 768px) {
    .slide-inner {
        padding-left: 70px;
        padding-right: 70px;
    }
}

/* Стрелки — позиция относительно wrap, не swiper */
.info-slider-wrap .info-slider-nav-prev,
.info-slider-wrap .info-slider-nav-next {
    color: #000;
    width: 44px;
    height: 44px;
    z-index: 20;
    cursor: pointer;
}
.info-slider-wrap .info-slider-nav-prev { left: 10px; }
.info-slider-wrap .info-slider-nav-next { right: 10px; }
.info-slider-wrap .info-slider-nav-prev::after,
.info-slider-wrap .info-slider-nav-next::after {
    font-size: 22px;
    font-weight: bold;
}


.reviews-slider-wrap { position: relative; }
.reviews-slider-inner { padding: 0 60px; }

/* Карточка */
.review-cards {
    height: 100%;
    min-height: 240px;
    background: #fff;
    display: flex;
    font-family: 'PT Mono', monospace;
}

.review-content {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* Шапка */
.review-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 10px;
}

.author-block {
    display: flex;
    flex-direction: column;
    max-width: 70%;
}

.author {
    font-weight: 600;
    font-size: 14px;
    line-height: 1.2;
}

.verified-yes {
    font-size: 11px;
    font-weight: 600;
    color: #22c55e;
}

.verified-no {
    font-size: 11px;
    font-weight: 600;
    color: #dc2626;
}

/* Звезды */
.stars {
    color: #facc15;
    white-space: nowrap;
    flex-shrink: 0;
    font-size: 14px;
}

/* Текст */
.review-texts {
    flex: 1;
    display: flex;
    align-items: center;
    font-size: 14px;
    line-height: 1.6;
    color: #374151;
    padding: 10px 0;
}

/* Дата */
.review-dates {
    text-align: right;
    font-size: 12px;
    color: #9ca3af;
    margin-top: 10px;
}

/* Стрелки */
.reviews-nav-prev,
.reviews-nav-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 42px;
    height: 42px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    color: black;
}

.reviews-nav-prev { left: 0; }
.reviews-nav-next { right: 0; }


#starRating span {
    color: #f5b301;
}
#starRating span.active {
    color: #f5b301;
}

.wishlist-btn {
    position: absolute; 
	top: 0; 
	right: 20px;
}