/* ===== ПЕРЕМЕННЫЕ ===== */
:root {
    --main-color: #d2100f;
    --main-color-hover: #b80e0d;
    --main-color-rgb: 210, 16, 15;
    --light-color: #e00100;
    --text-color: #252525;
    --dark-grey-color: #474747;
    --grey-color: #6c757d;
    --light-grey: #f1f3f5;
    --border-color: #e9ecef;
    --border-dark: #dee2e6;
    --white: #ffffff;
    --success-color: #198754;
    --success-hover: #157347;
    --danger-color: #dc3545;
    --danger-hover: #bb2d3b;
    --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 20px 60px rgba(0, 0, 0, 0.3);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: 0.2s ease;
}

.new-catalog-wrapper {
    padding-top: 80px;
}

/* .catalog {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 15px;
    width: 100%;
} */

.catalog__title {
    margin-top: 0;
    margin-bottom: 24px;
    font-size: 24px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    color: var(--text-color);
}

.catalog__title .cart-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.catalog__title .favorites-count {
    font-size: 14px;
    font-weight: 400;
    color: var(--grey-color);
    background: var(--light-grey);
    padding: 4px 12px;
    border-radius: 20px;
}

.catalog__title .favorites-count span {
    color: var(--danger-color);
    font-weight: 600;
}

.catalog__title .cart-button {
    font-size: 14px;
    font-weight: 500;
    color: var(--white);
    background: var(--main-color);
    padding: 6px 16px;
    border-radius: 20px;
    border: none;
    cursor: pointer;
    transition: background var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
}

.catalog__title .cart-button:hover {
    background: var(--main-color-hover);
}

.catalog__title .cart-button .cart-badge {
    background: rgba(255, 255, 255, 0.25);
    padding: 0px 8px;
    border-radius: 12px;
    font-size: 12px;
}

/* Вкладки */
.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 16px;
}

.tab {
    padding: 8px 20px;
    border-radius: 20px;
    background: var(--light-grey);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    border: none;
    transition: all 0.25s ease;
    color: var(--dark-grey-color);
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    position: relative;
}

.tab:hover {
    background: var(--border-color);
    transform: translateY(-1px);
}

.tab--active {
    background: var(--main-color);
    color: var(--white);
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(var(--main-color-rgb), 0.3);
}

.tab--active:hover {
    background: var(--main-color);
    color: var(--white);
    transform: translateY(0);
    cursor: default;
}

.tab--favorite {
    position: relative;
}

.tab--favorite .badge {
    background: var(--danger-color);
    color: var(--white);
    font-size: 11px;
    font-weight: 600;
    padding: 1px 8px;
    border-radius: 12px;
    margin-left: 4px;
}

.tab--active .badge {
    background: rgba(255, 255, 255, 0.3);
}

.tab__heart {
    display: inline-block;
    width: 16px;
    height: 16px;
}

.tab__heart .heart-path {
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
}

.tab--active .tab__heart .heart-path {
    fill: var(--white);
}

.tab__unit {
    font-size: 11px;
    font-weight: 400;
    opacity: 0.7;
    margin-left: 2px;
}

.tab--active .tab__unit {
    opacity: 1;
}

/* Таблица - десктопная версия */
.table-wrapper {
    overflow-x: auto;
    opacity: 0;
    animation: fadeInContent 0.75s ease forwards;
}

.product-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.product-table th {
    background: #f8f9fa;
    color: var(--dark-grey-color);
    font-weight: 600;
    padding: 12px 10px;
    text-align: left;
    border-bottom: 2px solid var(--border-dark);
    white-space: nowrap;
}

