

/* ==========================================================================
   АДАПТИВНОСТЬ — только layout и бургер-меню
   ========================================================================== */

/* === TABLET (max-width: 1024px) === */
@media (max-width: 1024px) {
    .hero__inner,
    .about__inner {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
        text-align: center;
    }

    .hero__image {
        order: -1;
        max-width: 450px;
        margin: 0 auto;
    }

    .hero__title,
    .hero__text {
        text-align: center;
        margin-left: auto;
        margin-right: auto;
    }

    .hero__buttons {
        justify-content: center;
    }

    .hero__stats {
        justify-content: center;
    }

    .contacts__inner {
        grid-template-columns: 1fr;
    }

    .contact-info,
    .contact-form {
        max-width: 600px;
        margin: 0 auto;
        width: 100%;
    }
}

/* === MOBILE (max-width: 768px) === */
@media (max-width: 768px) {
    html {
        font-size: 15px;
    }

    /* --- Burger Menu --- */
    .burger {
        display: flex;
    }

    .menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: min(320px, 85vw);
        height: 100dvh;
        background: var(--white);
        box-shadow: -10px 0 40px rgba(0,0,0,0.2);
        padding: 5rem var(--space-md) var(--space-md);
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: calc(var(--z-sticky) + 1);
        overflow-y: auto;
        display: block;
    }

    .menu.active {
        right: 0;
    }

    .menu__list {
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
    }

    .menu__item {
        width: 100%;
        border-bottom: 1px solid rgba(139, 92, 246, 0.1);
    }

    .menu__link {
        display: block;
        padding: var(--space-md) 0;
        font-size: var(--font-lg);
        width: 100%;
    }

    .menu__link::after {
        display: none;
    }

    /* Hide phone in header on mobile */
    .header__phone {
        display: none;
    }

    /* Profile in mobile menu */
    .header__profile {
        margin-left: auto;
    }

    .profile-link span {
        display: none;
    }

    .profile-link {
        padding: var(--space-sm);
        min-width: 44px;
        min-height: 44px;
        justify-content: center;
    }

    /* --- Hero --- */
    .hero {
        min-height: auto;
        padding-top: 70px;
    }

    .hero__inner {
        padding: var(--space-lg) 0;
    }

    .hero__title {
        font-size: clamp(1.8rem, 6vw, 2.5rem);
    }

    .hero__stats {
        flex-wrap: wrap;
        gap: var(--space-md);
    }

    .stat {
        flex: 1;
        min-width: 80px;
    }

    .stat-number {
        font-size: clamp(1.5rem, 4vw, 2rem);
    }

    /* --- Services --- */
    .services__grid {
        grid-template-columns: 1fr;
        max-width: 400px;
        margin: 0 auto;
    }

    .service-card {
        min-height: auto;
        padding: var(--space-lg);
    }

    .service-card__icon {
        width: 70px;
        height: 70px;
    }

    .service-card__icon i {
        font-size: 2rem;
    }

    /* --- Portfolio --- */
    .portfolio-card {
        height: 280px;
    }

    /* --- About --- */
    .about__features li:hover {
        transform: translateX(5px);
    }

    /* --- Contacts --- */
    .form-row {
        grid-template-columns: 1fr;
    }

    /* --- Footer --- */
    .footer__inner {
        flex-direction: column;
        text-align: center;
    }
}

/* === SMALL MOBILE (max-width: 480px) === */
@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    .container {
        padding: 0 var(--space-sm);
    }

    .hero__title {
        font-size: 1.8rem;
    }

    .hero__buttons {
        flex-direction: column;
        width: 100%;
    }

    .btn {
        width: 100%;
        padding: var(--space-md) var(--space-lg);
    }

    .section-title {
        font-size: 1.8rem;
    }

    .portfolio-card {
        height: 240px;
    }

    .contact-info,
    .contact-form {
        padding: var(--space-lg);
    }

    .image-container {
        max-height: 350px;
    }

    .portfolio-overlay {
        padding: var(--space-lg) var(--space-md) var(--space-md);
    }

    .portfolio-overlay h4 {
        font-size: 1.1rem;
    }

    .portfolio-link {
        padding: var(--space-sm) var(--space-md);
        font-size: 0.8rem;
    }
}

/* === EXTRA SMALL (max-width: 360px) === */
@media (max-width: 360px) {
    .hero__title {
        font-size: 1.5rem;
    }

    .stat-number {
        font-size: 1.5rem;
    }

    .service-card {
        padding: var(--space-md);
    }

    .portfolio-card {
        height: 200px;
    }

    .about__features li {
        padding: var(--space-sm);
        font-size: 0.9rem;
    }
}

/* === LANDSCAPE MOBILE === */
@media (max-height: 500px) and (orientation: landscape) and (max-width: 768px) {
    .hero {
        min-height: auto;
        padding: 5rem 0 2rem;
    }

    .hero__inner {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-lg);
        text-align: left;
    }

    .hero__image {
        order: 0;
        max-width: none;
    }

    .hero__title {
        font-size: var(--font-xl);
    }

    .hero__buttons {
        flex-direction: row;
        width: auto;
    }

    .btn {
        width: auto;
    }

    .menu {
        padding-top: 4rem;
    }
}