/* ===============================================
   GENERAL STYLES
   =============================================== */
:root {
    /* Colors */
    --primary-color: #6adc8a;
    --primary-light: #72ff9a;
    --primary-dark: #53be71;
    --secondary-color: #444;
    --positive-gradient-start: #06b1f8;
    --positive-gradient-end: #6adc8a;
    --negative-gradient-start: #ffcf08;
    --negative-gradient-end: #fe685b;
    --background-color: #fff;
    --text-color: #000;
    --light-gray: #eee;
    --medium-gray: #ccc;
    --dark-gray: #000;
    --error-color: #fe3a2f;
    
    /* Typography */
    --font-family: 'Poppins', sans-serif;
    
    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    
    /* Border Radius */
    --border-radius-sm: 4px;
    --border-radius-md: 8px;
    --border-radius-lg: 12px;
    --border-radius-round: 50%;
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-medium: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.1);
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-family);
}

html, body {
    width: 100%;
    height: 100%;
    overflow-x: hidden;
    background-color: var(--background-color);
    color: var(--text-color);
    -webkit-tap-highlight-color: transparent;
}

a {
    text-decoration: none;
    color: inherit;
}

button, input, select {
    font-family: inherit;
    font-size: inherit;
    border: none;
    outline: none;
    background: none;
}

ul, ol {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

.hidden {
    display: none !important;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light-gray);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--medium-gray);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--dark-gray);
}

.blurred {
    filter: blur(4px);
    pointer-events: none; /* Empêche tout clic */
}

#loader {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10000; /* Assurez-vous qu'il est au-dessus de tout le reste */
    opacity:0.1;
}

/* ===============================================
   LAYOUT
   =============================================== */
.app-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    min-height: 100%;
    display: none;
    flex-direction: column;
}

/* ===============================================
   BUTTONS
   =============================================== */
.to_pdc {
    color:#6adc8a;
    font-weight:bold;
}
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: transform var(--transition-fast), background-color var(--transition-fast), box-shadow var(--transition-fast);
    text-align: center;
}

.primary-btn {
    background: linear-gradient(90deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 1rem 2rem;
    font-size: 1.25rem;
    display: block;
    width: 100%;
    max-width: 400px;
    margin: 20px auto 20px;
    position: sticky;
    bottom: 80px;
    z-index: 10;
    box-shadow: 0 4px 20px rgba(106, 220, 138, 0.4);
}


.primary-btn:hover {
    background: linear-gradient(90deg, var(--primary-light), var(--primary-color));
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.secondary-btn {
    background-color: var(--light-gray);
    color: var(--secondary-color);
}

.secondary-btn:hover {
    background-color: var(--medium-gray);
}

.back-btn {
    display: inline-flex;
    align-items: center;
    background-color: var(--dark-gray);
    color: white;
    padding: 0.5rem 1rem;
}

.back-btn .icon-back {
    margin-right: 0.5rem;
    background: url('img/arrow_left.png') center no-repeat;
    background-size: contain;
    width: 16px;
    height: 16px;
    display: inline-block;
}

.download-btn {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(90deg, var(--negative-gradient-start), var(--negative-gradient-end));
    color: white;
    padding: 0.5rem 1rem;
    margin-left: var(--spacing-md);
}

.download-btn .icon-download {
    margin-right: 0.5rem;
    background: url('img/arrow_right.png') center no-repeat;
    background-size: contain;
    width: 16px;
    height: 16px;
    display: inline-block;
    animation: pulse 1s infinite;
}

.icon-arrow {
    margin-left: 0.5rem;
    background: url('img/arrow_right.png') center no-repeat;
    background-size: contain;
    width: 16px;
    height: 16px;
    display: inline-block;
}

/* ===============================================
   PROGRESS BAR (fixed full-width at top)
   =============================================== */
.progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: #ffffff;
    z-index: 1000;
    display: none;
}

.progress-bar-fill {
    height: 100%;
    width: 0%;
    background: var(--primary-color);
    transition: width 0.5s ease;
    border-radius: 0 3px 3px 0;
}

/* ===============================================
   HEADER (sticky, gradient blur)
   =============================================== */
.app-header {
    position: sticky;
    top: 0;
    z-index: 20;
    padding: 0;
    padding-bottom: 8px;
}

/* Gradient blur backdrop — always active, full viewport width, no color */
.app-header::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    backdrop-filter: blur(36px);
    -webkit-backdrop-filter: blur(36px);
    -webkit-mask-image: linear-gradient(to bottom, black 0%, black 60%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 0%, black 60%, transparent 100%);
    z-index: -1;
    pointer-events: none;
}

.header-top {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 8px;
    position: relative;
    z-index: 1;
}

.header-controls {
    display: flex;
    flex-shrink: 0;
}

.header-info {
    flex: 1;
    min-width: 0;
}

.header-title {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.1;
    white-space: normal;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: font-size 0.3s ease;
}

.header-text {
    font-size: 0.95rem;
    color: var(--secondary-color);
    line-height: 1.3;
    max-height: 60px;
    overflow: hidden;
    transition: all 0.3s ease;
}

/* Compact header when scrolled */
.app-header.scrolled .header-title {
    font-size: 1rem;
}

.app-header.scrolled .header-text {
    font-size: 0.8rem;
    max-height: 20px;
    opacity: 0.7;
}

@media (max-width: 600px) {
    .header-title {
        font-size: 1rem;
        white-space: normal;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
        line-height: 1.15;
    }
    .header-text { font-size: 0.8rem; }
    .header-top { padding: 8px 10px; gap: 8px; }
    .back-btn {
        padding: 0.4rem;
        min-width: 36px;
        min-height: 36px;
        justify-content: center;
    }
    .back-btn .icon-back {
        margin-right: 0;
    }
    .back-btn .back-btn-text {
        display: none;
    }
    /* Hide header download button on mobile — download-cta in detailed results replaces it */
    .download-btn {
        display: none !important;
    }
    .download-btn .icon-download {
        margin-right: 4px;
    }
    #header-download-text {
        display: none;
    }
    /* Header controls shrink — give space to title */
    .header-controls {
        flex-shrink: 0;
    }
    .header-info {
        text-align: left;
    }
}

/* ===============================================
   FOOTER
   =============================================== */
