/*
 * CSS SPÉCIFIQUE pour l'atelier "Changer un micro-comportement"
 * Ce fichier complète dispositif-mon-journal-datelier-extension.css (qui remplace homepage.css pour les ateliers)
 * et utilise la structure BEM.
 */

/* ========================================= */
/* 0. VARIABLES (Importées via dispositif-mon-journal-datelier-extension.css) */
/* ========================================= */
/*
  Ce fichier s'appuie sur les variables CSS définies dans :root,
  principalement dans 'dispositif-mon-journal-datelier-extension.css'.
  Exemples de variables utilisées ici :
  --tc-space-1, --tc-space-2, --tc-space-3, --tc-space-4, --tc-space-5, --tc-space-6, --tc-space-8, --tc-space-12
  --tc-font-sans, --tc-font-serif
  --tc-sage-50, --tc-sage-100, --tc-sage-200, --tc-sage-300, --tc-sage-400, --tc-sage-500, --tc-sage-600, --tc-sage-700, --tc-sage-800
  --tc-stone-50, --tc-stone-100, --tc-stone-200, --tc-stone-300, --tc-stone-400, --tc-stone-500, --tc-stone-600, --tc-stone-700, --tc-stone-800
  --tc-copper-400, --tc-copper-500, --tc-copper-600, --tc-copper-700
  --tc-shadow-xs, --tc-shadow-sm, --tc-shadow-md, --tc-shadow-lg
  --tc-transition-fast, --tc-transition-normal
*/

/* ========================================= */
/* 1. STYLES DE BASE ET AJUSTEMENTS GÉNÉRAUX */
/* (Complément aux styles génériques de .tedcraft-custom-page et .tc-*) */
/* ========================================= */

/* Ajustement spécifique du titre H1 de cet atelier (si dégradé unique) */
.tedcraft-custom-page h1#atelier-titre.tc-atelier-title-main {
    background: linear-gradient(135deg, var(--tc-stone-800) 0%, var(--tc-sage-700) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Ajustement de la description introductive (si spécifique) */
.tedcraft-custom-page .tc-intro-description {
    text-align: justify;
    max-width: 800px;
    margin-bottom: var(--tc-space-6);
}

/* Titre principal de chaque phase (H2) - Harmonisation avec .tc-title-1 si nécessaire */
.tedcraft-custom-page .etape-titre {
    font-family: var(--tc-font-serif);
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -0.015em;
    color: var(--tc-stone-800);
    text-align: center;
    margin-bottom: var(--tc-space-6);
}

/* Conteneurs de section */
.tedcraft-custom-page .tc-section-content-block {
    margin-top: var(--tc-space-8);
    margin-bottom: var(--tc-space-8);
    margin-left: auto; /* Centrage */
    margin-right: auto; /* Centrage */
    max-width: 900px; /* Limite de largeur */
    padding: var(--tc-space-6);
    background-color: var(--tc-stone-50);
    border: 1px solid var(--tc-stone-100);
    border-radius: var(--tc-radius-lg);
    box-shadow: var(--tc-shadow-sm);
    transition: all var(--tc-transition-fast);
    position: relative;
}

.tedcraft-custom-page .tc-section-content-block:hover {
    border-color: var(--tc-sage-200);
    box-shadow: var(--tc-shadow-sm);
}

/* Titres H3 des sections (Ex: "Étape 1 - Observer sans juger") */
.tedcraft-custom-page .tc-section-content-block .etape-titre { /* Spécificité pour surcharger le .etape-titre global */
    font-family: var(--tc-font-sans);
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    font-weight: 600;
    color: var(--tc-stone-800);
    margin-bottom: var(--tc-space-4);
    text-align: left;
    position: relative;
    padding-bottom: var(--tc-space-2);
}

.tedcraft-custom-page .tc-section-content-block .etape-titre::after {
    content: '';
    position: absolute;
    bottom: 0px;
    left: 0;
    width: 30px;
    height: 2px;
    background: linear-gradient(90deg, var(--tc-sage-400), transparent);
    border-radius: 1px;
}

/* Sous-titres à l'intérieur des sections (ex: "Sur le geste automatique initial :") */
.tedcraft-custom-page .phase-subtitle {
    font-family: var(--tc-font-sans);
    font-size: clamp(1rem, 1.5vw, 1.125rem);
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: -0.01em;
    color: var(--tc-stone-800);
    margin-top: var(--tc-space-6);
    margin-bottom: var(--tc-space-3);
}

/* ========================================= */
/* 2. NAVIGATION ENTRE PHASES               */
/* ========================================= */

.tedcraft-custom-page .phase-navigation {
    display: flex;
    flex-wrap: wrap;
    gap: var(--tc-space-3);
    justify-content: center;
    margin: var(--tc-space-4) auto var(--tc-space-8) auto; /* Centrage */
    max-width: 900px;
    padding: var(--tc-space-3);
    background-color: var(--tc-sage-50);
    border-radius: var(--tc-radius-md);
    box-shadow: var(--tc-shadow-sm);
}

.tedcraft-custom-page .phase-nav { /* Bouton de phase dans la navigation */
    flex-grow: 1;
    min-width: 100px;
    font-size: 0.9rem;
    padding: var(--tc-space-2) var(--tc-space-4);
    background-color: var(--tc-stone-100);
    color: var(--tc-stone-600);
    border: 1px solid var(--tc-stone-200);
    box-shadow: var(--tc-shadow-xs);
    transition: all var(--tc-transition-fast);
    text-align: center;
    justify-content: center;
    /* Hérite de tc-button mais peut avoir des spécificités */
    border-radius: var(--tc-radius-sm); /* Rayon un peu plus petit pour les pastilles de nav */
}

.tedcraft-custom-page .phase-nav:hover {
    background-color: var(--tc-stone-200);
    color: var(--tc-stone-700);
    transform: translateY(-1px);
    box-shadow: var(--tc-shadow-sm);
}

.tedcraft-custom-page .phase-nav.principal, /* Bouton de phase active */
.tedcraft-custom-page .phase-nav.active {
    background: linear-gradient(135deg, var(--tc-sage-500) 0%, var(--tc-sage-600) 100%);
    color: white;
    box-shadow: var(--tc-shadow-md);
    border-color: var(--tc-sage-500);
    transform: translateY(-1px);
}

.tedcraft-custom-page .phase-nav.principal:hover,
.tedcraft-custom-page .phase-nav.active:hover {
    background: linear-gradient(135deg, var(--tc-sage-600) 0%, var(--tc-sage-700) 100%);
    box-shadow: var(--tc-shadow-lg);
}

.tedcraft-custom-page .phase-nav:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    background-color: var(--tc-stone-100);
    color: var(--tc-stone-400);
    box-shadow: none;
    transform: none;
    border-color: var(--tc-stone-100);
}

