/**
 * Questionnaire d'éligibilité (FND)
 * Les balises p, ul, a, h* sont évitées : elles sont stylées par le thème dans #main > #post.
 */

.vc-eligibilite {
    --elig-blue: #005596;
    --elig-blue-dark: #003f70;
    --elig-yellow: #FFD200;
    --elig-yellow-light: #FFF8D6;
    --elig-white: #FFFFFF;
    --elig-shadow: rgba(0, 63, 112, .55);
    --elig-radio-border: rgba(0, 85, 150, .35);
    --elig-pulse: rgba(255, 210, 0, .6);
    --elig-pulse-end: rgba(255, 210, 0, 0);
    --elig-ease: cubic-bezier(.2, .8, .2, 1);

    position: relative;
    overflow: hidden;
    margin: 32px 0;
    padding: 56px 64px;
    background: var(--elig-blue);
    background-image: radial-gradient(circle at 100% 0, rgba(255, 255, 255, .12) 0, rgba(255, 255, 255, 0) 45%),
                      radial-gradient(circle at 0 100%, rgba(0, 0, 0, .18) 0, rgba(0, 0, 0, 0) 50%);
    color: var(--elig-white);
    font-family: inherit;
    font-size: 18px;
    line-height: 1.5;
    box-shadow: 0 24px 48px -24px var(--elig-shadow);
}

/* Thème framboise (couleurs du bouton de don des pages aidants) */
.vc-eligibilite.elig-theme-framboise {
    --elig-blue: #AE0044;
    --elig-blue-dark: #850034;
    --elig-yellow: #FFD16C;
    --elig-yellow-light: #FFF4DC;
    --elig-shadow: rgba(133, 0, 52, .55);
    --elig-radio-border: rgba(174, 0, 68, .35);
    --elig-pulse: rgba(255, 209, 108, .6);
    --elig-pulse-end: rgba(255, 209, 108, 0);
}

/* Équerre jaune, rappel des titres du site */
.vc-eligibilite .elig-deco {
    position: absolute;
    top: 0;
    left: 0;
    width: 122px;
    height: 98px;
    border-top: 13px solid var(--elig-yellow);
    border-left: 13px solid var(--elig-yellow);
    pointer-events: none;
}

.vc-eligibilite .elig-step {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
    padding: 0;
    border: 0;
    min-width: 0;
}

.vc-eligibilite .elig-step[hidden],
.vc-eligibilite .elig-critere[hidden] {
    display: none !important;
}

.vc-eligibilite .elig-step.is-active {
    animation: elig-in .5s var(--elig-ease) both;
}

.vc-eligibilite .elig-step.is-active.is-back {
    animation-name: elig-in-back;
}

@keyframes elig-in {
    from { opacity: 0; transform: translateX(40px); }
    to { opacity: 1; transform: none; }
}

@keyframes elig-in-back {
    from { opacity: 0; transform: translateX(-40px); }
    to { opacity: 1; transform: none; }
}

/* Textes */

.vc-eligibilite .elig-kicker {
    display: block;
    margin-bottom: 12px;
    color: var(--elig-yellow);
    font-size: 14px;
    line-height: 20px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.vc-eligibilite .elig-kicker-sep {
    margin: 0 4px;
    opacity: .7;
}

.vc-eligibilite .elig-titre {
    margin: 0 0 16px;
    color: var(--elig-white);
    font-size: 40px;
    line-height: 1.15;
    font-weight: 700;
    letter-spacing: -1px;
    outline: none;
}

.vc-eligibilite .elig-texte {
    margin-bottom: 24px;
    color: rgba(255, 255, 255, .88);
    font-size: 20px;
    line-height: 1.5;
}

.vc-eligibilite .elig-intro .elig-texte {
    max-width: 640px;
}

/* Puces d'introduction */

.vc-eligibilite .elig-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 36px;
}

.vc-eligibilite .elig-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid rgba(255, 255, 255, .25);
    border-radius: 50px;
    background: rgba(255, 255, 255, .08);
    font-size: 15px;
    line-height: 20px;
    font-weight: 500;
}

.vc-eligibilite .elig-chip svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: var(--elig-yellow);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Boutons */

