/* Переменные для цветов и шрифтов - Эбен Макассар */
:root {
    --primary-bg: #0B0B0B; /* Глубокий черный эбена */
    --secondary-bg: #1C1C1C; /* Темно-коричневый оттенок */
    --tertiary-bg: #2D2D2D; /* Средний коричневый */
    --text-color: #F5F5F5; /* Кремово-белый */
    --accent-color: #C9A96E; /* Золотисто-коричневый Макассар */
    --accent-hover: #D4B87A; /* Светлее для hover */
    --accent-dark: #A68B4F; /* Темный акцент */
    --light-text: #C8C8C8; /* Приглушенный светлый */
    --border-color: #3A3A3A; /* Тонкие границы */
    --makassar-brown: #8B4513; /* Коричневый Макассар */
    --makassar-gold: #DAA520; /* Золотой Макассар */
    --makassar-dark: #2F1B14; /* Темно-коричневый */
    
    --gradient-primary: linear-gradient(135deg, #C9A96E 0%, #A68B4F 50%, #8B4513 100%);
    --gradient-dark: linear-gradient(135deg, #1C1C1C 0%, #0B0B0B 100%);
    --gradient-makassar: linear-gradient(135deg, #DAA520 0%, #C9A96E 50%, #8B4513 100%);
    --shadow-soft: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-strong: 0 16px 48px rgba(0, 0, 0, 0.6);
    --shadow-gold: 0 4px 20px rgba(201, 169, 110, 0.3);

    --font-heading: 'Cormorant Garamond', serif;
    --font-body: 'Inter', sans-serif;
    --font-accent: 'Playfair Display', serif;
}

/* Общие стили и сброс */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth; /* Плавный скролл при переходе по якорям */
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--primary-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px; /* Вернул оригинальный паддинг */
}

/* Заголовки */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--text-color);
    margin-bottom: 20px;
    text-align: center;
}

/* Градиентная заливка для слова Nigrenum */
.nigrenum-gradient {
    background: var(--gradient-makassar);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

h1 {
    font-size: 3.5em; /* Очень крупный для Hero */
    line-height: 1.1;
    color: var(--accent-color); /* ИЗМЕНЕНО: теперь золотистый/бронзовый */
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5); /* Сохранил тень для читаемости */
}

h2 {
    font-size: 2.8em;
    margin-bottom: 15px;
    color: var(--accent-color); /* Остается золотистым */
}

h3 {
    font-size: 1.8em;
    font-weight: 400;
    color: var(--light-text); /* Оставил светлым для контраста */
    margin-bottom: 30px;
}

h4 {
    font-size: 1.4em;
    color: var(--text-color);
    margin-bottom: 10px;
}

p {
    font-size: 1.1em;
    margin-bottom: 20px;
    color: var(--light-text);
    text-align: center;
}

/* Стили для секций */
section {
    text-align: center;
    overflow-y: visible;
}

.section-padding {
    padding: 80px 0; /* Восстановлен оригинальный паддинг для секций */
}

.section-padding:nth-of-type(even) {
    background-color: var(--secondary-bg);
}

/* Кнопки */
.button {
    display: inline-block;
    background: var(--gradient-makassar);
    color: var(--primary-bg);
    padding: 20px 40px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1em;
    font-family: var(--font-accent);
    letter-spacing: 0.8px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    cursor: pointer;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-gold);
    text-transform: uppercase;
    font-size: 0.95em;
}

.button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.6s;
}

.button:hover::before {
    left: 100%;
}

.button:hover {
    background: var(--gradient-primary);
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 20px 40px rgba(201, 169, 110, 0.4);
    border-color: var(--accent-color);
}

.button-large {
    padding: 18px 40px;
    font-size: 1.2em;
}

/* Header */
.header {
    background-color: var(--primary-bg);
    padding: 15px 0;
    position: sticky; /* Остается sticky */
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    width: 100%; /* Остается 100% */
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    font-family: var(--font-heading);
    transition: all 0.3s ease;
    cursor: pointer;
}

.logo:hover {
    transform: scale(1.02);
}