/* ========================================= */
/* 3. INFO BOXES                            */
/* (Surcharge les styles tc-info-box si nécessaire, sinon utilise les génériques) */
/* ========================================= */

.tedcraft-custom-page .info-box {
    background: var(--tc-stone-50);
    border: 1px solid var(--tc-stone-100);
    border-radius: var(--tc-radius-lg);
    padding: var(--tc-space-6);
    margin: var(--tc-space-6) auto var(--tc-space-4) auto; /* Centrage et marges */
    max-width: 800px; /* Largeur max */
    box-shadow: var(--tc-shadow-sm);
    display: flex;
    flex-direction: column;
    gap: var(--tc-space-3);
    position: relative;
    overflow: hidden;
}

.tedcraft-custom-page .info-box.blue-box {
    display: flex;
    flex-direction: row;
    background: linear-gradient(135deg, var(--tc-sage-50), rgba(var(--tc-sage-500-rgb), 0.08));
    border: 1px solid var(--tc-sage-100);
}

/* Titres (H4) à l'intérieur des info-box (via tc-info-box__title) */
.tedcraft-custom-page .tc-info-box__title {
    font-family: var(--tc-font-sans);
    font-size: clamp(1.125rem, 2vw, 1.5rem);
    font-weight: 600;
    color: var(--tc-stone-800);
    margin: 0;
}

/* Paragraphes à l'intérieur des info-box (via tc-body) */
.tedcraft-custom-page .info-box p {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--tc-stone-600);
    margin-bottom: var(--tc-space-3);
}
.tedcraft-custom-page .info-box p:last-child {
    margin-bottom: 0;
}

/* Listes non ordonnées dans les info-box (via tc-list-items) */
.tedcraft-custom-page .info-box ul.tc-list-items {
    list-style: none;
    padding-left: 0;
    margin: var(--tc-space-3) 0;
}

