/* ══════════════════════════════
   ПЕРЕМЕННЫЕ
══════════════════════════════ */
:root {
    --bg: #07080d;
    --bg-deep: #04050a;
    --glass: rgba(255, 255, 255, 0.04);
    --glass-hover: rgba(255, 255, 255, 0.07);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-border-hover: rgba(255, 255, 255, 0.15);
    --text: #f0f2f8;
    --text-dim: #8b91a8;
    --text-faint: #4a5070;
    --accent: #7c5cff;
    --accent-2: #4d9fff;
    --accent-3: #ff5cf0;
    --red: #ff4d6d;
    --green: #4dffaa;
    --r-sm: 8px;
    --r-md: 14px;
    --r-lg: 20px;
    --shadow-glass: 0 8px 32px rgba(0, 0, 0, 0.4);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    height: 100%;
}

body {
    font-family: 'Space Grotesk', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
    line-height: 1.5;
}

/* ══════════════════════════════
   ФОН — BLOB'Ы
══════════════════════════════ */
.bg-blobs {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.6;
    transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
}

.blob-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
    top: -200px;
    left: -200px;
    animation: float-1 20s ease-in-out infinite;
}

.blob-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-2) 0%, transparent 70%);
    bottom: -150px;
    right: -150px;
    animation: float-2 25s ease-in-out infinite;
}

.blob-3 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--accent-3) 0%, transparent 70%);
    top: 40%;
    left: 50%;
    opacity: 0.3;
    animation: float-3 18s ease-in-out infinite;
}

.blob-red {
    background: radial-gradient(circle, var(--red) 0%, transparent 70%) !important;
}

@keyframes float-1 {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(100px, 80px) scale(1.1);
    }

    66% {
        transform: translate(-60px, 120px) scale(0.9);
    }
}

@keyframes float-2 {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(-120px, -80px) scale(1.15);
    }

    66% {
        transform: translate(80px, -100px) scale(0.85);
    }
}

@keyframes float-3 {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
    }

    50% {
        transform: translate(-30%, -60%) scale(1.2);
    }
}

/* Шум */
.noise {
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ══════════════════════════════
   СТЕКЛО
══════════════════════════════ */
.glass {
    background: var(--glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow-glass);
}

/* ══════════════════════════════
   ШАПКА
══════════════════════════════ */
.header {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    width: calc(100% - 40px);
    max-width: 1100px;
    animation: fade-down 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    border-radius: var(--r-md);
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text);
    transition: opacity 0.2s;
}

.logo-link:hover {
    opacity: 0.8;
}

.logo-mark {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    display: grid;
    place-items: center;
    color: #fff;
    box-shadow: 0 0 20px rgba(124, 92, 255, 0.4);
}

.logo-mark svg {
    width: 16px;
    height: 16px;
}

.logo-text {
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 3px;
}

.nav {
    display: flex;
    gap: 8px;
}

.nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 10px;
    color: var(--text-dim);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
}

.nav-btn:hover {
    background: var(--glass-hover);
    color: var(--text);
}

.nav-btn i {
    font-size: 14px;
}

/* ══════════════════════════════
   MAIN / HERO
══════════════════════════════ */
.main {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 24px 100px;
}

.hero {
    max-width: 800px;
    width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 28px;
}

/* ── Бейдж ── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-dim);
}

.badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 12px var(--green);
    animation: pulse 2s ease-in-out infinite;
}

.badge-dot-red {
    background: var(--red);
    box-shadow: 0 0 12px var(--red);
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.5;
        transform: scale(0.85);
    }
}

/* ── Заголовок ── */
.title {
    font-size: clamp(40px, 7vw, 72px);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -2px;
    max-width: 700px;
}

.title-gradient {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 50%, var(--accent-3) 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-shift 6s ease infinite;
    display: inline-block;
}

