/* Espace apprenant : tableau de bord, calendrier, messages. S'appuie sur style.css (couleurs, boutons, champs). */
body.space { background: var(--paper); }
.sp-top { background: var(--forest-900); color: var(--on-dark); }
.sp-top__in { display: flex; align-items: center; gap: 16px; min-height: 72px; }
.sp-top__logo img { height: 44px; width: auto; }
.sp-top__title { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; padding-left: 16px; border-left: 1px solid rgba(243, 246, 238, .25); }
.sp-top__out { margin-left: auto; }
.sp-top .sp-link { color: var(--on-dark); }
.sp-link { background: none; border: 0; padding: 0; color: var(--bordeaux); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.sp-main { padding-block: clamp(24px, 5vw, 48px) 64px; }
.sp-foot { padding: 24px 0 40px; color: var(--ink-3); font-size: .88rem; }
.sp-foot a { color: var(--ink-2); }
.sp-label { color: var(--bordeaux); font-weight: 700; font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; }
.sp-h1 { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.2rem); font-weight: 750; margin: 6px 0 0; }
.sp-h1 .serif { color: var(--bordeaux); }
.sp-h2 { font-size: clamp(1.35rem, 1.1rem + .8vw, 1.75rem); font-weight: 750; }
.sp-h3 { font-size: 1.1rem; font-weight: 700; margin: 26px 0 12px; }
.sp-muted { color: var(--ink-3); font-size: .95rem; }
.sp-center { text-align: center; margin-top: 18px; }
.sp-big { font-size: clamp(2.2rem, 1.6rem + 2.4vw, 3.2rem); color: var(--forest-900); line-height: 1; }

/* Connexion */
.sp-login { max-width: 560px; }
.sp-login__card { display: flex; flex-direction: column; gap: 18px; }

/* Grille du tableau de bord */
.sp-grid { display: grid; gap: clamp(18px, 3vw, 28px); }

