/* ============================================
   Analyse Situation - Page dédiée
   Style moderne avec étapes visuelles et scores
   ============================================ */

/* === Layout Principal === */
.analyse-main {
    min-height: 100vh;
    background: linear-gradient(180deg,
            var(--surface-container-lowest) 0%,
            var(--surface-container) 100%);
    padding-top: 80px;
}

.analyse-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 24px;
}

/* === Header === */
.analyse-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 32px;
}

.analyse-header-content h1 {
    font: var(--headline-medium);
    color: var(--on-surface);
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 8px 0;
    transition: opacity 0.3s ease;
}

.analyse-header-content h1 .material-icons {
    font-size: 36px;
    color: var(--primary-color);
}

.analyse-subtitle {
    font: var(--body-large);
    color: var(--on-surface-variant);
    margin: 0;
    transition: opacity 0.3s ease;
}


/* === Step Progress === */
.step-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 40px;
    padding: 20px;
    background: var(--surface);
    border-radius: 20px;
    box-shadow: var(--shadow-1);
}

.step-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    opacity: 0.5;
    transition: all 0.4s ease;
}

.step-item.active {
    opacity: 1;
}

.step-item.completed {
    opacity: 1;
}

.step-number {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--surface-container);
    border: 2px solid var(--outline-variant);
    display: flex;
    align-items: center;
    justify-content: center;
    font: var(--title-medium);
    font-weight: 600;
    color: var(--on-surface-variant);
    transition: all 0.4s ease;
}

.step-item.active .step-number {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-container) 100%);
    border-color: transparent;
    color: white;
    box-shadow: 0 4px 12px rgba(25, 52, 97, 0.3);
}

.step-item.completed .step-number {
    background: var(--tertiary-color);
    border-color: transparent;
    color: white;
}

.step-item.completed .step-number::before {
    content: '✓';
}

.step-label {
    font: var(--label-medium);
    color: var(--on-surface-variant);
    text-align: center;
}

.step-item.active .step-label {
    color: var(--primary-color);
    font-weight: 600;
}

.step-connector {
    flex: 1;
    max-width: 80px;
    height: 3px;
    background: var(--outline-variant);
    margin: 0 16px;
    border-radius: 2px;
    position: relative;
    top: -12px;
}

.step-connector.completed {
    background: linear-gradient(90deg, var(--tertiary-color) 0%, var(--primary-color) 100%);
}

.step-section {
    display: none;
}

.step-section.active {
    display: block;
}

.step-card {
    background: var(--surface);
    border-radius: 28px;
    padding: 32px;
    box-shadow: var(--shadow-2);
    border: 1px solid var(--outline-variant);
}

.step-card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--outline-variant);
}

.step-card-header .material-icons {
    font-size: 32px;
    color: var(--primary-color);
}

.step-card-header h2 {
    font: var(--headline-small);
    color: var(--on-surface);
    margin: 0;
}

/* === Step 1 Guidance === */
.situation-guidance {
    background: var(--surface-container-lowest);
    border-radius: 24px;
    padding: 24px;
    border: 1px solid var(--outline-variant);
    border-left: 6px solid var(--primary-color);
    margin-bottom: 8px;
    box-shadow: var(--shadow-1);
}

.guidance-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.guidance-header .material-icons {
    font-size: 24px;
    background: var(--primary-container);
    color: var(--primary-color);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.guidance-header h3 {
    font: var(--title-medium);
    margin: 0;
    font-weight: 600;
}

.guidance-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.guidance-list li {
    font: var(--body-small);
    color: var(--on-surface-variant);
    line-height: 1.5;
}

.guidance-list li strong {
    color: var(--on-surface);
    display: block;
    margin-bottom: 6px;
    font: var(--label-large);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

.situation-input-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.voice-input-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 32px;
    background: linear-gradient(180deg,
            var(--surface-container-low) 0%,
            var(--surface-container) 100%);
    border-radius: 20px;
    border: 2px dashed var(--outline-variant);
    transition: all 0.3s ease;
}

.voice-input-area.recording {
    border-color: #d32f2f;
    background: linear-gradient(180deg,
            rgba(211, 47, 47, 0.05) 0%,
            rgba(211, 47, 47, 0.1) 100%);
}

.voice-record-btn {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-container) 100%);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(25, 52, 97, 0.3);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.voice-record-btn .material-icons {
    font-size: 36px;
}