.product-table td {
    padding: 10px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.product-table tr:hover td {
    background-color: #f8f9fa;
}

.product-table tr.favorite-row td {
    background-color: #fff5f5;
}

.product-table tr.favorite-row:hover td {
    background-color: #ffebeb;
}

/* Заголовок категории в таблице */
.category-header td {
    background-color: var(--border-color) !important;
    font-weight: 600;
    padding: 10px 10px;
    border-bottom: 2px solid #ced4da;
    color: var(--text-color);
}

.category-header td:hover {
    background-color: var(--border-color) !important;
}

.category-header .category-name {
    font-size: 15px;
}

.category-header .category-unit {
    font-size: 13px;
    font-weight: 400;
    color: var(--dark-grey-color);
    margin-left: 8px;
    background: var(--border-dark);
    padding: 1px 10px;
    border-radius: 12px;
}

.category-header .category-count {
    font-size: 12px;
    font-weight: 400;
    color: var(--grey-color);
    margin-left: 8px;
}

/* Цены в таблице */
.price-cell {
    white-space: nowrap;
}

.price-base {
    font-weight: 600;
    color: var(--main-color);
}

.price-discount {
    color: var(--success-color);
}

.price-list {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 12px;
}

.price-item {
    font-size: 14px;
}

.price-item .label {
    color: var(--grey-color);
    font-size: 11px;
}


@media (min-width: 768px) {
    .price-item {
        font-size: 12px;
    }
}

/* Кнопки действий */
.action-cell {
    white-space: nowrap;
    text-align: center;
    min-width: 90px;
}




.btn {
	/* display: inline-flex; */
	/* align-items: center; */
	/* justify-content: center; */
	/* padding: 6px 12px; */
	border: none;
	border-radius: 6px;
	font-size: 13px;
	font-weight: 500;
	cursor: pointer;
	/* transition: all var(--transition); */
	/* background: var(--border-color); */
	/* color: var(--dark-grey-color); */
}

/* .btn:hover {
    background: var(--border-dark);
}

.btn--primary {
    background: var(--main-color);
    color: var(--white);
}

.btn--primary:hover {
    background: var(--main-color-hover);
} */

/* .btn--success {
    background: var(--success-color);
    color: var(--white);
}

.btn--success:hover {
    background: var(--success-hover);
}
 */
.btn--favorite {
    background: none;
    padding: 4px 8px;
    margin-right: 4px;
    transition: transform var(--transition);
}

.btn--favorite:hover {
    background: var(--light-grey);
    transform: scale(1.1);
}

.btn--favorite svg {
    display: block;
    width: 20px;
    height: 20px;
}

.btn--favorite .heart-path {
    fill: none;
    stroke: var(--danger-color);
    stroke-width: 2;
    transition: fill var(--transition);
}

.btn--favorite.is-favorite .heart-path {
    fill: var(--danger-color);
}

.btn--favorite.is-favorite:hover .heart-path {
    fill: var(--danger-color);
    opacity: 0.7;
}

/* Кнопка "В корзине" */
.btn--in-cart {
    background: var(--success-color);
    color: var(--white);
    gap: 4px;
    padding: 6px 10px;
}

.btn--in-cart:hover {
    background: var(--success-hover);
}

.btn--in-cart .cart-qty {
    background: rgba(255, 255, 255, 0.25);
    padding: 0px 6px;
    border-radius: 4px;
    font-size: 11px;
}

/* Пустое состояние */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--grey-color);
    animation: fadeInContent 0.35s ease-in-out forwards;
    opacity: 0;
}

.empty-state svg {
    width: 64px;
    height: 64px;
    margin-bottom: 16px;
    opacity: 0.3;
}

.empty-state h3 {
    margin: 0 0 8px 0;
    color: var(--text-color);
}

.empty-state p {
    margin: 0;
    font-size: 16px;
}

.loading,
.error {
    text-align: center;
    padding: 40px;
    font-size: 18px;
    color: var(--grey-color);
}

.error {
    color: var(--danger-color);
}

/* ============================================================ */
/* КОРЗИНА (ПОПАП) */
/* ============================================================ */
.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.cart-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.cart-popup {
    background: var(--white);
    max-width: 900px;
    width: 100%;
    height: 100%;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-md);
    transform: scale(0.95) translateY(-20px);
    opacity: 0;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    
    /* Тонкий скроллбар для Firefox */
    scrollbar-width: thin;
    scrollbar-color: var(--dark-color) var(--light-grey);
}

