:root {
    --bg: #f9fafe;
    --bg-soft: #ffffff;
    --text: #1b1e21;
    --muted: rgb(77, 91, 124);
    --primary: #ff0030;
    --primary-600: #e01319;
    --accent: #1b1e21;
    --brand-blue: #6090f0;
    --card: #ffffff;
    --line: rgba(0,0,0,0.08);
    --radius: 14px;
    --shadow: 0 8px 24px rgba(16, 24, 40, 0.08);
}

* { box-sizing: border-box; }
html, body { overflow-x: hidden; }
[hidden] { display: none !important; }
body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font: 16px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }

/* Layout */
.container, .media-container, .footer-container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
section { padding: 64px 0; }

/* Header */
header { background: rgba(255, 255, 255, 0.3); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); position: fixed; left: 0; right: 0; top: 0; z-index: 1000; box-shadow: 0 0 16px rgba(0,0,0,0.05); }
nav { display: flex; align-items: center; justify-content: space-between; min-height: 44px; width: 80%; margin: 0 auto; position: relative; }
.logo { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.logo a { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--text); }
.logo .description span { color: var(--text); font-size: 12px; }
/* prevent wrapping inside logo description */
.logo .description { white-space: nowrap; }
.navbar .navbar-nav { list-style: none; display: flex; gap: 10px; padding: 0; margin: 0; }
.navbar .nav-link { color: var(--text); opacity: 0.9; padding: 6px 8px; border-radius: 8px; position: relative; display: inline-flex; align-items: center; gap: 6px; line-height: 1; }
.navbar .nav-link:hover { opacity: 1; }
.navbar .nav-link::after { content: none; }
.navbar .nav-link.active::after { content: none; }
.navbar .nav-link:hover::after { transform: scaleX(1); }
.menu a { color: #ffffff; text-decoration: none; }
.menu a:hover { color: #6090f0; }
.nav-item.has-dropdown { position: relative; }
.nav-item.has-dropdown > .nav-link { position: relative; }
.nav-item.has-dropdown > .nav-link:after { content: ""; position: absolute; left: 0; right: 0; bottom: -12px; height: 12px; }
.nav-item .dropdown:before { content: ""; position: absolute; top: -12px; left: 0; right: 0; height: 12px; }
.nav-item .dropdown { display: none; position: absolute; top: 100%; left: 0; min-width: 220px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 6px; box-shadow: 0 8px 24px rgba(16,24,40,0.12); z-index: 1000; opacity: 0; transform: translateX(var(--dd-left, 0)) translateY(6px); visibility: hidden; transition: opacity .18s ease, transform .2s ease, visibility 0s linear .2s; }
.nav-item .dropdown.mega { display: none; white-space: nowrap; padding: 8px; }
.nav-item .dropdown .group { display: inline-flex; flex-direction: column; vertical-align: top; padding: 6px 8px; min-width: 200px; }
.nav-item .dropdown .group .title { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 0 0 8px; line-height: 1.2; }

.nav-item .dropdown li { list-style: none; }
.nav-item .dropdown a { display: flex; align-items: center; gap: 6px; padding: 6px 8px; color: var(--text); border-radius: 8px; }
.nav-item .dropdown a:hover { background: #f4f6fb; }
.nav-item.has-dropdown:hover .dropdown, .nav-item .dropdown:hover { display: block; opacity: 1; transform: translateX(var(--dd-left, 0)); visibility: visible; transition-delay: 0s; }


/* Mega dropdown viewport fit + arrow */
.nav-item .dropdown.mega { max-width: 1232px; min-width: 1200px; will-change: transform; }
.nav-item .dropdown.mega::after { content: ""; position: absolute; top: -6px; left: 50%; width: 12px; height: 12px; background: #fff; border-left: 1px solid var(--line); border-top: 1px solid var(--line); transform: translateX(-50%) rotate(45deg); box-shadow: -2px -2px 6px rgba(16,24,40,0.06); z-index: 1; }

/* Compact nav icons */
.nav-icon { display: inline-flex; width: 16px; height: 16px; align-items: center; justify-content: center; color: var(--muted); }
.nav-icon svg { width: 16px; height: 16px; display: block; stroke: currentColor; fill: none; stroke-width: 1.8; }
.navbar .nav-link:hover .nav-icon { color: var(--brand-blue); transform: translateY(-1px); transition: color .15s ease, transform .2s cubic-bezier(.16,1,.3,1); }
.nav-text { white-space: nowrap; }

/* Dropdown icon hover */
.nav-item .dropdown a:hover .nav-icon { color: var(--brand-blue); }

/* Mobile menu section titles */
.menu .mobile-title { color: #b0b0b0; padding: 8px 0 0; margin-top: 6px; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.separator { display: inline-block; width: 1px; height: 18px; background: var(--line); margin: 0 8px; align-self: center; }
/* Mobile nav */
.hamburger { display: none; width: 44px; height: 44px; align-items: center; justify-content: center; cursor: pointer; background: transparent; border: 0; padding: 0; }
.hamburger > div, .hamburger > div::before, .hamburger > div::after { content: ""; display: block; height: 2px; width: 24px; background: var(--text); border-radius: 2px; position: relative; }
.hamburger > div::before { position: absolute; top: -7px; }
.hamburger > div::after { position: absolute; top: 7px; }
.menu { display: none; position: fixed; top: 44px; left: 0; right: 0; bottom: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%); border-top: 1px solid rgba(255,255,255,0.1); z-index: 10000; will-change: transform, opacity; opacity: 0; visibility: hidden; }
.menu ul { list-style: none; margin: 0; padding: 12px 20px; display: grid; gap: 8px; }
.menu.is-open { display: block; opacity: 1; visibility: visible; }
/* Fallback: show menu when body has state class */
body.menu-open .menu { display: block; opacity: 1; visibility: visible; }
/* CSS fallback: open menu when aria-expanded=true */
.hamburger[aria-expanded="true"] + .menu { display: block; }
body.no-scroll { overflow: hidden; }

/* Hero */
.main-section {
    position: relative;
    overflow: hidden;
    background: linear-gradient(180deg, var(--bg-soft), var(--bg));
    margin-top: 44px;
    padding: 40px 0 80px 0;
    /* Use stable viewport height on mobile to prevent jump when URL bar collapses */
    min-height: calc(100vh - 44px);
    min-height: calc(100svh - 44px);
    display: flex;
    align-items: center;
}
/* Prefer dynamic viewport when supported (modern browsers) */
@supports (min-height: 100dvh) {
    .main-section { min-height: calc(100dvh - 44px); }
}
.main-section .container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    align-items: center;
    gap: 32px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
.main-section h1 {
    margin: 0 0 12px;
    font-size: 40px;
    line-height: 1.2;
    letter-spacing: -0.02em;
    font-weight: 700;
}
.main-section p {
    color: var(--muted);
    margin: 0 0 24px;
    max-width: 56ch;
    line-height: 1.6;
}
.main-section button {
    background: var(--primary);
    color: #fff;
    border: 0;
    border-radius: 20px;
    padding: 14px 22px;
    cursor: pointer;
    box-shadow: 0px 0px 50px 0px rgba(93, 93, 93, 0.27);
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
}
.main-section button:hover {
    background: var(--primary-600);
    transform: translateY(-2px);
    box-shadow: 0px 0px 60px 0px rgba(93, 93, 93, 0.35);
}
.main-section button:active {
    transform: translateY(0);
}
/* CTA subnote under buttons */
.cta-subnote { margin-top: 10px; font-size: 14px; color: var(--muted); }
.cta-subnote a { color: inherit; display: inline-flex; align-items: center; gap: 6px; }
.cta-subnote a:hover { color: var(--accent); }
.cta-subnote svg { width: 16px; height: 16px; stroke: currentColor; }
.hero-illustration { 
    width: 100%; 
    aspect-ratio: 4/3; 
    position: relative; 
    overflow: visible; 
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border-radius: 0;
}

.hero-illustration canvas {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    box-shadow: none;
    position: relative;
    z-index: 2;
}

.hero-illustration::after {
    display: none;
}

/* Full page background canvas */
#pageBackgroundCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    pointer-events: none;
}

/* Hero section focus effect */
.main-section {
    position: relative;
    z-index: 1;
    border-radius: 0;
    overflow: visible;
}

.main-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(
        ellipse at center,
        rgba(96, 144, 240, 0.08) 0%,
        rgba(96, 144, 240, 0.04) 30%,
        rgba(96, 144, 240, 0.02) 60%,
        transparent 100%
    );
    border-radius: 0;
    z-index: -1;
    pointer-events: none;
}

/* Services */
.services-section { padding: 24px 0 70px 0; }
.services-section h2 { font-weight: 700; font-size: 32px; margin: 0 20px 24px; }
.services-section .grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.services-section .card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; position: relative; overflow: hidden; box-shadow: var(--shadow); transition: transform .2s ease; }
.services-section .card:hover { transform: translateY(-2px); }
.services-section .card a { color: inherit; display: block; }
.services-section .icon { display: inline-flex; width: 36px; height: 36px; align-items: center; justify-content: center; color: var(--brand-blue); }
.services-section h4 { margin: 12px 0 6px; font-size: 16px; }
.services-section p { margin: 0; color: var(--muted); }
.services-section .background { position: absolute; inset: 0; pointer-events: none; }
.services-section .line { position: absolute; height: 1px; left: 12px; right: 12px; background: var(--line); }
.services-section .line-1 { top: 40%; } .services-section .line-2 { top: 60%; } .services-section .line-3 { bottom: 12px; }
/* disable legacy visual noise */
.services-section .shine, .services-section .tiles, .services-section .tile, .services-section .line, .services-section .background { display: none !important; }

/* SEO blocks (left aligned) */
.seo-section h2 { margin: 0 0 12px; font-size: 28px; letter-spacing: -0.01em; }
.seo-section p { margin: 0 0 10px; color: var(--muted); }
.seo-section ul { margin: 12px 0 16px; padding-left: 18px; color: var(--text); }
.seo-section .cta { text-align: left; }
.seo-section .cta button { background: var(--primary); color: #fff; border: 0; border-radius: 20px; padding: 12px 18px; cursor: pointer; box-shadow: 0 0 50px 0 rgba(93,93,93,0.27); font-size: 16px; }
.seo-section .cta button:hover { background: var(--primary-600); }
.seo-section .cta button span { display: inline-block; position: relative; transition: 0.3s; }
.seo-section .cta button span:after { content: "\00bb"; position: absolute; opacity: 0; top: 0; right: -16px; transition: 0.3s; }
.seo-section .cta button:hover span { padding-right: 20px; }
.seo-section .cta button:hover span:after { opacity: 1; right: 0; }
.seo-section .faq details { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; }
.seo-section .faq summary { cursor: pointer; font-weight: 600; }

/* Popular links */
.popular-links h2, .popular-links h3 { margin: 0 0 12px; }
.popular-links ul { list-style: none; padding: 0; margin: 0 0 16px; columns: 2; gap: 24px; }
.popular-links li { break-inside: avoid; padding: 6px 0; }

/* Media */
.in-media {
    padding-bottom: 60px;
}

.in-media .media-carousel {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
}

.in-media .carousel-container {
    overflow: hidden;
    border-radius: var(--radius);
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
    min-height: 250px;
}

.in-media .carousel-track {
    display: flex;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    gap: 0;
}

.in-media .carousel-track > * {
    flex: 0 0 calc(25% - 15px);
    min-width: calc(25% - 15px);
    margin-right: 15px;
}

.in-media .carousel-track > *:last-child {
    margin-right: 0;
}

/* Скрываем клоны от пользователя в медиа-карусели */
.in-media .carousel-track .clone {
    pointer-events: none;
}

.in-media .media-card { 
    background: var(--card); 
    border: 1px solid var(--line); 
    border-radius: var(--radius); 
    overflow: hidden;
    transition: all 0.3s ease;
    height: 200px;
    display: flex;
    flex-direction: column;
}

.in-media .media-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
    border-color: var(--primary);
}

.in-media .media-card a {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.in-media .card-title { 
    font-size: 16px; 
    margin: 0; 
    padding: 16px 16px 8px; 
    color: var(--text);
    font-weight: 600;
    line-height: 1.3;
}

.in-media .card-content { 
    padding: 0 16px 16px; 
    color: var(--muted);
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.in-media .card-content p {
    margin: 0;
    line-height: 1.5;
    font-size: 14px;
    flex-grow: 1;
}

/* Media carousel controls */
.in-media .carousel-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 25px;
    position: absolute;
    top: 50%;
    left: -22px;
    right: -22px;
    transform: translateY(-50%);
    pointer-events: none;
    z-index: 10;
}

.in-media .carousel-btn {
    background: var(--card);
    border: 2px solid var(--line);
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text);
    box-shadow: var(--shadow);
    pointer-events: auto;
}

.in-media .carousel-btn:hover {
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 0, 48, 0.3);
}