.voice-record-btn:hover {
    transform: scale(1.08);
    box-shadow: 0 12px 32px rgba(25, 52, 97, 0.4);
}

.voice-record-btn.recording {
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
    animation: recording-pulse 1.5s ease-in-out infinite;
}

@keyframes recording-pulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(211, 47, 47, 0.6),
            0 8px 24px rgba(211, 47, 47, 0.3);
    }

    50% {
        box-shadow: 0 0 0 16px rgba(211, 47, 47, 0),
            0 12px 32px rgba(211, 47, 47, 0.4);
    }
}

.voice-status {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    border-radius: 20px;
    background: var(--surface);
    font: var(--label-large);
    color: var(--on-surface-variant);
}

.voice-status .status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--outline);
}

.voice-status.recording .status-dot {
    background: #d32f2f;
    animation: blink 1s ease-in-out infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.3;
    }
}

.text-input-area {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.text-input-area label {
    font: var(--label-large);
    color: var(--on-surface-variant);
}

.text-input-area textarea {
    width: 100%;
    min-height: 150px;
    padding: 20px;
    border-radius: 16px;
    border: 2px solid var(--outline-variant);
    background: var(--surface-container-lowest);
    font: var(--body-large);
    color: var(--on-surface);
    resize: vertical;
    transition: all 0.3s ease;
}

.text-input-area textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(25, 52, 97, 0.1);
}

.text-input-area textarea::placeholder {
    color: var(--outline);
}

/* === Step Cards === */

/* === Step 2: Keywords === */
.keywords-container {
    min-height: 80px;
    margin-bottom: 24px;
}

.keywords-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 32px;
    color: var(--on-surface-variant);
    font: var(--body-large);
}

.loading-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--outline-variant);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}


.keywords-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.keyword-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 20px;
    background: linear-gradient(135deg, var(--primary-container) 0%, var(--secondary-container) 100%);
    color: var(--on-primary-container);
    font: var(--label-large);
    font-weight: 500;
    animation: scaleIn 0.4s ease backwards;
}

.keyword-chip:nth-child(1) {
    animation-delay: 0.1s;
}

.keyword-chip:nth-child(2) {
    animation-delay: 0.15s;
}

.keyword-chip:nth-child(3) {
    animation-delay: 0.2s;
}

.keyword-chip:nth-child(4) {
    animation-delay: 0.25s;
}

.keyword-chip:nth-child(5) {
    animation-delay: 0.3s;
}

.keyword-chip:nth-child(6) {
    animation-delay: 0.35s;
}

.keyword-chip:nth-child(7) {
    animation-delay: 0.4s;
}

.keyword-chip:nth-child(8) {
    animation-delay: 0.45s;
}


.situation-summary {
    padding: 20px;
    background: var(--surface-container-low);
    border-radius: 16px;
    border-left: 4px solid var(--primary-color);
}

.situation-summary h3 {
    font: var(--label-large);
    color: var(--on-surface-variant);
    margin: 0 0 8px 0;
}

.situation-summary p {
    font: var(--body-medium);
    color: var(--on-surface);
    margin: 0;
    line-height: 1.6;
}

/* === Step 3: Resources === */
.resources-category {
    margin-bottom: 28px;
}

.category-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: var(--surface-container-low);
    border-radius: 16px 16px 0 0;
    border: 1px solid var(--outline-variant);
    border-bottom: none;
}

.category-header .material-icons {
    font-size: 24px;
    color: var(--primary-color);
}

.category-header h3 {
    flex: 1;
    font: var(--title-medium);
    color: var(--on-surface);
    margin: 0;
}

.resource-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    padding: 0 10px;
    border-radius: 14px;
    background: var(--primary-color);
    color: white;
    font: var(--label-medium);
    font-weight: 600;
}

.resources-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 16px 0;
    border: 1px solid var(--outline-variant);
    border-radius: 0 0 16px 16px;
    overflow: hidden;
}



/* No Resources Message */
.no-resources-message {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px;
    background: var(--surface-container-low);
    border-radius: 16px;
    border: 1px solid var(--outline-variant);
    margin-bottom: 24px;
}

.no-resources-message .material-icons {
    font-size: 32px;
    color: var(--tertiary-color);
}