/* Тонкий скроллбар для Chrome, Safari, Edge */
.cart-popup::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.cart-popup::-webkit-scrollbar-track {
    background: transparent;
    border-radius: 3px;
}

.cart-popup::-webkit-scrollbar-thumb {
    background: var(--grey-color);
    border-radius: 3px;
    transition: background 0.2s ease;
}

.cart-popup::-webkit-scrollbar-thumb:hover {
    background: var(--grey-color);
}
.cart-overlay.open .cart-popup {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.cart-popup__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
    flex-shrink: 0;
}

.cart-popup__header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--text-color);
}

.cart-popup__close {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: var(--grey-color);
    padding: 0 8px;
    line-height: 1;
    transition: color var(--transition);
}

.cart-popup__close:hover {
    color: var(--text-color);
}

.cart-popup__body {
    padding: 20px 24px;
    /* overflow-y: auto; */
    flex: 1;
}

.cart-popup__footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    flex-shrink: 0;
}

/* Товары в корзине */
.cart-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid var(--light-grey);
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item__info {
    flex: 1;
    min-width: 0;
}

.cart-item__name {
    font-weight: 500;
    font-size: 14px;
    color: var(--text-color);
}

.cart-item__price {
    font-size: 13px;
    color: var(--grey-color);
}

.cart-item__price strong {
    color: var(--main-color);
}

.cart-item__controls {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.cart-item__controls .qty-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid var(--border-dark);
    background: var(--white);
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
    color: var(--dark-grey-color);
}

.cart-item__controls .qty-btn:hover {
    background: #f8f9fa;
    border-color: var(--main-color);
    color: var(--main-color);
}

.cart-item__controls .qty-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.cart-item__controls .qty {
    min-width: 32px;
    text-align: center;
    font-weight: 600;
    font-size: 16px;
}

.cart-item__controls .qty-input {
    width: 50px;
    padding: 4px 6px;
    text-align: center;
    border: 1px solid var(--border-dark);
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    background: var(--white);
    -moz-appearance: textfield;
}

.cart-item__controls .qty-input::-webkit-outer-spin-button,
.cart-item__controls .qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.cart-item__controls .qty-input:focus {
    outline: none;
    border-color: var(--main-color);
    box-shadow: 0 0 0 3px rgba(var(--main-color-rgb), 0.1);
}

.cart-item__remove {
    background: none;
    border: none;
    color: var(--danger-color);
    cursor: pointer;
    padding: 4px 8px;
    font-size: 18px;
    transition: transform var(--transition);
}

.cart-item__remove:hover {
    transform: scale(1.2);
}

.cart-item__total {
    font-weight: 600;
    font-size: 15px;
    color: var(--text-color);
    min-width: 80px;
    text-align: right;
    flex-shrink: 0;
}

/* Форма */
.cart-form {
    display: grid;
    /* grid-template-columns: 1fr 1fr; */
    gap: 12px;
}

.cart-form .form-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cart-form .form-group.full-width {
    grid-column: 1 / -1;
}

.cart-form label {
    font-size: 13px;
    font-weight: 500;
    color: var(--dark-grey-color);
}

.cart-form input {
    padding: 8px 12px;
    border: 1px solid var(--border-dark);
    border-radius: 6px;
    font-size: 14px;
    transition: border-color var(--transition);
}

.cart-form input:focus {
    outline: none;
    border-color: var(--main-color);
    box-shadow: 0 0 0 3px rgba(var(--main-color-rgb), 0.1);
}

.cart-form textarea {
    padding: 8px 12px;
    border: 1px solid var(--border-dark);
    border-radius: 6px;
    font-size: 14px;
    resize: vertical;
    min-height: 60px;
    font-family: inherit;
}

