/* ==========================================================================
   ENGTEC — Responsive Design (Mobile-First Overrides)
   ========================================================================== */

/* ── Tablet & Below (≤ 1024px) ────────────────────────────────────────────── */
@media (max-width: 1024px) {
    :root {
        --header-height: 70px;
    }

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

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

    .stat:nth-child(2)::after {
        display: none;
    }

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

    .grid--asymmetric,
    .grid--asymmetric-reverse {
        grid-template-columns: 1fr;
        gap: var(--space-8);
    }
}

/* ── Mobile Nav Breakpoint (≤ 768px) ──────────────────────────────────────── */
@media (max-width: 768px) {
    h1 {
        font-size: var(--text-2xl);
    }

    h2 {
        font-size: var(--text-xl);
    }

    h3 {
        font-size: var(--text-lg);
    }

    .section {
        padding-block: var(--space-10);
    }

    /* Mobile Navigation */
    .nav-toggle {
        display: flex;
    }

    .nav {
        position: fixed;
        inset: 0;
        background: rgba(13, 33, 55, 0.98);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: var(--space-8);
        opacity: 0;
        visibility: hidden;
        transition:
            opacity var(--duration-normal) var(--ease-out),
            visibility var(--duration-normal) var(--ease-out);
        z-index: calc(var(--z-nav) - 1);
    }

    .nav--open {
        opacity: 1;
        visibility: visible;
    }

    .nav__list {
        flex-direction: column;
        gap: var(--space-6);
        text-align: center;
    }

    .nav__link {
        font-size: var(--text-lg);
        color: var(--color-text-inverse);
    }

    .lang-switcher {
        border-color: rgba(255, 255, 255, 0.2);
    }

    .lang-switcher__btn {
        color: var(--color-accent-light);
    }

    .lang-switcher__btn--active {
        background: var(--color-secondary);
    }

    /* Grid */
    .grid--2,
    .grid--3 {
        grid-template-columns: 1fr;
    }

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

    .stat::after {
        display: none;
    }

    /* Hero */
    .hero {
        min-height: auto;
        padding-block: calc(var(--header-height) + var(--space-10)) var(--space-10);
    }

    .hero__diamond {
        display: none;
    }

    .hero__actions {
        flex-direction: column;
    }

    .hero__actions .btn {
        width: 100%;
    }

    /* Form */
    .form__row {
        grid-template-columns: 1fr;
    }

    /* Footer */
    .footer__grid {
        grid-template-columns: 1fr;
        gap: var(--space-6);
    }

    .footer__bottom {
        flex-direction: column;
        gap: var(--space-4);
        text-align: center;
    }

    /* Page Hero */
    .page-hero {
        padding-top: calc(var(--header-height) + var(--space-10));
        padding-bottom: var(--space-8);
    }

    /* Map */
    .map-container {
        height: 300px;
    }

    /* Portfolio */
    .portfolio-card__overlay {
        opacity: 1;
    }

    /* Diagonal Divider */
    .diagonal-divider {
        height: 50px;
    }
}

/* ── Small Mobile (≤ 480px) ───────────────────────────────────────────────── */
@media (max-width: 480px) {
    .container {
        padding-inline: var(--space-4);
    }

    .service-card {
        padding: var(--space-5);
    }

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

    .btn--lg {
        padding: var(--space-3) var(--space-5);
        font-size: var(--text-sm);
    }
}