:root {
    --bg-primary: #0a0812;
    --bg-secondary: #0f0c1a;
    --bg-tertiary: #16122b;
    --bg-card: #1a1530;
    --bg-hover: #221c3d;

    --purple-300: #d8b4fe;
    --purple-400: #c084fc;
    --purple-500: #a855f7;
    --purple-600: #9333ea;
    --purple-700: #7e22ce;
    --purple-800: #6b21a8;
    --purple-900: #581c87;

    --accent-pink: #ec4899;
    --accent-cyan: #22d3ee;
    --accent-green: #a6e3a1;

    --text-primary: #f5f3ff;
    --text-secondary: #c4b5fd;
    --text-muted: #7c6d9e;

    --border-subtle: rgba(168, 85, 247, 0.12);
    --border-medium: rgba(168, 85, 247, 0.25);
    --border-strong: rgba(168, 85, 247, 0.5);

    --glow-sm: 0 0 20px rgba(168, 85, 247, 0.3);
    --glow-md: 0 0 40px rgba(168, 85, 247, 0.4);
    --glow-lg: 0 0 80px rgba(168, 85, 247, 0.5);
}

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

html, body {
    background: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    overflow-x: hidden;
}

body {
    background:
        radial-gradient(ellipse 800px 600px at 20% 0%, rgba(168, 85, 247, 0.15), transparent 50%),
        radial-gradient(ellipse 600px 500px at 80% 100%, rgba(236, 72, 153, 0.1), transparent 50%),
        var(--bg-primary);
    background-attachment: fixed;
}

a {
    color: var(--purple-400);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--purple-300);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 12px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    text-decoration: none;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--purple-500) 0%, var(--purple-700) 100%);
    color: white;
    box-shadow: 0 4px 20px rgba(168, 85, 247, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(168, 85, 247, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-medium);
}

.btn-ghost:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
    border-color: var(--border-strong);
}

.btn-lg {
    padding: 16px 32px;
    font-size: 16px;
}

::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--purple-700), var(--purple-900));
    border-radius: 5px;
    border: 2px solid var(--bg-secondary);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--purple-500), var(--purple-700));
}

::selection {
    background: var(--purple-500);
    color: white;
}

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

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ═══════════════════════════════════════════════════
   ОБЩИЕ СТИЛИ NAV (для всех страниц)
   ═══════════════════════════════════════════════════ */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    backdrop-filter: blur(20px);
    background: rgba(10, 8, 18, 0.75);
    border-bottom: 1px solid var(--border-subtle);
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 18px 32px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 24px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 20px;
    color: var(--text-primary);
    justify-self: start;
}

.logo-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--purple-400), var(--accent-pink));
    box-shadow: 0 0 12px var(--purple-500);
    animation: pulse 2s infinite;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    justify-self: end;
}

.nav-link {
    color: var(--text-secondary);
    font-size: 15px;
    font-weight: 500;
    position: relative;
    padding: 6px 0;
    transition: color 0.2s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--purple-400), transparent);
    transition: transform 0.3s ease;
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-link:hover::after {
    transform: translateX(-50%) scaleX(1);
}

/* ═══════════════════════════════════════════════════
   ОБЩИЕ СТИЛИ FOOTER
   ═══════════════════════════════════════════════════ */

.footer {
    padding: 48px 32px 32px;
    border-top: 1px solid var(--border-subtle);
    background: var(--bg-secondary);
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    max-width: 600px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--purple-500), transparent);
    opacity: 0.5;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.footer-top {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 18px;
    color: var(--text-primary);
}

.footer-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-link {
    display: inline-flex;
    align-items: center;
    padding: 8px 18px;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: 100px;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.25s ease;
    white-space: nowrap;
}

.footer-link:hover {
    background: var(--bg-hover);
    border-color: var(--border-strong);
    color: var(--text-primary);
    transform: translateY(-2px);
    box-shadow: var(--glow-sm);
}

.footer-divider {
    width: 40px;
    height: 1px;
    background: var(--border-medium);
    margin: 0 auto;
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-align: center;
}

.footer-text {
    color: var(--text-muted);
    font-size: 13px;
    max-width: 500px;
    line-height: 1.6;
}

.footer-copy {
    color: var(--text-muted);
    font-size: 12px;
    opacity: 0.7;
}

@media (max-width: 768px) {
    .nav-inner {
        padding: 14px 20px;
        grid-template-columns: auto 1fr;
        gap: 16px;
    }
    .nav-links {
        gap: 16px;
    }
    .footer-links {
        flex-direction: column;
        width: 100%;
    }
    .footer-link {
        width: 100%;
        justify-content: center;
    }
}