.dgf-tasy-flow {
    position: relative;
    padding: 100px 0 116px;
    overflow: hidden;
    background: #fff;
}

.dgf-tasy-flow__header {
    max-width: 760px;
    margin: 0 auto 66px;
    text-align: center;
}

.dgf-tasy-flow__header .dgf-tasy-section-title {
    margin-bottom: 0;
}

/*
 * Isola os botões narrativos dos estilos globais do tema WordPress.
 * Alguns temas aplicam background de destaque em button:hover/active.
 */
#digifull-tasy button.dgf-tasy-flow__node,
#digifull-tasy button.dgf-tasy-flow__node:hover,
#digifull-tasy button.dgf-tasy-flow__node:focus,
#digifull-tasy button.dgf-tasy-flow__node:active,
#digifull-tasy button.dgf-tasy-flow__mobile-trigger,
#digifull-tasy button.dgf-tasy-flow__mobile-trigger:hover,
#digifull-tasy button.dgf-tasy-flow__mobile-trigger:focus,
#digifull-tasy button.dgf-tasy-flow__mobile-trigger:active {
    -webkit-appearance: none;
    appearance: none;
    background: transparent !important;
    box-shadow: none !important;
}

/* -------------------------------------------------------------------------
   Desktop — interação por clique
------------------------------------------------------------------------- */
.dgf-tasy-flow__desktop {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 170px;
    align-items: center;
    gap: 24px;
    width: 100%;
}

.dgf-tasy-flow__nodes-area {
    position: relative;
    min-width: 0;
    min-height: 440px;
}

.dgf-tasy-flow__track {
    position: absolute;
    z-index: 0;
    top: 50%;
    right: calc(100% / 14);
    left: calc(100% / 14);
    height: 4px;
    overflow: hidden;
    border-radius: 999px;
    background: #EEF1F5;
    transform: translateY(-50%);
    will-change: clip-path;
}

.dgf-tasy-flow__track-fill {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #FFB16B 0%, var(--dgf-orange) 100%);
    box-shadow: 0 0 16px rgba(245,130,31,.24);
    transform: scaleX(0);
    transform-origin: 0 50%;
    will-change: transform;
}

.dgf-tasy-flow__nodes {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    align-items: center;
    min-height: 440px;
}

.dgf-tasy-flow__node {
    position: relative;
    display: grid;
    min-width: 0;
    justify-items: center;
    gap: 10px;
    padding: 0 4px;
    border: 0;
    color: var(--dgf-ink);
    background: transparent;
    font: inherit;
    cursor: pointer;
    transform-origin: 50% 50%;
    transition: opacity .3s ease, filter .3s ease;
    -webkit-tap-highlight-color: transparent;
}

.dgf-tasy-flow__node.is-top { transform: translateY(-92px); }
.dgf-tasy-flow__node.is-bottom { transform: translateY(92px); }

.dgf-tasy-flow__node.is-dimmed {
    opacity: .76;
    filter: saturate(.82);
}

.dgf-tasy-flow__node.is-dimmed:hover,
.dgf-tasy-flow__node.is-dimmed:focus-visible {
    opacity: 1;
    filter: none;
}

.dgf-tasy-flow__circle {
    position: relative;
    display: grid;
    width: 76px;
    height: 76px;
    place-items: center;
    border: 1px solid rgba(16,33,63,.10);
    border-radius: 50%;
    color: var(--dgf-ink);
    background: #fff;
    box-shadow: 0 16px 30px -23px rgba(16,33,63,.44);
    transition:
        color .28s ease,
        background-color .28s ease,
        border-color .28s ease,
        box-shadow .28s ease,
        transform .28s cubic-bezier(.22,1,.36,1);
}

.dgf-tasy-flow__circle::before {
    content: '';
    position: absolute;
    inset: -10px;
    z-index: -1;
    border: 1px solid rgba(245,130,31,.25);
    border-radius: 50%;
    opacity: 0;
    transform: scale(.78);
    transition: opacity .32s ease, transform .44s cubic-bezier(.22,1,.36,1), box-shadow .32s ease;
}

