:root {
            /* Dark Mode */
            --bg-color: #050505;
            --text-main: #ffffff;
            --text-muted: #888888;
            --accent: #ccff00;
            --border-color: #222222;
            --modal-bg: rgba(5, 5, 5, 0.95);
            --btn-bg: #ffffff;
            --btn-text: #000000;
        }
        body.light-mode {
            --bg-color: #f0f0f0;
            --text-main: #111111;
            --text-muted: #666666;
            --accent: #445500;
            --border-color: #e0e0e0;
            --modal-bg: rgba(240, 240, 240, 0.95);
            --btn-bg: #000000;
            --btn-text: #ffffff;
        }
        * { margin: 0; padding: 0; box-sizing: border-box; }
        body {
            background-color: var(--bg-color);
            color: var(--text-main);
            font-family: 'Inter', sans-serif;
            transition: background-color 0.3s ease, color 0.3s ease;
            overflow-x: hidden;
        }
        img { width: 100%; height: 100%; object-fit: cover; display: block; }
        button { cursor: pointer; font-family: inherit; border: none; background: none; }

        /* LANGUAGE LOGIC */
        [data-lang="am"] { display: none; }
        body.lang-am [data-lang="ru"] { display: none; }
        body.lang-am [data-lang="am"] { display: block; }
        body.lang-am span[data-lang="am"], 
        body.lang-am h1[data-lang="am"],
        body.lang-am h2[data-lang="am"] { display: block; }

        /* HEADER */
        header {
            padding: 20px; display: flex; justify-content: space-between; align-items: center;
            position: fixed; top: 0; left: 0; width: 100%;
            background: var(--bg-color); border-bottom: 1px solid var(--border-color); z-index: 100;
        }
        .logo { font-weight: 800; font-size: 1.2rem; letter-spacing: -0.05em; }
        .controls { display: flex; gap: 10px; }
        .btn {
            background: none; border: 1px solid var(--border-color);
            color: var(--text-main); padding: 8px 12px;
            font-weight: 600; border-radius: 4px; transition: 0.2s;
        }
        .btn:hover { border-color: var(--text-main); }
        .lang-btn { color: var(--accent); }

        /* GALLERY GRID */
        .gallery-container {
            padding: 120px 20px 100px; max-width: 1400px; margin: 0 auto;
            display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px;
        }
        .gallery-item {
            position: relative; aspect-ratio: 3/4; cursor: pointer; overflow: hidden;
            border: 1px solid transparent; transition: 0.3s;
        }
        .gallery-item:hover { border-color: var(--accent); }
        .gallery-item img { transition: transform 0.5s ease; }
        .gallery-item:hover img { transform: scale(1.05); }
        .item-overlay {
            position: absolute; inset: 0; background: rgba(0,0,0,0.4);
            display: flex; flex-direction: column; justify-content: flex-end; padding: 20px;
            opacity: 0; transition: 0.3s;
        }
        .gallery-item:hover .item-overlay { opacity: 1; }

        /* MODAL */
        .modal {
            position: fixed; inset: 0; background: var(--modal-bg); z-index: 1000;
            display: flex; opacity: 0; pointer-events: none;
            transition: opacity 0.3s ease; backdrop-filter: blur(10px);
        }
        .modal.active { opacity: 1; pointer-events: all; }
        .modal-content { width: 100%; height: 100%; display: flex; flex-direction: column; position: relative; }
        
        .modal-header {
            padding: 20px; display: flex; justify-content: space-between; align-items: center;
            border-bottom: 1px solid var(--border-color); background: var(--bg-color);
        }
        .close-btn { font-size: 2rem; line-height: 0.5; color: var(--text-main); padding: 10px; }

        .modal-body {
            flex-grow: 1; display: flex; justify-content: center; align-items: center; padding: 40px; position: relative; overflow: hidden;
        }
        .main-image { max-width: 100%; max-height: 70vh; object-fit: contain; transition: opacity 0.3s ease; } /* Уменьшил max-height для места под текст */

        .nav-arrow {
            position: absolute; top: 50%; transform: translateY(-50%);
            background: var(--btn-bg); color: var(--btn-text);
            width: 50px; height: 50px; border-radius: 50%;
            display: flex; justify-content: center; align-items: center; font-size: 1.5rem; z-index: 10; transition: 0.2s;
        }
        .nav-arrow:hover { transform: translateY(-50%) scale(1.1); }
        .prev-arrow { left: 20px; }
        .next-arrow { right: 20px; }

        /* --- UPDATED FOOTER STYLES --- */
        .modal-footer {
            padding: 30px; background: var(--bg-color); border-top: 1px solid var(--border-color);
            display: flex; justify-content: space-between; align-items: flex-start;
            gap: 40px;
        }

        /* Левая колонка: Информация о товаре */
        .info-block { flex: 2; }
        .product-info h2 { font-size: 2rem; font-weight: 800; margin-bottom: 5px; }
        .product-info p.price { color: var(--text-main); font-size: 1.2rem; font-weight: 600; margin-bottom: 20px; }
        
        /* Описание */
        .product-desc {
            color: var(--text-muted);
            font-size: 0.95rem;
            line-height: 1.5;
            margin-bottom: 20px;
            max-width: 600px;
        }

        /* Характеристики (Сетка) */
        .specs-grid {
            display: flex;
            gap: 30px;
            border-top: 1px solid var(--border-color);
            padding-top: 15px;
        }
        .spec-item {
            display: flex; flex-direction: column; gap: 5px;
        }
        .spec-label {
            font-size: 0.75rem;
            text-transform: uppercase;
            color: var(--text-muted);
            letter-spacing: 0.05em;
        }
        .spec-value {
            font-size: 0.9rem;
            font-weight: 500;
        }

        /* Правая колонка: Управление цветами */
        .controls-block { 
            flex: 1; 
            display: flex; 
            flex-direction: column; 
            align-items: flex-end; 
            justify-content: space-between; 
            height: 100%;
        }
        
        .color-dots { display: flex; gap: 10px; }
        .dot {
            width: 12px; height: 12px; background: var(--border-color); cursor: pointer; transition: 0.2s;
        }
        .dot.active { background: var(--accent); transform: scale(1.3); }

        .hint { font-size: 0.75rem; color: var(--text-muted); text-align: right; margin-top: 10px; }

        @media (max-width: 768px) {
            .modal-footer { flex-direction: column; gap: 30px; }
            .controls-block { align-items: flex-start; width: 100%; }
            .color-dots { justify-content: flex-start; }
            .hint { text-align: left; }
            .nav-arrow { width: 40px; height: 40px; }
            .specs-grid { flex-direction: column; gap: 15px; }
        }