/* ============================================
MIXTRADER - MAIN STYLES
Architecture: Variables > Reset > Layout > Components > Pages > Responsive
============================================ */
:root {
--color-bg: #0a0a0a;
--color-surface: #1e1b4b;
--color-surface-light: #312e81;
--color-text: #ffffff;
--color-text-muted: rgba(255, 255, 255, 0.6);
--color-primary: #f97316;
--color-primary-hover: #fb923c;
--color-accent: #2DD4BF;
--color-success: #4ADE80;
--color-error: #ef4444;
--color-gold: #D4AF37;
--radius-sm: 8px;
--radius-md: 12px;
--radius-lg: 16px;
--radius-xl: 24px;
--shadow-card: 0 10px 30px rgba(0, 0, 0, 0.3);
--shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.4);
--transition: all 0.3s ease;
}

/* ===== 0. RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
font-family: 'Inter', system-ui, -apple-system, sans-serif;
background-color: var(--color-bg);
color: var(--color-text);
line-height: 1.6;
-webkit-font-smoothing: antialiased;
overflow-x: hidden;
}
a { color: inherit; text-decoration: none; transition: var(--transition); }
a:hover { color: var(--color-accent); }
img, svg { display: block; max-width: 100%; height: auto; }
button, input, select, textarea {
font-family: inherit; font-size: inherit; color: inherit; border: none; outline: none;
}
button { cursor: pointer; }
ul, ol { list-style: none; }
.container { max-width: 1280px; margin: 0 auto; padding: 0 20px; }

/* ===== 1. UTILITY CLASSES ===== */
.desktop-only { display: flex !important; }
.mobile-only { display: none !important; }

/* ===== 2. PROMO BAR ===== */
.promo-bar {
background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
padding: 8px 0; text-align: center; font-size: 0.85rem; font-weight: 600;
position: relative; z-index: 100;
}

/* ===== 3. HEADER ===== */
.site-header {
background: rgba(10, 10, 10, 0.95);
backdrop-filter: blur(10px);
border-bottom: 1px solid rgba(255, 255, 255, 0.05);
position: sticky; top: 0; z-index: 1000;
padding: 12px 0;
}
.header-inner {
display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.site-logo { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.5px; }
.site-logo span { color: var(--color-primary); }

/* Desktop Nav */
.main-nav { flex: 1; display: flex; justify-content: center; }
.nav-list { display: flex; gap: 24px; }
.nav-list a { font-size: 0.95rem; font-weight: 500; color: var(--color-text-muted); }
.nav-list a:hover, .nav-list a.active { color: var(--color-text); }

/* Header Actions */
.header-actions { display: flex; align-items: center; gap: 12px; }
.header-phone { font-weight: 600; font-size: 0.95rem; }
.cart-btn { position: relative; display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: rgba(255,255,255,0.05); transition: var(--transition); }
.cart-btn:hover { background: rgba(255,255,255,0.1); transform: scale(1.05); }
.cart-count {
position: absolute; top: -2px; right: -2px; background: var(--color-error); color: #fff;
font-size: 0.65rem; font-weight: 700; min-width: 16px; height: 16px; border-radius: 8px;
display: flex; align-items: center; justify-content: center; padding: 0 4px;
animation: pulse 0.3s ease;
}
.messenger-btn {
display: flex; align-items: center; justify-content: center;
width: 38px; height: 38px; background: var(--color-accent); border-radius: 50%;
color: #fff; transition: transform 0.2s;
}
.messenger-btn:hover { transform: scale(1.1); }

/* Burger Menu */
.burger-menu { display: flex; flex-direction: column; gap: 5px; padding: 8px; background: transparent; }
.burger-menu span { display: block; width: 24px; height: 2px; background: #fff; transition: var(--transition); }
.burger-menu.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.burger-menu.active span:nth-child(2) { opacity: 0; }
.burger-menu.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ============================================
   MOBILE MENU (ПОЛНОСТЬЮ ПЕРЕПИСАНО)
   ============================================ */

/* Overlay */
.mobile-menu-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important; /* Dynamic viewport height */
    min-height: 100% !important;
    background: #0a0a0a !important;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 99999 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

.mobile-menu-overlay.active {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Content container */
.mobile-menu-content {
    position: relative !important;
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
    height: 100dvh !important;
    min-height: 100vh !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    -webkit-overflow-scrolling: touch !important;
    background: #0a0a0a !important;
    padding: 70px 20px calc(20px + env(safe-area-inset-bottom)) 20px !important;
    box-sizing: border-box !important;
}

/* Close button */
.close-menu {
    position: fixed !important;
    top: calc(15px + env(safe-area-inset-top)) !important;
    right: calc(15px + env(safe-area-inset-right)) !important;
    width: 48px !important;
    height: 48px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 2rem !important;
    color: #fff !important;
    z-index: 100000 !important;
    cursor: pointer !important;
    backdrop-filter: blur(10px) !important;
}

/* Menu list */
.mobile-nav-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.mobile-nav-list li {
    margin: 0 !important;
    padding: 0 !important;
}

.mobile-nav-list a {
    display: block !important;
    padding: 16px 20px !important;
    color: #fff !important;
    font-size: 1.1rem !important;
    font-weight: 600 !important;
    text-align: center !important;
    text-decoration: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 8px !important;
    transition: background 0.2s ease !important;
}

.mobile-nav-list a:hover,
.mobile-nav-list a:active {
    background: rgba(255, 255, 255, 0.1) !important;
}

/* Legal section */
.mobile-legal-separator {
    margin: 30px 0 15px 0 !important;
    border-top: 1px solid rgba(255, 255, 255, 0.15) !important;
}

.mobile-legal-item {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.mobile-legal-link {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    padding: 12px 20px !important;
    color: rgba(255, 255, 255, 0.7) !important;
    font-size: 0.9rem !important;
    text-decoration: none !important;
    border-radius: 8px !important;
    transition: all 0.2s ease !important;
}

.mobile-legal-link:hover,
.mobile-legal-link:active {
    background: rgba(255, 255, 255, 0.08) !important;
    color: #fff !important;
    padding-left: 25px !important;
}

.mobile-legal-link svg {
    flex-shrink: 0 !important;
    opacity: 0.8 !important;
}

/* Scrollbar */
.mobile-menu-content::-webkit-scrollbar {
    width: 4px !important;
}

.mobile-menu-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05) !important;
}

.mobile-menu-content::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3) !important;
    border-radius: 2px !important;
}

