/* style.css */
:root {
    --bg-color: #0a0a0a;
    --text-color: #f2f2f2;
    --accent-color: #3b82f6;
    --secondary-text: #cfcfcf;
    --border-color: rgba(255,255,255,0.1);
    --font-main: 'Helvetica Neue', Arial, sans-serif;
    --nav-height: 70px;
}

::selection {
    background: var(--accent-color); /* Ваш синий */
    color: #ffffff;
}

html {
    scroll-behavior: smooth; /* Плавная прокрутка */
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

.container { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 0 20px; 
    width: 100%; 
}

/* --- HEADER & NAVIGATION --- */
header {
    height: var(--nav-height);
    display: flex;
    align-items: center;
    position: fixed;
    width: 100%;
    top: 0;
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

nav { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    width: 100%;
}

.logo { 
    font-size: 1.5rem; 
    font-weight: 700; 
    letter-spacing: -1px; 
    z-index: 1001;
}

.nav-links { 
    display: flex; 
    gap: 30px; 
    align-items: center; 
}
.nav-links a { font-size: 0.95rem; color: var(--secondary-text); font-weight: 500; }
.nav-links a:hover, .nav-links a.active { color: var(--text-color); }

.btn-contact {
    padding: 10px 25px;
    background: transparent;
    border: 1px solid var(--text-color);
    border-radius: 50px;
    font-size: 0.9rem;
    white-space: nowrap;
}

/* Эффект наведения для кнопки (как в блоке цен) */
.btn-contact:hover {
    background: rgba(59, 130, 246, 0.1); 
    border-color: #3b82f6; 
    color: var(--text-color) !important; 
}

/* Бургер меню */
.burger {
    display: none;
    cursor: pointer;
    z-index: 1001;
}
.burger div {
    width: 25px;
    height: 2px;
    background-color: var(--text-color);
    margin: 5px;
    transition: 0.3s;
}

.toggle .line1 { transform: rotate(-45deg) translate(-5px, 5px); }
.toggle .line2 { opacity: 0; }
.toggle .line3 { transform: rotate(45deg) translate(-5px, -5px); }


/* --- HERO SECTION --- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: var(--nav-height);
    padding-bottom: 40px;
    overflow: hidden;
    background: #0a0a0a;
}

.hero-bg-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    /* Постер по умолчанию (Горизонтальный) */
    background-image: url('img/poster_horizontal.webp');
}

/* Меняем постер на вертикальный для телефонов */
@media (max-width: 768px) {
    .hero-bg-video {
        background-image: url('img/poster_vertical.webp');
    }
}

.hero-overlay-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(10,10,10, 1) 0%, rgba(10,10,10, 0.4) 100%);
    z-index: 1;
}

.hero h1 {
    position: relative;
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 20px;
    background: linear-gradient(to right, #fff, #999);
    -webkit-background-clip: text;
    background-clip: text; 
    -webkit-text-fill-color: transparent;
    color: transparent; 
    z-index: 2;
}

.hero p { 
    position: relative;
    font-size: 1.2rem; 
    color: var(--secondary-text); 
    max-width: 600px; 
    margin: 0 auto 40px; 
    z-index: 2;
}

.hero-btn, button.hero-btn {
    display: inline-block;
    padding: 15px 40px;
    background-color: var(--accent-color);
    color: white;
    border-radius: 50px;
    font-weight: 700;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.4);
    z-index: 2;
    border: none; /* Для button */
    cursor: pointer; /* Для button */
    font-family: inherit; /* Для button */
    transition: transform 0.3s ease, background-color 0.3s ease, opacity 0.3s ease, box-shadow 0.3s ease;
}

.hero-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(59, 130, 246, 0.6); 
}

button.hero-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(59, 130, 246, 0.6); 
}

.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 25px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-color);
    font-size: 0.9rem;
    backdrop-filter: blur(5px);
}

.trust-badge svg {
    color: var(--accent-color);
    flex-shrink: 0;
}

/* 1. Ссылки по умолчанию (Белые и спокойные) */
.trust-badge a {
    color: #ffffff; 
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-color: rgba(255, 255, 255, 0.4); /* Еле заметное подчеркивание */
    transition: all 0.3s ease; /* Плавное появление цвета */
}

/* 2. Яндекс при наведении -> Становится красным */
.trust-badge .yandex-link:hover {
    color: #fc3f1d;
    text-decoration-color: #fc3f1d;
}