.in-media .carousel-btn:active {
    transform: translateY(0);
}

.in-media .carousel-btn svg {
    width: 18px;
    height: 18px;
}

.in-media .carousel-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.in-media .carousel-btn:disabled:hover {
    background: var(--card);
    color: var(--text);
    border-color: var(--line);
    box-shadow: var(--shadow);
}

/* Media carousel dots */
.in-media .carousel-dots {
    display: flex;
    gap: 8px;
    pointer-events: auto;
    position: absolute;
    bottom: -58px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.in-media .carousel-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--line);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.in-media .carousel-dot:hover {
    background: var(--brand-blue);
    transform: scale(1.2);
}

.in-media .carousel-dot.active {
    background: var(--primary);
    transform: scale(1.2);
}

/* Reveal animations */
.reveal { opacity: 0; transform: translateY(12px) scale(0.996); transition: opacity .4s ease, transform .5s cubic-bezier(.16,1,.3,1); }
.reveal.is-visible,
.reveal.animate { opacity: 1; transform: none; }

/* Обратная совместимость для класса animate */
.animate {
    opacity: 1;
    transform: none;
}

/* 
 * Классы анимаций для обеспечения совместимости:
 * - .is-visible - основной класс для IntersectionObserver
 * - .animate - обратная совместимость для старых скриптов
 * 
 * Все классы обеспечивают одинаковый результат:
 * opacity: 1 и transform: none
 */

