/* ===== SEÇÃO O QUE FAZEMOS ===== */
.oqf {
    width: 100%;
    height: 100vh;
    background: #00010D;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    position: relative;
}

/* ===== HEADER ===== */
.oqf__header {
    padding: 4vh 0 2vh 8vw;
    flex-shrink: 0;
}

.oqf__header--fixed {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 2vh 8vw;
    background: rgba(0, 1, 13, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(93, 220, 255, 0.1);
    z-index: 100;
}

.oqf__title {
    font-size: clamp(1rem, 2.5vw, 2rem);
    font-weight: 700;
    color: #FFF;
    text-transform: uppercase;
    letter-spacing: 6px;
    line-height: 1;
}

    .oqf__title span {
        color: #F2561D;
    }

/* ===== TRACK (DESKTOP) ===== */
.oqf__track {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 4vw;
    padding-left: calc(50vw - 310px);
    padding-right: calc(50vw - 310px);
    flex-shrink: 0;
    will-change: transform;
    transition: transform 0.7s cubic-bezier(.16,1,.3,1);
    overflow: visible;
    height: 100%;
}

/* ===== MOBILE GRID (HIDDEN NO DESKTOP) ===== */
.oqf__mobile-grid {
    display: none;
    flex-direction: column;
    gap: 0;
    padding: 0;
    overflow-y: auto;
    height: 100%;
    width: 100%;
}

/* ===== CARD WRAPPER ===== */
.oqf__card-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
    perspective: 1200px;
}

    /* ===== ESCADA — espaçamento vertical (DESKTOP ONLY) ===== */
    .oqf__card-wrapper[data-index="0"] {
        margin-top: 0;
    }

    .oqf__card-wrapper[data-index="1"] {
        margin-top: 180px;
    }

    .oqf__card-wrapper[data-index="2"] {
        margin-top: 360px;
    }

    .oqf__card-wrapper[data-index="3"] {
        margin-top: 540px;
    }

    .oqf__card-wrapper[data-index="4"] {
        margin-top: 720px;
    }

/* ===== CARD ===== */
.oqf__card {
    width: 620px;
    height: 360px;
    transform-style: preserve-3d;
    transition: transform 0.7s cubic-bezier(.16,1,.3,1);
    cursor: pointer;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6), 0 0 0 1px rgba(93,220,255,0.08);
    -webkit-box-reflect: below 2px linear-gradient(transparent 65%, rgba(93,220,255,0.06));
    position: relative;
}

/* ===== FRENTE / VERSO ===== */
.oqf__front,
.oqf__back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.7s cubic-bezier(.16,1,.3,1);
}

/* garante frente limpa no estado inicial */
.oqf__front {
    transform: rotateY(0deg);
    z-index: 2;
}

    /* ===== FRENTE ===== */
    .oqf__front img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        filter: none;
        opacity: 1;
    }

    .oqf__front::after {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 55%;
        height: 100%;
        background: linear-gradient(105deg, transparent 20%, rgba(255,255,255,0.07) 50%, transparent 80%);
        transform: skewX(-15deg);
        transition: left 0.5s cubic-bezier(.16,1,.3,1);
        pointer-events: none;
    }

.oqf__card:hover .oqf__front::after {
    left: 160%;
}

/* ===== VERSO REDESENHADO ===== */
.oqf__back {
    transform: rotateY(180deg);
    background: #00010D;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0;
    position: relative;
    overflow: hidden;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    z-index: 1;
}

/* ===== IMAGEM DE FUNDO ===== */
.oqf__back-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 1;
}

/* ===== OVERLAY ESCURO ===== */
.oqf__back-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 1, 13, 0.85) 0%, rgba(0, 1, 13, 0.75) 50%, rgba(0, 1, 13, 0.85) 100%);
    z-index: 2;
    backdrop-filter: blur(2px);
    opacity: 1;
    transition: opacity 0.35s ease;
}

/* ===== CONTEÚDO DO VERSO ===== */
.oqf__back-content {
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 2rem;
    text-align: center;
    width: 100%;
    height: 100%;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.35s ease, transform 0.35s ease;
}