.cart-form textarea:focus {
    outline: none;
    border-color: var(--main-color);
    box-shadow: 0 0 0 3px rgba(var(--main-color-rgb), 0.1);
}

/* .cart-form .checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding-top: 4px;
} */

/* .cart-form .checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex-shrink: 0;
    cursor: pointer;
}

.cart-form .checkbox-group label {
    font-size: 13px;
    font-weight: 400;
    color: var(--dark-grey-color);
    cursor: pointer;
}

.cart-form .checkbox-group a {
    color: var(--main-color);
    text-decoration: none;
} */

/* .cart-form .checkbox-group a:hover {
    text-decoration: underline;
} */

.phone-mask-input {
    padding: 8px 12px;
    border: 1px solid var(--border-dark);
    border-radius: 6px;
    font-size: 14px;
    transition: border-color var(--transition);
    width: 100%;
    font-family: inherit;
}

.phone-mask-input:focus {
    outline: none;
    border-color: var(--main-color);
    box-shadow: 0 0 0 3px rgba(var(--main-color-rgb), 0.1);
}

.phone-mask-input:disabled {
    background: var(--border-color);
    cursor: not-allowed;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    font-size: 18px;
    font-weight: 600;
}

.cart-total .total-price {
    color: var(--main-color);
    font-size: 22px;
}

.cart-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 12px;
}

.cart-actions .btn {
    padding: 10px 32px;
    font-size: 15px;
}

.btn--secondary {
    background: transparent;
    color: var(--text-color);
}

.btn--secondary:hover {
    background: var(--main-color);
    color: #fff;
}

.btn--danger {
    background: var(--danger-color);
    color: var(--white);
}

.btn--danger:hover {
    background: var(--danger-hover);
}

.empty-cart {
    text-align: center;
    padding: 40px 20px;
    color: var(--grey-color);
}

.empty-cart svg {
    width: 64px;
    height: 64px;
    opacity: 0.2;
    margin-bottom: 16px;
}

.empty-cart h3 {
    margin: 0 0 8px 0;
    color: var(--text-color);
}

/* Сообщение об отправке */
.submit-message {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 12px;
    font-weight: 500;
}

.submit-message--success {
    background: #d1e7dd;
    color: #0f5132;
    border: 1px solid #badbcc;
}

.submit-message--error {
    background: #f8d7da;
    color: #842029;
    border: 1px solid #f5c2c7;
}

/* ============================================================ */
/* Стили для контрола количества в таблице */
/* ============================================================ */
.qty-control {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #f8f9fa;
    border-radius: 6px;
    padding: 5px 2px;
    border: 1px solid var(--border-dark);
    justify-content: space-between;
    flex-grow: 1;
    max-width: 240px;
    width: 100%;
}



.qty-control .qty-btn {
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 4px;
    background: var(--white);
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    color: var(--dark-grey-color);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
}

.qty-control .qty-btn:hover {
    background: var(--main-color);
    color: var(--white);
}

.qty-control .qty-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.qty-control .qty-btn:disabled:hover {
    background: var(--white);
    color: var(--dark-grey-color);
}

.qty-control .qty-input {
    width: 40px;
    padding: 2px 4px;
    text-align: center;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    background: transparent;
    -moz-appearance: textfield;
}

.qty-control .qty-input::-webkit-outer-spin-button,
.qty-control .qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.qty-control .qty-input:focus {
    outline: none;
    background: var(--white);
    box-shadow: 0 0 0 2px rgba(var(--main-color-rgb), 0.2);
}

.action-cell .btn-group {
    display: flex;
    align-items: center;
    gap: 6px;
    /* justify-content: flex-end; */
    width: 100%;
    
    
}

.action-cell .btn--add-to-cart {
    background: transparent;
    color: var(--main-color);
    border: 1px solid var(--main-color);    
    padding: 7px 15px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
    flex-grow: 1;
    flex-shrink: 0;
    max-width: 240px;
    /* width: 100%; */
}

