/* ============================================
   MAIN.CSS
   Переменные, сброс, базовая типографика, утилиты
   Версия: 4.0.0
   ============================================ */

/* ============================================
   1. ПЕРЕМЕННЫЕ
   ============================================ */

:root {
    /* Цветовая палитра — Primary */
    --color-primary: #6b0182;
    --color-primary-dark: #4e015e;
    --color-primary-light: #c984db;
    --color-primary-gradient: linear-gradient(90deg, #2d2c2d 0%, #6b0182 100%);
    --color-accent: #a600b5;
    
    /* Цветовая палитра — Металлы */
    --color-gold: #d4af37;
    --color-silver: #c0c0c0;
    
    /* Цветовая палитра — Нейтральные */
    --color-white: #ffffff;
    --color-black: #000000;
    --color-gray-50: #fafafa;
    --color-gray-100: #f5f5f5;
    --color-gray-200: #eeeeee;
    --color-gray-300: #e0e0e0;
    --color-gray-400: #cccccc;
    --color-gray-500: #999999;
    --color-gray-600: #666666;
    --color-gray-700: #333333;
    --color-gray-800: #222222;
    --color-gray-900: #111111;
    
    /* Цветовая палитра — Семантические */
    --color-success: #5fbd74;
    --color-error: #cc373c;
    --color-warning: #ffb800;
    
    /* Типографика — Шрифты */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Montserrat', sans-serif;
    --font-accent: 'Inter', sans-serif;
    
    /* Типографика — Размеры (clamp для адаптивности) */
    --text-xs: clamp(10px, 3vw, 12px);
    --text-sm: clamp(12px, 3.5vw, 14px);
    --text-base: clamp(14px, 4vw, 16px);
    --text-lg: clamp(16px, 4.5vw, 18px);
    --text-xl: clamp(18px, 5vw, 20px);
    --text-2xl: clamp(20px, 6vw, 24px);
    --text-3xl: clamp(24px, 7vw, 30px);
    --text-4xl: clamp(28px, 8vw, 36px);
    --text-5xl: clamp(32px, 9vw, 45px);
    --text-6xl: 50px;
    
    /* Типографика — Специальные размеры */
    --hero-title: 60px;
    --hero-subtitle: 30px;
    --registration-title: 30px;
    
    /* Отступы — Базовая система */
    --spacing-xs: 5px;
    --spacing-sm: 10px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 36px;
    --spacing-2xl: 50px;
    --spacing-3xl: 70px;
    --spacing-4xl: 90px;
    --spacing-5xl: 120px;
    
    /* Скругления */
    --border-radius-sm: 4px;
    --border-radius-md: 8px;
    --border-radius-lg: 12px;
    --border-radius-xl: 20px;
    --border-radius-2xl: 30px;
    --border-radius-full: 9999px;
    
    /* Тени */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.08);
    --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.12);
    --shadow-hover: 0 12px 30px rgba(107, 1, 130, 0.3);
    
    /* Переходы */
    --transition-fast: 0.15s ease;
    --transition-base: 0.2s ease;
    --transition-slow: 0.3s ease;
    --transition-smooth: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Z-index слои */
    --z-dropdown: 100;
    --z-preview: 80;
    --z-sticky: 500;
    --z-fixed: 1000;
    --z-modal: 2000;
    --z-header: 9999;
    --z-cart-sticky: 9998;
}

/* ============================================
   2. СБРОС СТИЛЕЙ
   ============================================ */

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    max-width: 100%;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.5;
    color: var(--color-gray-700);
    background-color: var(--color-white);
    overflow-x: hidden;
    max-width: 100%;
}

/* ============================================
   3. ACCESSIBILITY
   ============================================ */

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--color-primary);
    color: var(--color-white);
    padding: var(--spacing-sm);
    z-index: var(--z-modal);
    transition: top var(--transition-fast);
    text-decoration: none;
}

.skip-link:focus {
    top: 0;
}

.visually-hidden:not(:focus):not(:active) {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ============================================
   4. КОНТЕЙНЕР
   ============================================ */

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--spacing-xl);
    position: relative;
    z-index: 1;
    overflow-x: visible;
}

@media (min-width: 640px) {
    .container {
        padding: 0 var(--spacing-2xl);
    }
}

@media (min-width: 1024px) {
    .container {
        padding: 0 var(--spacing-3xl);
    }
}

/* ============================================
   5. ТИПОГРАФИКА
   ============================================ */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 800;
    line-height: 1.2;
    color: var(--color-gray-800);
}

.section-title {
    font-size: var(--text-6xl);
    font-weight: 800;
    margin-bottom: var(--spacing-3xl);
    text-align: center;
}

.section-title span {
    position: relative;
    display: inline-block;
}

.section-title span::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 56px;
    height: 2px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-gold));
    border-radius: var(--border-radius-full);
}

.gradient-text {
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent), var(--color-gold));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    background-size: 200% 200%;
    animation: gradientShift 6s ease infinite;
}

.elegant-text {
    font-family: var(--font-heading);
    font-weight: 700;
}

/* ============================================
   6. СЕКЦИИ
   ============================================ */

.section {
    padding: var(--spacing-5xl) 0;
}

/* ============================================
   7. ПЛАВАЮЩИЕ ФОНОВЫЕ ПЯТНА
   ============================================ */

.floating-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.floating-blob {
    position: absolute;
    border-radius: 50%;
    will-change: transform;
}

.floating-blob.gold {
    background: radial-gradient(circle, var(--color-gold) 0%, rgba(212, 175, 55, 0.3) 40%, transparent 70%);
    width: 700px;
    height: 700px;
    top: 20%;
    left: -150px;
    opacity: 0.25;
    filter: blur(90px);
    animation: floatGold 25s infinite ease-in-out;
}

.floating-blob.silver {
    background: radial-gradient(circle, var(--color-silver) 0%, rgba(192, 192, 192, 0.5) 40%, transparent 70%);
    width: 700px;
    height: 700px;
    bottom: 10%;
    right: -150px;
    opacity: 0.5; /* Увеличено с 0.3 */
    filter: blur(85px);
    animation: floatSilver 25s infinite ease-in-out;
}

.floating-blob.purple {
    background: radial-gradient(circle, var(--color-primary) 0%, rgba(107, 1, 130, 0.2) 40%, transparent 70%);
    width: 500px;
    height: 500px;
    top: 45%;
    left: 35%;
    opacity: 0.18;
    filter: blur(80px);
    animation: floatPurple 25s infinite ease-in-out;
}

/* ============================================
   8. АНИМАЦИИ
   ============================================ */

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes floatGold {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(60px, -40px) scale(1.05); }
    66% { transform: translate(-40px, 30px) scale(0.95); }
}

@keyframes floatSilver {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(-80px, 50px) scale(1.1); }
    66% { transform: translate(50px, -30px) scale(0.95); }
}

@keyframes floatPurple {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(40px, -40px) scale(1.05); }
    66% { transform: translate(-30px, 30px) scale(0.95); }
}

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

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

@keyframes fadeInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

/* ============================================
   9. УМЕНЬШЕНИЕ ДВИЖЕНИЯ
   ============================================ */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ============================================
   10. ГЛОБАЛЬНЫЕ ФИКСЫ
   ============================================ */

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    cursor: pointer;
    font-family: inherit;
}

a {
    text-decoration: none;
    color: inherit;
}

ul, ol {
    list-style: none;
}