.tedcraft-custom-page .info-box ul.tc-list-items li.tc-list-items__item {
    position: relative;
    padding-left: var(--tc-space-6);
    margin-bottom: var(--tc-space-2);
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--tc-stone-600);
}

.tedcraft-custom-page .info-box ul.tc-list-items li.tc-list-items__item::before {
    content: '\2022'; /* Puce ronde par défaut */
    position: absolute;
    left: 0;
    top: 0;
    color: var(--tc-sage-500);
    font-weight: bold;
    font-size: 1.2em;
    line-height: 1;
}

/* Listes ordonnées dans les info-box (via tc-list-steps) */
.tedcraft-custom-page .info-box ol.tc-list-steps {
    list-style: none;
    counter-reset: info-step-counter;
    padding-left: 20px;
    margin: var(--tc-space-3) 0;
}

.tedcraft-custom-page .info-box ol.tc-list-steps li.tc-list-steps__item {
    counter-increment: info-step-counter;
    position: relative;
    padding-left: var(--tc-space-8);
    margin-bottom: var(--tc-space-3);
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--tc-stone-600);
}

.tedcraft-custom-page .info-box ol.tc-list-steps li.tc-list-steps__item::before {
    content: counter(info-step-counter);
    position: absolute;
    left: 0;
    top: 0;
    width: 24px;
    height: 24px;
    background: var(--tc-sage-500);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Icônes dans les info-box (via tc-info-box__icon) */
.tedcraft-custom-page .tc-info-box__icon {
    font-size: 24px;
    color: var(--tc-sage-600);
    line-height: 1;
    align-self: flex-start;
}

/* En-tête des info-box si elles ont une icône et un titre (via tc-info-box__header) */
.tedcraft-custom-page .tc-info-box__header {
    display: flex;
    gap: var(--tc-space-3);
    margin-top: auto;
    margin-bottom: auto;
}

/* Contenu des info-box si elles ont une structure spécifique (via tc-info-box__content) */
.tedcraft-custom-page .tc-info-box__content {
    margin: var(--tc-space-4) 0;
}

/* ========================================= */
/* 4. DOWNLOAD BOX                          */
/* (Surcharge les styles tc-download-box si nécessaire) */
/* ========================================= */

.tedcraft-custom-page .download-box-enhanced {
    display: flex;
    align-items: flex-start;
    gap: var(--tc-space-4);
    background: linear-gradient(135deg, var(--tc-sage-50), rgba(var(--tc-sage-500-rgb), 0.08));
    border: 1px solid var(--tc-sage-100);
    border-radius: var(--tc-radius-2xl); /* Plus grand rayon */
    padding: var(--tc-space-6);
    margin: var(--tc-space-8) auto;
    box-shadow: var(--tc-shadow-md);
    max-width: 800px;
    position: relative;
    overflow: hidden;
}

.tedcraft-custom-page .tc-download-icon { /* Icône dans la download box */
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--tc-sage-100), var(--tc-sage-200));
    border-radius: var(--tc-radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--tc-shadow-xs), inset 0 1px 0 rgba(255, 255, 255, 0.5);
    font-size: 28px;
    color: var(--tc-sage-700);
}

.tedcraft-custom-page .tc-download-content { /* Contenu de la download box */
    flex-grow: 1;
}

/* Titre (H4) dans le contenu des download-box (via tc-download-title) */
.tedcraft-custom-page .tc-download-title {
    font-family: var(--tc-font-sans);
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    font-weight: 600;
    color: var(--tc-stone-800);
    margin-bottom: var(--tc-space-2);
    position: relative;
}
.tedcraft-custom-page .tc-download-title::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 30px;
    height: 2px;
    background: linear-gradient(90deg, var(--tc-sage-400), transparent);
    border-radius: 1px;
}

/* Paragraphes dans le contenu des download-box (via tc-body) */
.tedcraft-custom-page .tc-download-content p {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--tc-stone-600);
    margin-bottom: var(--tc-space-4);
}

.tedcraft-custom-page .file-download-button {
    /* Hérite de tc-button-primary avec des spécificités */
    font-size: 0.875rem;
}

/* ========================================= */
/* 5. QUESTIONS ET FORMULAIRES              */
/* (Surcharge les styles tc-question-item si nécessaire) */
/* ========================================= */

