/* ============================================
   ATOMIC - Стили сайта
   Тема: Раскалённое ядро атома
   ============================================ */

/* CSS Переменные */
:root {
    /* Основные цвета */
    --bg-primary: #0d0d0d;
    --bg-secondary: #1a0f0a;
    --bg-card: rgba(26, 15, 10, 0.8);

    /* Акцентные цвета - огненная палитра */
    --accent-orange: #ff6b00;
    --accent-gold: #ffaa00;
    --accent-red: #ff3d00;
    --accent-cyan: #00d4ff;

    /* Текст */
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-muted: rgba(255, 255, 255, 0.5);

    /* Градиенты */
    --gradient-fire: linear-gradient(135deg, var(--accent-red), var(--accent-orange), var(--accent-gold));
    --gradient-core: radial-gradient(circle, var(--accent-gold), var(--accent-orange), var(--accent-red));
    --gradient-glow: radial-gradient(circle, rgba(255, 107, 0, 0.4), transparent 70%);

    /* Тени и свечения */
    --glow-orange: 0 0 30px rgba(255, 107, 0, 0.5);
    --glow-gold: 0 0 20px rgba(255, 170, 0, 0.4);
    --glow-cyan: 0 0 20px rgba(0, 212, 255, 0.4);

    /* Размеры */
    --header-height: 80px;
    --container-width: 1200px;
    --border-radius: 12px;

    /* Анимации */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* Сброс стилей */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Базовые стили */
html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Фоновый эффект */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(ellipse at 20% 20%, rgba(255, 61, 0, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(255, 107, 0, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(0, 212, 255, 0.05) 0%, transparent 70%);
    pointer-events: none;
    z-index: -1;
}

/* Контейнер */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

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

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    background: var(--gradient-fire);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--text-primary);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    color: var(--accent-gold);
}

p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

a {
    color: var(--accent-orange);
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--accent-gold);
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(13, 13, 13, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 107, 0, 0.2);
    z-index: 1000;
    transition: var(--transition-normal);
}

.header.scrolled {
    background: rgba(13, 13, 13, 0.95);
    box-shadow: 0 4px 30px rgba(255, 107, 0, 0.1);
}

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

/* Логотип */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.8rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    background: var(--gradient-fire);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
    position: relative;
}

.logo::before {
    content: '';
    width: 40px;
    height: 40px;
    background: var(--gradient-core);
    border-radius: 50%;
    box-shadow: var(--glow-orange);
    animation: pulse-core 2s ease-in-out infinite;
}

@keyframes pulse-core {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

/* Навигация */
.nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    padding: 10px 18px;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    border-radius: 8px;
    transition: var(--transition-fast);
    position: relative;
}

.nav-link:hover {
    color: var(--text-primary);
    background: rgba(255, 107, 0, 0.1);
}

.nav-link.active {
    color: var(--accent-orange);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 3px;
    background: var(--gradient-fire);
    border-radius: 2px;
}

/* Мобильное меню */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
}

.menu-toggle span {
    width: 25px;
    height: 2px;
    background: var(--accent-orange);
    transition: var(--transition-fast);
}

/* ============================================
   КНОПКИ
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 32px;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition-normal);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--gradient-fire);
    color: #000;
    box-shadow: var(--glow-orange);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 40px rgba(255, 107, 0, 0.6);
}

.btn-primary::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: 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--accent-orange);
}

.btn-secondary:hover {
    background: rgba(255, 107, 0, 0.1);
    box-shadow: var(--glow-orange);
}

.btn-download {
    padding: 18px 40px;
    font-size: 1.1rem;
    background: var(--gradient-fire);
    color: #000;
    box-shadow: var(--glow-orange);
    animation: pulse-btn 2s ease-in-out infinite;
}

@keyframes pulse-btn {
    0%, 100% { box-shadow: 0 0 30px rgba(255, 107, 0, 0.5); }
    50% { box-shadow: 0 0 50px rgba(255, 107, 0, 0.8); }
}

.btn-download:hover {
    animation: none;
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 0 60px rgba(255, 107, 0, 0.8);
}

/* Иконка скачивания */
.btn-download svg {
    width: 24px;
    height: 24px;
    transition: var(--transition-fast);
}

.btn-download:hover svg {
    transform: translateY(3px);
}

/* ============================================
   HERO СЕКЦИЯ
   ============================================ */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: var(--header-height);
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 107, 0, 0.15);
    border: 1px solid rgba(255, 107, 0, 0.3);
    border-radius: 50px;
    font-size: 0.9rem;
    color: var(--accent-gold);
    margin-bottom: 24px;
}

.hero-badge::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--accent-orange);
    border-radius: 50%;
    animation: blink 1.5s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.hero h1 {
    margin-bottom: 24px;
}

.hero-description {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

/* 3D Атом контейнер */
.hero-visual {
    position: absolute;
    right: -5%;
    top: 50%;
    transform: translateY(-50%);
    width: 50%;
    height: 80%;
    z-index: 1;
}

#atom-canvas {
    width: 100%;
    height: 100%;
}

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

.section {
    padding: 100px 0;
    position: relative;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 60px;
}

.section-badge {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(255, 107, 0, 0.15);
    border-radius: 50px;
    font-size: 0.85rem;
    color: var(--accent-orange);
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ============================================
   КАРТОЧКИ
   ============================================ */

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 107, 0, 0.15);
    border-radius: var(--border-radius);
    padding: 30px;
    transition: var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--gradient-fire);
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition-normal);
}

.card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 107, 0, 0.4);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), var(--glow-orange);
}

.card:hover::before {
    transform: scaleX(1);
}