/* 3. Циан при наведении -> Становится синим */
.trust-badge .cian-link:hover {
    color: var(--accent-color);
    text-decoration-color: var(--accent-color);
}


/* --- ОБЩИЕ СЕКЦИИ --- */
.page-header {
    padding: 160px 0 40px;
    width: 100%;
    margin-bottom: 60px;
}
.page-header h1 { 
    font-size: 3rem; 
    font-weight: 700; 
    margin-bottom: 15px; 
}
.page-header p { 
    color: var(--secondary-text); 
    max-width: 600px; 
    font-size: 1.1rem; 
}

.section { 
    padding-top: 80px;
    padding-bottom: 80px;
}

.section-title { margin-bottom: 40px; }


/* --- ZIG-ZAG БЛОКИ (Услуги) --- */
.service-row {
    display: flex;
    align-items: center;
    gap: 50px; /* Чуть уменьшили gap, так как добавился padding */
    margin-bottom: 60px; /* Отступ между карточками */
    
    /* --- НОВЫЕ СТИЛИ РАМКИ --- */
    border: 1px solid var(--border-color); /* Ваша стандартная тонкая рамка */
    border-radius: 30px; /* Современное сильное скругление */
    padding: 40px; /* Внутренний отступ от рамки до контента */
    background: rgba(255, 255, 255, 0.02); /* Еле заметный фон, чтобы блок не висел в пустоте */
}
.service-row.reverse { flex-direction: row-reverse; }
.service-content { flex: 1; }
.service-img-wrapper {
    flex: 1;
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    height: 400px;
}
.service-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.service-subtitle {
    color: var(--accent-color);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 2px;
    margin-bottom: 15px;
    display: block;
}
.service-content h2 { font-size: 2.5rem; line-height: 1.1; margin-bottom: 25px; }
.service-content p { color: var(--secondary-text); margin-bottom: 30px; font-size: 1.1rem; }

.feature-list-check li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 15px;
    color: var(--text-color);
    font-size: 1rem;
}
.feature-list-check li::before {
    content: "✓";
    position: absolute;
    left: 0; top: 0;
    color: var(--accent-color);
    font-weight: bold;
}
.center-btn-container { text-align: center; margin-top: 50px; }
.btn-outline {
    display: inline-block;
    padding: 15px 40px;
    border: 1px solid var(--secondary-text);
    color: var(--text-color);
    border-radius: 50px;
    font-weight: 500;
    transition: 0.3s;
}
.btn-outline:hover {
    border-color: var(--text-color);
    background: var(--text-color);
    color: var(--bg-color);
}


/* --- ПОРТФОЛИО --- */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); 
    gap: 30px;
}
.portfolio-item {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    aspect-ratio: 16/9;
    cursor: default;
    display: block; /* Важно для ссылок-карточек */
}
.portfolio-item img { width: 100%; height: 100%; object-fit: cover; transition: 0.5s ease; opacity: 0.85; }
.portfolio-item:hover img { transform: scale(1.05); opacity: 1; }
.portfolio-overlay {
    position: absolute; bottom: 0; left: 0; width: 100%; padding: 25px;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
}

.portfolio-section-header {
    margin-bottom: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    gap: 40px;
    flex-wrap: wrap;
}
.portfolio-desc-content { flex: 1; min-width: 300px; }
.portfolio-desc-content h2 { font-size: 2rem; margin-bottom: 15px; color: var(--text-color); }
.portfolio-desc-content p { color: var(--secondary-text); font-size: 1rem; max-width: 600px; }
.portfolio-benefits {
    flex: 1;
    min-width: 300px;
    background: rgba(255,255,255,0.03);
    padding: 25px;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    justify-content: center; /* Центр по вертикали */
    /* Горизонтально центровать не нужно, списки лучше читаются слева */
}
.portfolio-benefits h4 {
    color: var(--accent-color);
    margin-bottom: 15px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.portfolio-benefits li { position: relative; padding-left: 20px; margin-bottom: 10px; font-size: 0.95rem; color: var(--text-color); }
.portfolio-benefits li::before { content: "•"; color: var(--accent-color); position: absolute; left: 0; font-weight: bold; }

/* Кнопки внутри карточки портфолио */
.portfolio-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    flex-wrap: wrap; /* Чтобы кнопки переносились на узких экранах */
}

