/* =====================================================================
   PRINTINGLIFE — CATALOG v2
   /product-category/categories — родительская (карточки разделов)
   /product-category/categories/<slug> — лист категории (фильтры + товары)
   Префикс .plc-*. Токены — из printinglife-header.css (:root).
   ===================================================================== */

.plc-page {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--pl-text);
    padding: 2rem 0 4rem;
    background: #fff;
}

.plc-container {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0 var(--pl-page-px);
}

/* ========== Хлебные крошки ========== */
.plc-breadcrumbs {
    padding: 0;
    margin: 0 0 1rem;
}

.plc-breadcrumbs__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.15rem 0.1rem;
    font-size: 0.8125rem;
    color: var(--pl-muted);
}

.plc-breadcrumbs__item {
    display: inline-flex;
    align-items: center;
}

.plc-breadcrumbs__link {
    color: var(--pl-muted);
    text-decoration: none;
    transition: color 160ms ease;
    padding: 0.15rem 0;
}

.plc-breadcrumbs__link:hover {
    color: var(--pl-brand);
}

.plc-breadcrumbs__sep {
    color: var(--pl-line);
    margin: 0 0.4rem;
    user-select: none;
}

.plc-breadcrumbs__item--current span {
    color: var(--pl-ink);
    font-weight: 600;
}

/* ========== Заголовок страницы ========== */
.plc-page-head {
    margin: 0.75rem 0 2rem;
}

.plc-page-head__title {
    font-size: clamp(1.75rem, 3vw, 2.375rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--pl-ink);
    margin: 0 0 0.65rem;
    line-height: 1.15;
}

.plc-page-head__lead {
    max-width: 780px;
    font-size: 1rem;
    line-height: 1.55;
    color: var(--pl-ink-soft);
    margin: 0;
}

.plc-page-head--category {
    margin-bottom: 1.5rem;
}

.plc-page-head__meta {
    margin-top: 0.6rem;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.plc-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.75rem;
    background: var(--pl-brand);
    color: #fff;
    border-radius: 999px;
    font-size: 0.8125rem;
    font-weight: 700;
}

.plc-chip--muted {
    background: var(--pl-bg-soft);
    color: var(--pl-ink);
    border: 1px solid var(--pl-line);
    font-weight: 600;
}

/* ========== Каталог-корень: сетка карточек разделов ========== */
.plc-root-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.25rem;
}

.plc-root-card {
    display: flex;
    flex-direction: column;
    background: transparent;
    padding: 1.25rem 0;
    position: relative;
}

.plc-root-card__head {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.plc-root-card__icon {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    background-color: var(--pl-brand);
    -webkit-mask: var(--pl-cat-icon, none) no-repeat center / contain;
            mask: var(--pl-cat-icon, none) no-repeat center / contain;
}

.plc-root-card__title {
    flex: 1;
    margin: 0;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--pl-ink);
    letter-spacing: -0.01em;
    min-width: 0;
}

.plc-root-card__title-link {
    color: inherit;
    text-decoration: none;
    transition: color 160ms ease;
}

.plc-root-card__title-link:hover {
    color: var(--pl-brand);
}

.plc-root-card__list {
    list-style: none;
    padding: 0;
    margin: 0 0 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.28rem;
    flex: 1;
}

.plc-root-card__list li a {
    color: var(--pl-ink-soft);
    text-decoration: none;
    font-size: 0.875rem;
    line-height: 1.4;
    transition: color 160ms ease;
    position: relative;
    z-index: 2;
}

.plc-root-card__list li a:hover {
    color: var(--pl-brand);
}


/* ========== Сайдбар: Навигация (подкатегории) + Заголовки секций ========== */
.plc-nav {
    margin-bottom: 0.5rem;
}

.plc-nav__title,
.plc-sidebar__section-title {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--pl-muted);
    margin: 0 0 0.75rem;
}

.plc-sidebar__section-title {
    margin: 1.25rem 0 0.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--pl-line);
}

.plc-nav__list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.plc-nav__list a {
    display: block;
    padding: 0.35rem 0;
    font-size: 0.9375rem;
    color: var(--pl-text);
    text-decoration: none;
    transition: color 160ms ease;
    line-height: 1.35;
}

.plc-nav__list a:hover {
    color: var(--pl-brand);
}

/* ========== Лейаут категории: сайдбар + основной блок ========== */
.plc-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2rem;
    align-items: start;
}

