/*
 * IEF Questionnaire — Style v5.2.5
 * Risk Assessment — Investissements Étrangers en France
 * Design aligné sur Relians.fr
 * ================================================
 * Palette Relians :
 *   #1E3964  primary navy
 *   #1E62AA  accent blue (hover)
 *   #0E1A2C  very dark navy
 *   #1A3F79  mid navy (headings)
 *   #05060A  text primary
 *   #25272C  text secondary
 *   #FBF9F9  off-white background
 *   #FFFFFF  white
 *
 * Typography :
 *   Marcellus (serif)   — headings
 *   Inter (sans-serif)  — body (weight 300)
 *   Quicksand            — accents / pills
 */

/* ─── RESET & BASE ─────────────────────────────────────────────── */
[x-cloak] { display: none !important; }

.ief-wrapper *,
.ief-wrapper *::before,
.ief-wrapper *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* ─── THEME OVERRIDE — neutralise les styles Elementor/thème ──── */
.ief-wrapper button,
.ief-wrapper button[type="button"],
.ief-wrapper button[type="submit"],
.ief-wrapper button:hover,
.ief-wrapper button:focus,
.ief-wrapper button:active,
.ief-wrapper button[type="button"]:hover,
.ief-wrapper button[type="button"]:focus,
.ief-wrapper button[type="button"]:active,
.ief-wrapper button[type="submit"]:hover,
.ief-wrapper button[type="submit"]:focus,
.ief-wrapper button[type="submit"]:active,
.ief-wrapper input[type="email"],
.ief-wrapper input[type="text"],
.ief-wrapper input[type="tel"],
.ief-wrapper input[type="email"]:focus,
.ief-wrapper input[type="text"]:focus,
.ief-wrapper input[type="tel"]:focus {
    background-color: unset;
    color: unset;
    text-decoration: none;
    outline: none;
    box-shadow: none;
}

.ief-wrapper {
    --primary:         #1E3964;
    --primary-hover:   #1E62AA;
    --primary-dark:    #0E1A2C;
    --primary-mid:     #1A3F79;
    --accent:          #1E62AA;
    --white:           #FFFFFF;
    --off-white:       #F3F6FB;
    --bg-light:        #F5F5F5;
    --text-primary:    #05060A;
    --text-secondary:  #25272C;
    --text-muted:      #6B7280;
    --border:          #E5E7EB;
    --border-hover:    #CBD5E1;
    --green:           #16A34A;
    --amber:           #D97706;
    --red:             #DC2626;
    --blue-light:      #DBEAFE;

    --radius-btn:      99px;
    --radius-card:     10px;
    --radius-sm:       6px;

    --font-heading:    'Marcellus', Georgia, serif;
    --font-body:       'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-accent:     'Quicksand', 'Inter', sans-serif;

    --transition:      0.3s ease;

    font-family: var(--font-body);
    font-weight: 300;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-primary);
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-card);
    overflow: hidden;
    max-width: 860px;
    margin: 0 auto;
}

/* ─── LOADER ────────────────────────────────────────────────────── */
.ief-loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 32px;
    gap: 16px;
    min-height: 200px;
}

.ief-spinner {
    width: 36px;
    height: 36px;
    border: 2.5px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: ief-spin 0.8s linear infinite;
}

@keyframes ief-spin {
    to { transform: rotate(360deg); }
}

/* ─── HEADER HERO ────────────────────────────────────────────────── */
.ief-hero {
    background: var(--off-white);
    padding: 32px 32px 28px;
    border-bottom: 1px solid var(--border);
    text-align: center;
}

.ief-hero-logo {
    margin-bottom: 12px;
    line-height: 1;
}

.ief-relians-logo {
    display: inline-block;
    height: 24px !important;
    width: auto !important;
    max-width: 120px !important;
    opacity: 0.7;
    filter: brightness(0) saturate(100%) invert(17%) sepia(45%) saturate(1200%) hue-rotate(197deg) brightness(95%) contrast(95%);
}

.ief-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--primary);
    color: var(--white);
    font-family: var(--font-accent);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 5px 14px;
    border-radius: var(--radius-btn);
    margin-bottom: 14px;
}