/* Card micro-interactions */
.services-section .icon svg { transition: transform .2s ease; }
.services-section .card:hover .icon svg { transform: translateY(-2px); }
.services-section .card { transition: transform .2s ease, box-shadow .2s ease; }
.services-section .card:hover { box-shadow: 0 10px 30px rgba(16,24,40,0.12); }

/* Hero parallax */
.hero-illustration { transition: transform .3s ease; transform: translate3d(var(--tx, 0px), var(--ty, 0px), 0) scale(1.01); }

/* About */
.about h2 { margin: 0 0 10px; }
.about p { color: var(--muted); }

/* Benefits */
.benefits-section { background: var(--bg-soft); padding: 40px 0 60px 0; }
.benefits-section .container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.benefits-header { text-align: left; margin-bottom: 18px; }
.benefits-header h2 { margin: 0 0 6px; font-size: 28px; letter-spacing: -0.01em; }
.benefits-header p { margin: 0; color: var(--muted); }
.benefits-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.benefit-item { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; position: relative; overflow: hidden; }
.benefit-item:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(16,24,40,0.12); border-color: rgba(96,144,240,0.25); }
.benefit-icon { width: 40px; height: 40px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; color: var(--brand-blue); background: rgba(96,144,240,0.08); border: 1px solid rgba(96,144,240,0.2); }
.benefit-icon svg { width: 22px; height: 22px; stroke: currentColor; }
.benefit-icon svg.is-ready path,
.benefit-icon svg.is-ready line,
.benefit-icon svg.is-ready rect,
.benefit-icon svg.is-ready circle,
.benefit-icon svg.is-ready polyline,
.benefit-icon svg.is-ready polygon { stroke-dasharray: var(--dash, 100); stroke-dashoffset: var(--dash, 100); }
.reveal.is-visible .benefit-item:nth-child(1) .benefit-icon svg.is-ready * { animation: draw-stroke 1.1s ease .65s forwards; }
.reveal.is-visible .benefit-item:nth-child(2) .benefit-icon svg.is-ready * { animation: draw-stroke 1.1s ease .8s forwards; }
.reveal.is-visible .benefit-item:nth-child(3) .benefit-icon svg.is-ready * { animation: draw-stroke 1.1s ease .95s forwards; }
@keyframes draw-stroke { to { stroke-dashoffset: 0; } }
.benefit-item h3 { margin: 12px 0 6px; font-size: 16px; line-height: 1.3; }
.benefit-item p { margin: 0; color: var(--muted); }
@media (max-width: 1024px){ .benefits-grid { grid-template-columns: 1fr; } }