.no-resources-message p {
    font: var(--body-medium);
    color: var(--on-surface-variant);
    margin: 0;
    line-height: 1.5;
}

/* === Step 4: CUA Analysis === */
.cua-analysis-container {
    min-height: 200px;
}



/* === Responsive === */
@media (max-width: 768px) {
    .analyse-container {
        padding: 20px 16px;
    }

    .analyse-header {
        flex-direction: column;
        gap: 16px;
    }

    .back-btn {
        align-self: flex-start;
    }

    .step-progress {
        padding: 16px 12px;
        gap: 0;
    }

    .step-connector {
        max-width: 40px;
        margin: 0 8px;
    }

    .step-label {
        display: none;
    }

    .step-card {
        padding: 24px 20px;
        border-radius: 20px;
    }

    .step-actions {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }

}

@media (max-width: 480px) {
    .analyse-header-content h1 {
        font-size: 24px;
    }

    .analyse-header-content h1 .material-icons {
        font-size: 28px;
    }

    .step-number {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
}

/* === Modal de chargement CUA === */
.cua-loading-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 24px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cua-loading-modal.show,
.cua-loading-modal.active {
    display: flex;
    opacity: 1;
}

.cua-loading-modal-content {
    background: var(--surface);
    border-radius: 28px;
    padding: 40px;
    max-width: 480px;
    width: 100%;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.2);
    animation: modalSlideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.cua-loading-header {
    text-align: center;
    margin-bottom: 32px;
}

.cua-loading-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px auto;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-container) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 32px rgba(25, 52, 97, 0.3);
}

.cua-loading-icon .material-icons {
    font-size: 40px;
    color: white;
}

.animate-spin {
    animation: spin 2s linear infinite;
}

.cua-loading-header h3 {
    font: var(--headline-small);
    color: var(--on-surface);
    margin: 0 0 8px 0;
}

.cua-loading-header p {
    font: var(--body-medium);
    color: var(--on-surface-variant);
    margin: 0;
}

.cua-loading-progress {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 32px;
}

.cua-loading-progress .progress-bar {
    flex: 1;
    height: 12px;
    background: var(--surface-container);
    border-radius: 6px;
    overflow: hidden;
}

.cua-loading-progress .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--tertiary-color) 100%);
    border-radius: 6px;
    width: 0%;
    transition: width 0.4s ease;
}

.cua-loading-progress .progress-text {
    font: var(--title-medium);
    font-weight: 700;
    color: var(--primary-color);
    min-width: 48px;
    text-align: right;
}

.cua-loading-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 28px;
}

.loading-step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: var(--surface-container-low);
    border-radius: 16px;
    opacity: 0.5;
    transition: all 0.3s ease;
}

.loading-step.active {
    opacity: 1;
    background: var(--primary-container);
}

.loading-step.completed {
    opacity: 1;
}

.loading-step .step-icon {
    font-size: 22px;
    color: var(--on-surface-variant);
}

.loading-step.active .step-icon {
    color: var(--primary-color);
}

.loading-step.active .step-icon.animate-spin {
    animation: spin 1s linear infinite;
}

.loading-step.completed .step-icon {
    color: var(--tertiary-color);
}

.loading-step .step-text {
    font: var(--body-medium);
    color: var(--on-surface);
}

.cua-loading-tip {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    background: var(--tertiary-container);
    border-radius: 16px;
}

.cua-loading-tip .material-icons {
    font-size: 24px;
    color: var(--on-tertiary-container);
}

.cua-loading-tip p {
    font: var(--body-small);
    color: var(--on-tertiary-container);
    margin: 0;
    line-height: 1.5;
}




/* Mobile adjustments pour le modal */
@media (max-width: 480px) {
    .cua-loading-modal-content {
        padding: 28px 20px;
    }

    .cua-loading-icon {
        width: 64px;
        height: 64px;
    }

    .cua-loading-icon .material-icons {
        font-size: 32px;
    }

    .cua-loading-header h3 {
        font-size: 20px;
    }

    .loading-step {
        padding: 12px 14px;
    }

    .loading-step .step-text {
        font-size: 13px;
    }
}




.resource-card-premium {
    background: var(--surface);
    border-radius: 16px;
    border: 1px solid var(--outline-variant);
    overflow: hidden;
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.resource-card-premium:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    border-color: var(--primary-color);
}

.resource-card-accent {
    height: 4px;
    width: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    opacity: 0.8;
}

