
/* --- 1. ГЛОБАЛЬНЫЕ НАСТРОЙКИ --- */
:root {
    --malachite-deep: #021a12;
    --malachite-main: #0b3d2e;
    --malachite-light: #186049;
    --gold-shine: #f9d976;
    --gold-dark: #b8860b;
    --cream: #fdfbf7;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-header: rgba(2, 26, 18, 0.9);
    --glass-border: rgba(255, 255, 255, 0.1);
    --font-serif: 'Playfair Display', serif;
    --font-sans: 'Montserrat', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: var(--malachite-deep);
    color: var(--cream);
    font-family: var(--font-sans);
    line-height: 1.7;
    overflow-x: hidden;
    position: relative;
}

/* Живой фон (Ambient Background) */
body::before {
    content: '';
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: 
        radial-gradient(circle at 15% 50%, rgba(11, 61, 46, 0.4) 0%, transparent 50%),
        radial-gradient(circle at 85% 30%, rgba(184, 134, 11, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 50% 80%, rgba(24, 96, 73, 0.2) 0%, transparent 60%);
    z-index: -2;
    animation: bg-pulse 15s ease-in-out infinite alternate;
}

@keyframes bg-pulse {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.1); opacity: 1; }
}

/* Текстура шума для "каменного" эффекта */
.noise-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.04'/%3E%3C/svg%3E");
    z-index: -1;
    pointer-events: none;
}

#particles-js { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 2;
}

/* --- 2. ШАПКА И МОБИЛЬНОЕ МЕНЮ --- */
.main-header {
    position: fixed;
    top: 0; left: 0; width: 100%;
    padding: 15px 0;
    z-index: 1000;
    background: var(--glass-header);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(184, 134, 11, 0.2);
    transition: 0.3s;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gold-shine);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1001;
}

/* Навигация */
.nav-wrapper {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    color: var(--cream);
    font-size: 0.95rem;
    font-weight: 500;
    position: relative;
    text-decoration: none;
    transition: 0.3s;
}

.nav-links a:hover { color: var(--gold-shine); }

.auth-buttons { display: flex; gap: 15px; align-items: center; }

.btn-text {
    background: transparent;
    color: var(--gold-shine);
    border: 1px solid var(--gold-dark);
    padding: 8px 20px;
    border-radius: 30px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: 0.3s;
}
.btn-text:hover { background: rgba(184, 134, 11, 0.2); color: #fff; }

/* Бургер меню */
.burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    z-index: 1001;
}
.burger span {
    width: 25px; height: 3px; background: var(--gold-shine); transition: 0.3s;
}

/* АДАПТИВ ШАПКИ */
@media (max-width: 900px) {
    .nav-wrapper {
        position: fixed;
        top: 0; right: -100%;
        width: 100%; height: 100vh;
        background: var(--malachite-deep);
        flex-direction: column;
        justify-content: center;
        transition: 0.4s ease-in-out;
        z-index: 1000;
    }
    .nav-wrapper.active { right: 0; }
    .nav-links { flex-direction: column; align-items: center; gap: 40px; margin-bottom: 40px; }
    .nav-links a { font-size: 1.5rem; }
    .burger { display: flex; }
    
    /* Анимация бургера */
    .burger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 6px); }
    .burger.active span:nth-child(2) { opacity: 0; }
    .burger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -6px); }
}

