body { background-color: #f8fafc; color: #0f172a; overflow-x: hidden; }

/* Декоративные паттерны и глобальные свечения */
.bg-pattern {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background-image: radial-gradient(rgba(37, 99, 235, 0.1) 1.5px, transparent 1.5px);
    background-size: 32px 32px; z-index: -3; pointer-events: none;
}
.global-glow-1 {
    position: fixed; top: -10%; left: -10%; width: 50vw; height: 50vw;
    background: rgba(96, 165, 250, 0.12); border-radius: 50%;
    filter: blur(120px); pointer-events: none; z-index: -2;
}
.global-glow-2 {
    position: fixed; bottom: -10%; right: -10%; width: 50vw; height: 50vw;
    background: rgba(129, 140, 248, 0.12); border-radius: 50%;
    filter: blur(120px); pointer-events: none; z-index: -2;
}

.bento-card {
    background: rgba(255, 255, 255, 1);
    border-radius: 2rem; border: 1px solid rgba(226, 232, 240, 0.8);
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.05);
    transition: all 0.3s ease-out; position: relative; overflow: hidden;
}
.bento-card:hover { box-shadow: 0 20px 40px -10px rgba(15, 23, 42, 0.08); border-color: #cbd5e1; }

.video-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; background: #000; border-radius: 1rem;}
.video-container iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }
.vk-video-wrapper { position: relative; padding-bottom: 177.78%; height: 0; overflow: hidden; background: #000; border-radius: 1rem;}
.vk-video-wrapper iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; }

.scroller {
    max-width: 100%;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
}
.scroller__inner {
    width: max-content;
    display: flex;
    gap: 1rem;
    animation: scroll 40s linear infinite;
}
.scroller[data-direction="right"] .scroller__inner {
    animation-direction: reverse;
}
.scroller:hover .scroller__inner {
    animation-play-state: paused;
}
@keyframes scroll {
    to { transform: translateX(calc(-50% - 0.5rem)); }
}

.reveal { opacity: 1; transform: none; }
.js .reveal { opacity: 0; transform: translateY(40px); transition: 0.8s cubic-bezier(0.16, 1, 0.3, 1); }
.js .reveal.active { opacity: 1; transform: translateY(0); }
.delay-1 { transition-delay: 0.1s; } .delay-2 { transition-delay: 0.2s; } .delay-3 { transition-delay: 0.3s; }

.hero-marquee .scroller__inner {
    gap: 2rem;
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    color: white;
    font-weight: 700;
    text-shadow: 0 2px 12px rgba(0,0,0,0.6);
}
@media (min-width: 640px) {
    .hero-marquee .scroller__inner { font-size: 0.875rem; }
}
@media (min-width: 768px) {
    .hero-marquee .scroller__inner { font-size: 1rem; }
}

.brand-scroller .scroller__inner {
    gap: 1.5rem;
    align-items: center;
}
.brand-scroller .brand-item {
    height: 60px;
    width: 120px;
    background: white;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.75rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: all 0.2s;
    flex-shrink: 0;
}
.brand-scroller .brand-item:hover {
    border-color: #3b82f6;
    box-shadow: 0 8px 20px rgba(37,99,235,0.10);
    transform: scale(1.02);
}
.brand-scroller .brand-item img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    filter: none;
}
@media (min-width: 640px) {
    .brand-scroller .brand-item { height: 72px; width: 144px; padding: 0.75rem 1rem; }
}
@media (min-width: 768px) {
    .brand-scroller .brand-item { height: 80px; width: 160px; }
}

/* Form validation styles */
.footer-form input, .footer-form textarea {
    width: 100%;
    padding: 0.6rem 1rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    font-size: 0.875rem;
    transition: border-color 0.2s, background-color 0.2s;
    outline: none;
}
.footer-form input:focus, .footer-form textarea:focus {
    border-color: #3b82f6;
    background: white;
}
.footer-form input:not(:placeholder-shown):invalid, 
.footer-form textarea:not(:placeholder-shown):invalid {
    border-color: #ef4444;
    background-color: #fef2f2;
}
.footer-form input:not(:placeholder-shown):valid, 
.footer-form textarea:not(:placeholder-shown):valid {
    border-color: #10b981;
}

.footer-form .checkbox-group label {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: #94a3b8;
    cursor: pointer;
}
.footer-form .checkbox-group label input {
    width: 16px;
    height: 16px;
    margin-top: 0.15rem;
    flex-shrink: 0;
    accent-color: #3b82f6;
}

/* Toast notification */
.toast {
    position: fixed;
    top: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: #0f172a;
    color: white;
    padding: 1.25rem 2rem;
    border-radius: 1.25rem;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    z-index: 9999;
    max-width: 92%;
    width: 480px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    text-align: center;
    border: 1px solid rgba(255,255,255,0.08);
    backdrop-filter: blur(12px);
    background: rgba(15, 23, 42, 0.95);
    overflow: hidden;
}
.toast.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.toast .toast-icon {
    font-size: 2rem;
    color: #34d399;
    display: block;
    margin-bottom: 0.5rem;
}
.toast .toast-title {
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}
.toast .toast-desc {
    font-size: 0.9rem;
    color: #94a3b8;
}
.toast .toast-close {
    position: absolute;
    top: 0.75rem;
    right: 1rem;
    background: none;
    border: none;
    color: #64748b;
    font-size: 1.25rem;
    cursor: pointer;
    transition: color 0.2s;
}
.toast .toast-close:hover { color: white; }

.toast-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    background: #34d399;
    width: 100%;
    transform-origin: left;
}
.toast.show .toast-progress {
    animation: drain 6s linear forwards;
}
@keyframes drain {
    0% { transform: scaleX(1); }
    100% { transform: scaleX(0); }
}

@media (max-width: 480px) {
    .toast { padding: 1rem 1.25rem; width: 94%; top: 80px; }
    .toast .toast-title { font-size: 1rem; }
    .toast .toast-desc { font-size: 0.8rem; }
}

#main-header .logo-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.25rem 0;
}
@media (min-width: 640px) {
    #main-header .logo-wrapper { gap: 1rem; padding: 0.25rem 0.25rem 0.25rem 0; }
}
#main-header .logo-wrapper img { flex-shrink: 0; }
#main-header .logo-divider { display: none; }
@media (min-width: 640px) {
    #main-header .logo-divider {
        display: block; width: 1px; height: 28px; background: #cbd5e1; flex-shrink: 0;
    }
}
#main-header .logo-text {
    display: none; font-family: 'Unbounded', sans-serif; font-weight: 700;
    font-size: 8px; text-transform: uppercase; letter-spacing: 0.15em; color: #94a3b8; line-height: 1.2;
}
@media (min-width: 640px) {
    #main-header .logo-text { display: block; }
}

@media (max-width: 480px) {
    #main-header .logo-wrapper img { height: 32px; }
    #main-header .logo-wrapper { gap: 0.5rem; }
    #main-header { padding: 0 0.5rem; }
}

/* Cookies Popup */
#cookie-popup.show-cookie {
    transform: translateY(0);
    opacity: 1;
}