/* ========== Sidebar ========== */
.plc-sidebar__inner {
    position: sticky;
    top: calc(var(--pl-header-main-h) + 16px);
    display: flex;
    flex-direction: column;
}

.plc-applied {
    padding: 0 0 1rem;
    border-bottom: 1px solid var(--pl-line-soft);
    margin-bottom: 0.5rem;
}

.plc-applied[hidden] {
    display: none;
}

.plc-applied__list {
    list-style: none;
    padding: 0;
    margin: 0.5rem 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

/* === Фильтры — плоский стиль, без карточек-боксов === */
.plc-facet {
    border-bottom: 1px solid var(--pl-line-soft);
}

.plc-facet:last-of-type {
    border-bottom: 0;
}

.plc-facet details {
    margin: 0;
}

.plc-facet summary,
.plc-facet__title {
    padding: 0.85rem 0;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--pl-ink);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    user-select: none;
    margin: 0;
}

.plc-facet summary::-webkit-details-marker { display: none; }

.plc-facet summary::after {
    content: '';
    width: 8px;
    height: 8px;
    border-right: 1.5px solid var(--pl-muted);
    border-bottom: 1.5px solid var(--pl-muted);
    transform: rotate(45deg);
    transition: transform 180ms ease;
    margin-left: 0.5rem;
    flex-shrink: 0;
}

.plc-facet details[open] summary::after {
    transform: rotate(-135deg);
}

.plc-facet__head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
}

.plc-facet__clear {
    border: 0;
    background: transparent;
    color: var(--pl-brand);
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    padding: 0;
}

.plc-facet__count {
    color: var(--pl-muted);
    font-weight: 500;
    font-size: 0.8125rem;
    margin-left: 0.35rem;
}

.plc-facet__body {
    padding: 0 0 1rem;
}

.plc-facet__empty {
    padding: 0.5rem 0;
    color: var(--pl-muted);
    font-size: 0.8125rem;
}

.plc-facet__list {
    list-style: none;
    padding: 0;
    margin: 0.5rem 0 0;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    max-height: 240px;
    overflow-y: auto;
}

/* Range (цена) */
.plc-range {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.plc-range__field {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.45rem 0.6rem;
    background: var(--pl-bg-soft);
    border-radius: 8px;
    border: 1px solid transparent;
    transition: border-color 160ms ease;
}

.plc-range__field:focus-within {
    background: #fff;
    border-color: var(--pl-ink);
}

.plc-range__field span {
    font-size: 0.75rem;
    color: var(--pl-muted);
}

.plc-range__field input {
    width: 100%;
    border: 0;
    background: transparent;
    outline: none;
    font-size: 0.875rem;
    font-family: inherit;
    min-width: 0;
    color: var(--pl-text);
}

.plc-range__hint {
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: var(--pl-muted);
}

/* Чекбоксы */
.plc-check label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.875rem;
    color: var(--pl-text);
    padding: 0.2rem 0;
    transition: color 140ms ease;
    position: relative;
}

.plc-check input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.plc-check__box {
    width: 16px;
    height: 16px;
    border: 1.5px solid var(--pl-line);
    border-radius: 4px;
    flex-shrink: 0;
    background: #fff;
    position: relative;
    transition: all 160ms ease;
}

.plc-check input:checked + .plc-check__box {
    background: var(--pl-brand);
    border-color: var(--pl-brand);
}

.plc-check input:checked + .plc-check__box::after {
    content: '';
    position: absolute;
    left: 4px;
    top: 1px;
    width: 4px;
    height: 8px;
    border-right: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(45deg);
}

.plc-check__label {
    flex: 1;
    min-width: 0;
    line-height: 1.4;
}

.plc-check label:hover .plc-check__label {
    color: var(--pl-brand);
}

/* === Color swatches (фасет «Цвет») === */
.plc-swatches {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    max-height: 260px;
    overflow-y: auto;
}

.plc-swatch {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    cursor: pointer;
    padding: 0.3rem 0;
    font-size: 0.9rem;
    color: var(--pl-text);
    transition: color 140ms ease;
    position: relative;
}

.plc-swatch input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.plc-swatch__dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    flex-shrink: 0;
    border: 1px solid rgba(15, 23, 42, 0.12);
    box-shadow: inset 0 0 0 2px #fff;
    transition: box-shadow 180ms ease, transform 180ms ease;
}