.p-btn {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Стиль кнопки "Смотреть тур" (Синяя) */
.p-btn.tour {
    background: var(--accent-color);
    color: white;
}
.p-btn.tour:hover {
    background: #2563eb; /* Чуть темнее */
    transform: translateY(-2px);
}

/* Стиль кнопки "Читать кейс" (Прозрачная с рамкой) */
.p-btn.case {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}
.p-btn.case:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}


/* --- ЦЕНЫ И ТАБЛИЦЫ --- */
.price-section { margin-bottom: 60px; }
.table-wrapper { 
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-right: -20px; 
    padding-right: 20px;
} 
.price-table { width: 100%; border-collapse: collapse; margin-top: 20px; min-width: 600px; }
.price-table th {
    text-align: left;
    padding: 20px;
    color: var(--secondary-text);
    font-weight: 500;
    border-bottom: 2px solid var(--border-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.price-table td { padding: 25px 20px; border-bottom: 1px solid var(--border-color); }
.price-name { font-weight: 600; font-size: 1.1rem; }
.price-desc { font-size: 0.9rem; color: var(--secondary-text); margin-top: 5px; }
.price-value { font-weight: 700; color: var(--accent-color); font-size: 1.2rem; text-align: right; white-space: nowrap; }

/* Градация цен */
.price-tiers { display: flex; flex-direction: column; gap: 8px; min-width: 200px; }
.price-tier-row {
    display: flex; justify-content: space-between; align-items: center;
    border-bottom: 1px dashed rgba(255,255,255,0.1); padding-bottom: 4px;
}
.price-tier-row:last-child { border-bottom: none; }
.tier-qty { color: var(--secondary-text); font-size: 0.9rem; }
.tier-cost { color: var(--accent-color); font-weight: 700; font-size: 1.1rem; }

/* Блок условий */
.terms-block {
    background-color: #171717;
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 60px;
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 50px;
    align-items: stretch;
    border: 1px solid var(--border-color);
}
.min-order-box {
    padding: 25px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid var(--accent-color);
    border-radius: 15px;
    text-align: center;
    
    /* ИЗМЕНЕНИЕ 2: Центруем контент внутри растянутого блока */
    display: flex;
    flex-direction: column;
    justify-content: center; /* Центр по вертикали */
    align-items: center;     /* Центр по горизонтали */
    height: 100%;            /* Занимаем всю доступную высоту */
}
.min-order-icon { margin-bottom: 15px; color: var(--accent-color); }
.min-order-box h3 { font-size: 1.1rem; margin-bottom: 5px; color: var(--text-color); }
.min-order-box p { font-size: 0.9rem; color: var(--secondary-text); line-height: 1.4; }
.included-box h3 { font-size: 1.3rem; margin-bottom: 20px; }
.included-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px 30px; }
.included-item { display: flex; align-items: center; gap: 10px; font-size: 0.95rem; color: var(--secondary-text); }
.included-item svg { flex-shrink: 0; color: var(--accent-color); }


/* --- КОНТАКТЫ --- */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-top: 20px;
}
.contact-card {
    background-color: #171717;
    padding: 30px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    border: 2px solid transparent; 
    transition: all 0.3s ease;
    text-decoration: none;
}
.contact-card:hover {
    background-color: #222;
    transform: translateY(-5px);
    border-color: var(--accent-color);
    .contact-icon svg { color: var(--accent-color); }
}
.contact-icon {
    width: 60px; height: 60px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.contact-icon svg { width: 28px; height: 28px; color: var(--text-color); }
.contact-card h3 { margin: 0; font-size: 1.2rem; font-weight: 600; color: var(--text-color); }
.contact-card p { margin: 5px 0 0 0; font-size: 0.9rem; color: var(--secondary-text); }

/* --- FOOTER --- */
footer {
    margin-top: auto;
    padding: 40px 0;
    border-top: 1px solid var(--border-color);
    text-align: center;
    color: var(--secondary-text);
    font-size: 0.85rem;
}


/* --- ADAPTIVE / MEDIA QUERIES --- */
@media (max-width: 900px) {
    .service-row, .service-row.reverse {
        flex-direction: column-reverse;
        gap: 30px;
        margin-bottom: 40px;
        padding: 25px; 
    }
    .service-img-wrapper { 
        width: 100%;
        height: auto;        /* Убираем жесткое ограничение в 250px */
        aspect-ratio: 3 / 2; /* Заставляем блок всегда держать пропорцию 3:2 */
    }
    .hero h1 { font-size: 2.5rem; }
    .page-header h1 { font-size: 2.2rem; }
    
    /* УДАЛЕНО: .price-value { ... display: block } — это ломало таблицу */
    /* Теперь цена будет стоять ровно напротив описания */
    
    .section { padding-top: 40px; padding-bottom: 40px; }
    .container { padding-left: 20px; padding-right: 20px; }
    
    .terms-block { grid-template-columns: 1fr; gap: 30px; padding: 25px; }
    .included-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed; right: 0; top: 0;
        height: 100vh; width: 100%;
        background-color: #0a0a0a;
        flex-direction: column;
        justify-content: center;
        transform: translateY(-100%);
        transition: transform 0.4s ease-in-out;
        z-index: 1000;
    }
    .nav-links.nav-active { transform: translateY(0%); }
    .nav-links a { font-size: 1.5rem; margin-bottom: 30px; }
    
    .burger { display: block; }
    .portfolio-grid { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
    .contact-card { padding: 25px; }
}

/* --- МИКРО-АНИМАЦИИ (Fade In) --- */

/* Начальное состояние: прозрачный и немного ниже */
.fade-in {
    opacity: 0;
    transform: translateY(30px); /* Сдвиг вниз на 30px */
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    will-change: opacity, transform; /* Подсказка браузеру для оптимизации */
}

/* Конечное состояние: полная видимость и возврат на место */
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Опция: задержка для элементов, идущих подряд (чтобы появлялись лесенкой) */
.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }

