/* ============================================
   NETFLIX HOME - Caly-Quiz IRVE LMS
   Homepage redesign with horizontal carousels
   Version 1.0 — Feb 2026
   ============================================ */

/* ─── Override hero-section defaults for Netflix layout ─── */
.hero-section.nfx-home {
    padding: 0 !important;
    align-items: stretch !important;
    text-align: left !important;
}

/* ─── CSS Variables (Netflix theme) ───────── */
.nfx-home {
    --nfx-dark: #0f172a;
    --nfx-dark-80: rgba(15, 23, 42, 0.8);
    --nfx-dark-60: rgba(15, 23, 42, 0.6);
    --nfx-dark-40: rgba(15, 23, 42, 0.4);
    --nfx-row-gap: 12px;
    --nfx-side-pad: 4%;
    --nfx-card-radius: 8px;
    --nfx-transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ─── HERO BANNER ─────────────────────────── */
.nfx-hero {
    position: relative;
    width: 100%;
    height: 56vh;
    min-height: 300px;
    max-height: 600px;
    overflow: hidden;
    margin-bottom: 0;
    flex-shrink: 0;
    background: var(--nfx-dark);
}

.nfx-hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    transition: opacity 0.8s ease;
}

.nfx-hero-bg--fallback {
    background: linear-gradient(-45deg, #1e3a8a, #2563eb, #f97316, #fbbf24) !important;
    background-size: 400% 400% !important;
    animation: gradient-shift 15s ease infinite;
}

.nfx-hero-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(15, 23, 42, 1) 0%,
        rgba(15, 23, 42, 0.97) 30%,
        rgba(15, 23, 42, 0.85) 50%,
        rgba(15, 23, 42, 0.5) 70%,
        rgba(15, 23, 42, 0.15) 100%
    );
    pointer-events: none;
}

/* Side vignette effect */
.nfx-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to right,
        rgba(15, 23, 42, 0.6) 0%,
        rgba(15, 23, 42, 0.2) 25%,
        transparent 50%,
        transparent 75%,
        rgba(15, 23, 42, 0.3) 100%
    );
    pointer-events: none;
}

.nfx-hero-content {
    position: absolute;
    bottom: 2rem;
    left: var(--nfx-side-pad);
    right: 40%;
    z-index: 2;
    color: #fff;
    animation: slide-up-fade 0.6s ease-out;
    text-shadow: 0 2px 8px rgba(0,0,0,0.7), 0 0 30px rgba(15,23,42,0.5);
}

.nfx-hero-category {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.78rem;
    color: var(--primary-light, #fbbf24);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.nfx-hero-category .category-icon-animated {
    width: 20px;
    height: 20px;
}
.nfx-hero-category .category-icon-animated svg {
    width: 100%;
    height: 100%;
}

.nfx-hero-title {
    font-family: var(--font-heading, 'Outfit', sans-serif);
    font-size: clamp(1.4rem, 3.5vw, 2.6rem);
    font-weight: 700;
    line-height: 1.15;
    margin: 0 0 0.5rem;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
}

.nfx-hero-desc {
    font-size: 0.92rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.5;
    max-width: 520px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 1.2rem;
}

.nfx-hero-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.7);
}