.action-cell .btn--add-to-cart:hover {
    background: var(--main-color-hover);
    color: #fff;
}

.action-cell .btn--in-cart {
    background: var(--success-color);
    color: var(--white);
    padding: 6px 12px;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 4px;
}

.action-cell .btn--in-cart:hover {
    background: var(--success-hover);
}

.action-cell .btn--cart-icon {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    color: var(--main-color);
}

.action-cell .btn--cart-icon:hover {
    background: var(--border-color);
}

.action-cell .btn--cart-icon svg {
    width: 18px;
    height: 18px;
}

.action-cell:before {
    display: none;
}


@media(min-width: 480px) {
    .action-cell {
        justify-content: center;
    }
    
    .action-cell .btn-group {
        width: auto;
    }
    
    .action-cell .btn--add-to-cart {
        max-width: 100px;
    }
        
    .qty-control {
        max-width: 120px;
        padding: 2px;
    }
}    
@media (min-width: 768px) {
    .action-cell:before {
        display: block;
    }
    

}

/* ============================================================ */
/* ПЛАВАЮЩАЯ КНОПКА КОРЗИНЫ */
/* ============================================================ */
.floating-cart {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--main-color);
    color: var(--white);
    border: none;
    box-shadow: 0 4px 16px rgba(var(--main-color-rgb), 0.4);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 1000;
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
}

.floating-cart.visible {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
    animation: bounceIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.floating-cart:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 24px rgba(var(--main-color-rgb), 0.6);
}

.floating-cart .cart-icon {
    width: 28px;
    height: 28px;
}

.floating-cart .cart-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--danger-color);
    color: var(--white);
    border-radius: 50%;
    width: 24px;
    height: 24px;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--white);
    box-shadow: 0 2px 8px rgba(220, 53, 69, 0.4);
}