.tedcraft-custom-page .atelier-question,
.tedcraft-custom-page .tc-question-item { /* Cible les deux classes de runner pour une base commune */
    background-color: var(--tc-stone-100);
    border: 1px solid var(--tc-stone-300);
    border-radius: var(--tc-radius-md);
    padding: var(--tc-space-4);
    margin-bottom: var(--tc-space-4);
    box-shadow: var(--tc-shadow-xs);
    transition: all var(--tc-transition-fast);
}

.tedcraft-custom-page .atelier-question:hover,
.tedcraft-custom-page .tc-question-item:hover {
    border-color: var(--tc-sage-400);
    box-shadow: var(--tc-shadow-sm);
}

.tedcraft-custom-page .atelier-question.question-principale {
    background: linear-gradient(135deg, var(--tc-sage-200), rgba(var(--tc-sage-500-rgb), 0.05));
    border-color: var(--tc-sage-200);
    box-shadow: var(--tc-shadow-sm);
}

.tedcraft-custom-page .tc-question-item__header {
    margin-bottom: var(--tc-space-3);
}

.tedcraft-custom-page .tc-question-item__label {
    display: flex;
    text-align: start;
    font-family: var(--tc-font-sans);
    font-size: 1rem;
    font-weight: 600;
    color: var(--tc-stone-800);
    margin-bottom: var(--tc-space-1);
    line-height: 1.3;
}

.tedcraft-custom-page .tc-question-item__description {
    font-size: 0.875rem;
    color: var(--tc-stone-500);
    margin-bottom: var(--tc-space-3);
    line-height: 1.5;
}

.tedcraft-custom-page .tc-input-field {
    width: 100%;
    padding: var(--tc-space-3);
    border: 1px solid var(--tc-stone-300);
    border-radius: var(--tc-radius-sm);
    font-family: var(--tc-font-sans);
    font-size: 0.9375rem;
    color: var(--tc-stone-700);
    background-color: white;
    transition: all var(--tc-transition-fast);
    line-height: 1.5;
    min-height: 44px;
    box-sizing: border-box;
    max-width: 100%;
}

.tedcraft-custom-page textarea.tc-input-field {
    min-height: 80px;
    resize: vertical;
}

.tedcraft-custom-page .tc-input-field::placeholder {
    color: var(--tc-stone-400);
}

.tedcraft-custom-page .tc-input-field:focus {
    border-color: var(--tc-sage-400);
    box-shadow: 0 0 0 3px rgba(var(--tc-sage-500-rgb), 0.1);
    outline: none;
    background-color: white;
}

/* Styles pour les selects */
.tedcraft-custom-page select.tc-input-field {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke-width='2' stroke='%23a1a1aa' class='w-4 h-4'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M8.25 15L12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
}

/* ========================================= */
/* 6. LISTES DYNAMIQUES                     */
/* (Surcharge les styles tc-dynamic-list si nécessaire) */
/* ========================================= */

.tedcraft-custom-page .tc-dynamic-list-container {
    margin-top: var(--tc-space-8);
    background-color: var(--tc-sage-50);
    border: 1px solid var(--tc-sage-100);
    border-radius: var(--tc-radius-lg);
    padding: var(--tc-space-6);
    box-shadow: var(--tc-shadow-sm);
    position: relative;
    max-width: 900px; /* Aligné sur les autres conteneurs */
    margin-left: auto;
    margin-right: auto;
}

.tedcraft-custom-page .tc-dynamic-list-title {
    font-family: var(--tc-font-sans);
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    font-weight: 600;
    color: var(--tc-stone-800);
    margin-bottom: var(--tc-space-4);
    position: relative;
}
.tedcraft-custom-page .tc-dynamic-list-title::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 30px;
    height: 2px;
    background: linear-gradient(90deg, var(--tc-sage-400), transparent);
    border-radius: 1px;
}

.tedcraft-custom-page .tc-dynamic-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tedcraft-custom-page .tc-dynamic-list-item {
    display: flex;
    align-items: flex-start;
    width: 100%;
    background-color: white;
    border: 1px solid var(--tc-stone-200);
    border-radius: var(--tc-radius-sm);
    padding: var(--tc-space-3);
    margin-bottom: var(--tc-space-3);
    box-shadow: var(--tc-shadow-xs);
    position: relative;
    gap: var(--tc-space-3);
    transition: all var(--tc-transition-fast);
    animation: tc-fadeIn 0.5s ease-out;
}