.ief-hero h1 {
    font-family: var(--font-heading);
    font-size: 26px;
    font-weight: 400;
    color: var(--primary);
    line-height: 1.3;
    margin-bottom: 8px;
}

.ief-hero p {
    font-size: 15px;
    color: var(--text-muted);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.65;
}

/* ─── BLOCS NAVIGATION (PILLS) ──────────────────────────────────── */
.ief-blocks-nav {
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: wrap;
    padding: 16px 24px;
    background: var(--off-white);
    border-bottom: 1px solid var(--border);
}

.ief-wrapper .ief-block-pill,
.ief-wrapper button.ief-block-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: var(--radius-btn);
    border: 1px solid var(--border);
    background-color: var(--white);
    cursor: pointer;
    transition: all var(--transition);
    font-size: 13px;
    font-weight: 400;
    color: var(--text-secondary);
    min-width: 130px;
}

.ief-block-pill .pill-icon {
    font-size: 16px;
    line-height: 1;
}

.ief-block-pill .pill-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
}

.ief-block-pill .pill-label {
    font-family: var(--font-accent);
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-weight: 600;
    color: var(--text-muted);
}

.ief-block-pill .pill-name {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
}

.ief-block-pill .pill-result {
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}

/* Pill — locked */
.ief-wrapper .ief-block-pill.locked,
.ief-wrapper .ief-block-pill.locked:hover,
.ief-wrapper .ief-block-pill.locked:focus {
    opacity: 0.4;
    cursor: not-allowed;
    background-color: var(--white);
    color: var(--text-secondary);
}

/* Pill — available */
.ief-wrapper .ief-block-pill.available,
.ief-wrapper button.ief-block-pill.available {
    border-color: var(--primary);
    color: var(--primary);
    background-color: var(--white);
}

.ief-wrapper .ief-block-pill.available:hover,
.ief-wrapper .ief-block-pill.available:focus {
    background-color: var(--blue-light);
    color: var(--primary);
    transform: translateY(-1px);
}

/* Pill — active */
.ief-wrapper .ief-block-pill.active,
.ief-wrapper .ief-block-pill.active:hover,
.ief-wrapper .ief-block-pill.active:focus {
    background-color: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}
.ief-wrapper .ief-block-pill.active .pill-label,
.ief-wrapper .ief-block-pill.active .pill-name {
    color: rgba(255,255,255,0.85);
}

/* Pill — completed (green = hors champ) */
.ief-wrapper .ief-block-pill.completed-green,
.ief-wrapper .ief-block-pill.completed-green:hover,
.ief-wrapper .ief-block-pill.completed-green:focus {
    border-color: var(--green);
    background-color: #F0FDF4;
    color: var(--green);
}
.ief-wrapper .ief-block-pill.completed-green .pill-name {
    color: var(--green);
}
.ief-wrapper .ief-block-pill.completed-green .pill-icon-svg img {
    filter: invert(42%) sepia(93%) saturate(352%) hue-rotate(87deg) brightness(95%) contrast(97%);
}

/* Pill — completed (red = eligible / facteur de risque) */
.ief-wrapper .ief-block-pill.completed-red,
.ief-wrapper .ief-block-pill.completed-red:hover,
.ief-wrapper .ief-block-pill.completed-red:focus {
    border-color: #EF4444;
    background-color: #FEF2F2;
    color: #EF4444;
}
.ief-wrapper .ief-block-pill.completed-red .pill-name {
    color: #EF4444;
}
.ief-wrapper .ief-block-pill.completed-red .pill-icon-svg img {
    filter: invert(36%) sepia(95%) saturate(2000%) hue-rotate(343deg) brightness(95%) contrast(95%);
}

/* Pill — completed (orange = incertitude) */
.ief-wrapper .ief-block-pill.completed-orange,
.ief-wrapper .ief-block-pill.completed-orange:hover,
.ief-wrapper .ief-block-pill.completed-orange:focus {
    border-color: #F97316;
    background-color: #FFF7ED;
    color: #F97316;
}
.ief-wrapper .ief-block-pill.completed-orange .pill-name {
    color: #F97316;
}
.ief-wrapper .ief-block-pill.completed-orange .pill-icon-svg img {
    filter: invert(52%) sepia(90%) saturate(1500%) hue-rotate(360deg) brightness(100%) contrast(95%);
}