/* --- МОДАЛЬНОЕ ОКНО --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-window {
    background: #121212;
    padding: 40px;
    border-radius: 24px;
    border: 1px solid var(--border-color);
    width: 100%;
    max-width: 800px;
    position: relative;
    transform: translateY(50px);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.modal-overlay.active .modal-window {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 25px;
    font-size: 2rem;
    color: var(--secondary-text);
    cursor: pointer;
    line-height: 1;
    transition: 0.3s;
}
.close-modal:hover { color: var(--text-color); }

/* Адаптация сетки контактов внутри модалки для мобильных */
@media (max-width: 600px) {
    .modal-window { padding: 25px 15px; }
    .modal-window .contact-card { padding: 20px; }
}

/* --- ЕДИНЫЙ СТИЛЬ КАРТОЧЕК (Для преимуществ и шагов) --- */

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

/* Общий стиль самой карточки */
.info-card {
    background: #171717; /* Единый темный фон */
    border: 1px solid var(--border-color); /* Тонкая рамка */
    border-radius: 24px; /* Современное скругление */
    padding: 35px;
    transition: all 0.3s ease;
    height: 100%; /* Чтобы карточки в ряду были одной высоты */
    position: relative;
    overflow: hidden;
}

.info-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* Стили для иконок внутри карточек */
.card-icon {
    width: 56px;
    height: 56px;
    background: rgba(255, 255, 255, 0.07); /* Легкий светлый фон */
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-color);
    margin-bottom: 25px;
}

/* Заголовки и текст */
.info-card h3, .info-card h4 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-color);
}

.info-card p {
    font-size: 0.95rem;
    color: var(--secondary-text);
    line-height: 1.6;
}

/* Специфика для шагов (номер 01, 02...) */
.step-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.step-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: #fff;
    opacity: 0.1; /* Водяной знак */
    line-height: 1;
}
/* --- СПИСОК ПРОЦЕССОВ (Горизонтальные карточки) --- */

/* 1. Делаем список вертикальным (одна под другой) */
.info-grid.process-list {
    grid-template-columns: 1fr; /* Одна колонка */
    max-width: 1200px; /* Ограничиваем ширину, чтобы строки не были бесконечными */
    margin-left: auto;
    margin-right: auto;
}