/* Flip robusto: gira as faces (evita inconsistências ao girar o card inteiro) */
.oqf__card:hover .oqf__front {
    transform: rotateY(-180deg);
}

.oqf__card:hover .oqf__back {
    transform: rotateY(0deg);
}

/* ===== ÍCONE ===== */
.oqf__back-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #5ddcff;
    border-radius: 50%;
    color: #5ddcff;
    animation: iconFloat 3s ease-in-out infinite;
}

    .oqf__back-icon svg {
        width: 32px;
        height: 32px;
        stroke-linecap: round;
        stroke-linejoin: round;
    }

@keyframes iconFloat {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-8px);
    }
}

/* ===== TÍTULO DO VERSO ===== */
.oqf__back-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #FFF;
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1.2;
    margin: 0;
}

/* ===== DESCRIÇÃO ===== */
.oqf__back-description {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.6;
    margin: 0;
    max-width: 280px;
}

/* ===== CTA BUTTON ===== */
.oqf__back-cta {
    margin-top: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 2rem;
    background: linear-gradient(135deg, #5ddcff 0%, #F2561D 100%);
    color: #FFF;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(.16,1,.3,1);
    box-shadow: 0 8px 20px rgba(93, 220, 255, 0.3);
}

    .oqf__back-cta:hover {
        transform: translateY(-2px) scale(1.05);
        box-shadow: 0 12px 30px rgba(93, 220, 255, 0.5);
    }

/* ===== CLASSES ANTIGAS (DESKTOP) ===== */
.oqf__number {
    font-size: 6rem;
    font-weight: 900;
    color: rgba(93,220,255,0.08);
    position: absolute;
    top: 0.5rem;
    right: 1rem;
    line-height: 1;
    user-select: none;
}

.oqf__service-title {
    color: #FFF;
    font-size: 1.4rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: -0.5px;
    margin-bottom: 0.6rem;
    position: relative;
    z-index: 1;
}

.oqf__description {
    color: rgba(255,255,255,0.55);
    font-size: 0.85rem;
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

/* ===== LABEL (título sob o card — desktop) ===== */
.oqf__label {
    position: relative;
    margin-top: 1.25rem;
    padding: 0.55rem 1.35rem;
    min-width: min(100%, 280px);
    text-align: center;
    font-family: 'Syncopate', sans-serif;
    font-size: clamp(0.62rem, 0.85vw, 0.78rem);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.22em;
    line-height: 1.35;
    color: rgba(255, 255, 255, 0.95);
    background:
        linear-gradient(145deg, rgba(93, 220, 255, 0.12) 0%, rgba(0, 1, 13, 0.65) 45%, rgba(242, 86, 29, 0.08) 100%);
    border: 1px solid rgba(93, 220, 255, 0.35);
    border-radius: 999px;
    box-shadow:
        0 10px 28px rgba(0, 0, 0, 0.45),
        0 0 0 1px rgba(255, 255, 255, 0.04) inset,
        0 0 24px rgba(93, 220, 255, 0.08);
    text-shadow: 0 0 20px rgba(93, 220, 255, 0.25);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition:
        color 0.35s cubic-bezier(.16, 1, .3, 1),
        border-color 0.35s cubic-bezier(.16, 1, .3, 1),
        box-shadow 0.35s cubic-bezier(.16, 1, .3, 1),
        transform 0.35s cubic-bezier(.16, 1, .3, 1),
        text-shadow 0.35s ease;
}

    /* traço em gradiente (mesma linguagem do restante do site) */
    .oqf__label::before {
        content: "";
        position: absolute;
        left: 50%;
        top: 0;
        transform: translate(-50%, -55%);
        width: 42%;
        max-width: 120px;
        height: 2px;
        border-radius: 999px;
        background: linear-gradient(90deg, transparent, rgba(93, 220, 255, 0.85), rgba(242, 86, 29, 0.75), transparent);
        opacity: 0.9;
        pointer-events: none;
    }

.oqf__card-wrapper:hover .oqf__label {
    color: #fff;
    border-color: rgba(242, 86, 29, 0.55);
    text-shadow: 0 0 22px rgba(242, 86, 29, 0.35);
    box-shadow:
        0 14px 36px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(242, 86, 29, 0.2) inset,
        0 0 32px rgba(242, 86, 29, 0.15);
    transform: translateY(-2px);
}

/* ===== EFEITO DURANTE SCROLL ===== */
.oqf--scrolling .oqf__card {
    transform: rotate(-0.5deg) translateY(3px);
    transition: transform 0.5s ease;
}

/* ===== RESPONSIVO ===== */

/* TABLET (769px - 1024px) */
@media (max-width: 1024px) {
    .oqf {
        height: auto;
        min-height: 100vh;
    }

    .oqf__header {
        padding: 3vh 0 1.5vh 5vw;
    }

    .oqf__title {
        font-size: clamp(0.9rem, 2vw, 1.5rem);
    }

    .oqf__track {
        padding-left: calc(50vw - 250px);
        padding-right: calc(50vw - 250px);
        gap: 2vw;
    }

    .oqf__card {
        width: 500px;
        height: 300px;
    }

    .oqf__card-wrapper[data-index="1"] {
        margin-top: 140px;
    }

    .oqf__card-wrapper[data-index="2"] {
        margin-top: 280px;
    }

    .oqf__card-wrapper[data-index="3"] {
        margin-top: 420px;
    }

    .oqf__card-wrapper[data-index="4"] {
        margin-top: 560px;
    }
}

/* MOBILE (até 768px) — LAYOUT VERTICAL COM TITULO LATERAL */
@media (max-width: 768px) {
    .oqf {
        height: auto;
        min-height: 100vh;
        padding-bottom: 2rem;
        overflow: visible;
    }

    .oqf__header {
        position: sticky;
        top: 80px;
        padding: 2vh 4vw 1.5vh 4vw;
        background: rgba(0, 1, 13, 0.98);
        backdrop-filter: blur(10px);
        border-bottom: 1px solid rgba(93, 220, 255, 0.08);
        z-index: 50;
    }

    .oqf__title {
        font-size: clamp(0.85rem, 1.8vw, 1.2rem);
        letter-spacing: 3px;
        text-align: center;
    }

    .oqf__track {
        display: none !important;
    }

    .oqf__mobile-grid {
        display: flex !important;
        gap: 0;
        padding: 2rem 0;
        overflow: visible;
    }

    .oqf__mobile-card {
        width: 100%;
        display: flex;
        align-items: center;
        gap: 0;
        padding: 2rem 0;
        animation: cardEnter 0.6s cubic-bezier(.16,1,.3,1) backwards;
    }

        .oqf__mobile-card:nth-child(odd) {
            flex-direction: row;
            justify-content: flex-start;
        }

            .oqf__mobile-card:nth-child(odd) .oqf__mobile-title {
                padding-left: 1rem;
                padding-right: 1.5rem;
            }

            .oqf__mobile-card:nth-child(odd) .oqf__card {
                flex: 1;
                padding-right: 1rem;
            }

        .oqf__mobile-card:nth-child(even) {
            flex-direction: row-reverse;
            justify-content: flex-end;
        }

            .oqf__mobile-card:nth-child(even) .oqf__mobile-title {
                padding-right: 1rem;
                padding-left: 1.5rem;
            }

            .oqf__mobile-card:nth-child(even) .oqf__card {
                flex: 1;
                padding-left: 1rem;
            }

        .oqf__mobile-card[data-index="0"] {
            animation-delay: 0.1s;
        }

        .oqf__mobile-card[data-index="1"] {
            animation-delay: 0.2s;
        }

        .oqf__mobile-card[data-index="2"] {
            animation-delay: 0.3s;
        }

        .oqf__mobile-card[data-index="3"] {
            animation-delay: 0.4s;
        }

        .oqf__mobile-card[data-index="4"] {
            animation-delay: 0.5s;
        }

    @keyframes cardEnter {
        from {
            opacity: 0;
            transform: translateY(20px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .oqf__mobile-title {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        min-width: 80px;
        gap: 0.5rem;
        text-align: center;
        flex-shrink: 0;
    }

    .oqf__mobile-title-text {
        font-size: 0.9rem;
        font-weight: 700;
        color: #FFF;
        text-transform: uppercase;
        letter-spacing: 2px;
        line-height: 1.2;
        writing-mode: vertical-rl;
        text-orientation: mixed;
        transform: rotate(180deg);
    }

    .oqf__mobile-title-number {
        font-size: 1.2rem;
        font-weight: 900;
        color: #F2561D;
    }

    .oqf__mobile-card .oqf__card {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 8;
        box-shadow: 0 15px 40px rgba(0,0,0,0.5), 0 0 0 1px rgba(93,220,255,0.12), inset 0 1px 0 rgba(255,255,255,0.05);
        transition: all 0.5s cubic-bezier(.16,1,.3,1);
    }

        .oqf__mobile-card .oqf__card:hover {
            transform: rotateY(180deg) scale(1.02);
            box-shadow: 0 25px 50px rgba(93,220,255,0.2), 0 0 0 1px rgba(93,220,255,0.25), inset 0 1px 0 rgba(255,255,255,0.08);
        }

    .oqf__mobile-card .oqf__back-content {
        padding: 1.2rem;
        gap: 0.8rem;
    }

    .oqf__mobile-card .oqf__back-icon {
        width: 50px;
        height: 50px;
    }

        .oqf__mobile-card .oqf__back-icon svg {
            width: 28px;
            height: 28px;
        }

    .oqf__mobile-card .oqf__back-title {
        font-size: 1.2rem;
        letter-spacing: 0.5px;
    }

    .oqf__mobile-card .oqf__back-description {
        font-size: 0.8rem;
        max-width: 100%;
    }

    .oqf__mobile-card .oqf__back-cta {
        padding: 0.6rem 1.5rem;
        font-size: 0.75rem;
        margin-top: 0.8rem;
    }

    .oqf__mobile-card .oqf__front img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

/* SMALL MOBILE (até 480px) */
@media (max-width: 480px) {
    .oqf__header {
        top: 60px;
        padding: 1.5vh 3vw 1vh 3vw;
    }

    .oqf__title {
        font-size: clamp(0.75rem, 1.5vw, 1rem);
        letter-spacing: 2px;
    }

    .oqf__mobile-grid {
        padding: 1.5rem 0;
    }

    .oqf__mobile-card {
        padding: 1.5rem 0;
        gap: 0;
    }

        .oqf__mobile-card:nth-child(odd) .oqf__mobile-title {
            padding-left: 0.8rem;
            padding-right: 1rem;
        }

        .oqf__mobile-card:nth-child(odd) .oqf__card {
            padding-right: 0.8rem;
        }

        .oqf__mobile-card:nth-child(even) .oqf__mobile-title {
            padding-right: 0.8rem;
            padding-left: 1rem;
        }

        .oqf__mobile-card:nth-child(even) .oqf__card {
            padding-left: 0.8rem;
        }

    .oqf__mobile-title {
        min-width: 70px;
    }

    .oqf__mobile-title-text {
        font-size: 0.8rem;
        letter-spacing: 1px;
    }

    .oqf__mobile-title-number {
        font-size: 1rem;
    }

    .oqf__mobile-card .oqf__card {
        aspect-ratio: 16 / 7;
    }

    .oqf__mobile-card .oqf__back-content {
        padding: 1rem;
        gap: 0.6rem;
    }

    .oqf__mobile-card .oqf__back-icon {
        width: 45px;
        height: 45px;
    }

        .oqf__mobile-card .oqf__back-icon svg {
            width: 24px;
            height: 24px;
        }

    .oqf__mobile-card .oqf__back-title {
        font-size: 1rem;
    }

    .oqf__mobile-card .oqf__back-description {
        font-size: 0.75rem;
    }

    .oqf__mobile-card .oqf__back-cta {
        padding: 0.5rem 1.2rem;
        font-size: 0.7rem;
    }
}
