/* ======================================================================
   КАТЕГОРИИ — СЛАЙДЕР (ПК) + СВАЙП (МОБИЛЬНЫЕ)
====================================================================== */

.lolli-categories-wrapper {
    position: relative;
    width: 100%;
    padding: 0 40px; /* ← пространство для стрелок */
    margin: 0 auto 30px;
    box-sizing: border-box;
}

/* контейнер категорий */
.lolli-categories {
    display: flex;
    gap: 22px;
    padding: 10px 0 20px;

    overflow-x: auto;
    overflow-y: hidden;

    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.lolli-categories::-webkit-scrollbar {
    display: none;
}

/* элементы */
.lolli-cat-item {
    flex: 0 0 auto;
    scroll-snap-align: start;

    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;

    color: #ffd8f8;
    font-size: 14px;
    font-weight: 700;

    transition: .25s ease;
    min-width: 92px;
}

.lolli-cat-icon {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    background: #1e1e2a;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 8px;
    transition: .25s;
}

.lolli-cat-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.lolli-cat-item:hover .lolli-cat-icon {
    background: #ff7cd8;
    transform: translateY(-3px);
    box-shadow: 0 0 18px rgba(255,120,200,.7);
}

/* ======================================================================
   СТРЕЛКИ ДЛЯ ПК
====================================================================== */

.lolli-cat-arrow {
    display: none; /* Мобильные — скрыть */
}

@media (min-width: 960px) {
    .lolli-cat-arrow {
        display: flex;
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        width: 36px;
        height: 36px;
        border-radius: 50%;
        background: rgba(20,20,32,0.9);
        color: #ffd8f8;
        font-size: 20px;
        border: none;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        box-shadow: 0 0 18px rgba(255,120,220,.4);
        transition: .25s ease;
        z-index: 50;
    }

    .lolli-cat-arrow.left {
        left: 10px;
    }

    .lolli-cat-arrow.right {
        right: 10px;
    }
}

/* ======================================================================
   МОБИЛЬНАЯ АДАПТАЦИЯ — свайп
====================================================================== */

@media (max-width: 600px) {
    .lolli-categories {
        padding-left: 6px;
        padding-right: 6px;
        gap: 16px;
    }

    .lolli-cat-item {
        min-width: 78px;
    }

    .lolli-cat-icon {
        width: 72px;
        height: 72px;
    }

    .lolli-cat-item span {
        font-size: 12px;
    }
}


/* ======================================================================
   Убираем OceanWP overlays
====================================================================== */

.products.oceanwp-row::before,
.products.oceanwp-row::after,
ul.products::before,
ul.products::after,
ul.products li.product::before,
ul.products li.product::after {
    display: none !important;
    content: none !important;
}

/* ======================================================================
   СЕТКА
====================================================================== */

.lolli-products-grid,
.woocommerce ul.products {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 38px !important;
    padding: 20px 0 80px !important;
    width: 100% !important;
    list-style: none;
}

@media(max-width:1280px){
    .lolli-products-grid,
    .woocommerce ul.products {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media(max-width:960px){
    .lolli-products-grid,
    .woocommerce ul.products {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media(max-width:600px){
    .lolli-products-grid,
    .woocommerce ul.products {
        grid-template-columns: repeat(1, 1fr);
    }
}

/* ============================================================
   LOLLI PRODUCT CARD — ТОЧНО КАК НА HOME v2.0
============================================================ */

.lolli-product-card {
    background: #191923;
    border-radius: 18px;
    padding: 14px 14px 24px;
    box-shadow: 0 0 18px rgba(0,0,0,0.65);
    border: 1px solid rgba(255,255,255,0.05);

    display: flex !important;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;

    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
    position: relative;
    scroll-snap-align: start;
}

/* hover — как в lolli-home-card */
.lolli-product-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255,120,220,0.6);
    box-shadow: 0 0 26px rgba(255,120,220,0.45);
}

/* ======================================================================
   IMG
====================================================================== */

.lolli-product-image {
    width:100%;
    height:auto;
    border-radius:22px;

    display:flex;
    justify-content:center;
    align-items:center;
    overflow:hidden;
}

.lolli-product-image img{
    width:100%;
    height:100%;
    object-fit:contain;
    padding:18px;
    transition:.3s;
}

/* ======================================================================
   TITLE
====================================================================== */

.lolli-product-title {
    font-size:17px;
    font-weight:700;
    min-height:50px;
    margin:4px 0 10px;
    color:#ffd8f8;
}

.lolli-product-title a {
    color:#ffd8f8;
    text-decoration:none;
}

/* ======================================================================
   CATEGORY
====================================================================== */

.lolli-product-cat {
    display:inline-block;
    padding:4px 12px;
    background:linear-gradient(90deg,#ff7dd1,#b067ff);
    color:white;
    border-radius:12px;
    font-size:12px;
    font-weight:700;
    margin-bottom:10px;
    text-decoration:none;
}

/* ======================================================================
   PRICE
====================================================================== */

.lolli-product-price{
    font-size:16px;
    font-weight:700;
    color:#d9ff7a;
    margin-bottom:20px;
}

/* ======================================================================
   BUY BUTTON
====================================================================== */

.lolli-product-buy,
.woocommerce ul.products li.product .button {
    width:100% !important;
    background:white !important;
    color:black !important;
    padding:10px 18px !important;
    border-radius:16px !important;
    font-size:15px !important;
    font-weight:700 !important;
    transition:.25s !important;
    margin-top:auto !important;
}

.lolli-product-buy:hover,
.woocommerce ul.products li.product .button:hover{
    background:#ff7cd8 !important;
    color:white !important;
    box-shadow:0 0 18px rgba(255,100,200,.6) !important;
}
/* ============================================================
   КОМПАТ с карточками shop-home (новинки, популярные)
============================================================ */

.lolli-prod-card { 
    background:#1a1a25;
    border-radius:28px;
    padding:22px;
    box-shadow:0 0 18px rgba(255,120,220,.13);
    transition:.3s ease;
    display:flex !important;
    flex-direction:column;
    align-items:center;
    text-align:center;
    height:100%;
}

.lolli-prod-card:hover{
    transform:translateY(-6px) scale(1.03);
    box-shadow:0 0 32px rgba(255,120,220,.45);
}

.lolli-prod-image {
    width:100%;
    height:260px;
    background:#f9e5f6;
    border-radius:22px;
    display:flex;
    justify-content:center;
    align-items:center;
    overflow:hidden;
    margin-bottom:16px;
}

.lolli-prod-image img {
    width:100%;
    height:100%;
    object-fit:contain;
    padding:18px;
    transition:.3s;
}

.lolli-prod-title {
    font-size:17px;
    font-weight:700;
    min-height:50px;
    margin:4px 0 10px;
    color:#ffd8f8;
}

.lolli-prod-title a {
    color:#ffd8f8;
    text-decoration:none;
}

.lolli-prod-price{
    font-size:16px;
    font-weight:700;
    color:#d9ff7a;
    margin-bottom:10px;
}

.lolli-prod-btn {
    width:100%;
    background:white;
    color:black;
    padding:10px 18px;
    border-radius:16px;
    font-size:15px;
    font-weight:700;
    transition:.25s;
    margin-top:auto;
}

.lolli-prod-btn:hover{
    background:#ff7cd8;
    color:white;
    box-shadow:0 0 18px rgba(255,100,200,.6);
}

/* ======================================================================
   ВОССТАНОВЛЕНИЕ СТАРОЙ СЕТКИ 4-В-РЯД
====================================================================== */

.woocommerce ul.products {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 34px !important;
    padding: 20px 0 70px !important;
    width: min(1400px, 94%) !important;
    margin: 0 auto !important; /* ЦЕНТРУЕМ */
}

/* 3-в-ряд */
@media(max-width:1280px){
    .woocommerce ul.products {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

/* 2-в-ряд */
@media(max-width:900px){
    .woocommerce ul.products {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* 1-в-ряд */
@media(max-width:600px){
    .woocommerce ul.products {
        grid-template-columns: repeat(1, 1fr) !important;
    }
}

/* ======================================================================
   КАРТОЧКА ПРОДУКТА (ВОЗВРАЩАЮ «ОВАЛ», ФОН, ТЕНИ, ВЫРАВНИВАНИЕ)
====================================================================== */

.woocommerce ul.products li.product {
    background:#1a1a25 !important;
    border-radius:28px !important;
    box-shadow:0 0 18px rgba(255,120,220,.13) !important;
    text-align:center !important;
    display:flex !important;
    flex-direction:column !important;
    align-items:center !important;
    transition:.25s;
}

.woocommerce ul.products li.product:hover {
    transform:translateY(-6px) scale(1.03) !important;
    box-shadow:0 0 32px rgba(255,120,220,.45) !important;
}

/* ======================================================================
   ИЗОБРАЖЕНИЕ — ВОССТАНОВЛЯЮ ПРЯМОУГОЛЬНЫЙ ОВАЛ
====================================================================== */

.woocommerce ul.products li.product img {
    width:100% !important;
    border-radius:22px !important;
    padding:6px !important;
    transition:transform .25s;
}

.woocommerce ul.products li.product:hover img {
    transform:scale(1.05);
}

/* ======================================================================
   ТЕКСТ (НАЗВАНИЕ)
====================================================================== */

.woocommerce ul.products li.product .woocommerce-loop-product__title {
    color:#ffd8f8 !important;
    font-size:17px !important;
    font-weight:700 !important;
    min-height:50px !important;
    margin:12px 0 6px !important;
}

/* ======================================================================
   КАТЕГОРИЯ / БЕЙДЖ
====================================================================== */

.woocommerce ul.products li.product .woocommerce-loop-category__title,
.woocommerce ul.products li.product .lolli-product-cat {
    display:inline-block;
    padding:4px 12px;
    background:linear-gradient(90deg,#ff7dd1,#b067ff);
    color:white;
    border-radius:12px;
    font-size:12px;
    font-weight:700;
    margin-bottom:10px;
}

/* ======================================================================
   ЦЕНА
====================================================================== */
.woocommerce ul.products li.product .price {
    font-size:22px !important;
    font-weight:700 !important;
    margin-bottom:20px !important;
    color:#EE82EE !important;
}

/* ======================================================================
   КНОПКА
====================================================================== */

.woocommerce ul.products li.product .button {
    width:100% !important;
    background:white !important;
    color:black !important;
    padding:10px 18px !important;
    border-radius:16px !important;
    font-size:15px !important;
    font-weight:700 !important;
    transition:.25s !important;
}

.woocommerce ul.products li.product .button:hover {
    background:#ff7cd8 !important;
    color:white !important;
    box-shadow:0 0 18px rgba(255,100,200,.6) !important;
}

/* ================================  
   Lollibuy — сортировка  
================================= */

.woocommerce-ordering {
    margin: 0 auto 20px !important;
    display: flex !important;
    justify-content: center !important;
}

.woocommerce-ordering select {
    appearance: none !important;
    background: linear-gradient(90deg,#ff7dd1,#b067ff) !important;
    border: none !important;
    padding: 12px 18px !important;
    border-radius: 14px !important;
    color: #fff !important;
    font-weight: 700 !important;
    font-size: 14px !important;
    cursor: pointer !important;
    box-shadow: 0 0 22px rgba(255,120,220,.5) !important;
    transition: .25s !important;
}

.woocommerce-ordering select:hover {
    box-shadow: 0 0 32px rgba(255,120,220,.8) !important;
    transform: translateY(-2px);
}

/* стрелка для селекта */
.woocommerce-ordering select {
    background-image: url("data:image/svg+xml;utf8,<svg fill='white' height='20' viewBox='0 0 20 20' width='20' xmlns='http://www.w3.org/2000/svg'><polygon points='0,0 20,0 10,10'/></svg>");
    background-repeat: no-repeat;
    background-position: calc(100% - 14px) center;
    background-size: 12px;
    padding-right: 40px !important;
}

/* Keep WooCommerce errors and success notices visible. */

/* ============================
   Lollibuy Custom Sort Dropdown
============================ */

.lolli-sort {
    width: 100%;
    max-width: 320px;
    margin: 0 auto 30px;
    position: relative;
    z-index: 999;
    font-family: inherit;
}

/* Кнопка */
.lolli-sort-selected {
    background: linear-gradient(90deg,#ff7dd1,#b067ff);
    color: #fff;
    padding: 14px 18px;
    border-radius: 18px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    box-shadow: 0 0 22px rgba(255,120,220,.6);
    transition: .25s ease;
}

.lolli-sort-selected:hover {
    box-shadow: 0 0 32px rgba(255,120,220,.8);
    transform: translateY(-2px);
}

/* Выпадающий список */
.lolli-sort-list {
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: #1a1a25;
    border-radius: 16px;
    box-shadow: 0 0 26px rgba(0,0,0,.6);
    padding: 10px 0;
    display: none;
    flex-direction: column;
    overflow: hidden;
}

/* Элементы */
.lolli-sort-item {
    padding: 12px 20px;
    color: #ffd8f8;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: .2s;
}

.lolli-sort-item:hover {
    background: rgba(255,120,220,.15);
    color: #fff;
}

/* ==========================================================
   FIX: Lollibuy Product Category Link (под товаром)
   Убираем подчёркивание + выравнивание + красивый стиль
   (Не конфликтует с shop.css)
========================================================== */

.lolli-prod-cat,
.woocommerce ul.products li.product .lolli-product-cat,
.woocommerce ul.products li.product .woocommerce-loop-category__title a {
    text-decoration: none !important;
    border: none !important;
    outline: none !important;

    display: inline-block !important;
    padding: 4px 12px !important;
    border-radius: 12px !important;

    background: linear-gradient(90deg,#ff7dd1,#b067ff) !important;
    color: #fff !important;

    font-size: 12px !important;
    font-weight: 700 !important;

    margin-bottom: 10px !important;
    box-shadow: 0 0 12px rgba(255,120,220,.25) !important;

    transition: .25s ease !important;
}

/* Hover */
.lolli-prod-cat:hover,
.woocommerce ul.products li.product .lolli-product-cat:hover,
.woocommerce ul.products li.product .woocommerce-loop-category__title a:hover {
    color: #fff !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 0 22px rgba(255,120,220,.55) !important;
}

/* -------------------------------------------
   Фикс мобильного выравнивания
-------------------------------------------- */
@media (max-width: 600px) {
    .lolli-prod-cat,
    .woocommerce ul.products li.product .lolli-product-cat {
        margin-left: auto !important;
        margin-right: auto !important;
        display: inline-flex !important;
        justify-content: center !important;
    }
}

/* ==========================================================
   Lollibuy — Красивая пагинация WooCommerce
========================================================== */

.woocommerce-pagination {
    margin: 40px 0 !important;
    display: flex;
    justify-content: center;
}

.woocommerce-pagination ul.page-numbers {
    display: flex;
    gap: 10px;
    list-style: none;
    padding: 0;
    margin: 0 auto;
}

/* Базовый стиль кнопок */
.woocommerce-pagination ul.page-numbers li .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 40px;
    height: 40px;

    padding: 0 14px;

    background: #1b1b27;
    color: #ffd8f8 !important;

    border-radius: 14px;
    font-weight: 700;

    text-decoration: none !important;
    border: none !important;

    transition: .25s ease;
    box-shadow: 0 0 12px rgba(0,0,0,.45);
}

/* Hover */
.woocommerce-pagination ul.page-numbers li .page-numbers:hover {
    background: #ff7dd1;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 0 18px rgba(255,120,220,.65);
}

/* Активная страница */
.woocommerce-pagination ul.page-numbers li .page-numbers.current {
    background: linear-gradient(90deg,#ff7dd1,#b067ff) !important;
    color: #fff !important;
    cursor: default;
    box-shadow: 0 0 22px rgba(255,120,220,.55);
}

/* Стрелки */
.woocommerce-pagination ul.page-numbers li .prev,
.woocommerce-pagination ul.page-numbers li .next {
    font-size: 18px;
    padding: 0 14px;
}

/* Многоточие */
.woocommerce-pagination ul.page-numbers li .dots {
    background: transparent !important;
    box-shadow: none !important;
    color: #b88dd9 !important;
    cursor: default;
}

/* FULL WIDTH CATEGORY SLIDER ON MOBILE */
@media (max-width: 600px) {

    .lolli-categories-wrapper {
        width: 100%;
        max-width: 100%;
        padding: 0;
        margin: 0;
    }

    .lolli-categories {
        width: 100%;
        overflow-x: auto;
        padding-left: 10px;
        padding-right: 10px;
    }

    .lolli-cat-item {
        flex: 0 0 auto !important;
        margin-right: 18px;
    }

    .lolli-cat-arrow {
        display: none !important;
    }
}

/* ГЛАВНОЕ: категории по ширине товаров */
.lolli-categories-wrapper {
    width: min(1400px, 94%);
    margin: 0 auto 30px;
    padding: 0 40px;
    box-sizing: border-box;
}

/* Не дать слайдеру растягиваться */
.lolli-categories {
    max-width: 100%;
    margin: 0 auto;
}

@media (max-width: 767px) {
    .lolli-categories-wrapper {
        width: 100%;
        padding: 0 !important;
        margin: 0 0 20px 0;
    }

    .lolli-categories {
        padding: 0 10px;
        gap: 16px;
    }

    .lolli-cat-arrow {
        display: none !important;
    }
}

/* ============================================================
   ЧИСТЫЙ ТИТУЛЬНЫЙ H1 (НЕОН-БЕЗ МУСОРА)
============================================================ */
.skye-shop-title,
.woocommerce-products-header__title {
    text-align: center;
    font-size: 42px;
    font-weight: 800;
    margin: 40px auto 22px;

    color: #ffd8fa;

    /* очень мягкий внутренний отблеск */
    text-shadow:
        0 0 4px rgba(255,120,220,0.35),
        0 0 8px rgba(255,120,220,0.25);

    animation: lolliPulse 3.2s ease-in-out infinite;

    letter-spacing: 0.5px;
}

/* аккуратный пульс */
@keyframes lolliPulse {
    0%, 100% {
        text-shadow:
            0 0 4px rgba(255,120,220,0.30),
            0 0 7px rgba(255,120,220,0.15);
    }
    50% {
        text-shadow:
            0 0 10px rgba(255,120,220,0.40),
            0 0 18px rgba(255,120,220,0.18);
    }
}

/* MOBILE */
@media (max-width: 650px) {
    .skye-shop-title,
    .woocommerce-products-header__title {
        font-size: 32px;
    }
}

.term-description {
    max-width: 750px;
    margin: 0 auto 40px;
    padding: 16px 22px;

    text-align: center;
    font-size: 16px;
    line-height: 1.55;
    color: #f6e8ff;

    background: rgba(24, 24, 36, 0.55);
    border-radius: 18px;
    border: 1px solid rgba(255,120,220,0.12);

    backdrop-filter: blur(6px);
    box-shadow: inset 0 0 12px rgba(255,120,220,0.08);
}

@media (max-width: 650px) {
    .term-description {
        font-size: 15px;
        padding: 14px 18px;
    }
}

.lolli-home-price del {
    text-decoration: line-through;
    opacity: 0.5;
    color: #ff9acb;
}

.lolli-home-price ins {
    color: #ff57d6;
    font-weight: 800;
}

.lolli-product-image {
    position: relative;
}

/* Product-card badges share one predictable system. Discount stays at the top,
   real low-stock urgency stays at the bottom so narrow cards never overlap. */
.lolli-sale-badge,
.lolli-stock-badge {
    position: absolute;
    left: 12px;
    z-index: 20;
    max-width: calc(100% - 24px);
    box-sizing: border-box;
    padding: 6px 12px;
    border-radius: 14px;
    font-weight: 800;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    pointer-events: none;
    backdrop-filter: blur(5px);
}

.lolli-sale-badge {
    top: 12px;
    background: linear-gradient(135deg, #ff62d4, #ff2ba9);
    color: #fff;
    font-size: 14px;
    box-shadow: 0 0 12px rgba(255, 0, 140, 0.4);
    animation: lolliBadgeIn .28s ease-out;
}

.lolli-stock-badge {
    top: auto;
    bottom: 12px;
    background: rgba(20, 18, 30, 0.84);
    border: 1px solid rgba(255, 119, 204, 0.55);
    color: #ffe2f8;
    font-size: 13px;
    box-shadow: 0 0 12px rgba(255, 100, 200, 0.35);
}

@keyframes lolliBadgeIn {
    from { transform: scale(.82); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
    .lolli-sale-badge { animation: none; }
}

/* ==========================================================
   FIX: центрирование рейтинга (звёзд) в карточке товара
========================================================== */
.lolli-product-info .star-rating {
    display: block !important;
    margin: 6px auto 10px !important;
    width: 84px !important; /* стандартная ширина 5 звёзд у Woo */
    text-align: center;
}
/* Shared product card layout. */
.lolli-product-card{
    width:100%;
    height:100%;
}

/* ============================================================
   MOBILE FIXES — polish
============================================================ */

@media (max-width: 600px) {
  .lolli-product-summary { padding: 22px; }
  .single-product .price { font-size: 20px !important; }

  .woocommerce div.product .woocommerce-tabs ul.tabs li {
    font-size: 14px;
    padding: 8px 14px !important;
  }
  .woocommerce div.product .woocommerce-tabs .woocommerce-Tabs-panel {
    padding: 18px 20px;
  }

  #reviews .comment_container img.avatar {
    width: 42px;
    height: 42px;
  }
  #reviews #comments ol.commentlist li {
    padding: 14px 16px;
  }
  #review_form_wrapper {
    padding: 20px 22px;
  }

  .lolli-table-wrap{
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 20px 0;
    }

    /* Чтобы таблица не ломала страницу */
    .lolli-table-wrap table{
    min-width: 800px;
    }

    /* Убираем горизонтальный скролл у body */
    body{
    overflow-x: hidden;
    }
}

/* ==========================================================
   LOLLIBUY — SINGLE PRODUCT GALLERY (PREMIUM FIX + STYLE)
   ✅ Fixes:
   - main image not tiny
   - thumbs not on the side
   - clicks work for all images
   - keeps Woo lightbox intact
   ✅ Style:
   - square stage 1:1
   - neon glow
   - premium thumbs grid
========================================================== */

/* ---------- 0) HARD RESET: do NOT flex the Woo wrapper ---------- */
/* Это лечит твой баг "wrapper width:40%" и сломанные клики */
.woocommerce div.product div.images .woocommerce-product-gallery,
.woocommerce div.product div.images .woocommerce-product-gallery__wrapper {
  display: block !important;
  align-items: initial !important;
  justify-content: initial !important;

  width: 100% !important;
  max-width: 100% !important;

  transform: none !important; /* если тема подсовывает кривой transform */
}

/* Убираем float/ширины темы (OceanWP иногда вставляет) */
.woocommerce div.product div.images {
  float: none !important;
  width: 100% !important;
  max-width: 100% !important;
}

/* ---------- 1) YOUR GALLERY BOX (не ломаем Woo, стилим контейнер) ---------- */
.lolli-product-gallery {
  position: relative;
  overflow: hidden;

  background:
    radial-gradient(circle at 30% 10%, rgba(255,140,240,.22), transparent 60%),
    radial-gradient(circle at 85% 70%, rgba(180,120,255,.30), transparent 60%),
    #141421;

  border-radius: 28px;
  padding: 34px;
  box-shadow: 0 0 44px rgba(255,120,220,.42);

  /* центрируем контент безопасно */
  display: flex;
  align-items: center;
  justify-content: center;
}

/* subtle frame */
.lolli-product-gallery::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 28px;
  border: 1px solid rgba(255,255,255,0.06);
  pointer-events: none;
}

/* ---------- 2) Make Woo gallery layout: viewport on top, thumbs below ---------- */
.woocommerce div.product div.images .woocommerce-product-gallery {
  display: flex !important;
  flex-direction: column !important;
  gap: 14px !important;
}

/* viewport (main image area) */
.woocommerce div.product div.images .flex-viewport {
  order: 1 !important;

  border-radius: 22px;
  overflow: hidden;

  position: relative !important;
  z-index: 1 !important;
}

/* ---------- 3) Square Stage 1:1 (premium) ---------- */
/* Не трогаем wrapper flex'ом, но делаем stage квадратом */
.woocommerce div.product div.images .woocommerce-product-gallery__image {
  position: relative !important;

  width: 100% !important;
  max-width: 640px !important;

  aspect-ratio: 1 / 1 !important;

  display: flex !important;
  align-items: center !important;
  justify-content: center !important;

  margin: 0 auto !important;

  border-radius: 22px;
  background: rgba(0,0,0,.18);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.06),
    0 0 34px rgba(255,120,220,.12);
}

/* If link exists */
.woocommerce div.product div.images .woocommerce-product-gallery__image > a {
  width: 100% !important;
  height: 100% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

/* Image itself */
.woocommerce div.product div.images .woocommerce-product-gallery__image img {
  width: 100% !important;
  height: 100% !important;
  display: block !important;

  object-fit: contain !important;
  padding: 18px;

  border-radius: 18px;
  filter: drop-shadow(0 0 18px rgba(255,120,220,.10));
}

/* ---------- 4) Thumbs grid (below) + CLICK FIX ---------- */
.woocommerce div.product div.images .flex-control-nav.flex-control-thumbs {
  order: 2 !important;

  float: none !important;
  clear: both !important;

  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;

  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 10px !important;

  position: relative !important;
  z-index: 10 !important;          /* чтобы клики не перекрывались */
  pointer-events: auto !important;
}

.woocommerce div.product div.images .flex-control-thumbs li {
  list-style: none !important;
  margin: 0 !important;
  width: auto !important;
}

/* Thumb image */
.woocommerce div.product div.images .flex-control-thumbs img {
  width: 100% !important;
  height: 78px !important;

  object-fit: cover !important;

  border-radius: 16px !important;
  background: #1a1a25 !important;

  border: 1px solid rgba(255,255,255,0.07) !important;
  box-shadow: 0 0 14px rgba(0,0,0,.45) !important;

  opacity: .72 !important;
  cursor: pointer !important;

  transition: .22s ease !important;

  pointer-events: auto !important;
  transform: translateY(0);
}

/* Hover */
.woocommerce div.product div.images .flex-control-thumbs img:hover {
  opacity: 1 !important;
  transform: translateY(-2px);
  border-color: rgba(255,120,220,.55) !important;
  box-shadow: 0 0 18px rgba(255,120,220,.42) !important;
}

/* Active thumb */
.woocommerce div.product div.images .flex-control-thumbs img.flex-active {
  opacity: 1 !important;
  border-color: rgba(255,120,220,.75) !important;
  box-shadow: 0 0 24px rgba(255,120,220,.55) !important;
}

/* ---------- 5) Trigger / lightbox (не ломаем, но красиво) ---------- */
/* Оставляем элемент живым (не 1px!), просто делаем "премиум кнопку" */
.woocommerce div.product div.images .woocommerce-product-gallery__trigger {
  position: absolute !important;
  top: 16px !important;
  right: 16px !important;

  width: 44px !important;
  height: 44px !important;
  border-radius: 14px !important;

  display: flex !important;
  align-items: center !important;
  justify-content: center !important;

  background: rgba(15, 15, 28, 0.55) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;

  box-shadow: 0 0 18px rgba(255,120,220,.25) !important;
  backdrop-filter: blur(6px);

  color: #ffd8f8 !important;

  z-index: 20 !important;
  transition: .22s ease !important;
}

/* Hide Woo default icon if exists */
.woocommerce div.product div.images .woocommerce-product-gallery__trigger img,
.woocommerce div.product div.images .woocommerce-product-gallery__trigger svg {
  display: none !important;
}

/* Our icon */
.woocommerce div.product div.images .woocommerce-product-gallery__trigger::before {
  content: "";
  width: 18px;
  height: 18px;
  display: block;
  background: currentColor;

  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M21 21l-4.35-4.35m1.85-5.15a7 7 0 1 1-14 0a7 7 0 0 1 14 0Z'/%3E%3C/svg%3E") center/contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M21 21l-4.35-4.35m1.85-5.15a7 7 0 1 1-14 0a7 7 0 0 1 14 0Z'/%3E%3C/svg%3E") center/contain no-repeat;
}

.woocommerce div.product div.images .woocommerce-product-gallery__trigger:hover {
  transform: translateY(-1px);
  border-color: rgba(255,120,220,.55) !important;
  box-shadow: 0 0 26px rgba(255,120,220,.55) !important;
  background: rgba(255,120,220,0.14) !important;
}

/* Desktop: show on hover only (но элемент НЕ калечим) */
@media (hover:hover) and (pointer:fine) {
  .woocommerce div.product div.images .woocommerce-product-gallery__trigger {
    opacity: 0;
    pointer-events: none;
    transform: translateY(-6px);
  }

  .woocommerce div.product div.images .woocommerce-product-gallery__image:hover
  .woocommerce-product-gallery__trigger {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }
}

/* Mobile: always visible */
@media (hover:none) and (pointer:coarse) {
  .woocommerce div.product div.images .woocommerce-product-gallery__trigger {
    opacity: 1;
    pointer-events: auto;
    transform: none;
  }
}

/* ---------- 6) Mobile polish ---------- */
@media (max-width: 600px) {
  .lolli-product-gallery { padding: 20px; }

  .woocommerce div.product div.images .woocommerce-product-gallery__image {
    max-width: 440px !important;
  }

  .woocommerce div.product div.images .flex-control-nav.flex-control-thumbs {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  .woocommerce div.product div.images .flex-control-thumbs img {
    height: 58px !important;
    border-radius: 14px !important;
  }
}

/* ==========================================================
   FINAL FIX — for your markup (.lolli-product-gallery wrapper)
   - thumbs below
   - all clickable
   - no tiny image / no side column
========================================================== */

/* 1) УБИРАЕМ flex с Woo wrapper (это ломает flexslider расчёты) */
.woocommerce-product-gallery__wrapper {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
}

/* 2) Галерея = flex-column (это и есть "картинка сверху, превью снизу") */
/* ВАЖНО: делаем без привязки к div.images */
.woocommerce-product-gallery {
  display: flex !important;
  flex-direction: column !important;
  width: 100% !important;
  max-width: 100% !important;
}

/* 3) Viewport (главная картинка) занимает всю ширину */
.flex-viewport {
  order: 1 !important;
  width: 100% !important;
  max-width: 100% !important;
}

/* 4) Thumbs снизу сеткой */
.flex-control-nav.flex-control-thumbs {
  order: 2 !important;

  width: 100% !important;
  max-width: 100% !important;

  float: none !important;
  clear: both !important;

  margin: 14px 0 0 !important;
  padding: 0 !important;

  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 10px !important;

  position: relative !important;
  z-index: 999 !important;
  pointer-events: auto !important;
}

/* 5) Убираем цифры 1., 2. (как у тебя на скрине) */
.flex-control-nav.flex-control-thumbs,
.flex-control-nav.flex-control-thumbs li {
  list-style: none !important;
}

/* 6) li и img нормальные, кликабельные */
.flex-control-nav.flex-control-thumbs li {
  margin: 0 !important;
  width: auto !important;
}

.flex-control-nav.flex-control-thumbs img {
  width: 100% !important;
  height: 78px !important;
  object-fit: cover !important;

  border-radius: 16px !important;
  background: #1a1a25 !important;

  border: 1px solid rgba(255,255,255,0.07) !important;
  box-shadow: 0 0 14px rgba(0,0,0,.45) !important;

  opacity: .75 !important;
  cursor: pointer !important;

  pointer-events: auto !important;
  transition: .22s ease !important;
}

.flex-control-nav.flex-control-thumbs img:hover,
.flex-control-nav.flex-control-thumbs img.flex-active {
  opacity: 1 !important;
  transform: translateY(-2px);
  border-color: rgba(255,120,220,.65) !important;
  box-shadow: 0 0 22px rgba(255,120,220,.55) !important;
}

/* 7) Мобила */
@media (max-width: 600px) {
  .flex-control-nav.flex-control-thumbs {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }
  .flex-control-nav.flex-control-thumbs img {
    height: 58px !important;
    border-radius: 14px !important;
  }
}

.lolli-product-card{
    display:flex;
    flex-direction:column;
    height:100%;
}

.lolli-product-info{
    display:flex;
    flex-direction:column;
    flex:1;
}

.lolli-product-price{
    margin-top:auto;
}

.lolli-product-card .button{
    margin-top:16px;
}

.lolli-product-title{
    min-height:56px;

    display:-webkit-box;
    -webkit-box-orient:vertical;
    -webkit-line-clamp:2;
    overflow:hidden;
}

.lolli-product-image {
    position: relative;
    display: block;
    overflow: hidden;
}

/* ==========================================================
   VIEW CART BUTTON
========================================================== */

.lolli-product-card .added_to_cart.wc-forward {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 100%;
    margin-top: 12px;
    padding: 14px 20px;

    background: rgba(255,120,220,.08);
    border: 1px solid rgba(255,120,220,.28);
    border-radius: 16px;

    color: #ffd8f8 !important;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;

    backdrop-filter: blur(8px);

    transition:
        background .25s,
        border-color .25s,
        color .25s,
        box-shadow .25s,
        transform .2s;
}

.lolli-product-card .added_to_cart.wc-forward:hover {
    background: linear-gradient(135deg,#ff7cd8,#b067ff);
    border-color: transparent;

    color: #fff !important;

    transform: translateY(-2px);

    box-shadow: 0 0 22px rgba(255,120,220,.45);
}

.lolli-product-card .added_to_cart.wc-forward::before {
    content: "🛒";
    margin-right: 10px;
    font-size: 16px;
}
