.como-funciona {
    position: relative;
    background: url('https://www.arckdantech.com.br/comunidademayday/src/assets/fundo_section_funcionamento.png') no-repeat center center/cover;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 210px 2px 70px 2px;
    color: white;
    text-align: center;
}

.funcionamento-linha-azul {
    height: 20px;
    width: 100%;
    background-color: #00aaff;
}

.como-funciona .container {
    margin: -20px auto;
    position: relative;
}

.como-funciona .cabecalho h2 {
    font-size: 4.5rem;
    font-weight: bold;
    margin-bottom: 10px;
}

    .como-funciona .cabecalho h2 span {
        color: #00aaff;
    }

.como-funciona .cabecalho p {
    font-size: 2.0rem;
    line-height: 1.3;
    max-width: 100%;
    margin: 0 auto 115px auto;
    color: #d0d8e0;
}

.como-funciona .cabecalho strong {
    color: #00aaff;
}

.funcionalidades {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 100px;
    margin-bottom: 30px;
    align-content: center;
}

.item {
    flex: 1 1 200px;
    max-width: 220px;
    text-align: center;
    margin: 10px auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

    .item img {
        height: 100px;
        margin-bottom: 15px;
    }

    .item h3 {
        font-size: 1.6rem;
        line-height: 0.9;
        color: #00aaff;
        font-weight: bold;
        margin-bottom: 10px;
        min-height: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        text-align: center;
    }

    .item p {
        font-size: 0.95rem;
        line-height: 1.3;
        flex-grow: 1;
        display: block;
        text-align: center !important;
        margin-top: auto;
    }

.como-funciona .cabecalho {
    margin-top: -120px;
    margin-bottom: 0px;
}

@media (min-width: 1025px) {

    .como-funciona br {
        display: none;
    }

    br.quebra-fixa {
        display: inline;
    }
}

@media (max-width: 768px) {

    .como-funciona {
        position: relative;
        display: flex;
        align-items: flex-end;
        justify-content: center;
        padding: 205px 2px 80px 2px;
        text-align: center;
    }

    .img-comando-voz {
        width: 99px;
        min-height: 160px;
    }

    .funcionalidades {
        display: flex;
        flex-direction: column;
        align-items: center;
        overflow: hidden;
        gap: 32px;
        width: 100%;
    }

        .funcionalidades .item {
            width: 100%;
            max-width: 320px;
            text-align: center;
        }

    .como-funciona .cabecalho h2 {
        font-size: 2.7rem;
        line-height: 38px;
        padding: 5px;
        margin-bottom: 25px;
    }

    .como-funciona .cabecalho p {
        font-size: 1.3rem;
        line-height: 24px;
        margin-top: -10px;
        margin-bottom: 72px;
    }

    .item h3 {
        min-height: 40px;
        font-size: 1.9rem;
    }
}

/* Tablets landscape (769px–1024px) */
@media (min-width: 769px) and (max-width: 1024px) and (orientation: landscape) {

    .como-funciona br {
        display: none;
    }

    br.quebra-fixa {
        display: inline;
    }

    .funcionalidades {
        flex-wrap: nowrap;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 30px;
    }

    .como-funciona .container {
        margin-top: -40px;
    }

    .item {
        flex: 0 0 180px;
        scroll-snap-align: start;
        max-width: none;
    }

        .item img {
            height: 70px;
            margin-bottom: 15px;
        }

        .item h3 {
            font-size: 1.4rem;
            line-height: 0.9;
            color: #00aaff;
            font-weight: bold;
            margin-bottom: 10px;
            min-height: 48px;
            display: flex;
            align-items: center;
            justify-content: center;
            text-align: center;
        }

        .item p {
            font-size: 0.75rem;
            line-height: 1.1;
            flex-grow: 1;
            display: block;
            text-align: center;
            margin-top: auto;
        }

    .funcionamento-linha-azul {
        height: 20px;
        width: 100%;
        background-color: #00aaff;
    }

    .como-funciona .cabecalho h2 {
        font-size: 4rem;
        line-height: 3.3rem;
        font-weight: bold;
        margin-top: 10px;
        margin-bottom: 20px;
    }

    .como-funciona .cabecalho p {
        font-size: 1.25rem;
        line-height: 1.3;
        max-width: 800px;
        margin: 0 auto 65px auto;
        color: #d0d8e0;
    }

    .img-comando-voz {
        width: 55px;
        min-height: 80px;
        margin-top: -10px;
    }
}

/* Celulares landscape (até 768px) */
@media (max-width: 915px) and (orientation: landscape) {

    .como-funciona {
        padding: 55px 2px 20px 2px;
    }

    .como-funciona .container {
        margin-top: -20px;
        padding-bottom: 10px;
        width: 100%;
        overflow: visible;
    }

    .funcionamento-linha-azul {
        height: 15px;
        width: 100%;
        background-color: #00aaff;
    }

    .como-funciona .cabecalho {
        margin-top: -60px;
        margin-bottom: 0;
    }

    .como-funciona .cabecalho h2 {
        font-size: 2rem;
        line-height: 2rem;
        font-weight: bold;
        margin-top: 5px;
        margin-bottom: 8px;
        text-align: center;
    }

    .como-funciona .cabecalho p {
        font-size: 0.9rem;
        line-height: 1.2;
        max-width: 100%;
        margin: 0 auto 20px auto;
        text-align: center;
    }

    .funcionalidades {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 10px;
        padding: 10px 10px 20px 10px;
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
        align-items: flex-start;
    }

    .item {
        flex: 0 0 130px;
        min-width: 130px;
        scroll-snap-align: start;
        display: flex;
        flex-direction: column;
        padding: 8px;
    }

        .item img {
            height: 45px;
            margin: 0 auto 6px auto;
            display: block;
        }

        .item h3 {
            font-size: 0.85rem;
            line-height: 1.1;
            color: #00aaff;
            font-weight: bold;
            min-height: auto;
            text-align: center;
            justify-content: center;
            padding: 0;
            margin-bottom: 5px;
        }

        .item p {
            font-size: 0.68rem;
            line-height: 1.1;
            text-align: center;
            margin: 0;
            padding: 0;
        }

    .img-comando-voz {
        width: 38px;
        height: auto;
        margin-top: 0;
        margin-bottom: 6px;
    }
}