.app-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: calc(60px + env(safe-area-inset-bottom, 0px));
    background: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--spacing-lg);
    padding-bottom: env(safe-area-inset-bottom, 0px);
    box-shadow: var(--shadow-md);
    z-index: 50;
}

.app-footer .logo {
    width: 200px;
    height: 45px;
    background: url('img/logo_amarok.png') center no-repeat;
    background-size: contain;
}

.app-footer .logo.logo-partner {
    position:absolute;
    margin-left: 200px;
}

.app-footer .privacy-policy {
    font-size: 0.9rem;
    color: var(--secondary-color);
    cursor: pointer;
}

.app-footer .privacy-policy:hover {
    text-decoration: underline;
}

/* ===============================================
   MODAL COMPONENTS
   =============================================== */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 100;
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    z-index: 110;
    max-width: 90vw;
    max-height: 90vh;
    overflow: auto;
}

.modal-content {
    padding: var(--spacing-lg) var(--spacing-md);
}

.modal h2 {
    font-size: 1.75rem;
    margin-bottom: var(--spacing-lg);
    color: var(--primary-color);
}

.modal h3 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-md);
}

.modal-text {
    margin-bottom: var(--spacing-lg);
    line-height: 1.6;
}

.consent-modal, .no-consent-modal {
    width: 700px;
    max-width: calc(100vw - 32px);
}

/* Consent modal buttons should not be sticky */
.consent-modal .primary-btn,
.no-consent-modal .primary-btn {
    position: static;
    box-shadow: none;
}

.result-modal {
    width: 600px;
    max-width: calc(100vw - 32px);
    display: flex;
    flex-direction: column;
}

.result-modal .modal-content {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding-bottom: 0;
}

/* Scrollable text area */
.result-modal #modal-positive-text {
    flex: 1;
    overflow-y: auto;
    padding-bottom: 16px;
    -webkit-mask-image: linear-gradient(to bottom, black 0%, black 85%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 0%, black 85%, transparent 100%);
}

/* Fixed button at bottom of result modal — full width edge-to-edge */
.result-modal #close-result-modal {
    flex-shrink: 0;
    position: sticky;
    bottom: 0;
    padding: 16px 24px;
    border-radius: 0;
    /* Override .primary-btn constraints */
    max-width: none;
    width: calc(100% + 2 * var(--spacing-md));
    margin: 0 0 0 calc(-1 * var(--spacing-md));
    box-sizing: border-box;
}

.error-message {
    color: var(--error-color);
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    display: none;
}

.error-message.visible {
    display: block;
}

.legal-info {
    font-size: 0.8rem;
    color: var(--dark-gray);
    margin-top: var(--spacing-lg);
    line-height: 1.4;
}

/* Consent Summary */
.consent-summary {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
    padding: 16px;
    background: #f8faf8;
    border-radius: 12px;
}

.consent-point {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.consent-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    color: var(--primary-color);
}

.consent-point p {
    font-size: 0.9rem;
    color: #555;
    margin: 4px 0 0;
}

.consent-option {
    display: flex;
    align-items: flex-start;
    margin-bottom: var(--spacing-md);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-md);
    cursor: pointer;
    transition: background-color var(--transition-fast);
}

.consent-option:hover {
    background-color: var(--light-gray);
}

.consent-option input[type="radio"] {
    display: none;
}

.radio-custom {
    width: 22px;
    height: 22px;
    border: 2px solid var(--medium-gray);
    border-radius: 50%;
    flex-shrink: 0;
    margin-right: var(--spacing-md);
    transition: all 0.2s;
    position: relative;
}

.consent-option input[type="radio"]:checked + .radio-custom {
    border-color: var(--primary-color);
    background: var(--primary-color);
}

.consent-option input[type="radio"]:checked + .radio-custom::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: white;
}

.consent-option .option-text {
    flex: 1;
    line-height: 1.5;
}

/* ===============================================
   STEP SECTIONS
   =============================================== */
/* Step transitions — smooth fade-in / slide-up */
.step-section {
    flex: 1;
    display: none;
    padding: var(--spacing-sm) var(--spacing-sm);
}

.step-section.active {
    display: block;
    animation: stepEnter 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes stepEnter {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Step 0 - Introduction */
.intro-container {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
    padding: var(--spacing-xl) 0 0;
}

/* Start button: not sticky, sits at bottom */
#step0 .primary-btn {
    position: static;
    box-shadow: 0 4px 20px rgba(106, 220, 138, 0.4);
    margin-bottom: 0;
    font-size: 1.3rem;
    padding: 1.1rem 2.5rem;
}

.intro-image {
    width: 160px;
    height: 160px;
    border-radius:80px;
    margin: 0 auto var(--spacing-xl);
    background:url('img/intro.png') center no-repeat;
    background-size: contain;
}
.intro-images {
  display: flex;
  justify-content: center;
  position: relative;
  margin-top:20px;
  margin-bottom:30px;
}

.intro-images .intro-image {
  margin: 0;
}

.intro-images .intro-image + .intro-image {
  margin-left: -20px; /* chevauchement de 5px */
}

.intro-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: var(--spacing-lg);
    line-height: 1.15;
}

.intro-text {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: var(--spacing-xl);
}

.reference {
    font-size: 0.8rem;
    color: var(--dark-gray);
    margin-top: var(--spacing-md);
    line-height: 1.4;
}

/* Step 0 reference: small, below button */
#step0 .reference {
    margin-top: var(--spacing-sm);
    margin-bottom: 70px;
}

.reference a {
    color: var(--dark-gray);
}

.reference a:hover {
    text-decoration: underline;
}

.detailed-results .reference{
    padding-bottom:100px;
}

/* Step 1 - Demographics Form */
.form-container {
    max-width: 600px;
    margin: 0 auto;
    padding-bottom: 80px;
}

.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
}

.form-input, .form-select {
    width: 100%;
    padding: var(--spacing-md);
    background-color: var(--light-gray);
    border-radius: var(--border-radius-md);
    font-size: 1rem;
    color: #222;
}

.form-select option {
    color: #222;
    background: #fff;
}

.form-select {
    appearance: none;
    background-image: url('data:image/svg+xml;utf8,<svg fill="black" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/><path d="M0 0h24v24H0z" fill="none"/></svg>');
    background-repeat: no-repeat;
    background-position: right var(--spacing-md) center;
}