/* ─── ZONE QUESTION ─────────────────────────────────────────────── */
.ief-question-zone {
    padding: 28px 32px;
    min-height: 280px;
}

/* ─── BARRE DE PROGRESSION ──────────────────────────────────────── */
.ief-progress-wrap {
    margin-bottom: 20px;
}

.ief-progress-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.ief-progress-label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 400;
}

.ief-progress-pct {
    font-size: 12px;
    font-weight: 600;
    color: var(--primary);
}

.ief-progress-bar {
    height: 4px;
    background: var(--border);
    border-radius: 4px;
    overflow: hidden;
}

.ief-progress-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 4px;
    transition: width 0.4s ease;
}

/* ─── QUESTION CARD ─────────────────────────────────────────────── */
.ief-question-card {
    margin-bottom: 20px;
}

.ief-question-id {
    font-family: var(--font-accent);
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.ief-question-parcours {
    display: inline-block;
    font-family: var(--font-accent);
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--primary);
    background: var(--blue-light);
    padding: 2px 8px;
    border-radius: var(--radius-btn);
    margin-bottom: 8px;
}

.ief-question-text {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 400;
    color: var(--primary-mid);
    line-height: 1.35;
    margin-bottom: 8px;
}

.ief-help-text {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
    padding: 10px 14px;
    background: var(--off-white);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--primary);
    white-space: pre-line;
}

/* ─── OPTIONS ───────────────────────────────────────────────────── */
.ief-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.ief-wrapper .ief-option,
.ief-wrapper button.ief-option {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background-color: var(--white);
    cursor: pointer;
    transition: all var(--transition);
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 400;
    color: var(--text-primary);
    text-align: left;
    line-height: 1.5;
}

.ief-wrapper .ief-option:hover,
.ief-wrapper .ief-option:focus,
.ief-wrapper button.ief-option:hover,
.ief-wrapper button.ief-option:focus {
    border-color: var(--primary);
    background-color: var(--off-white);
    color: var(--text-primary);
}

.ief-wrapper .ief-option.selected,
.ief-wrapper button.ief-option.selected,
.ief-wrapper .ief-option.selected:hover,
.ief-wrapper .ief-option.selected:focus {
    border-color: var(--primary);
    background-color: var(--blue-light);
    color: var(--text-primary);
    font-weight: 500;
}

.ief-option-icon {
    font-size: 16px;
    line-height: 1;
    flex-shrink: 0;
}

/* ─── MULTI-SELECT CHECKBOXES ──────────────────────────────────── */
.ief-multiselect-scroll {
    max-height: 360px;
    overflow-y: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 4px;
}

.ief-checkbox-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background var(--transition);
    font-size: 13px;
    line-height: 1.4;
}

.ief-checkbox-item:hover {
    background: var(--off-white);
}

.ief-checkbox-item.checked {
    background: var(--blue-light);
}

.ief-checkbox-box {
    width: 18px;
    height: 18px;
    border: 1.5px solid var(--border);
    border-radius: 3px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
}

.ief-checkbox-item.checked .ief-checkbox-box {
    background: var(--primary);
    border-color: var(--primary);
}

.ief-checkbox-box svg {
    width: 11px;
    height: 11px;
    fill: none;
    stroke: white;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0;
    transition: opacity var(--transition);
}

.ief-checkbox-item.checked .ief-checkbox-box svg {
    opacity: 1;
}

/* ─── BOUTONS ───────────────────────────────────────────────────── */
.ief-wrapper .ief-continue-btn,
.ief-wrapper .ief-validate-btn,
.ief-wrapper button.ief-continue-btn,
.ief-wrapper button.ief-validate-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 24px;
    border: 1px solid var(--primary);
    border-radius: var(--radius-btn);
    background-color: var(--primary);
    color: var(--white);
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    margin-top: 16px;
}