.tedcraft-custom-page .tc-dynamic-list-item:hover {
    transform: translateY(-1px);
    box-shadow: var(--tc-shadow-sm);
}

.tedcraft-custom-page .tc-dynamic-list-item__content {
    display: flex;
    flex-wrap: wrap;
    gap: var(--tc-space-2);
    width: 100%;
}

.tedcraft-custom-page .tc-dynamic-list-item__content input[type="text"],
.tedcraft-custom-page .tc-dynamic-list-item__content input[type="number"],
.tedcraft-custom-page .tc-dynamic-list-item__content input[type="date"],
.tedcraft-custom-page .tc-dynamic-list-item__content textarea {
    flex: 1 1 calc(50% - var(--tc-space-2));
    min-width: 180px;
    padding: var(--tc-space-3);
    border: 1px solid var(--tc-stone-300);
    border-radius: var(--tc-radius-sm);
    font-family: var(--tc-font-sans);
    font-size: 0.9375rem;
    color: var(--tc-stone-700);
    background-color: var(--tc-stone-50);
    line-height: 1.5;
    min-height: 40px;
    box-sizing: border-box;
}

.tedcraft-custom-page .tc-dynamic-list-item__content textarea {
    flex: 1 1 100%;
    min-height: 80px;
    resize: vertical;
}

.tedcraft-custom-page .tc-remove-item-btn {
    background-color: var(--tc-stone-600);
    color: white;
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all var(--tc-transition-fast);
    flex-shrink: 0;
    align-self: center;
}

.tedcraft-custom-page .tc-remove-item-btn:hover {
    background-color: var(--tc-copper-500);
    transform: scale(1.1);
}

/* Bouton d'ajout d'élément dynamique */
.tedcraft-custom-page .tc-button-add {
    background-color: var(--tc-stone-500);
    color: white;
    margin-top: var(--tc-space-4);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--tc-space-2);
    margin-inline: auto;
    max-width: max-content;
    border-radius: var(--tc-radius-md); /* Utilisation de la variable */
    padding: var(--tc-space-3) var(--tc-space-5); /* Utilisation des variables */
    font-weight: 600;
    font-size: 0.9375rem;
    line-height: 1.2;
    transition: all var(--tc-transition-fast);
    box-shadow: var(--tc-shadow-sm);
    border: none;
    cursor: pointer;
}

.tedcraft-custom-page .tc-button-add:hover {
    background-color: var(--tc-sage-600);
    transform: translateY(-1px);
    box-shadow: var(--tc-shadow-md);
}

.tedcraft-custom-page .tc-button-add .material-symbols-outlined {
    font-size: 18px;
    color: white;
}

/* ========================================= */
/* 7. PROCESSUS VERTICAL (Phase 4)          */
/* ========================================= */

.tedcraft-custom-page .processus-vertical-wrapper {
    max-width: 600px;
    margin: var(--tc-space-8) auto;
    text-align: center;
}

.tedcraft-custom-page .processus-titre {
    font-family: var(--tc-font-serif);
    font-size: clamp(1.1875rem, 2vw, 1.375rem);
    font-weight: 600;
    color: var(--tc-sage-800);
    margin-bottom: var(--tc-space-6);
}

.tedcraft-custom-page .processus-vertical {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: relative;
    padding-left: var(--tc-space-6);
}

.tedcraft-custom-page .processus-vertical::before {
    content: '';
    position: absolute;
    left: calc(var(--tc-space-6) / 2);
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: var(--tc-sage-200);
    border-radius: 1px;
}

.tedcraft-custom-page .etape-processus {
    display: flex;
    align-items: center;
    margin-bottom: var(--tc-space-6);
    position: relative;
    width: 100%;
}

.tedcraft-custom-page .connecteur-etape {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 1;
    margin-right: var(--tc-space-3);
}

.tedcraft-custom-page .numero-etape {
    width: 32px;
    height: 32px;
    background-color: var(--tc-sage-500);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    flex-shrink: 0;
    box-shadow: var(--tc-shadow-sm);
    border: 2px solid var(--tc-sage-100);
}

.tedcraft-custom-page .ligne-verticale {
    width: 2px;
    height: var(--tc-space-6);
    background-color: var(--tc-sage-200);
    margin-top: var(--tc-space-1);
}

.tedcraft-custom-page .etape-processus:last-child .connecteur-etape .ligne-verticale {
    display: none;
}

