/* ===================================================================
   CONFK THEME v2 Ã¢â‚¬â€ Design System from scratch
   Remplace core.css + responsive.css pour le nouveau design ConfK
   =================================================================== */

/* ----- DESIGN TOKENS ----- */
:root {
  --bleu-petrole:       #124e5e;
  --bleu-petrole-rgb:   18, 78, 94;
  --bleu-petrole-moyen: #00596c;
  --bleu-petrole-clair: #0e7487;
  --abricot:            #de895a;
  --abricot-hover:      #c97a4a;
  --orange:             #fed383;
  --jaune-apes0:        #fff8bb;
  --lilas-premiere:     #ebd6ea;
  --bleu-vert-pass:     #cfe9e7;
  --rose-poudre-intern: #fde3d7;
  --success:            #3d9e7c;
  --danger:             #c44a4a;
  --bg:                 #f6f8f9;
  --card:               #ffffff;
  --text:               #1a2a3a;
  --text-muted:         #6b7e8c;
  --border:             #dce4e8;
  --shadow:             0 2px 12px rgba(var(--bleu-petrole-rgb), 0.06);
  --shadow-hover:       0 6px 24px rgba(var(--bleu-petrole-rgb), 0.10);
  --radius:             14px;
  --radius-sm:          8px;
  --font:               'Montserrat', sans-serif;
  --header-h:           64px;
  --nav-w:              240px;
  --nav-collapsed-w:    52px;
}

/* ----- RESET & BASE (ecrase core.css) ----- */
html, body {
  margin: 0; padding: 0;
  min-height: 100vh; height: auto; overflow: auto;
  background: var(--bg);
  font-family: var(--font);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: none;
}
body { display: block; }
body *, body *::before, body *::after { box-sizing: border-box; }
a { color: var(--bleu-petrole-clair); text-decoration: none; }
a:hover { color: var(--bleu-petrole); }
strong { font-weight: 700; }
h1, h2, h3, h4, h5, h6 { font-family: var(--font); }
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-thumb { background: rgba(var(--bleu-petrole-rgb), 0.2); border-radius: 4px; }

/* ----- APP LAYOUT ----- */
.app {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* ----- SIDEBAR ----- */
.sidebar {
  width: var(--nav-w);
  min-width: var(--nav-w);
  background: var(--bleu-petrole);
  color: #fff;
  display: flex;
  flex-direction: column;
  height: 100vh;
  flex-shrink: 0;
  overflow: hidden;
  transition: width 0.3s ease, min-width 0.3s ease;
  z-index: 200;
}
.sidebar.collapsed {
  width: var(--nav-collapsed-w);
  min-width: var(--nav-collapsed-w);
}
.sidebar.collapsed .sidebar-logo,
.sidebar.collapsed .sidebar-nav { display: none; }
.sidebar.collapsed .toggle-label { display: none; }

.sidebar-logo {
  padding: 16px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.10);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: background 0.2s ease;
}
.sidebar-logo:hover {
  background: rgba(255,255,255,0.16);
}
.sidebar-logo .logo-svg {
  height: 40px;
  width: auto;
  display: block;
}

.sidebar-nav {
  flex: 1;
  padding: 12px 0;
  overflow-y: auto;
}
.sidebar-nav::-webkit-scrollbar { width: 4px; }
.sidebar-nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 4px; }

.nav-section {
  padding: 14px 20px 4px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgb(224, 218, 133);
  font-weight: 700;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 20px;
  color: rgba(255,255,255,0.6);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  border-left: 3px solid transparent;
  transition: all 0.2s;
  cursor: pointer;
}
.nav-item:hover {
  color: #fff;
  background: rgba(255,255,255,0.06);
}
.nav-item.active {
  color: #fff;
  background: rgba(255,255,255,0.10);
  border-left-color: var(--abricot);
}

.nav-ico {
  width: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.nav-ico svg {
  width: 18px; height: 18px;
  fill: currentColor;
  opacity: 0.7;
}
.nav-item:hover .nav-ico svg,
.nav-item.active .nav-ico svg { opacity: 1; }

.nav-badge {
  margin-left: auto;
  background: var(--abricot);
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 8px;
  line-height: 1.4;
}
.nav-badge.green { background: var(--success); }
.nav-badge.orange { background: var(--orange); color: var(--bleu-petrole); }

/* ----- LIVE EN COURS ----- */
/* Badge "Live" visible + clignotant uniquement pendant qu'un live est
   diffusé (fenêtre : début de la conférence → +2h, cf. core.js / ConfKCards).
   Pulsation douce d'opacité, partagée menu / cartes / hero. */
@keyframes confk-live-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}
.nav-badge.live { animation: confk-live-blink 1.6s ease-in-out infinite; }

.nav-sep {
  height: 1px;
  background: rgba(255,255,255,0.08);
  margin: 6px 20px;
}

/* ----- SIDEBAR TOGGLE ----- */
.sidebar-toggle {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 8px;
}
.sidebar-toggle-btn {
  background: none;
  border: none;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  width: 100%;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 6px;
  font-family: var(--font);
  transition: color 0.2s, background 0.2s;
}
.sidebar-toggle-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.06);
}
.toggle-arrow {
  font-size: 16px;
  line-height: 1;
  font-weight: 700;
}
.toggle-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* ----- MAIN AREA ----- */
.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow-y: auto;
  background: linear-gradient(180deg, #f9fbfc 0%, #f4f8f9 50%, #eef3f5 100%);
}

/* ----- TOPBAR ----- */
.topbar {
  height: var(--header-h);
  min-height: var(--header-h);
  background: var(--card);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 14px;
  position: sticky;
  top: 0;
  z-index: 100;
}
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
}
.breadcrumb a { color: var(--bleu-petrole-clair); }
.breadcrumb a:hover { color: var(--bleu-petrole); }
.breadcrumb .sep { color: var(--border); }
.breadcrumb .current { color: var(--text); font-weight: 700; }
.topbar-spacer { flex: 1; }

/* ----- HAMBURGER (mobile) ----- */
.topbar-hamburger {
  display: none;
  width: 40px; height: 40px;
  margin-left: -8px;
  border: none;
  background: transparent;
  color: var(--bleu-petrole);
  cursor: pointer;
  border-radius: 8px;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s;
}
.topbar-hamburger:hover { background: var(--bg); }
.main-menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 180;
  background: rgba(18, 78, 94, 0.4);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
body.menu-open .main-menu-overlay { opacity: 1; visibility: visible; }

.topbar-btn {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: background 0.2s;
}
.topbar-btn:hover { background: var(--bg); }
.topbar-btn .dot {
  position: absolute;
  top: 5px; right: 5px;
  width: 7px; height: 7px;
  background: var(--danger);
  border-radius: 50%;
  border: 2px solid var(--card);
}

