/* Магазин ВОИР (ТК shop): каталог и страница товара.
   По прототипу voir-shop-original/shop.css, очищено от !important-оверрайдов. */

/* ===== Каталог ===== */
.shop-page {
    padding-bottom: 80px;
}

.shop-kicker {
    color: #0986f9;
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 10px;
}

.shop-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 30px;
}

.shop-count {
    color: #8fa3ad;
    padding-bottom: 10px;
    white-space: nowrap;
}

.shop-toolbar {
    display: grid;
    grid-template-columns: auto minmax(240px, 1fr) auto;
    gap: 16px;
    margin: 25px 0 32px;
}

.shop-filter-toggle {
    display: none;
}

.shop-search {
    border: 1px solid rgba(32, 46, 143, .14);
    border-radius: 18px;
    display: flex;
    align-items: center;
    padding: 0 18px;
    min-height: 56px;
    background: #fff;
    cursor: text;
}

.shop-search .icon {
    width: 18px;
    height: 18px;
    color: #202e8f;
    margin-right: 12px;
    flex: none;
}

.shop-search input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    font-size: 16px;
}

.shop-select,
.shop-price-row input {
    border: 1px solid rgba(32, 46, 143, .14);
    border-radius: 16px;
    background: #fff;
    padding: 0 16px;
    min-height: 54px;
    color: #202e8f;
}

.shop-layout {
    display: grid;
    grid-template-columns: minmax(240px, 280px) minmax(0, 1fr);
    align-items: start;
    gap: 32px;
}

.shop-filters {
    position: sticky;
    top: 24px;
    background: #fff;
    border: 1px solid rgba(32, 46, 143, .09);
    border-radius: 24px;
    padding: 8px 24px 12px;
    box-shadow: 0 18px 50px rgba(32, 46, 143, .08);
}

.shop-filter-head,
.shop-filter-group {
    padding: 20px 0;
    border-bottom: 1px solid rgba(32, 46, 143, .12);
}

.shop-filter-group:last-child {
    border-bottom: 0;
}

.shop-filter-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.shop-filter-head strong {
    font-size: 20px;
    color: #202e8f;
}

.shop-filter-head button {
    border: 0;
    background: none;
    color: #0986f9;
    padding: 0;
    font-weight: 500;
    cursor: pointer;
}

.shop-filter-title {
    font-weight: 600;
    color: #202e8f;
    margin-bottom: 14px;
}

.shop-filter-group label {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 12px 0;
    cursor: pointer;
    color: #33435f;
}

.shop-cat.__sub {
    padding-left: 22px;
}

.shop-filter-group input[type=checkbox] {
    accent-color: #202e8f;
    width: 17px;
    height: 17px;
    flex: none;
}

.shop-price-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.shop-price-row input {
    min-width: 0;
    min-height: 44px;
}

.shop-results {
    min-width: 0;
}

/* ===== Карточка товара в каталоге ===== */
.shop-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    align-items: stretch;
}

.shop-card {
    position: relative;
    height: 100%;
    min-width: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(32, 46, 143, .08);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 14px 38px rgba(32, 46, 143, .07);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.shop-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 22px 52px rgba(32, 46, 143, .13);
    border-color: rgba(32, 46, 143, .18);
}

.shop-card-image {
    display: block;
    flex: 0 0 150px;
    height: 150px;
    overflow: hidden;
    background: #eef3f6;
    position: relative;
}

.shop-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
}

.shop-card:hover .shop-card-image img {
    transform: scale(1.045);
}

.shop-card-noimage {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: .14em;
    color: rgba(32, 46, 143, .28);
    background: linear-gradient(135deg, #eef3f6 0%, #e2ebf2 100%);
}

.shop-card-content {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    padding: 14px 16px 16px;
    background: #fff;
}

.shop-card-title {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    color: #202e8f;
    font-size: 17px;
    line-height: 1.25;
    font-weight: 600;
    min-height: 42px;
    margin: 0 0 7px;
}

.shop-card-description {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    color: #66758a;
    font-size: 13px;
    line-height: 1.4;
    min-height: 37px;
    margin: 0 0 13px;
}

.shop-card-purchase {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid rgba(32, 46, 143, .1);
}

.shop-card-price {
    display: block;
    color: #202e8f;
    font-size: 21px;
    line-height: 1.05;
    font-weight: 600;
    white-space: nowrap;
}

.shop-card-old-price {
    display: block;
    margin-top: 4px;
    color: #9aa9bc;
    font-size: 14px;
    font-weight: 400;
    white-space: nowrap;
}

.shop-card-meta {
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 12px;
    color: #65748a;
}

.shop-card-meta:before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #26dee0;
    flex: none;
}