.nfx-hero-meta-item {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.nfx-hero-actions {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.nfx-hero-btn {
    padding: 0.75rem 2rem;
    background: var(--primary, #f59e0b);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    font-family: var(--font-body, 'Inter', sans-serif);
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.nfx-hero-btn:hover {
    background: var(--primary-dark, #d97706);
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
}

.nfx-hero-btn-info {
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: var(--font-body, 'Inter', sans-serif);
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.nfx-hero-btn-info:hover {
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.4);
}

/* ─── AD SLIDESHOW ───────────────────────── */
.nfx-slideshow {
    position: relative;
    overflow: hidden;
}

.nfx-slideshow-track {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.nfx-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity var(--nfx-ss-transition, 800ms) ease;
    pointer-events: none;
}
.nfx-slide--active {
    opacity: 1;
    pointer-events: auto;
    z-index: 1;
}

.nfx-slide-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
}

.nfx-slide-gradient {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(
        to top,
        rgba(15, 23, 42, 0.95) 0%,
        rgba(15, 23, 42, 0.6) 35%,
        rgba(15, 23, 42, 0.2) 60%,
        transparent 100%
    );
}

.nfx-slide-content {
    position: absolute;
    bottom: 2.5rem;
    left: var(--nfx-side-pad);
    right: 40%;
    z-index: 3;
    color: #fff;
    animation: slide-up-fade 0.6s ease-out;
    text-shadow: 0 2px 8px rgba(0,0,0,0.7), 0 0 30px rgba(15,23,42,0.5);
}
.nfx-slide-title {
    font-family: var(--font-heading, 'Outfit', sans-serif);
    font-size: clamp(1.4rem, 3.5vw, 2.6rem);
    font-weight: 700;
    line-height: 1.15;
    margin: 0 0 0.5rem;
}
.nfx-slide-subtitle {
    font-size: 1rem;
    color: rgba(255,255,255,0.85);
    line-height: 1.5;
    max-width: 520px;
    margin: 0 0 1rem;
}
.nfx-slide-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.65rem 1.8rem;
    background: var(--primary, #f59e0b);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}
.nfx-slide-cta:hover {
    background: var(--primary-dark, #d97706);
    transform: scale(1.05);
}

/* Slideshow Arrows */
.nfx-slideshow-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 4;
    width: 48px;
    height: 64px;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border: none;
    color: white;
    font-size: 2.2rem;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s ease, background 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}
.nfx-slideshow-arrow:hover {
    opacity: 1;
    background: rgba(15, 23, 42, 0.8);
}
.nfx-slideshow-arrow--left {
    left: 0;
    border-radius: 0 8px 8px 0;
}
.nfx-slideshow-arrow--right {
    right: 0;
    border-radius: 8px 0 0 8px;
}

/* Slideshow Indicators (dots) */
.nfx-slideshow-indicators {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 4;
    display: flex;
    gap: 8px;
}
.nfx-ss-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.6);
    background: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}
.nfx-ss-dot:hover {
    border-color: #fff;
    background: rgba(255,255,255,0.3);
}
.nfx-ss-dot--active {
    background: var(--primary, #f59e0b);
    border-color: var(--primary, #f59e0b);
    transform: scale(1.2);
}

/* Hide carousel dots on mobile (useless on small screens, swipe is enough) */
@media (max-width: 768px) {
    .nfx-slideshow-indicators { display: none !important; }
    .nfx-slideshow-arrow { width: 32px; height: 32px; font-size: 1.2rem; }
}

/* Slideshow Admin button */
.nfx-slideshow-admin {
    position: absolute;
    top: 0.8rem;
    right: 0.8rem;
    z-index: 5;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.7);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    opacity: 0;
}
.nfx-slideshow:hover .nfx-slideshow-admin {
    opacity: 1;
}
.nfx-slideshow-admin:hover {
    background: rgba(15, 23, 42, 0.8);
    color: #fff;
    border-color: rgba(255,255,255,0.4);
}

/* Slideshow Empty State */
.nfx-slideshow-empty {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.5);
    font-size: 1.1rem;
    text-align: center;
    background: linear-gradient(-45deg, #1e3a8a, #2563eb, #0f172a);
    background-size: 300% 300%;
    animation: gradient-shift 12s ease infinite;
}

/* ─── SLIDESHOW ADMIN MODAL ──────────────── */
.nfx-ss-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.nfx-ss-modal-overlay.nfx-ss-modal--visible {
    opacity: 1;
}
.nfx-ss-modal {
    background: #1e293b;
    border-radius: 16px;
    width: 90%;
    max-width: 520px;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.1);
    transform: translateY(20px);
    transition: transform 0.3s ease;
}
.nfx-ss-modal--visible .nfx-ss-modal {
    transform: translateY(0);
}
.nfx-ss-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.nfx-ss-modal-header h3 {
    margin: 0;
    color: #fff;
    font-size: 1.1rem;
}
.nfx-ss-modal-close {
    background: none;
    border: none;
    color: rgba(255,255,255,0.6);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all 0.2s;
}
.nfx-ss-modal-close:hover {
    background: rgba(255,255,255,0.1);
    color: #fff;
}
.nfx-ss-modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}
.nfx-ss-field {
    margin-bottom: 18px;
}
.nfx-ss-field label {
    display: block;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.7);
    margin-bottom: 6px;
}
.nfx-ss-field input[type="range"] {
    width: calc(100% - 60px);
    vertical-align: middle;
    accent-color: var(--primary, #f59e0b);
}
.nfx-ss-field span {
    display: inline-block;
    width: 50px;
    text-align: right;
    color: var(--primary, #f59e0b);
    font-weight: 600;
    font-size: 0.9rem;
}
.nfx-ss-checkboxes label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255,255,255,0.85);
    font-size: 0.9rem;
    margin-bottom: 8px;
    cursor: pointer;
}
.nfx-ss-checkboxes input[type="checkbox"] {
    accent-color: var(--primary, #f59e0b);
    width: 16px;
    height: 16px;
}
.nfx-ss-slides-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 200px;
    overflow-y: auto;
}
.nfx-ss-slide-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    background: rgba(255,255,255,0.05);
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.08);
}
.nfx-ss-slide-item input[type="checkbox"] {
    accent-color: var(--primary, #f59e0b);
    flex-shrink: 0;
}
.nfx-ss-slide-thumb {
    width: 60px;
    height: 34px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
}
.nfx-ss-slide-item span {
    color: rgba(255,255,255,0.85);
    font-size: 0.85rem;
    text-align: left;
    width: auto;
}
.nfx-ss-hint {
    margin: 0;
    padding: 10px 12px;
    background: rgba(255,255,255,0.05);
    border-radius: 8px;
    color: rgba(255,255,255,0.5);
    font-size: 0.8rem;
}
.nfx-ss-hint code {
    color: var(--primary, #f59e0b);
    background: rgba(255,255,255,0.08);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.78rem;
}
.nfx-ss-modal-footer {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    padding: 14px 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
}
.nfx-ss-btn {
    padding: 8px 20px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}
.nfx-ss-btn--primary {
    background: var(--primary, #f59e0b);
    color: #fff;
}
.nfx-ss-btn--primary:hover {
    background: var(--primary-dark, #d97706);
    transform: scale(1.03);
}
.nfx-ss-btn--secondary {
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.8);
    border: 1px solid rgba(255,255,255,0.15);
}
.nfx-ss-btn--secondary:hover {
    background: rgba(255,255,255,0.18);
}

/* ─── ACTION DOCK ─────────────────────────── */
.nfx-dock {
    display: flex;
    justify-content: center;
    gap: 0;
    padding: 0.5rem var(--nfx-side-pad);
    background: var(--surface, #ffffff);
    border-bottom: 1px solid var(--border, #e5e7eb);
    margin-bottom: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    -ms-overflow-style: none;
    scrollbar-width: none;
    flex-shrink: 0;
}

.nfx-dock::-webkit-scrollbar { display: none; }

.nfx-dock-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.15rem;
    padding: 0.5rem 1.1rem;
    cursor: pointer;
    border-radius: 10px;
    transition: all 0.2s ease;
    flex-shrink: 0;
    user-select: none;
    -webkit-user-select: none;
}

.nfx-dock-item:hover {
    background: rgba(245, 158, 11, 0.08);
}

.nfx-dock-item:active {
    transform: scale(0.95);
}

.nfx-dock-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--surface-alt, #f3f4f6);
    color: var(--text-secondary, #64748b);
    transition: all 0.2s ease;
}

.nfx-dock-icon svg {
    width: 20px;
    height: 20px;
}

.nfx-dock-item:hover .nfx-dock-icon {
    background: rgba(245, 158, 11, 0.12);
    color: var(--primary, #f59e0b);
}

.nfx-dock-label {
    font-size: 0.65rem;
    color: var(--text-muted, #6b7280);
    white-space: nowrap;
    font-weight: 500;
    letter-spacing: 0.01em;
}

.nfx-dock-item:hover .nfx-dock-label {
    color: var(--primary, #f59e0b);
}

/* ─── STATS BADGE (compact inline) ────────── */
.nfx-stats {
    display: flex;
    justify-content: center;
    gap: 0.8rem;
    padding: 0.6rem var(--nfx-side-pad);
    flex-wrap: wrap;
}

.nfx-stats-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.8rem;
    background: rgba(245, 158, 11, 0.06);
    border: 1px solid rgba(245, 158, 11, 0.15);
    border-radius: 20px;
    font-size: 0.78rem;
    color: var(--text-muted, #4b5563);
}

.nfx-stats-value {
    font-weight: 700;
    color: var(--primary-text, #92400e);
    font-family: var(--font-heading, 'Outfit', sans-serif);
}

/* ─── CATEGORY ROWS ───────────────────────── */
.nfx-row {
    padding: 0.8rem 0 0.4rem;
}

.nfx-row-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--nfx-side-pad) 0.5rem;
}

.nfx-row-title {
    font-family: var(--font-heading, 'Outfit', sans-serif);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text, #1f2937);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
}

.nfx-row-title .category-icon-animated {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}
.nfx-row-title .category-icon-animated svg {
    width: 100%;
    height: 100%;
}

.nfx-row-count {
    font-size: 0.82rem;
    font-weight: 400;
    color: var(--text-muted, #4b5563);
}

.nfx-row-link {
    font-size: 0.8rem;
    color: var(--primary, #f59e0b);
    text-decoration: none;
    cursor: pointer;
    font-weight: 500;
    transition: color 0.2s;
    white-space: nowrap;
}

.nfx-row-link:hover {
    color: var(--primary-dark, #d97706);
    text-decoration: underline;
}

/* Scroll container with arrows */
.nfx-row-scroll-container {
    position: relative;
}

.nfx-row-scroll {
    display: flex;
    gap: var(--nfx-row-gap);
    padding: 0.25rem var(--nfx-side-pad) 0.5rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.nfx-row-scroll::-webkit-scrollbar { display: none; }

/* Navigation Arrows */
.nfx-row-arrow {
    position: absolute;
    top: 0;
    bottom: 0.5rem;
    width: 48px;
    background: var(--nfx-dark-60);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    opacity: 0.3;
    transition: opacity 0.3s ease, background 0.2s ease;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.nfx-row-scroll-container:hover .nfx-row-arrow:not(.nfx-hidden) {
    opacity: 1;
}

.nfx-row-arrow:hover {
    opacity: 1;
    background: var(--nfx-dark-80);
}

.nfx-row-arrow--left {
    left: 0;
    border-radius: 0 6px 6px 0;
}

.nfx-row-arrow--right {
    right: 0;
    border-radius: 6px 0 0 6px;
}

.nfx-row-arrow.nfx-hidden {
    display: none;
}

/* ─── COURSE CARDS v2 (informative) ──────── */
.nfx-card {
    flex-shrink: 0;
    width: 260px;
    min-width: 220px;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    scroll-snap-align: start;
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: var(--surface, #ffffff);
    border: 1px solid var(--border, #e5e7eb);
    display: flex;
    flex-direction: column;
}

.nfx-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
    z-index: 10;
    border-color: rgba(245, 158, 11, 0.3);
}

/* Card Header — colored gradient + thumbnail */
.nfx-card-header {
    padding: 0.75rem 0.85rem;
    position: relative;
    min-height: 120px;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}

.nfx-card-thumb {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    z-index: 0;
}

/* Gradient overlay for text readability on thumbnail */
.nfx-card-header::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0,0,0,0.65) 0%, rgba(0,0,0,0.15) 55%, transparent 100%);
    pointer-events: none;
    z-index: 1;
}

.nfx-card-header > *:not(.nfx-card-thumb) {
    position: relative;
    z-index: 2;
}

.nfx-card-header-content {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    width: 100%;
    gap: 0.4rem;
}

.nfx-card-header-title {
    font-family: var(--font-heading, 'Outfit', sans-serif);
    font-size: 0.82rem;
    font-weight: 600;
    color: #fff;
    line-height: 1.25;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
    flex: 1;
}

.nfx-card-header-badge {
    font-size: 0.62rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.88);
    background: rgba(0, 0, 0, 0.25);
    padding: 0.12rem 0.4rem;
    border-radius: 4px;
    white-space: nowrap;
    flex-shrink: 0;
}

/* Nouveau badge */
.nfx-card-new {
    position: absolute;
    top: 7px;
    left: 7px;
    padding: 0.12rem 0.45rem;
    background: linear-gradient(135deg, #22c55e, #16a34a);
    border-radius: 4px;
    font-size: 0.58rem;
    font-weight: 700;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    z-index: 2;
    animation: badge-pulse 2s ease-in-out infinite;
}

@keyframes badge-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Card Body — topics list */
.nfx-card-body {
    padding: 0.55rem 0.75rem;
    flex: 1;
    min-height: 90px;
}

.nfx-topics-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.nfx-topic-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.7rem;
    color: var(--text-secondary, #4b5563);
    line-height: 1.3;
}

.nfx-topic-check {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 1.5px solid var(--border, #d1d5db);
    flex-shrink: 0;
    position: relative;
    transition: all 0.2s;
    box-sizing: border-box;
}

.nfx-topic-check--done {
    background: #22c55e;
    border-color: #22c55e;
}

.nfx-topic-check--done::after {
    content: '\2713';
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.5rem;
    font-weight: 700;
}

.nfx-topic-text {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nfx-topic-more {
    font-size: 0.65rem;
    color: var(--primary, #f59e0b);
    font-style: italic;
    padding-left: 1.25rem;
}

/* Card Footer — progress + info */
.nfx-card-footer {
    padding: 0.45rem 0.75rem 0.55rem;
    border-top: 1px solid var(--border, #f0f0f0);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nfx-progress-row {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.nfx-progress-bar {
    flex: 1;
    height: 4px;
    background: var(--border, #e5e7eb);
    border-radius: 2px;
    overflow: hidden;
}

.nfx-progress-fill {
    height: 100%;
    border-radius: 2px;
    transition: width 0.5s ease;
}

.nfx-progress-text {
    font-size: 0.63rem;
    font-weight: 600;
    color: var(--text-muted, #6b7280);
    min-width: 26px;
    text-align: right;
}

.nfx-info-btn {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: none;
    background: var(--surface-alt, #f3f4f6);
    color: var(--text-muted, #6b7280);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    flex-shrink: 0;
    padding: 0;
}

.nfx-info-btn:hover {
    background: var(--primary, #f59e0b);
    color: white;
    transform: scale(1.1);
}

/* ─── HERO DETAILS BUTTON ────────────────── */
.nfx-hero-btn--info {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 0.65rem 1.5rem;
    border-radius: 8px;
    color: white;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s;
}

.nfx-hero-btn--info:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* ─── COURSE INFO POPUP ──────────────────── */
.nfx-popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: nfx-fade-in 0.2s ease;
    backdrop-filter: blur(4px);
}

@keyframes nfx-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes nfx-slide-up {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.nfx-popup-card {
    background: var(--surface, #fff);
    border-radius: 16px;
    width: 92%;
    max-width: 520px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: nfx-slide-up 0.3s ease;
}

.nfx-popup-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 30px;
    height: 30px;
    border: none;
    background: rgba(0, 0, 0, 0.3);
    color: white;
    font-size: 1.2rem;
    border-radius: 50%;
    cursor: pointer;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    line-height: 1;
}

.nfx-popup-close:hover {
    background: rgba(0, 0, 0, 0.5);
}

.nfx-popup-header {
    padding: 1.4rem 1.2rem 1rem;
    border-radius: 16px 16px 0 0;
}

.nfx-popup-header h3 {
    color: white;
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    padding-right: 2rem;
    line-height: 1.3;
}

.nfx-popup-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    padding: 0.75rem 1.2rem;
}

.nfx-popup-meta-item {
    font-size: 0.72rem;
    padding: 0.2rem 0.55rem;
    background: var(--surface-alt, #f3f4f6);
    border-radius: 12px;
    color: var(--text-secondary, #4b5563);
    font-weight: 500;
}

.nfx-popup-desc {
    padding: 0 1.2rem 0.5rem;
    font-size: 0.8rem;
    color: var(--text-secondary, #4b5563);
    line-height: 1.55;
    margin: 0;
}

.nfx-popup-section-title {
    padding: 0.6rem 1.2rem 0.3rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text, #1f2937);
    margin: 0;
}

.nfx-popup-topics {
    list-style: none;
    padding: 0 1.2rem 0.6rem;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.nfx-popup-topic {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--text-secondary, #4b5563);
    padding: 0.2rem 0;
}

.nfx-popup-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    padding: 0 1.2rem 0.6rem;
}

.nfx-popup-tag {
    font-size: 0.65rem;
    padding: 0.15rem 0.45rem;
    background: var(--primary-light, #fef3c7);
    color: var(--primary-dark, #92400e);
    border-radius: 4px;
    font-weight: 500;
}

.nfx-popup-actions {
    padding: 0.8rem 1.2rem 1rem;
    border-top: 1px solid var(--border, #e5e7eb);
}

.nfx-popup-launch {
    width: 100%;
    padding: 0.7rem;
    background: var(--primary, #f59e0b);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.nfx-popup-launch:hover {
    background: var(--primary-dark, #d97706);
    transform: scale(1.01);
}

/* ─── RESUME ROW ─────────────────────────── */
.nfx-row--resume {
    padding-top: 1rem;
}

.nfx-row--resume .nfx-row-title {
    color: var(--primary, #f59e0b);
}

/* ─── RESUME DROPDOWN (native <details>) ──── */
.nfx-resume-dropdown-wrap {
    position: relative;
}
/* Hide dropdown when <details> is closed — position:absolute escapes
   the browser's native content-visibility hiding on closed <details> */
.nfx-resume-dropdown-wrap:not([open]) > .nfx-resume-dropdown {
    display: none !important;
}

.nfx-resume-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.85rem;
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    background: rgba(255,255,255,0.06);
    color: var(--text-muted, #94a3b8);
    font-size: 0.78rem;
    font-weight: 500;
    font-family: var(--font-heading, 'Outfit', sans-serif);
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    list-style: none;
}
.nfx-resume-dropdown-btn::-webkit-details-marker { display: none; }
.nfx-resume-dropdown-btn::marker { display: none; content: ''; }
.nfx-resume-dropdown-btn:hover {
    background: rgba(255,255,255,0.12);
    border-color: var(--primary, #f59e0b);
    color: var(--text, #e2e8f0);
}
.nfx-resume-dropdown-icon {
    font-size: 0.6rem;
    transition: transform 0.2s;
}
details[open] > .nfx-resume-dropdown-btn .nfx-resume-dropdown-icon {
    transform: rotate(180deg);
}

.nfx-resume-dropdown {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 220px;
    background: var(--card-bg, #1e293b);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.5);
    padding: 0.5rem;
    z-index: 200;
    animation: nfx-dropdown-in 0.2s ease;
}
@keyframes nfx-dropdown-in {
    from { opacity: 0; transform: translateY(-8px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.nfx-resume-section-label {
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted, #64748b);
    padding: 0.4rem 0.6rem 0.2rem;
}

.nfx-resume-opt {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.5rem 0.7rem;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--text, #e2e8f0);
    font-size: 0.8rem;
    font-family: var(--font, 'Inter', sans-serif);
    cursor: pointer;
    text-align: left;
    transition: background 0.15s;
}
.nfx-resume-opt:hover {
    background: rgba(255,255,255,0.08);
}
.nfx-resume-opt--active {
    background: rgba(245,158,11,0.15);
    color: var(--primary, #f59e0b);
    font-weight: 600;
}
.nfx-resume-opt--active:hover {
    background: rgba(245,158,11,0.25);
}
.nfx-resume-opt--danger {
    color: #ef4444;
}
.nfx-resume-opt--danger:hover {
    background: rgba(239,68,68,0.12);
}

.nfx-resume-divider {
    height: 1px;
    background: rgba(255,255,255,0.08);
    margin: 0.35rem 0.3rem;
}

/* ─── SKELETON LOADING ────────────────────── */
.nfx-skeleton-hero {
    height: 45vh;
    min-height: 250px;
    max-height: 450px;
    background: linear-gradient(135deg, #e5e7eb, #f3f4f6);
    position: relative;
    overflow: hidden;
}

.nfx-skeleton-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: shimmer 1.5s infinite;
    transform: translateX(-100%);
}

@keyframes shimmer {
    100% { transform: translateX(100%); }
}

.nfx-skeleton-row {
    padding: 1rem var(--nfx-side-pad);
}

.nfx-skeleton-row-title {
    width: 220px;
    height: 20px;
    background: #e5e7eb;
    border-radius: 4px;
    margin-bottom: 0.8rem;
}

.nfx-skeleton-cards {
    display: flex;
    gap: var(--nfx-row-gap);
}

.nfx-skeleton-card {
    flex-shrink: 0;
    width: 260px;
    min-width: 220px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e5e7eb;
}

.nfx-skeleton-header {
    height: 68px;
    background: #e5e7eb;
    position: relative;
    overflow: hidden;
}

.nfx-skeleton-header::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: shimmer 1.5s infinite;
    transform: translateX(-100%);
}

.nfx-skeleton-body {
    padding: 0.6rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.nfx-skeleton-line {
    height: 10px;
    background: #e5e7eb;
    border-radius: 3px;
    width: 100%;
}

.nfx-skeleton-line.short {
    width: 60%;
}

.nfx-skeleton-footer {
    height: 34px;
    border-top: 1px solid #f0f0f0;
    background: #fafafa;
}

/* ─── RESPONSIVE — Tablet ─────────────────── */
@media (max-width: 1200px) {
    .nfx-hero {
        height: 40vh;
    }

    .nfx-hero-content {
        right: 20%;
    }

    .nfx-card {
        width: 240px;
        min-width: 200px;
    }

    .nfx-skeleton-card {
        width: 240px;
        min-width: 200px;
    }
}

/* ─── RESPONSIVE — Mobile ─────────────────── */
@media (max-width: 768px) {
    .nfx-hero {
        height: 38vh;
        min-height: 220px;
    }

    .nfx-hero-content {
        right: 8%;
        left: 5%;
        bottom: 1.5rem;
    }

    .nfx-hero-title {
        font-size: 1.3rem;
    }

    .nfx-hero-desc {
        display: none;
    }

    .nfx-hero-btn {
        padding: 0.6rem 1.4rem;
        font-size: 0.9rem;
    }

    .nfx-hero-btn--info {
        padding: 0.5rem 1rem;
        font-size: 0.82rem;
    }

    .nfx-card {
        width: 220px;
        min-width: 180px;
    }

    .nfx-card-header-title {
        font-size: 0.75rem;
    }

    .nfx-topic-item {
        font-size: 0.65rem;
    }

    .nfx-skeleton-card {
        width: 220px;
        min-width: 180px;
    }

    .nfx-dock {
        justify-content: flex-start;
        gap: 0;
    }

    .nfx-dock-item {
        padding: 0.4rem 0.8rem;
    }

    .nfx-dock-icon {
        font-size: 1.2rem;
    }

    .nfx-dock-label {
        font-size: 0.62rem;
    }

    .nfx-row-arrow {
        width: 36px;
        font-size: 1.4rem;
    }

    .nfx-slideshow-arrow {
        width: 36px;
        height: 48px;
        font-size: 1.6rem;
    }
    .nfx-slide-content {
        right: 8%;
        left: 5%;
        bottom: 2rem;
    }
    .nfx-slide-title {
        font-size: 1.3rem;
    }
    .nfx-slide-subtitle {
        display: none;
    }
    .nfx-ss-modal {
        width: 96%;
        max-height: 90vh;
    }

    .nfx-stats {
        gap: 0.5rem;
    }

    .nfx-stats-item {
        padding: 0.2rem 0.6rem;
        font-size: 0.72rem;
    }

    .nfx-popup-card {
        width: 96%;
        max-height: 90vh;
    }
}

/* ─── RESPONSIVE — Small Mobile ───────────── */
@media (max-width: 480px) {
    .nfx-hero {
        height: 32vh;
    }

    .nfx-card {
        width: 200px;
        min-width: 170px;
    }

    .nfx-card-body {
        min-height: 70px;
        padding: 0.4rem 0.6rem;
    }

    .nfx-skeleton-card {
        width: 200px;
        min-width: 170px;
    }

    .nfx-hero-meta {
        display: none;
    }
}

/* ─── ACCESSIBILITY ───────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .nfx-hero-bg--fallback,
    .nfx-card-new {
        animation: none;
    }

    .nfx-card:hover {
        transform: none;
    }

    .nfx-skeleton-hero::after,
    .nfx-skeleton-header::after {
        animation: none;
    }

    .nfx-popup-overlay,
    .nfx-popup-card {
        animation: none;
    }

    .nfx-hero-content {
        animation: none;
    }
}

/* ============================================
   TAB BAR — Navigation par onglets
   ============================================ */
.nfx-tabs {
    display: flex;
    justify-content: center;
    gap: 4px;
    padding: 10px var(--nfx-side-pad, 4%) 10px;
    margin-bottom: 20px;
    background: var(--nfx-dark, #0f172a);
    position: sticky;
    top: 0;
    z-index: 500;
}

.nfx-tab {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 10px 20px;
    border: none;
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.6);
    font-size: 14px;
    font-weight: 600;
    border-radius: 10px 10px 0 0;
    cursor: pointer;
    transition: all 0.25s ease;
    border-bottom: 3px solid transparent;
    white-space: nowrap;
}

.nfx-tab:hover {
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.85);
}

.nfx-tab-active {
    background: rgba(245, 158, 11, 0.12);
    color: #f59e0b;
    border-bottom-color: #f59e0b;
}

.nfx-tab .tab-icon {
    font-size: 16px;
}

.nfx-tab .tab-count {
    font-size: 11px;
    background: rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.7);
    padding: 1px 7px;
    border-radius: 10px;
    font-weight: 500;
}

.nfx-tab-active .tab-count {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

/* Masquage des sections par onglet */
.nfx-section-hidden {
    display: none !important;
}

/* ============================================
   API CARDS — Cartes interactives
   ============================================ */
.nfx-api-section {
    padding: 20px var(--nfx-side-pad, 4%) 30px;
    background: #0f172a;
    border-radius: 16px;
    margin: 0 var(--nfx-side-pad, 4%) 20px;
}

.nfx-api-section h2 {
    color: #fff;
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 4px 0;
}

.nfx-api-section > p {
    color: rgba(255,255,255,0.6);
    font-size: 13px;
    margin: 0 0 16px 0;
}

.nfx-api-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.nfx-api-card {
    background: linear-gradient(145deg, #1e293b, #1a2332);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 16px;
    padding: 24px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nfx-api-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.3);
}

.nfx-api-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.nfx-api-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 800;
    color: #fff;
    flex-shrink: 0;
}

.nfx-api-card-title {
    font-size: 17px;
    font-weight: 700;
    color: #fff;
}

.nfx-api-card-desc {
    font-size: 13px;
    color: rgba(255,255,255,0.7);
    margin-top: 2px;
}

.nfx-api-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 16px;
}

.nfx-api-field {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.nfx-api-field label {
    font-size: 11px;
    font-weight: 600;
    color: rgba(255,255,255,0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nfx-api-field select,
.nfx-api-field input[type="number"],
.nfx-api-field input[type="text"] {
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.18);
    background: rgba(0,0,0,0.4);
    color: #fff;
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
}

.nfx-api-field select option {
    background: #1e293b;
    color: #fff;
}

.nfx-api-field select:focus,
.nfx-api-field input:focus {
    border-color: #f59e0b;
}

.nfx-api-field-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nfx-api-field-row input[type="checkbox"] {
    accent-color: #f59e0b;
    width: 16px;
    height: 16px;
}

.nfx-api-field-row label {
    font-size: 13px;
    color: rgba(255,255,255,0.7);
    text-transform: none;
    letter-spacing: 0;
}

.nfx-api-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 4px;
}

.nfx-api-btn:hover {
    filter: brightness(1.15);
    transform: translateY(-1px);
}

.nfx-api-btn:disabled {
    opacity: 0.5;
    cursor: wait;
}

.nfx-api-result {
    margin-top: 14px;
    padding: 14px;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.6;
    color: #fff;
    animation: nfxApiFadeIn 0.3s ease;
    display: none;
}

.nfx-api-result.visible {
    display: block;
}

.nfx-api-result .result-value {
    font-size: 22px;
    font-weight: 800;
    display: block;
    margin: 4px 0;
}

.nfx-api-result .result-detail {
    font-size: 12px;
    opacity: 0.8;
}

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

/* API Card color themes */
.nfx-api-card.api-advenir .nfx-api-card-icon { background: linear-gradient(135deg, #0c2340, #1a7a5a); }
.nfx-api-card.api-advenir .nfx-api-btn { background: linear-gradient(135deg, #0c2340, #1a7a5a); }
.nfx-api-card.api-advenir .nfx-api-result { background: rgba(26, 122, 90, 0.2); border: 1px solid rgba(26, 122, 90, 0.3); }

.nfx-api-card.api-enedis .nfx-api-card-icon { background: linear-gradient(135deg, #0e4d92, #1a9bd7); }
.nfx-api-card.api-enedis .nfx-api-btn { background: linear-gradient(135deg, #0e4d92, #1a9bd7); }
.nfx-api-card.api-enedis .nfx-api-result { background: rgba(26, 155, 215, 0.15); border: 1px solid rgba(26, 155, 215, 0.3); }

.nfx-api-card.api-urssaf .nfx-api-card-icon { background: linear-gradient(135deg, #6b21a8, #9333ea); }
.nfx-api-card.api-urssaf .nfx-api-btn { background: linear-gradient(135deg, #6b21a8, #9333ea); }
.nfx-api-card.api-urssaf .nfx-api-result { background: rgba(147, 51, 234, 0.15); border: 1px solid rgba(147, 51, 234, 0.3); }

/* ─── RESPONSIVE TABS ─────────── */
@media (max-width: 900px) {
    .nfx-api-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .nfx-tab {
        padding: 8px 14px;
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .nfx-tabs {
        justify-content: flex-start;
        gap: 6px;
        padding: 8px 12px;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
    }
    .nfx-tabs::-webkit-scrollbar { display: none; }
    .nfx-tab {
        padding: 10px 14px;
        font-size: 13px;
        flex-shrink: 0;
        scroll-snap-align: start;
        min-height: 44px;
    }
    .nfx-tab .tab-label {
        display: inline;
        font-size: 12px;
    }
    .nfx-tab .tab-count {
        font-size: 10px;
        padding: 1px 6px;
    }
}

@media (max-width: 480px) {
    .nfx-api-grid {
        grid-template-columns: 1fr;
    }
    .nfx-tab .tab-label {
        display: none;
    }
    .nfx-tab {
        padding: 10px 12px;
        gap: 5px;
    }
    .nfx-tab .tab-icon {
        font-size: 18px;
    }
    .nfx-tab .tab-count {
        font-size: 11px;
    }
}

/* ─── OUTILS TAB HEADER ──────────────────── */

.nfx-outils-header {
    margin: 0.8rem 4% 1.2rem;
}
.nfx-outils-header-inner {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, rgba(59,130,246,0.10), rgba(139,92,246,0.08));
    border: 1px solid rgba(59,130,246,0.18);
    border-radius: 14px;
}
.nfx-outils-header-icon {
    font-size: 2.2rem;
    line-height: 1;
    flex-shrink: 0;
}
.nfx-outils-header-info h2 {
    font-family: 'Outfit', var(--font-heading, system-ui), sans-serif;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text, #e2e8f0);
    margin: 0 0 2px;
    letter-spacing: 0.02em;
}
.nfx-outils-header-info p {
    font-size: 0.78rem;
    color: var(--text-muted, #94a3b8);
    margin: 0;
}
.nfx-outils-header-stats {
    margin-left: auto;
    display: flex;
    gap: 1rem;
    flex-shrink: 0;
}
.nfx-outils-stat {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-muted, #94a3b8);
}
.nfx-outils-stat-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--stat-color);
}

/* ─── THEME VIEW ─────────────────────────── */

.nfx-theme { margin-bottom: 1.2rem; }

.nfx-theme-header {
    padding: 0.6rem 1.5rem;
    border-radius: 10px;
    margin: 0 4% 0.3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    justify-content: center;
    gap: 0.6rem;
    border: none;
    cursor: pointer;
    width: calc(100% - 8%);
    transition: filter 0.2s;
    color: #fff;
    font-size: inherit;
}

.nfx-theme-header:hover { filter: brightness(1.15); }

.nfx-theme-emoji { font-size: 1.3rem; }

.nfx-theme-header h2 {
    color: #fff;
    font-size: 1.1rem;
    margin: 0;
    font-family: 'Outfit', var(--font-heading, system-ui), sans-serif;
    line-height: 1;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-weight: 700;
}

.nfx-theme-count {
    color: rgba(255,255,255,0.7);
    font-size: 0.8rem;
    margin-left: 0.3rem;
}

.nfx-theme-chevron {
    position: absolute;
    right: 1.2rem;
    font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
    transition: transform 0.3s ease;
}

.nfx-theme-body {
    display: none;
    animation: nfxFadeIn 0.3s ease;
}

.nfx-theme-body.visible {
    display: block;
}

.nfx-theme-header p { display: none; }

/* Subtheme collapsible toggle */
.nfx-subtheme { margin: 0.4rem 0 0.6rem; }

.nfx-subtheme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: calc(100% - 10%);
    margin: 0 5%;
    padding: 0.45rem 1.2rem;
    background: linear-gradient(135deg, var(--sub-color, #6366f1), color-mix(in srgb, var(--sub-color, #6366f1), #000 25%));
    opacity: 0.75;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s;
    color: #fff;
    font-size: inherit;
    position: relative;
}

.nfx-subtheme-toggle:hover {
    opacity: 0.9;
    filter: brightness(1.1);
}

.nfx-subtheme-title {
    color: #fff;
    font-size: 0.88rem;
    font-weight: 700;
    font-family: 'Outfit', var(--font-heading, system-ui), sans-serif;
    border-left: none;
    padding-left: 0;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.nfx-subtheme-count {
    color: rgba(255,255,255,0.7);
    font-size: 0.75rem;
    margin-left: 0.3rem;
}

.nfx-subtheme-chevron {
    position: absolute;
    right: 1rem;
    font-size: 0.75rem;
    color: rgba(255,255,255,0.7);
    transition: transform 0.3s ease;
}

.nfx-subtheme-content {
    display: none;
    animation: nfxFadeIn 0.3s ease;
}

.nfx-subtheme-content.visible {
    display: block;
}

/* Center cards within theme slider rows */
.nfx-theme .nfx-slider {
    justify-content: center;
}

/* Socle collapsible */
.nfx-socle-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(59,130,246,0.1);
    border: 1px solid rgba(59,130,246,0.3);
    color: #60a5fa;
    padding: 0.8rem 1.5rem;
    border-radius: 12px;
    cursor: pointer;
    margin: 1rem 4%;
    font-size: 0.95rem;
    transition: all 0.3s;
    width: auto;
}

.nfx-socle-toggle:hover {
    background: rgba(59,130,246,0.2);
}

.nfx-socle-chevron {
    margin-left: auto;
    font-size: 0.75rem;
    transition: transform 0.3s;
}

.nfx-socle-content {
    display: none;
    animation: nfxFadeIn 0.3s ease;
}

.nfx-socle-content.visible { display: block; }

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

/* View toggle button in dock */
.nfx-view-toggle {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    color: #e2e8f0;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.3s;
    white-space: nowrap;
    flex-shrink: 0;
}

.nfx-view-toggle:hover {
    background: rgba(255,255,255,0.2);
}

.nfx-view-toggle.active {
    background: rgba(99,102,241,0.3);
    border-color: #6366f1;
}

/* Responsive adjustments for theme view */
@media (max-width: 768px) {
    .nfx-theme-header {
        padding: 1rem 4%;
        border-radius: 12px;
    }
    .nfx-theme-header h2 { font-size: 1.3rem; }
    .nfx-theme-emoji { font-size: 2rem; }
    .nfx-view-toggle { padding: 0.4rem 0.8rem; font-size: 0.8rem; }
}

/* ─── INACTIVE COURSES ("Autre cours" tab) ── */

.nfx-inactive-section {
    padding: 0 1rem 2rem;
}

.nfx-inactive-intro {
    padding: 1.5rem 0 0.5rem;
}

.nfx-inactive-intro h2 {
    color: rgba(255,255,255,0.9);
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.nfx-inactive-intro p {
    color: rgba(255,255,255,0.45);
    font-size: 0.85rem;
    margin: 0;
    line-height: 1.5;
}

.nfx-inactive-status-group {
    margin-bottom: 1.5rem;
}

.nfx-inactive-status-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.7rem 1rem;
    margin: 1rem 0 0.5rem;
    background: rgba(255,255,255,0.04);
    border-radius: 8px;
}

.nfx-inactive-status-icon {
    font-size: 1.2rem;
}

.nfx-inactive-status-label {
    font-size: 1rem;
    font-weight: 600;
    color: rgba(255,255,255,0.85);
}

.nfx-inactive-status-count {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.4);
    margin-left: auto;
}

/* Inactive row styling — slightly dimmed */
.nfx-row--inactive .nfx-row-title {
    opacity: 0.7;
}

/* Inactive card — slight desaturation and opacity */
.nfx-card--inactive {
    position: relative;
    filter: saturate(0.6);
    transition: filter 0.3s ease, transform 0.2s ease;
}

.nfx-card--inactive:hover {
    filter: saturate(1);
    transform: translateY(-4px);
}

/* Status badge on card */
.nfx-card-status-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.65rem;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 2;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

/* Notes line on inactive cards */
.nfx-inactive-notes {
    font-size: 0.72rem;
    color: rgba(255,255,255,0.4);
    font-style: italic;
    padding: 0 0 0.4rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    margin-bottom: 0.4rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ─── PRINT — Hide Netflix layout ─────────── */
@media print {
    .nfx-home { display: none; }
}