.plc-swatch input:checked + .plc-swatch__dot {
    box-shadow: inset 0 0 0 2px #fff, 0 0 0 2px var(--pl-brand);
    transform: scale(1.05);
}

.plc-swatch:hover .plc-swatch__label {
    color: var(--pl-brand);
}

.plc-swatch__label {
    flex: 1;
    min-width: 0;
    line-height: 1.4;
}

/* === Pills (фасет «Материал» и т. п.) === */
.plc-pills {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    max-height: 260px;
    overflow-y: auto;
}

.plc-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    border: 1.5px solid var(--pl-line);
    border-radius: 999px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--pl-ink);
    cursor: pointer;
    transition: all 160ms ease;
    position: relative;
    background: #fff;
}

.plc-pill input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.plc-pill:hover {
    border-color: var(--pl-ink);
}

.plc-pill:has(input:checked) {
    background: var(--pl-brand);
    border-color: var(--pl-brand);
    color: #fff;
}

/* Кнопки фильтров */
.plc-filters__actions {
    display: flex;
    gap: 0.5rem;
    flex-direction: column;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--pl-line-soft);
}

.plc-btn {
    padding: 0.7rem 1rem;
    border-radius: 9px;
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 180ms ease;
    font-family: inherit;
    border: 1.5px solid transparent;
}

.plc-btn--primary {
    background: var(--pl-brand);
    color: #fff;
    box-shadow: 0 3px 10px rgba(254, 46, 70, 0.2);
}

.plc-btn--primary:hover {
    background: var(--pl-brand-dark);
    transform: translateY(-1px);
}

.plc-btn--ghost {
    background: transparent;
    color: var(--pl-ink);
    border-color: var(--pl-line);
}

.plc-btn--ghost:hover {
    border-color: var(--pl-ink);
}

.plc-btn--block {
    width: 100%;
}

/* ========== Main area ========== */
.plc-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.75rem 0;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--pl-line-soft);
    flex-wrap: wrap;
}

.plc-toolbar__counter {
    font-size: 0.875rem;
    color: var(--pl-muted);
}

.plc-toolbar__counter span {
    color: var(--pl-ink);
    font-weight: 600;
}

.plc-sort {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.plc-sort__label {
    color: var(--pl-muted);
}

.plc-sort__select {
    padding: 0.5rem 2rem 0.5rem 0.75rem;
    border: 1px solid var(--pl-line);
    border-radius: 8px;
    background: #fff url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>") no-repeat right 0.5rem center / 16px;
    font-family: inherit;
    font-size: 0.875rem;
    color: var(--pl-ink);
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
}

.plc-sort__select:focus {
    outline: 2px solid var(--pl-ink);
    outline-offset: 2px;
}

/* ============================================================
   Сетка товаров + карточка товара
   ============================================================ */
.plc-products {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
}

@media (max-width: 1200px) {
    .plc-products { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
    .plc-products { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
    .plc-products { grid-template-columns: 1fr; }
}

/* Внутренняя раскладка: колонка миниатюр (слева, фиксированная ширина) +
   правая колонка (фото + текст). Бейдж растянут на обе колонки.
   Колонка миниатюр всегда зарезервирована, чтобы фото всех карточек
   было одной ширины, даже если у товара нет вариаций. */
.plc-product {
    position: relative;
    display: grid;
    grid-template-columns: 56px 1fr;
    column-gap: 0.55rem;
    row-gap: 0.5rem;
    padding: 1rem 1rem 1.25rem;
    background: transparent;
    z-index: 1;
}

.plc-product__badge {
    grid-column: 1 / -1;
}

.plc-product__thumbs {
    grid-column: 1;
    align-self: start;
}

.plc-product__main {
    grid-column: 2;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    min-width: 0;
}


/* Невидимый фон-«надставка»: на hover он появляется, ниже карточки —
   чтобы actions легли поверх соседей, а не сдвигали грид вниз. */
.plc-product::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    border-radius: 12px;
    opacity: 0;
    transition: opacity 200ms ease, bottom 260ms ease, box-shadow 260ms ease;
    z-index: -1;
    pointer-events: none;
}

.plc-product:hover {
    z-index: 3;
}

.plc-product:hover::before {
    opacity: 1;
    bottom: -110px;
    box-shadow: 0 18px 36px -14px rgba(15, 23, 42, 0.18),
                0 8px 18px -10px rgba(15, 23, 42, 0.08);
}

/* Бейдж «возможно брендирование» */
.plc-product__badge {
    align-self: flex-start;
    font-size: 0.7rem;
    padding: 0.3rem 0.6rem;
    background: #fff;
    border: 1px solid var(--pl-line);
    border-radius: 6px;
    color: var(--pl-ink-soft);
    margin-bottom: 0.25rem;
}

/* Колонка миниатюр — вертикальный стек; при hover карточки «расползается»
   по колонкам вправо, показывая все вариации. */
/* Колонка миниатюр — простой вертикальный стек, 4 штуки максимум + «+N» */
.plc-product__thumbs {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    width: 48px;
}

.plc-product__thumb {
    width: 48px;
    height: 48px;
    border-radius: 6px;
    overflow: hidden;
    border: 0;
    outline: 0;
    background: transparent;
    padding: 0;
    cursor: pointer;
    position: relative;
    display: block;
    opacity: 0.55;
    transition: opacity 160ms ease, transform 160ms ease;
}

.plc-product__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.plc-product__thumb:hover {
    opacity: 1;
}

.plc-product__thumb--active {
    opacity: 1;
}

/* +N для товаров с более чем 4 вариациями */
.plc-product__thumbs-more {
    width: 48px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--pl-muted);
    text-align: center;
}

/* Основное фото */
.plc-product__media {
    aspect-ratio: 1 / 1;
    background: transparent;
    border: 0;
    padding: 0;
    cursor: pointer;
    display: block;
    width: 100%;
    overflow: hidden;
    border-radius: 8px;
    text-decoration: none;
}

.plc-product__img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    display: block;
}