/* --- 3. ТИПОГРАФИКА --- */
h1, h2, h3 {
    font-family: var(--font-serif);
    color: var(--gold-shine);
    background: linear-gradient(to right, #fbf5b7, #b8860b, #fbf5b7);
    background-size: 200% auto;
    animation: shine 5s linear infinite;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
@keyframes shine { to { background-position: 200% center; } }

h1 { 
    font-size: clamp(2.2rem, 6vw, 4.5rem); 
    line-height: 1.1; 
    margin-bottom: 1.5rem;
}

.section-title-wrapper { text-align: center; margin-bottom: 3.5rem; width: 100%; position: relative; }

h2 { 
    font-size: clamp(1.8rem, 4vw, 2.8rem); 
    display: inline-block;
}

/* Узор под заголовком */
.divider-ornament {
    display: block;
    margin: 10px auto 0;
    width: 150px;
    height: 2px;
    background: radial-gradient(circle, var(--gold-dark) 0%, transparent 100%);
    position: relative;
}
.divider-ornament::after {
    content: '❖';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    background: var(--malachite-deep);
    padding: 0 10px;
    color: var(--gold-dark);
    font-size: 1.2rem;
}

p { margin-bottom: 1rem; font-size: 1.05rem; opacity: 0.9; color: #e0e0e0; }
a.text-link { color: var(--gold-shine); text-decoration: none; border-bottom: 1px dotted var(--gold-dark); }

/* --- 4. КОМПОНЕНТЫ --- */
.btn-gold {
    background: linear-gradient(135deg, #b8860b, #f0e68c, #b8860b);
    background-size: 200% auto;
    border: none;
    padding: 16px 40px;
    color: #051910;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    border-radius: 50px;
    cursor: pointer;
    transition: 0.5s;
    box-shadow: 0 10px 25px rgba(0,0,0,0.4);
    position: relative;
    overflow: hidden;
}

.btn-gold:hover {
    background-position: right center;
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(184, 134, 11, 0.3);
}
.btn-gold.small { padding: 10px 25px; font-size: 0.85rem; }

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-top: 1px solid rgba(255,255,255,0.2);
    border-radius: 20px;
    box-shadow: 0 15px 40px 0 rgba(0, 0, 0, 0.4);
}

/* --- 5. HERO SECTION --- */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 80px;
    position: relative;
    overflow: hidden;
}

/* Фоновый кристалл для объема */
.floating-crystal {
    position: absolute;
    right: -100px; top: 20%;
    width: 500px; height: 500px;
    background: radial-gradient(circle, rgba(24, 96, 73, 0.3) 0%, transparent 70%);
    filter: blur(40px);
    z-index: 0;
    animation: float 10s infinite ease-in-out;
}
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-30px); } }

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text .subtitle {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    font-style: italic;
    font-family: var(--font-serif);
    color: #ccc;
    margin-bottom: 30px;
    display: block;
    border-left: 3px solid var(--gold-dark);
    padding-left: 20px;
}

.registration-form-container {
    padding: 40px;
    transform: perspective(1000px) rotateY(-5deg);
    transition: transform 0.5s ease;
    position: relative;
}
.registration-form-container:hover { transform: perspective(1000px) rotateY(0deg); }

/* Золотая рамка вокруг формы */
.registration-form-container::before {
    content: ''; position: absolute; inset: 5px; 
    border: 1px solid rgba(249, 217, 118, 0.2); 
    border-radius: 16px; pointer-events: none;
}

.form-input {
    width: 100%;
    padding: 16px;
    margin-bottom: 20px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(184, 134, 11, 0.4);
    border-radius: 8px;
    color: #fff;
    transition: 0.3s;
    font-size: 1rem;
}
.form-input:focus { outline: none; border-color: var(--gold-shine); background: rgba(0,0,0,0.5); box-shadow: 0 0 15px rgba(184, 134, 11, 0.2); }

/* Адаптив Hero */
@media (max-width: 900px) {
    .hero-content { grid-template-columns: 1fr; text-align: center; gap: 3rem; }
    .hero-text .subtitle { border-left: none; border-bottom: 2px solid var(--gold-dark); padding-left: 0; padding-bottom: 10px; display: inline-block;}
    .registration-form-container { transform: none; width: 100%; max-width: 500px; margin: 0 auto; }
    .floating-crystal { right: -50%; top: 10%; opacity: 0.5; }
}