.tedcraft-custom-page .texte-etape {
    font-family: var(--tc-font-sans);
    font-size: 1rem;
    font-weight: 600;
    color: var(--tc-stone-800);
    text-align: left;
    flex-grow: 1;
}

/* ========================================= */
/* 8. GRILLE D'ÉVALUATION (Phase 4)         */
/* ========================================= */

.tedcraft-custom-page .evaluation-grid {
    display: flex;
    flex-direction: column;
    gap: var(--tc-space-6);
    margin: var(--tc-space-8) auto;
    max-width: 1000px;
}

.tedcraft-custom-page .evaluation-card {
    background-color: white;
    border: 1px solid var(--tc-stone-200);
    border-radius: var(--tc-radius-lg);
    padding: var(--tc-space-5);
    box-shadow: var(--tc-shadow-sm);
    transition: all var(--tc-transition-normal);
    position: relative;
}

.tedcraft-custom-page .evaluation-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--tc-shadow-md);
    border-color: var(--tc-sage-200);
}

.tedcraft-custom-page .evaluation-card-header {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: var(--tc-space-4);
    border-bottom: 1px solid var(--tc-stone-100);
    padding-bottom: var(--tc-space-3);
}

.tedcraft-custom-page .evaluation-card-header h4 {
    font-family: var(--tc-font-sans);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--tc-stone-800);
    margin: 0;
}

.tedcraft-custom-page .completion-badge {
    background-color: var(--tc-sage-500);
    color: white;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    flex-shrink: 0;
    box-shadow: var(--tc-shadow-xs);
}

/* Les questions dans les cartes d'évaluation sont des .tc-question-item / .atelier-question */
.tedcraft-custom-page .evaluation-card .tc-question-item,
.tedcraft-custom-page .evaluation-card .atelier-question {
    background-color: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin-bottom: var(--tc-space-4);
}
.tedcraft-custom-page .evaluation-card .tc-question-item:last-of-type,
.tedcraft-custom-page .evaluation-card .atelier-question:last-of-type {
    margin-bottom: 0;
}

.tedcraft-custom-page .evaluation-card .tc-question-item__label {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--tc-stone-700);
    margin-bottom: var(--tc-space-2);
    display: block;
}

.tedcraft-custom-page .evaluation-card .tc-input-field {
    background-color: var(--tc-stone-50);
    border-radius: var(--tc-radius-sm);
    min-height: 38px;
}
.tedcraft-custom-page .evaluation-card textarea.tc-input-field {
    min-height: 70px;
}

/* ========================================= */
/* 9. SECTIONS DE CONCLUSION                */
/* (Surcharge les styles tc-atelier-conclusion-box si nécessaire) */
/* ========================================= */

.tedcraft-custom-page .atelier-conclusion-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: var(--tc-space-12);
    max-width: 900px;
    padding: var(--tc-space-8);
    background: linear-gradient(135deg, var(--tc-sage-50), rgba(var(--tc-sage-500-rgb), 0.05));
    border: 1px solid var(--tc-sage-100);
    border-radius: var(--tc-radius-2xl);
    text-align: center;
    box-shadow: var(--tc-shadow-md);
    position: relative;
    overflow: hidden;
}

.tedcraft-custom-page .atelier-conclusion-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(var(--tc-sage-500-rgb), 0.1), transparent);
    transition: left 2s ease-in-out;
}

.tedcraft-custom-page .atelier-conclusion-box:hover::before {
    left: 100%;
}

.tedcraft-custom-page .atelier-conclusion-box h3.tc-title-2 {
    font-family: var(--tc-font-serif);
    font-size: clamp(1.25rem, 2.2vw, 1.5rem);
    color: var(--tc-sage-800);
    margin-bottom: var(--tc-space-4);
    line-height: 1.3;
}

.tedcraft-custom-page .atelier-conclusion-box p.tc-body {
    font-size: 1rem;
    color: var(--tc-stone-600);
    margin-bottom: var(--tc-space-6);
}

.tedcraft-custom-page .atelier-conclusion-buttons {
    display: flex;
    justify-content: space-between;
    gap: var(--tc-space-4);
    flex-wrap: wrap;
}