/* Название товара */
.plc-product__name {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--pl-ink);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.4;
    min-height: 2.5em;
    transition: color 160ms ease;
    margin-top: 0.25rem;
}

.plc-product__name:hover {
    color: var(--pl-brand);
}

/* Цена */
.plc-product__price-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 0.15rem;
}

.plc-product__price-label {
    font-size: 0.8125rem;
    color: var(--pl-muted);
}

.plc-product__price {
    font-size: 1.125rem;
    font-weight: 800;
    color: var(--pl-ink);
    letter-spacing: -0.01em;
    line-height: 1.15;
}

/* Артикул */
.plc-product__article {
    font-size: 0.8125rem;
    color: var(--pl-muted);
    margin-top: 0.15rem;
}

/* Блок остатков */
.plc-product__stock {
    font-size: 0.8125rem;
    color: var(--pl-muted);
    display: flex;
    flex-direction: column;
    gap: 1px;
    line-height: 1.45;
    margin-top: 0.2rem;
}

.plc-product__stock span {
    color: var(--pl-ink);
    font-weight: 600;
}

/* Hover-действия: абсолютное позиционирование снизу карточки
   — не расширяют её высоту, не сдвигают грид. Поверх соседних карточек
   благодаря высокому z-index у .plc-product:hover. */
.plc-product__actions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    padding: 0.5rem 1rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    opacity: 0;
    transform: translateY(-4px);
    pointer-events: none;
    transition: opacity 220ms ease, transform 220ms ease;
}

.plc-product:hover .plc-product__actions {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.plc-product__cart,
.plc-product__view {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.7rem 1rem;
    border: 0;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 160ms ease, color 160ms ease, border-color 160ms ease;
    width: 100%;
    text-decoration: none;
    box-sizing: border-box;
}

.plc-product__cart svg,
.plc-product__view svg {
    width: 16px;
    height: 16px;
}

/* Основное действие — брендовый красный */
.plc-product__cart {
    background: var(--pl-brand);
    color: #fff;
    box-shadow: 0 3px 10px rgba(254, 46, 70, 0.2);
}

.plc-product__cart:hover {
    background: var(--pl-brand-dark);
}

/* Вторичное — обведённая кнопка в бренд-палитре */
.plc-product__view {
    background: transparent;
    color: var(--pl-brand);
    border: 1.5px solid var(--pl-brand);
    padding: calc(0.7rem - 1.5px) calc(1rem - 1.5px);
}

.plc-product__view:hover {
    background: var(--pl-brand);
    color: #fff;
}

/* ============================================================
   QUICKVIEW modal
   ============================================================ */
.plc-quickview {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    overflow-y: auto;
}

.plc-quickview[hidden] { display: none; }

.plc-quickview__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    opacity: 0;
    transition: opacity 220ms ease;
}