.shop-card-meta.is-order:before {
    background: #f0b85d;
}

.shop-card-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 104px;
    height: 40px;
    padding: 0 16px;
    border: 0;
    border-radius: 12px;
    background: #202e8f;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: background .2s ease;
}

.shop-card-button:hover {
    background: #0986f9;
    color: #fff;
}

.shop-empty {
    text-align: center;
    padding: 80px 20px;
}

.shop-breadcrumbs {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    color: #8fa3ad;
    margin-bottom: 30px;
    font-size: 14px;
}

.shop-breadcrumbs a {
    color: #202e8f;
}

/* ===== Страница товара ===== */
.product-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(380px, .9fr);
    gap: 60px;
}

.product-main-image {
    background: #f2f6f8;
    border-radius: 28px;
    overflow: hidden;
    aspect-ratio: 1.08;
    position: relative;
}

.product-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-summary h1 {
    font-size: clamp(36px, 4vw, 62px);
    line-height: 1.02;
}

.product-code {
    color: #8fa3ad;
    margin: 18px 0;
}

.stock-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #26dee0;
}

.stock-dot.is-order {
    background: #f0b85d;
}

.product-lead {
    font-size: 18px;
    line-height: 1.55;
}

.product-price {
    font-size: 40px;
    color: #202e8f;
    font-weight: 600;
    margin: 28px 0;
}

.product-price .shop-card-old-price {
    font-size: 22px;
    margin: 0 0 0 14px;
}

.product-buy {
    display: flex;
    gap: 12px;
    margin-top: 28px;
}

.qty {
    display: flex;
    border: 1px solid rgba(32, 46, 143, .2);
    border-radius: 16px;
    overflow: hidden;
}

.qty button,
.qty input {
    width: 48px;
    border: 0;
    background: #fff;
    text-align: center;
    color: #202e8f;
    font-size: 18px;
    padding: 12px 0;
}

.qty button {
    cursor: pointer;
}

.product-cart {
    flex: 1;
    background: #202e8f;
    color: #fff;
    border: 0;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background .2s ease;
}

.product-cart:hover {
    background: #0986f9;
    color: #fff;
}

.product-note {
    margin-top: 18px;
    color: #8fa3ad;
    font-size: 14px;
}

.product-details {
    margin-top: 80px;
}

.product-tabs {
    display: flex;
    gap: 30px;
    border-bottom: 1px solid rgba(32, 46, 143, .2);
}

.product-tabs button {
    border: 0;
    background: none;
    color: #8fa3ad;
    padding: 0 0 16px;
    font-size: 18px;
    cursor: pointer;
}

.product-tabs button.active {
    color: #202e8f;
    border-bottom: 3px solid #202e8f;
}

.product-tab {
    display: none;
    max-width: 900px;
    padding: 35px 0;
    font-size: 17px;
    line-height: 1.65;
}

.product-tab.active {
    display: block;
}

.product-props-title {
    margin: 30px 0 0;
    color: #202e8f;
}

.spec-table > div {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding: 16px 0;
    border-bottom: 1px solid rgba(32, 46, 143, .15);
}

.product-delivery-list {
    padding-left: 20px;
}

.product-delivery-list li {
    margin: 8px 0;
}

/* ===== Адаптив ===== */
@media (max-width: 1200px) {
    .shop-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .product-layout {
        gap: 35px;
    }
}

@media (max-width: 767px) {
    .shop-heading {
        display: block;
    }

    .shop-toolbar {
        grid-template-columns: 1fr auto;
    }

    .shop-filter-toggle {
        display: block;
    }

    .shop-search {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    .shop-layout {
        display: block;
    }

    .shop-filters {
        position: static;
        display: none;
        margin-bottom: 24px;
    }

    .shop-filters.open {
        display: block;
    }

    .shop-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .shop-card-image {
        height: 165px;
        flex-basis: 165px;
    }

    .product-layout {
        grid-template-columns: 1fr;
    }

    .product-summary h1 {
        font-size: 38px;
    }

    .product-buy {
        flex-direction: column;
    }

    .qty {
        height: 54px;
        justify-content: center;
    }

    .product-tabs {
        overflow: auto;
        gap: 20px;
    }

    .product-tabs button {
        white-space: nowrap;
    }

    .spec-table > div {
        grid-template-columns: 1fr;
    }

    .product-details {
        margin-top: 50px;
    }
}