/* Form Sections */
fieldset.form-section {
    border: none;
    padding: 0;
    margin: 0 0 24px;
}

/* ===============================================
   FORM CARD MODE — 1 question per screen
   =============================================== */
.form-card-mode .form-container {
    padding-bottom: 40px;
}

.form-card-mode fieldset.form-section {
    display: none !important;
}

.form-card-mode .form-group {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 32px 20px;
    margin-bottom: 0;
    animation: stepEnter 0.35s ease both;
    min-height: 40vh;
}

.form-card-mode .form-group.active-card {
    display: flex;
}

.form-card-mode .form-group label {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 24px;
    line-height: 1.3;
    max-width: 480px;
}

.form-card-mode .form-group .form-input,
.form-card-mode .form-group .form-select {
    max-width: 360px;
    font-size: 1.1rem;
    padding: 14px 16px;
    text-align: center;
}

.form-card-mode .form-group .toggle-group {
    max-width: 360px;
    width: 100%;
    gap: 12px;
}

.form-card-mode .form-group .toggle-btn {
    padding: 14px;
    font-size: 1.1rem;
}

.form-card-mode .form-group .field-error {
    margin-top: 8px;
}

/* Progress ring for form */
.form-progress-ring {
    position: relative;
    width: 56px;
    height: 56px;
    margin: 0 auto 20px;
}

.form-progress-ring svg {
    transform: rotate(-90deg);
}

.form-progress-ring .ring-bg {
    fill: none;
    stroke: #eee;
    stroke-width: 4;
}

.form-progress-ring .ring-fill {
    fill: none;
    stroke: var(--primary-color);
    stroke-width: 4;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.4s ease;
}

.form-progress-label {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    color: #333;
}

/* Card nav buttons */
.form-card-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    margin-top: 16px;
}

.form-card-back {
    background: none;
    border: none;
    cursor: pointer;
    color: #999;
    font-size: 0.85rem;
    padding: 8px 16px;
    border-radius: 8px;
    transition: background-color 0.2s, color 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.form-card-back:hover {
    background-color: #f0f0f0;
    color: #555;
}

.form-card-back svg {
    width: 16px;
    height: 16px;
}

/* Hide original next-from-form in card mode — replaced by auto-advance */
.form-card-mode #next-from-form {
    display: none;
}

.form-card-mode #form-error {
    display: none;
}

.form-section-title {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--light-gray);
}

.form-section-highlight {
    background: #f8faf8;
    padding: 20px;
    border-radius: 12px;
}

.form-section-highlight .form-section-title {
    border-bottom: none;
}

.form-section-highlight label {
    font-size: 1.1rem;
}

.field-error {
    display: none;
    font-size: 0.8rem;
    color: var(--error-color);
    margin-top: 4px;
}

.field-error.visible {
    display: block;
}

.form-input.error, .form-select.error {
    border: 2px solid var(--error-color);
}

.toggle-group.error {
    border: 2px solid var(--error-color);
    border-radius: var(--border-radius-md);
}

.toggle-group {
    display: flex;
    gap: var(--spacing-sm);
}

.toggle-btn {
    flex: 1;
    padding: var(--spacing-md);
    background-color: var(--light-gray);
    border-radius: var(--border-radius-md);
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    transition: background-color var(--transition-fast), color var(--transition-fast);
}

.toggle-btn:hover {
    background-color: var(--medium-gray);
}

.toggle-btn.selected {
    background-color: var(--primary-color);
    color: white;
}

/* Steps 2 & 4 - Events Selection */
.events-container {
    padding-bottom: 100px; /* Footer space */
}

/* Events "suivant" button: not sticky, at bottom of list */
.events-container .primary-btn {
    position: static;
    box-shadow: 0 4px 20px rgba(106, 220, 138, 0.4);
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
}

.event-card {
    /* Hauteur fixe pour toutes les cartes */
    height: 180px;

    /* Mise en page en flex */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;

    position: relative;
    border-radius: var(--border-radius-md);
    overflow: hidden;
    cursor: pointer;
    transition: transform var(--transition-fast), background-color var(--transition-fast);
    background-color: rgba(255, 255, 255, 0.2);
}

.event-card.positive:hover {
    background-color: rgba(106, 220, 138, 0.3);
}

.event-card.negative:hover {
    background-color: rgba(254, 104, 91, 0.3);
}

.event-card.selected.positive {
    background-color: var(--positive-gradient-end);
    animation: cardBounce 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.event-card.selected.negative {
    background-color: var(--negative-gradient-end);
    animation: cardBounce 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes cardBounce {
    0%   { transform: scale(1); }
    40%  { transform: scale(1.06); }
    100% { transform: scale(1); }
}

.event-icon {
    /* L'icône prend l'espace libre au milieu */
    flex: 1; 
    width: 60%;
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
    margin-top: var(--spacing-md); /* Ajustez selon vos préférences */
}

.event-name {
    width: 100%;
    min-height: 52px;
    background-color: rgba(255, 255, 255, 0.8);
    padding: 6px 4px;
    font-size: 0.8rem;
    font-weight: 600;
    text-align: center;
    line-height: 1.25;
    transition: background-color var(--transition-fast), color var(--transition-fast);
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    text-overflow: ellipsis;
    word-break: break-word;
    hyphens: auto;
}

.event-card.selected .event-name {
    background-color: rgba(255, 255, 255, 0.15);
    color: white;
}

/* Events Toolbar */
.events-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    gap: 12px;
    flex-wrap: wrap;
}

.events-counter {
    font-weight: 600;
    font-size: 0.95rem;
    color: white;
    background: rgba(0, 0, 0, 0.2);
    padding: 6px 14px;
    border-radius: 20px;
}

.events-counter span:first-child {
    font-size: 1.2rem;
}

#global-scroll-indicator {
    display: none;
    position: fixed;
    bottom: 80px;
    left: 50%;
    width: 44px;
    height: 44px;
    margin-left: -22px;
    background-color: rgba(0, 0, 0, 0.55);
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 12px rgba(0,0,0,0.2);
    z-index: 2147483647;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    animation: bounce 2s infinite;
}
#global-scroll-indicator.show {
    display: flex !important;
}

