/* ============================================================
   RESPONSIVE MEDIA QUERIES
   ============================================================ */

/* ── Tablet Large (≤1100px) ── */
@media (max-width: 1100px) {
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 52px;
        text-align: center;
    }

    .hero-content {
        order: 1;
    }

    .hero-visual {
        order: 2;
        max-width: 600px;
        margin: 0 auto;
    }

    .hero-badge {
        display: inline-flex;
    }

    .hero-desc {
        max-width: 100%;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .hero-mini.f1 {
        left: 0;
    }

    .hero-mini.f2 {
        right: 0;
    }

    .services-grid {
        grid-template-columns: 1fr 1fr;
    }

    .service-card.featured {
        grid-column: span 2;
    }

    .about-inner {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .about-visual {
        order: 2;
    }

    .about-float {
        right: 0;
    }

    .steps-track {
        grid-template-columns: repeat(3, 1fr);
        gap: 32px;
    }

    .steps-track::before {
        display: none;
    }

    .faq-inner {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .team-staff .team-grid,
    .team-section-staff .team-grid,
    .team-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 36px;
    }

    .footer-brand {
        grid-column: 1 / -1;
    }
}

/* ── Tablet (≤900px) — collapse navbar ── */
@media (max-width: 900px) {
    .section {
        padding: 80px 0;
    }

    /* Navbar: hide desktop links & actions, show hamburger */
    .nav-menu,
    .nav-actions {
        display: none;
    }

    .nav-toggle {
        display: flex;
    }

    /* Floating header: reduce padding so the pill isn't too tall */
    .header {
        padding: 10px 14px;
    }

    .navbar {
        padding: 12px 18px;
    }

    /* Hero: clear the floating pill header (~68px total at tablet) */
    .hero {
        padding: 110px 0 70px;
    }

    .hero-title {
        font-size: clamp(2.2rem, 7vw, 3.2rem);
    }

    /* Services */
    .services-grid {
        grid-template-columns: 1fr;
    }

    .service-card.featured {
        grid-column: span 1;
        grid-template-columns: 1fr;
    }

    .feature-visual {
        display: none;
    }

    /* Stats */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .stat-card:nth-child(2) {
        border-right: 1px solid var(--border);
    }

    .stat-card:nth-child(even) {
        border-right: none;
    }

    /* Steps */
    .steps-track {
        grid-template-columns: repeat(2, 1fr);
        gap: 28px;
    }

    /* Team — 2 columns on tablet */
    .team-staff .team-grid,
    .team-section-staff .team-grid,
    .team-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* News */
    .news-grid {
        grid-template-columns: 1fr;
    }
}

/* ── Mobile (≤640px) ── */
@media (max-width: 640px) {
    html {
        font-size: 15px;
    }

    .container {
        width: calc(100% - 36px);
        margin-inline: auto;
        padding-inline: 0;
    }

    .section {
        padding: 64px 0;
    }

    /* Header: compact floating pill on mobile */
    .header {
        padding: 10px 14px;
    }

    .header-wrap {
        border-radius: 14px;
    }

    .navbar {
        padding: 10px 16px;
    }

    .nav-logo-img {
        height: 30px;
    }

    /* Hero: clear floating header (~64px) + breathing room */
    .hero {
        padding: 110px 0 56px;
        min-height: auto;
    }

    .hero-inner {
        gap: 36px;
    }

    .hero-title {
        font-size: clamp(1.9rem, 9vw, 2.8rem);
        line-height: 1.15;
        letter-spacing: -0.02em;
    }

    .hero-desc {
        font-size: 0.97rem;
    }

    .hero-actions {
        flex-direction: column;
        gap: 12px;
        width: 100%;
    }

    .hero-actions .btn {
        width: 100%;
        justify-content: center;
    }

    .hero-stats {
        gap: 24px;
        flex-wrap: wrap;
    }

    .stat-num {
        font-size: 1.65rem;
    }

    .hero-mini {
        display: none;
    }

    /* Section headers */
    .section-title {
        font-size: clamp(1.6rem, 6vw, 2.2rem);
    }

    .section-subtitle {
        font-size: 0.95rem;
    }

    /* Services */
    .services-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .service-card {
        padding: 26px 22px;
    }

    /* Steps */
    .steps-track {
        grid-template-columns: 1fr;
        gap: 20px;
        max-width: 340px;
        margin: 0 auto;
    }

    .step-item {
        flex-direction: row;
        text-align: left;
        align-items: flex-start;
        gap: 16px;
        padding: 0;
    }

    .step-circle {
        width: 56px;
        height: 56px;
        min-width: 56px;
        margin-bottom: 0;
    }

    .step-num {
        font-size: 1.05rem;
    }

    /* About */
    .about-inner {
        gap: 36px;
    }

    .about-card {
        min-height: auto;
        padding: 24px 20px;
    }

    .about-float {
        position: static;
        margin-top: 16px;
        display: inline-flex;
        gap: 10px;
        align-items: center;
    }

    .float-num {
        font-size: 1.6rem;
    }

    /* Stats */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0;
    }

    .stat-card {
        padding: 32px 20px;
        border-right: 1px solid var(--border);
    }

    .stat-card:nth-child(even) {
        border-right: none;
    }

    .stat-card:nth-child(n+3) {
        border-top: 1px solid var(--border);
    }

    .stat-big {
        font-size: 2.4rem;
    }

    /* Testimonials */
    .testimonial-quote {
        padding: 30px 24px;
    }

    .testimonial-text {
        font-size: 0.97rem;
    }

    .testimonial-author {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    /* Team — 2 portrait columns on mobile (cards are tall, 2 fits well) */
    .team-staff .team-grid,
    .team-section-staff .team-grid,
    .team-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .team-staff .team-card,
    .team-section-staff .team-card,
    .team-card {
        padding-bottom: 24px;
        min-height: auto;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        box-sizing: border-box;
    }

    .team-staff .team-img-wrap,
    .team-img-wrap {
        width: 100%;
        height: auto;
        aspect-ratio: 3.2 / 4;
        flex-shrink: 0;
    }

    .team-info {
        width: 100%;
        box-sizing: border-box;
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    /* FAQ */
    .faq-inner {
        gap: 32px;
    }

    .faq-question {
        padding: 16px 18px;
    }

    .faq-answer-inner {
        padding: 0 18px 16px;
    }

    /* Partners */
    .partners-grid {
        gap: 14px;
    }

    .partner-item {
        min-width: 130px;
        padding: 18px 20px;
    }

    .partner-item img {
        height: 72px;
        max-width: 150px;
    }

    /* News */
    .news-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    /* CTA */
    .cta-section {
        padding: 72px 0;
    }

    .cta-inner h2 {
        font-size: clamp(1.7rem, 7vw, 2.4rem);
    }

    .cta-actions {
        flex-direction: column;
        gap: 12px;
    }

    .cta-actions .btn {
        width: 100%;
        justify-content: center;
    }

    /* Footer */
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 36px;
    }

    .footer-brand {
        grid-column: 1;
    }

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

    .footer-bottom-links {
        justify-content: center;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .newsletter-btn {
        width: 100%;
    }
}

/* ── Mobile Small (≤350px) ── */
@media (max-width: 350px) {
    .hero-stats {
        flex-direction: column;
        gap: 16px;
        padding-top: 24px;
    }

    .stat-item {
        display: flex;
        gap: 10px;
        align-items: center;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .stat-card {
        border-right: none !important;
        border-top: 1px solid var(--border);
    }

    .stat-card:first-child {
        border-top: none;
    }

    /* Team — single column on very small screens */
    .team-staff .team-grid,
    .team-section-staff .team-grid,
    .team-grid {
        grid-template-columns: 1fr;
        max-width: 320px;
        margin: 0 auto;
    }
}

/* ── Mobile Menu ── */
.mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 300px;
    max-width: 90vw;
    background: #ffffff;
    z-index: 2000;
    padding: 28px 24px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -8px 0 40px rgba(123, 93, 255, 0.12);
    border-left: 1px solid var(--border)
}

.mobile-menu.open {
    transform: translateX(0);
}

.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(26, 22, 48, 0.5);
    z-index: 1999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
    backdrop-filter: blur(2px);
}

.mobile-menu-overlay.open {
    opacity: 1;
    pointer-events: all;
}

.mobile-menu-close {
    align-self: flex-end;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--purple-dim);
    color: var(--purple);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
}