/* 2. Настройка горизонтальной карточки (только для ПК и планшетов) */
@media (min-width: 768px) {
    .process-list .info-card {
        display: grid;
        /* Левая колонка (80px) под иконку/цифру, Правая (auto) под текст */
        grid-template-columns: 80px 1fr; 
        grid-template-areas: 
            "header title"
            "header text";
        gap: 0 40px; /* Отступ между иконкой и текстом */
        align-items: start;
        text-align: left;
        padding: 40px; /* Чуть больше воздуха */
    }

    /* Перестраиваем шапку (Иконка + Цифра) в вертикальную колонку слева */
    .process-list .step-header {
        grid-area: header;
        flex-direction: column; /* Ставим цифру под иконкой */
        align-items: center;
        justify-content: flex-start;
        gap: 15px;
        margin-bottom: 0;
    }

    /* Центруем иконку в левой колонке */
    .process-list .card-icon {
        margin: 0; 
    }

    /* Красиво ставим цифру под иконкой */
    .process-list .step-number {
        font-size: 1.8rem;
        opacity: 0.3; /* Чуть заметнее */
    }

    /* Настройки текста справа */
    .process-list .info-card h3 {
        grid-area: title;
        margin-bottom: 10px;
        margin-top: 5px; /* Выравниваем по верхней границе иконки */
        font-size: 1.4rem;
    }

    .process-list .info-card p {
        grid-area: text;
    }
}

/* --- СТИЛИ ДЛЯ СТАТЕЙ (CASE STUDY) --- */

/* Контейнер для текста статьи (узкий, для удобства чтения) */
.article-container {
    max-width: 720px; /* Оптимальная ширина для чтения */
    margin: 0 auto;
    padding: 0 20px;
}

/* Заголовок кейса */
.case-header {
    padding: 140px 0 60px;
    text-align: center;
}
.case-meta {
    color: var(--accent-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
    display: block;
    font-weight: 600;
}
.case-header h1 {
    font-size: 3rem;
    line-height: 1.1;
    margin-bottom: 30px;
}
.case-lead {
    font-size: 1.25rem;
    color: var(--secondary-text);
    line-height: 1.6;
}

/* Кнопка "Назад" */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--secondary-text);
    font-size: 0.95rem;
    font-weight: 500;
    transition: 0.3s;
    cursor: pointer;
}

.back-link svg {
    transition: transform 0.3s ease;
}

.back-link:hover {
    color: var(--accent-color);
}

.back-link:hover svg {
    transform: translateX(-4px); /* Стрелка немного отъезжает влево */
}

/* Тело статьи */
.article-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #e5e5e5; /* Чуть светлее обычного текста */
    margin-bottom: 80px;
}

.article-content p { margin-bottom: 25px; }

.article-content h2 {
    font-size: 1.8rem;
    margin-top: 50px;
    margin-bottom: 20px;
    color: #fff;
}

.article-content ul {
    margin-bottom: 30px;
    list-style: disc;
    padding-left: 20px;
    color: var(--secondary-text);
}
.article-content li { margin-bottom: 10px; }

/* Изображения в статье */
.article-image-full {
    width: 100%;
    height: auto;
    border-radius: 20px;
    margin: 40px 0;
    border: 1px solid var(--border-color);
}
.article-caption {
    text-align: center;
    font-size: 0.9rem;
    color: var(--secondary-text);
    margin-top: -30px;
    margin-bottom: 40px;
    display: block;
}

/* Блок "Результаты" (выделенный) */
.case-results {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid var(--accent-color);
    border-radius: 20px;
    padding: 30px;
    margin: 40px 0;
}
.case-results h3 { margin-bottom: 15px; color: #fff; }

/* --- ГАЛЕРЕЯ В КЕЙСАХ (Обновленная) --- */

.gallery-section {
    margin-bottom: 80px; 
}

.gallery-grid {
    display: grid;
    /* СТАЛО: Ровно 2 колонки. Фотографии будут большими. */
    grid-template-columns: repeat(2, 1fr); 
    gap: 30px; /* Отступ чуть больше, так как фото стали крупнее */
    margin-top: 40px;
}

.gallery-item {
    position: relative;
    border-radius: 20px; 
    border: 1px solid var(--border-color);
    overflow: hidden;
    background: #121212;

    /* СТАЛО: Фиксированная пропорция 3:2 */
    width: 100%;
    aspect-ratio: 3 / 2; 
    /* Высоту убрали, она теперь считается сама от ширины */
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Заполняет рамку, обрезая лишнее по краям */
    transition: transform 0.5s ease;
}

/* Адаптив для мобильных */
@media (max-width: 768px) {
    .gallery-grid {
        /* На телефоне делаем 1 колонку, чтобы фото было на весь экран */
        grid-template-columns: 1fr; 
        gap: 20px;
    }
}

/* --- СРАВНИТЕЛЬНАЯ ТАБЛИЦА (Обновленная) --- */

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 700px;
    background: transparent;
}

