/* ================================================================
   PATCH 23 — MOBILE FIRST / HOME + CABECALHO PUBLICO
   Corrige excesso de altura no menu e simplifica o hero em celulares.
   ================================================================ */

@media (max-width: 720px) {
    html,
    body {
        overflow-x: hidden;
    }

    .site-header {
        position: sticky;
        top: 0;
        z-index: 50;
        background: rgba(250,252,248,.98);
        backdrop-filter: blur(14px);
    }

    .header-inner {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 8px !important;
        min-height: 0 !important;
        padding: 10px 0 8px !important;
    }

    .brand {
        display: inline-flex;
        align-self: flex-start;
        line-height: 0;
    }

    .brand img {
        width: 126px !important;
        max-width: 126px !important;
        height: auto !important;
    }

    .header-nav {
        display: flex !important;
        width: 100% !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        gap: 6px !important;
        margin: 0 !important;
        padding: 0 0 2px !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        overscroll-behavior-x: contain;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .header-nav::-webkit-scrollbar {
        display: none;
    }

    .header-nav a,
    .header-nav .header-admin-link {
        display: inline-flex !important;
        flex: 0 0 auto !important;
        min-height: 32px !important;
        padding: 7px 10px !important;
        border-radius: 999px !important;
        font-size: 11px !important;
        line-height: 1 !important;
        white-space: nowrap !important;
    }

    .header-nav .header-admin-link {
        padding-inline: 12px !important;
    }

    .home-hero-v3 {
        padding: 22px 0 30px !important;
    }

    .home-hero-v3-grid {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 18px !important;
        min-height: 0 !important;
    }

    .home-hero-v3-copy {
        order: 1;
        max-width: none !important;
    }

    .home-hero-v3-copy h1 {
        max-width: none !important;
        margin: 10px 0 9px !important;
        font-size: clamp(2.2rem, 11.5vw, 3.05rem) !important;
        line-height: .94 !important;
        letter-spacing: -.055em !important;
    }

    .home-hero-v3-copy > p {
        max-width: 36rem !important;
        font-size: .92rem !important;
        line-height: 1.48 !important;
    }

    .home-hero-v3 .home-hero-actions {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 9px !important;
        margin-top: 16px !important;
    }

    .home-hero-v3 .home-hero-actions .button {
        width: 100% !important;
        min-height: 41px !important;
        padding: 9px 11px !important;
        font-size: .78rem !important;
        text-align: center;
    }

    .home-hero-visual {
        order: 2;
        min-height: 0 !important;
        width: 100% !important;
    }

    .home-hero-visual-stack {
        position: relative !important;
        width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        margin: 0 !important;
    }

    /* No celular, usa somente uma arte em destaque. A colagem fica para telas maiores. */
    .home-hero-visual-card {
        display: none !important;
    }

    .home-hero-visual-card:first-child,
    .home-hero-visual-card:only-child {
        position: relative !important;
        inset: auto !important;
        display: block !important;
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 16 / 9 !important;
        transform: none !important;
        border: 3px solid rgba(255,255,255,.98) !important;
        border-radius: 18px !important;
        box-shadow: 0 14px 34px rgba(7,19,27,.14) !important;
    }

    .home-hero-visual-card:first-child img,
    .home-hero-visual-card:only-child img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
    }

    .home-hero-trustbar {
        position: static !important;
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        width: 100% !important;
        min-height: 0 !important;
        margin-top: 10px !important;
        padding: 9px 8px !important;
        gap: 4px !important;
        border-radius: 15px !important;
        transform: none !important;
        box-shadow: 0 8px 22px rgba(7,19,27,.08) !important;
    }

    .home-hero-trustbar span {
        display: inline-flex !important;
        justify-content: center !important;
        gap: 4px !important;
        font-size: .61rem !important;
        white-space: nowrap !important;
    }

    .home-hero-trustbar svg {
        width: 13px !important;
        height: 13px !important;
    }

    .home-search-section {
        padding: 0 0 2px;
    }

    .home-search-form {
        min-height: 50px !important;
        margin-top: -10px !important;
        padding: 5px 6px 5px 13px !important;
    }

    .home-search-form input[type="search"] {
        min-height: 38px !important;
        font-size: .82rem !important;
    }

    .home-search-form button {
        flex-basis: 39px !important;
        width: 39px !important;
        height: 39px !important;
    }

    .home-events-v3 {
        padding-top: 24px !important;
    }

    .home-category-pills {
        margin-bottom: 13px !important;
    }

    .home-product-rail {
        gap: 12px !important;
    }

    .home-promoter-strip {
        margin-top: 16px !important;
    }
}

@media (max-width: 390px) {
    .brand img {
        width: 116px !important;
        max-width: 116px !important;
    }

    .header-nav a,
    .header-nav .header-admin-link {
        font-size: 10.5px !important;
        padding: 7px 9px !important;
    }

    .home-hero-v3 .home-hero-actions {
        grid-template-columns: 1fr !important;
    }

    .home-hero-trustbar span {
        font-size: .56rem !important;
    }
}