.mobile-menu-close svg {
    width: 18px;
    height: 18px;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.mobile-nav-link {
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--text);
    padding: 12px 14px;
    border-radius: var(--r-md);
    transition: var(--t);
}

.mobile-nav-link:hover {
    background: var(--purple-dim);
    color: var(--purple);
}

.mobile-submenu {
    padding-left: 16px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.mobile-submenu-link {
    font-size: 0.88rem;
    color: var(--text-muted);
    padding: 8px 12px;
    border-radius: var(--r-sm);
    transition: var(--t);
}

.mobile-submenu-link:hover {
    color: var(--purple);
    background: var(--purple-dim);
}

/* Mobile menu footer: language switcher + CTA */
.mobile-menu-footer {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
}

.mobile-lang-row {
    display: flex;
    gap: 8px;
    align-items: center;
}

.mobile-lang-row .lang-pill {
    flex: 1;
    text-align: center;
    padding: 8px 12px;
}

.mobile-cta-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 20px;
    background: var(--purple);
    color: #fff;
    border-radius: var(--r-full);
    font-size: 0.9rem;
    font-weight: 700;
    font-family: var(--font-head);
    text-decoration: none;
    transition: var(--t);
    box-shadow: 0 3px 18px var(--purple-glow);
}

.mobile-cta-btn:hover {
    background: var(--purple-soft);
}