.ief-wrapper .ief-continue-btn:hover,
.ief-wrapper .ief-continue-btn:focus,
.ief-wrapper .ief-validate-btn:hover,
.ief-wrapper .ief-validate-btn:focus,
.ief-wrapper button.ief-continue-btn:hover,
.ief-wrapper button.ief-continue-btn:focus,
.ief-wrapper button.ief-validate-btn:hover,
.ief-wrapper button.ief-validate-btn:focus {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
    color: var(--white);
}

/* ─── DISPLAY CARD ─────────────────────────────────────────────── */
.ief-display-card {
    padding: 16px 20px;
    background: var(--off-white);
    border-left: 3px solid var(--amber);
    border-radius: var(--radius-sm);
    font-size: 14px;
    line-height: 1.65;
    color: var(--text-secondary);
}

/* ─── BLOCK RESULT (résultat intermédiaire) ────────────────────── */
.ief-block-result {
    text-align: center;
    padding: 24px 0;
}

.ief-block-result-icon {
    font-size: 36px;
    display: block;
    margin-bottom: 12px;
}

.ief-block-result h3 {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 8px;
}

.ief-block-result p {
    font-size: 15px;
    color: var(--text-muted);
    max-width: 540px;
    margin: 0 auto;
    line-height: 1.65;
}

.ief-block-result .ief-result-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    border-radius: var(--radius-btn);
    font-family: var(--font-accent);
    font-size: 12px;
    font-weight: 600;
    border-width: 1px;
    border-style: solid;
    margin-bottom: 12px;
}

/* ─── D SCORE DISPLAY ──────────────────────────────────────────── */
.ief-d-score-display {
    text-align: center;
}

.ief-d-score-number {
    font-family: var(--font-heading);
    font-size: 36px;
    font-weight: 400;
    line-height: 1;
    margin-bottom: 4px;
}

.ief-d-score-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 12px;
    color: var(--text-muted);
}

.ief-d-score-meta strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* ─── RÉSULTAT FINAL ───────────────────────────────────────────── */
.ief-result-zone {
    padding: 28px 32px;
}

.ief-blocks-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 10px;
    margin-bottom: 24px;
}

.ief-summary-block {
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    text-align: center;
    background: var(--white);
}

.ief-summary-block.pass {
    border-color: #EF4444;
    background: #FEF2F2;
}

.ief-summary-block.fail {
    border-color: var(--green);
    background: #F0FDF4;
}

.ief-summary-block.uncertain {
    border-color: #F97316;
    background: #FFF7ED;
}

.ief-summary-block .sb-icon {
    font-size: 20px;
    display: block;
    margin-bottom: 4px;
}

.ief-summary-block .sb-name {
    font-family: var(--font-accent);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.ief-summary-block .sb-result {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
}

/* ─── MAIN RESULT ──────────────────────────────────────────────── */
.ief-main-result {
    border: 1px solid var(--border);
    border-radius: var(--radius-card);
    overflow: hidden;
}

.ief-main-result-header {
    padding: 28px 28px 20px;
    text-align: center;
    background: var(--off-white);
    border-bottom: 1px solid var(--border);
}

.ief-main-result-header h2 {
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 8px;
}

.ief-main-result-header .result-desc {
    font-size: 15px;
    color: var(--text-muted);
    max-width: 540px;
    margin: 0 auto;
    line-height: 1.65;
}

.ief-result-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    border-radius: var(--radius-btn);
    font-family: var(--font-accent);
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 12px;
}

.ief-result-body {
    padding: 24px 28px;
}

/* ─── RISK METER (jauge 5 niveaux) ─────────────────────────────── */
.ief-risk-meter {
    margin-bottom: 20px;
}

.ief-risk-meter-title {
    font-family: var(--font-accent);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    text-align: center;
    margin-bottom: 8px;
}

.ief-risk-track {
    display: flex;
    gap: 3px;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
}

.ief-risk-segment {
    flex: 1;
    opacity: 0.2;
    transition: opacity var(--transition);
    border-radius: 2px;
}

.ief-risk-segment.active {
    opacity: 1;
}

.ief-risk-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 4px;
    font-size: 9px;
    color: var(--text-muted);
    font-weight: 500;
}