.icon-scroll {
    width: 20px;
    height: 20px;
    background: url('img/arrow_bottom.png') center no-repeat;
    background-size: contain;
    display: inline-block;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

/* Steps 3 & 5 - Score Display */
.score-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    min-height: 100dvh;
    padding: 60px 16px 80px;
    box-sizing: border-box;
    gap: 24px;
}

.score-container .btn.primary-btn {
    flex-shrink: 0;
    width: 80%;
    max-width: 400px;
}

/* SVG Thermometer — aspect-ratio matches viewBox 260/440 */
.thermometer {
    position: relative;
    aspect-ratio: 260 / 440;
    height: clamp(280px, 58dvh, 560px);
    max-height: calc(100dvh - 220px);
    flex-shrink: 0;
}

.thermometer-svg {
    width: 100%;
    height: 100%;
    display: block;
}

/* Fill animation via clip-path — starts fully clipped (hidden) */
.thermometer-fill-rect {
    clip-path: inset(100% 0% 0% 0%);
    transition: clip-path 2s ease-out;
}

/* Score value centered over the capsule (dark on white background) */
.score-value {
    position: absolute;
    top: 50%;
    left: 53.8%;
    transform: translate(-50%, -50%);
    text-align: center;
    font-family: var(--font-family);
    font-size: 2.6rem;
    font-weight: 700;
    color: #333;
    z-index: 5;
}

/* White score overlay — full-size so clip-path % matches thermometer */
.score-value-white {
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-left: 7.6%;
    box-sizing: border-box;
    color: #fff;
    clip-path: inset(100% 0% 0% 0%);
    transition: clip-path 2s ease-out;
}

@media (max-width: 480px) {
    .thermometer {
        height: clamp(250px, 55dvh, 450px);
    }
    .score-value {
        font-size: 2rem;
    }
}

/* Step 6 - Results */
/* ---- Step 6: Balance Results — fits 100dvh ---- */
.balance-scale {
    text-align: center;
    padding: 8px 16px 100px; /* 100px bottom for fixed burnout-invitation */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: calc(100dvh - 100px);
    box-sizing: border-box;
}

.overall-score {
    font-size: 3.8rem;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 2px;
    color: var(--primary-color);
    transition: color 0.5s;
}

.overall-score.positive {
    color: var(--primary-color);
}

.overall-score.negative {
    color: var(--negative-gradient-end);
}

.result-message {
    max-width: 600px;
    margin: 0 auto 8px;
    line-height: 1.5;
    padding: 8px 12px;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: var(--border-radius-md);
    font-size: 0.9rem;
    display: none;
}

.result-message.active {
    display: block;
}

/* ---- Modern Balance ---- */
.scale-visualization {
    position: relative;
    width: 100%;
    height: 220px;
    flex-shrink: 0;
}

.modern-balance {
    --tilt: 0;
    position: relative;
    width: 100%;
    max-width: 380px;
    height: 100%;
    margin: 0 auto;
}

.balance-arm {
    position: absolute;
    top: 50px;
    left: 10%;
    width: 80%;
    height: 4px;
    background: #bbb;
    border-radius: 3px;
    transform-origin: center center;
    transform: rotate(calc(var(--tilt) * 1deg));
    transition: transform 2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.plate-wrapper {
    position: absolute;
    top: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.plate-wrapper-left {
    left: -30px;
}

.plate-wrapper-right {
    right: -30px;
}

.positive-plate, .negative-plate {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 1.05rem;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
    transform: rotate(calc(var(--tilt) * -1deg));
    transition: transform 2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.positive-plate {
    background: linear-gradient(135deg, var(--positive-gradient-start), var(--positive-gradient-end));
}

.negative-plate {
    background: linear-gradient(135deg, var(--negative-gradient-start), var(--negative-gradient-end));
}

.plate-score {
    color: white;
}

.plate-label {
    margin-top: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    color: #999;
    white-space: nowrap;
    transform: rotate(calc(var(--tilt) * -1deg));
    transition: transform 2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.balance-stand {
    position: absolute;
    top: 48px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.balance-pivot {
    display: none;
}

.balance-pillar {
    width: 4px;
    height: 110px;
    background: #bbb;
    border-radius: 2px;
}

.balance-foot {
    width: 60px;
    height: 4px;
    background: #bbb;
    border-radius: 3px;
}

.detailed-results {
    display: none;
    padding: var(--spacing-lg);
    padding-bottom: 140px; /* space for fixed burnout-invitation + footer */
}
.detailed-results.active {
    display: block !important;
}

/* Download CTA — mobile only, full width */
.download-cta {
    display: none; /* hidden on desktop */
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 16px 24px;
    margin-bottom: var(--spacing-lg);
    background: linear-gradient(90deg, var(--primary-color), var(--primary-dark));
    color: #fff !important;
    font-size: 1.1rem;
    font-weight: 700;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(106, 220, 138, 0.35);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.download-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(106, 220, 138, 0.5);
}
.download-cta:active {
    transform: translateY(0);
}
.download-cta-icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    color: #fff;
}
.download-cta #download-cta-text {
    color: #fff;
}
@media (max-width: 600px) {
    .download-cta {
        display: flex;
    }
}

.result-tabs {
    display: none; /* Will be shown on mobile */
    margin-bottom: var(--spacing-lg);
}

.tab-btn {
    padding: var(--spacing-md) var(--spacing-lg);
    font-weight: 600;
    background-color: var(--light-gray);
    border-radius: var(--border-radius-md) var(--border-radius-md) 0 0;
}

.tab-btn.active {
    background-color: white;
    border-bottom: 3px solid var(--primary-color);
}

.result-section {
    margin-bottom: var(--spacing-xl);
}
#positive-results,
#negative-results {
  display: inline-block;
  width: 48%;
  vertical-align: top;
  box-sizing: border-box;
}


.section-title {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-md);
}

.events-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.event-item {
    display: flex;
    align-items: center;
    padding: var(--spacing-sm);
    background-color: var(--light-gray);
    border-radius: var(--border-radius-md);
}

.event-item-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--border-radius-round);
    margin-right: var(--spacing-md);
    background-position: center;
    background-repeat: no-repeat;
    background-size: 70%;
}

.positive-item .event-item-icon {
    background-color: var(--positive-gradient-end);
}

.negative-item .event-item-icon {
    background-color: var(--negative-gradient-end);
}