/* Styles spécifiques pour la boîte de conclusion finale (Phase 5) */
.tedcraft-custom-page .atelier-conclusion-box.conclusion-box-final {
    background: linear-gradient(135deg, var(--tc-sage-100), rgba(var(--tc-sage-500-rgb), 0.1));
    border-color: var(--tc-sage-200);
    box-shadow: var(--tc-shadow-lg);
}

.tedcraft-custom-page .atelier-conclusion-box.conclusion-box-final h3 {
    color: var(--tc-sage-800);
    font-size: clamp(1.5rem, 2.5vw, 1.875rem);
}

.tedcraft-custom-page .atelier-conclusion-box.conclusion-box-final p {
    color: var(--tc-stone-700);
}

/* ========================================= */
/* 10. RESPONSIVE DESIGN                     */
/* ========================================= */

@media (max-width: 768px) {
    .tedcraft-custom-page {
        padding: var(--tc-space-6);
        margin: var(--tc-space-6) auto;
    }

    .tedcraft-custom-page .etape-titre {
        font-size: clamp(1.5rem, 6vw, 2.5rem);
        margin-bottom: var(--tc-space-4);
    }

    .tedcraft-custom-page .info-box,
    .tedcraft-custom-page .download-box-enhanced,
    .tedcraft-custom-page .tc-section-content-block {
        padding: var(--tc-space-4);
        margin: var(--tc-space-4) auto;
    }

    .tedcraft-custom-page .tc-info-box__title,
    .tedcraft-custom-page .tc-download-title {
        font-size: 1rem;
        margin-bottom: var(--tc-space-3);
    }

    .tedcraft-custom-page .info-box p,
    .tedcraft-custom-page .info-box ul.tc-list-items li.tc-list-items__item,
    .tedcraft-custom-page .tc-download-content p,
    .tedcraft-custom-page .tc-question-item__label,
    .tedcraft-custom-page .tc-question-item__description {
        font-size: 0.875rem;
    }

    .tedcraft-custom-page .info-box ol.tc-list-steps li.tc-list-steps__item {
        font-size: 0.875rem;
        padding-left: var(--tc-space-7);
    }

    .tedcraft-custom-page .info-box ol.tc-list-steps li.tc-list-steps__item::before {
        width: 20px;
        height: 20px;
        font-size: 0.75rem;
    }

    .tedcraft-custom-page .info-box ul.tc-list-items li.tc-list-items__item::before {
        font-size: 1em;
        top: 0.1em;
    }

    .tedcraft-custom-page .tc-download-icon {
        margin-bottom: var(--tc-space-3);
        width: 48px;
        height: 48px;
        font-size: 24px;
    }
    .tedcraft-custom-page .tc-download-title::after {
        left: 50%;
        transform: translateX(-50%);
    }
    .tedcraft-custom-page .download-box-enhanced {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .tedcraft-custom-page .tc-question-item {
        padding: var(--tc-space-3);
        margin-bottom: var(--tc-space-3);
    }
    .tedcraft-custom-page .tc-input-field {
        font-size: 0.875rem;
        min-height: 40px;
    }

    .tedcraft-custom-page .tc-dynamic-list-container {
        padding: var(--tc-space-4);
        margin-top: var(--tc-space-6);
        margin-bottom: var(--tc-space-6);
    }
    .tedcraft-custom-page .tc-dynamic-list-title {
        font-size: 1.125rem;
        margin-bottom: var(--tc-space-3);
    }
    .tedcraft-custom-page .tc-dynamic-list-title::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .tedcraft-custom-page .tc-dynamic-list-item {
        padding: var(--tc-space-2);
        margin-bottom: var(--tc-space-2);
        flex-direction: column;
    }
    .tedcraft-custom-page .tc-dynamic-list-item__content {
        flex-direction: column;
        gap: var(--tc-space-2);
    }
    .tedcraft-custom-page .tc-dynamic-list-item__content input,
    .tedcraft-custom-page .tc-dynamic-list-item__content textarea {
        flex: 1 1 100%;
    }
    .tedcraft-custom-page .tc-remove-item-btn {
        margin-top: var(--tc-space-2);
        align-self: flex-end;
    }

    .tedcraft-custom-page .tc-button-add {
        font-size: 0.875rem;
        padding: var(--tc-space-2) var(--tc-space-4);
    }

    .tedcraft-custom-page .processus-titre {
        font-size: 1.125rem;
        margin-bottom: var(--tc-space-4);
    }
    .tedcraft-custom-page .processus-vertical {
        padding-left: var(--tc-space-4);
    }
    .tedcraft-custom-page .processus-vertical::before {
        left: calc(var(--tc-space-4) / 2);
    }
    .tedcraft-custom-page .numero-etape {
        width: 28px;
        height: 28px;
        font-size: 0.9rem;
    }
    .tedcraft-custom-page .texte-etape {
        font-size: 0.9375rem;
    }
    .tedcraft-custom-page .ligne-verticale {
        height: var(--tc-space-5);
    }
    .tedcraft-custom-page .etape-processus {
        margin-bottom: var(--tc-space-5);
    }


    .tedcraft-custom-page .evaluation-card {
        padding: var(--tc-space-4);
    }
    .tedcraft-custom-page .evaluation-card-header h4 {
        font-size: 1.125rem;
    }
    .tedcraft-custom-page .completion-badge {
        width: 24px;
        height: 24px;
        font-size: 0.9rem;
    }
    .tedcraft-custom-page .evaluation-card .tc-question-item__label,
    .tedcraft-custom-page .evaluation-card .tc-input-field {
        font-size: 0.875rem;
    }

    .tedcraft-custom-page .atelier-conclusion-box {
        padding: var(--tc-space-6);
        margin-top: var(--tc-space-8);
    }
    .tedcraft-custom-page .atelier-conclusion-box h3 {
        font-size: clamp(1.125rem, 4.5vw, 1.5rem);
        margin-bottom: var(--tc-space-3);
    }
    .tedcraft-custom-page .atelier-conclusion-box p {
        font-size: 0.9375rem;
        margin-bottom: var(--tc-space-4);
    }
    .tedcraft-custom-page .atelier-conclusion-buttons {
        flex-direction: column;
        gap: var(--tc-space-3);
    }
    .tedcraft-custom-page .tc-button { /* Ciblage général des boutons pour responsive */
        width: 100%;
        justify-content: center;
        font-size: 0.875rem;
        padding: var(--tc-space-2) var(--tc-space-4);
    }

    .tedcraft-custom-page .phase-navigation {
        gap: var(--tc-space-2);
        margin: var(--tc-space-4) auto;
        padding: var(--tc-space-2);
        border-radius: var(--tc-radius-sm);
    }
    .tedcraft-custom-page .phase-nav {
        font-size: 0.85rem;
        padding: var(--tc-space-2);
        min-width: unset;
        flex-basis: auto;
    }
    .tedcraft-custom-page .phase-nav.principal,
    .tedcraft-custom-page .phase-nav.active {
        box-shadow: var(--tc-shadow-sm);
    }

    .tedcraft-custom-page .phase-subtitle {
        font-size: 0.9375rem;
        margin-top: var(--tc-space-4);
        margin-bottom: var(--tc-space-2);
    }

   div.tc-body.tc-intro-description h3.tc-title-3{
        font-size: 1.2rem !important;
        font-weight: 600 !important;
    }
}

@media (max-width: 480px) {
    .tedcraft-custom-page {
        padding: var(--tc-space-4);
    }

    .tedcraft-custom-page .etape-titre {
        font-size: clamp(1.375rem, 7vw, 2.25rem);
    }

    .tedcraft-custom-page .info-box,
    .tedcraft-custom-page .download-box-enhanced,
    .tedcraft-custom-page .tc-question-item,
    .tedcraft-custom-page .tc-section-content-block {
        padding: var(--tc-space-3);
        margin: var(--tc-space-3) auto;
    }

    .tedcraft-custom-page .tc-question-item__label {
        font-size: 0.9375rem;
    }

    .tedcraft-custom-page .tc-dynamic-list-container {
        padding: var(--tc-space-3);
    }

    .tedcraft-custom-page .tc-button,
    .tedcraft-custom-page .tc-button-add,
    .tedcraft-custom-page .tc-download-button {
        font-size: 0.8125rem;
        padding: var(--tc-space-2) var(--tc-space-3);
    }

    .tedcraft-custom-page .phase-navigation {
        gap: var(--tc-space-2);
        padding: var(--tc-space-1);
        border-radius: var(--tc-radius-sm);
        margin-left: auto;
        margin-right: auto;
        max-width: 90%;
    }
    .tedcraft-custom-page .phase-nav {
        font-size: 0.75rem;
        padding: var(--tc-space-1) var(--tc-space-2);
    }
}