/* --- КАЛЕЙДОСКОП (Заполнение пустоты) --- */
.kaleidoscope-section { padding: 0 0; text-align: center; position: relative; }

/* Орнаментальный SVG разделитель */
.section-divider {
    width: 100%; height: 50px; 
    background-image: url("data:image/svg+xml,%3Csvg width='40' height='10' viewBox='0 0 40 10' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 0 L25 5 L20 10 L15 5 Z' fill='%23b8860b' opacity='0.3'/%3E%3C/svg%3E");
    margin: 0 0;
    opacity: 0.5;
}

.kaleidoscope-wrapper {
    width: 280px; height: 280px; margin: 40px auto; position: relative;
    display: flex; justify-content: center; align-items: center;
}
.k-layer { position: absolute; border-radius: 50%; mix-blend-mode: screen; }
.k-1 { width: 100%; height: 100%; background: conic-gradient(from 0deg, var(--malachite-main), var(--gold-dark), var(--malachite-main)); animation: spin 25s linear infinite; opacity: 0.6; box-shadow: 0 0 50px rgba(11, 61, 46, 0.5); }
.k-2 { width: 75%; height: 75%; border: 1px solid var(--gold-shine); background: conic-gradient(from 45deg, transparent, rgba(249, 217, 118, 0.2), transparent); animation: spin-rev 20s linear infinite; }
.k-3 { width: 50%; height: 50%; background: radial-gradient(circle, var(--gold-shine) 0%, transparent 60%); animation: spin 15s linear infinite; opacity: 0.4; }
@keyframes spin { 100% { transform: rotate(360deg); } }
@keyframes spin-rev { 100% { transform: rotate(-360deg); } }



/* --- СТИЛИ ДЛЯ НОВЫХ БЛОКОВ (4, 5, 6) --- */

/* Блок 4: Создательница */
.creator-wrapper {
    display: flex;
    align-items: center;
    gap: 40px;
    padding: 40px;
    max-width: 900px;
    margin: 0 auto;
}

.creator-image {
    position: relative;
    width: 300px;
    height: 300px;
    flex-shrink: 0;
}

.creator-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Форма кристалла через clip-path */
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    filter: sepia(30%);
    transition: 0.5s;
}

.creator-image:hover img { filter: sepia(0%); transform: scale(1.05); }

/* Золотая обводка для фото */
.img-border {
    position: absolute;
    top: -5px; left: -5px; right: -5px; bottom: -5px;
    background: linear-gradient(45deg, var(--gold-dark), transparent, var(--gold-shine));
    z-index: -1;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    animation: spin-slow 20s linear infinite;
}

.creator-content h3 { font-size: 2rem; margin-bottom: 5px; }
.creator-content .role { color: var(--gold-shine); font-style: italic; margin-bottom: 20px; font-weight: 300; }
.creator-content .signature {
    font-family: 'Playfair Display', cursive; /* Имитация подписи */
    font-size: 1.5rem;
    color: var(--gold-dark);
    text-align: right;
    margin-top: 20px;
}

@media (max-width: 768px) {
    .creator-wrapper { flex-direction: column; text-align: center; }
    .creator-content .signature { text-align: center; }
}