.resource-card-premium.internal .resource-card-accent {
    background: linear-gradient(90deg, #1a237e, #3949ab);
}

.resource-card-premium.partner .resource-card-accent {
    background: linear-gradient(90deg, #006064, #00acc1);
}

.resource-card-body {
    padding: 18px;
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 12px;
}

.resource-header-row {
    display: flex;
    justify-content: flex-start;
    gap: 12px;
    align-items: center;
}

.resource-rank-circle {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid var(--outline-variant);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.resource-rank-circle .score-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--primary-color);
    opacity: 1;
}

.resource-premium-title {
    font: var(--title-medium);
    font-weight: 600;
    color: var(--on-surface);
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
    overflow: hidden;
    line-height: 1.4;
}

.resource-premium-excerpt {
    font: var(--body-small);
    color: var(--on-surface-variant);
    line-height: 1.6;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    line-clamp: 3;
    overflow: hidden;
    background: var(--surface-container-low);
    padding: 10px;
    border-radius: 8px;
    word-break: break-word;
}

.resource-premium-meta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: auto;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
    font: var(--label-small);
    color: var(--on-surface-variant);
    background: var(--surface-container);
    padding: 2px 8px;
    border-radius: 4px;
}

.meta-item .material-icons {
    font-size: 14px;
    color: var(--primary-color);
}

.resource-premium-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag-chip-soft {
    font: var(--label-small);
    padding: 2px 10px;
    background: var(--secondary-container);
    color: var(--on-secondary-container);
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.resource-badge {
    padding: 3px 10px;
    border-radius: 20px;
    font: var(--label-small);
    font-weight: 600;
}

.resource-badge.idt {
    background: #e8eaf6;
    color: #1a237e;
}

.resource-badge.partner {
    background: #e0f2f1;
    color: #006064;
}



/* === New CUA Sections === */




/* === Accessibility focus styles === */
button:focus-visible,
a:focus-visible,
textarea:focus-visible,
[role="button"]:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 4px;
    box-shadow: 0 0 0 4px rgba(33, 150, 243, 0.2);
}



/* === Print Medial Query === */
@media print {

    .analyse-header,
    .step-progress,
    .step-actions,
    .back-btn,
    .voice-input-area {
        display: none !important;
    }

    .analyse-container {
        max-width: 100%;
        padding: 0;
    }

    .step-card {
        box-shadow: none;
        border: none;
    }


}


/* Modern Resource Loading */
.resources-loading-modern {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    gap: 16px;
    color: var(--secondary-text);
}

.loading-dots {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.loading-dots span,
.loading-dots .dot {
    width: 12px;
    height: 12px;
    background-color: var(--primary-color);
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out both;
}

.loading-dots span:nth-child(1),
.loading-dots .dot:nth-child(1) {
    animation-delay: -0.32s;
}

.loading-dots span:nth-child(2),
.loading-dots .dot:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes bounce {

    0%,
    80%,
    100% {
        transform: scale(0);
    }

    40% {
        transform: scale(1);
    }
}

.loading-progress-bar {
    width: 200px;
    /* Or 100% of container */
    max-width: 100%;
    height: 6px;
    background-color: rgba(var(--primary-rgb), 0.2);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 10px;
    position: relative;
}

.loading-progress-fill {
    height: 100%;
    background-color: var(--primary-color);
    width: 30%;
    /* Default starting width */
    border-radius: 3px;
    transition: width 0.5s ease;
    animation: progressIndeterminate 2s infinite ease-in-out;
}

@keyframes progressIndeterminate {
    0% {
        width: 10%;
        margin-left: 0;
    }

    50% {
        width: 60%;
        margin-left: 20%;
    }

    100% {
        width: 10%;
        margin-left: 90%;
    }
}

.loading-text {
    font-size: 14px;
    font-weight: 500;
    color: var(--on-surface-variant);
    animation: pulse 2s infinite;
}

/* Analysis Tabs Styles */
.analysis-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--outline-variant);
    padding-bottom: 0;
}

.tab-btn {
    padding: 10px 20px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    font-weight: 500;
    color: var(--on-surface-variant);
    cursor: pointer;
    transition: all 0.2s;
}

.tab-btn:hover {
    color: var(--primary-color);
    background-color: var(--surface-container-high);
}

.tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
    font-weight: 600;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease-out;
}

