:root {
  /* --- ЦВЕТОВАЯ ПАЛИТРА (Светлая) --- */
  --bg-page: #dbe4ef;
  
  /* Стекло */
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 1);
  --glass-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.15);
  
  --card-bg: #ffffff; 
  --card-border: transparent;
  --card-shadow: 0 4px 15px rgba(0,0,0,0.03);
  
  --input-bg: #e5e5ea;
  --input-text: #1d1d1f;
  
  --nav-bg: rgba(255,255,255,0.6);
  --nav-text: #86868b;
  --nav-active-bg: #ffffff;
  --nav-active-text: #1d1d1f;
  
  --nav-bg-mobile: rgba(255, 255, 255, 0.85);
  --nav-mobile-backdrop: blur(20px);

  --accent: #ff7b00;
  --accent-gradient: linear-gradient(135deg, #ff8800, #ff4d00);
  
  --text-main: #1d1d1f;
  --text-muted: #86868b;
  
  --color-success: #34c759;
  --color-error: #ff3b30;
  
  --radius-card: 32px;
  --radius-pill: 50px;
  --ease-spring: cubic-bezier(0.25, 0.8, 0.25, 1);
  
  --dot-inactive: rgba(0,0,0,0.1); 
}

/* --- ТЕМНАЯ ТЕМА --- */
body.dark-mode {
  --bg-page: #0f1115;
  --glass-bg: rgba(20, 20, 23, 0.80);
  --glass-border: rgba(255, 255, 255, 0.1);
  --glass-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.5);
  
  --card-bg: rgba(35, 37, 40, 0.7);
  --card-border: rgba(255,255,255,0.05);
  --card-shadow: 0 4px 15px rgba(0,0,0,0.2);
  
  --input-bg: rgba(255,255,255,0.1);
  --input-text: #ffffff;
  
  --nav-bg: rgba(30, 30, 35, 0.8);
  --nav-text: #a1a1a6;
  --nav-active-bg: rgba(255,255,255,0.15);
  --nav-active-text: #ffffff;
  
  --nav-bg-mobile: rgba(40, 40, 45, 0.9);
  
  --text-main: #f5f5f7;
  --text-muted: #a1a1a6;
  
  --accent: #ff9500; 
  --dot-inactive: rgba(255,255,255,0.2);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

/* 1. БАЗА (Возвращаем стили ПК в основу) */
body {
  margin: 0; padding: 0;
  min-height: 100vh;
  font-family: 'Inter', sans-serif;
  background: var(--bg-page);
  color: var(--text-main);
  transition: background 0.3s;
  overflow-x: hidden;
  
  /* СТИЛИ ПК (CENTERED) - ДЕЛАЕМ ИХ БАЗОВЫМИ */
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px 20px; 
}

/* --- ФОНОВЫЕ ЭЛЕМЕНТЫ --- */
.energy-wrapper { position: fixed; top: 0; left: 0; width: 100%; height: 100%; overflow: hidden; z-index: -2; pointer-events: none; }
.energy-trace { position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.5; animation: floatEnergy 15s infinite ease-in-out alternate; will-change: transform; }
.trace-1 { top: -10%; left: -10%; width: 700px; height: 700px; background: radial-gradient(circle, rgba(255, 123, 0, 0.25) 0%, transparent 70%); }
.trace-2 { bottom: -10%; right: -10%; width: 600px; height: 600px; background: radial-gradient(circle, rgba(255, 60, 0, 0.2) 0%, transparent 70%); }
@keyframes floatEnergy { 0% { transform: translate(0, 0) scale(1); } 100% { transform: translate(-30px, 20px) scale(0.9); } }

#floatingLogosContainer { position: fixed; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1; overflow: hidden; }
.bg-tiktok-icon { position: absolute; object-fit: contain; filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.4)); animation: floatLogo ease-in-out infinite; }
@keyframes floatLogo { 0% { transform: translateY(0) rotate(0deg) scale(1); } 50% { transform: translateY(-30px) rotate(10deg) scale(1.05); } 100% { transform: translateY(0) rotate(0deg) scale(1); } }