.plc-quickview[aria-hidden="false"] .plc-quickview__backdrop {
    opacity: 1;
}

.plc-quickview__panel {
    position: relative;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 24px 64px rgba(15, 23, 42, 0.18);
    max-width: 900px;
    width: 100%;
    max-height: calc(100vh - 4rem);
    overflow: hidden;
    opacity: 0;
    transform: translateY(12px) scale(0.98);
    transition: opacity 240ms ease, transform 240ms cubic-bezier(0.2, 0.9, 0.3, 1);
}

.plc-quickview[aria-hidden="false"] .plc-quickview__panel {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.plc-quickview__close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 36px;
    height: 36px;
    border: 0;
    background: rgba(255, 255, 255, 0.9);
    color: var(--pl-ink);
    border-radius: 50%;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 160ms ease;
    z-index: 2;
}

.plc-quickview__close svg { width: 20px; height: 20px; }

.plc-quickview__close:hover {
    background: #fff;
    color: var(--pl-brand);
}

.plc-quickview__body {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 0;
    max-height: calc(100vh - 4rem);
}

/* Левая колонка: изображение */
.plc-quickview__media {
    padding: 1.5rem;
    background: var(--pl-bg-soft);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 380px;
}

.plc-quickview__img {
    width: 100%;
    flex: 1;
    object-fit: contain;
    max-height: 440px;
    min-height: 0;
}

.plc-quickview__thumbs {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.plc-quickview__thumb {
    width: 52px;
    height: 52px;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid transparent;
    background: #fff;
    cursor: pointer;
    padding: 0;
    transition: border-color 180ms ease;
}

.plc-quickview__thumb--active {
    border-color: var(--pl-brand);
}

.plc-quickview__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Правая колонка: инфо и действия */
.plc-quickview__info {
    padding: 2rem 2rem 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
}

.plc-quickview__title {
    margin: 0;
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--pl-ink);
    letter-spacing: -0.01em;
    line-height: 1.25;
}

.plc-quickview__article {
    font-size: 0.8125rem;
    color: var(--pl-muted);
}

.plc-quickview__price-row {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    flex-wrap: wrap;
}

.plc-quickview__price {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--pl-ink);
    letter-spacing: -0.01em;
}

.plc-quickview__stock {
    font-size: 0.875rem;
    color: var(--pl-muted);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.plc-quickview__stock::before {
    content: '';
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--pl-muted);
}

.plc-quickview__stock--in {
    color: #16a34a;
}

.plc-quickview__stock--in::before {
    background: #16a34a;
}

.plc-quickview__label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--pl-muted);
    margin-bottom: 0.4rem;
}

/* Swatches в модалке (более крупные) */
.plc-quickview__variations[hidden] { display: none; }

.plc-quickview__swatches {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    max-height: 200px;
    overflow-y: auto;
}

.plc-quickview__swatch {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.45rem 0.6rem;
    background: transparent;
    border: 1.5px solid var(--pl-line);
    border-radius: 10px;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
    transition: border-color 160ms ease;
}

.plc-quickview__swatch:hover {
    border-color: var(--pl-ink);
}

.plc-quickview__swatch--active {
    border-color: var(--pl-brand);
    background: rgba(254, 46, 70, 0.03);
}

.plc-quickview__swatch-dot {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1px solid rgba(15, 23, 42, 0.12);
    box-shadow: inset 0 0 0 2px #fff;
    flex-shrink: 0;
}

.plc-quickview__swatch-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.875rem;
    color: var(--pl-ink);
    font-weight: 500;
    line-height: 1.2;
}

.plc-quickview__swatch-info small {
    color: var(--pl-muted);
    font-size: 0.75rem;
    font-weight: 400;
}

/* Stepper */
.plc-quickview__stepper {
    display: inline-flex;
    align-items: stretch;
    border: 1.5px solid var(--pl-line);
    border-radius: 10px;
    overflow: hidden;
    width: fit-content;
}

.plc-quickview__step {
    width: 40px;
    height: 40px;
    background: transparent;
    border: 0;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--pl-ink);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 140ms ease;
    font-family: inherit;
}

.plc-quickview__step:hover {
    background: var(--pl-bg-soft);
}