/* Cognitive Load Styles */
.clt-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
    border: 1px solid var(--outline-variant);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.clt-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--outline-variant);
}

.clt-header h3 {
    margin: 0;
    font-size: 18px;
    color: var(--on-surface);
}

.clt-status-badge {
    padding: 4px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
}

.clt-status-high {
    background: #ffebee;
    color: #c62828;
}

.clt-status-medium {
    background: #fff3e0;
    color: #ef6c00;
}

.clt-status-low,
.clt-status-good {
    background: #e8f5e9;
    color: #2e7d32;
}

.clt-status-improve {
    background: #e3f2fd;
    color: #1565c0;
}

.clt-recommendations ul {
    margin: 0;
    padding-left: 20px;
}

.clt-recommendations li {
    margin-bottom: 8px;
    color: var(--on-surface);
}

/* === Fiches de Synthèse Guidance === */
.fiches-guidance {
    background: var(--surface-container-low);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid var(--outline-variant);
}

.approach-description {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    background: white;
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-1);
    border-left: 4px solid var(--primary-color);
}

.approach-description .material-icons {
    font-size: 32px;
    color: var(--primary-color);
    background: var(--primary-container);
    padding: 12px;
    border-radius: 12px;
}

.approach-info h4 {
    margin: 0 0 6px 0;
    font: var(--title-medium);
    color: var(--on-surface);
}

.approach-info p {
    margin: 0;
    font: var(--body-medium);
    color: var(--on-surface-variant);
    line-height: 1.5;
}

.universal-desc {
    border-color: #0277bd;
}

.universal-desc .material-icons {
    color: #0277bd;
    background: #e1f5fe;
}

.cognitive-desc {
    border-color: #673ab7;
}

.cognitive-desc .material-icons {
    color: #673ab7;
    background: #f3e5f5;
}

.explicit-desc {
    border-color: #2e7d32;
}

.explicit-desc .material-icons {
    color: #2e7d32;
    background: #e8f5e9;
}

/* Animation active tab content */
.tab-content.active {
    display: block;
    animation: slideUp 0.4s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* === Modal Implementation Styles === */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-content {
    background: var(--surface);
    border-radius: 28px;
    padding: 0;
    width: 90%;
    max-width: 500px;
    box-shadow: var(--shadow-5);
    overflow: hidden;
    animation: scaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-header {
    padding: 24px;
    border-bottom: 1px solid var(--outline-variant);
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--surface-container);
}

.modal-header h3 {
    margin: 0;
    flex: 1;
    font: var(--headline-small);
    color: var(--on-surface);
}

.close-modal-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--on-surface-variant);
    padding: 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.close-modal-btn:hover {
    background: var(--surface-container-highest);
    color: var(--on-surface);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    max-height: 60vh;
}

.modal-body p {
    font: var(--body-large);
    color: var(--on-surface);
    margin: 0 0 16px 0;
    line-height: 1.5;
}

.modal-footer {
    padding: 16px 24px;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    border-top: 1px solid var(--outline-variant);
    background: var(--surface-container-low);
}

/* === Step Actions & Buttons === */
.step-actions {
    display: flex;
    justify-content: flex-end;
    gap: 16px;
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid var(--outline-variant);
}

.btn-primary,
.btn-secondary {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 28px;
    font: var(--label-large);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-container) 100%);
    border: none;
    color: white;
    box-shadow: 0 4px 16px rgba(25, 52, 97, 0.3);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(25, 52, 97, 0.4);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-secondary {
    background: var(--surface);
    border: 2px solid var(--outline-variant);
    color: var(--on-surface);
}

.btn-secondary:hover {
    background: var(--surface-container);
    border-color: var(--outline);
}

/* === Text Button & Highlights === */
.text-btn {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: underline;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px 0;
    font-family: inherit;
    font-size: inherit;
}

.text-btn:hover {
    color: var(--primary-container);
    text-decoration: none;
}

mark {
    background-color: var(--tertiary-container);
    color: var(--on-tertiary-container);
    border-radius: 4px;
    padding: 0 4px;
    font-weight: 500;
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
}

/* Theme overrides for buttons */
.btn-primary.btn-universal {
    background: #0277bd;
}

.btn-primary.btn-cognitive {
    background: #673ab7;
}

.btn-primary.btn-explicit {
    background: #2e7d32;
}