/* Prochaine séance */
.sp-next { display: flex; gap: clamp(18px, 3vw, 32px); padding: clamp(22px, 4vw, 36px); border-radius: var(--radius); background: var(--forest-900); color: var(--on-dark); }
.sp-next__date { flex: none; width: 92px; height: 104px; border-radius: 18px; background: var(--bordeaux); display: flex; flex-direction: column; align-items: center; justify-content: center; text-transform: capitalize; font-weight: 600; font-size: .85rem; }
.sp-next__date b { font-family: var(--font-display); font-size: 2.4rem; line-height: 1; font-weight: 800; }
.sp-next__body { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.sp-next__kicker { color: var(--amber); font-weight: 700; font-size: .85rem; letter-spacing: .04em; }
.sp-next__title { font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.2rem); font-weight: 750; }
.sp-next__meta { color: var(--on-dark-2); }
.sp-next__desc { color: var(--on-dark); opacity: .92; max-width: 70ch; }
.sp-next__cta { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.sp-countdown { font-family: var(--font-display); font-weight: 700; color: var(--amber); font-size: 1.05rem; }
.sp-countdown.is-live { color: #8EE3A6; }
.sp-pill { display: inline-flex; padding: 8px 14px; border-radius: var(--pill); background: rgba(243, 246, 238, .1); color: var(--on-dark-2); font-size: .9rem; }

/* Ressources */
.sp-res { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.sp-res a { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: var(--pill); background: var(--sage-100); color: var(--forest-900); font-size: .88rem; font-weight: 600; text-decoration: none; }
.sp-res a:hover { background: #D5E3CA; }
.sp-res--dark a { background: rgba(243, 246, 238, .12); color: var(--on-dark); }

/* Calendrier */
.sp-cal { padding: clamp(16px, 3vw, 28px); }
.sp-cal__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.sp-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: .88rem; color: var(--ink-2); }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: 0; }
.dot--open { background: var(--bordeaux); }
.dot--done { background: var(--moss); }
.dot--locked { background: #B8C0B9; }
#calendar { --fc-border-color: var(--line); --fc-today-bg-color: var(--amber-soft); --fc-button-bg-color: var(--white); --fc-button-border-color: var(--line); --fc-button-text-color: var(--ink); --fc-button-hover-bg-color: var(--sage-100); --fc-button-hover-border-color: var(--line); --fc-button-active-bg-color: var(--forest-900); --fc-button-active-border-color: var(--forest-900); --fc-event-border-color: transparent; --fc-list-event-hover-bg-color: var(--sage-100); font-size: .92rem; }
#calendar .fc-button { border-radius: 10px; font-weight: 600; text-transform: none; box-shadow: none !important; }
#calendar .fc-button-active { color: var(--white); }
#calendar .fc-toolbar-title { font-family: var(--font-display); font-size: 1.25rem; text-transform: capitalize; }
#calendar .fc-col-header-cell-cushion, #calendar .fc-daygrid-day-number { color: var(--ink-2); text-decoration: none; text-transform: capitalize; }
#calendar .fc-event { cursor: pointer; border-radius: 6px; padding: 1px 3px; }
#calendar .ev-open { background: var(--bordeaux); color: #fff; }
#calendar .ev-done { background: var(--moss); color: #fff; }
#calendar .ev-locked { background: #DDE2DC; color: var(--ink-3); }
#calendar .fc-daygrid-event-dot { border-color: currentColor; }
#calendar .fc-daygrid-dot-event.ev-open, #calendar .fc-daygrid-dot-event.ev-done, #calendar .fc-daygrid-dot-event.ev-locked { color: #fff; }
#calendar .fc-daygrid-dot-event.ev-locked { color: var(--ink-3); }
#calendar .fc-list-event.ev-open .fc-list-event-dot { border-color: var(--bordeaux); }
#calendar .fc-list-event.ev-done .fc-list-event-dot { border-color: var(--moss); }
#calendar .fc-list-event.ev-locked .fc-list-event-dot { border-color: #B8C0B9; }
#calendar .fc-list-event.ev-open, #calendar .fc-list-event.ev-done, #calendar .fc-list-event.ev-locked { background: transparent; color: var(--ink); }
#calendar .fc-list-day-cushion { background: var(--paper); text-transform: capitalize; }
.fc .fc-footer-toolbar { margin-top: 12px; }

/* Formation */
.sp-course__head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; align-items: flex-start; margin-bottom: 18px; }
.sp-badge { display: inline-flex; padding: 6px 12px; border-radius: var(--pill); font-size: .85rem; font-weight: 700; }
.sp-badge--ok { background: var(--sage-100); color: var(--forest-900); }
.sp-badge--wait { background: var(--amber-soft); color: #5B3A0B; }
.sp-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 16px; }
.sp-stats div { background: var(--paper); border-radius: 14px; padding: 14px; display: flex; flex-direction: column; }
.sp-stats b { font-family: var(--font-display); font-size: 1.8rem; line-height: 1.1; }
.sp-stats span { color: var(--ink-3); font-size: .88rem; }
.sp-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.sp-details summary { cursor: pointer; font-weight: 600; margin-top: 6px; }
.sp-details p { margin-top: 6px; }

.sp-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.sp-item { display: flex; gap: 14px; align-items: flex-start; padding: 14px; border: 1px solid var(--line); border-radius: 16px; background: var(--white); }
.sp-item.is-locked { background: var(--paper); opacity: .85; }
.sp-item__date { flex: none; width: 54px; border-radius: 12px; background: var(--bordeaux); color: #fff; text-align: center; padding: 6px 0; text-transform: capitalize; font-size: .78rem; font-weight: 600; }
.sp-item.is-locked .sp-item__date { background: #B8C0B9; }
.sp-item__date b { display: block; font-family: var(--font-display); font-size: 1.5rem; line-height: 1.05; }
.sp-item__body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.sp-item__title { font-weight: 700; }
.sp-item__desc { color: var(--ink-2); font-size: .95rem; margin-top: 4px; }
.sp-item__cta { flex: none; align-self: center; }

.sp-agenda { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.sp-agenda > div:first-child { max-width: 60ch; }
.sp-agenda .sp-actions { margin-top: 0; }

/* Messages */
.sp-msgs { display: flex; flex-direction: column; gap: 10px; }
.sp-msg { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); }
.sp-msg:hover { border-color: var(--forest-800); }
.sp-msg__subject { font-weight: 700; }
.sp-narrow { max-width: 780px; }
.sp-article { display: flex; flex-direction: column; gap: 14px; }
.sp-prose { line-height: 1.7; }
.sp-prose p, .sp-prose ul, .sp-prose ol { margin: 0 0 12px; }
.sp-sign { margin-top: 8px; }

/* Détail d'une séance */
.sp-dialog { width: min(560px, calc(100vw - 32px)); border: 0; border-radius: var(--radius); padding: 28px; box-shadow: 0 40px 80px -30px rgba(16, 40, 27, .5); }
.sp-dialog::backdrop { background: rgba(11, 29, 19, .55); }
.sp-dialog > * + * { margin-top: 8px; }
.sp-dialog__x { position: absolute; top: 12px; right: 14px; border: 0; background: none; font-size: 1.8rem; line-height: 1; cursor: pointer; color: var(--ink-3); }
.sp-dialog .btn { margin-top: 14px; }

@media (max-width: 720px) {
  .sp-top__title { display: none; }
  .sp-next { flex-direction: column; }
  .sp-next__date { width: 100%; height: auto; flex-direction: row; gap: 10px; padding: 10px 14px; justify-content: flex-start; }
  .sp-next__date b { font-size: 1.6rem; }
  .sp-stats b { font-size: 1.4rem; }
  .sp-item { flex-wrap: wrap; }
  .sp-item__cta { width: 100%; justify-content: center; }
}

/* Tests de niveau */
.lt-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; }
.lt-card { display: flex; flex-direction: column; gap: 10px; text-decoration: none; color: var(--ink); transition: transform .2s, border-color .2s; }
.lt-card:hover { transform: translateY(-2px); border-color: var(--forest-800); }
.lt-card .btn { align-self: flex-start; margin-top: 6px; }
.lt-progress { position: sticky; top: 0; z-index: 5; height: 6px; background: var(--sage-100); border-radius: 0 0 6px 6px; margin-bottom: 16px; overflow: hidden; }
.lt-progress span { display: block; height: 100%; width: 0; background: var(--bordeaux); transition: width .25s; }
.lt-form { gap: 20px; }
.lt-part { display: flex; flex-direction: column; gap: 6px; }
.lt-q { border: 0; margin: 0; padding: 16px 0; border-top: 1px solid var(--line); min-width: 0; }
.lt-q legend { font-weight: 650; padding: 0; margin-bottom: 10px; float: left; width: 100%; }
.lt-q legend + * { clear: both; }
.lt-q.is-err legend { color: var(--bordeaux); }
.lt-n { display: inline-grid; place-items: center; min-width: 28px; height: 28px; border-radius: 50%; background: var(--sage-100); color: var(--forest-900); font-size: .85rem; margin-right: 6px; }
.lt-opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.lt-opts--wrap { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.lt-opts label { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--paper); cursor: pointer; }
.lt-opts label:has(input:checked) { border-color: var(--forest-800); background: var(--sage-100); font-weight: 600; }
.lt-opts input { accent-color: var(--forest-800); }
.lt-scale { display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); gap: 8px; }
.lt-scale label { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 10px 4px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--paper); cursor: pointer; text-align: center; }
.lt-scale input { position: absolute; opacity: 0; pointer-events: none; }
.lt-scale b { font-family: var(--font-display); font-size: 1.2rem; }
.lt-scale small { font-size: .72rem; color: var(--ink-3); min-height: 1em; line-height: 1.2; }
.lt-scale label:has(input:checked) { border-color: var(--bordeaux); background: #F6E3E6; }
.lt-scale label:has(input:focus-visible) { outline: 3px solid var(--amber); outline-offset: 2px; }
.lt-level { color: var(--amber); }
.lt-bars { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; }
.lt-barrow { display: grid; grid-template-columns: minmax(120px, 200px) minmax(0, 1fr) 64px; gap: 12px; align-items: center; }
.lt-barrow b { text-align: right; font-size: .92rem; }
.lt-track { height: 10px; border-radius: 6px; background: var(--sage-100); overflow: hidden; }
.lt-track i { display: block; height: 100%; background: var(--bordeaux); border-radius: 6px; }
@media (max-width: 720px) {
  .lt-opts { grid-template-columns: minmax(0, 1fr); }
  .lt-barrow { grid-template-columns: minmax(0, 1fr) 60px; }
  .lt-barrow .lt-track { grid-column: 1 / -1; grid-row: 2; }
}

/* ---------- Espace connecté : barre latérale + contenu ---------- */
.ic { width: 18px; height: 18px; flex: none; vertical-align: -3px; }
.sp-shell { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: clamp(20px, 3vw, 36px); align-items: start; }
.sp-side { position: sticky; top: 20px; display: flex; flex-direction: column; gap: 14px; }
.sp-who { display: flex; align-items: center; gap: 12px; padding: 4px 6px 12px; border-bottom: 1px solid var(--line); }
.sp-who b { display: block; font-size: 1rem; }
.sp-who small { display: block; color: var(--ink-3); font-size: .78rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 170px; }
.sp-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--forest-900); color: var(--on-dark); display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; flex: none; }
.sp-nav { display: flex; flex-direction: column; gap: 2px; }
.sp-nav a, .sp-nav button { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; color: var(--ink-2); text-decoration: none; font-weight: 600; font-size: .95rem; background: none; border: 0; cursor: pointer; text-align: left; width: 100%; }
.sp-nav a:hover, .sp-nav button:hover { background: var(--sage-100); color: var(--ink); }
.sp-nav a.is-active { background: var(--forest-900); color: var(--on-dark); }