.event-item-details {
    flex: 1;
}

.event-item-name {
    font-weight: 600;
    margin-bottom: var(--spacing-xs);
}

.event-item-score {
    font-size: 0.9rem;
    color: var(--dark-gray);
}

.event-item-bar {
    height: 5px;
    background-color: var(--medium-gray);
    margin-top: var(--spacing-xs);
    border-radius: var(--border-radius-sm);
    overflow: hidden;
}

.positive-item .event-item-bar-fill {
    height: 100%;
    background: linear-gradient(to right, var(--positive-gradient-start), var(--positive-gradient-end));
}

.negative-item .event-item-bar-fill {
    height: 100%;
    background: linear-gradient(to right, var(--negative-gradient-start), var(--negative-gradient-end));
}

/* ===============================================
   BURNOUT INVITATION — sticky CTA
   =============================================== */
.burnout-invitation {
    display: none;
    position: fixed;
    bottom: calc(60px + env(safe-area-inset-bottom, 0px));
    left: 0;
    right: 0;
    z-index: 55;
    width: 100%;
    padding: 16px 24px;
    background: #fff;
    box-shadow: 0 -2px 20px rgba(0, 0, 0, 0.1);
    border-top: 2px solid var(--primary-color);
}

.burnout-invitation.active {
    display: flex !important;
    flex-direction: column;
    gap: 12px;
    opacity: 1;
    transform: translateY(0);
    animation: burnoutInvSlideUp 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes burnoutInvSlideUp {
    from { opacity: 0; transform: translateY(100%); }
}

/* Top row: icon + content */
.burnout-inv-top {
    display: flex;
    align-items: center;
    gap: 14px;
}

/* Icon */
.burnout-inv-icon {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    background: linear-gradient(135deg, #df8650, #e9a800);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.burnout-inv-icon svg {
    width: 22px;
    height: 22px;
    color: #fff;
}

/* Content block */
.burnout-inv-content {
    flex: 1;
    min-width: 0;
}

/* Badge */
.burnout-inv-badge {
    display: inline-block;
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #b86e1a;
    background: rgba(233, 168, 0, 0.12);
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 4px;
}

/* Text */
.burnout-inv-text {
    font-size: 0.88rem;
    line-height: 1.4;
    color: #555;
    margin: 0;
}

/* CTA Button */
.burnout-inv-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px 24px;
    font-size: 1.05rem;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(90deg, #df8650, #d4712a);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 16px rgba(223, 134, 80, 0.35);
    font-family: var(--font-family);
}

.burnout-inv-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(223, 134, 80, 0.5);
}

.burnout-inv-cta:active {
    transform: translateY(0);
}

.burnout-inv-cta-arrow {
    width: 18px;
    height: 18px;
    transition: transform 0.2s ease;
}

.burnout-inv-cta:hover .burnout-inv-cta-arrow {
    transform: translateX(4px);
}

/* ---- MOBILE: burnout-invitation redesign ---- */
@media (max-width: 600px) {
    .burnout-invitation {
        bottom: calc(56px + env(safe-area-inset-bottom, 0px));
        padding: 0;
        border-top: none;
        background: linear-gradient(160deg, #f0faf3 0%, #fff 60%, #e6f7eb 100%);
        box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.12);
        border-radius: 18px 18px 0 0;
        overflow: hidden;
    }

    .burnout-invitation.active {
        gap: 8px;
    }

    .burnout-inv-top {
        padding: 14px 16px 0;
        gap: 10px;
        align-items: flex-start;
    }

    .burnout-inv-icon {
        width: 36px;
        height: 36px;
        background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
        animation: burnoutIconPulse 2s ease-in-out infinite;
    }

    .burnout-inv-icon svg {
        width: 18px;
        height: 18px;
        color: #fff;
    }

    .burnout-inv-badge {
        display: none;
    }

    .burnout-inv-text {
        font-size: 0.82rem;
        line-height: 1.4;
        color: #444;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
        margin: 0;
    }

    .burnout-inv-cta {
        margin: 0 12px 12px;
        width: calc(100% - 24px);
        padding: 13px 20px;
        font-size: 1rem;
        border-radius: 10px;
        background: linear-gradient(90deg, var(--primary-color), var(--primary-dark));
        box-shadow: 0 4px 16px rgba(106, 220, 138, 0.35);
        animation: burnoutCtaGlow 2.5s ease-in-out infinite;
    }

    .burnout-inv-cta:active {
        transform: scale(0.97);
    }

    .burnout-inv-cta-arrow {
        animation: burnoutArrowBounce 1.5s ease-in-out infinite;
    }

    @keyframes burnoutIconPulse {
        0%, 100% { transform: scale(1); }
        50% { transform: scale(1.1); }
    }

    @keyframes burnoutCtaGlow {
        0%, 100% { box-shadow: 0 4px 16px rgba(106, 220, 138, 0.35); }
        50% { box-shadow: 0 4px 24px rgba(106, 220, 138, 0.6); }
    }

    @keyframes burnoutArrowBounce {
        0%, 100% { transform: translateX(0); }
        50% { transform: translateX(5px); }
    }
}

/* Background Transitions */
.app-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    min-height: 100%;
    display: none;
    flex-direction: column;
    z-index: 1;
}

/* Pseudo-élément pour le fond en pleine largeur */
.app-container::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(160deg, #f0faf3 0%, #fff 40%, #f5f5f5 100%);
    transition: background 0.8s ease;
    z-index: -1;
}

/* Gradient bleu pour la classe .blue */
.app-container.blue::before {
    background: linear-gradient(0deg, rgba(6, 177, 248, 0.4) 0%, rgba(106, 220, 138, 0.7) 100%) !important;
}

/* Gradient rouge pour la classe .red */
.app-container.red::before {
    background: linear-gradient(0deg, rgba(255, 207, 8, 0.5) 0%, rgba(254, 104, 91, 0.6) 100%) !important;
}
/**/
.app-container.burnout-gradient::before {
    background: linear-gradient(to bottom, white, #eee) !important;
}

/* ===============================================
   MEDIA QUERIES
   =============================================== */
@media (max-width: 1200px) {
    .events-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 1024px) {
    .events-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .events-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .result-tabs {
        display: none;
    }

    #positive-results,
    #negative-results {
        display: block;
        width: 100%;
    }

    .detailed-results {
        padding: var(--spacing-md);
    }

    .app-footer {
        padding: 0 var(--spacing-sm);
        gap: 8px;
    }

    .app-footer .logo {
        width: 100px;
        flex-shrink: 0;
    }

    .app-footer .logo.logo-partner {
        position: static;
        margin-left: 0;
        width: 80px;
    }

    .app-footer .privacy-policy {
        font-size: 0.7rem;
        flex-shrink: 1;
        text-align: right;
        min-width: 0;
    }
}