/* Footer */
footer { background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%); color: #ffffff; }
.footer-main { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; padding: 50px 0 30px 0; }
.footer-logo img { height: 20px; filter: brightness(0) invert(1); }
 .footer-tagline { color: #6090f0; font-size: 12px; margin-left: 8px; }
 .footer-description { color: #b0b0b0; }
.footer-social { display: flex; gap: 10px; }
.footer-links { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.footer-section h6 { margin: 0 0 8px; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: #ffffff; position: relative; }
.footer-section h6::after { content: ""; position: absolute; bottom: -5px; left: 0; width: 30px; height: 2px; background: #6090f0; }
.footer-section ul { list-style: none; padding: 0; margin: 0; }
.footer-section a { color: #b0b0b0; opacity: 1; }
.footer-section a:hover { color: #6090f0; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding: 20px 0; margin-top: 10px; color: #888888; text-align: center; }

/* Responsive */
@media (max-width: 1024px) {
    nav { width: 100%; padding: 0 12px; }
    .navbar { display: none; }
    .hamburger { display: inline-flex; position: absolute; top: 0; right: 0; height: 44px; width: 48px; padding: 0; align-items: center; justify-content: center; cursor: pointer; z-index: 1002; }
    .main-section .container { grid-template-columns: 1fr; padding: 0 20px; }
    .hero-illustration { order: -1; }
    .hero-illustration canvas { width: 100%; height: 100%; }
    .services-section .grid { grid-template-columns: repeat(2, 1fr); padding: 0 16px; }
    .in-media .carousel-track > * {
        flex: 0 0 calc(50% - 15px);
        min-width: calc(50% - 15px);
        margin-right: 15px;
    }
    
    .in-media .media-card {
        height: 180px;
    }
    
    .in-media .card-title {
        font-size: 15px;
        padding: 14px 14px 6px;
    }
    
    .in-media .card-content {
        padding: 0 14px 14px;
    }
    
    .in-media .card-content p {
        font-size: 13px;
    }
    .footer-main { grid-template-columns: 1fr; }
    .menu.is-open { min-height: calc(100vh - 44px); }
}
/* Hide logo description on medium screens to avoid overlap with menu */
@media (max-width: 1280px) {
    .logo .separator, .logo .description { display: none; }
}
/* Show hamburger and hide desktop nav up to 1280px */
@media (max-width: 1280px) {
    .navbar { display: none; }
    .hamburger { display: inline-flex; position: absolute; top: 0; right: 0; height: 44px; width: 48px; padding: 0; align-items: center; justify-content: center; cursor: pointer; z-index: 1002; }
}
@media (max-width: 640px) {
    section { padding: 40px 0; }
    .main-section h1 { font-size: 32px; }
    .popular-links ul { columns: 1; padding: 0 16px; }
    .services-section .grid { grid-template-columns: 1fr; gap: 12px; padding: 0 16px; }
    .menu ul { padding: 16px; display: flex; flex-direction: column; gap: 12px; }
    
    /* Footer adjustments for mobile */
    .footer-main { grid-template-columns: 1fr; gap: 20px; padding: 30px 0 20px 0; }
    .footer-links { grid-template-columns: 1fr; gap: 16px; }
    .footer-section h6 { font-size: 12px; margin-bottom: 8px; }
    .footer-section a { font-size: 14px; }
    .footer-bottom { padding: 15px 0; }
    .footer-copyright { font-size: 12px; }
    
    .in-media .carousel-track > * {
        flex: 0 0 100%;
        min-width: 100%;
        margin-right: 0;
    }
    
    .in-media .media-card {
        height: 160px;
    }
    
    .in-media .carousel-container {
        min-height: 200px;
    }
    
    .in-media .card-title {
        font-size: 14px;
        padding: 12px 12px 6px;
    }
    
    .in-media .card-content {
        padding: 0 12px 12px;
    }
    
    .in-media .card-content p {
        font-size: 12px;
    }
    
    .in-media .carousel-controls {
        margin-top: 20px;
        gap: 15px;
        position: relative;
        top: auto;
        left: auto;
        right: auto;
        transform: none;
        justify-content: center;
    }
    
    .in-media .carousel-btn {
        width: 40px;
        height: 40px;
    }
    
    .in-media .carousel-btn svg {
        width: 16px;
        height: 16px;
    }
    
    .in-media .carousel-dots {
        position: relative;
        bottom: auto;
        left: auto;
        transform: none;
        margin-top: 15px;
    }
    
    .in-media {
        padding-bottom: 40px;
    }
}

/* Business Form */
.business-form {
    background: linear-gradient(135deg, #2d2d2d 0%, #1a1a1a 100%);
    padding: 48px 0;
    margin: 32px auto;
    max-width: 100%;
    overflow: hidden;
    box-sizing: border-box;
}

.form-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
    max-width: 100%;
}

.form-left h2 {
    color: #ffffff;
    font-size: 32px;
    line-height: 1.2;
    margin: 0 0 16px;
    font-weight: 700;
    padding-left: 20px;
}

.form-left p {
    color: #e0e0e0;
    font-size: 18px;
    line-height: 1.5;
    margin: 0;
    padding-left: 20px;
}

.form-right {
    background: #ffffff;
    padding: 40px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    max-width: 100%;
    box-sizing: border-box;
}

.business-form-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 100%;
}

.business-form-form input,
.business-form-form textarea {
    padding: 16px 20px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 16px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    background: #ffffff;
    width: 100%;
    box-sizing: border-box;
    font-family: inherit;
    resize: vertical;
}

.business-form-form input:focus,
.business-form-form textarea:focus {
    outline: none;
    border-color: var(--brand-blue);
    box-shadow: 0 0 0 3px rgba(96, 144, 240, 0.1);
}

.form-note {
    font-size: 12px;
    color: #6b7280;
    text-align: center;
    margin-top: 10px;
    line-height: 1.4;
}

/* Form Features */
.form-features {
    margin-top: 32px;
    padding-left: 20px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    color: #ffffff;
    font-size: 16px;
    font-weight: 500;
}

.feature-icon {
    width: 32px;
    height: 32px;
    background: rgba(96, 144, 240, 0.1);
    border: 1px solid rgba(96, 144, 240, 0.3);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--brand-blue);
    flex-shrink: 0;
}

.feature-icon svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    stroke-width: 1.5;
}

.business-form-form input::placeholder {
    color: #9ca3af;
}

.business-form-form button {
    background: var(--accent);
    color: #ffffff;
    border: none;
    padding: 16px 24px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    width: 100%;
    box-sizing: border-box;
}

.business-form-form button:hover {
    background: #000000;
    transform: translateY(-2px);
}

.form-disclaimer {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.5;
    margin: 0;
    max-width: 100%;
    word-wrap: break-word;
}

.form-disclaimer a {
    color: var(--brand-blue);
    text-decoration: underline;
}

.form-disclaimer a:hover {
    color: #4f46e5;
}

/* Responsive for business form */
@media (max-width: 768px) {
    .form-container {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .form-left h2 {
        font-size: 28px;
        padding-left: 0;
    }
    
    .form-left p {
        font-size: 16px;
        padding-left: 0;
    }
    
    .form-right {
        padding: 32px 24px;
    }
    
    .business-form {
        margin: 16px auto;
        padding: 32px 0;
    }
}

@media (max-width: 480px) {
    .form-right {
        padding: 24px 16px;
    }
    
    .business-form-form input,
    .business-form-form button {
        padding: 14px 16px;
    }
    
    /* Additional footer fixes for small screens */
    .footer-container { padding: 0 12px; }
    .footer-main { padding: 25px 0 15px 0; gap: 16px; }
    .footer-links { gap: 12px; }
    .footer-section { text-align: center; }
    .footer-section h6 { font-size: 11px; }
    .footer-section a { font-size: 13px; word-break: break-word; }
    .footer-bottom { padding: 12px 0; }
    .footer-copyright { font-size: 11px; }
    
    .in-media .carousel-controls {
        position: relative;
        top: auto;
        left: auto;
        right: auto;
        transform: none;
        justify-content: center;
        margin-top: 15px;
    }
    
    .in-media .carousel-dots {
        position: relative;
        bottom: auto;
        left: auto;
        transform: none;
        margin-top: 12px;
    }
    
    .in-media .carousel-btn {
        width: 36px;
        height: 36px;
    }
    
    .in-media .carousel-btn svg {
        width: 14px;
        height: 14px;
    }
    
    .in-media {
        padding-bottom: 30px;
    }
    
    .in-media .carousel-container {
        min-height: 180px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Mega dropdown for services - smaller width */
.nav-item .dropdown.mega.services-mega {
    max-width: 600px;
    min-width: 500px;
}

.nav-item .dropdown.mega.services-mega .group {
    min-width: 250px;
}

/* Regular mega dropdown styles */
.nav-item .dropdown.mega { display: none; white-space: nowrap; padding: 8px; }

/* Case Showcase Section */
.case-showcase {
    background: var(--bg-soft);
    padding: 30px 0 60px 0;
    position: relative;
    min-height: 500px;
}

.case-showcase h2 {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 25px;
    color: var(--text);
    position: relative;
    animation: caseTitleSlideIn 0.8s ease-out 0.1s both;
}

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

.case-showcase h2::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--primary);
    border-radius: 2px;
}

.case-card-large {
    background: var(--card);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid var(--line);
    position: relative;
    max-width: 350px;
    margin: 0 auto;
    animation: caseCardSlideIn 0.8s ease-out 0.3s both;
    height: 100%;
    display: flex;
    flex-direction: column;
}

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

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

.case-card-large::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--brand-blue), var(--primary));
    background-size: 200% 100%;
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.case-card-large:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 24px 80px rgba(16, 24, 40, 0.15);
    border-color: var(--primary);
}

.case-card-image {
    height: 160px;
    overflow: hidden;
    position: relative;
    background: linear-gradient(135deg, var(--bg-soft), var(--bg));
    border-radius: 12px 12px 0 0;
}

.case-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.case-card-large:hover .case-card-image img {
    transform: scale(1.05);
}

/* Cases carousel */
.cases-carousel {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    height: 100%;
    min-height: 400px;
}

.carousel-container {
    overflow: hidden;
    border-radius: 16px;
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
    min-height: 400px;
}

.carousel-track {
    display: flex;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    gap: 0;
    flex: 1;
    align-items: stretch;
    /* Improve touch swiping on mobile */
    touch-action: pan-y; /* allow horizontal swipes without blocking vertical scroll */
}

.carousel-track > * {
    flex: 0 0 calc(33.333% - 12px);
    min-width: calc(33.333% - 12px);
    margin-right: 12px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.carousel-track > *:last-child {
    margin-right: 0;
}

/* Скрываем клоны от пользователя */
.carousel-track .clone {
    pointer-events: none;
}

/* Case card (regular size) */
.case-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(96, 144, 240, 0.1);
    animation: caseCardStaggered 0.6s ease-out both;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.case-card:nth-child(2) { animation-delay: 0.1s; }
.case-card:nth-child(3) { animation-delay: 0.2s; }
.case-card:nth-child(4) { animation-delay: 0.3s; }
.case-card:nth-child(5) { animation-delay: 0.4s; }
.case-card:nth-child(6) { animation-delay: 0.5s; }

.case-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    border-color: rgba(96, 144, 240, 0.3);
}

.case-card .case-card-image {
    height: 140px;
}

.case-card .case-card-content {
    padding: 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.case-card .case-card-content h3 {
    font-size: 14px;
    margin-bottom: 5px;
    line-height: 1.2;
}

.case-card .case-card-content p {
    font-size: 10px;
    margin-bottom: 8px;
    line-height: 1.3;
    flex-grow: 1;
}

.case-card .case-card-footer {
    flex-direction: column;
    gap: 10px;
    align-items: stretch;
}

.case-card .case-buttons {
    flex-direction: column;
    gap: 6px;
}

.case-card .case-link-btn {
    width: 100%;
    justify-content: center;
}

/* Carousel controls */
.carousel-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 20px;
    position: absolute;
    top: 50%;
    left: -24px;
    right: -24px;
    transform: translateY(-50%);
    pointer-events: none;
    z-index: 10;
}

.carousel-btn {
    background: var(--card);
    border: 2px solid var(--line);
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text);
    box-shadow: var(--shadow);
    pointer-events: auto;
}

.carousel-btn:hover {
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 0, 48, 0.3);
}