.logo-text {
    font-family: var(--font-accent);
    font-size: 1.8em;
    font-weight: 700;
    letter-spacing: 2px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    background: var(--gradient-makassar);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo-subtitle {
    font-family: var(--font-body);
    font-size: 0.7em;
    font-weight: 400;
    color: var(--light-text);
    letter-spacing: 1px;
    opacity: 0.8;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
    align-items: center;
}

.main-nav a {
    color: var(--light-text);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.main-nav a:hover {
    color: var(--accent-color);
}

.menu-toggle {
    display: none; /* Скрыто на больших экранах */
    background: none;
    border: none;
    font-size: 2em;
    color: var(--accent-color);
    cursor: pointer;
}

/* Hero Section */
.hero-section {
    background: var(--gradient-dark);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-color);
    position: relative;
    overflow: hidden;
}

#particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(ellipse at center, rgba(201, 169, 110, 0.1) 0%, rgba(0, 0, 0, 0.8) 70%);
    z-index: 2;
}

.hero-section .container {
    position: relative;
    z-index: 3;
    padding: 80px 20px;
    max-width: 1200px;
}

.hero-section h1 {
    margin-bottom: 20px;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
    font-size: 5em;
    font-weight: 700;
    letter-spacing: -0.02em;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    background: var(--gradient-makassar);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-section h2 {
    font-size: 2.8em;
    margin-bottom: 50px;
    color: var(--light-text);
    font-weight: 300;
    letter-spacing: 0.02em;
    font-style: italic;
}

.hero-section p {
    max-width: 900px;
    margin: 0 auto 50px auto;
    font-size: 1.3em;
    line-height: 1.7;
    font-weight: 300;
}



.hero-cta {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 40px;
}

.button-outline {
    background: transparent;
    color: var(--accent-color);
    border: 2px solid var(--accent-color);
}

.button-outline:hover {
    background: var(--accent-color);
    color: var(--primary-bg);
}

.button-telegram {
    background: rgba(201, 169, 110, 0.1);
    color: var(--light-text);
    border: 1px solid rgba(201, 169, 110, 0.3);
    padding: 8px 16px;
    font-size: 0.85em;
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0.5px;
}

.button-telegram:hover {
    background: rgba(201, 169, 110, 0.2);
    color: var(--accent-color);
    border-color: var(--accent-color);
    transform: translateY(-1px);
}



/* Product Grid */
.product-grid, .advantage-grid, .case-grid, .testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
    margin-top: 50px;
}

.product-item {
    opacity: 1;
    transform: scale(1);
    transition: all 0.3s ease;
}

.product-item.hidden {
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
}

.product-price {
    font-family: var(--font-accent);
    font-size: 1.4em;
    font-weight: 700;
    color: var(--accent-color);
    margin-top: 20px;
    padding: 12px 24px;
    background: linear-gradient(135deg, rgba(201, 169, 110, 0.15) 0%, rgba(139, 69, 19, 0.1) 100%);
    border-radius: 25px;
    border: 2px solid rgba(201, 169, 110, 0.3);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(201, 169, 110, 0.2);
}

.product-grid p, .advantage-grid p, .case-grid p, .testimonial-grid p {
    text-align: center; /* Снова по центру для единообразия */
}
.product-grid h4, .advantage-grid h4, .case-grid h4, .testimonial-grid .author {
    text-align: center;
}


.product-item, .advantage-item, .case-item, .testimonial-item {
    background: linear-gradient(145deg, var(--secondary-bg) 0%, var(--tertiary-bg) 100%);
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    border: 1px solid rgba(201, 169, 110, 0.2);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
}

.product-item::before, .advantage-item::before, .case-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-makassar);
    transform: scaleX(0);
    transition: transform 0.4s ease;
    border-radius: 20px 20px 0 0;
}

.product-item:hover::before, .advantage-item:hover::before, .case-item:hover::before {
    transform: scaleX(1);
}

.product-item:hover, .advantage-item:hover, .case-item:hover {
    transform: translateY(-12px) scale(1.03);
    box-shadow: 0 20px 60px rgba(201, 169, 110, 0.2);
    border-color: var(--accent-color);
    background: linear-gradient(145deg, var(--tertiary-bg) 0%, var(--secondary-bg) 100%);
}

.product-item img, .case-item img {
    max-width: 100%;
    height: 250px; /* Фиксированная высота для единообразия */
    object-fit: cover; /* Обрезка, чтобы изображение заполнило пространство */
    border-radius: 4px;
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
}