@media (max-width: 480px) {
    .events-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .event-card {
        height: 150px;
    }

    .event-name {
        font-size: 0.7rem;
        min-height: 44px;
        padding: 4px 3px;
        -webkit-line-clamp: 3;
    }

    .thermometer {
        height: 300px;
    }

    .score-value {
        font-size: 2rem;
    }

    .header-title {
        font-size: 1.1rem;
    }

    .header-text {
        font-size: 0.85rem;
    }

    .btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }

    .primary-btn {
        padding: 0.9rem 1.5rem;
        font-size: 1.1rem;
        bottom: 72px;
    }

    .balance-scale {
        padding: 4px 12px 8px;
        min-height: auto;
    }

    .overall-score {
        font-size: 2.6rem;
        margin-bottom: 0;
    }

    .result-message {
        padding: 6px 10px;
        font-size: 0.85rem;
        margin-bottom: 4px;
    }

    .scale-visualization {
        height: 180px;
    }

    .balance-arm {
        width: 90%;
        left: 5%;
        top: 40px;
    }

    .balance-stand {
        top: 38px;
    }

    .balance-pillar {
        height: 85px;
    }

    .positive-plate, .negative-plate {
        width: 56px;
        height: 56px;
        font-size: 0.9rem;
    }

    .plate-wrapper-left { left: -22px; }
    .plate-wrapper-right { right: -22px; }

    .overall-score {
        font-size: 3rem;
    }

}

/* ===============================================
   ANIMATIONS
   =============================================== */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

@keyframes highlight {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.highlight {
    animation: highlight 0.5s ease;
}



/* Burnout Assessment Styles */
.burnout-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0.5rem 0.5rem 100px;
}

.burnout-title {
    font-size: 1.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 0.5rem;
    line-height: 1.1;
}

.burnout-instruction {
    font-size: 1.1rem;
    text-align: center;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.score-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.25rem;
    margin-bottom: 1rem;
}

.score-item {
    display: flex;
    align-items: center;
    margin: 0 0.25rem;
    font-size: 0.8rem;
}

.score-item span {
    display: inline-block;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    background-color: var(--primary-color);
    color: white;
    text-align: center;
    line-height: 24px;
    margin-right: 0.25rem;
    font-weight: 600;
}

.burnout-questions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.burnout-question {
    --q-text: #444;
    --q-muted: #999;
    --q-btn-border: #ddd;
    --q-btn-color: #888;
    border-radius: 12px;
    padding: 1.25rem;
    transition: all 0.3s ease;
    background-color: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    color: var(--q-text);
}

.burnout-question.completed {
    --q-text: #1a5c2e;
    --q-muted: #3a8a55;
    --q-btn-border: rgba(106, 220, 138, 0.6);
    --q-btn-color: #2e7d46;
    background-color: #dff5e6;
    border: 2px solid var(--primary-color);
    box-shadow: 0 1px 6px rgba(106, 220, 138, 0.25);
}

.question-progress {
    font-size: 0.7rem;
    color: var(--q-muted);
    font-weight: 600;
    margin-bottom: 4px;
}

.scale-reminder {
    display: flex;
    justify-content: space-between;
    font-size: 0.7rem;
    color: var(--q-muted);
    margin-top: 4px;
    padding: 0 2px;
}

.question-text {
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--q-text);
}

.rating-buttons {
    display: flex;
    gap: 6px;
    flex-wrap: nowrap;
    justify-content: space-between;
}

.rating-btn {
    flex: 1;
    min-width: 40px;
    height: 44px;
    border-radius: 8px;
    background-color: transparent;
    border: 1.5px solid var(--q-btn-border);
    color: var(--q-btn-color);
    font-size: 0.95rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
}

.rating-btn:hover {
    border-color: var(--q-btn-color);
    color: var(--q-text);
    background-color: rgba(0, 0, 0, 0.03);
}

.rating-btn.selected {
    background-color: #2d7aef;
    border-color: #2d7aef;
    color: white;
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(45, 122, 239, 0.3);
}