.card-icon {
    width: 60px;
    height: 60px;
    background: var(--gradient-fire);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.card-title {
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.card-text {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ============================================
   FEATURES - Возможности
   ============================================ */

.features-list {
    display: flex;
    flex-direction: column;
    gap: 80px;
}

.feature-item {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.feature-item:nth-child(even) {
    direction: rtl;
}

.feature-item:nth-child(even) > * {
    direction: ltr;
}

.feature-content h3 {
    font-size: 2rem;
    margin-bottom: 20px;
}

.feature-content p {
    font-size: 1.1rem;
    margin-bottom: 24px;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    color: var(--text-secondary);
}

.feature-list li::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--accent-orange);
    border-radius: 50%;
    box-shadow: var(--glow-orange);
}

.feature-visual {
    background: var(--bg-card);
    border: 1px solid rgba(255, 107, 0, 0.2);
    border-radius: var(--border-radius);
    aspect-ratio: 16/10;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.feature-visual::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-glow);
    opacity: 0.5;
}

/* ============================================
   СТАТИСТИКА
   ============================================ */

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    padding: 60px 0;
    border-top: 1px solid rgba(255, 107, 0, 0.2);
    border-bottom: 1px solid rgba(255, 107, 0, 0.2);
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    background: var(--gradient-fire);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 8px;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* ============================================
   FAQ
   ============================================ */

.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    border-bottom: 1px solid rgba(255, 107, 0, 0.2);
}

.faq-question {
    width: 100%;
    background: none;
    border: none;
    padding: 24px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    text-align: left;
    transition: var(--transition-fast);
}

.faq-question:hover {
    color: var(--accent-orange);
}

.faq-icon {
    width: 24px;
    height: 24px;
    position: relative;
    flex-shrink: 0;
}

.faq-icon::before,
.faq-icon::after {
    content: '';
    position: absolute;
    background: var(--accent-orange);
    transition: var(--transition-fast);
}

.faq-icon::before {
    width: 100%;
    height: 2px;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
}

.faq-icon::after {
    width: 2px;
    height: 100%;
    left: 50%;
    top: 0;
    transform: translateX(-50%);
}

.faq-item.active .faq-icon::after {
    transform: translateX(-50%) rotate(90deg);
    opacity: 0;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 500px;
}

.faq-answer p {
    padding-bottom: 24px;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ============================================
   CTA СЕКЦИЯ
   ============================================ */

.cta {
    text-align: center;
    padding: 100px 0;
    position: relative;
}

.cta::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: var(--gradient-glow);
    border-radius: 50%;
    opacity: 0.3;
    pointer-events: none;
}

.cta-content {
    position: relative;
    z-index: 1;
}

.cta h2 {
    margin-bottom: 20px;
}

.cta p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ============================================
   FOOTER
   ============================================ */

.footer {
    background: var(--bg-secondary);
    border-top: 1px solid rgba(255, 107, 0, 0.2);
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand .logo {
    margin-bottom: 16px;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.footer-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 20px;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: var(--text-muted);
    transition: var(--transition-fast);
}

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

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0;
}

.social-links {
    display: flex;
    gap: 16px;
}

.social-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    color: var(--text-secondary);
    transition: var(--transition-fast);
}

.social-link:hover {
    background: var(--accent-orange);
    color: #000;
}

/* ============================================
   ЧАСТИЦЫ
   ============================================ */

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

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--accent-orange);
    border-radius: 50%;
    opacity: 0.6;
    animation: float-particle 15s infinite linear;
}

.particle:nth-child(odd) {
    background: var(--accent-cyan);
}

@keyframes float-particle {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.6;
    }
    90% {
        opacity: 0.6;
    }
    100% {
        transform: translateY(-100vh) rotate(720deg);
        opacity: 0;
    }
}

/* ============================================
   PAGE HEADER (для внутренних страниц)
   ============================================ */

.page-header {
    padding: 160px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(255, 107, 0, 0.15), transparent 70%);
    pointer-events: none;
}

.page-header h1 {
    position: relative;
    z-index: 1;
}

.page-header p {
    position: relative;
    z-index: 1;
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Хлебные крошки */
.breadcrumbs {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 24px;
    font-size: 0.9rem;
}

.breadcrumbs a {
    color: var(--text-muted);
}

.breadcrumbs a:hover {
    color: var(--accent-orange);
}

.breadcrumbs span {
    color: var(--text-muted);
}

.breadcrumbs .current {
    color: var(--accent-orange);
}

/* ============================================
   АДАПТИВНОСТЬ
   ============================================ */

@media (max-width: 1024px) {
    .hero-visual {
        position: relative;
        right: auto;
        top: auto;
        transform: none;
        width: 100%;
        height: 400px;
        margin-top: 40px;
    }

    .hero {
        flex-direction: column;
        text-align: center;
        padding-bottom: 60px;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero-buttons {
        justify-content: center;
    }

    .feature-item {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .feature-item:nth-child(even) {
        direction: ltr;
    }

    .stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .nav {
        position: fixed;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background: rgba(13, 13, 13, 0.98);
        flex-direction: column;
        padding: 20px;
        gap: 0;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition-normal);
    }

    .nav.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-link {
        width: 100%;
        padding: 16px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .menu-toggle {
        display: flex;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .stats {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 20px;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .section {
        padding: 60px 0;
    }
}

/* ============================================
   УТИЛИТЫ
   ============================================ */

.text-gradient {
    background: var(--gradient-fire);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-center {
    text-align: center;
}

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.hidden {
    display: none;
}

/* Скрытие элементов для screen readers */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