.product-item h4, .case-item h4 {
    font-size: 1.6em;
    margin-bottom: 10px;
}

.product-item p, .case-item p {
    font-size: 1em;
    color: var(--light-text);
    flex-grow: 1; /* Чтобы параграфы занимали все доступное место */
}

.cta-inline {
    text-align: center;
    margin-top: 60px;
}

/* Advantages Section */
.advantage-item h4 {
    color: var(--accent-color);
    font-size: 1.5em;
}


/* Target Audience Section */
.target-audience-section p {
    max-width: 800px;
    margin: 0 auto 20px auto;
}

/* How It Works (Steps List) */
.steps-list {
    list-style: none;
    counter-reset: step-counter;
    max-width: 900px;
    margin: 50px auto 0 auto;
    padding: 0;
}

.steps-list li {
    background-color: var(--secondary-bg);
    padding: 30px;
    margin-bottom: 20px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    display: flex;
    align-items: flex-start;
    gap: 25px;
}

.steps-list li::before {
    counter-increment: step-counter;
    content: "0" counter(step-counter);
    font-family: var(--font-heading);
    font-size: 2.5em;
    font-weight: 700;
    color: var(--accent-color);
    min-width: 60px; /* Фиксированная ширина для номера */
    text-align: right;
    line-height: 1;
}

.steps-list li h4 {
    text-align: left;
    margin-top: 5px;
    margin-bottom: 5px;
}

.steps-list li p {
    text-align: left;
    margin-bottom: 0;
}


/* Testimonials Section */
.testimonial-item {
    background: var(--gradient-dark);
    padding: 35px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    text-align: left;
    position: relative;
    overflow: hidden;
}

.testimonial-item::before {
    content: '"';
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 4em;
    color: var(--accent-color);
    opacity: 0.3;
    font-family: var(--font-accent);
}

.testimonial-rating {
    font-size: 1.2em;
    margin-bottom: 15px;
    color: var(--accent-color);
}

.testimonial-item p {
    font-style: italic;
    margin-bottom: 20px;
    color: var(--light-text);
    text-align: left;
    font-size: 1.05em;
    line-height: 1.6;
}

.author {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.author-name {
    font-weight: 700;
    color: var(--accent-color);
    font-size: 1.1em;
}

.author-title {
    color: var(--light-text);
    font-size: 0.9em;
    opacity: 0.8;
}

/* CTA Section (Bottom) */
.cta-section {
    text-align: center;
    background-color: var(--primary-bg);
    border-top: 1px solid var(--border-color);
}

.cta-section h2 {
    font-size: 2.5em;
}
.cta-section p {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

/* Стили для обертки и изображения QR-кода */
.cta-section .container {
    display: flex;
    flex-direction: column;
    align-items: center; /* Центрируем содержимое колонками */
}

.qr-code-wrapper {
    margin-top: 50px;
    text-align: center;
    padding: 40px;
    background: linear-gradient(145deg, var(--secondary-bg) 0%, var(--tertiary-bg) 100%);
    border-radius: 20px;
    border: 1px solid rgba(201, 169, 110, 0.2);
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
}

.qr-code-image {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 20px auto 0 auto;
    border: 2px solid var(--accent-color);
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(201, 169, 110, 0.2);
    transition: all 0.3s ease;
}

.qr-code-image:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(201, 169, 110, 0.3);
}

.qr-text {
    font-size: 1em;
    color: var(--light-text);
    margin-bottom: 0;
    font-weight: 500;
    letter-spacing: 0.5px;
}


/* Footer */
.footer {
    background-color: var(--secondary-bg);
    color: var(--light-text);
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
}

.footer .container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.footer p {
    margin-bottom: 0;
    font-size: 0.9em;
}

.social-links a {
    color: var(--light-text);
    text-decoration: none;
    margin: 0 10px;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--accent-color);
}

/* Медиа-запросы для адаптивности */

/* Большие планшеты и маленькие ноутбуки */
@media (max-width: 1200px) {
    h1 { font-size: 3em; }
    h2 { font-size: 2.3em; }
    .logo-text { font-size: 1.7em; }
}

