/* Home Landing - Minas Mais Indique e Ganhe
   Escopo isolado em .mm-home para evitar conflito com o sistema existente. */

:root {
    --mm-red: #d71920;
    --mm-red-700: #b80e16;
    --mm-red-900: #8f0710;
    --mm-black: #151922;
    --mm-text: #2b313d;
    --mm-muted: #697180;
    --mm-line: #eceff3;
    --mm-white: #ffffff;
    --mm-bg: #f7f8fa;
    --mm-shadow-soft: 0 18px 60px rgba(20, 24, 32, 0.10);
    --mm-shadow-card: 0 12px 36px rgba(20, 24, 32, 0.08);
    --mm-radius-xl: 32px;
    --mm-radius-lg: 24px;
    --mm-radius-md: 18px;
    --mm-container: 1180px;
}

.mm-home,
.mm-home * {
    box-sizing: border-box;
}

.mm-home {
    min-height: 100vh;
    background: var(--mm-bg);
    color: var(--mm-text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    overflow-x: hidden;
}

.mm-home a {
    color: inherit;
    text-decoration: none;
}

.mm-home img,
.mm-home svg {
    display: block;
}

.mm-home__container {
    width: min(var(--mm-container), calc(100% - 40px));
    margin-inline: auto;
}

.mm-home__hero {
    position: relative;
    min-height: 720px;
    background:
        radial-gradient(circle at 74% 34%, rgba(215, 25, 32, .16), transparent 38%),
        linear-gradient(180deg, #fff 0%, #fff7f7 56%, #fff 100%);
    overflow: hidden;
}

.mm-home__hero-bg {
    position: absolute;
    inset: 96px 0 0;
    pointer-events: none;
}

.mm-home__hero-bg img {
    position: absolute;
    top: 0;
    right: max(0px, calc((100vw - var(--mm-container)) / 2 - 24px));
    width: min(780px, 58vw);
    height: 590px;
    object-fit: cover;
    object-position: right center;
    opacity: .98;
    filter: saturate(1.04);
}

.mm-home__hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, #fff 0%, rgba(255,255,255,.95) 34%, rgba(255,255,255,.35) 62%, rgba(255,255,255,.05) 100%);
    pointer-events: none;
    z-index: 1;
}

.mm-home__hero-inner {
    position: relative;
    z-index: 2;
}

.mm-home__header {
    height: 96px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.mm-home__brand img {
    width: min(260px, 52vw);
    height: auto;
    object-fit: contain;
}

.mm-home__nav {
    display: flex;
    align-items: center;
    gap: 18px;
}

.mm-home__nav-link {
    font-weight: 700;
    color: var(--mm-text);
    transition: color .2s ease, transform .2s ease;
}

.mm-home__nav-link:hover,
.mm-home__nav-link:focus-visible {
    color: var(--mm-red);
    transform: translateY(-1px);
}

.mm-home__nav-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 26px;
    border-radius: 14px;
    color: #FFFFFF !important;
    background: linear-gradient(135deg, var(--mm-red), #ef111c);
    font-weight: 800;
    box-shadow: 0 12px 26px rgba(215, 25, 32, .28);
    transition: transform .2s ease, box-shadow .2s ease;
}

.mm-home__nav-button:hover,
.mm-home__nav-button:focus-visible {
    transform: translateY(-2px);
    box-shadow: 0 18px 34px rgba(215, 25, 32, .36);
}

.mm-home__hero-content {
    width: min(520px, 100%);
    padding-top: 72px;
}

.mm-home__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 18px;
    border-radius: 999px;
    background: rgba(255,255,255,.92);
    box-shadow: 0 10px 28px rgba(20, 24, 32, .09);
    font-weight: 850;
    text-transform: uppercase;
    letter-spacing: .02em;
    color: var(--mm-black);
    margin-bottom: 30px;
}

.mm-home__eyebrow strong {
    color: var(--mm-red);
}

.mm-home__title {
    margin: 0;
    color: var(--mm-black);
    font-size: clamp(3.15rem, 5.3vw, 5.25rem);
    line-height: .98;
    letter-spacing: -.055em;
    font-weight: 900;
}

.mm-home__title span {
    color: var(--mm-red);
}

.mm-home__lead {
    width: min(450px, 100%);
    margin: 26px 0 32px;
    font-size: clamp(1.08rem, 1.8vw, 1.35rem);
    line-height: 1.55;
    color: #333946;
}

.mm-home__lead strong {
    color: var(--mm-red);
}

.mm-home__actions {
    display: grid;
    width: min(460px, 100%);
    gap: 16px;
}

.mm-home__btn {
    min-height: 64px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    font-size: 1.08rem;
    font-weight: 900;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.mm-home__btn svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.mm-home__btn--primary {
    color: #FFFFFF !important;
    background: linear-gradient(135deg, var(--mm-red), #ec111b);
    box-shadow: 0 16px 32px rgba(215, 25, 32, .32);
}

/* CTAs vermelhos: texto/ícones brancos (vence .mm-home a { color: inherit }) */
.mm-home__nav-button *,
.mm-home__btn--primary *,
.mm-home button *,
.mm-home .btn--primary *,
.mm-home .home-hero__primary *,
.mm-home .home-header__signup *,
.mm-home .home-auth__panel *,
.mm-home .home-cta * {
    color: #FFFFFF !important;
}

.mm-home__nav-button svg,
.mm-home__btn--primary svg,
.mm-home .btn--primary svg,
.mm-home .home-hero__primary svg,
.mm-home .home-header__signup svg,
.mm-home .home-auth__panel svg,
.mm-home .home-cta svg {
    stroke: currentColor;
    fill: currentColor;
}

.mm-home__btn--outline {
    color: var(--mm-red);
    border: 2px solid var(--mm-red);
    background: rgba(255,255,255,.72);
}

.mm-home__btn:hover,
.mm-home__btn:focus-visible {
    transform: translateY(-3px);
}

.mm-home__btn--primary:hover,
.mm-home__btn--primary:focus-visible {
    box-shadow: 0 22px 44px rgba(215, 25, 32, .38);
}

.mm-home__btn--outline:hover,
.mm-home__btn--outline:focus-visible {
    background: #fff5f5;
}

.mm-home__summary {
    position: absolute;
    z-index: 3;
    right: 0;
    bottom: 42px;
    width: min(640px, 52vw);
}

.mm-home__summary-card {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    background: rgba(255,255,255,.92);
    border: 1px solid rgba(255,255,255,.75);
    border-radius: 24px 24px 0 0;
    box-shadow: var(--mm-shadow-soft);
    backdrop-filter: blur(10px);
    overflow: hidden;
}

.mm-home__summary-item {
    position: relative;
    min-height: 156px;
    display: grid;
    place-items: center;
    align-content: center;
    text-align: center;
    padding: 20px 18px;
    gap: 14px;
}

.mm-home__summary-item + .mm-home__summary-item::before {
    content: "";
    position: absolute;
    left: 0;
    top: 34px;
    bottom: 34px;
    width: 1px;
    background: #e5e7ec;
}

.mm-home__summary-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: var(--mm-red);
    background: linear-gradient(180deg, #fff, #fff4f4);
    box-shadow: inset 0 0 0 1px #ffd7d7, 0 12px 22px rgba(215,25,32,.13);
}

.mm-home__summary-icon svg {
    width: 34px;
    height: 34px;
    fill: currentColor;
}

.mm-home__summary-item strong {
    font-size: 1.02rem;
    line-height: 1.25;
    color: var(--mm-black);
}

.mm-home__summary-ribbon {
    min-height: 62px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    padding: 14px 24px;
    color: #fff;
    font-size: 1.28rem;
    border-radius: 0 0 18px 18px;
    background: linear-gradient(135deg, var(--mm-red), #a90811);
    box-shadow: 0 16px 32px rgba(215,25,32,.28);
}

.mm-home__summary-ribbon span {
    font-size: 1.7rem;
}

.mm-home__steps {
    padding: 72px 0 48px;
    background: #fff;
}

.mm-home__section-head {
    text-align: center;
    margin-bottom: 52px;
}

.mm-home__section-head span {
    display: inline-block;
    color: var(--mm-red);
    font-size: .9rem;
    text-transform: uppercase;
    font-weight: 900;
    letter-spacing: .06em;
    margin-bottom: 8px;
}

.mm-home__section-head h2 {
    margin: 0;
    color: var(--mm-black);
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1.06;
    letter-spacing: -.04em;
}

.mm-home__section-head h2 strong {
    color: var(--mm-red);
}

.mm-home__steps-grid {
    position: relative;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 28px;
}

.mm-home__steps-grid::before {
    content: "";
    position: absolute;
    top: 51px;
    left: 13%;
    right: 13%;
    height: 2px;
    background-image: linear-gradient(90deg, #e3e6ec 50%, transparent 0);
    background-size: 18px 2px;
}

.mm-home__step {
    position: relative;
    text-align: center;
    z-index: 2;
}

.mm-home__step-icon {
    width: 104px;
    height: 104px;
    margin: 0 auto 20px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: var(--mm-red);
    background: linear-gradient(180deg, #fff, #fafafa);
    box-shadow: inset 0 0 0 1px #f0f1f4, 0 18px 38px rgba(20,24,32,.08);
}

.mm-home__step-icon svg {
    width: 44px;
    height: 44px;
    fill: currentColor;
}

.mm-home__step-number {
    display: inline-grid;
    place-items: center;
    width: 30px;
    height: 30px;
    margin-right: 8px;
    border-radius: 9px;
    color: #fff;
    background: var(--mm-red);
    font-weight: 900;
    box-shadow: 0 8px 18px rgba(215,25,32,.24);
}

.mm-home__step h3 {
    display: inline;
    color: var(--mm-black);
    font-size: 1.08rem;
    font-weight: 900;
}

.mm-home__step p {
    margin: 14px auto 0;
    max-width: 230px;
    color: #3d4450;
    line-height: 1.45;
}

.mm-home__app-banner {
    padding: 32px 0 42px;
    background: #fff;
}

.mm-home__app-card {
    position: relative;
    min-height: 380px;
    border-radius: 26px;
    overflow: hidden;
    background: linear-gradient(135deg, #d71920, #9d0710);
    box-shadow: var(--mm-shadow-soft);
}

.mm-home__app-card > img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: right center;
}

.mm-home__app-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(151,0,10,.94) 0%, rgba(191,7,17,.80) 34%, rgba(191,7,17,.14) 64%, rgba(191,7,17,0) 100%);
}

.mm-home__app-text {
    position: relative;
    z-index: 2;
    width: min(520px, 78%);
    padding: 62px 64px;
    color: #fff;
}

.mm-home__app-text span {
    display: block;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .04em;
    margin-bottom: 16px;
}

.mm-home__app-text h2 {
    margin: 0;
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: .98;
    letter-spacing: -.055em;
}

.mm-home__app-text h2 strong {
    color: #ffe268;
}

.mm-home__app-text p {
    max-width: 430px;
    margin: 24px 0 0;
    font-size: 1.25rem;
    line-height: 1.45;
}

.mm-home__trust {
    padding: 8px 0 56px;
    background: #fff;
}

.mm-home__trust-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: rgba(255,255,255,.92);
    border: 1px solid #edf0f4;
    border-radius: 24px;
    box-shadow: 0 14px 38px rgba(20,24,32,.07);
    overflow: hidden;
}

.mm-home__trust-grid article {
    min-height: 104px;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 22px 24px;
}

.mm-home__trust-grid article + article {
    border-left: 1px solid #edf0f4;
}

.mm-home__trust-grid svg {
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    fill: var(--mm-red);
}

.mm-home__trust-grid strong {
    display: block;
    color: var(--mm-black);
    font-weight: 900;
    margin-bottom: 2px;
}

.mm-home__trust-grid span {
    color: var(--mm-muted);
    font-size: .95rem;
}

.mm-home__footer {
    color: #fff;
    background: linear-gradient(135deg, var(--mm-red-700), var(--mm-red-900));
    padding: 34px 0;
}

.mm-home__footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
}

.mm-home__footer img {
    width: 190px;
    height: auto;
    filter: brightness(0) invert(1);
}

.mm-home__footer p {
    margin: 0;
    font-weight: 700;
}

.mm-home__footer span {
    opacity: .9;
}

/* Animations */
.mm-home [data-mm-animate],
.mm-home__hero-content,
.mm-home__summary,
.mm-home__step,
.mm-home__app-card,
.mm-home__trust-grid {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity .65s ease, transform .65s ease;
}

.mm-home .is-visible,
.mm-home__hero-content.is-visible,
.mm-home__summary.is-visible,
.mm-home__step.is-visible,
.mm-home__app-card.is-visible,
.mm-home__trust-grid.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 1100px) {
    .mm-home__hero {
        min-height: auto;
        padding-bottom: 44px;
    }

    .mm-home__hero-bg img {
        width: 64vw;
        height: 540px;
        opacity: .82;
    }

    .mm-home__summary {
        position: relative;
        right: auto;
        bottom: auto;
        width: 100%;
        margin-top: 44px;
    }

    .mm-home__hero-content {
        padding-top: 42px;
    }
}

@media (max-width: 860px) {
    .mm-home__container {
        width: min(100% - 28px, 720px);
    }

    .mm-home__hero-bg {
        inset: 82px 0 auto;
        height: 420px;
    }

    .mm-home__hero-bg img {
        right: -26vw;
        width: 105vw;
        height: 410px;
        opacity: .55;
        object-position: right top;
    }

    .mm-home__hero::before {
        background:
            linear-gradient(180deg, rgba(255,255,255,.96) 0%, rgba(255,255,255,.88) 40%, rgba(255,255,255,.96) 100%),
            linear-gradient(90deg, #fff 0%, rgba(255,255,255,.6) 100%);
    }

    .mm-home__header {
        height: 86px;
    }

    .mm-home__brand img {
        width: min(215px, 50vw);
    }

    .mm-home__nav {
        gap: 10px;
    }

    .mm-home__nav-link {
        font-size: .95rem;
    }

    .mm-home__nav-button {
        min-height: 44px;
        padding: 0 18px;
        border-radius: 13px;
    }

    .mm-home__title {
        font-size: clamp(2.75rem, 12vw, 4.3rem);
    }

    .mm-home__summary-card {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .mm-home__summary-item {
        min-height: 136px;
        padding: 18px 10px;
    }

    .mm-home__summary-icon {
        width: 62px;
        height: 62px;
    }

    .mm-home__summary-icon svg {
        width: 30px;
        height: 30px;
    }

    .mm-home__summary-ribbon {
        font-size: 1.05rem;
        gap: 12px;
        text-align: center;
    }

    .mm-home__steps {
        padding-top: 56px;
    }

    .mm-home__steps-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 12px;
    }

    .mm-home__steps-grid::before {
        left: 10%;
        right: 10%;
        top: 43px;
    }

    .mm-home__step-icon {
        width: 86px;
        height: 86px;
    }

    .mm-home__step-icon svg {
        width: 38px;
        height: 38px;
    }

    .mm-home__step-number {
        display: grid;
        margin: 0 auto 8px;
    }

    .mm-home__step h3 {
        display: block;
        font-size: .95rem;
        line-height: 1.22;
    }

    .mm-home__step p {
        display: none;
    }

    .mm-home__app-card {
        min-height: 440px;
    }

    .mm-home__app-card > img {
        object-position: center bottom;
        opacity: .82;
    }

    .mm-home__app-card::before {
        background: linear-gradient(180deg, rgba(174,7,16,.96) 0%, rgba(174,7,16,.65) 42%, rgba(174,7,16,.06) 100%);
    }

    .mm-home__app-text {
        width: 100%;
        padding: 36px 30px;
    }

    .mm-home__app-text h2 {
        font-size: clamp(2.35rem, 10vw, 3.25rem);
    }

    .mm-home__app-text p {
        width: min(320px, 100%);
        font-size: 1.08rem;
    }

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

    .mm-home__trust-grid article:nth-child(odd) {
        border-left: 0;
    }

    .mm-home__trust-grid article:nth-child(n+3) {
        border-top: 1px solid #edf0f4;
    }

    .mm-home__footer-inner {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 520px) {
    .mm-home__container {
        width: min(100% - 24px, 480px);
    }

    .mm-home__header {
        height: 76px;
    }

    .mm-home__brand img {
        width: 172px;
    }

    .mm-home__nav-link {
        font-size: .88rem;
    }

    .mm-home__nav-button {
        min-height: 40px;
        padding: 0 14px;
        font-size: .9rem;
    }

    .mm-home__hero-content {
        padding-top: 28px;
    }

    .mm-home__eyebrow {
        padding: 10px 14px;
        font-size: .78rem;
    }

    .mm-home__lead {
        font-size: 1rem;
        margin: 22px 0 26px;
    }

    .mm-home__btn {
        min-height: 58px;
        border-radius: 15px;
        font-size: 1rem;
    }

    .mm-home__summary-card {
        border-radius: 20px 20px 0 0;
    }

    .mm-home__summary-item {
        min-height: 122px;
    }

    .mm-home__summary-icon {
        width: 54px;
        height: 54px;
    }

    .mm-home__summary-item strong {
        font-size: .87rem;
    }

    .mm-home__summary-ribbon {
        min-height: 56px;
        font-size: .98rem;
        border-radius: 0 0 16px 16px;
    }

    .mm-home__section-head {
        margin-bottom: 38px;
    }

    .mm-home__steps-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 7px;
    }

    .mm-home__steps-grid::before {
        top: 35px;
    }

    .mm-home__step-icon {
        width: 70px;
        height: 70px;
        margin-bottom: 12px;
    }

    .mm-home__step-icon svg {
        width: 31px;
        height: 31px;
    }

    .mm-home__step-number {
        width: 26px;
        height: 26px;
        border-radius: 8px;
        font-size: .85rem;
    }

    .mm-home__step h3 {
        font-size: .8rem;
    }

    .mm-home__app-card {
        min-height: 420px;
        border-radius: 22px;
    }

    .mm-home__app-text {
        padding: 30px 24px;
    }

    .mm-home__trust-grid article {
        flex-direction: column;
        text-align: center;
        gap: 10px;
        padding: 20px 12px;
    }
}

@media (max-width: 768px) {
    /* Padding lateral uniforme no conteúdo (não no header nem no footer) */
    .mm-home__hero-content,
    .mm-home__summary {
        padding-left: 16px;
        padding-right: 16px;
        box-sizing: border-box;
        width: 100%;
        max-width: 100%;
    }

    .mm-home__steps > .mm-home__container,
    .mm-home__app-banner > .mm-home__container,
    .mm-home__trust > .mm-home__container {
        width: 100%;
        max-width: 100%;
        padding-left: 16px;
        padding-right: 16px;
        box-sizing: border-box;
    }

    .mm-home__actions,
    .mm-home__btn {
        width: 100%;
    }

    /* Banner 1 — imagem mobile inteira, sem corte */
    .mm-home__hero {
        display: grid;
        grid-template-areas:
            "header"
            "banner"
            "content"
            "summary";
        min-height: 0;
        padding-bottom: 0;
        overflow: visible;
    }

    .mm-home__hero-inner {
        display: contents;
    }

    .mm-home__header {
        grid-area: header;
    }

    .mm-home__hero-bg {
        grid-area: banner;
        position: relative;
        inset: auto;
        width: 100%;
        height: auto;
        margin: 0;
        padding: 0 12px;
        box-sizing: border-box;
        overflow: visible;
        background-image: url('../images/banner1mobile.webp');
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
    }

    .mm-home__hero-bg::before {
        content: url('../images/banner1mobile.webp');
        display: block;
        width: 100%;
        height: auto;
        visibility: hidden;
        pointer-events: none;
    }

    .mm-home__hero-bg img {
        display: none;
    }

    .mm-home__hero::before {
        content: none;
        display: none;
    }

    .mm-home__hero-content {
        grid-area: content;
    }

    .mm-home__summary {
        grid-area: summary;
    }

    /* Banner 2 — imagem mobile inteira, sem corte */
    .mm-home__app-banner {
        padding-top: 24px;
        padding-bottom: 32px;
    }

    .mm-home__app-card {
        min-height: 0;
        display: flex;
        flex-direction: column;
    }

    .mm-home__app-card::before {
        display: none;
    }

    .mm-home__app-card > img {
        content: url('../images/banner2mobile.webp');
        display: block;
        position: relative;
        inset: auto;
        width: calc(100% - 24px);
        height: auto;
        margin: 0 auto;
        object-fit: contain;
        object-position: center;
        opacity: 1;
        order: -1;
    }
}

/* Integração com layout public (Sprint 4.0) */
.page--public:has(.mm-home) .mm-header,
.page--public:has(.mm-home) .footer--public {
    display: none;
}

.page--public:has(.mm-home) .main {
    padding: 0;
}

.page--public:has(.mm-home) .container.page-content {
    width: 100%;
    max-width: none;
    padding: 0;
    margin: 0;
}