/* ============================================================ */
/* АНИМАЦИИ */
/* ============================================================ */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeInContent {
    from {
        opacity: 0;
        transform: translateY(25px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounceIn {
    0% {
        transform: scale(0.3);
        opacity: 0;
    }
    50% {
        transform: scale(1.15);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ============================================================ */
/* АДАПТИВНОСТЬ */
/* ============================================================ */





@media (max-width: 768px) {


    .catalog__title {
        font-size: 20px;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .catalog__title .cart-info {
        width: 100%;
        justify-content: space-between;
    }

    .catalog__title .favorites-count {
        font-size: 13px;
        padding: 3px 10px;
    }

    .catalog__title .cart-button {
        font-size: 13px;
        padding: 5px 14px;
    }

    .tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        gap: 6px;
        padding-bottom: 12px;
        margin-bottom: 16px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
    }

    .tabs::-webkit-scrollbar {
        height: 4px;
    }

    .tabs::-webkit-scrollbar-thumb {
        background: #ced4da;
        border-radius: 4px;
    }

    .tab {
        padding: 6px 14px;
        font-size: 13px;
        flex-shrink: 0;
        white-space: nowrap;
    }

    .tab__unit {
        font-size: 10px;
    }

    .tab--favorite .badge {
        font-size: 10px;
        padding: 0px 6px;
    }

    .table-wrapper {
        overflow-x: visible;
    }

    .product-table thead {
        display: none;
    }

    .product-table,
    .product-table tbody,
    .product-table tr,
    .product-table td {
        display: block;
        width: 100%;
    }

    .product-table tr {
        margin-bottom: 16px;
        border: 1px solid var(--border-color);
        border-radius: var(--radius-sm);
        overflow: hidden;
        background: var(--white);
    }

    .product-table td {
        padding: 10px 14px;
        border-bottom: 1px solid var(--light-grey);
        display: flex;
        justify-content: space-between;
        align-items: center;
        flex-wrap: wrap;
        gap: 6px;
    }

    .product-table td:last-child {
        border-bottom: none;
    }

    .product-table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: var(--grey-color);
        font-size: 12px;
        flex-shrink: 0;
    }

    .category-header td {
        display: block !important;
        padding: 10px 14px !important;
        border-radius: var(--radius-sm) var(--radius-sm) 0 0;
        background-color: var(--border-color) !important;
    }

    .category-header td::before {
        display: none;
    }

    .category-header .category-name {
        font-size: 14px;
    }

    .category-header .category-unit {
        font-size: 12px;
        padding: 0px 8px;
    }

    .category-header .category-count {
        font-size: 11px;
    }

    .price-cell {
        white-space: normal;
        width: 100%;
    }

    .price-cell::before {
        content: 'Цены';
    }

    .price-list {
        flex-direction: column;
        gap: 2px;
        width: 100%;
    }

    .price-item {
        display: flex;
        justify-content: space-between;
        padding: 2px 0;
        border-bottom: 1px dashed var(--light-grey);
    }

    .price-item:last-child {
        border-bottom: none;
    }

    .price-item .label {
        font-size: 13px;
    }

    .product-table td:first-child {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .product-table td:first-child::before {
        content: 'Наименование';
    }


    .product-table td:first-child span {
        font-size: 11px !important;
        margin-left: 0 !important;
    }

    .action-cell {
        display: flex !important;
        justify-content: center !important;
        gap: 8px;
        /* padding: 10px 14px !important; */
    }

    .action-cell::before {
        content: 'Действия';
    }

    .action-cell .btn-group {
        flex-wrap: wrap;
    }

    .btn {
        padding: 6px 14px;
        font-size: 12px;
        flex: 1;
        justify-content: center;
    }

    .btn--favorite {
        flex: 0 0 auto;
        padding: 8px 10px;
    }

    .btn--favorite svg {
        width: 18px;
        height: 18px;
    }

    .qty-control .qty-input {
        width: 32px;
        font-size: 13px;
    }

    .qty-control .qty-btn {
        width: 24px;
        height: 24px;
        font-size: 14px;
    }

/*     .action-cell .btn--add-to-cart,
.action-cell .btn--in-cart {
    padding: 4px 8px;
    font-size: 11px;
} */

    .product-table tr.favorite-row td {
        background-color: #fff5f5;
    }

    .product-table tr.favorite-row td:first-child {
        border-left: 3px solid var(--danger-color);
    }

    .empty-state {
        padding: 40px 16px;
    }

    .empty-state svg {
        width: 48px;
        height: 48px;
    }

    .empty-state h3 {
        font-size: 18px;
    }

    .empty-state p {
        font-size: 14px;
    }

    .loading,
    .error {
        padding: 30px 16px;
        font-size: 16px;
    }

    .cart-popup {
        max-width: 100%;
        max-height: 95vh;
        border-radius: var(--radius);
        transform: scale(0.95) translateY(-15px);
    }

    .cart-popup__header {
        padding: 14px 16px;
    }

    .cart-popup__header h2 {
        font-size: 18px;
    }

    .cart-popup__body {
        padding: 14px 16px;
    }

    .cart-popup__footer {
        padding: 14px 16px;
    }

    .cart-item {
        flex-wrap: wrap;
        gap: 10px;
    }

    .cart-item__info {
        flex: 1 1 100%;
    }

    .cart-item__total {
        min-width: auto;
        text-align: left;
    }

    .cart-item__controls {
        flex: 1;
        justify-content: flex-start;
    }

    .cart-form {
        grid-template-columns: 1fr;
    }

    .cart-form .form-group.full-width {
        grid-column: 1;
    }

    .cart-total {
        font-size: 16px;
        flex-wrap: wrap;
        gap: 8px;
    }

    .cart-total .total-price {
        font-size: 19px;
    }

    .cart-actions {
        flex-direction: column;
    }

    .cart-actions .btn {
        width: 100%;
        justify-content: center;
    }

    .floating-cart {
        bottom: 20px;
        right: 20px;
        width: 52px;
        height: 52px;
    }

    .floating-cart .cart-icon {
        width: 24px;
        height: 24px;
    }

    .floating-cart .cart-badge {
        width: 20px;
        height: 20px;
        font-size: 10px;
        top: -2px;
        right: -2px;
    }

    .cart-overlay {
        padding: 10px;
    }
}

@media (max-width: 480px) {


    .catalog__title {
        font-size: 18px;
    }

    .tab {
        padding: 5px 10px;
        font-size: 12px;
    }

    .product-table td {
        padding: 8px 10px;
        font-size: 13px;
    }

    .product-table td:first-child strong {
        font-size: 16px;
    }

    .price-item {
        font-size: 13px;
    }

    .btn {
        font-size: 13px;
        padding: 7px 10px;
    }

    .category-header .category-name {
        font-size: 13px;
    }
}


.catalog__select-wrapper, .catalog__radio-wrapper {
	display: flex;
	flex-direction: column;
	gap: 3px;
}

.catalog__select-label {
    font-weight: 700;    
}

.catalog__select {
    width: 100%;
    max-width: 260px;
    min-width: 160px;
    padding: 3px 16px;
    height: 40px;
    font-size: 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background-color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M6 8L1 3h10z' fill='%23333'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
}


@media (max-width: 567px) {
    .catalog__select--cats {
        width: 100%;
        max-width: 100%;
    }
}

.catalog__select:hover {
    border-color: var(--main-color);
}

/* .catalog__select:focus {
    outline: none;
    border-color: #0d6efd;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
} */



/* Панель фильтров */
.price-filters {
    display: flex;
    gap: 24px;
    align-items: center;
    padding: 12px 16px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-label {
    font-weight: 600;
    color: #495057;
    font-size: 14px;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 14px;
    cursor: pointer;
    color: #495057;
}

.radio-label input[type="radio"] {
    cursor: pointer;
    margin: 0;
}

.discount-select {
    padding: 4px 8px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 14px;
    background: white;
    cursor: pointer;
}

/* Ячейка цены в таблице */
.price-cell-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

.price-current {
    font-weight: 600;
    font-size: 15px;
}

.price-base-old {
    font-size: 12px;
    color: #6c757d;
    text-decoration: line-through;
    text-decoration-color: #dc3545;
}

.price-no-data {
    color: #6c757d;
    font-size: 14px;
}


.catalog__controls-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    margin-bottom: 32px;
}


/* ===== КАТАЛОГ - РАДИО КНОПКИ ===== */
.catalog__radio-wrapper {
    display: flex;
}

.catalog__select-label {
    font-size: 12px;
    font-weight: 700;
}

.catalog__radios {
    display: flex;
    gap: 6px;
    background: var(--light-grey);
    padding: 4px;
    height: 40px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.catalog__radio {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 16px;
    font-size: 13px;
    font-weight: 500;
    color: var(--grey-color);
    background: transparent;
    border-radius: 6px;
    cursor: pointer;
    transition: all var(--transition);
    user-select: none;
    min-width: 44px;
}

/* Скрываем нативный input */
.catalog__radio input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

/* Активное состояние */
.catalog__radio:has(input:checked) {
    background: var(--white);
    color: var(--main-color);
    box-shadow: var(--shadow-sm);
    font-weight: 600;
}

/* Hover для неактивных */
.catalog__radio:not(:has(input:checked)):hover {
    color: var(--text-color);
    background: rgba(0, 0, 0, 0.04);
}

/* Фокус для доступности */
.catalog__radio input[type="radio"]:focus-visible + span {
    outline: 2px solid var(--main-color);
    outline-offset: 2px;
}

/* Адаптив */
@media (max-width: 576px) {

    .catalog__radios {
        width: 100%;
        justify-content: stretch;
    }

    .catalog__radio {
        flex: 1;
        padding: 8px 12px;
        font-size: 14px;
    }
}



.cart-section__title {
	font-size: 20px;
	margin-bottom: 10px;
	font-weight: bold;
	color: var(--main-color-hover);
}