/* Burnout Results Styles */
.burnout-results {
    display: none;
    max-width: 520px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.results-card {
    background: white;
    border-radius: 20px;
    padding: 2.5rem 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Subtle top gradient accent */
.results-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    border-radius: 20px 20px 0 0;
    background: var(--primary-color);
    transition: background 0.3s ease;
}

.results-card.medium-risk::before {
    background: linear-gradient(90deg, #f0c040, #e9a800);
}

.results-card.high-risk::before {
    background: linear-gradient(90deg, #e87040, #df8650);
}

/* Risk icon at top */
.burnout-risk-icon {
    margin: 0 auto 1rem;
}

.burnout-risk-icon svg {
    width: 56px;
    height: 56px;
}

/* Results heading */
.burnout-results-heading {
    font-size: 1.3rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 1.5rem;
}

/* Score ring */
.burnout-score-ring {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 2px;
    margin: 0 auto 0.5rem;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f8faf8, #edf7f0);
    border: 3px solid var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.3s ease;
}

.results-card.medium-risk .burnout-score-ring {
    background: linear-gradient(135deg, #fffdf0, #fef8e0);
    border-color: #e9a800;
}

.results-card.high-risk .burnout-score-ring {
    background: linear-gradient(135deg, #fff5f0, #fef0e8);
    border-color: #df8650;
}

.burnout-score-value {
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
    position: relative;
}

.results-card.medium-risk .burnout-score-value {
    color: #e9a800;
}

.results-card.high-risk .burnout-score-value {
    color: #df8650;
}

.burnout-score-max {
    font-size: 1.1rem;
    font-weight: 600;
    color: #aaa;
    margin-left: 2px;
}

/* Risk label */
.burnout-risk-label {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 1rem 0;
    padding: 6px 16px;
    border-radius: 20px;
    display: inline-block;
}

.results-card.low-risk .burnout-risk-label {
    background: #edf7f0;
    color: #2d8a4e;
}

.results-card.medium-risk .burnout-risk-label {
    background: #fef8e0;
    color: #b8860b;
}

.results-card.high-risk .burnout-risk-label {
    background: #fef0e8;
    color: #c25a2a;
}

/* Result message */
.burnout-result-message {
    margin-top: 1.25rem;
    line-height: 1.7;
    font-size: 1rem;
    color: #555;
    text-align: left;
}

.burnout-result-message p {
    margin-bottom: 0.75rem;
}

.contact-intro {
    font-size: 0.95rem;
    color: #666;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--light-gray);
}

/* Contact button */
.contact-button {
    display: none;
    margin-top: 24px;
    padding: 18px 28px;
    background: linear-gradient(135deg, #e87040, #df8650);
    color: white;
    border-radius: 16px;
    font-weight: 700;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 6px 24px rgba(223, 134, 80, 0.3);
    align-items: center;
    gap: 12px;
}

.contact-button.active {
    display: flex;
    justify-content: center;
}

.contact-button p {
    margin: 0;
    flex: 1;
}

.contact-btn-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    opacity: 0.9;
}

.contact-btn-arrow {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.contact-button:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 32px rgba(223, 134, 80, 0.4);
}

.contact-button:hover .contact-btn-arrow {
    transform: translateX(4px);
}

.contact-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transition: left 0.5s ease;
}

.contact-button:hover::before {
    left: 100%;
}

/* ---------- Modal Vidéo - Style Moderne ---------- */

/* Overlay avec effet de flou */
.video_cover {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 900;
    background-color: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.video_cover.visible {
    opacity: 1;
    visibility: visible;
}

/* Container principal */
.video_wrapper {
    position: fixed;
    width: min(90%, 800px);
    max-height: min(90vh, 700px);
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 940;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.25);
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, -55%);
    transition: all 0.4s cubic-bezier(0.19, 1, 0.22, 1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.video_wrapper.visible {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%);
}

.video_wrapper.set1 {
    max-height: min(90vh, 600px);
}

/* Bouton de fermeture */
.video_wrapper .close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.15);
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 950;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video_wrapper .close::before,
.video_wrapper .close::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 2px;
    background-color: white;
    border-radius: 1px;
}

.video_wrapper .close::before {
    transform: rotate(45deg);
}

.video_wrapper .close::after {
    transform: rotate(-45deg);
}

.video_wrapper .close:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

/* Pied de page du modal */
.video_wrapper .vw_footer {
    width: 100%;
    padding: 18px 0;
    background: linear-gradient(to right, #2c3e50, #4ca1af);
    color: white;
    font-weight: 600;
    text-transform: uppercase;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: auto;
    letter-spacing: 1px;
    font-size: 15px;
}

.video_wrapper .vw_footer:hover {
    background: linear-gradient(to right, #314457, #55b3c2);
    letter-spacing: 2px;
}

/* Container du contenu */
.video_wrapper .vw_container {
    padding: 0;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
    flex: 1;
    display: flex;
    flex-direction: column;
    background: linear-gradient(135deg, #2c3e50, #1a1a2e);
}

.video_wrapper .vw_container::-webkit-scrollbar {
    width: 8px;
}

.video_wrapper .vw_container::-webkit-scrollbar-track {
    background: transparent;
}

.video_wrapper .vw_container::-webkit-scrollbar-thumb {
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

/* Titre du modal */
.video_wrapper .vw_container .title {
    color: white;
    padding: 30px 30px 20px;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), transparent);
}

.video_wrapper .vw_container .title p {
    color: white;
    font-weight: 700;
    font-size: 28px;
    margin: 0 0 8px 0;
    line-height: 1.2;
}

/* Container des vidéos */
.video_wrapper .vw_container .video_container {
    padding: 0 30px 30px;
    flex: 1;
    overflow-y: auto;
}

/* Étiquettes des vidéos */
.video_wrapper .vw_container .video_container .video_label {
    color: white;
    font-weight: 600;
    font-size: 18px;
    margin: 25px 0 10px;
    padding-left: 12px;
    border-left: 3px solid #4ca1af;
}

.video_wrapper .vw_container .video_container .video_label:first-child {
    margin-top: 0;
}

/* Container des iframes */
.video_wrapper .vw_container .video_container .video {
    position: relative;
    width: 100%;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    background-color: #111;
}

/* Maintenir le ratio des vidéos avec padding-bottom */
.video_wrapper .vw_container .video_container .video {
    padding-bottom: 56.25%; /* Ratio 16:9 */
    height: 0;
}

.video_wrapper .vw_container .video_container .video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Ajustements responsifs */
@media (max-width: 768px) {
    .video_wrapper {
        width: 95%;
    }
    
    .video_wrapper .vw_container .title {
        padding: 25px 20px 15px;
    }
    
    .video_wrapper .vw_container .title p {
        font-size: 24px;
    }
    
    .video_wrapper .vw_container .video_container {
        padding: 0 20px 20px;
    }
    
    .video_wrapper .vw_container .video_container .video_label {
        font-size: 16px;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translate(-50%, -40%); opacity: 0; }
    to { transform: translate(-50%, -50%); opacity: 1; }
}

.video_wrapper.animate-in {
    animation: slideUp 0.5s forwards;
}

.video_cover.animate-in {
    animation: fadeIn 0.3s forwards;
}

/* Contact Modal */
.contact-modal {
    max-width: 500px;
}

.modal-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1.5rem;
}

/* Animation for pulse effect */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Responsive adjustments for burnout section */
@media (max-width: 768px) {
    .score-legend {
        flex-direction: column;
        align-items: flex-start;
    }

    .rating-btn {
        min-width: 38px;
        height: 42px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .burnout-title {
        font-size: 1.5rem;
    }
    
    .burnout-instruction {
        font-size: 1.1rem;
    }
    
    .burnout-score-value {
        font-size: 2.2rem;
    }

    .burnout-score-ring {
        width: 110px;
        height: 110px;
    }

    .results-card {
        padding: 1.5rem 1rem;
    }
}

/* ===============================================
   THERMOMETER BUBBLES
   =============================================== */
.thermo-bubbles {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 4;
    border-radius: 50%;
}

.thermo-bubble {
    position: absolute;
    border-radius: 50%;
    background: rgba(255,255,255,0.4);
    animation: bubbleRise linear forwards;
    opacity: 0;
}

@keyframes bubbleRise {
    0%   { transform: translateY(0) scale(0.5); opacity: 0.7; }
    80%  { opacity: 0.3; }
    100% { transform: translateY(-400px) scale(1.2); opacity: 0; }
}

/* Thermometer shake when fill completes */
@keyframes thermoShake {
    0%, 100% { transform: rotate(0); }
    20%  { transform: rotate(-1.5deg); }
    40%  { transform: rotate(1.5deg); }
    60%  { transform: rotate(-1deg); }
    80%  { transform: rotate(0.5deg); }
}

.thermometer.shake {
    animation: thermoShake 0.5s ease;
}

/* ===============================================
   BALANCE RESULTS REDESIGN (Step 6)
   =============================================== */
.balance-label {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 4px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    line-height: 1.1;
}

.balance-label.positive { color: var(--primary-color); }
.balance-label.negative { color: var(--negative-gradient-end); }

.balance-summary {
    display: none;
}

.balance-actions {
    display: flex;
    justify-content: center;
    margin-top: 16px;
}

.balance-actions .btn {
    min-width: 240px;
    position: static;
}

/* secondary-outline-btn removed */

/* Comparative bars in detailed results */
.event-bar-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}

.event-bar-name {
    flex: 1;
    font-size: 0.85rem;
    min-width: 0;
}

.event-bar-track {
    width: 120px;
    height: 8px;
    background: #eee;
    border-radius: 4px;
    overflow: hidden;
    flex-shrink: 0;
}

.event-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.6s ease-out;
}

.event-bar-fill.positive { background: var(--primary-color); }
.event-bar-fill.negative { background: var(--negative-gradient-end); }

.event-bar-score {
    font-size: 0.8rem;
    font-weight: 600;
    width: 36px;
    text-align: right;
    flex-shrink: 0;
}

/* ===============================================
   BURNOUT GAMIFICATION — 1 question per screen
   =============================================== */
.burnout-card-mode .burnout-questions {
    position: relative;
    min-height: 50vh;
}

.burnout-card-mode .burnout-question {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px 20px;
    animation: stepEnter 0.35s ease both;
}

.burnout-card-mode .burnout-question.active-card {
    display: flex;
}

.burnout-card-mode .score-legend {
    display: none;
}

.burnout-card-mode .burnout-instruction {
    display: none;
}

/* Circular progress */
.burnout-progress-ring {
    position: relative;
    width: 64px;
    height: 64px;
    margin: 0 auto 12px;
}

.burnout-progress-ring svg {
    transform: rotate(-90deg);
}

.burnout-progress-ring .ring-bg {
    fill: none;
    stroke: #eee;
    stroke-width: 4;
}

.burnout-progress-ring .ring-fill {
    fill: none;
    stroke: var(--primary-color);
    stroke-width: 4;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.4s ease;
}

.burnout-progress-label {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
    color: #333;
}

.burnout-card-mode .question-text {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 32px;
    max-width: 500px;
    line-height: 1.5;
}

.burnout-card-mode .rating-buttons {
    gap: 8px;
    width: 100%;
    justify-content: center;
    flex-wrap: nowrap;
}

.burnout-card-mode .rating-btn {
    min-width: 0;
    width: calc((100% - 6 * 8px) / 7);
    max-width: 52px;
    min-height: 48px;
    font-size: 1.1rem;
    flex-shrink: 1;
}

.burnout-card-mode .scale-reminder {
    margin-top: 12px;
    font-size: 0.8rem;
    width: 100%;
}

/* Dot-plot recap before results */
.burnout-recap {
    display: none;
    flex-direction: column;
    align-items: center;
    padding: 30px 20px;
    animation: stepEnter 0.4s ease both;
}

.burnout-recap.active {
    display: flex;
}

.burnout-recap h3 {
    margin-bottom: 24px;
    font-size: 1.2rem;
}

.dot-plot {
    display: flex;
    gap: 8px;
    align-items: flex-end;
    height: 160px;
    padding: 0 20px;
}

.dot-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.dot-bar {
    width: 28px;
    border-radius: 4px 4px 0 0;
    transition: height 0.5s ease;
}

.dot-label {
    font-size: 0.7rem;
    color: #999;
    margin-top: 4px;
}

/* ===============================================
   BURNOUT GAUGE (semi-circular)
   =============================================== */
.burnout-gauge-wrapper {
    position: relative;
    width: 240px;
    height: 140px;
    margin: 0 auto 20px;
}

.burnout-gauge-wrapper svg {
    width: 100%;
    height: 100%;
}

.gauge-bg {
    fill: none;
    stroke: #eee;
    stroke-width: 18;
    stroke-linecap: round;
}

.gauge-fill {
    fill: none;
    stroke-width: 18;
    stroke-linecap: round;
    transition: stroke-dashoffset 2s ease-out, stroke 0.5s ease;
}

.gauge-needle {
    fill: #ddd;
    transform-origin: 120px 120px;
    transition: transform 2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gauge-center-dot {
    fill: #ddd;
}

.gauge-score-label {
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2.2rem;
    font-weight: 800;
    color: #222;
    z-index: 2;
}

.gauge-labels {
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    font-size: 0.7rem;
    color: #999;
}

/* Recommendations — removed */

/* ===============================================
   MOBILE KEYBOARD: scroll input into view
   =============================================== */
@media (max-width: 768px) {
    .form-input:focus, .form-select:focus {
        scroll-margin-bottom: 120px;
    }

    .score-container {
        padding: 40px 12px 80px;
    }
}

/* ===============================================
   FOCUS-VISIBLE (WCAG 2.4.7)
   =============================================== */
:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.btn:focus-visible {
    outline: 2px solid var(--primary-dark);
    outline-offset: 2px;
    box-shadow: 0 0 0 4px rgba(106, 220, 138, 0.25);
}

.rating-btn:focus-visible {
    outline: 2px solid #2d7aef;
    outline-offset: 1px;
}

.form-input:focus-visible, .form-select:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 0;
}

/* ===============================================
   PREFERS-REDUCED-MOTION
   =============================================== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}