/* Блок 5: Сетка души и Мини-калейдоскопы */
.soul-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.soul-card {
    padding: 25px;
    text-align: center;
    cursor: pointer;
    transition: 0.4s;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.soul-card:hover { transform: translateY(-5px); border-color: var(--gold-shine); }
.soul-card h4 { color: var(--gold-shine); margin: 15px 0 10px; font-size: 1.1rem; }
.soul-card p { font-size: 0.9rem; line-height: 1.4; }

/* CSS-Калейдоскоп (имитация GIF) */
.kaleidoscope-mini {
    width: 80px; height: 80px;
    border-radius: 50%;
    position: relative;
    overflow: hidden; /* Обрезает всё, что выходит за круг */
    border: 2px solid rgba(255,255,255,0.1);
    box-shadow: 0 0 15px rgba(0,0,0,0.5) inset;
    background: #000; /* Черный фон, пока грузится фото */
}

/* 2. Слой с КАРТИНКОЙ или ЦВЕТОМ (теперь он крутится) */
.kaleidoscope-mini::before {
    content: ''; 
    position: absolute;
    /* Делаем слой чуть больше (140%), чтобы при вращении не было видно пустых углов */
    top: -20%; left: -20%; width: 140%; height: 140%; 
    
    background: inherit; /* ПОЛУЧАЕТ КАРТИНКУ ОТ РОДИТЕЛЯ (.k-green, .k-blue и т.д.) */
    background-size: cover;
    background-position: center;
    
    animation: k-spin 15s linear infinite; /* Вращение фона */
    z-index: 1;
}

/* 3. Слой со СВЕТОВЫМ БЛИКОМ (крутится в другую сторону) */
.kaleidoscope-mini::after {
    content: ''; 
    position: absolute;
    top: -50%; left: -50%; width: 200%; height: 200%;
    background: conic-gradient(from 0deg, transparent, rgba(255,255,255,0.3), transparent);
    
    animation: k-spin 7s linear infinite reverse; /* Вращение блика в обратную сторону */
    mix-blend-mode: overlay;
    z-index: 2;
}

/* Цветовые вариации калейдоскопов */
.k-green { 
    background-image: url("/static/images/1.jpg") !important; 
    background-size: cover;
    background-position: center;
}


.k-blue {     background-image: url("/static/images/2.jpg") !important; 
    background-size: cover;
    background-position: center; }
.k-gold {     background-image: url("/static/images/3.jpg") !important; 
    background-size: cover;
    background-position: center;}
.k-purple {    background-image: url("/static/images/4.jpg") !important; 
    background-size: cover;
    background-position: center;}
.k-red {     background-image: url("/static/images/5.jpg") !important; 
    background-size: cover;
    background-position: center;}
.k-pink {     background-image: url("/static/images/6.jpg") !important; 
    background-size: cover;
    background-position: center; }
.k-emerald {     background-image: url("/static/images/7.jpg") !important; 
    background-size: cover;
    background-position: center; }
.k-cyan {     background-image: url("/static/images/8.jpg") !important; 
    background-size: cover;
    background-position: center; }

@keyframes k-spin { 100% { transform: rotate(360deg); } }

/* Блок 6: Инструкция */
.manual-steps {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 40px;
}

.step-item {
    flex: 1;
    min-width: 280px;
    position: relative;
    padding-left: 20px;
}

.step-num {
    font-size: 4rem;
    font-family: var(--font-serif);
    color: rgba(184, 134, 11, 0.15);
    position: absolute;
    top: -20px; left: 0;
    font-weight: 700;
    z-index: -1;
}

.step-content h4 { color: var(--cream); margin-bottom: 10px; font-size: 1.2rem; }

/* Имитация скриншотов */
.mock-screen {
    width: 100%; height: 150px;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    margin-top: 15px;
    display: flex; align-items: center; justify-content: center;
    color: rgba(255,255,255,0.3);
    font-size: 0.8rem;
    position: relative;
    overflow: hidden;
}
.mock-screen::after {
    content: ''; position: absolute;
    top: 0; left: 0; width: 100%; height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold-shine), transparent);
    animation: scan 3s ease-in-out infinite;
}
@keyframes scan { 0% { top: 0; } 100% { top: 100%; } }

/* Таблица символики */
.symbolism-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 20px;
}
.sym-row {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-bottom: 10px;
    border-bottom: 1px dashed rgba(255,255,255,0.1);
}
.sym-row:last-child { border-bottom: none; }
.color-dot { width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0; border: 1px solid rgba(255,255,255,0.2); }
.sym-desc { font-size: 0.95rem; }

@media (max-width: 600px) {
    .manual-steps { flex-direction: column; }
}