.vc-eligibilite .elig-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 0;
    padding: 13px 32px;
    border: 3px solid transparent;
    border-radius: 50px;
    background: none;
    font-family: inherit;
    font-size: 18px;
    line-height: 24px;
    font-weight: 600;
    text-transform: uppercase;
    text-decoration: none !important;
    cursor: pointer;
    transition: background-color .2s, color .2s, border-color .2s, transform .2s var(--elig-ease), box-shadow .2s, opacity .2s;
}

.vc-eligibilite .elig-btn svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform .2s var(--elig-ease);
}

.vc-eligibilite .elig-btn:focus-visible {
    outline: 3px solid var(--elig-white);
    outline-offset: 3px;
}

.vc-eligibilite .elig-btn-primary {
    border-color: var(--elig-yellow);
    background: var(--elig-yellow);
    color: var(--elig-blue) !important;
}

.vc-eligibilite .elig-btn-primary:hover,
.vc-eligibilite .elig-btn-primary:focus {
    background: var(--elig-white);
    border-color: var(--elig-white);
    color: var(--elig-blue) !important;
    box-shadow: 0 10px 24px -10px rgba(0, 0, 0, .45);
    transform: translateY(-2px);
}

.vc-eligibilite .elig-btn-primary:hover svg {
    transform: translateX(4px);
}

.vc-eligibilite .elig-btn-ghost {
    padding-left: 8px;
    padding-right: 8px;
    color: var(--elig-white);
    font-size: 15px;
}

.vc-eligibilite .elig-btn-ghost:hover,
.vc-eligibilite .elig-btn-ghost:focus {
    color: var(--elig-yellow);
}

.vc-eligibilite .elig-btn-ghost:hover svg {
    transform: translateX(-4px);
}

.vc-eligibilite .elig-btn-outline {
    border-color: var(--elig-white);
    color: var(--elig-white);
}

.vc-eligibilite .elig-btn-outline:hover,
.vc-eligibilite .elig-btn-outline:focus {
    background: var(--elig-white);
    color: var(--elig-blue);
}

.vc-eligibilite .elig-btn-outline:hover svg {
    transform: rotate(-90deg);
}

/* Questions */

.vc-eligibilite .elig-progress {
    height: 6px;
    margin-bottom: 32px;
    border-radius: 6px;
    background: rgba(255, 255, 255, .18);
    overflow: hidden;
}

.vc-eligibilite .elig-progress-bar {
    width: var(--to);
    height: 100%;
    border-radius: 6px;
    background: var(--elig-yellow);
}

.vc-eligibilite .is-active .elig-progress-bar {
    animation: elig-progress .6s var(--elig-ease) both;
}

@keyframes elig-progress {
    from { width: var(--from); }
    to { width: var(--to); }
}

.vc-eligibilite .elig-legend {
    display: block;
    width: 100%;
    margin: 0 0 20px;
    padding: 0;
    border: 0;
    color: var(--elig-white);
    outline: none;
}

.vc-eligibilite .elig-question-texte {
    display: block;
    font-size: 30px;
    line-height: 1.25;
    font-weight: 700;
    letter-spacing: -.5px;
}

.vc-eligibilite .elig-precisions {
    margin-bottom: 24px;
    color: rgba(255, 255, 255, .85);
    font-size: 17px;
    line-height: 1.5;
}

.vc-eligibilite .elig-precision-item {
    position: relative;
    margin-bottom: 8px;
    padding-left: 22px;
}

.vc-eligibilite .elig-precision-item:before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    width: 9px;
    height: 9px;
    background: var(--elig-yellow);
}

.vc-eligibilite .elig-precision-texte {
    margin-bottom: 8px;
}

.vc-eligibilite .elig-choices {
    display: grid;
    gap: 12px;
    margin-bottom: 32px;
}

.vc-eligibilite .elig-choice {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 0;
    padding: 18px 22px;
    border: 3px solid transparent;
    border-radius: 14px;
    background: var(--elig-white);
    color: var(--elig-blue);
    font-size: 18px;
    line-height: 1.4;
    font-weight: 500;
    cursor: pointer;
    transition: transform .2s var(--elig-ease), box-shadow .2s, border-color .2s, background-color .2s;
}

.vc-eligibilite .elig-choice:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px -12px rgba(0, 0, 0, .5);
}

.vc-eligibilite .elig-choice input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    pointer-events: none;
}

.vc-eligibilite .elig-choice:focus-within {
    outline: 3px solid var(--elig-yellow);
    outline-offset: 3px;
}