.carousel-btn:active {
    transform: translateY(0);
}

.carousel-btn svg {
    width: 20px;
    height: 20px;
}

.carousel-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.carousel-btn:disabled:hover {
    background: var(--card);
    color: var(--text);
    border-color: var(--line);
    box-shadow: var(--shadow);
}

/* Carousel dots */
.carousel-dots {
    display: flex;
    gap: 8px;
    pointer-events: auto;
    position: absolute;
    bottom: -151px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.carousel-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--line);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.carousel-dot:hover {
    background: var(--brand-blue);
    transform: scale(1.2);
}

.carousel-dot.active {
    background: var(--primary);
    transform: scale(1.2);
}

.case-card-content {
    padding: 14px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.case-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
    margin-bottom: 10px;
}

.case-tech-tag {
    background: rgba(96, 144, 240, 0.08);
    color: var(--brand-blue);
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 9px;
    font-weight: 600;
    border: 1px solid rgba(96, 144, 240, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.case-tech-tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(96, 144, 240, 0.1), transparent);
    transition: left 0.5s ease;
}

.case-tech-tag:hover::before {
    left: 100%;
}

.case-tech-tag:hover {
    transform: translateY(-1px);
    background: rgba(96, 144, 240, 0.15);
    border-color: rgba(96, 144, 240, 0.4);
    box-shadow: 0 4px 16px rgba(96, 144, 240, 0.2);
}