/* Планшеты */
@media (max-width: 1024px) {
    h1 { font-size: 2.5em; }
    h2 { font-size: 2em; }
    h3 { font-size: 1.5em; }
    .hero-section { min-height: 70vh; }
    .main-nav ul { gap: 20px; }
    .container { padding: 0 30px; }
    
    /* Логотип для планшетов */
    .logo-text { font-size: 1.6em; }
    .logo-subtitle { font-size: 0.65em; }
    
    /* Кнопки для планшетов */
    .button-large { font-size: 1.1em; padding: 16px 32px; }
    .button { font-size: 0.95em; padding: 12px 24px; }
}

@media (max-width: 768px) { /* Планшеты и мобильные горизонтально */
    .header .main-nav {
        display: none; /* Скрываем навигацию по умолчанию на мобильных */
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 70px; /* Под хедером */
        left: 0;
        background-color: var(--primary-bg);
        border-top: 1px solid var(--border-color);
        padding-bottom: 20px;
        box-shadow: 0 5px 10px rgba(0,0,0,0.3);
    }
    .header .main-nav.active {
        display: flex; /* Показываем при активном классе */
    }
    .main-nav ul {
        flex-direction: column;
        gap: 15px;
        width: 100%;
        padding: 20px 0;
    }
    .main-nav li {
        width: 100%;
        text-align: center;
    }
    .main-nav a.button {
        display: block;
        margin: 10px auto;
        width: fit-content;
    }
    .menu-toggle {
        display: block; /* Показываем кнопку-гамбургер */
    }

    h1 { font-size: 1.9em; }
    h2 { font-size: 1.6em; }
    h3 { font-size: 1.3em; }
    p { font-size: 0.95em; }
    
    /* Логотип для мобильных */
    .logo-text { font-size: 1.4em; }
    .logo-subtitle { font-size: 0.6em; }
    
    /* Кнопки для мобильных */
    .button-large { font-size: 1em; padding: 14px 28px; }
    .button { font-size: 0.9em; padding: 10px 20px; }
    .button-telegram { font-size: 0.8em; padding: 6px 12px; }
    .section-padding { padding: 60px 0; } /* Уменьшили вертикальный паддинг */
    .hero-section { min-height: 60vh; }

    .product-grid, .advantage-grid, .case-grid, .testimonial-grid {
        gap: 30px;
        grid-template-columns: 1fr; /* На мобильных колонки в один столбец */
    }
    .container { padding: 0 20px; } /* Возвращаем стандартный паддинг */

    .steps-list li {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .steps-list li::before {
        text-align: center;
        margin-bottom: 10px;
    }
    .steps-list li h4, .steps-list li p {
        text-align: center;
    }

    .qr-code-wrapper {
        padding: 20px;
        margin-top: 40px;
    }
    .qr-code-image {
        margin-top: 15px;
    }
}

/* Средние мобильные устройства */
@media (max-width: 600px) {
    h1 { font-size: 1.7em; }
    h2 { font-size: 1.5em; }
    h3 { font-size: 1.2em; }
    .logo-text { font-size: 1.3em; }
    .logo-subtitle { font-size: 0.58em; }
    .button-large { font-size: 0.98em; padding: 13px 26px; }
    .button { font-size: 0.88em; padding: 9px 18px; }
    .button-telegram { font-size: 0.78em; padding: 6px 11px; }
}

@media (max-width: 480px) { /* Очень маленькие экраны, мобильные вертикально */
    .logo-text { font-size: 1.2em; }
    .logo-subtitle { font-size: 0.55em; }
    
    h1 { font-size: 1.6em; }
    h2 { font-size: 1.4em; }
    h3 { font-size: 1.1em; }
    p { font-size: 0.9em; }
    
    .hero-section { min-height: 50vh; }
    
    .button-large {
        padding: 12px 24px;
        font-size: 0.95em;
    }
    .button {
        padding: 8px 16px;
        font-size: 0.85em;
    }
    .button-telegram {
        padding: 5px 10px;
        font-size: 0.75em;
    }
    
    .product-item img, .case-item img {
        height: 180px;
    }
    .product-item h4, .case-item h4 {
        font-size: 1.2em;
    }
    .product-price {
        font-size: 1.1em;
    }
    
    .qr-code-wrapper {
        max-width: 250px;
        padding: 30px 20px;
    }
    
    .container { padding: 0 15px; }
}