/* TutorLab Pro LMS v5 — Frontend CSS
   Palette : #8B9CE2 (primaire) · #0F172A (nuit) · #E5F8F6 (menthe) · #EFF2FB (bleu doux) */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700&display=swap');

:root {
    --tp:  #8B9CE2;   /* Bleu Pervenche */
    --tpd: #6B7FD4;   /* Pervenche foncé */
    --dk:  #0F172A;   /* Bleu Nuit */
    --mn:  #E5F8F6;   /* Fond Menthe */
    --sb:  #EFF2FB;   /* Fond Bleu Doux */
    --gr:  #2ecc71;
    --rd:  #EF4444;
    --or:  #F59E0B;
    --wa:  #25D366;
    --br:  #D1D9F5;   /* Bordure pervenche claire */
    --tx:  #0F172A;
    --tx2: #64748B;
    --sf:  #F8FAFF;
    --r:   14px;
    --rs:  10px;
    --bar-h: 52px;
}

/* ══════════════════════════════
   BARRE FRONT-END — CORRIGÉE
   La barre est fixed, le body
   reçoit padding-top via JS/PHP
══════════════════════════════ */
#tlp-bar {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--bar-h);
    z-index: 99999;
    background: #ffffff;
    border-bottom: 1px solid #E8EAF2;
    -webkit-box-shadow: 0 1px 12px rgba(139,156,226,.12);
            box-shadow: 0 1px 12px rgba(139,156,226,.12);
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    -webkit-box-pack: justify;
        -ms-flex-pack: justify;
            justify-content: space-between;
    padding: 0 20px;
    -webkit-box-sizing: border-box;
            box-sizing: border-box;
}

body.tlp-has-bar { padding-top: var(--bar-h) !important; }
body.tlp-has-bar .elementor-location-header { top: var(--bar-h) !important; }

/* ── Fix : barre de navigation des leçons (#nav) ──
   #nav est position:fixed;top:0 → masqué par la barre TutorLab.
   On le décale vers le bas de la hauteur de la barre.
   #app a padding-top:82px (hauteur #nav) → on ajoute la même valeur. */
body.tlp-has-bar #nav {
    top: var(--bar-h, 52px) !important;
}
body.tlp-has-bar #app {
    padding-top: calc(82px + var(--bar-h, 52px)) !important;
}
/* Sections Elementor sticky (autres pages) */
body.tlp-has-bar .elementor-sticky--active { top: var(--bar-h, 52px) !important; }
body.tlp-has-bar .e-sticky-up             { top: var(--bar-h, 52px) !important; }