.plc-quickview__step-input {
    width: 56px;
    border: 0;
    border-left: 1.5px solid var(--pl-line);
    border-right: 1.5px solid var(--pl-line);
    text-align: center;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    color: var(--pl-ink);
    background: #fff;
    appearance: textfield;
    -moz-appearance: textfield;
}
.plc-quickview__step-input::-webkit-outer-spin-button,
.plc-quickview__step-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.plc-quickview__step-input:focus {
    outline: 2px solid var(--pl-ink);
    outline-offset: -2px;
}

/* Actions */
.plc-quickview__actions {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-top: auto;
    padding-top: 0.25rem;
}

.plc-quickview__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.95rem 1.5rem;
    background: var(--pl-brand);
    color: #fff;
    border: 0;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.9375rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(254, 46, 70, 0.22);
    transition: all 200ms ease;
}

.plc-quickview__cta svg { width: 18px; height: 18px; }

.plc-quickview__cta:hover:not(:disabled) {
    background: var(--pl-brand-dark);
    transform: translateY(-1px);
}

.plc-quickview__cta:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.plc-quickview__link {
    font-size: 0.875rem;
    color: var(--pl-ink-soft);
    text-decoration: none;
    text-align: center;
}

.plc-quickview__link:hover {
    color: var(--pl-brand);
}

.plc-quickview__result {
    margin-top: 0.25rem;
    padding: 0.7rem 1rem;
    border-radius: 9px;
    font-size: 0.875rem;
}

.plc-quickview__result--success {
    background: rgba(22, 163, 74, 0.08);
    color: #166534;
    border: 1px solid rgba(22, 163, 74, 0.2);
}

.plc-quickview__result--error {
    background: rgba(254, 46, 70, 0.08);
    color: var(--pl-brand-dark);
    border: 1px solid rgba(254, 46, 70, 0.2);
}

/* Skeleton-ы */
.plc-skeleton {
    background: linear-gradient(90deg, #f1f3f7 0%, #fafbfc 50%, #f1f3f7 100%);
    background-size: 200% 100%;
    animation: plc-shimmer 1.6s ease-in-out infinite;
    border-radius: 6px;
}

.plc-skeleton--line {
    height: 14px;
    width: 85%;
}

.plc-skeleton--short {
    width: 55%;
}

.plc-skeleton--price {
    height: 18px;
    width: 40%;
    margin-top: 0.25rem;
}

@keyframes plc-shimmer {
    0%   { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

/* Пагинация */
.plc-pagination {
    margin-top: 2rem;
    display: flex;
    justify-content: center;
    gap: 0.35rem;
    flex-wrap: wrap;
    align-items: center;
}

.plc-pagination:empty {
    display: none;
}

.plc-pagination__btn {
    min-width: 36px;
    height: 36px;
    padding: 0 0.65rem;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid var(--pl-line);
    color: var(--pl-ink);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 160ms ease;
}

.plc-pagination__btn:hover {
    border-color: var(--pl-ink);
}

.plc-pagination__btn--active {
    background: var(--pl-ink);
    border-color: var(--pl-ink);
    color: #fff;
}

.plc-pagination__dots {
    padding: 0 0.35rem;
    color: var(--pl-muted);
    font-size: 0.875rem;
}

/* Пусто */
.plc-empty {
    padding: 4rem 1rem;
    text-align: center;
    color: var(--pl-muted);
    font-size: 1rem;
}

/* ========== Адаптивность ========== */
@media (max-width: 960px) {
    .plc-layout {
        grid-template-columns: 1fr;
    }
    .plc-sidebar__inner {
        position: static;
    }
    .plc-subcats {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.25rem;
        scrollbar-width: thin;
    }
    .plc-subcat {
        flex-shrink: 0;
    }
}

@media (max-width: 760px) {
    .plc-quickview__body {
        grid-template-columns: 1fr;
        max-height: none;
    }
    .plc-quickview__media {
        min-height: 260px;
    }
    .plc-quickview__info {
        padding: 1.25rem 1.25rem 1.5rem;
    }
}

@media (max-width: 640px) {
    .plc-page {
        padding: 1.25rem 0 3rem;
    }
    .plc-root-grid {
        grid-template-columns: 1fr;
    }
    .plc-products {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    .plc-toolbar {
        gap: 0.5rem;
    }
    .plc-sort__label {
        display: none;
    }
}

@media (max-width: 420px) {
    .plc-products {
        grid-template-columns: 1fr;
    }
}