.comparison-table th {
    text-align: left;
    padding: 25px;
    font-size: 1.1rem;
    color: var(--text-color); /* Теперь все заголовки белые */
    border-bottom: 2px solid var(--border-color);
}

/* УДАЛЕНО: Специальные цвета для колонок. 
   Теперь они наследуют белый цвет от th.
*/

.comparison-table td {
    padding: 20px 25px;
    border-bottom: 1px solid var(--border-color);
    vertical-align: top;
    color: var(--secondary-text);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Первый столбец (Критерий) */
.comparison-table td:first-child {
    color: var(--text-color);
    font-weight: 600;
    width: 25%;
}

.comparison-table td:nth-child(2),
.comparison-table td:nth-child(3) {
    width: 37.5%;
}

/* Иконки */
.comp-icon {
    display: inline-block;
    vertical-align: middle;
    margin-right: 8px;
}
.comp-check { color: var(--accent-color); }
.comp-cross { color: #ef4444; opacity: 0.7; }
.comp-yandex { color: #FC3F1D; }

/* Подсветка строки при наведении */
.comparison-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

/* --- COOKIE БАННЕР --- */
.cookie-banner {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px); /* Скрыт внизу */
    width: 90%;
    max-width: 600px;
    background: rgba(23, 23, 23, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 20px 25px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: none; /* Чтобы не мешал кликам, пока скрыт */
}

.cookie-banner.active {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    pointer-events: all;
}

.cookie-text {
    font-size: 0.9rem;
    color: var(--secondary-text);
    line-height: 1.4;
    margin: 0;
}

.cookie-text a {
    color: var(--accent-color);
    text-decoration: underline;
}

.cookie-btn {
    background: var(--text-color);
    color: var(--bg-color);
    border: none;
    padding: 10px 25px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    white-space: nowrap;
    transition: 0.3s;
}

.cookie-btn:hover {
    background: var(--accent-color);
    color: white;
}

/* Адаптив для телефонов */
@media (max-width: 600px) {
    .cookie-banner {
        flex-direction: column;
        bottom: 0;
        width: 100%;
        max-width: 100%;
        border-radius: 20px 20px 0 0;
        border-left: none;
        border-right: none;
        border-bottom: none;
        text-align: center;
    }
    .cookie-btn {
        width: 100%;
    }
}

/* --- QR CODE --- */
.qr-container {
    text-align: center;
    margin-top: 60px; /* <--- Увеличили отступ (было 20px) */
    display: flex;
    flex-direction: column;
    align-items: center;
}

#vcard-qr {
    background-color: white; /* Обязательно белый фон для контраста */
    padding: 15px;
    border-radius: 15px;
    display: inline-block; /* Чтобы блок обтягивал QR код */
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

#vcard-qr img {
    display: block; /* Убирает лишние отступы у картинки */
}

/* --- FAQ SECTION --- */
.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background-color: rgba(255, 255, 255, 0.03); /* Очень легкий фон */
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    margin-bottom: 15px;
    overflow: hidden;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

/* Эффект при наведении на плашку */
.faq-item:hover {
    background-color: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.1);
}

/* Если вопрос открыт - выделяем его */
.faq-item.active {
    background-color: rgba(255, 255, 255, 0.08);
    border-color: var(--accent-color);
}

.faq-question {
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.faq-question h3 {
    font-size: 1.1rem;
    margin: 0;
    font-weight: 600;
    color: #fff;
    padding-right: 20px;
}

/* Иконка плюсика */
.faq-icon {
    color: var(--accent-color);
    display: flex;
    align-items: center;
    transition: transform 0.3s ease; /* Плавный поворот */
    flex-shrink: 0;
}

/* Поворот иконки при открытии */
.faq-item.active .faq-icon {
    transform: rotate(45deg); /* Превращается в крестик */
    color: #ff6b6b; /* Можно сделать красным, или оставить accent-color */
}

/* Блок ответа (скрыт по умолчанию) */
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out; /* Магия плавной высоты */
}

.faq-content {
    padding: 0 25px 25px 25px;
    color: var(--secondary-text);
    line-height: 1.6;
    font-size: 0.95rem;
}