.case-card-content h3 {
    color: var(--text);
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 8px;
    line-height: 1.2;
    transition: all 0.3s ease;
}

.case-card-large:hover .case-card-content h3 {
    color: var(--primary);
}

.case-card-content p {
    color: var(--muted);
    line-height: 1.3;
    font-size: 11px;
    margin-bottom: 12px;
    font-weight: 400;
    transition: color 0.3s ease;
    flex-grow: 1;
}

.case-card-large:hover .case-card-content p {
    color: var(--text);
}

.case-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.case-buttons {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
}

.case-duration-tag {
    background: rgba(255, 0, 48, 0.08);
    color: var(--primary);
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 9px;
    font-weight: 600;
    border: 1px solid rgba(255, 0, 48, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.case-duration-tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 0, 48, 0.1), transparent);
    transition: left 0.5s ease;
}

.case-duration-tag:hover::before {
    left: 100%;
}

.case-duration-tag:hover {
    transform: translateY(-1px);
    background: rgba(255, 0, 48, 0.15);
    border-color: rgba(255, 0, 48, 0.4);
    box-shadow: 0 4px 16px rgba(255, 0, 48, 0.2);
}

.case-link-btn {
    text-decoration: none;
    padding: 5px 12px;
    border-radius: 14px;
    font-size: 11px;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 90px;
}