/* ─── RECOMMENDATIONS ──────────────────────────────────────────── */
.ief-recommendations h4 {
    font-family: var(--font-heading);
    font-size: 16px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 10px;
}

.ief-reco-list {
    list-style: none;
    padding: 0;
}

.ief-reco-list li {
    position: relative;
    padding: 6px 0 6px 16px;
    font-size: 14px;
    line-height: 1.55;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border);
}

.ief-reco-list li:last-child {
    border-bottom: none;
}

.ief-reco-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 12px;
    width: 5px;
    height: 5px;
    background: var(--primary);
    border-radius: 50%;
}

/* ─── DIAGNOSTIC SECTION ───────────────────────────────────────── */
.ief-diagnostic-section {
    padding: 24px 32px;
    background: var(--off-white);
    border-top: 1px solid var(--border);
}

.ief-diagnostic-card {
    max-width: 640px;
    margin: 0 auto;
}

.ief-diagnostic-card h3 {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 10px;
}

.ief-diagnostic-card .diagnostic-intro {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.65;
    margin-bottom: 16px;
    white-space: pre-line;
}

.ief-diagnostic-card .diagnostic-desc {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.65;
    margin-bottom: 20px;
    white-space: pre-line;
}

.ief-diagnostic-card .diagnostic-cta-box {
    background: var(--white);
    border: 1px solid var(--primary);
    border-radius: var(--radius-card);
    padding: 20px;
}

.ief-diagnostic-card .diagnostic-cta-box h4 {
    font-family: var(--font-heading);
    font-size: 16px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 10px;
}

.ief-diagnostic-card .diagnostic-cta-desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.65;
    margin-bottom: 12px;
    white-space: pre-line;
}

.ief-diagnostic-card .diagnostic-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    font-size: 12px;
    color: var(--text-muted);
}

.ief-diagnostic-card .diagnostic-meta strong {
    color: var(--text-primary);
}

/* ─── CTA SECTION ──────────────────────────────────────────────── */
.ief-cta-section {
    padding: 28px 32px;
    text-align: center;
}

.ief-cta-title {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 6px;
}

.ief-cta-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    max-width: 560px;
    margin: 0 auto 20px;
    line-height: 1.65;
}

.ief-cta-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 10px;
    margin-bottom: 28px;
}

.ief-cta-primary,
.ief-cta-secondary,
.ief-cta-book {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: var(--radius-card);
    text-decoration: none;
    transition: all var(--transition);
    font-size: 13px;
    line-height: 1.35;
}

/* !important sur la couleur uniquement : nécessaire pour bypasser les
   builders qui injectent des règles de type `.elementor-kit-N a {color:...}`
   (spécificité 0,1,1) qui battent `.ief-cta-primary` seul (0,1,0). */
.ief-cta-primary {
    background: var(--primary);
    color: var(--white) !important;
    border: 1px solid var(--primary);
}
.ief-cta-primary:hover,
.ief-cta-primary:focus {
    background: var(--primary-hover);
    border-color: var(--primary-hover);
    color: var(--white) !important;
}
.ief-cta-primary .cta-text,
.ief-cta-primary .cta-text strong,
.ief-cta-primary:hover .cta-text,
.ief-cta-primary:hover .cta-text strong,
.ief-cta-primary:focus .cta-text,
.ief-cta-primary:focus .cta-text strong {
    color: var(--white) !important;
}

.ief-cta-secondary {
    background: var(--white);
    color: var(--primary) !important;
    border: 1px solid var(--primary);
}
.ief-cta-secondary:hover {
    background: var(--off-white);
}
.ief-cta-secondary .cta-text,
.ief-cta-secondary .cta-text strong {
    color: var(--primary) !important;
}

.ief-cta-book {
    background: var(--off-white);
    color: var(--text-secondary) !important;
    border: 1px solid var(--border);
}
.ief-cta-book:hover {
    border-color: var(--primary);
}
.ief-cta-book .cta-text,
.ief-cta-book .cta-text strong {
    color: var(--text-secondary) !important;
}

.ief-cta-primary .cta-icon,
.ief-cta-secondary .cta-icon,
.ief-cta-book .cta-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.ief-cta-primary .cta-text,
.ief-cta-secondary .cta-text,
.ief-cta-book .cta-text {
    text-align: left;
}