/* iOS fix */
@supports (-webkit-touch-callout: none) {
    .mobile-menu-overlay {
        height: -webkit-fill-available !important;
    }
    .mobile-menu-content {
        height: -webkit-fill-available !important;
        min-height: -webkit-fill-available !important;
    }
}

/* Block body scroll */
body.menu-open {
    overflow: hidden !important;
    position: fixed !important;
    width: 100% !important;
    height: 100% !important;
    top: 0 !important;
    left: 0 !important;
    touch-action: none !important;
}
/* ===== 4. CATALOG & PRODUCT CARDS ===== */
.catalog-header { padding: 60px 0 30px; text-align: center; background: linear-gradient(135deg, #1A0838 0%, #2D1B3D 100%); }
.catalog-header h1 {
font-family: 'Playfair Display', serif; font-size: 3rem; font-weight: 700; margin-bottom: 10px;
background: linear-gradient(90deg, #84CC16, #2DD4BF, #A78BFA); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.catalog-header p { color: rgba(255,255,255,0.7); font-size: 1.1rem; }

.category-nav {
background: var(--color-surface); border-bottom: 1px solid rgba(255,255,255,0.1);
overflow-x: auto; -webkit-overflow-scrolling: touch;
}
.category-nav::-webkit-scrollbar { display: none; }
.category-nav-inner { display: flex; gap: 0; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.category-nav-item {
flex-shrink: 0; padding: 16px 24px; color: rgba(255,255,255,0.6); text-decoration: none;
font-size: 0.9rem; font-weight: 500; text-transform: uppercase; letter-spacing: 1px;
border-bottom: 2px solid transparent; white-space: nowrap; transition: var(--transition);
}
.category-nav-item:hover { color: #fff; }
.category-nav-item.active { color: var(--color-primary); border-bottom-color: var(--color-primary); }

.catalog-section { padding: 40px 0 80px; }
.products-grid {
display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
gap: 30px; max-width: 1200px; margin: 0 auto; padding: 0 20px;
}
.product-card {
background: linear-gradient(135deg, var(--color-surface) 0%, var(--color-surface-light) 100%);
border-radius: var(--radius-lg); overflow: hidden; transition: var(--transition); box-shadow: var(--shadow-card);
}
.product-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-hover); }
.product-image { position: relative; aspect-ratio: 3/4; overflow: hidden; background: rgba(255,255,255,0.05); }
.product-image a { display: block; width: 100%; height: 100%; }
.product-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.product-card:hover .product-image img { transform: scale(1.05); }

.stock-badge {
position: absolute; top: 12px; right: 12px; padding: 6px 12px; border-radius: var(--radius-sm);
font-size: 0.75rem; font-weight: 600; text-transform: uppercase; z-index: 2;
}
.stock-badge.low { background: #f97316; color: #fff; }
.stock-badge.out { background: #ef4444; color: #fff; }

.product-info { padding: 20px; }
.product-title { font-size: 1.15rem; font-weight: 600; margin-bottom: 8px; }
.product-title a:hover { color: var(--color-accent); }
.product-front-description {
font-size: 0.85rem; color: var(--color-text-muted); margin-bottom: 12px; line-height: 1.4;
min-height: 36px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.product-price { font-size: 1.5rem; font-weight: 700; color: var(--color-accent); margin-bottom: 12px; text-align: center; }

/* ===== ОБНОВЛЕННЫЙ СЕЛЕКТОР КОЛИЧЕСТВА (ГОРИЗОНТАЛЬНЫЙ) ===== */
.quantity-selector {
display: flex;
align-items: center;
justify-content: center;
gap: 0;
background: rgba(255, 255, 255, 0.05);
border: 1px solid rgba(255, 255, 255, 0.1);
border-radius: 8px;
overflow: hidden;
width: 140px;
height: 40px;
margin: 0 auto 15px;
}
.qty-btn {
width: 40px; height: 100%; background: transparent; border: none;
color: rgba(255, 255, 255, 0.6); font-size: 1.1rem; cursor: pointer; transition: all 0.2s;
display: flex; align-items: center; justify-content: center; padding: 0;
}
.qty-btn:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.qty-btn:active { background: rgba(249, 115, 22, 0.2); color: var(--color-primary); }
.qty-input {
width: 60px; height: 100%; background: transparent; border: none;
border-left: 1px solid rgba(255, 255, 255, 0.1); border-right: 1px solid rgba(255, 255, 255, 0.1);
color: #fff; font-size: 1rem; font-weight: 600; text-align: center;
-moz-appearance: textfield; padding: 0;
}
.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button {
-webkit-appearance: none; margin: 0;
}
.add-to-cart {
width: 100%; padding: 12px 16px; background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
border-radius: var(--radius-md); color: #fff; font-size: 0.95rem; font-weight: 600;
text-transform: uppercase; letter-spacing: 0.5px; transition: var(--transition);
}
.add-to-cart:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(249,115,22,0.4); }
.add-to-cart:disabled { background: #6b7280; cursor: not-allowed; transform: none; box-shadow: none; }

.pagination { display: flex; justify-content: center; gap: 8px; margin: 50px 0; padding: 0 20px; }
.pagination a, .pagination span {
padding: 10px 16px; background: rgba(255,255,255,0.08); border-radius: var(--radius-sm); transition: var(--transition);
}
.pagination a:hover, .pagination span.current { background: var(--color-primary); }

/* ===== 5. SINGLE PRODUCT ===== */
.product-section { padding: 40px 0 80px; }
.product-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; }
.product-gallery { position: sticky; top: 100px; }
.main-image { position: relative; border-radius: var(--radius-xl); overflow: hidden; box-shadow: var(--shadow-hover); margin-bottom: 20px; aspect-ratio: 3/4; background: rgba(255,255,255,0.05); }
.main-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.main-image:hover img { transform: scale(1.05); }
.thumbnail-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.thumbnail { aspect-ratio: 1; border-radius: var(--radius-md); overflow: hidden; cursor: pointer; border: 2px solid transparent; transition: var(--transition); opacity: 0.6; }
.thumbnail:hover, .thumbnail.active { border-color: var(--color-accent); opacity: 1; }
.thumbnail img { width: 100%; height: 100%; object-fit: cover; }
.product-title-single { font-family: 'Playfair Display', serif; font-size: 3rem; line-height: 1.2; margin-bottom: 20px; background: linear-gradient(90deg, #fff, #e0e0e0); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.product-description { font-size: 1.1rem; color: var(--color-text-muted); margin-bottom: 35px; line-height: 1.8; }
.product-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; padding: 25px; background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.1); border-radius: var(--radius-lg); margin-bottom: 35px; }
.meta-item { display: flex; align-items: center; gap: 12px; }
.meta-icon { width: 45px; height: 45px; background: linear-gradient(135deg, rgba(139,92,246,0.2), rgba(45,212,191,0.2)); border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; }
.product-section .quantity-selector { width: 160px; height: 45px; margin: 0 auto 20px; }
.product-section .qty-btn { width: 45px; font-size: 1.3rem; }
.product-section .qty-input { width: 70px; font-size: 1.1rem; }
.trust-badges { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; padding-top: 35px; border-top: 1px solid rgba(255,255,255,0.1); }
.trust-item { text-align: center; font-size: 0.85rem; color: var(--color-text-muted); }

/* ===== 6. CART PAGE ===== */
.cart-section { padding: 40px 0 80px; }
.cart-layout { display: grid; grid-template-columns: 1fr 400px; gap: 50px; align-items: start; }
.cart-items { background: var(--color-surface); border: 1px solid rgba(255,255,255,0.1); border-radius: var(--radius-xl); padding: 30px; }
.cart-items-header { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 20px; padding-bottom: 20px; border-bottom: 1px solid rgba(255,255,255,0.1); margin-bottom: 20px; font-size: 0.85rem; color: var(--color-text-muted); text-transform: uppercase; }
.cart-item { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 20px; padding: 30px 0; border-bottom: 1px solid rgba(255,255,255,0.1); align-items: center; }
.cart-item:last-child { border-bottom: none; }
.product-details-col { display: flex; flex-direction: column; gap: 10px; }
.cart-product-image { width: 120px; height: 160px; border-radius: var(--radius-md); overflow: hidden; }
.cart-product-image img { width: 100%; height: 100%; object-fit: cover; }
.quantity-col { position: relative; }
.remove-item { position: absolute; left: 50%; bottom: -20px; transform: translateX(-50%); background: transparent; color: var(--color-text-muted); font-size: 1.5rem; transition: var(--transition); }
.remove-item:hover { color: var(--color-error); transform: translateX(-50%) scale(1.2); }
.cart-item-total { font-family: 'Playfair Display', serif; font-size: 1.4rem; font-weight: 700; color: var(--color-gold); }
.cart-item .quantity-selector { width: 120px; height: 35px; margin: 0 auto; }
.cart-item .qty-btn { width: 35px; font-size: 1rem; }
.cart-item .qty-input { width: 50px; font-size: 0.95rem; }
.cart-summary { background: var(--color-surface); border: 1px solid rgba(255,255,255,0.1); border-radius: var(--radius-xl); padding: 30px; position: sticky; top: 100px; }
.cart-summary h2 { font-family: 'Playfair Display', serif; font-size: 1.8rem; margin-bottom: 25px; color: var(--color-gold); }
.summary-row { display: flex; justify-content: space-between; padding: 15px 0; border-bottom: 1px solid rgba(255,255,255,0.1); }
.summary-total { margin-top: 25px; padding-top: 25px; border-top: 2px solid rgba(255,255,255,0.1); }
.summary-total .summary-value { font-family: 'Playfair Display', serif; font-size: 2.2rem; color: var(--color-gold); font-weight: 700; }
.promo-code-section { margin: 25px 0; padding: 20px; background: rgba(255,255,255,0.03); border-radius: var(--radius-md); border: 1px solid rgba(255,255,255,0.1); }
.promo-input-group { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.promo-input { padding: 12px 15px; background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1); border-radius: var(--radius-sm); color: #fff; }
.promo-btn { padding: 12px 25px; background: linear-gradient(135deg, #84CC16, #2DD4BF); border-radius: var(--radius-sm); color: #fff; font-weight: 600; transition: var(--transition); }
.promo-btn.applied { background: var(--color-success); cursor: default; }
.promo-message { margin-top: 10px; font-size: 0.9rem; text-align: center; min-height: 20px; }
.promo-message.error { color: var(--color-error); }
.promo-message.success { color: var(--color-success); }
.checkout-btn {
display: block; width: 100%; padding: 18px; background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
border-radius: var(--radius-md); color: #fff; font-size: 1rem; font-weight: 700; text-transform: uppercase;
text-align: center; margin-top: 25px; transition: var(--transition);
}
.checkout-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(249,115,22,0.4); }
.continue-shopping { display: block; text-align: center; margin-top: 20px; color: var(--color-text-muted); }
.empty-cart { text-align: center; padding: 100px 0; }
.empty-cart-icon { font-size: 6rem; margin-bottom: 30px; opacity: 0.5; }

/* ===== 7. CHECKOUT PAGE ===== */
.checkout-layout { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 50px; align-items: start; }
.checkout-form { background: var(--color-surface); border: 1px solid rgba(255,255,255,0.1); border-radius: var(--radius-xl); padding: 40px; }
.checkout-form h2 { font-family: 'Playfair Display', serif; font-size: 1.8rem; margin-bottom: 30px; color: var(--color-gold); border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 15px; }
.client-type-tabs { display: flex; gap: 10px; margin-bottom: 30px; border-bottom: 2px solid rgba(255,255,255,0.1); padding-bottom: 20px; }
.client-tab { flex: 1; padding: 15px; background: rgba(255,255,255,0.05); border: 2px solid rgba(255,255,255,0.1); border-radius: var(--radius-md); cursor: pointer; text-align: center; font-weight: 600; color: var(--color-text-muted); transition: var(--transition); }
.client-tab.active { background: linear-gradient(135deg, var(--color-accent), #84CC16); border-color: var(--color-accent); color: #fff; }
.client-tab-content { display: none; }
.client-tab-content.active { display: block; animation: fadeIn 0.3s ease; }
.form-group { margin-bottom: 25px; position: relative; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 600; color: rgba(255,255,255,0.9); font-size: 0.95rem; }
.form-group label .required { color: var(--color-error); }
.form-group input, .form-group select, .form-group textarea {
width: 100%; padding: 14px 18px; background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
border-radius: var(--radius-md); color: #fff; font-size: 1rem; transition: var(--transition);
}
.form-group input:focus, .form-group textarea:focus { border-color: var(--color-accent); background: rgba(255,255,255,0.1); }
.form-group.error input { border-color: var(--color-error); background: rgba(239,68,68,0.05); }
.form-group .error-msg { color: var(--color-error); font-size: 0.85rem; margin-top: 6px; animation: fadeIn 0.3s; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.delivery-options, .payment-options { display: flex; flex-direction: column; gap: 12px; margin-top: 10px; }
.delivery-option, .payment-option {
display: flex; align-items: center; gap: 12px; padding: 15px 20px; background: rgba(255,255,255,0.03);
border: 2px solid rgba(255,255,255,0.1); border-radius: var(--radius-md); cursor: pointer; transition: var(--transition);
}
.delivery-option:hover, .payment-option:hover { border-color: rgba(45,212,191,0.5); }
.delivery-option input, .payment-option input { width: 20px; height: 20px; accent-color: var(--color-accent); }
.delivery-option.selected, .payment-option.selected { border-color: var(--color-accent); background: rgba(45,212,191,0.1); }
.terms-group { display: flex; align-items: flex-start; gap: 12px; margin: 30px 0; padding: 20px; background: rgba(255,255,255,0.03); border-radius: var(--radius-md); }
.terms-group input[type="checkbox"] { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--color-accent); flex-shrink: 0; }
.terms-group label { margin: 0; font-size: 0.9rem; color: var(--color-text-muted); line-height: 1.5; cursor: pointer; }
.terms-group a { color: var(--color-accent); text-decoration: underline; }
.checkout-submit {
width: 100%; padding: 18px; background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
border-radius: var(--radius-md); color: #fff; font-size: 1.1rem; font-weight: 700; text-transform: uppercase;
cursor: pointer; transition: var(--transition); margin-top: 20px;
}
.checkout-submit:hover { transform: translateY(-3px); box-shadow: 0 15px 40px rgba(249,115,22,0.5); }
.checkout-submit:disabled { background: #6b7280; cursor: not-allowed; transform: none; box-shadow: none; }
.checkout-submit.loading { position: relative; pointer-events: none; }
.checkout-submit.loading::after {
content: ''; position: absolute; width: 20px; height: 20px; border: 2px solid transparent;
border-top-color: #fff; border-radius: 50%; animation: spin 0.8s linear infinite; right: 20px; top: 50%; transform: translateY(-50%);
}
.order-summary { background: var(--color-surface); border: 1px solid rgba(255,255,255,0.1); border-radius: var(--radius-xl); padding: 30px; position: sticky; top: 100px; }
.order-summary h2 { font-family: 'Playfair Display', serif; font-size: 1.8rem; margin-bottom: 25px; color: var(--color-gold); border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 15px; }
.checkout-item { display: flex; gap: 15px; padding: 15px 0; border-bottom: 1px solid rgba(255,255,255,0.1); }
.checkout-item:last-child { border-bottom: none; }
.checkout-item-image { width: 50px; height: 67px; border-radius: var(--radius-sm); overflow: hidden; flex-shrink: 0; background: rgba(255,255,255,0.05); }
.checkout-item-image img { width: 100%; height: 100%; object-fit: cover; }
.checkout-item-info { flex: 1; }
.checkout-item-title { font-weight: 600; margin-bottom: 5px; font-size: 0.95rem; }
.checkout-item-meta { font-size: 0.85rem; color: var(--color-text-muted); margin-bottom: 5px; }
.checkout-item-price { font-weight: 700; color: var(--color-accent); }
.edit-cart-link { display: block; text-align: center; margin: 15px 0 25px; padding: 10px; color: var(--color-text-muted); border: 1px dashed rgba(255,255,255,0.2); border-radius: var(--radius-sm); transition: var(--transition); }
.edit-cart-link:hover { color: var(--color-accent); border-color: var(--color-accent); }
.security-badge { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 25px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.1); color: var(--color-text-muted); font-size: 0.85rem; }

/* ===== 8. THANK YOU PAGE ===== */
.thank-you-section { padding: 80px 0 120px; min-height: 70vh; display: flex; align-items: center; justify-content: center; }
.thank-you-card { max-width: 700px; margin: 0 auto; background: var(--color-surface); border: 1px solid rgba(255,255,255,0.1); border-radius: var(--radius-xl); padding: 60px 40px; text-align: center; box-shadow: var(--shadow-hover); }
.thank-you-icon { width: 100px; height: 100px; margin: 0 auto 30px; background: linear-gradient(135deg, #4ADE80, #2DD4BF); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 3rem; color: #fff; animation: successPulse 0.6s ease; }
.thank-you-card h1 { font-family: 'Playfair Display', serif; font-size: 2.5rem; color: #4ADE80; margin-bottom: 20px; }
.thank-you-card .subtitle { color: var(--color-text-muted); font-size: 1.1rem; margin-bottom: 40px; }
.order-info { background: rgba(255,255,255,0.05); border-radius: var(--radius-lg); padding: 30px; margin: 30px 0; text-align: left; }
.order-info h3 { color: var(--color-gold); margin-bottom: 20px; }
.order-row { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,0.1); }
.order-row:last-child { border-bottom: none; }
.order-label { color: var(--color-text-muted); }
.order-value { font-weight: 600; }
.order-total { font-size: 1.5rem; color: var(--color-gold) !important; font-weight: 700; }
.discount-row { color: #4ADE80; }
.contact-block { margin-top: 30px; padding: 25px; background: rgba(45,212,191,0.1); border: 1px solid rgba(45,212,191,0.3); border-radius: var(--radius-md); text-align: left; }
.contact-block h3 { color: var(--color-accent); margin: 0 0 15px 0; }
.contact-block p { margin: 8px 0; color: var(--color-text-muted); }
.contact-block a { color: var(--color-accent); text-decoration: none; }

/* ===== 9. DESKTOP FOOTER ===== */
.desktop-footer { background: var(--color-surface); border-top: 1px solid rgba(255,255,255,0.1); padding: 60px 0 30px; margin-top: 80px; }
.footer-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; margin-bottom: 40px; }
.footer-col h4 { font-size: 1.1rem; margin-bottom: 20px; color: #fff; }
.footer-links li { margin-bottom: 12px; }
.footer-links a { color: var(--color-text-muted); font-size: 0.95rem; }
.footer-links a:hover { color: var(--color-accent); }
.footer-logo { font-size: 1.5rem; font-weight: 800; margin-bottom: 15px; }
.footer-logo span { color: var(--color-primary); }
.footer-desc { color: var(--color-text-muted); font-size: 0.9rem; line-height: 1.6; margin-bottom: 20px; }
.social-links { display: flex; gap: 10px; }
.social-icon { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; background: rgba(255,255,255,0.1); border-radius: 50%; font-size: 0.8rem; font-weight: 700; }
.social-icon:hover { background: var(--color-primary); }
.footer-phone, .footer-email { display: block; margin-bottom: 8px; color: var(--color-text); font-weight: 600; }
.working-hours { color: var(--color-text-muted); font-size: 0.85rem; margin-top: 15px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 30px; border-top: 1px solid rgba(255,255,255,0.1); color: var(--color-text-muted); font-size: 0.85rem; }
.footer-legal { display: flex; gap: 20px; }
.footer-legal a { color: var(--color-text-muted); }
.footer-legal a:hover { color: #fff; }

/* ===== 10. MOBILE TAB BAR ===== */
.mobile-tab-bar {
display: none; position: fixed; bottom: 0; left: 0; right: 0;
background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%);
border-top: 1px solid rgba(255,255,255,0.15);
padding: 6px 0; padding-bottom: max(6px, env(safe-area-inset-bottom));
z-index: 9999; box-shadow: 0 -4px 20px rgba(0,0,0,0.3);
}
.tab-item {
display: flex; flex-direction: column; align-items: center; justify-content: center;
gap: 2px; padding: 4px 0; color: rgba(255,255,255,0.5); text-decoration: none;
font-size: 0.65rem; font-weight: 500; transition: all 0.2s; position: relative; flex: 1;
white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.tab-item svg { width: 20px; height: 20px; transition: all 0.2s; }
.tab-item:hover, .tab-item.active { color: var(--color-primary); }
.tab-item.active svg { transform: scale(1.1); stroke-width: 2.5; }
.tab-badge {
position: absolute; top: -2px; right: -4px; background: #ec4899; color: #fff;
font-size: 0.6rem; font-weight: 700; min-width: 14px; height: 14px; border-radius: 7px;
display: flex; align-items: center; justify-content: center; padding: 0 3px;
}

/* ===== 11. ANIMATIONS & UTILS ===== */
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.3); } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes successPulse { 0% { transform: scale(0); opacity: 0; } 50% { transform: scale(1.2); } 100% { transform: scale(1); opacity: 1; } }
@keyframes spin { to { transform: translateY(-50%) rotate(360deg); } }
@keyframes slideIn { from { transform: translateX(100px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes fadeOut { from { opacity: 1; transform: translateY(0); } to { opacity: 0; transform: translateY(-10px); } }
.cart-notification {
position: fixed; bottom: 80px; right: 20px; padding: 12px 24px; border-radius: var(--radius-md);
color: #fff; font-weight: 500; z-index: 10000; animation: slideIn 0.3s ease, fadeOut 0.3s ease 2.7s forwards;
box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}
.cart-notification.success { background: #16a34a; }
.cart-notification.error { background: #dc2626; }

/* ===== БЕЙДЖИ В УГЛАХ ТОВАРА ===== */
.corner-badge {
position: absolute; padding: 6px 12px; color: #fff; font-size: 0.75rem; font-weight: 700;
text-transform: uppercase; border-radius: 6px; z-index: 10; box-shadow: 0 2px 8px rgba(0,0,0,0.2); pointer-events: none;
}
.corner-badge.top-left { top: 12px; left: 12px; }
.corner-badge.top-right { top: 12px; right: 12px; }
.corner-badge.bottom-left { bottom: 12px; left: 12px; }
.corner-badge.bottom-right { bottom: 12px; right: 12px; }
.corner-badge-sold {
position: absolute; top: 12px; right: 12px; padding: 6px 12px; color: #fff;
font-size: 0.75rem; font-weight: 700; text-transform: uppercase; border-radius: 6px;
z-index: 10; box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* ============================================
   12. RESPONSIVE (FIXED & OPTIMIZED)
   ============================================ */
@media (max-width: 1024px) {
.product-grid, .checkout-layout, .cart-layout { grid-template-columns: 1fr; gap: 40px; }
.product-gallery { position: static; }
.footer-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
/* Toggle utilities */
.mobile-only { display: flex !important; }
.desktop-only, .desktop-nav, .desktop-footer { display: none !important; }
.mobile-tab-bar { display: flex !important; }
body { padding-bottom: 60px !important; }

/* Header */
.site-header { padding: 10px 0; }
.header-inner { gap: 10px; }
.site-logo { font-size: 1.3rem; }

/* ✅ 1. МИНИМАЛЬНЫЕ ОТСТУПЫ КАТАЛОГА НА МОБИЛЬНОМ */
.products-grid { 
    grid-template-columns: repeat(2, 1fr) !important; 
    gap: 3px !important; 
    padding: 0 3px !important; 
}
@media (max-width: 480px) {
    .products-grid { gap: 2px !important; padding: 0 2px !important; }
}
.product-card { border-radius: 4px !important; }
.product-info { padding: 8px !important; }
.product-title { font-size: 0.85rem !important; }
/*.product-front-description { display: none !important; }*/
.product-price { font-size: 1rem !important; margin-bottom: 6px !important; }
.add-to-cart { padding: 8px !important; font-size: 0.7rem !important; }
.category-nav-item { padding: 12px 15px !important; font-size: 0.75rem !important; }

/* Quantity Selector on Mobile */
.quantity-selector { width: 100px !important; height: 30px !important; margin: 0 auto 8px !important; }
.qty-btn { width: 30px !important; font-size: 0.9rem !important; }
.qty-input { width: 40px !important; font-size: 0.85rem !important; }

/* Product Single Mobile */
.product-title-single { font-size: 2.2rem; }
.product-meta { grid-template-columns: 1fr; }
.trust-badges { grid-template-columns: 1fr; gap: 15px; }

/* Cart Mobile */
.cart-items-header { display: none; }
.cart-item { grid-template-columns: 1fr; gap: 15px; text-align: center; justify-items: center; padding: 20px 0; }
.product-details-col { width: 100%; align-items: center; }
.cart-product-image { width: 100px; height: 133px; margin: 0 auto; }
.cart-item .quantity-selector { width: 120px; }
.remove-item { position: static; transform: none; margin: 10px auto 0; }
.cart-summary { position: static; padding: 20px; }
.cart-summary h2 { font-size: 1.3rem; }
.summary-total .summary-value { font-size: 1.8rem; }
.promo-input-group { grid-template-columns: 1fr; }

/* Checkout */
.checkout-form { padding: 20px; }
.checkout-form h2 { font-size: 1.3rem; }
.client-type-tabs { flex-direction: column; gap: 8px; }
.form-row { grid-template-columns: 1fr; gap: 15px; }
.delivery-option, .payment-option { padding: 12px 15px; flex-wrap: wrap; }
.checkout-submit { padding: 15px; font-size: 1rem; }

/* Thank You */
.thank-you-card { padding: 40px 25px; margin: 0 15px; }
.thank-you-card h1 { font-size: 2rem; }
.order-row { flex-direction: column; gap: 5px; }

/* ✅ 2. ФИЛЬТРЫ/SHEET НЕ ЗАХОДЯТ ПОД ФУТЕР И ТАБ-БАР */
.filter-sheet {
    bottom: 60px !important; /* Отступ под мобильный тап-бар */
    max-height: calc(100vh - 80px) !important; /* Учитываем шапку и тап-бар */
    z-index: 9998 !important;
    border-radius: 16px 16px 0 0 !important;
}
.filter-overlay {
    z-index: 9997 !important;
}
}

@media (max-width: 480px) {
    .product-info { padding: 6px !important; }
    .product-price { font-size: 0.95rem !important; }
    .checkout-submit { padding: 14px; font-size: 0.95rem; }
    .summary-total .summary-value { font-size: 1.6rem; }
}
/* ===== КАТАЛОГ: МИНИМАЛЬНЫЕ ОТСТУПЫ НА МОБИЛЬНОМ (1 ММ) ===== */
@media (max-width: 768px) {
    .products-grid {
        gap: 3px !important;       /* ~1 мм между карточками */
        padding: 0 3px !important; /* ~1 мм от краев экрана */
    }
    .product-card {
        border-radius: 2px !important; /* Чуть меньше скругление, чтобы не сливалось */
    }
}
/* ✅ УБИРАЕМ СТРЕЛОЧКИ У ПОЛЕЙ ВВОДА (ЦЕНА / ВЕС) */
/* Для Chrome, Safari, Edge, Opera */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Для Firefox */
input[type="number"] {
    -moz-appearance: textfield;
}

/* Специально для полей в десктопном фильтре */
.desktop-filter-sidebar input[type="number"] {
    -webkit-appearance: none;
    -moz-appearance: textfield;
    appearance: none;
}
/* ✅ СКРЫВАЕМ КРЕСТИК УДАЛЕНИЯ ФИЛЬТРА НА ДЕСКТОПЕ */
/* На мобильном он нужен — в шторке нет прямого доступа к чекбоксам */
/* На десктопе с автоприменением проще снять галочку в сайдбаре */
@media (min-width: 1025px) {
    #desktopActiveFilters .filter-chip-remove {
        display: none !important;
    }
}
/* ===== СКРЫВАЕМ КРЕСТИК ВЕЗДЕ ===== */
/*.filter-chip-remove {
    display: none !important;
}*/
/* ✅ ФИКС СМЕЩЕНИЯ ЗНАЧКА КОРЗИНЫ */
/*.header-actions .cart-btn .cart-count {
    top: -2px !important;
    right: -2px !important;
    position: absolute !important;
}*/
/* Фикс центрирования иконки корзины */
.cart-btn svg {
    display: block !important;
    margin: auto !important; /* Центрирует внутри flex */
}
/* Фикс центрирования иконки на странице каталога */
.products-grid ~ .cart-btn svg,
.catalog-header ~ * .cart-btn svg,
.archive .cart-btn svg {
    margin: 0 !important;
    padding: 0 !important;
}
/* ===== ПЕРЕБИВАЕМ СТИЛИ AURA.CSS ===== */
/* Принудительно центрируем кнопку и иконку */
/* ===== ФИКС КОРЗИНЫ ТОЛЬКО ДЛЯ ДЕСКТОПА ===== */
/* Этот блок сработает только на экранах шире 1024px, 
   поэтому на мобильном корзина будет скрыта стандартно */
@media (min-width: 1025px) {
    .header-actions .cart-btn.desktop-only {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        position: relative !important;
        width: 40px !important;
        height: 40px !important;
        border-radius: 50% !important;
        background: rgba(255,255,255,0.05) !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    .header-actions .cart-btn.desktop-only svg {
        display: block !important;
        margin: 0 !important;
        padding: 0 !important;
        width: 24px !important;
        height: 24px !important;
    }

    .header-actions .cart-btn .cart-count {
        position: absolute !important;
        top: -2px !important;
        right: -2px !important;
        left: auto !important;
        bottom: auto !important;
        background: var(--color-error) !important;
        color: #fff !important;
        font-size: 0.65rem !important;
        min-width: 16px !important;
        height: 16px !important;
        border-radius: 8px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0 4px !important;
        z-index: 10 !important;
    }
}
/* ===== ГАЛЕРЕЯ: КАРУСЕЛЬ + 3:4 + МОБИЛЬНАЯ ВЕРСИЯ БЕЗ ОБРЕЗКИ ===== */

/* === ДЕСКТОП: ВЫРАВНИВАНИЕ ПО ЗАГОЛОВКУ === */
/* ===== НАСТРОЙКА ОТСТУПОВ ОТ ШАПКИ ===== */

/* === ДЕСКТОП (от 1025px) === */
@media (min-width: 1025px) {
    /* 1. Базовый отступ секции (оставляем 0, управление через колонки) */
    .product-section {
        padding-top: 0 !important;
        margin-top: 0 !important;
    }

    .product-grid {
        align-items: start !important;
        margin-top: 0 !important;
    }

    /* 2. ️ Отступ от шапки до ВЕРХА КАРТИНКИ (левая колонка) */
    .product-gallery {
        padding-top: 10px !important; /* 👈 МЕНЯЙТЕ ЭТО ЧИСЛО */
        
        /* Структурные стили галереи (без изменений) */
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        width: fit-content !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        position: relative;
        top: 0 !important;
    }

    /* 3. 📝 Отступ от шапки до НАЗВАНИЯ ТОВАРА (правая колонка) */
    .product-details {
        padding-top: 30px !important; /* 👈 МЕНЯЙТЕ ЭТО ЧИСЛО */
    }

    /* Стили основной картинки (без изменений) */
    .main-image {
        position: relative !important;
        padding-top: 0 !important;
        margin-top: 0 !important;
        height: auto !important;
        max-height: calc(100vh - 110px) !important;
        aspect-ratio: 3 / 4 !important;
        width: auto !important;
        background: transparent !important;
        overflow: hidden;
        border-radius: var(--radius-xl);
        margin-bottom: 15px !important;
        cursor: grab;
        user-select: none;
    }
    .main-image:active { cursor: grabbing; }

    .main-image img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        display: block;
        transition: opacity 0.15s ease, transform 0.15s ease;
    }
    .main-image img.swipe-left { transform: translateX(-20px); opacity: 0; }
    .main-image img.swipe-right { transform: translateX(20px); opacity: 0; }

    /* Стрелки (без изменений) */
    .gallery-nav {
        position: absolute; top: 50%; transform: translateY(-50%);
        width: 44px; height: 44px; background: rgba(0,0,0,0.6);
        backdrop-filter: blur(4px); border: 1px solid rgba(255,255,255,0.2);
        border-radius: 50%; color: #fff; cursor: pointer;
        display: flex; align-items: center; justify-content: center;
        transition: all 0.2s; z-index: 10; opacity: 0; padding: 0;
    }
    .main-image:hover .gallery-nav { opacity: 1; }
    .gallery-nav:hover { background: rgba(0,0,0,0.8); transform: translateY(-50%) scale(1.1); }
    .gallery-nav:active { transform: translateY(-50%) scale(0.95); }
    .gallery-nav svg { width: 20px; height: 20px; pointer-events: none; }
    .gallery-nav.prev { left: 15px; }
    .gallery-nav.next { right: 15px; }
    .main-image.single-image .gallery-nav { display: none !important; }
}

/* === ПРЕВЬЮ (вне медиа-запросов, применяются везде) === */
.thumbnail-grid {
    width: 100% !important; margin: 0 !important;
    display: grid !important; grid-template-columns: repeat(4, 1fr) !important;
    gap: 12px !important; overflow: visible !important; max-height: none !important;
}
.thumbnail {
    aspect-ratio: 3 / 4 !important; border-radius: var(--radius-md);
    overflow: hidden; cursor: pointer; border: 2px solid transparent;
    transition: all 0.2s; opacity: 0.6; padding: 0; width: 100%;
}
.thumbnail:hover { opacity: 0.8; border-color: rgba(255,255,255,0.3); }
.thumbnail.active { opacity: 1; border-color: var(--color-accent); box-shadow: 0 0 0 2px rgba(45,212,191,0.3); }
.thumbnail img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* === МОБИЛЬНЫЙ (до 1024px) === */
@media (max-width: 1024px) {
    /* 4. 📱 Отступ от шапки до верха картинки на мобильном */
    .product-section {
        padding-top: 10px !important; /* 👈 МЕНЯЙТЕ ЭТО ЧИСЛО */
        margin-top: 0 !important;
    }
    
    .product-grid { margin-top: 0 !important; }

    .main-image {
        width: 100% !important;
        max-height: none !important;
        aspect-ratio: 3 / 4 !important;
        margin: 0 auto 15px auto !important;
        cursor: grab;
        position: relative !important;
        top: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    .main-image img {
        object-fit: contain !important;
        width: 100% !important;
        height: auto !important;
        max-height: 70vh !important;
        background: transparent !important;
        display: block !important;
        margin: 0 auto !important;
    }
    
    .gallery-nav { opacity: 1 !important; width: 36px; height: 36px; }
    .gallery-nav.prev { left: 10px; }
    .gallery-nav.next { right: 10px; }
    
    .thumbnail { aspect-ratio: 3 / 4 !important; }
}
/* ✅ КНОПКА МЕССЕНДЖЕРА В ШАПКЕ СПРАВА (МОБИЛЬНЫЙ) */
@media (max-width: 1024px) {
    .messenger-btn,
    .header-actions .messenger-btn {
        position: fixed !important;
        top: 8px !important;        /* 👈 Отступ от верха шапки */
        right: 15px !important;      /* 👈 Отступ от правого края */
        z-index: 10001 !important;   /* Поверх всего */
        
        width: 40px !important;
        height: 40px !important;
        margin: 0 !important;
        padding: 0 !important;
        
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        
        opacity: 1 !important;
        visibility: visible !important;
    }
}
.catalog-banners-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px 0;
    max-width: 1200px;
    margin: 0 auto;
}
.banner-item-vertical {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}
.banner-media-img, .banner-media-video {
    width: 100%;
    height: auto;
    display: block;
    max-height: 500px;
    object-fit: cover;
}
@media (max-width: 768px) {
    .banner-media-img, .banner-media-video {
        max-height: 250px;
    }
}
/* Скрываем tab-bar когда меню открыто */
body.menu-open .mobile-tab-bar {
    display: none !important;
}

/* Увеличиваем отступ снизу в меню */
.mobile-menu-content {
    padding-bottom: calc(20px + env(safe-area-inset-bottom)) !important;
}

/* Последний элемент меню — дополнительный отступ */
.mobile-legal-item:last-child {
    margin-bottom: 30px !important;
}