.case-link-btn-primary {
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 4px 20px rgba(255, 0, 48, 0.3);
}

.case-link-btn-secondary {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
    box-shadow: 0 2px 10px rgba(255, 0, 48, 0.1);
}

.case-link-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    transition: left 0.5s ease;
}

.case-link-btn-primary::before {
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.case-link-btn-secondary::before {
    background: linear-gradient(90deg, transparent, rgba(255, 0, 48, 0.1), transparent);
}

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

.case-link-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(255, 0, 48, 0.4);
    background: var(--primary-600);
}

.case-link-btn-secondary:hover {
    transform: translateY(-2px);
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 6px 20px rgba(255, 0, 48, 0.3);
}

/* Responsive for case showcase */
@media (max-width: 768px) {
    .case-showcase {
        padding: 25px 0 40px 0;
        min-height: 400px;
    }
    
    .case-showcase h2 {
        font-size: 22px;
        margin-bottom: 20px;
    }
    
    .cases-carousel {
        margin: 0; /* align with container gutters */
        min-height: 350px;
    }
    
    .carousel-container {
        min-height: 350px;
    }
    
    .carousel-track > * {
        flex: 0 0 calc(50% - 10px);
        min-width: calc(50% - 10px);
        margin-right: 10px;
    }
    
    .carousel-controls {
        margin-top: 20px;
        gap: 15px;
        position: relative;
        top: auto;
        left: auto;
        right: auto;
        transform: none;
        justify-content: center;
    }
    
    .carousel-btn {
        width: 40px;
        height: 40px;
    }
    
    .carousel-dots {
        position: relative;
        bottom: auto;
        left: auto;
        transform: none;
        margin-top: 15px;
    }
    
    .case-card-image {
        height: 140px;
    }
    
    .case-card-content {
        padding: 14px;
    }
    
    .case-card-content h3 {
        font-size: 15px;
    }
    
    .case-card-footer {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }
    
    .case-buttons {
        flex-direction: column;
        gap: 5px;
        width: 100%;
    }
    
    .case-link-btn {
        min-width: auto;
        width: 100%;
        justify-content: center;
        padding: 4px 10px;
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .case-showcase {
        padding: 20px 0 30px 0;
        min-height: 350px;
    }
    
    .case-showcase h2 {
        font-size: 20px;
        margin-bottom: 15px;
    }
    
    .case-card-large {
        margin: 0; /* fill slide width on mobile */
    }
    
    .case-card-image {
        height: 120px;
    }
    
    .case-card-image img {
        object-position: center top;
    }
    
    .case-card-content {
        padding: 12px;
    }
    
    .case-card-content h3 {
        font-size: 15px;
    }
    
    .case-card-content p {
        font-size: 11px;
    }
    
    .cases-carousel {
        margin: 0; /* align with container gutters */
        min-height: 300px;
    }
    
    .carousel-container {
        min-height: 300px;
    }
    
    .carousel-track > * {
        flex: 0 0 100%;
        min-width: 100%;
        margin-right: 0;
    }
    
    .carousel-controls {
        margin-top: 15px;
        gap: 12px;
        position: relative;
        top: auto;
        left: auto;
        right: auto;
        transform: none;
        justify-content: center;
    }
    
    .carousel-btn {
        width: 36px;
        height: 36px;
    }
    
    .carousel-btn svg {
        width: 16px;
        height: 16px;
    }
    
    .carousel-dots {
        gap: 6px;
        position: relative;
        bottom: auto;
        left: auto;
        transform: none;
        margin-top: 12px;
    }
    
    .carousel-dot {
        width: 10px;
        height: 10px;
    }
    
    .case-card .case-card-content {
        padding: 12px;
    }
    
    .case-card .case-card-content h3 {
        font-size: 13px;
    }
    
    .case-card .case-card-content p {
        font-size: 10px;
    }
    
    .case-link-btn {
        padding: 3px 8px;
        font-size: 9px;
        min-width: 70px;
    }
}