.title-gradient-red {
    background: linear-gradient(135deg, var(--red) 0%, #ff8a4d 50%, var(--accent-3) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

@keyframes gradient-shift {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

/* ── Описание ── */
.desc {
    font-size: 17px;
    color: var(--text-dim);
    max-width: 500px;
    line-height: 1.7;
    font-weight: 400;
}

/* ── Кнопки ── */
.cta-group {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

.cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 24px;
    border-radius: 12px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.cta-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: #fff;
    box-shadow: 0 8px 24px rgba(124, 92, 255, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.cta-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--accent-2), var(--accent-3));
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 0;
}

.cta-primary>* {
    position: relative;
    z-index: 1;
}

.cta-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(124, 92, 255, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.cta-primary:hover::before {
    opacity: 1;
}

.cta-ghost {
    color: var(--text);
}

.cta-ghost:hover {
    background: var(--glass-hover);
    border-color: var(--glass-border-hover);
    transform: translateY(-3px);
}

.cta-arrow {
    transition: transform 0.3s;
    font-size: 12px;
}

.cta:hover .cta-arrow {
    transform: translateX(4px);
}

/* ══════════════════════════════
   ФИЧИ
══════════════════════════════ */
.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    width: 100%;
    margin-top: 24px;
}

.feature {
    padding: 24px 20px;
    border-radius: var(--r-md);
    text-align: left;
    transition: all 0.3s;
    cursor: default;
}

.feature:hover {
    background: var(--glass-hover);
    border-color: var(--glass-border-hover);
    transform: translateY(-4px);
}

.feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 16px;
    margin-bottom: 14px;
    box-shadow: 0 4px 16px rgba(124, 92, 255, 0.3);
}

.feature-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

.feature-desc {
    font-size: 13px;
    color: var(--text-dim);
    font-weight: 400;
}

/* ══════════════════════════════
   404 — БОЛЬШОЙ НОМЕР
══════════════════════════════ */
.error-big {
    position: relative;
    display: inline-block;
    margin-bottom: 8px;
}

.error-big-text {
    font-size: clamp(120px, 22vw, 220px);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -10px;
    background: linear-gradient(135deg,
            var(--red) 0%,
            #ff8a4d 40%,
            var(--accent-3) 80%,
            var(--accent) 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-shift 6s ease infinite, glitch 8s infinite;
    position: relative;
    z-index: 2;
}

.error-big-glow {
    position: absolute;
    inset: -40px;
    background: radial-gradient(circle,
            rgba(255, 77, 109, 0.4) 0%,
            rgba(124, 92, 255, 0.2) 40%,
            transparent 70%);
    filter: blur(40px);
    z-index: 1;
    animation: glow-pulse 4s ease-in-out infinite;
}

@keyframes glow-pulse {

    0%,
    100% {
        opacity: 0.6;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.1);
    }
}

@keyframes glitch {

    0%,
    92%,
    100% {
        transform: translate(0, 0);
        filter: none;
    }

    93% {
        transform: translate(-4px, 2px);
        filter: hue-rotate(90deg);
    }

    94% {
        transform: translate(4px, -2px);
        filter: hue-rotate(-90deg);
    }

    95% {
        transform: translate(-2px, -1px);
        filter: hue-rotate(45deg);
    }

    96% {
        transform: translate(2px, 1px);
        filter: none;
    }
}

/* ══════════════════════════════
   ФУТЕР
══════════════════════════════ */
.footer {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
    color: var(--text-faint);
    letter-spacing: 0.5px;
    font-weight: 400;
    white-space: nowrap;
    animation: fade-up-x 0.6s 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.footer-sep {
    opacity: 0.5;
}

/* ══════════════════════════════
   АНИМАЦИИ ПОЯВЛЕНИЯ
══════════════════════════════ */
.hero>* {
    animation: fade-up 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero>*:nth-child(1) {
    animation-delay: 0.0s;
}

.hero>*:nth-child(2) {
    animation-delay: 0.1s;
}

.hero>*:nth-child(3) {
    animation-delay: 0.2s;
}

.hero>*:nth-child(4) {
    animation-delay: 0.3s;
}

.hero>*:nth-child(5) {
    animation-delay: 0.4s;
}

.hero>*:nth-child(6) {
    animation-delay: 0.5s;
}

@keyframes fade-up {
    from {
        opacity: 0;
        transform: translateY(24px);
        filter: blur(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

@keyframes fade-down {
    from {
        opacity: 0;
        transform: translate(-50%, -20px);
    }

    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

@keyframes fade-up-x {
    from {
        opacity: 0;
        transform: translate(-50%, 24px);
    }

    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

/* ══════════════════════════════
   SELECTION / SCROLLBAR
══════════════════════════════ */
::selection {
    background: rgba(124, 92, 255, 0.4);
    color: #fff;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-deep);
}

::-webkit-scrollbar-thumb {
    background: var(--glass-border);
    border-radius: 100px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

/* ══════════════════════════════
   АДАПТИВ
══════════════════════════════ */
@media (max-width:768px) {
    .header {
        top: 12px;
        width: calc(100% - 24px);
    }

    .header-inner {
        padding: 10px 16px;
    }

    .logo-text {
        font-size: 13px;
        letter-spacing: 2px;
    }

    .nav-btn span {
        display: none;
    }

    .nav-btn {
        padding: 8px 10px;
    }

    .main {
        padding: 100px 20px;
    }

    .hero {
        gap: 24px;
    }

    .features {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .feature {
        display: flex;
        align-items: center;
        gap: 16px;
    }

    .feature-icon {
        margin-bottom: 0;
        flex-shrink: 0;
    }
}

@media (max-width:480px) {
    .cta-group {
        flex-direction: column;
        width: 100%;
    }

    .cta {
        width: 100%;
        justify-content: center;
    }

    .title {
        letter-spacing: -1px;
    }

    .footer {
        font-size: 11px;
        bottom: 16px;
    }

    .error-big-text {
        letter-spacing: -6px;
    }
}

/* ══════════════════════════════
   REDUCED MOTION
══════════════════════════════ */
@media (prefers-reduced-motion:reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .blob {
        animation: none !important;
    }
}