.vc-eligibilite .elig-radio {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border: 2px solid var(--elig-radio-border);
    border-radius: 50%;
    transition: background-color .2s, border-color .2s, transform .3s var(--elig-ease);
}

.vc-eligibilite .elig-radio svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: var(--elig-yellow);
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 20;
    stroke-dashoffset: 20;
    transition: stroke-dashoffset .3s var(--elig-ease) .05s;
}

.vc-eligibilite .elig-choice.is-checked {
    border-color: var(--elig-yellow);
    background: var(--elig-yellow-light);
}

.vc-eligibilite .elig-choice.is-checked .elig-radio {
    border-color: var(--elig-blue);
    background: var(--elig-blue);
    transform: scale(1.1);
}

.vc-eligibilite .elig-choice.is-checked .elig-radio svg {
    stroke-dashoffset: 0;
}

.vc-eligibilite .elig-nav {
    display: flex;
    align-items: center;
}

.vc-eligibilite .elig-nav .elig-btn-ghost {
    padding-left: 0;
}

/* Résultats */

.vc-eligibilite .elig-result {
    text-align: center;
}

.vc-eligibilite .elig-result .elig-texte {
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.vc-eligibilite .elig-result-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 96px;
    height: 96px;
    margin: 0 auto 24px;
    border-radius: 50%;
    background: var(--elig-yellow);
    animation: elig-pop .6s var(--elig-ease) .1s both;
}

.vc-eligibilite .elig-result-ko .elig-result-icon {
    background: var(--elig-white);
}

.vc-eligibilite .elig-result-icon svg {
    width: 56px;
    height: 56px;
    fill: none;
    stroke: var(--elig-blue);
    stroke-width: 5;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 60;
    stroke-dashoffset: 60;
    animation: elig-draw .5s var(--elig-ease) .45s forwards;
}

.vc-eligibilite .elig-result-ok .elig-result-icon {
    box-shadow: 0 0 0 0 var(--elig-pulse);
    animation: elig-pop .6s var(--elig-ease) .1s both, elig-pulse 2s ease-out 1s 2;
}

@keyframes elig-pop {
    from { opacity: 0; transform: scale(.4); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes elig-draw {
    to { stroke-dashoffset: 0; }
}

@keyframes elig-pulse {
    0% { box-shadow: 0 0 0 0 var(--elig-pulse); }
    100% { box-shadow: 0 0 0 24px var(--elig-pulse-end); }
}

.vc-eligibilite .elig-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 16px 24px;
    margin-top: 32px;
}

.vc-eligibilite .elig-cta {
    padding: 16px 40px;
    font-size: 20px;
}

.vc-eligibilite .elig-criteres {
    display: grid;
    gap: 12px;
    max-width: 600px;
    margin: 0 auto;
    text-align: left;
}

.vc-eligibilite .elig-critere {
    padding: 16px 20px;
    border-left: 7px solid var(--elig-yellow);
    background: rgba(255, 255, 255, .1);
}

.vc-eligibilite .elig-critere-nom {
    font-size: 16px;
    line-height: 22px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.vc-eligibilite .elig-critere-message {
    margin-top: 4px;
    color: rgba(255, 255, 255, .85);
    font-size: 17px;
    line-height: 1.45;
}

.vc-eligibilite .elig-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* Responsive */

@media (max-width: 767px) {
    .vc-eligibilite {
        margin: 24px 0;
        padding: 48px 24px 32px;
    }

    .vc-eligibilite .elig-deco {
        width: 86px;
        height: 76px;
        border-width: 11px;
    }

    .vc-eligibilite .elig-titre {
        font-size: 28px;
        letter-spacing: -.5px;
    }

    .vc-eligibilite .elig-texte {
        font-size: 17px;
    }

    .vc-eligibilite .elig-question-texte {
        font-size: 22px;
    }

    .vc-eligibilite .elig-choice {
        padding: 14px 16px;
        font-size: 16px;
    }

    .vc-eligibilite .elig-btn {
        padding: 12px 24px;
        font-size: 16px;
    }

    .vc-eligibilite .elig-intro .elig-btn,
    .vc-eligibilite .elig-cta {
        width: 100%;
    }

    .vc-eligibilite .elig-result-icon {
        width: 80px;
        height: 80px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .vc-eligibilite *,
    .vc-eligibilite *:before {
        animation-duration: .01ms !important;
        animation-delay: 0s !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}