/* --- КАРТОЧКИ (АДАПТИВ) --- */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Умный адаптив */
    gap: 30px;
    margin-top: 50px;
}

.card {
    padding: 40px 25px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%; /* Одинаковая высота */
}

/* Свечение при наведении */
.card::after {
    content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
    opacity: 0; transform: scale(0.5); transition: 0.5s;
}
.card:hover::after { opacity: 1; transform: scale(1); }
.card:hover { transform: translateY(-10px); background: rgba(255, 255, 255, 0.1); border-color: var(--gold-shine); }

.card-icon { font-size: 3rem; margin-bottom: 20px; filter: drop-shadow(0 0 15px rgba(255,215,0,0.4)); transition: 0.3s; }
.card:hover .card-icon { transform: scale(1.2) rotate(10deg); }
.card h3 { font-size: 1.4rem; margin-bottom: 10px; color: #fff; -webkit-text-fill-color: initial; background: none;}

/* --- ТАРИФЫ (АДАПТИВ) --- */
.tariffs-container {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap; /* Важно для мобильных */
    margin-top: 50px;
    align-items: stretch;
}

.tariff-card {
    background: rgba(255,255,255,0.95);
    color: var(--malachite-deep);
    padding: 50px 30px;
    border-radius: 20px;
    flex: 1 1 300px; /* Растягиваться, но не меньше 300px */
    max-width: 380px;
    text-align: center;
    transition: 0.3s;
    position: relative;
    display: flex;
    flex-direction: column;
}

.tariff-card h3 { -webkit-text-fill-color: initial; color: var(--malachite-main); background: none; font-size: 1.6rem; }

.tariff-card.popular {
    transform: scale(1.05);
    border: 3px solid var(--gold-dark);
    box-shadow: 0 0 50px rgba(184, 134, 11, 0.3);
    z-index: 2;
    background: #fff;
}

.tariff-card ul { list-style: none; margin: 20px 0; text-align: left; opacity: 0.8; flex-grow: 1; }
.tariff-card ul li { padding: 5px 0; border-bottom: 1px dashed #ddd; display: flex; gap: 10px; }
.tariff-card ul li::before { content: '✦'; color: var(--gold-dark); }

.price { font-size: 3rem; font-family: var(--font-serif); font-weight: 700; margin: 15px 0; color: var(--malachite-main); }

@media (max-width: 900px) {
    .tariff-card.popular { transform: scale(1); border-width: 2px; order: -1; /* Популярный первым на мобилках */ }
    .tariffs-container { gap: 20px; }
}

@media (max-width: 600px) {
    .cookie-banner { 
        flex-direction: column; 
        text-align: center;
        bottom: 20px; /* На мобилках чуть ниже */
        padding: 25px 20px;
        gap: 15px;
    }
    
    .cookie-banner .btn-gold { 
        width: 100%; /* На мобилках кнопка на всю ширину */
        padding: 12px;
    }

    /* Чтобы баннер точно уходил за экран на мобилках */
    .cookie-banner:not(.visible) {
        transform: translateX(-50%) translateY(150vh); 
    }
}

/* --- ПОДВАЛ --- */
footer { margin-top: 100px; padding: 60px 20px; background: rgba(2, 26, 18, 0.8); border-top: 1px solid var(--gold-dark); text-align: center; }
.social-links { margin-top: 30px; display: flex; justify-content: center; gap: 20px; }
.social-btn { 
    width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--gold-shine); 
    display: flex; align-items: center; justify-content: center; color: var(--gold-shine); text-decoration: none; transition: 0.3s; 
}
.social-btn:hover { background: var(--gold-shine); color: var(--malachite-deep); }

.reveal { opacity: 0; transform: translateY(40px); transition: all 1s cubic-bezier(0.5, 0, 0, 1); }
.reveal.active { opacity: 1; transform: translateY(0); }