.dgf-tasy-flow__circle svg,
.dgf-tasy-flow__destination-icon svg,
.dgf-tasy-flow__mobile-icon svg,
.dgf-tasy-flow__mobile-destination svg {
    display: block;
    width: 27px;
    height: 27px;
    overflow: visible;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
    transform-origin: 50% 50%;
}

.dgf-tasy-flow__node:hover .dgf-tasy-flow__circle,
.dgf-tasy-flow__node:focus-visible .dgf-tasy-flow__circle,
.dgf-tasy-flow__node.is-active .dgf-tasy-flow__circle {
    color: #fff;
    border-color: var(--dgf-orange);
    background: var(--dgf-orange);
    box-shadow: 0 22px 40px -18px rgba(245,130,31,.76);
    transform: scale(1.08);
}

.dgf-tasy-flow__node.is-active .dgf-tasy-flow__circle::before {
    opacity: 1;
    transform: scale(1);
    box-shadow: 0 0 30px rgba(245,130,31,.12);
}

.dgf-tasy-flow__node:focus-visible { outline: none; }

.dgf-tasy-flow__label {
    max-width: 120px;
    color: var(--dgf-heading);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0;
    line-height: 1.25;
    text-align: center;
    text-transform: none;
    transition: color .28s ease, font-weight .28s ease;
}

.dgf-tasy-flow__node.is-active .dgf-tasy-flow__label {
    color: var(--dgf-ink);
    font-weight: 700;
}