.ief-cta-primary .cta-text strong,
.ief-cta-secondary .cta-text strong,
.ief-cta-book .cta-text strong {
    font-weight: 600;
}

/* ─── FORMULAIRE CONTACT ───────────────────────────────────────── */
.ief-contact-form-wrapper {
    background: var(--off-white);
    border: 1px solid var(--border);
    border-radius: var(--radius-card);
    padding: 24px;
    text-align: left;
}

.ief-contact-form-title {
    font-family: var(--font-heading);
    font-size: 18px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 6px;
}

.ief-contact-form-subtitle {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 16px;
    line-height: 1.55;
}

.ief-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

.ief-form-group {
    margin-bottom: 12px;
}

.ief-form-label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.ief-form-label .required {
    color: var(--red);
}

.ief-wrapper .ief-form-input,
.ief-wrapper input.ief-form-input,
.ief-wrapper input[type="tel"].ief-form-input {
    width: 100%;
    padding: 9px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background-color: var(--white);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 300;
    transition: border-color var(--transition);
}

.ief-wrapper .ief-form-input:focus,
.ief-wrapper input.ief-form-input:focus {
    outline: none;
    border-color: var(--primary);
    background-color: var(--white);
    color: var(--text-primary);
    box-shadow: none;
}

.ief-wrapper .ief-form-input::placeholder {
    color: var(--text-muted);
    opacity: 0.6;
}

.ief-wrapper .ief-form-submit,
.ief-wrapper button.ief-form-submit {
    width: 100%;
    padding: 11px 24px;
    border: 1px solid var(--primary);
    border-radius: var(--radius-btn);
    background-color: var(--primary);
    color: var(--white);
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    margin-top: 4px;
}

.ief-wrapper .ief-form-submit:hover,
.ief-wrapper .ief-form-submit:focus,
.ief-wrapper button.ief-form-submit:hover,
.ief-wrapper button.ief-form-submit:focus {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
    color: var(--white);
}

.ief-wrapper .ief-form-submit:disabled {
    opacity: 0.6;
    cursor: wait;
}

.ief-form-error {
    color: var(--red);
    font-size: 13px;
    margin-bottom: 8px;
    padding: 8px 12px;
    background: #FEF2F2;
    border-radius: var(--radius-sm);
}

/* ─── EMAIL INLINE FORM ────────────────────────────────────────── */
.ief-email-form {
    display: flex;
    gap: 8px;
}

.ief-wrapper .ief-email-send-btn,
.ief-wrapper button.ief-email-send-btn {
    padding: 9px 16px;
    border: 1px solid var(--primary);
    border-radius: var(--radius-btn);
    background-color: var(--primary);
    color: var(--white);
    font-family: var(--font-body);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
}

.ief-wrapper .ief-email-send-btn:hover,
.ief-wrapper .ief-email-send-btn:focus,
.ief-wrapper button.ief-email-send-btn:hover,
.ief-wrapper button.ief-email-send-btn:focus {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
    color: var(--white);
}

.ief-wrapper .ief-email-send-btn:disabled {
    opacity: 0.6;
    cursor: wait;
}

/* ─── CONTACT SUCCESS ──────────────────────────────────────────── */
.ief-contact-success {
    text-align: center;
    padding: 20px;
}

.ief-contact-success .success-icon {
    font-size: 36px;
    display: block;
    margin-bottom: 10px;
}

.ief-contact-success h4 {
    font-family: var(--font-heading);
    font-size: 18px;
    font-weight: 400;
    color: var(--primary);
    margin-bottom: 6px;
}

.ief-contact-success p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.55;
}

/* ─── NAV BAR (retour / recommencer) ──────────────────────────── */
.ief-nav-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 32px;
    border-top: 1px solid var(--border);
    background: var(--off-white);
}

.ief-wrapper .ief-back-btn,
.ief-wrapper .ief-restart-btn,
.ief-wrapper button.ief-back-btn,
.ief-wrapper button.ief-restart-btn {
    padding: 7px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-btn);
    background-color: var(--white);
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: 13px;
    font-weight: 400;
    cursor: pointer;
    transition: all var(--transition);
}