/* --- ГЛАВНЫЙ КОНТЕЙНЕР (App Shell) --- */
.app-shell { width: 100%; max-width: 900px; z-index: 10; position: relative; }

.shell-inner {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-card);
  box-shadow: var(--glass-shadow);
  display: flex; flex-direction: column; 
  padding: 40px; 
  min-height: 800px; 
  position: relative;
  overflow: visible !important;
  transition: background 0.4s, border-color 0.4s;
}

/* HEADER */
header.app-header { 
    display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; 
    margin-bottom: 30px; flex-shrink: 0; position: relative; z-index: 100; 
}
.brand { display: flex; align-items: center; gap: 12px; justify-self: start; cursor: pointer; }
.brand-logo-img { width: 44px; height: 44px; object-fit: contain; filter: drop-shadow(0 4px 6px rgba(255, 100, 0, 0.2)); transition: 0.4s; }
.brand:hover .brand-logo-img { transform: scale(1.1) rotate(5deg); }
.brand-text-main { font-size: 20px; font-weight: 800; letter-spacing: -0.5px; line-height: 1.1; }
.brand-text-sub { font-size: 12px; color: var(--text-muted); font-weight: 500; }

/* MENU (Десктоп) */
.header-nav { 
    justify-self: center; display: flex; gap: 4px; background: var(--nav-bg); 
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    padding: 5px; border-radius: 50px; border: 1px solid var(--glass-border);
    position: relative; z-index: 1001; box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.nav-link { color: var(--nav-text); font-size: 14px; font-weight: 600; padding: 10px 24px; border-radius: 24px; transition: all 0.2s; cursor: pointer; }
.nav-link.active { background: var(--nav-active-bg); color: var(--nav-active-text); box-shadow: 0 4px 12px rgba(0,0,0,0.06); }

/* КНОПКИ В ШАПКЕ */
.header-right { justify-self: end; display: flex; align-items: center; gap: 12px; position: relative; z-index: 1001; }
.theme-toggle-btn, .lang-switch-btn, .cart-icon-btn {
    border: 1px solid var(--glass-border); background: var(--nav-bg); color: var(--text-main);
    cursor: pointer; transition: all 0.3s;
    width: 44px; height: 44px; border-radius: 50%; padding: 0;
    display: flex; align-items: center; justify-content: center; overflow: hidden; 
}
.header-icon-unified { width: 26px; height: 26px; object-fit: contain; display: block; transition: transform 0.3s; pointer-events: none; }
.theme-toggle-btn:hover, .lang-switch-btn:hover, .cart-icon-btn:hover { background: var(--nav-active-bg); transform: scale(1.05); }
.theme-toggle-btn:hover .header-icon-unified { transform: rotate(15deg); }
.cart-icon-btn:hover .header-icon-unified { transform: translateX(2px); }
#langIcon { transform: scale(0.85); border-radius: 50%; }
.cart-badge {
  position: absolute; top: -2px; right: -2px; min-width: 20px; height: 20px; padding: 0 5px;
  border-radius: 20px; background: var(--accent); color: #fff; font-size: 10px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 10px rgba(255, 123, 0, 0.4);
  transform: scale(0); transition: transform 0.3s; pointer-events: none;
}
.cart-badge.has-items { transform: scale(1); }

/* CONTENT */
.views-wrapper { flex: 1; position: relative; display: flex; flex-direction: column; overflow: visible; z-index: 10; }
.view-section { display: none; flex-direction: column; height: 100%; flex: 1; }
.view-section.view-active { display: flex; animation: fadeInView 0.4s ease; }
@keyframes fadeInView { from { opacity: 0; } to { opacity: 1; } }

.step-header, .view-header { text-align: center; margin-bottom: 20px; flex-shrink: 0; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.step-title, .view-title { font-size: 32px; font-weight: 800; letter-spacing: -0.8px; margin: 0; line-height: 1.1; }
.step-subtitle, .view-subtitle { font-size: 16px; color: var(--text-muted); margin: 0; }

.steps-indicator { display: flex; justify-content: center; gap: 8px; margin-top: 15px; }
.step-dot { width: 36px; height: 6px; border-radius: 10px; background: var(--dot-inactive); overflow: hidden; }
.step-dot-inner { width: 100%; height: 100%; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform 0.4s var(--ease-spring); }
.step-dot.active .step-dot-inner { transform: scaleX(1); }

/* SCROLL AREA - ИСПРАВЛЕНА ОБРЕЗКА ТЕНЕЙ (ПК) */
.scroll-area { 
    flex: 1; 
    overflow-y: auto; 
    padding: 30px 40px; 
    margin: 0 -40px; 
    scrollbar-width: thin; 
    scrollbar-color: rgba(0,0,0,0.1) transparent; 
    overflow-x: hidden; 
}

.screen { display: none; flex-direction: column; height: 100%; flex: 1;}
.screen.screen-active { display: flex; animation: zoomInSoft 0.4s var(--ease-spring); }
@keyframes zoomInSoft { from { opacity: 0; transform: scale(0.98); } to { opacity: 1; transform: scale(1); } }
.stagger-list > * { opacity: 0; animation: itemPopUp 0.5s var(--ease-spring) forwards; }
@keyframes itemPopUp { 0% { opacity: 0; transform: scale(0.95) translateY(10px); } 100% { opacity: 1; transform: scale(1) translateY(0); } }

/* CARDS */
.type-card { 
    position: relative; border-radius: 26px; background: var(--card-bg); border: 2px solid var(--card-border); 
    padding: 24px; display: flex; align-items: center; justify-content: space-between; gap: 15px; 
    cursor: pointer; transition: 0.3s var(--ease-spring); box-shadow: var(--card-shadow); margin-bottom: 16px;
}
.type-card:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(0,0,0,0.08); }
.type-card.active { border-color: var(--accent); background: var(--nav-active-bg); box-shadow: 0 15px 40px rgba(255, 123, 0, 0.15); }
.type-name { font-size: 18px; font-weight: 700; margin-bottom: 4px; }
.type-desc { font-size: 14px; color: var(--text-muted); }
.type-price { font-size: 18px; font-weight: 800; white-space: nowrap; } 
.type-tag { display: inline-block; margin-top: 4px; padding: 4px 10px; border-radius: 12px; font-size: 10px; font-weight: 800; }
.type-card.disabled { pointer-events: none; opacity: 0.6; }
.sold-out-label { color: #ff3b30; font-size: 11px; font-weight: 800; background: rgba(255, 59, 48, 0.1); padding: 5px 10px; border-radius: 8px; margin-top: 6px; }

/* LOCATION */
.location-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; padding: 10px; }
.location-card { border-radius: 22px; background: var(--card-bg); border: 2px solid transparent; padding: 20px; cursor: pointer; transition: all 0.2s; box-shadow: var(--card-shadow); display: flex; flex-direction: column; gap: 12px; }
.location-card:hover { transform: scale(1.03); z-index: 2; }
.location-card.selected { border-color: var(--accent); background: var(--nav-active-bg); box-shadow: 0 10px 30px rgba(255, 123, 0, 0.25); }
.location-card.disabled { opacity: 0.5; pointer-events: none; filter: grayscale(100%); }
.loc-header { display: flex; justify-content: space-between; }
.loc-flag-img { width: 32px; height: 32px; object-fit: contain; }
.loc-qty-badge { background: rgba(0,0,0,0.06); padding: 4px 8px; border-radius: 8px; font-size: 11px; font-weight: 700; color: var(--text-muted); }
.loc-name { font-weight: 800; font-size: 16px; margin-bottom: 2px; }
.loc-status { font-size: 12px; color: #34c759; font-weight: 600; }
.loc-status.soldout { color: #ff3b30; }
.loc-footer { margin-top: auto; border-top: 1px solid rgba(0,0,0,0.04); padding-top: 10px; display: flex; justify-content: space-between; align-items: center; }
.loc-price { font-weight: 800; font-size: 15px; white-space: nowrap; }

/* КОРЗИНА И ФОРМА */
.checkout-form { margin-top: 20px; display: flex; flex-direction: column; gap: 12px; padding: 0 5px; }
.input-group { position: relative; display: flex; gap: 8px; align-items: center; }
.custom-input { width: 100%; padding: 16px 20px; border-radius: 18px; border: 1px solid transparent; background: var(--input-bg); color: var(--input-text); font-size: 15px; outline: none; transition: 0.3s; font-family: 'Inter', sans-serif; }
.custom-input:focus { border-color: var(--accent); background: var(--input-bg-focus); box-shadow: 0 0 0 4px rgba(255, 123, 0, 0.1); }
.custom-input.error { border-color: var(--color-error); box-shadow: 0 0 0 4px rgba(255, 59, 48, 0.1); }
.btn-apply { padding: 0 20px; height: 52px; border-radius: 18px; background: var(--card-bg); border: 1px solid var(--card-border); font-weight: 700; font-size: 13px; cursor: pointer; transition: 0.3s; color: var(--text-main); white-space: nowrap; display: flex; align-items: center; justify-content: center; }
.btn-apply:hover { background: var(--accent); color: white; border-color: var(--accent); }
#cartItems > div { background: var(--card-bg) !important; color: var(--text-main) !important; box-shadow: var(--card-shadow) !important; }
.promo-check { width: 32px; height: 32px; background: var(--color-success); border-radius: 50%; color: white; display: flex; align-items: center; justify-content: center; font-size: 16px; margin-left: 10px; animation: popIn 0.3s; }
@keyframes popIn { from { transform: scale(0); } to { transform: scale(1); } }
.field-error-msg { font-size: 12px; color: var(--color-error); font-weight: 600; margin-left: 15px; margin-top: -5px; display: none; }
.field-error-msg.show { display: block; }
.control-row { background: var(--card-bg); padding: 20px 30px; border-radius: 28px; display: flex; justify-content: space-between; align-items: center; box-shadow: var(--card-shadow); margin-top: 15px; flex-shrink: 0; border: 1px solid var(--card-border); }
.price-main { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; }
.price-old { font-size: 14px; text-decoration: line-through; color: var(--text-muted); font-weight: 500; margin-right: 8px; }
.qty-btn { width: 36px; height: 36px; border-radius: 50%; border: none; background: var(--input-bg); color: var(--text-main); font-weight: 600; cursor: pointer; transition: 0.2s; font-size: 18px; display: flex; align-items: center; justify-content: center; }

.standard-footer { padding: 20px 20px 60px 20px; margin: 0 -20px; display: flex; gap: 8px; justify-content: flex-end; flex-shrink: 0; margin-top: auto; overflow: visible !important; position: relative; z-index: 10; animation: fadeInUpStandard 0.4s var(--ease-spring) forwards; opacity: 0; }
@keyframes fadeInUpStandard { from { opacity: 0; transform: translateY(15px); } to { opacity: 1; transform: translateY(0); } }
.btn { padding: 18px 38px; border-radius: var(--radius-pill); font-size: 15px; font-weight: 700; border: none; cursor: pointer; transition: all 0.3s var(--ease-spring); display: inline-flex; align-items: center; justify-content: center; position: relative; z-index: 1; letter-spacing: 0.3px; overflow: visible; margin: 5px; }
.btn:active { transform: scale(0.96); }
.btn-primary { background: var(--accent-gradient); color: white; box-shadow: 0 0 20px rgba(255, 123, 0, 0.5); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 0 35px rgba(255, 123, 0, 0.8); }
.btn-outline { background: var(--card-bg); color: var(--text-main); border: 1px solid var(--card-border); box-shadow: 0 4px 10px rgba(0,0,0,0.02); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); background: var(--nav-active-bg); box-shadow: 0 0 20px rgba(255, 123, 0, 0.2); transform: translateY(-2px); }

.support-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; padding: 20px 10px 30px 10px; }
.contact-card { background: var(--card-bg); padding: 40px 20px; border-radius: 30px; text-align: center; border: 1px solid var(--card-border); transition: 0.3s; display: flex; flex-direction: column; align-items: center; justify-content: center; text-decoration: none; color: var(--text-main); box-shadow: var(--card-shadow); }
.contact-card:hover { transform: translateY(-8px); box-shadow: 0 20px 40px rgba(0,0,0,0.08); border-color: rgba(255, 123, 0, 0.1); }
.contact-icon-img { width: 64px; height: 64px; object-fit: contain; margin-bottom: 20px; filter: drop-shadow(0 8px 15px rgba(0,0,0,0.1)); }
.contact-title { font-weight: 800; font-size: 20px; margin-bottom: 8px; }
.contact-value { color: var(--accent); font-weight: 600; font-size: 14px; background: rgba(255, 123, 0, 0.1); padding: 8px 16px; border-radius: 16px; }

.faq-container { display: flex; flex-direction: column; gap: 14px; padding: 5px; }
.faq-item { background: var(--card-bg); border-radius: 20px; overflow: hidden; border: 1px solid var(--card-border); transition: all 0.3s; cursor: pointer; box-shadow: var(--card-shadow); }
.faq-item:hover { box-shadow: 0 8px 20px rgba(0,0,0,0.04); transform: translateY(-1px); }
.faq-item.active { border-color: rgba(255, 123, 0, 0.5); box-shadow: 0 10px 25px rgba(255, 123, 0, 0.1); }
.faq-question { padding: 22px; font-weight: 700; font-size: 16px; display: flex; justify-content: space-between; align-items: center; color: var(--text-main); }
.faq-question::after { content: '+'; font-size: 24px; color: var(--accent); font-weight: 700; transition: transform 0.4s; }
.faq-item.active .faq-question::after { transform: rotate(45deg); }
.faq-answer { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.4s; opacity: 0.8; }
.faq-item.active .faq-answer { grid-template-rows: 1fr; opacity: 1; }
.faq-inner { overflow: hidden; padding: 0 22px; font-size: 15px; color: var(--text-muted); line-height: 1.6; }
.faq-item.active .faq-inner { padding-bottom: 25px; }
.faq-inner p, .faq-inner ul { margin: 5px 0; }
.faq-inner ul { padding-left: 20px; }
.support-badge { display: inline-block; background: #34c759; color: white; padding: 6px 14px; border-radius: 20px; font-size: 11px; font-weight: 800; margin: 0; box-shadow: 0 4px 15px rgba(52, 199, 89, 0.4); }

.main-footer { margin-top: 20px; padding-top: 20px; border-top: 1px solid rgba(0,0,0,0.05); text-align: center; font-size: 12px; color: #999; padding-bottom: 20px;}

/* =========================================
   🎄 НОВОГОДНИЙ ПАК (ОСНОВНЫЕ СТИЛИ)
   ========================================= */

#snowCanvas { position: fixed; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; z-index: 0; }

.garland-wrap {
    position: absolute; top: 0; left: 0; width: 100%; height: 0;
    top: 15px; /* Базовая высота для ПК */
    z-index: 2001; pointer-events: none; overflow: visible;
}
.g-bulb {
    width: 10px; height: 10px; border-radius: 50%; position: absolute; top: -5px; left: 50%; transform: translateX(-50%); z-index: 2;
    animation: glow 1.5s infinite alternate ease-in-out;
}
.g-bulb.c1 { background: #ff7b00; box-shadow: 0 0 10px 2px rgba(255, 123, 0, 0.8); }
.g-bulb.c2 { background: #007aff; box-shadow: 0 0 10px 2px rgba(0, 122, 255, 0.8); }
body.dark-mode .g-bulb.c2 { background: #ffffff; box-shadow: 0 0 10px 2px rgba(255, 255, 255, 1.0); }
.g-bulb.c3 { background: #ffcc00; box-shadow: 0 0 10px 2px rgba(255, 204, 0, 0.8); }
.g-bulb.c4 { background: #ff3b30; box-shadow: 0 0 10px 2px rgba(255, 59, 48, 0.7); }
@keyframes glow { 0% { opacity: 0.8; transform: translateX(-50%) scale(1); } 100% { opacity: 1; transform: translateX(-50%) scale(1.1); } }


/* =========================================
   📱 АБСОЛЮТНО НОВЫЙ АДАПТИВ (APP-LIKE)
   ========================================= */
/* ВАЖНО: Этот блок должен быть в самом низу файла, чтобы перебивать остальные стили! */
@media (max-width: 768px) {
    /* 1. Сброс для мобильного потока (ВКЛЮЧАЯ ПЛАНШЕТЫ) */
    body {
        display: block; padding: 0; margin: 0; background: var(--bg-page);
        overflow-x: hidden;
        padding-top: 20px; /* Отступ сверху для гирлянды */
    }

    .app-shell { max-width: 100%; margin: 0; padding: 0; border: none; box-shadow: none; background: transparent; }
    .shell-inner {
        border-radius: 0; border: none; box-shadow: none;
        backdrop-filter: none; -webkit-backdrop-filter: none; background: transparent; 
        padding: 20px 15px 120px 15px; /* Увеличенный нижний отступ для плавающего меню */
        min-height: 100vh;
    }
    
    /* ФИКС ГИРЛЯНДЫ: Поднимаем на мобилке */
    .garland-wrap {
        top: 0px; /* <--- МЕНЯЙ ЗДЕСЬ, ЕСЛИ НУЖНО ЕЩЕ ВЫШЕ/НИЖЕ */
    }

    /* ФИКС ШАПКИ: Прижимаем иконки вправо */
    header.app-header {
        /* Уходим от десктопного Grid */
        display: flex;
        justify-content: space-between;
        margin-top: 0; 
        margin-bottom: 20px;
        padding: 0 5px; 
    }
    .brand { flex: 1; } /* Лого занимает место */
    .header-right { 
        justify-self: end;
        margin-left: auto; /* Жестко прижимаем иконки вправо */
    }
    
    /* 2. МЕНЮ (Apple Dock) */
    .header-nav { 
        position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%); 
        width: 90%; max-width: 350px; justify-content: space-between; padding: 10px 15px;
        
        background: var(--nav-bg-mobile); backdrop-filter: blur(25px); -webkit-backdrop-filter: blur(25px);
        box-shadow: 0 10px 40px rgba(0,0,0,0.15); border: 1px solid rgba(255,255,255,0.2); z-index: 5000;
    }
    .nav-link { font-size: 13px; }

    /* 3. ФУТЕР И КНОПКИ */
    .standard-footer {
        flex-direction: column; width: 100%; padding: 20px 0 0 0; margin: 0;
    }
    .btn { width: 100%; margin: 5px 0; }

    .support-grid { grid-template-columns: 1fr; }
    .location-grid { grid-template-columns: repeat(2, 1fr); }
    
    /* 4. СКРОЛЛ БЕЗ ОБРЕЗКИ ТЕНЕЙ (MOBILE FIX) */
    .scroll-area { 
        /* Растягиваем контейнер на 15px влево и вправо, компенсируя отступы shell-inner */
        margin: 0 -15px; 
        /* Добавляем внутренний отступ 25px, чтобы тени карточек не обрезались */
        padding: 20px 25px; 
        overflow-y: auto; 
        overflow-x: hidden; 
    }
    
    .main-footer { padding-bottom: 100px; }
}