/* ==========================================================================
   Like Lombard - Shop Styles (Isolated Public Showcase)
   ========================================================================== */

/* Общий макет витрины */
body.shop-body {
    background-color: #f4f6f9;
    font-family: 'Lato', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #333;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
}

/* Единая ширина контейнера витрины (синхронизировано с Landing 1380px) */
.shop-body .container {
    width: 100% !important;
    max-width: 1380px !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
}

.shop-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.shop-main-content {
    flex: 1 0 auto;
    padding-bottom: 40px;
}

/* Шапка витрины */
.shop-header {
    background: #1f1e2e;
    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
}

.shop-header .nav-top {
    padding: 10px 0;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.shop-header .fav-top-link {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    transition: opacity 0.2s;
}

.shop-header .fav-top-link:hover {
    opacity: 0.85;
    color: #fff;
}

.shop-header .nav-bottom {
    background: #181824;
    padding: 6px 0;
}

.shop-nav {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}

.shop-nav .nav-item {
    margin-right: 5px;
}

.shop-nav .nav-link {
    color: rgba(255,255,255,0.75);
    font-weight: 600;
    font-size: 14px;
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
}

.shop-nav .nav-link:hover {
    color: #fff;
    background: rgba(255,255,255,0.08);
}

.shop-nav .nav-item.active .nav-link {
    color: #1e2035;
    background: #ffda00;
    font-weight: 700;
    box-shadow: none !important;
}

.shop-nav .nav-item.active .nav-link:hover {
    color: #1e2035;
    background: #ffda00;
}

.shop-nav .nav-item.active .nav-link .badge {
    background: #1e2035;
    color: #ffda00;
}

.shop-nav .logo-item a {
    padding: 2px 12px 2px 0;
}

/* Иконка сердца в кнопке Избранного */
.shop-nav .nav-link .fa-heart {
    color: #e66;
    font-size: 15px;
}

.shop-nav .nav-item.active .nav-link .fa-heart {
    color: #1e2035;
}

.shop-nav .logo-item img {
    height: 48px;
    width: auto;
}

/* Липкая панель фильтров */
.card.filters {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #ffffff;
    border-radius: 0 0 10px 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    margin-bottom: 0.5rem;
    border: 1px solid #e9ecef;
    border-top: none;
}

.card.filters .card-body {
    padding: 12px 16px;
}

.cat-as-btn {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    gap: 8px;
    margin-top: 10px;
    padding: 4px 2px 8px 2px;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
}

.cat-as-btn:active {
    cursor: grabbing;
}

.cat-as-btn::-webkit-scrollbar {
    height: 4px;
}

.cat-as-btn::-webkit-scrollbar-track {
    background: transparent;
}

.cat-as-btn::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.cat-as-btn::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.cat-button {
    flex: 0 0 auto;
    font-size: 13px;
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid #343a40 !important;
    background: #212529 !important;
    color: #cbd5e1 !important;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    line-height: 1.4;
    box-shadow: none !important;
}

.cat-button:hover,
.cat-button:focus {
    background: #0284c7 !important;
    border-color: #0284c7 !important;
    color: #ffffff !important;
    box-shadow: none !important;
}

.cat-button.active,
.cat-button.active:hover,
.cat-button.active:focus {
    background: #ffda00 !important;
    border-color: #ffda00 !important;
    color: #1e2035 !important;
    font-weight: 700 !important;
    box-shadow: none !important;
}

.filters .select2-selection {
    height: inherit;
    padding: .25rem 1.75rem .25rem .5rem !important;
    font-size: .875rem !important;
    line-height: 1.5 !important;
}

/* Поле поиска в фильтрах */
.search-box {
    position: relative;
    width: 100%;
}

.search-box .form-control {
    padding-left: 1.8rem !important;
}

.search-box .search-icon {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 13px;
    pointer-events: none;
}

.search-box .btn-clear-search {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    padding: 2px 6px;
}

.search-box .btn-clear-search:hover {
    color: #334155;
}

/* Блок "Ничего не найдено" */
.no-products-found {
    background: #fff;
    border-radius: 10px;
    border: 1px dashed #cbd5e1;
    margin: 20px auto;
    max-width: 500px;
    padding: 40px 20px;
}

.no-products-found i {
    color: #94a3b8;
}

.no-products-found h4 {
    color: #1e293b;
    margin-top: 15px;
    font-size: 18px;
}

.no-products-found p {
    font-size: 14px;
    margin-bottom: 20px;
}

/* Кнопка "Показать ещё" */
.btn-load-more {
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.3px;
    border-radius: 25px;
    padding: 10px 28px !important;
    box-shadow: none !important;
    transition: all 0.2s ease;
}

.btn-load-more:hover {
    transform: translateY(-2px);
    box-shadow: none !important;
}

/* Сетка каталога */
.shop .row {
    margin-left: -6px;
    margin-right: -6px;
}

.product-card {
    padding: 6px;
    display: flex;
}

/* Карточка товара - Flexbox */
.product {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
    height: 100%;
    background: #fff;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    padding: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.03);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.product:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    border-color: #cbd5e1;
}

.product .box-1 {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product .box-2 {
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid #f1f5f9;
}

/* Блок изображений */
.img-block {
    position: relative;
    width: 100%;
    height: 240px;
    overflow: hidden;
    border-radius: 8px;
    background: #f8fafc;
    margin-bottom: 0.25rem;
}

.img-block img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.swiper {
    width: 100%;
    height: 100%;
}

.swiper .swiper-wrapper {
    height: 100%;
}

.swiper-pagination-bullet {
    background: #fff;
    opacity: 0.7;
}

.swiper-pagination-bullet-active {
    background: #0284c7;
    opacity: 1;
}

/* Информация о товаре */
.product .name {
    font-weight: 600;
    font-size: 15px;
    line-height: 20px;
    color: #1e293b;
}

.product .name p {
    margin-bottom: 4px;
}

.product .name span {
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    background: #f1f5f9;
    color: #475569;
    display: inline-block;
}

.product .name span.red {
    color: #dc2626;
    background: #fee2e2;
}

.product .charac {
    margin: 6px 0 10px;
    font-size: 13px;
    line-height: 18px;
    color: #334155;
}

.product .charac p {
    margin: 0 0 3px;
}

.product .price_text {
    margin: 6px 0 10px;
    font-size: 14px;
    p {
        margin-bottom: 0;
    }
}

.product .prices {
    padding: 0;
    margin: 4px 0 0;
    list-style: none;
    font-size: 13px;
}

.product .prices li {
    margin-bottom: 2px;
}

.blue_ {
    color: #0284c7;
    font-weight: 700;
}

.text-muted {
    color: #94a3b8;
}

/* Сервисная инфо-строка */
.product .info {
    font-size: 11px;
    color: #64748b;
    margin: 0 0 8px;
    font-weight: 500;
}

/* Панель иконок действий */
.actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

/* Гарантия вертикального прямого начертания иконок (защита от курсива тега <i>) */
.fa, .fas, .far, .fab, .fal {
    font-style: normal !important;
}

.actions a {
    font-size: 20px;
    color: #64748b;
    cursor: pointer;
    text-decoration: none;
    padding: 2px 6px;
    transition: color 0.15s ease, transform 0.15s ease;
}

.actions a:hover {
    color: #0284c7;
    transform: scale(1.1);
}

.actions a.wh {
    color: #25d366;
    font-size: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.actions a.wh:hover {
    color: #128c7e;
    transform: scale(1.15);
}

.go_wa {
    color: #25d366;
    font-size: 32px;
    vertical-align: middle;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: color 0.15s ease, transform 0.15s ease;
}

.go_wa:hover {
    color: #128c7e;
    transform: scale(1.1);
}

.text-whatsapp {
    color: #25d366;
    font-size: 24px;
    vertical-align: middle;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: color 0.15s ease, transform 0.15s ease;
}

.text-whatsapp:hover {
    color: #128c7e;
    transform: scale(1.15);
}

.heart-f .fas {
    display: none;
    color: #0284c7;
}

.heart-f.is-active .fas {
    display: inline-block;
}

.heart-f.is-active .far {
    display: none;
}

/* Кнопки рассрочки и себестоимости в карточках товаров */
.action {
    display: flex;
    gap: 6px;
    align-items: stretch;
    width: 100%;
}

.action .btn {
    flex: 1 1 0;
    width: 100%;
    min-width: 0;
    font-size: 11.5px;
    font-weight: 600;
    padding: 6px 4px;
    border-radius: 6px;
    letter-spacing: 0.1px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    white-space: normal;
    word-break: normal;
    line-height: 1.2;
    margin-top: 0 !important;
}

.btn-info {
    background-color: #0284c7;
    border-color: #0284c7;
    color: #fff;
    box-shadow: none !important;
}

.btn-info:hover {
    background-color: #0369a1;
    border-color: #0369a1;
    color: #fff;
    box-shadow: none !important;
}

.btn-info:focus,
.btn-info:active {
    box-shadow: none !important;
}

/* Блоки тарифов подписки и оферты */
.tab_info {
    width: 100%;
    margin: 15px 0;
    border-collapse: collapse;
}

.tab_info tr td {
    padding: 10px;
    border: 1px solid #e2e8f0;
    font-size: 13px;
}

.tab_info tr:first-child {
    font-weight: bold;
    background: #f8fafc;
}

.div_info {
    display: none;
    margin: 15px 0;
}

.tarfi_b {
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 12px;
    background: #fff;
}

.tarfi_b h2 {
    font-size: 16px;
    text-align: center;
    margin: 0 0 8px;
}

.tarfi_b .t_list {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    margin-bottom: 6px;
}

.tarfi_b .t_list .t_name {
    color: #64748b;
}

.tarfi_b .t_list .t_value {
    font-weight: 600;
}

/* Подвал витрины */
.shop-footer {
    background: #181824;
    color: rgba(255,255,255,0.7);
    padding: 20px 0;
    font-size: 13px;
    margin-top: auto;
}

.shop-footer a {
    color: #38bdf8;
    text-decoration: none;
}

/* Адаптивность для смартфонов (до 767px) */
@media only screen and (max-width: 767px) {
    .product-card {
        width: 50%;
        padding: 4px;
    }

    .product {
        padding: 8px;
        border-radius: 8px;
    }

    .img-block {
        height: 140px;
        border-radius: 6px;
        margin-bottom: 8px;
    }

    .product .name {
        font-size: 12px;
        line-height: 16px;
        margin-bottom: 6px;
    }

    .product .name span {
        font-size: 10px;
        padding: 2px 4px;
    }

    .product .charac {
        font-size: 11px;
        line-height: 15px;
        margin-bottom: 6px;
    }

    .product .prices li {
        font-size: 11px;
    }

    .product .info {
        font-size: 9px;
        margin-bottom: 6px;
    }

    .actions a {
        font-size: 16px;
    }

    .actions a.wh {
        font-size: 18px;
    }

    .action {
        gap: 4px;
    }

    .action .btn {
        font-size: 10px;
        padding: 5px 3px;
        line-height: 1.15;
    }

    .tab_info {
        display: none;
    }

    .div_info {
        display: block;
    }

    .card.filters {
        border-radius: 0;
    }

    /* Отступы между фильтрами на мобилке */
    .card.filters .card-body .row > [class*="col-"] {
        margin-bottom: 8px;
    }

    .card.filters .card-body .row > [class*="col-"]:last-child {
        margin-bottom: 0;
    }

    /* На мобилке в кнопке Избранное показываем только иконку */
    .fav-nav-text {
        display: none;
    }
}
