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

html, body {
    height: 100%;
    width: 100%;
    background: #000;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    position: fixed;
    touch-action: none;
}

canvas {
    position: fixed;
    top: 0; 
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    z-index: 1;
}

/* Текст в левом верхнем углу */
.title-container {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 100;
    pointer-events: none;
    max-width: 80vw;
}

h1 {
    font-weight: 900;
    text-align: left;
    letter-spacing: -0.03em;
    line-height: 0.9;
    word-break: break-word;
    text-transform: uppercase;
    
    /* Улучшенный градиент с волновым эффектом */
    background: linear-gradient(
        90deg,
        #ff0055,
        #ff5500,
        #ffff00,
        #00ff80,
        #00ffff,
        #0088ff,
        #8800ff,
        #ff00ff,
        #ff0055
    );
    background-size: 400% 400%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: waveGradient 8s ease infinite;
    text-shadow: 0 0 30px rgba(255, 0, 85, 0.3);
    
    /* Адаптивные размеры для всех устройств */
    font-size: clamp(24px, 6vw, 60px);
}

/* Адаптация для iPhone */
@media (max-width: 768px) and (orientation: portrait) {
    .title-container {
        top: 15px;
        left: 15px;
    }
    
    h1 {
        font-size: clamp(20px, 5vw, 40px);
        line-height: 0.85;
        letter-spacing: -0.02em;
    }
}

@media (max-width: 768px) and (orientation: landscape) {
    .title-container {
        top: 10px;
        left: 10px;
    }
    
    h1 {
        font-size: clamp(16px, 4vw, 30px);
        line-height: 0.8;
    }
}

/* Волновая анимация градиента */
@keyframes waveGradient {
    0%, 100% { 
        background-position: 0% 50%;
        filter: hue-rotate(0deg);
    }
    25% { 
        background-position: 100% 25%;
    }
    50% { 
        background-position: 50% 100%;
        filter: hue-rotate(180deg);
    }
    75% { 
        background-position: 25% 0%;
    }
}

.footer {
    position: fixed;
    bottom: 0; 
    left: 0; 
    width: 100%;
    text-align: center;
    padding: 20px;
    z-index: 20;
    pointer-events: none;
}

.footer p {
    color: rgba(255, 255, 255, 0.4);
    font-size: clamp(11px, 2vw, 13px);
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 300;
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.7; }
}

/* Полностью убираем скролл */
body {
    -webkit-overflow-scrolling: touch;
    overflow: hidden;
    position: fixed;
    width: 100%;
    height: 100%;
}

/* Предотвращение выделения и масштабирования */
.no-select {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
}

* {
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: none;
}

/* Для iOS Safari */
@supports (-webkit-touch-callout: none) {
    body {
        height: -webkit-fill-available;
    }
}

/* Скрываем скроллбар */
::-webkit-scrollbar {
    display: none;
    width: 0;
    background: transparent;
}

/* Оптимизация рендеринга */
@media (-webkit-min-device-pixel-ratio: 2) {
    canvas {
        image-rendering: optimizeQuality;
    }
}