/* Mini-card informativo do módulo ativo. */
.dgf-tasy-flow__tooltip {
    position: absolute;
    left: 50%;
    width: 310px;
    max-width: calc(100vw - 32px);
    box-sizing: border-box;
    padding: 18px 20px 19px;
    border: 1px solid rgba(16,33,63,.10);
    border-radius: 18px;
    color: var(--dgf-body);
    background: linear-gradient(145deg, #fff 0%, #FBFCFE 100%);
    box-shadow: 0 28px 54px -28px rgba(16,33,63,.36);
    opacity: 0;
    pointer-events: none;
    overflow-wrap: break-word;
    white-space: normal;
    text-align: center;
    transform: translateX(-50%) scale(.94);
    transition: opacity .24s ease, transform .34s cubic-bezier(.22,1,.36,1), border-color .28s ease, box-shadow .28s ease;
}

.dgf-tasy-flow__tooltip-title,
.dgf-tasy-flow__tooltip-copy {
    display: block;
    max-width: 100%;
    white-space: normal;
}

.dgf-tasy-flow__tooltip-title {
    margin-bottom: 7px;
    color: var(--dgf-heading);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: -.01em;
    line-height: 1.25;
}

.dgf-tasy-flow__tooltip-copy {
    color: var(--dgf-body);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.56;
}

.dgf-tasy-flow__node.is-top .dgf-tasy-flow__tooltip {
    bottom: calc(100% + 22px);
    transform-origin: 50% 100%;
}

.dgf-tasy-flow__node.is-bottom .dgf-tasy-flow__tooltip {
    top: calc(100% + 22px);
    transform-origin: 50% 0;
}

/* Evita corte do primeiro e do último painel nas bordas da área. */
.dgf-tasy-flow__node:first-child .dgf-tasy-flow__tooltip {
    left: 0;
    transform: scale(.94);
}

.dgf-tasy-flow__node:last-child .dgf-tasy-flow__tooltip {
    right: 0;
    left: auto;
    transform: scale(.94);
}

.dgf-tasy-flow__node.is-active .dgf-tasy-flow__tooltip {
    border-color: rgba(245,130,31,.22);
    opacity: 1;
    transform: translateX(-50%) scale(1);
    box-shadow: 0 30px 60px -28px rgba(16,33,63,.42), 0 0 0 1px rgba(245,130,31,.04);
}

.dgf-tasy-flow__node:first-child.is-active .dgf-tasy-flow__tooltip,
.dgf-tasy-flow__node:last-child.is-active .dgf-tasy-flow__tooltip {
    transform: scale(1);
}

/* Destino final: reage à progressão pelos módulos. */
.dgf-tasy-flow__destination {
    --dgf-destination-halo: 0;
    position: relative;
    z-index: 2;
    display: grid;
    justify-items: center;
    gap: 8px;
    text-align: center;
}

.dgf-tasy-flow__arrow {
    position: absolute;
    top: 43px;
    left: -20px;
    color: #C8CFD9;
    font-size: 28px;
    line-height: 1;
    opacity: .42;
    transition: color .3s ease, opacity .3s ease;
}

.dgf-tasy-flow__destination-icon {
    position: relative;
    display: grid;
    width: 90px;
    height: 90px;
    place-items: center;
    border: 1px solid rgba(245,130,31,.08);
    border-radius: 25px;
    color: var(--dgf-orange);
    background: rgba(245,130,31,.09);
    box-shadow: 0 18px 34px -30px rgba(245,130,31,.3);
    transition: color .34s ease, background-color .34s ease, border-color .34s ease, box-shadow .34s ease;
}

.dgf-tasy-flow__destination-icon::before {
    content: '';
    position: absolute;
    inset: -9px;
    z-index: -1;
    border: 1px solid rgba(245,130,31,.28);
    border-radius: 30px;
    opacity: var(--dgf-destination-halo);
    transform: scale(.94);
    transition: opacity .35s ease, transform .35s ease;
}

.dgf-tasy-flow__destination.is-engaged .dgf-tasy-flow__arrow {
    color: var(--dgf-orange);
}

.dgf-tasy-flow__destination.is-engaged .dgf-tasy-flow__destination-icon::before {
    transform: scale(1);
}

.dgf-tasy-flow__destination.is-complete .dgf-tasy-flow__destination-icon {
    color: #fff;
    border-color: var(--dgf-orange);
    background: var(--dgf-orange);
    box-shadow: 0 24px 44px -24px rgba(245,130,31,.72);
}

.dgf-tasy-flow__destination strong {
    color: var(--dgf-heading);
    font-size: 13.5px;
    line-height: 1.25;
}

.dgf-tasy-flow__destination small {
    max-width: 154px;
    color: var(--dgf-muted);
    font-size: 11.5px;
    line-height: 1.42;
}

.dgf-tasy-flow__mobile { display: none; }

/* -------------------------------------------------------------------------
   Mobile / tablet: progressão conduzida pelo scroll
------------------------------------------------------------------------- */
@media (max-width: 1023px) {
    .dgf-tasy-flow { padding: 78px 0 88px; }

    .dgf-tasy-flow__header { margin-bottom: 34px; }

    .dgf-tasy-flow__desktop { display: none; }

    .dgf-tasy-flow__mobile {
        position: relative;
        display: block;
        width: min(100%, 680px);
        margin-inline: auto;
        padding-bottom: 18px;
    }

    .dgf-tasy-flow__mobile-rail {
        position: absolute;
        z-index: 0;
        top: 38px;
        bottom: 108px;
        left: 31px;
        width: 3px;
        overflow: hidden;
        border-radius: 999px;
        background: #EEF1F5;
    }

    .dgf-tasy-flow__mobile-rail > span {
        display: block;
        width: 100%;
        height: 100%;
        border-radius: inherit;
        background: linear-gradient(180deg, #FFB16B 0%, var(--dgf-orange) 100%);
        transform: scaleY(0);
        transform-origin: 50% 0;
        will-change: transform;
        transition: transform .32s cubic-bezier(.22,1,.36,1);
    }

    .dgf-tasy-flow__mobile-item {
        position: relative;
        z-index: 1;
        min-height: 174px;
        padding: 24px 0 26px;
        opacity: .45;
        transform: scale(.985);
        transform-origin: 0 50%;
        transition: opacity .42s cubic-bezier(.22,1,.36,1), transform .42s cubic-bezier(.22,1,.36,1);
    }

    .dgf-tasy-flow__mobile-item.is-active {
        opacity: 1;
        transform: scale(1);
    }

    .dgf-tasy-flow__mobile-trigger {
        display: grid;
        grid-template-columns: 64px minmax(0, 1fr);
        width: 100%;
        align-items: center;
        gap: 16px;
        padding: 0;
        border: 0;
        color: var(--dgf-heading);
        background: transparent;
        font: inherit;
        text-align: left;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

    .dgf-tasy-flow__mobile-trigger:focus-visible {
        outline: 3px solid rgba(245,130,31,.22);
        outline-offset: 5px;
        border-radius: 18px;
    }

    .dgf-tasy-flow__mobile-icon {
        position: relative;
        display: grid;
        width: 62px;
        height: 62px;
        place-items: center;
        border: 1px solid var(--dgf-line);
        border-radius: 50%;
        color: var(--dgf-ink);
        background: #fff;
        box-shadow: 0 12px 26px -22px rgba(16,33,63,.42);
        transition:
            color .38s ease,
            border-color .38s ease,
            background-color .38s ease,
            box-shadow .38s ease,
            transform .38s cubic-bezier(.22,1,.36,1);
    }

    .dgf-tasy-flow__mobile-icon::before {
        content: '';
        position: absolute;
        inset: -7px;
        border: 1px solid rgba(245,130,31,.22);
        border-radius: 50%;
        opacity: 0;
        transform: scale(.82);
        transition: opacity .34s ease, transform .4s cubic-bezier(.22,1,.36,1);
    }

    .dgf-tasy-flow__mobile-item.is-active .dgf-tasy-flow__mobile-icon {
        color: #fff;
        border-color: var(--dgf-orange);
        background: var(--dgf-orange);
        box-shadow: 0 18px 34px -20px rgba(245,130,31,.72);
        transform: scale(1.07);
    }

    .dgf-tasy-flow__mobile-item.is-active .dgf-tasy-flow__mobile-icon::before {
        opacity: 1;
        transform: scale(1);
    }

    .dgf-tasy-flow__mobile-icon svg { width: 25px; height: 25px; }

    .dgf-tasy-flow__mobile-trigger strong {
        color: var(--dgf-heading);
        font-size: 17px;
        font-weight: 700;
        line-height: 1.25;
    }

    .dgf-tasy-flow__mobile-content {
        min-height: 62px;
        margin: 11px 0 0 80px;
        visibility: hidden;
        opacity: 0;
        transform: translateY(8px);
        transition: opacity .38s ease, transform .38s cubic-bezier(.22,1,.36,1), visibility .38s ease;
    }

    .dgf-tasy-flow__mobile-item.is-active .dgf-tasy-flow__mobile-content {
        visibility: visible;
        opacity: 1;
        transform: translateY(0);
    }

    .dgf-tasy-flow__mobile-content p {
        max-width: 500px;
        margin: 0;
        padding: 0 14px 0 0;
        color: var(--dgf-body);
        font-size: 14px;
        line-height: 1.55;
    }

    .dgf-tasy-flow__mobile-destination {
        position: relative;
        z-index: 2;
        display: flex;
        align-items: center;
        gap: 14px;
        margin-top: 8px;
        padding: 17px 18px;
        border-radius: 20px;
        background: var(--dgf-ink);
        box-shadow: 0 18px 38px -28px rgba(16,33,63,.65);
    }

    .dgf-tasy-flow__mobile-destination > span {
        display: grid;
        width: 52px;
        height: 52px;
        flex: 0 0 auto;
        place-items: center;
        border-radius: 15px;
        color: #fff;
        background: var(--dgf-orange);
    }

    .dgf-tasy-flow__mobile-destination svg { width: 25px; height: 25px; }

    .dgf-tasy-flow__mobile-destination strong,
    .dgf-tasy-flow__mobile-destination small { display: block; }

    .dgf-tasy-flow__mobile-destination strong {
        color: #fff;
        font-size: 15px;
        font-weight: 900;
    }

    .dgf-tasy-flow__mobile-destination small {
        margin-top: 3px;
        color: var(--dgf-dark-muted);
        font-size: 12px;
        line-height: 1.4;
    }
}

@media (max-width: 520px) {
    .dgf-tasy-flow__mobile-item { min-height: 168px; }
    .dgf-tasy-flow__mobile-content { margin-left: 78px; }
}