.tlp-bar-logo {
    text-decoration: none;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    -ms-flex-negative: 0;
        flex-shrink: 0;
}
.tlp-brand { color: var(--tp); font-weight: 700; font-size: 16px; letter-spacing: -.02em; }
.tlp-bar-right {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    gap: 10px;
}
.tlp-bar-level {
    font-size: 10px; font-weight: 700; letter-spacing: .08em;
    text-transform: uppercase;
    background: var(--sb); color: var(--tp);
    padding: 3px 11px; border-radius: 100px;
    border: 1px solid var(--br);
    white-space: nowrap;
}
.tlp-bar-exp { font-size: 11px; color: var(--tx2); white-space: nowrap; }
.tlp-urgent { background: #FEF2F2 !important; border-color: #FCA5A5 !important; color: var(--rd) !important; }
.tlp-exp-urgent { color: var(--rd) !important; font-weight: 700; }

.tlp-bar-user {
    position: relative;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    gap: 7px;
    cursor: pointer;
    padding: 4px 0;
    -webkit-user-select: none;
       -moz-user-select: none;
        -ms-user-select: none;
            user-select: none;
}
.tlp-bar-av {
    width: 32px; height: 32px; border-radius: 50%;
    background: var(--tp); color: #fff;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    -webkit-box-pack: center;
        -ms-flex-pack: center;
            justify-content: center;
    font-size: 13px; font-weight: 700;
    -ms-flex-negative: 0; flex-shrink: 0;
}
.tlp-bar-nm { font-size: 13px; color: var(--tx); font-weight: 600; }
.tlp-caret { color: var(--tx2); -ms-flex-negative: 0; flex-shrink: 0; }
.tlp-bar-drop {
    display: none; position: absolute; top: calc(100% + 8px); right: 0;
    background: #fff; border: 1px solid var(--br); border-radius: var(--rs);
    overflow: hidden; min-width: 170px;
    -webkit-box-shadow: 0 8px 32px rgba(15,23,42,.15);
            box-shadow: 0 8px 32px rgba(15,23,42,.15);
    z-index: 100000;
}
.tlp-bar-user:hover .tlp-bar-drop,
.tlp-bar-user:focus-within .tlp-bar-drop { display: block; }
.tlp-bar-drop a { display: block; padding: 11px 16px; font-size: 13px; color: var(--tx); text-decoration: none; border-bottom: 1px solid var(--sb); }
.tlp-bar-drop a:last-child { border-bottom: none; }
.tlp-bar-drop a:hover { background: var(--sb); color: var(--tp); }

/* ══════════════════════════
   TEMPLATE DE PAGE CUSTOM
══════════════════════════ */
.tlp-layout-header {
    background: var(--dk);
    padding: 0 24px;
    height: 60px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
}
.tlp-layout-header-inner {
    max-width: 900px; margin: 0 auto; width: 100%;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    -webkit-box-pack: justify;
        -ms-flex-pack: justify;
            justify-content: space-between;
}
.tlp-layout-brand { color: var(--tp); font-weight: 700; font-size: 18px; text-decoration: none; }
.tlp-layout-back { color: rgba(255,255,255,.6); font-size: 13px; text-decoration: none; }
.tlp-layout-back:hover { color: var(--tp); }
.tlp-layout-hero {
    background: -webkit-linear-gradient(135deg, var(--dk) 0%, #1e2a4a 100%);
    background:         linear-gradient(135deg, var(--dk) 0%, #1e2a4a 100%);
    padding: 48px 24px 40px;
    text-align: center;
}
.tlp-layout-hero-inner { max-width: 600px; margin: 0 auto; }
.tlp-hero-icon { font-size: 40px; display: block; margin-bottom: 12px; }
.tlp-hero-title { color: #fff; font-size: 28px; font-weight: 700; margin: 0 0 8px; letter-spacing: -.02em; }
.tlp-hero-sub { color: rgba(255,255,255,.6); font-size: 15px; margin: 0; }
.tlp-layout-main { max-width: 100%; }
.tlp-main-system { max-width: 900px; margin: 0 auto; padding: 32px 20px 60px; }
.tlp-main-course { padding: 0; }
.tlp-layout-footer {
    background: var(--dk);
    padding: 20px 24px;
    text-align: center;
    font-size: 13px;
    color: rgba(255,255,255,.4);
    margin-top: 40px;
}
.tlp-layout-footer-inner { max-width: 900px; margin: 0 auto; display: -webkit-box; display: -ms-flexbox; display: flex; -webkit-box-align: center; -ms-flex-align: center; align-items: center; -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; gap: 12px; -ms-flex-wrap: wrap; flex-wrap: wrap; }
.tlp-footer-sep { opacity: .3; }
.tlp-layout-footer a { color: rgba(255,255,255,.5); text-decoration: none; }
.tlp-layout-footer a:hover { color: var(--tp); }
.tlp-course-header {
    background: var(--dk);
    padding: 0 24px;
    height: 52px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    position: sticky;
    top: var(--bar-h);
    z-index: 100;
}
.tlp-course-header-inner {
    width: 100%; display: -webkit-box; display: -ms-flexbox; display: flex;
    -webkit-box-align: center; -ms-flex-align: center; align-items: center;
    -webkit-box-pack: justify; -ms-flex-pack: justify; justify-content: space-between;
    gap: 12px;
}
.tlp-course-header-center { -webkit-box-flex: 1; -ms-flex: 1; flex: 1; text-align: center; }
.tlp-course-title { color: rgba(255,255,255,.8); font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ══════════════════════════
   FORMULAIRES (BOUCLIER ANTI-ELEMENTOR)
══════════════════════════ */
.tlp-form-box {
    max-width: 520px !important; margin: 0 auto !important; background: #fff !important;
    border: 1px solid var(--br) !important; border-radius: var(--r) !important;
    overflow: hidden !important;
    -webkit-box-shadow: 0 4px 32px rgba(139,156,226,.12) !important;
            box-shadow: 0 4px 32px rgba(139,156,226,.12) !important;
    font-family: 'Outfit', sans-serif !important; /* Force la police globale de la box */
    letter-spacing: normal !important;
}
.tlp-form-head { background: var(--dk) !important; padding: 28px 32px 22px !important; }
.tlp-form-head h2 { color: var(--tp) !important; font-size: 20px !important; font-weight: 700 !important; margin: 0 0 5px !important; letter-spacing: normal !important; }
.tlp-form-head p  { color: rgba(255,255,255,.55) !important; font-size: 13px !important; margin: 0 !important; letter-spacing: normal !important; }
.tlp-form-body    { padding: 26px 32px !important; background: #fff !important; }
.tlp-form-foot    { text-align: center !important; padding: 14px 32px 22px !important; border-top: 1px solid var(--sb) !important; font-size: 13px !important; color: var(--tx2) !important; background: #fff !important; letter-spacing: normal !important; }
.tlp-form-foot a  { color: var(--dk) !important; font-weight: 600 !important; text-decoration: none !important; }
.tlp-form-foot a:hover { color: var(--tp) !important; }

/* Desktop Espacement */
.tlp-field { margin-bottom: 16px !important; }
.tlp-field label { display: block !important; font-size: 13px !important; font-weight: 600 !important; color: var(--tx) !important; margin-bottom: 5px !important; letter-spacing: normal !important; }
.req { color: var(--rd) !important; }

/* Supprimer les spinners des champs number */
.tlp-no-spinner::-webkit-outer-spin-button,
.tlp-no-spinner::-webkit-inner-spin-button { -webkit-appearance: none !important; margin: 0 !important; }
.tlp-no-spinner { -moz-appearance: textfield !important; }

/* FORCER LE STYLE DES INPUTS CONTRE ELEMENTOR */
.tlp-field input[type="text"],
.tlp-field input[type="email"],
.tlp-field input[type="password"],
.tlp-field input[type="tel"],
.tlp-field input[type="number"],
.tlp-field select,
.tlp-field textarea {
    width: 100% !important; 
    padding: 11px 14px !important;
    border: 1.5px solid var(--br) !important; 
    border-radius: var(--rs) !important;
    font-size: 14px !important; 
    color: var(--tx) !important; 
    background: #fff !important;
    -webkit-transition: border-color .2s, -webkit-box-shadow .2s !important;
            transition: border-color .2s, box-shadow .2s !important;
    -webkit-box-sizing: border-box !important; 
            box-sizing: border-box !important;
    font-family: 'Outfit', sans-serif !important; /* Fix Police Elementor */
    letter-spacing: normal !important; /* Fix Lettres collées */
    box-shadow: none !important; /* Retire l'ombre d'Elementor */
}
.tlp-field input:focus,
.tlp-field select:focus {
    outline: none !important; 
    border-color: var(--tp) !important;
    -webkit-box-shadow: 0 0 0 3px rgba(139,156,226,.15) !important;
            box-shadow: 0 0 0 3px rgba(139,156,226,.15) !important;
}
.tlp-field small { display: block !important; font-size: 12px !important; color: var(--tx2) !important; margin-top: 4px !important; line-height: 1.5 !important; letter-spacing: normal !important; }
.tlp-chk label { display: -webkit-box !important; display: -ms-flexbox !important; display: flex !important; -webkit-box-align: flex-start !important; -ms-flex-align: flex-start !important; align-items: flex-start !important; gap: 8px !important; font-size: 13px !important; font-weight: 400 !important; cursor: pointer !important; line-height: 1.5 !important; color: var(--tx) !important; letter-spacing: normal !important; }
.tlp-cgu-link { color: var(--tp) !important; font-weight: 600 !important; text-decoration: underline !important; }
.tlp-pw { position: relative !important; }
.tlp-pw input { padding-right: 44px !important; }
.tlp-pw button {
    position: absolute !important;
    right: 10px !important;
    top: 50% !important;
    -webkit-transform: translateY(-50%) !important;
    transform: translateY(-50%) !important;
    background: none !important;
    border: none !important;
    cursor: pointer !important;
    color: #94a3b8 !important;
    padding: 4px !important;
    display: -webkit-inline-box !important;
    display: -ms-inline-flexbox !important;
    display: inline-flex !important;
    -webkit-box-align: center !important;
    -ms-flex-align: center !important;
    align-items: center !important;
    line-height: 0 !important;
    border-radius: 4px !important;
    -webkit-transition: color .15s !important;
    transition: color .15s !important;
}
.tlp-pw button:hover { color: #475569 !important; }
/* SVG eye icons inside the toggle button */
.tlp-pw .tlp-eye-show,
.tlp-pw .tlp-eye-hide { display: block; pointer-events: none; }

/* Grille pour les prénoms/noms sur Desktop */
.tlp-row2 { 
    display: flex !important; 
    gap: 12px !important; 
    flex-wrap: wrap !important; 
}
.tlp-row2 .tlp-field { 
    flex: 1 1 180px !important; 
}

/* ══════════════════════════
   BOUTONS (BOUCLIER ANTI-ELEMENTOR)
══════════════════════════ */
.tlp-btn {
    display: -webkit-inline-box !important; display: -ms-inline-flexbox !important; display: inline-flex !important;
    -webkit-box-align: center !important; -ms-flex-align: center !important; align-items: center !important;
    -webkit-box-pack: center !important; -ms-flex-pack: center !important; justify-content: center !important;
    gap: 7px !important; padding: 11px 22px !important; border-radius: var(--rs) !important;
    font-size: 14px !important; font-weight: 600 !important; cursor: pointer !important;
    border: 1.5px solid var(--br) !important; background: #fff !important; color: var(--tx) !important;
    text-decoration: none !important; -webkit-transition: all .18s !important; transition: all .18s !important;
    font-family: 'Outfit', sans-serif !important; /* Fix Police Elementor */
    letter-spacing: normal !important; /* Fix Lettres collées */
    white-space: nowrap !important; line-height: 1 !important;
    -webkit-box-sizing: border-box !important; box-sizing: border-box !important;
    box-shadow: none !important;
}
.tlp-btn:hover { background: var(--sb) !important; border-color: var(--tp) !important; }
.tlp-btn-primary { background: var(--tp) !important; border-color: var(--tp) !important; color: #fff !important; }
.tlp-btn-primary:hover { background: var(--tpd) !important; border-color: var(--tpd) !important; color: #fff !important; }
.tlp-btn-full { width: 100% !important; display: -webkit-box !important; display: -ms-flexbox !important; display: flex !important; }
.tlp-btn-wa { background: var(--wa) !important; border-color: var(--wa) !important; color: #fff !important; }
.tlp-btn-wa:hover { background: #1ebe5d !important; border-color: #1ebe5d !important; color: #fff !important; }
.tlp-btn-danger { border-color: var(--rd) !important; color: var(--rd) !important; }
.tlp-btn-danger:hover { background: var(--rd) !important; color: #fff !important; }
.tlp-btn-cert { background: var(--dk) !important; border-color: var(--dk) !important; color: var(--tp) !important; }
.tlp-btn-cert:hover { background: #1e2a4a !important; }

/* ══════════════════════════
   NOTICES
══════════════════════════ */
.tlp-notice { padding: 13px 18px; border-radius: var(--rs); font-size: 14px; line-height: 1.6; margin-bottom: 16px; border-left: 4px solid; }
.tlp-info    { background: var(--sb); border-color: var(--tp); color: var(--dk); }
.tlp-success { background: #f0fff4; border-color: var(--gr); color: #155724; }
.tlp-warning { background: #FFFBEB; border-color: var(--or); color: #92400E; }
.tlp-error   { background: #FEF2F2; border-color: var(--rd); color: #7F1D1D; }

/* ══════════════════════════
   BARRE DE PROGRESSION
══════════════════════════ */
.tlp-pb { background: #fff; border: 1px solid var(--br); border-radius: var(--rs); padding: 15px 18px; margin: 14px 0; }
.tlp-pb-header { display: -webkit-box; display: -ms-flexbox; display: flex; -webkit-box-align: center; -ms-flex-align: center; align-items: center; gap: 10px; margin-bottom: 9px; -ms-flex-wrap: wrap; flex-wrap: wrap; }
.tlp-pb-badge { font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; background: var(--dk); color: var(--tp); padding: 3px 9px; border-radius: 5px; }
.tlp-pb-count { -webkit-box-flex: 1; -ms-flex: 1; flex: 1; font-size: 13px; color: var(--tx); font-weight: 500; }
.tlp-pb-pct { font-size: 17px; font-weight: 700; }
.tlp-pb-track { height: 8px; background: var(--sb); border-radius: 100px; overflow: hidden; }
.tlp-pb-fill { height: 100%; border-radius: 100px; -webkit-transition: width .8s ease; transition: width .8s ease; }
.tlp-pb-complete { margin-top: 10px; font-size: 13px; font-weight: 600; color: var(--gr); background: #f0fff4; padding: 10px 14px; border-radius: var(--rs); }
.tlp-pb-complete a { color: var(--tp); }

/* ══════════════════════════
   LISTE DES LEÇONS
══════════════════════════ */
.tlp-lesson-list { list-style: none; margin: 0; padding: 0; }
.tlp-ll-item { display: -webkit-box; display: -ms-flexbox; display: flex; -webkit-box-align: center; -ms-flex-align: center; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--sb); font-size: 14px; }
.tlp-ll-item:last-child { border-bottom: none; }
.tlp-ll-dot { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--br); -ms-flex-negative: 0; flex-shrink: 0; display: -webkit-box; display: -ms-flexbox; display: flex; -webkit-box-align: center; -ms-flex-align: center; align-items: center; -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center; font-size: 11px; font-weight: 700; }
.tlp-ll-done .tlp-ll-dot { background: var(--gr); border-color: var(--gr); color: #fff; }
.tlp-ll-item a { color: var(--tx); text-decoration: none; font-weight: 500; }
.tlp-ll-done a { color: var(--gr); }
.tlp-ll-item a:hover { color: var(--tp); }

/* ══════════════════════════
   PAGE MON COMPTE
══════════════════════════ */
.tlp-account { max-width: 680px; margin: 0 auto; font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; }

/* Hero */
.tlp-acc-hero {
    display: -webkit-box; display: -ms-flexbox; display: flex;
    -webkit-box-align: center; -ms-flex-align: center; align-items: center;
    gap: 18px;
    background: -webkit-linear-gradient(135deg, #0F172A 0%, #1e2a4a 100%);
    background:         linear-gradient(135deg, #0F172A 0%, #1e2a4a 100%);
    border-radius: var(--r);
    padding: 26px 24px;
    margin-bottom: 16px;
    border: 1px solid rgba(139,156,226,.15);
    -webkit-box-shadow: 0 4px 24px rgba(15,23,42,.18);
            box-shadow: 0 4px 24px rgba(15,23,42,.18);
}
.tlp-acc-av {
    width: 64px; height: 64px; border-radius: 50%;
    background: -webkit-linear-gradient(135deg, var(--tp) 0%, var(--tpd) 100%);
    background:         linear-gradient(135deg, var(--tp) 0%, var(--tpd) 100%);
    color: #fff;
    display: -webkit-box; display: -ms-flexbox; display: flex;
    -webkit-box-align: center; -ms-flex-align: center; align-items: center;
    -webkit-box-pack: center; -ms-flex-pack: center; justify-content: center;
    font-size: 26px; font-weight: 700;
    -ms-flex-negative: 0; flex-shrink: 0;
    -webkit-box-shadow: 0 0 0 3px rgba(139,156,226,.3);
            box-shadow: 0 0 0 3px rgba(139,156,226,.3);
    letter-spacing: -.02em;
}
.tlp-acc-info { min-width: 0; flex: 1; }
.tlp-acc-info h2 { margin: 0 0 4px; color: #fff; font-size: 20px; font-weight: 700; letter-spacing: -.025em; line-height: 1.2; }
.tlp-acc-info p  { margin: 0 0 10px; font-size: 13px; color: rgba(255,255,255,.5); font-weight: 400; }
.tlp-acc-badge { background: var(--tp); color: #fff; font-size: 10px; font-weight: 700; padding: 3px 10px; border-radius: 100px; letter-spacing: .06em; text-transform: uppercase; }

/* Card */
.tlp-acc-card {
    background: #fff;
    border: 1px solid var(--br);
    border-radius: var(--r);
    padding: 20px 22px;
    margin-bottom: 14px;
    -webkit-box-shadow: 0 2px 10px rgba(139,156,226,.08);
            box-shadow: 0 2px 10px rgba(139,156,226,.08);
}
.tlp-acc-card h3 {
    margin: 0 0 16px;
    font-size: 14px;
    font-weight: 700;
    color: var(--tx2);
    text-transform: uppercase;
    letter-spacing: .06em;
    border-bottom: 1px solid var(--sb);
    padding-bottom: 12px;
}

/* Tabs */
.tlp-acc-tabs { display: -webkit-box; display: -ms-flexbox; display: flex; gap: 0; margin-bottom: 14px; border-bottom: 2px solid var(--sb); -ms-flex-wrap: wrap; flex-wrap: wrap; }
.tlp-acc-tab { padding: 11px 18px; font-size: 13px; font-weight: 500; color: var(--tx2); text-decoration: none; border-bottom: 2px solid transparent; margin-bottom: -2px; white-space: nowrap; -webkit-transition: all .15s; transition: all .15s; letter-spacing: -.005em; }
.tlp-acc-tab:hover { color: var(--tp); }
.tlp-acc-tab.tlp-tab-active { color: var(--dk); border-bottom-color: var(--tp); font-weight: 700; }

/* Stat grid */
.tlp-acc-stat-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; margin: 16px 0; }
.tlp-acc-stat { background: var(--sb); border-radius: var(--rs); padding: 14px 10px; text-align: center; border: 1px solid var(--br); }
.tlp-acc-stat.tlp-urgent { background: #FEF2F2; border-color: #FCA5A5; }
.tlp-acc-stat-val { font-size: 16px; font-weight: 700; color: var(--dk); line-height: 1.2; }
.tlp-acc-stat.tlp-urgent .tlp-acc-stat-val { color: var(--rd); }
.tlp-acc-stat-l { font-size: 10px; color: var(--tx2); margin-top: 4px; text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }

/* Account actions */
.tlp-acc-actions { display: -webkit-box; display: -ms-flexbox; display: flex; gap: 10px; margin-top: 16px; -ms-flex-wrap: wrap; flex-wrap: wrap; }

/* Table */
.tlp-acc-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.tlp-acc-table th { background: var(--sb); padding: 10px 12px; text-align: left; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--tx2); white-space: nowrap; }
.tlp-acc-table td { padding: 11px 12px; border-bottom: 1px solid var(--sb); color: var(--tx); vertical-align: middle; }
.tlp-acc-table tbody tr:last-child td { border-bottom: none; }
.tlp-acc-table tbody tr:hover td { background: var(--sf); }
.tlp-status-active    { color: #2ecc71; font-weight: 700; }
.tlp-status-expired   { color: var(--rd); font-weight: 600; }
.tlp-status-revoked   { color: var(--tx2); font-weight: 600; }
.tlp-status-pending   { color: var(--or); font-weight: 600; }
.tlp-status-superseded { color: var(--tx2); }

/* Vide */
.tlp-empty-state { text-align: center; color: var(--tx2); font-size: 14px; padding: 28px 16px; line-height: 1.6; }

/* Historique leçon — date à droite */
.tlp-hist-date { margin-left: auto; font-size: 11px; color: var(--tx2); white-space: nowrap; -ms-flex-negative: 0; flex-shrink: 0; }

/* Certificat */
.tlp-cert-card { background: -webkit-linear-gradient(135deg,var(--dk) 0%,#1e2a4a 100%); background: linear-gradient(135deg,var(--dk) 0%,#1e2a4a 100%); border-radius: var(--r); padding: 32px 24px; text-align: center; margin-bottom: 20px; border: 1px solid rgba(139,156,226,.2); }
.tlp-cert-icon { font-size: 52px; margin-bottom: 14px; display: block; }
.tlp-cert-name { font-size: 22px; font-weight: 700; color: #fff; margin-bottom: 6px; letter-spacing: -.025em; }
.tlp-cert-level { font-size: 14px; color: var(--tp); font-weight: 600; margin-bottom: 8px; }
.tlp-cert-date { font-size: 12px; color: rgba(255,255,255,.45); }

/* Favori bouton (utilisé sur les pages de cours via shortcode [tla_favorite]) */
.tlp-fav-btn { display: -webkit-inline-box; display: -ms-inline-flexbox; display: inline-flex; -webkit-box-align: center; -ms-flex-align: center; align-items: center; gap: 6px; padding: 9px 18px; background: #fff; border: 1.5px solid var(--br); border-radius: var(--rs); font-size: 13px; font-weight: 600; cursor: pointer; color: var(--tx2); -webkit-transition: all .18s; transition: all .18s; font-family: 'Outfit', sans-serif; }
.tlp-fav-btn:hover { border-color: var(--tp); color: var(--tp); background: var(--sb); }
.tlp-fav-active { border-color: #FFD54F !important; color: #F57F17 !important; background: #FFFBEB !important; }
.tlp-fav-icon { font-size: 15px; line-height: 1; }

/* ══════════════════════════
   RESPONSIVE MOBILE : LA CORRECTION EST ICI
══════════════════════════ */
@media (max-width: 600px) {
    /* Ajustement de la boîte principale */
    .tlp-form-body { padding: 20px 18px !important; }
    .tlp-form-head { padding: 22px 18px 18px !important; }
    .tlp-form-foot { padding: 14px 18px 18px !important; }
    .tlp-form-head h2 { font-size: 18px !important; }
    
    /* 🔴 FIX ESPACEMENT NOM/PRÉNOM SUR MOBILE */
    .tlp-field { 
        margin-bottom: 12px !important; /* Marge standard courte pour téléphone */
    }

    .tlp-row2 { 
        display: flex !important; 
        flex-direction: column !important; /* Empile les champs de la ligne (Nom/Prénom) */
        gap: 12px !important; /* Espace strict entre Nom et Prénom */
        margin-bottom: 12px !important; /* Espace après la ligne complète */
    }
    
    .tlp-row2 .tlp-field { 
        width: 100% !important; 
        margin-bottom: 0 !important; /* ANNULE la marge interne pour tuer le double espace */
        flex: none !important;
    }

    .tlp-acc-hero { -webkit-box-orient: vertical; -webkit-box-direction: normal; -ms-flex-direction: column; flex-direction: column; text-align: center; }
    .tlp-acc-tabs { overflow-x: auto; -ms-flex-wrap: nowrap; flex-wrap: nowrap; }
    .tlp-acc-tab { -ms-flex-negative: 0; flex-shrink: 0; padding: 10px 12px; font-size: 12px; }
    .tlp-acc-stat-grid { gap: 8px; }
    .tlp-acc-actions { -webkit-box-orient: vertical; -webkit-box-direction: normal; -ms-flex-direction: column; flex-direction: column; }
    .tlp-acc-actions .tlp-btn { width: 100% !important; }

    .tlp-layout-hero { padding: 32px 16px 28px; }
    .tlp-hero-title { font-size: 22px; }
    .tlp-main-system { padding: 20px 14px 40px; }

    #tlp-lesson-badge { bottom: 10px; right: 10px; left: 10px; max-width: none; }

    .tlp-course-header { top: var(--bar-h); }
    .tlp-course-header-inner { gap: 8px; }
    .tlp-course-title { font-size: 11px; }
    .tlp-layout-back { font-size: 11px; white-space: nowrap; }

    .tlp-pb-header { -webkit-box-orient: vertical; -webkit-box-direction: normal; -ms-flex-direction: column; flex-direction: column; -webkit-box-align: start; -ms-flex-align: start; align-items: flex-start; gap: 6px; }
    .tlp-cert-card { min-width: unset; width: 100%; -webkit-box-sizing: border-box; box-sizing: border-box; }
    .tlp-cert-name { font-size: 16px; }
    .tlp-acc-table { font-size: 12px; }
    .tlp-acc-table th, .tlp-acc-table td { padding: 7px 8px; }

    .tlp-current-lesson { padding: 12px; }
    .tlp-cl-title { font-size: 13px; }
    .tlp-btn { padding: 11px 16px !important; font-size: 13px !important; }
    .tlp-btn-full { width: 100% !important; }
}

/* ══════════════════════════
   INDICATEUR FORCE MOT DE PASSE
══════════════════════════ */
.tlp-strength-bar {
    height: 5px;
    background: var(--sb);
    border-radius: 100px;
    overflow: hidden;
    margin-top: 7px;
    margin-bottom: 4px;
}
.tlp-strength-fill {
    height: 100%;
    width: 0;
    border-radius: 100px;
    transition: width .3s ease, background .3s ease;
}

/* ══════════════════════════
   GUIDE NIVEAU — INSCRIPTION
══════════════════════════ */
.tlp-level-info {
    background: var(--sb);
    border: 1px solid var(--br);
    border-radius: var(--rs);
    padding: 11px 14px;
    font-size: 13px;
    line-height: 1.6;
    color: var(--tx);
    margin-top: 8px;
}
.tlp-level-info ul { margin: 6px 0 0; padding-left: 16px; }
.tlp-level-info li { margin: 4px 0; }

/* ══════════════════════════
   ONGLET PROFIL — MON ESPACE
══════════════════════════ */
#tlp-profile-form .tlp-field { margin-bottom: 14px; }
#tlp-profile-form hr { margin: 18px 0; border: none; border-top: 1px solid var(--sb); }
#tlp-strength-label-profile { display: none; font-size: 12px; margin-top: 3px; }

/* Séparateur dans le dropdown */
.tlp-drop-sep {
    height: 1px;
    background: var(--sb);
    margin: 4px 0;
}
.tlp-drop-logout {
    color: var(--rd) !important;
}
.tlp-drop-logout:hover {
    background: #FEF2F2 !important;
    color: var(--rd) !important;
}

/* ══════════════════════════
   BOUTON TERMINER LA LEÇON
   [tla_complete_button]
══════════════════════════ */
.tlp-complete-wrap {
    margin: 32px 0 16px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: center;
        -ms-flex-pack: center;
            justify-content: center;
}
.tlp-complete-btn {
    display: -webkit-inline-box;
    display: -ms-inline-flexbox;
    display: inline-flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    gap: 10px;
    padding: 14px 32px;
    background: var(--tp);
    border: none;
    border-radius: var(--rs);
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    -webkit-transition: background .18s, -webkit-transform .12s;
            transition: background .18s, transform .12s;
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    -webkit-box-shadow: 0 4px 18px rgba(139,156,226,.35);
            box-shadow: 0 4px 18px rgba(139,156,226,.35);
    letter-spacing: -.01em;
}
.tlp-complete-btn:hover { background: var(--tpd); -webkit-transform: translateY(-1px); transform: translateY(-1px); }
.tlp-complete-btn:active { -webkit-transform: translateY(0); transform: translateY(0); }
.tlp-complete-btn:disabled { opacity: .6; cursor: not-allowed; -webkit-transform: none; transform: none; }
.tlp-complete-btn-icon { font-size: 18px; line-height: 1; }

.tlp-complete-done {
    display: -webkit-inline-box;
    display: -ms-inline-flexbox;
    display: inline-flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: #f0fff4;
    border: 2px solid #2ecc71;
    border-radius: var(--rs);
    color: #2ecc71;
    font-size: 15px;
    font-weight: 700;
}

/* Pill statut leçon [tla_lesson_status] */
.tlp-status-pill { display: inline-flex; align-items: center; gap: 4px; padding: 3px 12px; border-radius: 100px; font-size: 12px; font-weight: 700; }
.tlp-status-done    { background: #f0fff4; color: #2ecc71; border: 1px solid #2ecc71; }
.tlp-status-ongoing { background: var(--sb); color: var(--tp); border: 1px solid var(--br); }

/* ─── Barre d'actions leçon [tla_lesson_actions] — v6.5.5 ─── */
.tlp-lesson-actions {
    display: flex !important;
    flex-wrap: wrap !important;           /* retour à la ligne si pas assez de place */
    align-items: stretch !important;      /* MÊME HAUTEUR pour tous les boutons */
    gap: 10px !important;
    margin: 24px 0 16px !important;
    list-style: none !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    width: 100% !important;
    max-width: 100% !important;
}

/* Boutons : largeur auto (s'adapte au contenu), hauteur fixe égale */
.tlp-action-btn,
.tlp-lesson-actions a,
.tlp-lesson-actions button,
.tlp-lesson-actions div {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    height: 44px !important;             /* hauteur identique pour tous */
    padding: 0 18px !important;
    border-radius: 10px !important;
    font-size: 13.5px !important;
    font-weight: 600 !important;
    font-family: 'Outfit', sans-serif !important;
    cursor: pointer !important;
    border: 1.5px solid #D1D9F5 !important;
    background: #fff !important;
    color: #64748B !important;
    transition: background .15s, border-color .15s, color .15s !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    box-sizing: border-box !important;
    line-height: 1 !important;
    margin: 0 !important;
    width: auto !important;              /* largeur naturelle : s'adapte au texte */
    flex-shrink: 0 !important;
}

/* Hover : état neutre */
.tlp-lesson-actions a:hover,
.tlp-lesson-actions button:hover { background: #f5f7ff !important; border-color: #8B9CE2 !important; color: #5563ab !important; }

/* Bouton ← Retour */
.tlp-action-back,
.tlp-lesson-actions .tlp-action-back {
    background: #f0f2fb !important;
    border-color: #D1D9F5 !important;
    color: #5563ab !important;
}
.tlp-action-back:hover { background: #e4e8f7 !important; border-color: #8B9CE2 !important; }

/* Bouton ☆ Favoris */
.tlp-lesson-actions .tlp-fav-btn { background: #fff !important; color: #64748B !important; }
.tlp-lesson-actions .tlp-fav-btn:hover { border-color: #8B9CE2 !important; color: #8B9CE2 !important; background: #EFF2FB !important; }
.tlp-lesson-actions .tlp-fav-active { border-color: #FFD54F !important; color: #F57F17 !important; background: #FFFBEB !important; }

/* Bouton ✅ J'ai terminé */
.tlp-action-complete,
.tlp-lesson-actions .tlp-action-complete {
    background: #8B9CE2 !important;
    border-color: #8B9CE2 !important;
    color: #fff !important;
    box-shadow: 0 3px 10px rgba(139,156,226,.3) !important;
}
.tlp-action-complete:hover { background: #6B7FD4 !important; border-color: #6B7FD4 !important; box-shadow: none !important; }
.tlp-action-complete:disabled { opacity: .65 !important; cursor: not-allowed !important; box-shadow: none !important; }

/* État "Terminé" (div statique) */
.tlp-action-done,
.tlp-lesson-actions .tlp-action-done {
    background: #f0fff4 !important;
    border-color: #a8d5b5 !important;
    color: #27ae60 !important;
    cursor: default !important;
    font-weight: 700 !important;
}

/* ── Mobile : UNE SEULE LIGNE HORIZONTALE, ZÉRO EMPILEMENT ── */
@media (max-width: 540px) {
    .tlp-lesson-actions {
        flex-direction: row !important;   /* force horizontal */
        flex-wrap: nowrap !important;     /* INTERDIT l'empilement vertical */
        overflow-x: auto !important;      /* scroll horizontal si nécessaire */
        -webkit-overflow-scrolling: touch !important;
        gap: 6px !important;
        padding-bottom: 2px !important;
    }
    .tlp-action-btn,
    .tlp-lesson-actions a,
    .tlp-lesson-actions button,
    .tlp-lesson-actions div {
        flex-shrink: 1 !important;        /* peut se réduire pour tenir sur la ligne */
        flex-grow: 0 !important;
        white-space: nowrap !important;
        font-size: 11px !important;
        padding: 0 10px !important;
        height: 38px !important;
        border-radius: 8px !important;
        min-width: 0 !important;
    }
}

/* Fix : badge badge de leçon ne chevauche pas le bouton flottant */
#tlp-lesson-badge {
    bottom: 80px; /* au-dessus du bouton flottant */
}
@media (max-width: 600px) {
    #tlp-lesson-badge { bottom: 72px; right: 10px; left: auto; max-width: 220px; }
}

/* ═══ Inscription : message de succès et validation ═══ */
.tlp-reg-success { text-align: center; padding: 12px 0; }
.tlp-reg-check   { font-size: 32px; margin-bottom: 12px; }
.tlp-reg-title   { font-weight: 700; color: #155724; margin: 0 0 8px; font-size: 17px; }
.tlp-reg-sub     { color: #374151; margin: 0 0 16px; font-size: 14px; }
.tlp-reg-wa-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #25D366 !important;
    color: #fff !important;
    text-decoration: none !important;
    padding: 14px 24px !important;
    border-radius: 10px !important;
    font-weight: 700 !important;
    font-size: 15px !important;
    box-shadow: 0 4px 12px rgba(37,211,102,.35) !important;
}
.tlp-reg-hint { font-size: 12px; color: #888; margin: 4px 0 0; }

.tlp-input-error { border-color: #e74c3c !important; background: #fef2f2 !important; }

/* ═══ Page Accès Refusé — v6.5 mobile-first ═══ */
.tlp-denied {
    max-width: 480px;
    width: calc(100% - 32px);
    margin: 40px auto;
    padding: 44px 36px 40px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 8px 40px rgba(15,23,42,.10), 0 1px 4px rgba(15,23,42,.06);
    text-align: center;
    border: 1px solid #e4eaf8;
    font-family: inherit;
    box-sizing: border-box;
}
.tlp-denied-icon {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: #EFF2FB;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: #8B9CE2;
}
.tlp-denied-icon svg { display: block; }
.tlp-denied-icon-vip {
    background: -webkit-linear-gradient(135deg, #FFD54F 0%, #F97316 100%);
    background:         linear-gradient(135deg, #FFD54F 0%, #F97316 100%);
    color: #fff;
}
/* Badge pill sous l'icône */
.tlp-denied-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 12px;
    border-radius: 99px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .05em;
    text-transform: uppercase;
    background: #EFF2FB;
    color: #8B9CE2;
    margin: 0 auto 14px;
}
.tlp-denied-badge-vip {
    background: #FFF3E0;
    color: #F97316;
}
.tlp-denied h2 {
    font-size: 21px;
    font-weight: 700;
    color: #0F172A;
    margin: 0 0 10px;
    letter-spacing: -.02em;
    line-height: 1.25;
}
.tlp-denied-h2-vip { color: #F97316 !important; }
.tlp-denied p {
    color: #64748b;
    font-size: 15px;
    line-height: 1.65;
    margin: 0 0 28px;
}
.tlp-denied-actions {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    gap: 10px;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
}
.tlp-btn-icon {
    display: -webkit-inline-box;
    display: -ms-inline-flexbox;
    display: inline-flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 7px;
}
/* Mobile ≤ 540px */
@media (max-width: 540px) {
    .tlp-denied {
        width: calc(100% - 24px);
        margin: 20px auto;
        padding: 32px 20px 28px;
        border-radius: 16px;
    }
    .tlp-denied-icon { width: 64px; height: 64px; }
    .tlp-denied h2 { font-size: 19px; }
    .tlp-denied p { font-size: 14px; }
    .tlp-denied-actions {
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-direction: column;
        flex-direction: column;
        -webkit-box-align: stretch;
        -ms-flex-align: stretch;
        align-items: stretch;
        gap: 10px;
    }
    .tlp-denied-actions .tlp-btn { width: 100%; justify-content: center; }
}

/* ═══ Guest wall (compte non connecté) ═══ */
.tlp-guest-wall {
    max-width: 500px;
    margin: 48px auto;
    padding: 40px 32px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0,0,0,.08);
    text-align: center;
    border: 1px solid var(--br, #e8eaf6);
}
.tlp-guest-icon { font-size: 48px; margin-bottom: 16px; line-height: 1; }
.tlp-guest-title { font-size: 22px; font-weight: 700; color: var(--dk, #1a1a2e); margin: 0 0 10px; }
.tlp-guest-sub { color: #6b7280; font-size: 14px; line-height: 1.6; margin: 0 0 24px; }
.tlp-guest-actions { display: flex; flex-direction: column; gap: 12px; margin-bottom: 32px; }
.tlp-btn-lg { padding: 14px 28px !important; font-size: 16px !important; }
.tlp-btn-outline {
    display: inline-block;
    padding: 12px 20px;
    border: 2px solid var(--tp, #8B9CE2);
    color: var(--tp, #8B9CE2);
    border-radius: var(--r, 8px);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: background .2s, color .2s;
}
.tlp-btn-outline:hover { background: var(--tp, #8B9CE2); color: #fff; text-decoration: none; }
.tlp-guest-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    background: var(--sb, #f0f4ff);
    border-radius: 10px;
    padding: 16px;
}
.tlp-guest-feat {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #374151;
}
.tlp-guest-feat span:first-child { font-size: 18px; }

/* ═══ Already-logged card (connexion / inscription) ═══ */
.tlp-already-logged {
    max-width: 480px;
    margin: 48px auto;
    padding: 28px 24px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 4px 20px rgba(0,0,0,.08);
    border: 1px solid var(--br, #e8eaf6);
    display: flex;
    align-items: center;
    gap: 18px;
}
.tlp-already-av {
    width: 56px;
    height: 56px;
    min-width: 56px;
    border-radius: 50%;
    background: var(--tp, #8B9CE2);
    color: #fff;
    font-size: 22px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.tlp-already-info { flex: 1; }
.tlp-already-greet { margin: 0 0 4px; font-size: 15px; color: var(--dk, #1a1a2e); }
.tlp-already-level { margin: 0; font-size: 13px; color: #6b7280; }
.tlp-badge-inline {
    display: inline-block;
    background: var(--tp, #8B9CE2);
    color: #fff;
    font-weight: 700;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
}
@media (max-width: 520px) {
    .tlp-already-logged { flex-direction: column; text-align: center; }
    .tlp-guest-features { grid-template-columns: 1fr; }
}

/* ═══ CGU redesign ═══ */
.tlp-cgu-wrap { max-width: 720px; margin: 0 auto; }
.tlp-cgu-hero {
    text-align: center;
    padding: 40px 24px 32px;
    background: linear-gradient(135deg, var(--sb, #f0f4ff) 0%, #fff 100%);
    border-radius: 16px;
    margin-bottom: 28px;
    border: 1px solid var(--br, #e8eaf6);
}
.tlp-cgu-hero-icon { font-size: 44px; margin-bottom: 12px; line-height: 1; }
.tlp-cgu-title { font-size: 26px; font-weight: 700; color: var(--dk, #1a1a2e); margin: 0 0 6px; }
.tlp-cgu-site { font-size: 14px; color: var(--tp, #8B9CE2); font-weight: 600; margin: 0 0 4px; }
.tlp-cgu-date { font-size: 12px; color: #9ca3af; margin: 0; }
.tlp-cgu-body { display: flex; flex-direction: column; gap: 2px; }
.tlp-cgu-section {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    padding: 22px 20px;
    background: #fff;
    border: 1px solid var(--br, #e8eaf6);
    border-radius: 12px;
    margin-bottom: 10px;
    transition: box-shadow .2s;
}
.tlp-cgu-section:hover { box-shadow: 0 2px 12px rgba(0,0,0,.06); }
.tlp-cgu-num {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    background: var(--tp, #8B9CE2);
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 2px;
}
.tlp-cgu-text h2 { font-size: 16px; font-weight: 700; color: var(--dk, #1a1a2e); margin: 0 0 8px; }
.tlp-cgu-text p  { font-size: 14px; color: #4b5563; line-height: 1.7; margin: 0; }
.tlp-cgu-footer { text-align: center; padding: 28px 0 10px; }

/* ═══ Account hero plan badges ═══ */
.tlp-acc-badge-vip {
    display: inline-block;
    background: linear-gradient(135deg, #FFD54F 0%, #F57F17 100%);
    color: #fff;
    font-weight: 700;
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 12px;
    margin-left: 6px;
    box-shadow: 0 2px 6px rgba(245,127,23,.3);
}
.tlp-acc-badge-std {
    display: inline-block;
    background: rgba(139, 156, 226, 0.22);
    color: #fff;
    font-weight: 700;
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 12px;
    margin-left: 6px;
    border: 1px solid rgba(139, 156, 226, 0.4);
}
/* ═══ Multi-niveaux : checkboxes inscription (v6.3.0) ═══ */
.tlp-level-checks {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 8px;
    margin-top: 4px;
}
.tlp-check-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border: 1.5px solid #e0dfd8;
    border-radius: 8px;
    cursor: pointer;
    transition: all .15s;
    background: #fff;
    user-select: none;
}
.tlp-check-label:hover {
    border-color: var(--tp, #8B9CE2);
    background: #f8faff;
}
.tlp-check-label:has(input:checked) {
    border-color: var(--tp, #8B9CE2);
    background: #eef2fc;
    box-shadow: 0 2px 6px rgba(139, 156, 226, .15);
}
.tlp-check-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    cursor: pointer;
    accent-color: var(--tp, #8B9CE2);
}
.tlp-check-badge {
    display: inline-block;
    background: var(--tp, #8B9CE2);
    color: #fff;
    font-weight: 700;
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 4px;
    letter-spacing: .04em;
}
.tlp-check-desc {
    font-size: 11px;
    color: #666;
    line-height: 1.2;
}

/* ═══ Mon Compte multi-niveaux (v6.3.1) ═══ */
.tlp-acc-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 6px;
}
.tlp-acc-level-block {
    border: 1px solid var(--sb, #e0dfd8);
    border-radius: 12px;
    padding: 16px 18px;
    margin-bottom: 14px;
    background: #fff;
    transition: border-color .2s, box-shadow .2s;
}
.tlp-acc-level-block:hover {
    border-color: var(--tp, #8B9CE2);
    box-shadow: 0 4px 14px rgba(139,156,226,.12);
}
.tlp-acc-level-block:last-child { margin-bottom: 0; }
.tlp-acc-level-head {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f0f0ec;
}
.tlp-acc-level-badge {
    display: inline-block;
    background: var(--tp, #8B9CE2);
    color: #fff;
    font-weight: 800;
    font-size: 14px;
    padding: 4px 12px;
    border-radius: 6px;
    letter-spacing: .05em;
    min-width: 44px;
    text-align: center;
}
.tlp-acc-level-name {
    flex: 1;
    font-size: 14px;
    font-weight: 600;
    color: #1a1a24;
}

/* ═══ Plan souhaité (radios) — inscription (v6.3.3) ═══ */
.tlp-plan-radios {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
    margin-top: 4px;
}
.tlp-plan-radio {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border: 1.5px solid #e0dfd8;
    border-radius: 10px;
    cursor: pointer;
    transition: all .15s;
    background: #fff;
    user-select: none;
    -webkit-user-select: none;
}
.tlp-plan-radio:hover {
    border-color: var(--tp, #8B9CE2);
    background: #f8faff;
}
.tlp-plan-radio:has(input:checked) {
    border-color: var(--tp, #8B9CE2);
    background: #eef2fc;
    box-shadow: 0 3px 10px rgba(139, 156, 226, .18);
}
.tlp-plan-radio input[type="radio"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--tp, #8B9CE2);
    flex-shrink: 0;
    margin-top: 2px;
}
.tlp-plan-radio-body {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
}
.tlp-plan-radio-title {
    font-weight: 700;
    font-size: 14px;
    color: #1a1a24;
}
.tlp-plan-radio-desc {
    font-size: 12px;
    color: #666;
    line-height: 1.4;
}

/* ═══════════════════════════════════════════════════
   SPLIT-SCREEN AUTH — CONNEXION / INSCRIPTION
   Design premium LMS : panneau gauche branding,
   panneau droit formulaire.
═══════════════════════════════════════════════════ */

/* ── Conteneur principal ── */
.tlp-auth-split {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: flex-start;
        -ms-flex-align: flex-start;
            align-items: flex-start;
    min-height: 100vh;
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ── PANNEAU GAUCHE : Branding ── */
.tlp-auth-left {
    -ms-flex: 0 0 42%;
        flex: 0 0 42%;
    max-width: 42%;
    background: -webkit-linear-gradient(160deg, #0F172A 0%, #1a2748 55%, #0e1b3a 100%);
    background:         linear-gradient(160deg, #0F172A 0%, #1a2748 55%, #0e1b3a 100%);
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
    -webkit-box-pack: center;
        -ms-flex-pack: center;
            justify-content: center;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow: hidden;
}

.tlp-auth-left-inner {
    padding: 52px 48px;
    max-height: 100vh;
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.tlp-auth-left-inner::-webkit-scrollbar { display: none; }

/* Logo gauche */
.tlp-auth-left-logo {
    margin-bottom: 48px;
}

/* Accroche gauche */
.tlp-auth-left-tagline {
    margin-bottom: 36px;
}
.tlp-auth-left-tagline h2 {
    color: #fff;
    font-size: 36px;
    font-weight: 800;
    line-height: 1.18;
    letter-spacing: -.03em;
    margin: 0 0 14px;
    font-family: 'Outfit', sans-serif;
}
.tlp-auth-left-tagline p {
    color: rgba(255,255,255,.58);
    font-size: 15px;
    line-height: 1.75;
    margin: 0;
    max-width: 320px;
}

/* Liste des avantages */
.tlp-auth-features {
    list-style: none;
    padding: 0;
    margin: 0 0 44px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
    gap: 15px;
}
.tlp-auth-features li {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    gap: 13px;
    color: rgba(255,255,255,.82);
    font-size: 14.5px;
    font-weight: 500;
    line-height: 1.4;
}
.tlp-auth-feat-icon {
    -ms-flex-negative: 0;
        flex-shrink: 0;
    width: 26px;
    height: 26px;
    background: rgba(139,156,226,.16);
    border: 1px solid rgba(139,156,226,.28);
    border-radius: 50%;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    -webkit-box-pack: center;
        -ms-flex-pack: center;
            justify-content: center;
    color: #8B9CE2;
}

/* Statistiques */
.tlp-auth-stats {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    padding: 18px 20px;
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(139,156,226,.1);
    border-radius: 14px;
}
.tlp-auth-stat {
    -webkit-box-flex: 1;
        -ms-flex: 1;
            flex: 1;
    text-align: center;
    padding: 2px 6px;
    min-width: 60px;
}
.tlp-auth-stat-num {
    display: block;
    color: #fff;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -.02em;
    line-height: 1.25;
}
.tlp-auth-stat-label {
    display: block;
    color: rgba(255,255,255,.42);
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .07em;
    margin-top: 3px;
}
.tlp-auth-stat-sep {
    width: 1px;
    height: 28px;
    background: rgba(255,255,255,.1);
    -ms-flex-negative: 0;
        flex-shrink: 0;
}

/* ── PANNEAU DROIT : Formulaire ── */
.tlp-auth-right {
    -webkit-box-flex: 1;
        -ms-flex: 1;
            flex: 1;
    background: #f8faff;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
    min-height: 100vh;
}
.tlp-auth-right-inner {
    -webkit-box-flex: 1;
        -ms-flex: 1;
            flex: 1;
    padding: 56px 60px 40px;
    max-width: 540px;
    margin: 0 auto;
    width: 100%;
    -webkit-box-sizing: border-box;
            box-sizing: border-box;
}

/* Titre contextuel dans le panneau droit */
.tlp-auth-right-title {
    margin-bottom: 28px;
}
.tlp-auth-right-title h1 {
    font-size: 26px;
    font-weight: 800;
    color: #0F172A;
    margin: 0 0 6px;
    letter-spacing: -.03em;
    line-height: 1.2;
    font-family: 'Outfit', sans-serif;
}
.tlp-auth-right-title p {
    font-size: 14px;
    color: #64748B;
    margin: 0;
    line-height: 1.55;
}

/* ── Override .tlp-form-box dans le panneau droit ── */
.tlp-auth-right .tlp-form-box {
    max-width: 100% !important;
    border: none !important;
    -webkit-box-shadow: none !important;
            box-shadow: none !important;
    border-radius: 0 !important;
    background: transparent !important;
    overflow: visible !important;
}
/* Masquer l'en-tête sombre du formulaire (le titre est dans tlp-auth-right-title) */
.tlp-auth-right .tlp-form-head {
    display: none !important;
}
.tlp-auth-right .tlp-form-body {
    padding: 0 !important;
    background: transparent !important;
}
.tlp-auth-right .tlp-form-foot {
    border-top: 1px solid #E8EAF2 !important;
    padding: 14px 0 0 !important;
    margin-top: 6px !important;
    background: transparent !important;
    text-align: left !important;
}
/* Carte "déjà connecté" dans le panneau droit */
.tlp-auth-right .tlp-already-logged {
    max-width: 460px;
    margin: 40px auto;
}

/* Pied de page du panneau droit */
.tlp-auth-right-footer {
    padding: 14px 60px;
    text-align: center;
    font-size: 12px;
    color: #94a3b8;
    border-top: 1px solid #E8EAF2;
    background: #f8faff;
}
.tlp-auth-right-footer a {
    color: #94a3b8;
    text-decoration: none;
    -webkit-transition: color .15s;
            transition: color .15s;
}
.tlp-auth-right-footer a:hover { color: #8B9CE2; }

/* En-tête mobile (caché sur desktop, visible < 768px) */
.tlp-auth-mobile-header {
    display: none;
    background: #0F172A;
    padding: 14px 20px;
    -webkit-box-align: center;
        -ms-flex-align: center;
            align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}
.tlp-auth-mobile-logo  { height: 32px; width: auto; display: block; }
.tlp-auth-mobile-brand { color: #8B9CE2; font-weight: 800; font-size: 18px; letter-spacing: -.02em; }

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
    .tlp-auth-left { -ms-flex: 0 0 40%; flex: 0 0 40%; max-width: 40%; }
    .tlp-auth-left-inner { padding: 44px 36px; }
    .tlp-auth-left-tagline h2 { font-size: 30px; }
    .tlp-auth-right-inner { padding: 44px 40px; }
}

@media (max-width: 768px) {
    /* Panneau gauche masqué sur mobile */
    .tlp-auth-left { display: none; }
    /* En-tête mobile visible */
    .tlp-auth-mobile-header { display: -webkit-box; display: -ms-flexbox; display: flex; }
    /* Panneau droit pleine largeur, fond blanc */
    .tlp-auth-split { display: block; min-height: auto; }
    .tlp-auth-right {
        min-height: calc(100vh - 60px);
        background: #fff;
    }
    .tlp-auth-right-inner {
        padding: 32px 24px;
        -webkit-box-pack: start;
            -ms-flex-pack: start;
                justify-content: flex-start;
        max-width: 100%;
    }
    .tlp-auth-right-title h1 { font-size: 22px; }
    .tlp-auth-right-footer { padding: 14px 24px; }
}

@media (max-width: 480px) {
    .tlp-auth-right-inner { padding: 24px 16px; }
    .tlp-auth-right-title h1 { font-size: 20px; }
    .tlp-auth-right-footer { padding: 12px 16px; }
}

/* ═══════════════════════════════════════════════════════
   BLOC NOTES — intégré dans [tla_lesson_actions] (v6.8)
   Design premium, responsive, auto-save silencieux.
════════════════════════════════════════════════════════ */

/* Wrapper global : barre d'actions + notes en colonne */
.tlp-lesson-actions-wrap {
    margin: 24px 0;
    width: 100%;
    box-sizing: border-box;
}

/* Bloc Notes */
.tlp-notes-block {
    width: 100%;
    box-sizing: border-box;
    background: #fff;
    border: 1.5px solid #E5EAF5;
    border-radius: 14px;
    overflow: hidden;
    margin-top: 16px;
    box-shadow: 0 4px 18px rgba(139,156,226,.10);
    transition: border-color .2s, box-shadow .2s;
}
.tlp-notes-block:focus-within {
    border-color: #8B9CE2;
    box-shadow: 0 0 0 3px rgba(139,156,226,.12);
}

/* En-tête du bloc notes */
.tlp-notes-hd {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 16px;
    background: #F8F9FF;
    border-bottom: 1.5px solid #E5EAF5;
    gap: 10px;
}
.tlp-notes-hd-title {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    font-weight: 700;
    color: #374151;
    font-family: 'Outfit', sans-serif;
}
.tlp-notes-hd-title svg {
    color: #8B9CE2;
    flex-shrink: 0;
}

/* Indicateur "Sauvegardé" (apparaît 2s puis disparaît) */
.tlp-notes-hd-saved {
    font-size: 12px;
    color: #2ecc71;
    font-weight: 600;
    display: none;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}

/* Zone de texte */
.tlp-notes-ta {
    display: block;
    width: 100%;
    min-height: 220px;
    max-height: 600px;
    padding: 18px 20px;
    border: none;
    outline: none;
    resize: vertical;
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 15px;
    color: #374151;
    line-height: 1.7;
    background: #fff;
    box-sizing: border-box;
    transition: background .15s;
}
.tlp-notes-ta::placeholder {
    color: #b0bac9;
    font-style: italic;
}
.tlp-notes-ta:focus { background: #FAFBFF; }

/* ── Mobile ── */
@media (max-width: 540px) {
    .tlp-notes-ta {
        min-height: 180px;
        font-size: 15px; /* plus lisible sur mobile */
    }
    .tlp-notes-hd { padding: 10px 14px; }
}

/* ═══════════════════════════════════════════════════════════
   HEADER + FOOTER PUBLICS LMS — v6.5.3 (design clair)
   Pages publiques uniquement (Connexion, Inscription, MDP oublié,
   Réinitialisation, CGU, Accès refusé, Espace membres).
   JAMAIS l'espace apprenant (Mon Compte, cours, leçons).
   Palette claire TutorLab : blanc, bleu très léger #EFF2FB,
   bordures #E5EAF5, texte #0F172A/#475569, accent pervenche #8B9CE2.
═══════════════════════════════════════════════════════════ */

/* ── Sticky footer : header en haut, contenu extensible, footer collé en bas
   sur TOUTES les pages publiques (page-tlp.php OU thème). Aucun espace sous le footer. ── */
body.tlp-pub-chrome {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
    background: #EFF2FB;
}
body.tlp-pub-chrome > .tlp-pub-header { flex: 0 0 auto; }
body.tlp-pub-chrome > .tlp-pub-footer { margin-top: auto; flex: 0 0 auto; }

/* ── Header clair ── */
.tlp-pub-header {
    background: #ffffff;
    height: 62px;
    display: flex;
    align-items: center;
    position: relative;
    z-index: 50;
    border-bottom: 1px solid #E5EAF5;
    box-shadow: 0 1px 6px rgba(15,23,42,.04);
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.tlp-pub-header-in {
    width: 100%;
    max-width: 100%;            /* pleine largeur : logo proche du bord gauche */
    margin: 0;
    padding: 0 24px;            /* marge gauche réduite */
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    box-sizing: border-box;
}
.tlp-pub-logo {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    line-height: 1;
}
.tlp-pub-logo img { height: 30px; width: auto; display: block; }
.tlp-pub-logo span { color: #0F172A; font-weight: 800; font-size: 19px; letter-spacing: .2px; }

/* ── Navigation : tous les liens au MÊME style (aucun bouton spécial) ── */
.tlp-pub-nav { display: flex; align-items: center; gap: 2px; }
.tlp-pub-nav a {
    color: #475569;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    font-family: 'Outfit', sans-serif;
    padding: 8px 14px;
    border-radius: 8px;
    transition: color .15s, background .15s;
}
.tlp-pub-nav a:hover { color: #6B7FD4; background: #EFF2FB; }

/* Hamburger (masqué sur desktop) — barres foncées sur fond clair */
.tlp-pub-burger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    padding: 9px;
    background: none;
    border: 0;
    cursor: pointer;
}
.tlp-pub-burger span {
    display: block;
    height: 2px;
    width: 100%;
    background: #0F172A;
    border-radius: 2px;
    transition: transform .2s, opacity .2s;
}
.tlp-pub-burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.tlp-pub-burger.is-open span:nth-child(2) { opacity: 0; }
.tlp-pub-burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Footer minimaliste clair ── */
.tlp-pub-footer {
    background: #ffffff;
    color: #64748B;
    font-family: 'Outfit', sans-serif;
    font-size: 13px;
    text-align: center;
    border-top: 1px solid #E5EAF5;
}
.tlp-pub-footer-in { max-width: 1280px; margin: 0 auto; padding: 18px 22px; box-sizing: border-box; }

/* ── Split-screen Connexion/Inscription : remplit la hauteur entre header et footer ── */
.tlp-pub-chrome .tlp-auth-split      { flex: 1 0 auto; align-items: stretch; min-height: 0; }
.tlp-pub-chrome .tlp-auth-left       { height: auto; position: static; }
.tlp-pub-chrome .tlp-auth-left-inner { max-height: none; }
.tlp-pub-chrome .tlp-auth-right      { min-height: 0; }

/* ── Largeur IDENTIQUE Connexion / Inscription (cohérence visuelle) ──
   Même conteneur, mêmes marges latérales, même alignement, sur ordinateur,
   tablette et mobile. Le sélecteur :has() cible la boîte de CHAQUE formulaire
   d'authentification où qu'elle se trouve (page du plugin OU page Elementor),
   garantissant des dimensions strictement égales entre les deux pages. */
.tlp-form-box:has(#tlp-login-form),
.tlp-form-box:has(#tlp-reg-form),
.tlp-form-box:has(#tlp-lost-form),
.tlp-form-box:has(#tlp-rp-form) {
    max-width: 460px !important;
    width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
}
/* Le panneau droit du split-screen est assez large pour que le formulaire
   atteigne réellement ces 460px (sinon la connexion paraît plus étroite). */
body.tlp-pub-chrome .tlp-auth-right-inner { max-width: 600px; }

/* ── Mobile / tablette : menu hamburger déroulant (fond blanc) ── */
@media (max-width: 820px) {
    .tlp-pub-burger { display: flex; }
    .tlp-pub-nav {
        display: none;
        position: absolute;
        top: 62px;
        left: 0;
        right: 0;
        z-index: 49;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: #ffffff;
        padding: 8px 12px 14px;
        border-top: 1px solid #E5EAF5;
        box-shadow: 0 14px 28px rgba(15,23,42,.10);
    }
    .tlp-pub-nav.tlp-pub-nav-open { display: flex; }
    .tlp-pub-nav a { padding: 12px 14px; }
}