.topbar-avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--abricot);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 12px;
  cursor: pointer;
  text-decoration: none;
}
.topbar-avatar:hover { color: #fff; }

/* ----- PAGE CONTAINER ----- */
.page {
  padding: 20px 24px 32px;
  /* max-width: 1300px; */
  width: 100%;
}

/* ----- PAGE HEADER ----- */
.page-header {
  margin-bottom: 20px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.page-header h1 {
  font-weight: 800;
  font-size: 26px;
  color: var(--bleu-petrole);
  line-height: 1.2;
  margin: 0;
}
.page-header p {
  color: var(--text-muted);
  font-size: 13px;
  margin-top: 2px;
  font-weight: 500;
}
.page-header-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* ----- BUTTONS ----- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 700;
  font-family: var(--font);
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  white-space: nowrap;
  line-height: 1.4;
}

/* display explicite ci-dessus = l'attribut hidden ne suffit pas
   (la règle UA [hidden] est moins spécifique) : on le rétablit. */
.btn[hidden] { display: none; }
.btn-primary {
  background: var(--bleu-petrole);
  color: #fff;
}
.btn-primary:hover {
  background: var(--bleu-petrole-moyen);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(var(--bleu-petrole-rgb), 0.2);
  color: #fff;
}
.btn-outline {
  background: transparent;
  color: var(--bleu-petrole);
  border: 1.5px solid var(--bleu-petrole);
}
.btn-outline:hover {
  background: rgba(var(--bleu-petrole-rgb), 0.06);
}
.btn-accent {
  background: var(--abricot);
  color: #fff;
}
.btn-accent:hover {
  background: var(--abricot-hover);
  transform: translateY(-1px);
  color: #fff;
}
.btn-sm { padding: 6px 12px; font-size: 11px; }

/* ----- CHIPS ----- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 16px;
  font-size: 11px;
  font-weight: 600;
  background: var(--bg);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--text-muted);
}
.chip:hover { border-color: var(--bleu-petrole-clair); color: var(--bleu-petrole); }
.chip.active { background: rgba(var(--bleu-petrole-rgb), 0.08); border-color: var(--bleu-petrole-clair); color: var(--bleu-petrole); }
.chip.live { background: #fce8e0; color: var(--danger); border-color: #f0c0b0; }
.chip.presentiel { background: #e8f5e9; color: #2e7d32; border-color: #c8e6c9; }
/* État « Inscrit » (présentiel) : plein, plus affirmé que le type (chip.presentiel) */
.chip.signed { background: var(--success); color: #fff; border-color: var(--success); }
.chip.replay { background: rgba(var(--bleu-petrole-rgb), 0.08); color: var(--bleu-petrole); border-color: var(--bleu-petrole-clair); }
.chip.vod { background: #e8e8f5; color: #5a5a8a; border-color: #d0d0e8; }

/* ----- CARDS ----- */
.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 18px 22px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  transition: box-shadow 0.2s;
}
.card:hover { box-shadow: var(--shadow-hover); }

/* ----- CARD TITLE (commune ÃƒÂ  tous les cards) ----- */
.card-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--bleu-petrole);
  margin: 0 0 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.card-header h3 { margin: 0; }
.card-header a { font-size: 11px; color: var(--bleu-petrole-clair); font-weight: 600; }
.card-header a:hover { color: var(--bleu-petrole); }

/* ----- GRIDS ----- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(240px, 1fr)); gap: 14px; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }

/* ----- STATS ----- */
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 16px; }
.stat-box {
  text-align: center;
  padding: 14px 10px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.stat-val { font-size: 24px; font-weight: 800; color: var(--bleu-petrole); line-height: 1.2; }
.stat-val.accent { color: var(--abricot); }
.stat-val.green { color: var(--success); }
.stat-lbl {
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 2px;
}

/* ----- SPLIT LAYOUT (dashboard) ----- */
.split { display: flex; gap: 20px; }
.split-side {width: 280px;flex-shrink: 0;display: flex;flex-direction: column;gap: 14px;}
.split-main { flex: 1; min-width: 0; }

/* ----- CALENDAR ----- */
.calendar .cal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.calendar .cal-header span {
  font-size: 13px;
  font-weight: 700;
  color: var(--bleu-petrole);
}
.cal-nav { display: flex; gap: 4px; }
.cal-nav a {
  width: 26px; height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
  color: var(--text-muted);
  text-decoration: none;
}
.cal-nav a:hover { background: var(--bg); }

.cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 4px;
}
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}
.cal-grid a {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
}
.cal-grid a:hover { background: var(--bg); }
.cal-grid a.today { background: var(--bleu-petrole); color: #fff; font-weight: 700; }
.cal-grid a.event { background: rgba(var(--bleu-petrole-rgb), 0.08); color: var(--bleu-petrole); font-weight: 700; }
.cal-grid a.other { color: var(--border); }

/* ----- UPCOMING LIST (sidebar) ----- */
.upcoming { padding: 14px 16px; }
.upcoming-item {
  font-size: 12px;
  margin-bottom: 6px;
}
.upcoming-item strong { color: var(--abricot); }
.upcoming-empty {
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
  padding: 10px;
}

/* ----- PODIUM ----- */
.podium-grid {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  justify-content: center;
}
.podium-item { text-align: center; flex: 1; }
.podium-rank { font-size: 12px; font-weight: 800; line-height: 1; margin-bottom: 2px; }
.podium-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  margin: 0 auto 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  font-weight: 800;
  color: #fff;
}
.podium-name { font-size: 9px; font-weight: 700; color: var(--text); line-height: 1.1; }
.podium-score { font-size: 8px; color: var(--text-muted); font-weight: 600; }
.podium-bar { width: 100%; border-radius: 3px 3px 0 0; margin: 0 auto; min-height: 4px; }