.ief-wrapper .ief-back-btn:hover,
.ief-wrapper .ief-back-btn:focus,
.ief-wrapper .ief-restart-btn:hover,
.ief-wrapper .ief-restart-btn:focus,
.ief-wrapper button.ief-back-btn:hover,
.ief-wrapper button.ief-back-btn:focus,
.ief-wrapper button.ief-restart-btn:hover,
.ief-wrapper button.ief-restart-btn:focus {
    border-color: var(--primary);
    color: var(--primary);
    background-color: var(--white);
}

/* ─── DISCLAIMER ───────────────────────────────────────────────── */
.ief-disclaimer {
    font-size: 13px;
    color: var(--text-secondary);
    text-align: center;
    padding: 16px 24px;
    line-height: 1.6;
    background: var(--off-white);
    border-top: 1px solid var(--border);
}

.ief-disclaimer strong {
    font-weight: 600;
}

/* ─── SVG ICONS ────────────────────────────────────────────────── */
.pill-icon-svg img {
    width: 20px !important;
    height: 20px !important;
    max-width: 20px !important;
    display: block;
    fill: currentColor;
}

.ief-block-pill.active .pill-icon-svg img {
    filter: brightness(0) invert(1);
}

.ief-block-pill.completed .pill-icon-svg img {
    filter: invert(42%) sepia(93%) saturate(352%) hue-rotate(87deg) brightness(95%) contrast(97%);
}

.sb-icon-svg img {
    width: 22px !important;
    height: 22px !important;
    max-width: 22px !important;
    display: block;
    margin: 0 auto;
}

.cta-icon-svg img {
    width: 22px !important;
    height: 22px !important;
    max-width: 22px !important;
    display: inline-block;
    vertical-align: middle;
}

.ief-cta-primary .cta-icon-svg img {
    filter: brightness(0) invert(1);
}

.ief-cta-title .cta-icon-svg {
    display: inline-block;
    vertical-align: middle;
    margin-right: 4px;
}

.ief-cta-title .cta-icon-svg img {
    width: 24px !important;
    height: 24px !important;
    max-width: 24px !important;
}

/* ─── ANIMATIONS ───────────────────────────────────────────────── */
.ief-animate-in {
    animation: ief-fadeIn 0.3s ease;
}

@keyframes ief-fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.ief-animate-bounce {
    animation: ief-bounce 0.5s ease;
}

@keyframes ief-bounce {
    0%   { transform: scale(0.8); opacity: 0; }
    60%  { transform: scale(1.05); }
    100% { transform: scale(1); opacity: 1; }
}

.ief-animate-slide {
    animation: ief-slideUp 0.4s ease;
}

@keyframes ief-slideUp {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ─── RESPONSIVE ───────────────────────────────────────────────── */
@media (max-width: 640px) {
    .ief-wrapper { border-radius: 0; border-left: none; border-right: none; }
    .ief-hero { padding: 24px 20px 20px; }
    .ief-hero h1 { font-size: 22px; }
    .ief-question-zone { padding: 20px; }
    .ief-blocks-nav { padding: 12px 16px; gap: 6px; }
    .ief-block-pill { min-width: 0; padding: 8px 12px; }
    .ief-result-zone { padding: 20px; }
    .ief-nav-bar { padding: 10px 20px; }
    .ief-form-row { grid-template-columns: 1fr; }
    .ief-blocks-summary { grid-template-columns: repeat(2, 1fr); }
    .ief-cta-grid { grid-template-columns: 1fr; }
    .ief-contact-form-wrapper { padding: 16px; }
    .ief-email-form { flex-direction: column; }
    .ief-diagnostic-section { padding: 20px; }
    .ief-cta-section { padding: 20px; }
}

@media (max-width: 480px) {
    .ief-blocks-nav { gap: 4px; }
    .ief-block-pill { padding: 6px 10px; }
    .ief-block-pill .pill-name { font-size: 11px; }
    .ief-question-text { font-size: 17px; }
    .ief-blocks-summary { grid-template-columns: 1fr 1fr; }
}