.sp-count { margin-left: auto; min-width: 22px; height: 22px; padding: 0 6px; border-radius: var(--pill); background: var(--bordeaux); color: #fff; font-style: normal; font-size: .75rem; display: grid; place-items: center; }
.sp-content { display: flex; flex-direction: column; gap: clamp(16px, 2.4vw, 22px); min-width: 0; }
.sp-pagehead { display: flex; flex-direction: column; gap: 4px; }
.sp-pagehead .sp-h1 { font-size: clamp(1.8rem, 1.3rem + 1.8vw, 2.5rem); }

.sp-next__more { display: inline-flex; align-items: center; gap: 6px; color: var(--on-dark-2); font-weight: 600; text-decoration: none; }
.sp-next__more:hover { color: var(--on-dark); }
.sp-next .btn .ic, .sp-item__cta .ic, .sp-actions .btn .ic { margin-right: 6px; }

.sp-alert { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; border-radius: 14px; background: var(--amber-soft); color: #5B3A0B; font-size: .95rem; }
.sp-alert > .ic { margin-top: 2px; }
.sp-alert p { flex: 1; }
.sp-alert .sp-link { flex: none; color: #5B3A0B; }
.sp-alert--soft { background: var(--sage-100); color: var(--forest-900); }
.sp-alert--soft .sp-link { color: var(--forest-900); }

.sp-cols { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.sp-panel { display: flex; flex-direction: column; gap: 14px; padding: clamp(18px, 3vw, 26px); }
.sp-panel__head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.sp-panel .sp-h2 { font-size: 1.2rem; }

.sp-item__meta { color: var(--ink-3); font-size: .85rem; text-transform: none; }
.sp-item__title { font-family: var(--font-body); font-size: 1.05rem; font-weight: 700; letter-spacing: 0; line-height: 1.35; }
.sp-item__note { display: flex; align-items: center; gap: 6px; color: var(--ink-3); font-size: .9rem; margin-top: 2px; }
.sp-item--locked { background: var(--paper); }
.sp-item--locked .sp-item__date { background: #B8C0B9; }
.sp-item--done .sp-item__date { background: var(--moss); }
.sp-tag { flex: none; align-self: center; padding: 5px 10px; border-radius: var(--pill); font-size: .8rem; font-weight: 700; }
.sp-tag--done { background: var(--sage-100); color: var(--forest-900); }
.sp-res a .ic { width: 15px; height: 15px; }

.sp-tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: var(--pill); background: var(--white); border: 1px solid var(--line); align-self: flex-start; }
.sp-tabs a { padding: 8px 16px; border-radius: var(--pill); text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: .92rem; }
.sp-tabs a.is-active { background: var(--forest-900); color: var(--on-dark); }
.sp-pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.sp-pager a, .sp-pager .is-off { padding: 9px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--white); color: var(--ink); font-weight: 600; text-decoration: none; }
.sp-pager .is-off { opacity: .45; }
.sp-pager__info { color: var(--ink-3); font-size: .9rem; }
.sp-empty { color: var(--ink-3); text-align: center; }

.sp-msg { flex-direction: row; align-items: center; gap: 14px; }
.sp-msg__icon { width: 38px; height: 38px; border-radius: 12px; background: var(--sage-100); color: var(--forest-900); display: grid; place-items: center; flex: none; }
.sp-msg__text { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.sp-msg__go { color: var(--ink-3); }
.sp-panel .sp-msg { flex-direction: column; align-items: flex-start; gap: 2px; }

.sp-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 0 0 14px; }
.sp-facts div { padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; }
.sp-facts dt { color: var(--ink-3); font-size: .82rem; }
.sp-facts dd { margin: 2px 0 0; font-weight: 600; }
.sp-cal { display: flex; flex-direction: column; gap: 12px; }
.sp-agenda__text { display: flex; gap: 14px; align-items: flex-start; max-width: 62ch; }
.sp-agenda__ic { width: 28px; height: 28px; color: var(--bordeaux); margin-top: 2px; }
.sp-agenda .sp-h3 { margin: 0 0 4px; }

@media (max-width: 960px) {
  .sp-cols { grid-template-columns: minmax(0, 1fr); }
}


/* Test de niveau en étapes */
.lt-steps { position: sticky; top: 0; z-index: 5; background: var(--paper); padding: 10px 0 12px; margin-bottom: 8px; }
.lt-steps #lt-step-label { display: block; font-weight: 700; font-size: .92rem; color: var(--ink-2); margin-bottom: 8px; }
.lt-steps .lt-progress { position: static; margin: 0; border-radius: 6px; }
.lt-step { display: flex; flex-direction: column; gap: 4px; }
.lt-step .sp-h2 { margin-bottom: 6px; }
.lt-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; }
.lt-nav [data-next], .lt-nav [type="submit"] { margin-left: auto; }
.lt-q-plain { border: 0; padding: 0; margin: 0; }
.lt-q-plain.is-err .flabel, .field.is-err > label { color: var(--bordeaux); }
.field.is-err .input { border-color: var(--bordeaux); }
.lt-form:not(.is-stepped) [data-prev], .lt-form:not(.is-stepped) [data-next] { display: none; }

/* ---------- Organisation par formation ---------- */
.sp-side__head { display: flex; align-items: center; gap: 8px; }
.sp-side__head .sp-who { flex: 1; min-width: 0; }
.sp-close, .sp-burger { display: none; width: 42px; height: 42px; border-radius: 12px; border: 0; background: none; color: inherit; cursor: pointer; place-items: center; }
.sp-close .ic, .sp-burger .ic { width: 22px; height: 22px; }
.sp-nav__label { margin: 6px 12px -6px; font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.sp-nav--foot { padding-top: 10px; border-top: 1px solid var(--line); }
.sp-nav form { margin: 0; }
.sp-dotc { width: 10px; height: 10px; border-radius: 50%; flex: none; display: inline-block; }
.sp-nav a .sp-dotc { margin: 0 4px; }
.sp-nav a span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.sp-pagehead--course { padding-left: 16px; border-left: 4px solid var(--fc, var(--bordeaux)); }
.sp-tabs--wide { flex-wrap: wrap; }
.sp-filter { display: flex; flex-wrap: wrap; gap: 8px; }
.sp-filter a { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: var(--pill); border: 1px solid var(--line); background: var(--white); color: var(--ink-2); text-decoration: none; font-size: .88rem; font-weight: 600; }
.sp-filter a.is-active { border-color: var(--forest-900); color: var(--forest-900); background: var(--sage-100); }

.sp-item { border-left: 7px solid var(--fc, var(--bordeaux)); border-top-left-radius: 0; border-bottom-left-radius: 0; }
.sp-item__date { background: var(--fc, var(--bordeaux)); }
.sp-item--done .sp-item__date { background: #8C978F; }
.sp-item--locked { border-left-color: #B8C0B9; }
.sp-item__title a, .sp-plain { color: inherit; text-decoration: none; }
.sp-item__title a:hover, .sp-plain:hover { text-decoration: underline; text-underline-offset: 3px; }
.sp-item__course { color: var(--fc, var(--bordeaux)); font-weight: 600; }
.sp-resblock { display: flex; flex-direction: column; gap: 6px; padding: clamp(16px, 3vw, 24px); }
.sp-resblock .sp-h3 { margin: 0; }
.sp-tag { display: inline-flex; align-items: center; gap: 6px; }
.sp-tag--open { background: var(--amber-soft); color: #5B3A0B; }
.sp-tag--lock { background: #EEF0EC; color: var(--ink-3); }

.sp-lesson { display: flex; flex-direction: column; gap: 18px; border-top: 7px solid var(--fc, var(--bordeaux)); border-top-left-radius: 0; border-top-right-radius: 0; }
.sp-lesson .sp-h1 { margin: 0; font-size: clamp(1.7rem, 1.2rem + 1.8vw, 2.4rem); }
.sp-lesson .sp-h3 { margin: 0 0 8px; }
.sp-lesson__facts { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 22px; color: var(--ink-2); }
.sp-lesson__facts li { display: inline-flex; align-items: center; gap: 8px; }
.sp-lesson__join { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 16px; border-radius: 16px; background: var(--paper); }
.sp-lesson__join .btn .ic { margin-right: 6px; }
.sp-countdown--light { color: var(--bordeaux); }
.sp-lesson__desc { line-height: 1.7; max-width: 70ch; }
.sp-reslist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.sp-reslist a { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; color: var(--ink); text-decoration: none; }
.sp-reslist a:hover { border-color: var(--forest-800); }
.sp-reslist b { display: block; }
.sp-reslist small { color: var(--ink-3); }
.sp-reslist a > span:nth-child(2) { flex: 1; min-width: 0; }
.sp-pager a { display: inline-flex; align-items: center; gap: 6px; }

.sp-legend__item { display: inline-flex; align-items: center; gap: 6px; cursor: default; }
.sp-legend__item input { accent-color: var(--forest-900); margin: 0; cursor: pointer; }
.sp-legend__item:has(input) { cursor: pointer; }
.sp-legend__item .dot { margin-right: 0; }
#calendar .fc-event.ev-done { opacity: .45; }
#calendar .fc-event.ev-locked { background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.55) 0 5px, transparent 5px 10px); opacity: .7; }
#calendar .fc-event { color: #fff; }
#calendar .fc-list-event { color: var(--ink); }

body.sp-locked { overflow: hidden; }
.sp-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(11, 29, 19, .5); }

@media (max-width: 820px) {
  .sp-shell { grid-template-columns: minmax(0, 1fr); }
  .sp-burger { display: grid; margin-left: auto; color: var(--on-dark); }
  .sp-close { display: grid; }
  .sp-side { position: fixed; top: 0; left: 0; bottom: 0; z-index: 50; width: min(300px, 86vw); padding: 18px 16px; background: var(--paper); overflow-y: auto;
    transform: translateX(-105%); transition: transform .25s ease; box-shadow: 20px 0 50px -20px rgba(11, 29, 19, .4); }
  .sp-side.is-open { transform: none; }
  .sp-who small { max-width: 160px; }
  .sp-facts { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) { .sp-side { transition: none; } }

/* Présentation de la formation (onglet Infos) */
.sp-about { display: flex; flex-direction: column; gap: 14px; }
.sp-about .btn .ic { margin-right: 6px; }
.sp-prose h2 { font-size: 1.25rem; margin: 6px 0 8px; }
.sp-prose h3 { font-size: 1.08rem; margin: 6px 0 6px; }
.sp-prose a { color: var(--bordeaux); }