.podium-item.gold .podium-rank { color: #d4a017; }
.podium-item.gold .podium-bar { background: #d4a017; height: 44px; }
.podium-item.gold .podium-avatar { background: #d4a017; }
.podium-item.silver .podium-rank { color: #8f9bb3; }
.podium-item.silver .podium-bar { background: #8f9bb3; height: 32px; }
.podium-item.silver .podium-avatar { background: #8f9bb3; }
.podium-item.bronze .podium-rank { color: #cd7f32; }
.podium-item.bronze .podium-bar { background: #cd7f32; height: 22px; }
.podium-item.bronze .podium-avatar { background: #cd7f32; }

/* ----- TOP 100 ----- */
.top100 {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 12px;
}
.top100-title {
  font-size: 12px; font-weight: 700;
  color: var(--bleu-petrole);
  margin-bottom: 10px;
  display: flex; align-items: center; gap: 6px;
}
.top100-row {
  display: flex; align-items: center; gap: 8px;
  padding: 4px 0;
  border-bottom: 1px solid var(--border);
  font-size: 11px;
}
.top100-row:last-child { border-bottom: none; }
.top100-rank { width: 18px; font-weight: 800; color: var(--text-muted); text-align: right; font-size: 10px; flex-shrink: 0; }
.top100-avatar {
  width: 20px; height: 20px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 8px; font-weight: 700; color: #fff; flex-shrink: 0;
}
.top100-name { flex: 1; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top100-score { font-weight: 700; color: var(--bleu-petrole); font-size: 10px; }
.top100-row.me {
  background: rgba(var(--bleu-petrole-rgb), 0.08);
  border-radius: 4px;
  padding: 4px 8px;
  margin: 0 -8px;
}
.top100-row.me .top100-rank { color: var(--bleu-petrole); }

/* ----- PROGRESS BAR ----- */
.progress { height: 5px; background: var(--border); border-radius: 3px; overflow: hidden; }
.progress-fill { height: 100%; border-radius: 3px; background: var(--bleu-petrole); transition: width 0.5s; }
.progress-fill.green { background: var(--success); }

.progress-card {
  padding: 14px 18px;
}
.progress-card-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.progress-card-main { flex: 1; min-width: 120px; }
.progress-card-label {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  margin-bottom: 4px;
}
.progress-card-label span:first-child { font-weight: 600; }
.progress-card-label span:last-child { font-weight: 700; color: var(--success); }

/* ----- SECTION TITLE ----- */
.section-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--bleu-petrole);
  margin: 18px 0 10px;
}

/* ----- CONFERENCE CARD ----- */
.conf-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
}
.conf-card:hover {
  border-color: var(--bleu-petrole-clair);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}
.conf-thumb {
  width: 100%;
  height: 140px;
  background: #2a3a4a;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.conf-thumb.tall { height: 150px; }
.conf-thumb-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(18,78,94,0.7) 0%, rgba(222,137,90,0.3) 100%);
}
.conf-thumb-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.5s ease;
}
.conf-thumb-bg img.loaded {
  opacity: 1;
}
.conf-thumb-art {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 0;
  font-size: 50px;
  opacity: 0.3;
}
.conf-play {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 2;
  transition: transform 0.2s, background 0.2s;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
  text-decoration: none;
}
.conf-card:hover .conf-play { transform: scale(1.1); background: #fff; }
.conf-play svg { width: 20px; height: 20px; fill: var(--bleu-petrole); margin-left: 2px; }
.conf-duration {
  position: absolute;
  bottom: 8px; right: 8px;
  z-index: 2;
  background: rgba(0,0,0,0.75);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
}
.conf-badge {
  position: absolute;
  top: 8px; left: 8px;
  z-index: 2;
  font-size: 9px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.conf-badge.live { background: var(--danger); color: #fff; }
.conf-badge.live.is-now { animation: confk-live-blink 1.6s ease-in-out infinite; }
.conf-badge.presentiel { background: #4caf50; color: #fff; }
.conf-badge.replay { background: var(--bleu-petrole); color: #fff; }

/* Badge date empile en haut a droite du thumb : Jeu. / 25 / Dec. / 09h00
   (confs a venir uniquement ; les replays n'ont pas ce badge) */
.conf-datebadge {
  position: absolute;
  top: 8px; right: 8px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 46px;
  padding: 5px 9px 6px;
  background: rgba(255,255,255,0.96);
  border-radius: var(--radius-sm);
  box-shadow: 0 2px 10px rgba(0,0,0,0.20);
  line-height: 1;
  text-align: center;
}
.conf-datebadge .db-dow { font-size: 11px; font-weight: 800; color: var(--text-muted); }
.conf-datebadge .db-day { font-size: 22px; font-weight: 800; color: var(--bleu-petrole); line-height: 1.05; margin-top: 1px; }
.conf-datebadge .db-mon { font-size: 12px; font-weight: 800; color: var(--text-muted); }
.conf-datebadge .db-hr {
  font-size: 12px; font-weight: 700; color: var(--abricot);
  margin-top: 4px; padding-top: 4px;
  border-top: 1px solid rgba(0,0,0,0.08);
  width: 100%;
}

.conf-body { padding: 12px 14px 10px; flex: 1; }
.conf-matiere {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--bleu-petrole-clair);
  margin-bottom: 2px;
}
.conf-body h4 { font-size: 14px; font-weight: 700; color: var(--text); margin: 0 0 2px; }
.conf-meta { font-size: 11px; color: var(--text-muted); }
.conf-meta span { display: inline-flex; align-items: center; gap: 3px; margin-right: 10px; }

.conf-footer {
  padding: 8px 14px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: auto;
}

/* ----- TOPIC CARD (digital content) ----- */
.topic-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  color: inherit;
}
.topic-card:hover {
  border-color: var(--bleu-petrole-clair);
  box-shadow: 0 4px 12px rgba(var(--bleu-petrole-rgb), 0.08);
  transform: translateY(-2px);
  color: inherit;
}
.tc-icon {
  width: 38px; height: 38px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.tc-icon svg { width: 20px; height: 20px; }
.tc-icon.blue   { background: rgba(var(--bleu-petrole-rgb), 0.08); }
.tc-icon.blue svg   { fill: var(--bleu-petrole); }
.tc-icon.green  { background: var(--bleu-vert-pass); }
.tc-icon.green svg  { fill: #2a7a6a; }
.tc-icon.pink   { background: var(--rose-poudre-intern); }
.tc-icon.pink svg   { fill: #b05a7a; }
.tc-icon.purple { background: var(--lilas-premiere); }
.tc-icon.purple svg { fill: #7a5a8a; }
.tc-icon.orange { background: #fef0e0; }
.tc-icon.orange svg { fill: #b07040; }
.tc-info h4 { font-size: 13px; font-weight: 700; color: var(--text); line-height: 1.2; margin: 0; }
.tc-info span { font-size: 11px; color: var(--text-muted); }

/* ----- SUBJECT CARD (digital : Learning / Trainings / Coaching / Fiches ...)
   Carte reutilisable listant un contenu d'apprentissage (souvent par specialite) :
   icone + nom + stats (items/questions...) + barre de progression (taux de reussite).
   Couleur d'accent = variable --color-matiere posee par [data-color-matiere] (matiere.css).
   Icone via .ico-matiere (fonds SVG de matiere.css), taille maitrisee ici par specificite. ----- */
.subject-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.subject-card:hover {
  border-color: var(--bleu-petrole-clair);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
  color: inherit;
}
/* Cartes cliquables en <button> (hub Training + vue « Par matiere » des
   listings ConfK). Les usages en <a> (Learning, forum) ne sont pas touches. */
button.subject-card { width: 100%; font-family: var(--font); text-align: left; cursor: pointer; }
.subject-card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
/* L'icone .ico-matiere vaut 128px par defaut dans matiere.css : on la cadre a 40px.
   Specificite (.subject-card .subject-ico) superieure -> l'emporte sur l'ordre de charge. */
.subject-card .subject-ico {
  position: relative;
  width: 40px; height: 40px;
  flex: none;
  display: block;
  margin: 0;
  border-radius: 10px;
  background: rgba(var(--bleu-petrole-rgb), 0.05);
}
.subject-card .subject-ico::before {
  content: "";
  position: absolute;
  inset: 5px;
  width: auto;            /* ecrase le width/height:128px de matiere.css */
  height: auto;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}
.subject-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.25;
  margin: 0;
  min-width: 0;
}
.subject-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
}
.subject-stat { font-size: 12px; color: var(--text-muted); font-weight: 500; }
.subject-stat b { color: var(--bleu-petrole); font-weight: 700; }
.subject-progress { display: flex; flex-direction: column; gap: 6px; }
.subject-progress-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}
.subject-score { font-size: 14px; font-weight: 800; color: var(--color-matiere, var(--bleu-petrole)); }
.subject-progress-lbl {
  font-size: 10px; font-weight: 600; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.05em;
}
/* Barre teintee a la couleur de la specialite (fallback bleu petrole) */
.subject-card .progress-fill { background: var(--color-matiere, var(--bleu-petrole)); }
.subject-card:focus-visible { outline: 2px solid var(--bleu-petrole-clair); outline-offset: 2px; }

/* ----- FILTER BAR ----- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  align-items: center;
}
.filter-bar select {
  padding: 7px 13px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: var(--font);
  font-weight: 500;
  background: var(--card);
  color: var(--text);
  cursor: pointer;
}
.filter-bar select:focus { outline: none; border-color: var(--bleu-petrole-clair); }
.filter-search {
  position: relative;
}
.filter-search-icon {
  position: absolute;
  left: 9px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 12px;
  pointer-events: none;
}
.filter-search input {
  padding: 8px 12px 8px 32px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: var(--font);
  font-weight: 500;
  background: var(--card);
  color: var(--text);
  width: 200px;
}
.filter-search input:focus { outline: none; border-color: var(--bleu-petrole-clair); }
/* Bouton chip dans la filter-bar (ex. reset) : herite la police */
.filter-bar button.chip { font-family: var(--font); }

/* ----- DECORATIVE VECTORS (fond) ----- */
.deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.deco-vec {
  position: absolute;
  display: block;
  max-width: 40%;
}
.deco-vec svg {
  width: 100%;
  height: auto;
  display: block;
}
.main > *:not(.deco):not(.topbar) { position: relative; z-index: 1; }

/* ===================================================================
   POPOVER Ã¢â‚¬â€ calque contextuel rÃƒÂ©utilisable
   Cf. controls/popover.control.js Ã¢â€ â€™ Popover.open({anchor, content|items, ...})
   Styles volontairement gÃƒÂ©nÃƒÂ©riques pour servir : menu d'actions (Ã¢â€¹Â®),
   liste de confÃƒÂ©rences (clic calendrier), et tout popover futur.
   =================================================================== */
:root {
  --z-popover: 1000;
  --z-popover-backdrop: 900;
  --popover-radius: 14px;
}

.popover-backdrop {
  position: fixed;
  inset: 0;
  z-index: var(--z-popover-backdrop);
  opacity: 0;
  background: rgba(var(--bleu-petrole-rgb), 0);
  -webkit-backdrop-filter: blur(0);
  backdrop-filter: blur(0);
  transition: opacity .18s ease, background .18s ease, backdrop-filter .18s ease;
}
.popover-backdrop.is-open {
  opacity: 1;
  background: rgba(var(--bleu-petrole-rgb), 0.06);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
}

.popover {
  position: fixed;
  top: 0; left: 0;
  z-index: var(--z-popover);
  width: max-content;
  max-width: min(92vw, 380px);
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: var(--popover-radius);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  backdrop-filter: blur(18px) saturate(160%);
  box-shadow: 0 12px 40px rgba(var(--bleu-petrole-rgb), 0.18),
              0 2px 8px rgba(var(--bleu-petrole-rgb), 0.08);
  opacity: 0;
  transform: translate3d(0, var(--pop-ty, -8px), 0) scale(var(--pop-scale, 0.94));
  transform-origin: var(--pop-origin, top center);
  transition: transform .24s cubic-bezier(.2, .9, .25, 1.25), opacity .16s ease-out;
  will-change: transform, opacity;
}
.popover.is-open {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}
.popover-body {
  padding: 6px;
  max-height: min(70vh, 520px);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.popover-body::-webkit-scrollbar { width: 6px; }
.popover-body::-webkit-scrollbar-thumb { background: rgba(var(--bleu-petrole-rgb), 0.18); border-radius: 4px; }

/* --- Items de menu (Mode B : items) --- */
.popover-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 12px;
  border: none;
  background: transparent;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  border-radius: 9px;
  cursor: pointer;
  text-align: left;
  text-decoration: none;
  transition: background .15s, color .15s;
}
.popover-item:hover { background: rgba(var(--bleu-petrole-rgb), 0.07); color: var(--bleu-petrole); }
.popover-item:disabled { opacity: .45; cursor: default; }
.popover-item.danger { color: var(--danger); }
.popover-item.danger:hover { background: rgba(196, 74, 74, 0.10); color: var(--danger); }
.popover-item-ico {
  width: 22px; height: 22px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  font-size: 16px;
  opacity: .85;
}
.popover-item-ico svg { width: 18px; height: 18px; fill: currentColor; }
.popover-item-main { flex: 1; min-width: 0; }
.popover-item-sub { font-size: 11px; color: var(--text-muted); font-weight: 500; }
.popover-separator { height: 1px; background: var(--border); margin: 5px 8px; }
.popover-header {
  padding: 9px 12px 5px;
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--text-muted);
}

/* --- Liste de confÃƒÂ©rences (Mode A : content, clic calendrier) --- */
.popconf { min-width: 270px; }
.popconf-head {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px 9px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 4px;
}
.popconf-date { font-size: 13px; font-weight: 700; color: var(--bleu-petrole); }
.popconf-count {
  margin-left: auto;
  font-size: 10px; font-weight: 700;
  background: rgba(var(--bleu-petrole-rgb), 0.08);
  color: var(--bleu-petrole);
  padding: 2px 8px; border-radius: 10px;
}
.popconf-row {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--text);
  cursor: pointer;
  transition: background .15s;
}
.popconf-row:hover { background: rgba(var(--bleu-petrole-rgb), 0.07); }
.popconf-type {
  flex-shrink: 0;
  width: 5px; height: 30px; border-radius: 3px;
  background: var(--bleu-petrole-clair);
}
.popconf-type.live { background: var(--danger); }
.popconf-type.presentiel { background: var(--success); }
.popconf-type.replay { background: var(--bleu-petrole); }
.popconf-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.popconf-title {
  font-size: 13px; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.popconf-sub {
  font-size: 11px; color: var(--text-muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.popconf-time { flex-shrink: 0; font-size: 12px; font-weight: 700; color: var(--abricot); }
/* État « Inscrit » sur la ligne d'un présentiel (noeud retiré du DOM sinon) */
.popconf-signed {
  flex-shrink: 0;
  font-size: 9.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
  color: var(--success);
  background: #e8f5e9;
  padding: 2px 7px; border-radius: 4px;
}
.popconf-empty { padding: 16px 12px; text-align: center; font-size: 12px; color: var(--text-muted); }

/* --- Bouton Ã¢â€¹Â® sur les cartes conf (rÃƒÂ©utilise le Popover) --- */
.conf-menu-btn {
  flex-shrink: 0;
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  border: none;
  border-radius: 50%;
  background: var(--abricot);
  color: #fff;
  font-size: 16px; line-height: 1;
  cursor: pointer;
  transition: background .2s;
}
.conf-card:hover .conf-menu-btn { opacity: 1; transform: scale(1); }
.conf-menu-btn:hover { background: rgba(0, 0, 0, 0.7); transform: scale(1.08); }
.conf-menu-btn:focus-visible { opacity: 1; transform: scale(1); outline: 2px solid var(--bleu-petrole-clair); outline-offset: 2px; }

/* Actions "secondaires" du menu (⋮) : Partager / Ajouter à ma liste, atténuées
   pour laisser ressortir la section primaire (entraînement + documents). */
.conf-menu .popover-item.is-secondary { color: var(--text-muted); font-weight: 400; }
.conf-menu .popover-item.is-secondary:hover { color: var(--bleu-petrole); }

/* Invite « Inscris-toi pour y accéder » (présentiel non inscrit) : item
   désactivé mais lisible, sans retour de survol (ce n'est pas une action) */
.conf-menu .popover-item.is-hint:disabled { opacity: 1; cursor: default; }
.conf-menu .popover-item.is-hint:hover { background: transparent; color: var(--text); }
.conf-menu .popover-item.is-hint .popover-item-sub { color: var(--abricot-hover); font-weight: 600; }

/* --- Utilitaire de filtrage (recherche/filtres dashboard) --- */
.is-hidden { display: none !important; }

/* ----- RESPONSIVE ----- */
@media (max-width: 1600px) {
  .grid-4 { grid-template-columns: repeat(3,1fr); }
}
@media (max-width: 1300px) {
  .grid-4 { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 900px) {
  /* .app { height: auto; overflow: auto; } */
  .topbar-hamburger { display: flex; }
  .breadcrumb { display: none; }
  .sidebar {
    position: fixed;
    top: 0; left: 0; bottom: 0;
    height: 100%;
    z-index: 190;
    transform: translateX(-100%);
    transition: transform 0.3s ease, width 0.3s ease, min-width 0.3s ease;
    box-shadow: none;
  }
  body.menu-open .sidebar { transform: none; box-shadow: var(--shadow-hover); }
  body.menu-open { overflow: hidden; }
  .sidebar-toggle { display: none; }
  .grid-3 { grid-template-columns: 1fr; }
  .split { flex-direction: column; }
  .split-side { width: 100%; }
  .page { padding: 12px; }
}
@media (max-width: 700px) {
  .stat-row { grid-template-columns: repeat(2, 1fr); }
}
/* Pas de hover sur tactile : le bouton Ã¢â€¹Â® reste visible */
@media (hover: none) {
  .conf-menu-btn { opacity: 1; transform: scale(1); }
}

/* ===================================================================
   CONF-VIEW Ã¢â‚¬â€ calque de lecture faÃƒÂ§on Netflix
   Cf. controls/conf-view.control.js Ã¢â€ â€™ ConfView.open(idConfDate)
   Overlay plein ÃƒÂ©cran : ÃƒÂ  gauche vignette floutÃƒÂ©e + titre/infos/actions,
   ÃƒÂ  droite la zone lecteur + bouton "Lancer la lecture". Ãƒâ‚¬ la lecture,
   la colonne gauche se masque en transition (.is-playing), rÃƒÂ©affichÃƒÂ©e pause.
   =================================================================== */
:root { --z-confview: 9000000; }

.conf-view {
  position: fixed;
  inset: 0;
  z-index: var(--z-confview);
  display: flex;
  flex-direction: column;
  background: #000; /* base noire opaque (cache le dashboard) */
  opacity: 0;
  visibility: hidden;
  transition: opacity .28s ease;
}
.conf-view.is-open { opacity: 1; visibility: visible; }

/* ArriÃƒÂ¨re-plan : vignette floutÃƒÂ©e ÃƒÂ  0.3 sur fond noir (clic = fermer) */
.conf-view-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: blur(26px) saturate(115%);
  opacity: 0.3;
  transform: scale(1.12);
  transition: opacity .3s;
}

/* Flex gauche / droite ; la colonne gauche GLISSE hors-champ ÃƒÂ  gauche ÃƒÂ  la lecture
   (margin-left animable sur une largeur fixe = pas d'ÃƒÂ©crasement du contenu,
   contrairement ÃƒÂ  width ou ÃƒÂ  grid-template-columns qui snappent). overflow:hidden
   = la colonne sortante est clippÃƒÂ©e proprement au bord gauche. */
.conf-view-inner {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  max-width: 1500px;
  width: 100%;
  margin: 0 auto;
  min-height: 0;
  /* overflow: hidden; */
  transition: max-width .48s cubic-bezier(.2, .9, .25, 1);
}

/* ---- Colonne gauche : infos (centrÃƒÂ©es verticalement) ---- */
.conf-view-info {
  display: flex;
  flex-direction: column;
  justify-content: safe center;
  flex: 0 0 400px;        /* largeur FIXE => le contenu n'est jamais ÃƒÂ©crasÃƒÂ© */
  min-width: 0;
  overflow: hidden;
  max-height: 100%;
  overflow: auto;
  padding: 40px 34px;
  color: #fff;
  /* background: linear-gradient(90deg, rgba(8, 14, 20, 0.72) 0%, rgba(8, 14, 20, 0.32) 65%, rgba(8, 14, 20, 0) 100%); */
  transition: margin-left .48s cubic-bezier(.2, .9, .25, 1),
              opacity .3s ease;
}
.conf-view.is-playing .conf-view-info {
  margin-left: -400px;    /* glisse intÃƒÂ©gralement ÃƒÂ  gauche + libÃƒÂ¨re la place pour la vidÃƒÂ©o */
  opacity: 0;
  pointer-events: none;
}
/* Ãƒâ‚¬ la lecture on casse le container max-width => la vidÃƒÂ©o occupe toute la fenÃƒÂªtre */
.conf-view.is-playing .conf-view-inner { max-width: 100vw; }

.conf-view-logo { width: 128px; height: auto; margin-bottom: 24px; opacity: 0.95; }

.conf-view-head {
  display: flex; align-items: flex-start; gap: 12px;
  margin-bottom: 14px;
}
.conf-view-title-wrap { flex: 1; min-width: 0; }
.conf-view-back {
  flex: none;
  width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(0, 0, 0, 0.45);
  color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .18s, transform .12s;
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.conf-view-back:hover { background: rgba(0, 0, 0, 0.7); }
.conf-view-back:active { transform: scale(0.92); }
.conf-view-back svg { width: 20px; height: 20px; fill: currentColor; }
.conf-view-badge {
  display: inline-block;
  font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em;
  padding: 3px 8px; border-radius: 4px; margin-bottom: 8px;
}
.conf-view-badge.live { background: var(--danger); color: #fff; }
.conf-view-badge.presentiel { background: var(--success); color: #fff; }
.conf-view-badge.replay { background: var(--bleu-petrole-clair); color: #fff; }
.conf-view-title-wrap h2 { color: #fff; font-size: 26px; margin: 0; line-height: 1.18; }
.conf-view-info>.conf-view-date {
    font-weight: bold;
    font-size: 1.4em;
    color: var(--abricot);
    padding-left: 50px;
    margin-bottom: 10px;
}
.conf-view-meta {
  display: flex; flex-wrap: wrap; gap: 6px 14px;
  font-size: 12px; color: rgba(255, 255, 255, 0.72);
  margin-bottom: 16px;
}
.conf-view-meta b { color: #fff; font-weight: 600; }
.conf-view-desc {
  font-size: 13px; line-height: 1.5;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 16px;
  max-height: 120px; overflow-y: auto;
  white-space: pre-line;
  flex-shrink: 0;
}

.conf-view-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.cv-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 15px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font: 600 13px/1 var(--font);
  cursor: pointer;
  text-decoration: none;
  transition: background .18s, border-color .18s, transform .12s;
}
.cv-btn:hover { background: rgba(255, 255, 255, 0.22); }
.cv-btn:active { transform: scale(0.97); }
.cv-btn.primary { background: var(--bleu-petrole-clair); border-color: var(--bleu-petrole-clair); }
.cv-btn.primary:hover { background: var(--bleu-petrole); }
.cv-btn.accent { background: var(--abricot); border-color: var(--abricot); }
.cv-btn.accent:hover { background: var(--abricot-hover); }
.cv-btn svg { width: 16px; height: 16px; fill: currentColor; flex: none; }
.cv-btn[disabled] { opacity: 0.4; cursor: default; }

.conf-view-docs { margin-top: 20px; border-top: 1px solid rgba(255, 255, 255, 0.12); padding-top: 12px; }
.conf-view-docs-title { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: rgba(255, 255, 255, 0.6); margin-bottom: 8px; }
.conf-view-docs-list { display: flex; flex-direction: column; gap: 2px; max-height: 160px; overflow-y: auto; }
.conf-view-doc {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px; border-radius: var(--radius-sm);
  color: rgba(255, 255, 255, 0.85); font-size: 13px;
  text-decoration: none;
  transition: background .15s, color .15s;
}
.conf-view-doc:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.conf-view-doc svg { width: 16px; height: 16px; fill: currentColor; opacity: 0.8; flex: none; }

/* Note d'accès (présentiel non inscrit) : entraînement & documents verrouillés */
.conf-view-access-note {
  display: flex; align-items: flex-start; gap: 8px;
  padding: 10px 12px;
  margin-bottom: 14px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.07);
  font-size: 12px; color: rgba(255, 255, 255, 0.75);
}
.conf-view-access-note svg { width: 15px; height: 15px; fill: var(--orange); flex: none; margin-top: 2px; }

/* ---- Mode présentiel : fiche rendez-vous (stage sans lecteur) ---- */
/* Le stage perd son ratio 16/9 forcé : la fiche épouse son contenu,
   centrée dans la colonne lecteur, surface sombre translucide. */
.conf-view-stage.is-rdv {
  aspect-ratio: auto;
  width: min(100%, 520px);
  max-height: calc(100vh - 110px);
  overflow-y: auto;
  background: rgba(10, 20, 28, 0.55);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.conf-view-rdv { display: flex; flex-direction: column; gap: 14px; padding: 26px 24px 22px; }
.cv-rdv-when { display: flex; align-items: center; gap: 10px; color: #fff; font-size: 15px; font-weight: 700; }
.cv-rdv-when svg { width: 18px; height: 18px; fill: var(--abricot); flex: none; }

.cv-rdv-lieu {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-sm);
}
.cv-rdv-lieu.is-mine { border-color: rgba(254, 211, 131, 0.5); }
.cv-rdv-lieu>svg { width: 18px; height: 18px; fill: rgba(255, 255, 255, 0.75); flex: none; margin-top: 2px; }
.cv-rdv-lieu-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cv-rdv-lieu-nom { font-size: 13.5px; font-weight: 700; color: #fff; }
.cv-rdv-lieu-adresse { font-size: 12.5px; color: rgba(255, 255, 255, 0.72); }
.cv-rdv-lieu-horaires { font-size: 12px; font-weight: 600; color: var(--orange); }
.cv-rdv-lieu-tag {
  margin-left: auto; flex: none;
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
  color: #26333d;
  background: var(--orange);
  padding: 3px 8px; border-radius: 4px;
}

.cv-rdv-status { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 20px; }
.cv-rdv-state { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; color: #93dcae; }
.cv-rdv-state svg { width: 15px; height: 15px; fill: currentColor; }
.cv-rdv-places { margin-left: auto; font-size: 12px; font-weight: 600; color: rgba(255, 255, 255, 0.72); }
.cv-rdv-places.is-full { color: #e89b9b; }

.cv-rdv-cta {
  width: 100%;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: transparent;
  color: #fff;
  font: 700 14px/1 var(--font);
  cursor: pointer;
  transition: background .18s, border-color .18s, transform .12s;
}
.cv-rdv-cta:hover { background: rgba(255, 255, 255, 0.12); }
.cv-rdv-cta:active { transform: scale(0.98); }
.cv-rdv-cta.accent { background: var(--abricot); border-color: var(--abricot); }
.cv-rdv-cta.accent:hover { background: var(--abricot-hover); }
.cv-rdv-cta[disabled] { opacity: .45; cursor: default; }
.cv-rdv-note { font-size: 12px; color: rgba(255, 255, 255, 0.65); text-align: center; }

/* ---- Colonne droite : lecteur ---- */
.conf-view-player {
  flex: 1 1 auto;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 40px 28px 24px;
  min-width: 0;
  transition: padding .48s cubic-bezier(.2, .9, .25, 1);
}
/* En lecture : padding rÃƒÂ©duit => la vidÃƒÂ©o occupe (presque) toute la fenÃƒÂªtre */
.conf-view.is-playing .conf-view-player { padding: 12px; }
.conf-view-stage {
  position: relative;
  /* Formule CONSTANTE (jamais de snap min()/max()) : la largeur Ã©pouse la boÃ®te
     du lecteur, qui grandit fluidement (flex + transition du padding) => vidÃ©o
     agrandie fluidement, jamais brutalement. */
  width: min(100%, calc((100vh - 24px) * 16 / 9));
  max-height: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  background: #000;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  transition: box-shadow .3s, border-radius .3s;
}
.conf-view-stage iframe,
.conf-view-stage video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }

.conf-view-poster {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  display: flex; align-items: center; justify-content: center;
}
.conf-view-poster-scrim { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.35); }
.conf-view-launch {
  position: relative; z-index: 2;
  width: 78px; height: 78px; border-radius: 50%;
  border: none; cursor: pointer;
  background: rgba(255, 255, 255, 0.92);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);
  transition: transform .2s, background .2s;
}
.conf-view-launch:hover { transform: scale(1.08); background: #fff; }
.conf-view-launch svg { width: 30px; height: 30px; fill: var(--bleu-petrole); margin-left: 3px; }
.conf-view-stage-label {
  position: absolute; bottom: 22px; left: 0; right: 0; z-index: 2;
  text-align: center; color: #fff; font-size: 14px; font-weight: 600;
}
.conf-view-stage-hint {
  position: absolute; bottom: 48px; left: 0; right: 0; z-index: 2;
  text-align: center; color: rgba(255, 255, 255, 0.82);
  font-size: 12px; font-weight: 500;
}

.conf-view-loading {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255, 255, 255, 0.75); font-size: 14px;
}
.conf-view-loading .spinner {
  width: 26px; height: 26px; margin-right: 12px;
  border: 3px solid rgba(255, 255, 255, 0.2);
  border-top-color: #fff;
  border-radius: 50%;
  animation: conf-view-spin .8s linear infinite;
}
@keyframes conf-view-spin { to { transform: rotate(360deg); } }

.conf-view-empty {
  color: rgba(255, 255, 255, 0.8); font-size: 14px; text-align: center; padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}
.conf-view.is-playing>.conf-view-bg {
    opacity: 0;
}

.conf-view.is-playing .conf-view-stage {border-radius: 0;box-shadow: 0 0px 0px rgba(0, 0, 0, 0);}

/* ---- watchTime : barre de progression sur les cartes ---- */
.conf-watch {
  display: none; /* affichÃƒÂ©e via .show quand maxWatchTime > 0 */
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.25);
  z-index: 3;
}
.conf-watch.show { display: block; }
.conf-watch-fill { display:block;height: 100%; width: var(--watch-pct, 0%); background: var(--abricot); transition: width .3s ease; }

/* ---- Toast (Partager copiÃƒÂ©, "BientÃƒÂ´t") ---- */
.conf-toast {
  position: fixed; left: 50%; bottom: 32px;
  transform: translateX(-50%) translateY(20px);
  background: rgba(18, 78, 94, 0.96); color: #fff;
  padding: 12px 20px; border-radius: var(--radius-sm);
  font: 600 13px/1 var(--font);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
  z-index: calc(var(--z-confview) + 1);
  opacity: 0; pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}
.conf-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---- Chapitres (replays Vimeo) : bouton flottant + panneau glissant ---- */
/* Superposés au stage (z-index > iframe) : le bouton reste visible sur le
   poster comme pendant la lecture ; le panneau glisse depuis la droite et
   floute la vidéo derrière. Synchronisés au lecteur (updateChapMirror). */
.conf-view-chap-btn {
  position: absolute; top: 12px; right: 12px; z-index: 6;
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 12px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(0, 0, 0, 0.45);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  color: #fff; font: 600 12px/1 var(--font); cursor: pointer;
  overflow: hidden; /* la ligne de temps suit la forme de la pilule */
  transition: background .18s, transform .12s, opacity .2s ease;
}
.conf-view-chap-btn:hover { background: rgba(0, 0, 0, 0.7); }
.conf-view-chap-btn:active { transform: scale(0.95); }
.conf-view-chap-btn svg { width: 16px; height: 16px; fill: currentColor; flex: none; }
.cv-chap-label { white-space: nowrap; }
/* Titre du chapitre courant (remplace le libellé) — largeur fixe pour éviter que
   la pilule ne se redimensionne à chaque changement de chapitre */
.cv-chap-now { min-width: 0; }
.cv-chap-now[hidden] { display: none; }
.cv-chap-now-title {
  display: block; width: 150px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  text-align: left;
}
/* Ligne de temps du chapitre courant, en talon du bouton — même custom property
   --chap-pct que les rangées de la liste (posée sur le bouton par le sondage) */
.cv-chap-bar {
  position: absolute; left: 0; bottom: 0; height: 2px;
  width: var(--chap-pct, 0%); background: var(--abricot);
  transition: width .25s linear;
}
/* Panneau ouvert : le bouton flottant s'efface (le panneau a sa croix) */
.conf-view.is-chap-open .conf-view-chap-btn { opacity: 0; pointer-events: none; }

.conf-view-chap {
  position: absolute; top: 0; right: 0; bottom: 0; z-index: 5;
  width: min(340px, 85%);
  display: flex; flex-direction: column;
  background: rgba(10, 20, 28, 0.72);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: -12px 0 32px rgba(0, 0, 0, 0.35);
  transform: translateX(calc(100% + 16px));
  visibility: hidden;
  transition: transform .35s cubic-bezier(.2, .9, .25, 1), visibility .35s;
}
.conf-view-chap.is-open { transform: translateX(0); visibility: visible; }

.conf-view-chap-head { display: flex; align-items: center; gap: 8px; padding: 14px 14px 10px; }
.conf-view-chap-title {
  font-size: 11px; font-weight: 800; text-transform: uppercase;
  letter-spacing: .06em; color: rgba(255, 255, 255, 0.6);
}
.conf-view-chap-total { margin-left: auto; font-size: 11px; font-weight: 700; color: rgba(255, 255, 255, 0.5); }
.conf-view-chap-close {
  flex: none;
  width: 30px; height: 30px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(0, 0, 0, 0.45);
  color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .18s, transform .12s;
}
.conf-view-chap-close:hover { background: rgba(0, 0, 0, 0.7); }
.conf-view-chap-close:active { transform: scale(0.9); }
.conf-view-chap-close svg { width: 15px; height: 15px; fill: currentColor; }

.conf-view-chap-list {
  position: relative; /* repère offsetTop pour l'auto-scroll (scrollTo) */
  flex: 1; min-height: 0;
  overflow-y: auto; overscroll-behavior: contain;
  display: flex; flex-direction: column; gap: 2px;
  padding: 0 10px 12px;
}
.conf-view-chap-row {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: auto 1fr; gap: 3px 10px; align-items: start;
  flex: none; /* liste scrollable : sans ça, flex-shrink tasse les rangées quand la liste déborde */
  width: 100%; padding: 9px 10px 11px;
  border: 0; border-radius: var(--radius-sm);
  background: transparent; text-align: left; cursor: pointer;
  font-family: var(--font);
  transition: background .15s;
}
.conf-view-chap-row:hover { background: rgba(255, 255, 255, 0.08); }
.conf-view-chap-row:focus-visible { outline: 2px solid var(--abricot); outline-offset: -2px; }
.conf-view-chap-row.is-active { background: rgba(222, 137, 90, 0.16); }
.conf-view-chap-time {
  grid-row: span 2;
  /* Largeur fixe : aligne titres/thèmes d'une rangée à l'autre, même quand un
     timecode passe en heures. has-h (posé par buildChapters) élargit la colonne
     si AU MOINS un chapitre dépasse 1h. */
  min-width: 52px; text-align: center;
  font-size: 11px; font-weight: 800; font-variant-numeric: tabular-nums;
  color: rgba(255, 255, 255, 0.75);
  background: rgba(255, 255, 255, 0.1);
  padding: 3px 7px; border-radius: 4px;
  transition: background .15s, color .15s;
}
.conf-view-chap.has-h .conf-view-chap-time { min-width: 68px; }
.conf-view-chap-row.is-active .conf-view-chap-time { background: var(--abricot); color: #fff; }
.conf-view-chap-seq {
  font-size: 13px; font-weight: 700; color: #fff;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.conf-view-chap-theme {
  font-size: 12px; line-height: 1.35; color: rgba(255, 255, 255, 0.62);
  display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
/* Barre de progression du chapitre actif — largeur pilotée par --chap-pct
   (écrite par le sondage 250 ms : simple custom property, pas de reflow) */
.conf-view-chap-row::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px;
  width: var(--chap-pct, 0%); background: var(--abricot);
  opacity: 0; transition: width .25s linear, opacity .2s;
}
.conf-view-chap-row.is-active::after { opacity: 1; }

@media (max-width: 900px) {
  .conf-view-inner { flex-direction: column; overflow-y: auto; max-width: none !important; }
  .conf-view-info { flex: 0 0 auto !important; width: 100% !important; margin-left: 0 !important; padding: 56px 16px 24px; opacity: 1 !important; pointer-events: auto !important; }
  .conf-view-player { padding: 0 16px 24px; }
  .conf-view-stage { width: 100% !important; }
  .conf-view-logo { width: 104px; margin-bottom: 18px; }
  .conf-view-chap { width: 100%; }
  .conf-view-chap-btn { top: 8px; right: 8px; padding: 7px 10px; }
}

@media (max-width: 480px) {
  .conf-view-chap-btn .cv-chap-label { display: none; }
  .cv-chap-now-title { width: 100px; } /* titre raccourci sur petit écran */
}

/* ===== CONFERENCES PAGE (toolbar, chips matiere, segment de vues, hero, empty) ===== */

/* Utility : curseur clickable (ex. upcoming items) */
.clickable { cursor: pointer; }

/* Etat vide des grilles / filtres (remplace les styles inline des helpers) */
.conf-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 28px 20px;
  color: var(--text-muted);
  font-size: 13px;
  border: 1.5px dashed var(--border);
  border-radius: var(--radius-sm);
  background: var(--card);
}
.conf-empty-filter { grid-column: 1 / -1; }
.conf-loading {
  grid-column: 1 / -1;
  text-align: center;
  padding: 36px;
  color: var(--text-muted);
  font-size: 13px;
}

/* Toolbar : recherche + chips matiere + segment de vues */
.conf-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 22px;
}
.conf-toolbar .filter-search,
.conf-toolbar .seg { flex: 0 0 auto; }
/* Le switch de vues reste aligné à droite, quel que soit le nombre de filtres. */
.conf-toolbar .seg { margin-left: auto; }
.conf-toolbar .filter-search input { width: 300px; height: 38px; }
.conf-toolbar .filter-chips { flex: 1 1 300px; min-width: 0; }
/* Filtre « Item » : groupe attaché au champ de recherche (cf. .item-select),
   hors de la rangée de chips -> non extensible, pas de trou avant le seg. */
.conf-toolbar .filter-item { flex: 0 0 auto; display: flex; align-items: center; }
/* Conteneur vide (aucun bouton item) : retiré du flux flex — sinon le gap du
   toolbar crée un espace entre le champ de recherche et la pastille spécialité. */
.conf-toolbar .filter-item:empty { display: none; }
.conf-toolbar .filter-item:not(:empty) { margin-left: -13.5px; } /* gap + bordure du champ */
.filter-search:has(+ .filter-item:not(:empty)) input {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}
/* Les chips croissent (flex-grow) -> poussent le seg de vue (Grille/Mois/Matiere)
   tout a droite, sans detacher le seg Toutes/Live/Presentiel du groupe de filtres. */

/* Rangee de chips matiere */
.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

/* Filtre « Item » (pages Replays / Masterclass / Khalicours) : bouton ouvrant
   un popover cherchable — une centaine d'items ne tient pas en chips. Posé
   juste après le champ de recherche, il en épouse le style (groupe attaché). */
.chip.item-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  max-width: 260px;
  padding: 0 12px;
  border: 1.5px solid var(--border);
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  background: var(--bg);
}
/* .chip.item-select:hover { border-color: var(--bleu-petrole-clair); color: var(--bleu-petrole); } */
.chip.item-select.active {
  background: rgba(var(--bleu-petrole-rgb), 0.08);
  border-color: var(--bleu-petrole-clair);
  color: var(--bleu-petrole);
}
.item-select-value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.chip.item-select svg {
  width: 16px; height: 16px;
  flex: none;
  fill: currentColor;
  opacity: .5;
}
.item-pop {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 320px;
  max-width: calc(92vw - 14px);
}
.item-pop-search {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--bg);
  font: 500 13px/1 var(--font);
  color: var(--text);
  outline: none;
}
.item-pop-search:focus { border-color: var(--bleu-petrole-clair); }
.item-pop-list {
  max-height: min(45vh, 320px);
  overflow-y: auto;
  overscroll-behavior: contain;
  margin: 0 -2px;
  padding: 0 2px;
}
.item-pop-row {
  display: block;
  width: 100%;
  padding: 8px 10px;
  border: none;
  background: transparent;
  border-radius: 8px;
  font: 500 13px/1.3 var(--font);
  color: var(--text);
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: background .12s, color .12s;
}
.item-pop-row:hover { background: rgba(var(--bleu-petrole-rgb), 0.07); color: var(--bleu-petrole); }
.item-pop-row.is-active {
  background: rgba(var(--bleu-petrole-rgb), 0.1);
  color: var(--bleu-petrole);
  font-weight: 700;
}
.item-pop-hint { padding: 10px; font-size: 12.5px; color: var(--text-muted); text-align: center; }

/* Dropdown « Spécialité » : même patron que le filtre item (pastille + popover
   cherchable). Le groupe est SOUDÉ : (recherche|Tous les items|Toutes les
   spécialités) — bordures partagées, angles intérieurs carrés, seul le dernier
   élément est arrondi à droite. */
.conf-toolbar .filter-chips:has(.matiere-select) {
  flex: 0 0 auto;
  margin-left: -13.5px; /* gap + bordure du bouton item (ou du champ de recherche) */
}
/* L'item est collé des deux côtés : il perd ses arrondis droits. */
.conf-toolbar:has(.matiere-select) .chip.item-select {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}
/* Sans bouton item, la pastille spécialité se colle au champ de recherche.
   ~ et pas + : le conteneur .filter-item (vide) reste entre les deux dans le DOM. */
.filter-search:has(~ .filter-chips .matiere-select) input {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}
.filter-search ~ .filter-chips .matiere-select {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}
.chip.matiere-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  max-width: 260px;
  padding: 0 12px;
  border: 1.5px solid var(--border);
  border-left-width: 0; /* bordure partagée avec l'élément collé à gauche */
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  border-top-right-radius: 16px;
  border-bottom-right-radius: 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  background: var(--bg);
}
/* Pas de changement de bordure/couleur au survol (base .chip:hover neutralisée) :
   la pastille est soudée au groupe, sa bordure changeante jette un trou. */
.chip.matiere-select:hover { border-color: var(--border); color: var(--text); }
.chip.matiere-select.active {
  background: rgba(var(--bleu-petrole-rgb), 0.08);
  border-color: var(--bleu-petrole-clair);
  color: var(--bleu-petrole);
}
.chip.matiere-select.active:hover {
  border-color: var(--bleu-petrole-clair);
  color: var(--bleu-petrole);
}
.matiere-select-value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.chip.matiere-select svg {
  width: 16px; height: 16px;
  flex: none;
  fill: currentColor;
  opacity: .5;
}

/* Responsive : sous 768px le toolbar se recharge — le champ prend la pleine
   largeur et chaque filtre redevient une pastille autonome : la soudure de
   groupe (marges négatives, angles carrés) est entièrement défaite. */
@media (max-width: 768px) {
  .conf-toolbar .filter-search { flex: 1 1 100%; }
  .conf-toolbar .filter-search input { width: 100%; }
  .conf-toolbar .filter-item:not(:empty),
  .conf-toolbar .filter-chips:has(.matiere-select) { margin-left: 0; }
  .conf-toolbar .seg { margin-left: 0; }
  .filter-search:has(+ .filter-item:not(:empty)) input,
  .filter-search:has(~ .filter-chips .matiere-select) input {
    border-top-right-radius: var(--radius-sm);
    border-bottom-right-radius: var(--radius-sm);
  }
  .conf-toolbar:has(.matiere-select) .chip.item-select {
    border-top-right-radius: 16px;
    border-bottom-right-radius: 16px;
  }
  .chip.matiere-select {
    border-left-width: 1.5px;
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
  }
  .filter-search ~ .filter-chips .matiere-select {
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
  }
}

/* Controle segmente (Grille / Par mois / Par matiere) */
.seg {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  background: rgba(var(--bleu-petrole-rgb), 0.06);
  border: 1.5px solid var(--border);
  border-radius: 999px;
}
.seg-btn {
  border: none;
  background: transparent;
  color: var(--text-muted);
  font: 600 12px/1 var(--font);
  padding: 8px 15px;
  border-radius: 999px;
  cursor: pointer;
  transition: background .2s ease, color .2s ease;
  white-space: nowrap;
}
.seg-btn:hover { color: var(--text); }
.seg-btn.active {
  background: var(--bleu-petrole);
  color: #fff;
  box-shadow: 0 2px 8px rgba(var(--bleu-petrole-rgb), 0.25);
}

/* Mise en avant (hero) - premiere conference a venir */
.conf-hero {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 330px;
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 26px;
  cursor: pointer;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  transition: transform .25s ease, box-shadow .25s ease;
}
.conf-hero:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }
.conf-hero-bg { position: absolute; inset: 0; z-index: 0; }
.conf-hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.conf-hero-bg::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(8,18,24,.94) 0%, rgba(8,18,24,.72) 42%, rgba(8,18,24,.2) 100%);
}
.conf-hero-body { position: relative; z-index: 1; padding: 34px; max-width: 640px; }
.conf-hero-label {
  display: inline-block;
  font: 800 10px/1 var(--font);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--abricot);
  margin-bottom: 12px;
}
.conf-hero h2 {
  color: #fff;
  font-size: 30px;
  line-height: 1.15;
  font-weight: 800;
  margin: 0 0 10px;
  text-shadow: 0 2px 18px rgba(0,0,0,.4);
}
.conf-hero-meta { color: rgba(255,255,255,.86); font-size: 13px; font-weight: 500; }
.conf-hero-badge {
  display: inline-flex;
  align-items: center;
  font: 700 11px/1 var(--font);
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--abricot);
  color: #fff;
  margin-bottom: 12px;
}
.conf-hero-badge.live { background: var(--danger); }
.conf-hero-badge.live.is-now { animation: confk-live-blink 1.6s ease-in-out infinite; }
.conf-hero-badge.presentiel { background: var(--success); }
.conf-hero-actions { margin-top: 18px; display: flex; gap: 10px; align-items: center; }
.conf-hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: none;
  background: #fff;
  color: var(--bleu-petrole);
  font: 700 13px/1 var(--font);
  padding: 12px 22px;
  border-radius: 999px;
  cursor: pointer;
  transition: transform .2s ease, background .2s ease, color .2s ease;
}
.conf-hero-btn:hover { transform: scale(1.04); background: var(--abricot); color: #fff; }

/* Sections groupees (Par mois / Par matiere) */
.conf-group { margin-bottom: 30px; }
.conf-group > .section-title {
  font-size: 20px;
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 20px 0;
}

/* Vue « Par matiere » : drill d'une specialite (replays, masterclass...).
   Le bouton retour .hub-drill-back est partage avec le hub Training
   (regles deplacees depuis training-hub.css). */
.confk-drill { margin-bottom: 30px; }
.hub-drill-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 16px;
  padding: 6px 12px 6px 8px;
  border: 1.5px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--bleu-petrole-clair);
  font: 700 12px/1 var(--font);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.hub-drill-back:hover { background: var(--bg); color: var(--bleu-petrole); border-color: var(--bleu-petrole-clair); }
.hub-drill-back svg { width: 15px; height: 15px; fill: currentColor; }
.hub-drill-back:focus-visible { outline: 2px solid var(--bleu-petrole-clair); outline-offset: 2px; }

@media (max-width: 700px) {
  .conf-hero { min-height: 240px; }
  .conf-hero-body { padding: 22px; }
  .conf-hero h2 { font-size: 22px; }
  .conf-toolbar .seg { margin-left: 0; }
}

/* ===================================================================
   AUTH LAYOUT — ecrans connexion / inscription / mot de passe oublié
   Layout ecran scinde : panneau marque a gauche + carte formulaire a droite.
   Active via body.auth-page (cf. header.part.php).
   Cf. assets/js/auth.js pour les interactions (toggle pass, stepper, reCaptcha).
   =================================================================== */

/* On desactive le chrome de l'app (sidebar + topbar) et on transforme
   .main / .page en un fond d'auth plein ecran centre. */
body.auth-page .app { height: auto; min-height: 100vh; }
body.auth-page .sidebar,
body.auth-page .topbar { display: none !important; }
body.auth-page .main {
  background:
    radial-gradient(1100px 600px at 12% -8%, rgba(18, 78, 94, 0.10), transparent 60%),
    radial-gradient(900px 500px at 100% 110%, rgba(222, 137, 90, 0.12), transparent 55%),
    linear-gradient(180deg, #eef4f5 0%, #e7eff1 100%);
}
body.auth-page .page {
  padding: 28px;
  width: 100%;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Grille scindee */
.auth {
  width: 100%;
  max-width: 1040px;
  display: grid;
  grid-template-columns: 1.02fr 1fr;
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 24px 70px rgba(var(--bleu-petrole-rgb), 0.16);
  border: 1px solid var(--border);
}

/* ----- Panneau marque (gauche) ----- */
.auth-aside {
  position: relative;
  padding: 44px 42px;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 18px;
  overflow: hidden;
  background:
    radial-gradient(420px 320px at 88% 6%, rgba(222, 137, 90, 0.42), transparent 62%),
    radial-gradient(520px 420px at 0% 100%, rgba(14, 116, 135, 0.55), transparent 60%),
    linear-gradient(150deg, #0a3d4a 0%, var(--bleu-petrole) 50%, #0b3440 100%);
}
.auth-aside > * { position: relative; z-index: 1; }

.auth-brand { display: flex; align-items: center; }
.auth-brand img { height: 38px; width: auto; display: block; filter: brightness(0) invert(1); }

.auth-slogan {
  font-size: 27px;
  font-weight: 800;
  line-height: 1.22;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.18);
}
.auth-slogan em {
  font-style: normal;
  color: var(--orange);
}
.auth-lead { margin: 0; font-size: 13.5px; line-height: 1.55; color: rgba(255, 255, 255, 0.82); }

.auth-features { display: flex; flex-direction: column; gap: 13px; margin: 0; padding: 0; list-style: none; }
.auth-feature {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
}
.auth-feature-ico {
  width: 34px; height: 34px;
  flex: none;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
  display: flex; align-items: center; justify-content: center;
}
.auth-feature-ico svg { width: 18px; height: 18px; fill: #fff; }

.auth-apps { display: flex; gap: 10px; flex-wrap: wrap; }
.auth-app-badge {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 8px 13px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff; text-decoration: none;
  transition: background 0.2s, transform 0.2s;
}
.auth-app-badge:hover { background: rgba(255, 255, 255, 0.20); transform: translateY(-1px); color: #fff; }
.auth-app-badge svg { width: 20px; height: 20px; fill: #fff; flex: none; }
.auth-app-badge b { display: block; font-size: 13px; font-weight: 800; line-height: 1.1; }
.auth-app-badge small { display: block; font-size: 9px; font-weight: 600; opacity: 0.82; text-transform: uppercase; letter-spacing: 0.05em; }

/* ----- Panneau formulaire (droite) ----- */
.auth-main {
  padding: 46px 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--card);
}
.auth-brand-mobile { display: none; justify-content: center; margin-bottom: 18px; }
.auth-brand-mobile img { height: 36px; width: auto; }

.auth-head { margin-bottom: 22px; }
.auth-head h1 {
  font-size: 25px; font-weight: 800; color: var(--bleu-petrole);
  margin: 0 0 5px; line-height: 1.2;
}
.auth-head p { font-size: 13px; color: var(--text-muted); margin: 0; line-height: 1.5; }

/* Champs */
.auth-field { margin-bottom: 14px; }
.auth-field > label {
  display: block; font-size: 12px; font-weight: 700;
  color: var(--text); margin-bottom: 6px;
}
.auth-field .auth-req { color: var(--abricot); margin-left: 2px; }
.auth-input-wrap { position: relative; display: block; }
.auth-input-wrap.has-ico .auth-input,
.auth-input-wrap.has-toggle .auth-input { padding-left: 42px; }
.auth-input-wrap.has-toggle .auth-input { padding-right: 44px; }
.auth-field-ico {
  position: absolute; left: 13px; top: 50%; transform: translateY(-50%);
  display: flex; pointer-events: none; color: var(--text-muted);
}
.auth-field-ico svg { width: 18px; height: 18px; fill: currentColor; }

.auth-input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font: 500 13px/1.4 var(--font);
  color: var(--text);
  background: var(--bg);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
  -webkit-appearance: none; appearance: none;
}
.auth-input:focus {
  outline: none;
  border-color: var(--bleu-petrole-clair);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(var(--bleu-petrole-rgb), 0.10);
}
.auth-input::placeholder { color: #9aa8b3; }
/* Select : fleche native remplacee */
select.auth-input {
  padding-right: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24'%3E%3Cpath fill='%236b7e8c' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

/* Bouton afficher / masquer le mot de passe */
.auth-toggle-pass {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  background: transparent; border: none; cursor: pointer;
  color: var(--text-muted); border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}
.auth-toggle-pass:hover { color: var(--bleu-petrole); background: rgba(var(--bleu-petrole-rgb), 0.06); }
.auth-toggle-pass svg { width: 18px; height: 18px; fill: currentColor; }
.auth-toggle-pass .ico-off { display: none; }
.auth-input-wrap.is-visible .auth-toggle-pass .ico-on { display: none; }
.auth-input-wrap.is-visible .auth-toggle-pass .ico-off { display: block; }

/* Indice de robustesse du mot de passe */
.auth-strength { margin-top: 9px; }
.auth-strength-track { height: 5px; border-radius: 3px; background: var(--border); overflow: hidden; }
.auth-strength-fill { height: 100%; width: 0; background: var(--danger); border-radius: 3px; transition: width 0.25s ease, background 0.25s ease; }
.auth-strength-label { font-size: 10.5px; color: var(--text-muted); margin-top: 5px; font-weight: 600; }
.auth-hint { font-size: 11px; color: var(--text-muted); margin-top: 6px; }

/* Grille 2 colonnes (nom / prenom, etc.) */
.auth-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }

/* Bloc etape / stepper inscription */
.auth-steps-wrap { position: relative; }
.auth-step-panel { display: none; animation: auth-fade 0.3s ease; }
.auth-step-panel.is-active { display: block; }
@keyframes auth-fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.auth-back {
  display: inline-flex; align-items: center; gap: 5px;
  background: none; border: none; cursor: pointer;
  font: 600 12px/1 var(--font); color: var(--text-muted);
  padding: 6px 0; margin-bottom: 12px;
}
.auth-back:hover { color: var(--bleu-petrole); }
.auth-back svg { width: 16px; height: 16px; fill: currentColor; }

/* Cases a cocher (conditions / charte) */
.auth-check {
  display: flex; align-items: flex-start; gap: 10px;
  margin: 10px 0; font-size: 12px; color: var(--text); line-height: 1.5;
  cursor: pointer;
}
.auth-check input { margin-top: 2px; width: 16px; height: 16px; accent-color: var(--bleu-petrole); flex: none; cursor: pointer; }
.auth-check a { color: var(--bleu-petrole-clair); font-weight: 600; }
.auth-check a:hover { color: var(--bleu-petrole); }
.auth-conditions {
  max-height: 160px; overflow: auto;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 14px; background: var(--bg);
  font-size: 11.5px; color: var(--text-muted); line-height: 1.55;
  margin: 6px 0 10px;
}
.auth-fieldsep { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--bleu-petrole); margin: 18px 0 6px; }
.auth-fieldsep-opt { text-transform: none; font-weight: 600; color: var(--text-muted); letter-spacing: 0; }

/* Bouton principal plein large */
.auth-submit {
  width: 100%;
  justify-content: center;
  padding: 13px 18px;
  font-size: 13px;
  margin-top: 8px;
}

/* Liens sous le formulaire */
.auth-links {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; flex-wrap: wrap;
  margin-top: 16px; font-size: 12.5px;
}
.auth-links a { color: var(--bleu-petrole-clair); font-weight: 600; text-decoration: none; }
.auth-links a:hover { color: var(--bleu-petrole); text-decoration: underline; }
.auth-links.center { justify-content: center; }

.auth-divider {
  display: flex; align-items: center; gap: 12px;
  margin: 18px 0; color: var(--text-muted);
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em;
}
.auth-divider::before, .auth-divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }

.auth-foot { margin-top: 18px; font-size: 11px; color: var(--text-muted); text-align: center; line-height: 1.6; }
.auth-foot a { color: var(--bleu-petrole-clair); }

/* Stepper du flux commande (Choix > Identification > Paiement) */
.auth-steps {
  display: flex; align-items: center; justify-content: center;
  gap: 0; margin: 0 auto 22px; max-width: 460px;
}
.auth-step { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; color: var(--text-muted); }
.auth-step .num {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--bg); border: 1.5px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; color: var(--text-muted);
}
.auth-step.done .num { background: var(--success); border-color: var(--success); color: #fff; }
.auth-step.done { color: var(--success); }
.auth-step.current .num { background: var(--bleu-petrole); border-color: var(--bleu-petrole); color: #fff; box-shadow: 0 0 0 4px rgba(var(--bleu-petrole-rgb), 0.10); }
.auth-step.current { color: var(--bleu-petrole); }
.auth-step-sep { width: 32px; height: 2px; background: var(--border); margin: 0 8px; border-radius: 2px; }
.auth-step a { color: inherit; text-decoration: none; }
.auth-step a:hover { text-decoration: underline; }

/* Encart info / synopsis (concours, formule, ecos) */
.auth-notice {
  background: rgba(var(--bleu-petrole-rgb), 0.04);
  border: 1px solid var(--border);
  border-left: 3px solid var(--abricot);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 18px;
  font-size: 12.5px; color: var(--text); line-height: 1.6;
}
.auth-notice h1, .auth-notice h2 { font-size: 16px; font-weight: 800; color: var(--bleu-petrole); margin: 0 0 6px; }
.auth-notice p { margin: 0 0 6px; }
.auth-notice p:last-child { margin-bottom: 0; }

/* Etat succes / info centre */
.auth-state { text-align: center; padding: 8px 0; }
.auth-state-ico {
  width: 70px; height: 70px; margin: 0 auto 18px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.auth-state-ico.success { background: rgba(61, 158, 124, 0.12); }
.auth-state-ico.success svg { fill: var(--success); }
.auth-state-ico.info { background: rgba(var(--bleu-petrole-rgb), 0.08); }
.auth-state-ico.info svg { fill: var(--bleu-petrole); }
.auth-state-ico svg { width: 34px; height: 34px; }
.auth-state h1 { font-size: 23px; font-weight: 800; color: var(--bleu-petrole); margin: 0 0 10px; }
.auth-state p { font-size: 13.5px; color: var(--text-muted); line-height: 1.6; margin: 0 0 8px; }
.auth-state .auth-state-actions { margin-top: 22px; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.auth-state-actions .auth-submit { max-width: 280px; margin: 0 auto; }
html[data-page-view="document"] iframe.pdfviewer {
    width: 100vw;
    height: 100vh;
}

html[data-page-view="document"] {
    overflow: hidden;
}
/* ----- Responsive ----- */
@media (max-width: 900px) {
  .auth { grid-template-columns: 1fr; max-width: 460px; }
  .auth-aside { display: none; }
  .auth-brand-mobile { display: flex; }
  .auth-main { padding: 34px 28px; }
  body.auth-page .page { padding: 18px; }
}
@media (max-width: 520px) {
  .auth-grid-2 { grid-template-columns: 1fr; }
  .auth-main { padding: 30px 20px; }
  .auth-head h1 { font-size: 22px; }
  .auth-links { flex-direction: column; align-items: center; gap: 8px; }
}

