/* ── Reset ── */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: Georgia, 'Times New Roman', serif; font-size: 15px; color: #222; background: #fff; }
a { color: #2255a0; text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }

/* ── Header ── */
#header { background: #1a3a6e; }
#header-top {
  display: flex; align-items: center; gap: 18px;
  padding: 14px 28px; border-bottom: 3px solid #3a6ec8;
}
#header-logo {
  flex-shrink: 0; display: flex; align-items: center;
}
#header-logo img { height: 54px; width: auto; display: block; }
#header-title h1 { font-size: 20px; color: #fff; font-weight: bold; }
#header-title p { font-size: 12px; color: #aac4f0; font-style: italic; margin-top: 2px; }

/* ── Nav ── */
nav { background: #1a3a6e; padding: 0 28px; }
nav ul { list-style: none; display: flex; flex-wrap: wrap; }
nav ul li a {
  display: block; color: #c8dcff; padding: 9px 15px;
  font-size: 13px; font-family: Arial, sans-serif;
  border-right: 1px solid #2a4a80;
}
nav ul li:first-child a { border-left: 1px solid #2a4a80; }
nav ul li a:hover { background: #2a4a80; color: #fff; text-decoration: none; }
nav ul li.active a { background: #3a6ec8; color: #fff; }

/* ── Breadcrumb ── */
#breadcrumb {
  background: #f0f4fb; border-bottom: 1px solid #d0daea;
  padding: 7px 28px; font-size: 12px; font-family: Arial, sans-serif; color: #666;
}
#breadcrumb a { color: #2255a0; }
#breadcrumb a:hover { text-decoration: underline; }
#breadcrumb .sep { color: #bbb; margin: 0 5px; }

/* ── Layout ── */
#main-wrapper { display: flex; max-width: 1100px; margin: 0 auto; min-height: 500px; }

/* ── Sidebar ── */
#sidebar {
  width: 210px; flex-shrink: 0;
  border-right: 1px solid #ddd; padding: 20px 0; background: #f7f9fc;
}
.sidebar-section { margin-bottom: 20px; }
.sidebar-section h3 {
  font-size: 11px; font-family: Arial, sans-serif; text-transform: uppercase;
  letter-spacing: 1px; color: #1a3a6e; padding: 4px 14px;
  border-left: 3px solid #3a6ec8; margin-bottom: 6px; font-weight: bold;
}
.sidebar-section ul { list-style: none; padding: 0 0 0 17px; }
.sidebar-section ul li { padding: 2px 0; }
.sidebar-section ul li a { font-size: 13px; color: #2255a0; }
.sidebar-section ul li a:hover { text-decoration: underline; }
.sidebar-section ul li.sub { padding-left: 10px; }
.sidebar-section ul li.sub a { font-size: 12px; color: #446; }

/* ── Content ── */
#content { flex: 1; padding: 24px 32px; min-width: 0; }

/* ── Hero ── */
.hero {
  width: 100%; height: 220px; object-fit: cover;
  display: block; margin-bottom: 22px;
  border-bottom: 3px solid #3a6ec8;
}
.hero-caption {
  font-size: 11px; color: #888; font-family: Arial, sans-serif;
  margin-top: -18px; margin-bottom: 18px; font-style: italic;
}

/* ── Typography ── */
h2 {
  font-size: 20px; color: #1a3a6e;
  border-bottom: 2px solid #3a6ec8; padding-bottom: 6px;
  margin-bottom: 18px; font-family: Arial, sans-serif;
}
h3 { font-size: 15px; color: #1a3a6e; margin: 22px 0 8px; font-family: Arial, sans-serif; }
h4 { font-size: 14px; color: #333; margin: 14px 0 5px; font-family: Arial, sans-serif; }
p { margin-bottom: 10px; line-height: 1.75; }
ul.content-list { margin: 6px 0 12px 22px; line-height: 1.85; }
ul.content-list li { margin-bottom: 2px; }

/* ── Info box ── */
.info-box {
  background: #eef3fb; border-left: 4px solid #3a6ec8;
  padding: 12px 16px; margin-bottom: 16px; font-size: 14px; line-height: 1.75;
}
.info-box strong { color: #1a3a6e; }

.alert-box {
  background: #fff8e8; border-left: 4px solid #d4a017;
  padding: 12px 16px; margin-bottom: 16px; font-size: 14px; line-height: 1.7;
}

/* ── Cards ── */
.card-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 12px 0 18px; }
.card-grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; margin: 12px 0 18px; }
.card {
  border: 1px solid #d0daea; padding: 14px;
  background: #fafcff; transition: border-color 0.15s;
}
.card:hover { border-color: #3a6ec8; }
.card h4 { margin-top: 0; color: #1a3a6e; font-size: 13px; font-weight: bold; }
.card p, .card ul { font-size: 13px; color: #444; margin-bottom: 0; }
.card ul { margin-left: 16px; line-height: 1.75; }
.card img { width: 100%; height: 130px; object-fit: cover; margin-bottom: 10px; display: block; }
.card a.card-link { font-size: 12px; font-family: Arial, sans-serif; color: #3a6ec8; display: inline-block; margin-top: 8px; }

/* ── Tables ── */
table.data-table { width: 100%; border-collapse: collapse; font-size: 14px; margin-bottom: 20px; }
table.data-table th {
  background: #1a3a6e; color: #fff; padding: 9px 12px;
  text-align: left; font-family: Arial, sans-serif; font-weight: normal; font-size: 13px;
}
table.data-table td { padding: 8px 12px; border-bottom: 1px solid #e0e8f4; vertical-align: top; }
table.data-table tr:nth-child(even) td { background: #f4f7fc; }
table.data-table td a { color: #2255a0; }

/* ── Formation blocs ── */
.formation-bloc { border: 1px solid #d0daea; margin-bottom: 14px; background: #fafcff; }
.formation-bloc-header {
  background: #e4ecf8; padding: 9px 14px;
  font-weight: bold; font-family: Arial, sans-serif;
  font-size: 14px; color: #1a3a6e;
  border-bottom: 1px solid #c8d8f0;
  display: flex; justify-content: space-between; align-items: center;
}
.formation-bloc-header a { font-size: 12px; font-weight: normal; color: #3a6ec8; }
.formation-bloc-body { padding: 12px 14px; }
.formation-bloc-body ul { margin-left: 18px; line-height: 1.85; font-size: 14px; }
.formation-bloc-body p { font-size: 14px; line-height: 1.7; margin-bottom: 6px; }

/* ── Tags ── */
.tag {
  display: inline-block; background: #e4ecf8; color: #1a3a6e;
  font-size: 11px; font-family: Arial, sans-serif;
  padding: 2px 8px; border-radius: 2px; margin: 2px;
}
.tag-green { background: #e8f5e9; color: #2e7d32; }
.tag-orange { background: #fff3e0; color: #e65100; }

/* ── News ── */
.news-list { list-style: none; }
.news-list li { padding: 14px 0; border-bottom: 1px solid #e5eaf5; display: flex; gap: 14px; align-items: flex-start; }
.news-list li:last-child { border-bottom: none; }
.news-list .news-img { width: 110px; height: 75px; object-fit: cover; flex-shrink: 0; }
.news-list .news-body { flex: 1; }
.news-list .news-date { font-size: 11px; color: #888; font-family: Arial, sans-serif; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 3px; }
.news-list .news-cat { font-size: 11px; font-family: Arial, sans-serif; color: #3a6ec8; font-weight: bold; margin-left: 8px; }
.news-list .news-title a { font-size: 15px; font-weight: bold; color: #1a3a6e; }
.news-list .news-excerpt { font-size: 13px; color: #555; margin-top: 5px; line-height: 1.6; }

/* ── Person cards ── */
.person-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; }
.person-card {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 12px; border: 1px solid #d0daea; background: #fafcff;
}
.person-card img {
  width: 72px; height: 72px; object-fit: cover;
  border-radius: 2px; flex-shrink: 0; filter: grayscale(20%);
}
.person-card .person-info h4 { margin-top: 0; font-style: normal; color: #1a3a6e; font-size: 13px; font-weight: bold; }
.person-card .person-info .person-role { font-size: 12px; color: #555; font-style: italic; margin-bottom: 2px; }
.person-card .person-info .person-email { font-size: 12px; color: #2255a0; font-family: Arial, sans-serif; }
.person-card .person-info .person-theme { font-size: 12px; color: #777; margin-top: 3px; }

/* ── Article ── */
.article-meta { font-size: 13px; color: #888; font-family: Arial, sans-serif; margin-bottom: 16px; padding-bottom: 10px; border-bottom: 1px solid #e0e8f4; }
.article-meta strong { color: #444; }
.article-img { width: 100%; max-height: 280px; object-fit: cover; margin-bottom: 10px; display: block; }
.article-img-caption { font-size: 12px; color: #888; font-style: italic; margin-bottom: 16px; }
.article-body p { line-height: 1.85; margin-bottom: 14px; }

/* ── Lab page ── */
.lab-stat { text-align: center; padding: 16px 10px; border: 1px solid #d0daea; background: #f7f9fc; }
.lab-stat .stat-num { font-size: 28px; font-weight: bold; color: #1a3a6e; font-family: Arial, sans-serif; }
.lab-stat .stat-label { font-size: 12px; color: #666; font-family: Arial, sans-serif; margin-top: 2px; }

/* ── Pagination / quick nav ── */
.page-nav { display: flex; gap: 10px; flex-wrap: wrap; margin: 18px 0; }
.page-nav a {
  padding: 6px 14px; border: 1px solid #3a6ec8; color: #3a6ec8;
  font-size: 13px; font-family: Arial, sans-serif;
}
.page-nav a:hover { background: #3a6ec8; color: #fff; text-decoration: none; }
.page-nav a.current { background: #1a3a6e; color: #fff; border-color: #1a3a6e; }

/* ── Footer ── */
#footer {
  background: #1a3a6e; color: #aac4f0;
  text-align: center; padding: 16px;
  font-size: 12px; font-family: Arial, sans-serif; margin-top: 30px;
}
#footer a { color: #c8dcff; }
#footer .footer-links { margin-top: 5px; }
#footer .footer-links a { margin: 0 8px; }

/* ── Partner logos ── */
.partner-logos {
  display: flex; flex-wrap: wrap; gap: 24px;
  align-items: center; margin: 14px 0 22px;
}
.partner-logos img {
  height: 64px; width: auto; max-width: 160px;
  object-fit: contain; filter: grayscale(20%);
  transition: filter 0.2s;
}
.partner-logos img:hover { filter: none; }

/* ── Burger button ── */
.burger-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-shrink: 0;
  margin-left: auto;
}
.burger-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: #c8dcff;
  border-radius: 2px;
  transition: transform .25s, opacity .25s;
}
.burger-btn.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger-btn.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.burger-btn.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Sidebar toggle (injecté via JS, visible uniquement mobile) ── */
.sidebar-toggle-btn {
  display: none;
  width: 100%;
  padding: 10px 14px;
  background: #e4ecf8;
  border: none;
  border-bottom: 1px solid #c8d8f0;
  font-family: Arial, sans-serif;
  font-size: 13px;
  font-weight: bold;
  color: #1a3a6e;
  cursor: pointer;
  text-align: left;
}
.sidebar-toggle-btn:hover { background: #d0ddf0; }

/* ── Responsive ── */
@media (max-width: 768px) {
  /* Header */
  #header { position: relative; }
  #header-top { padding: 10px 14px; gap: 12px; }
  #header-logo img { height: 42px !important; }
  #header-title h1 { font-size: 15px; }
  #header-title p { display: none; }

  /* Burger + nav dropdown */
  .burger-btn { display: flex; }
  nav {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    z-index: 200;
    background: #1a3a6e;
    border-top: 2px solid #3a6ec8;
  }
  nav.open { display: block; }
  nav ul { flex-direction: column; padding: 0; }
  nav ul li a {
    border-right: none;
    border-left: none !important;
    border-bottom: 1px solid #2a4a80;
    padding: 11px 18px;
  }
  nav ul li:first-child a { border-top: none; }

  /* Layout */
  #main-wrapper { flex-direction: column; }

  /* Sidebar collapsible */
  .sidebar-toggle-btn { display: block; }
  #sidebar {
    display: none;
    width: 100%;
    border-right: none;
    border-bottom: 1px solid #ddd;
    padding: 14px 0;
  }
  #sidebar.sidebar-open { display: block; }

  /* Content */
  #content { padding: 14px 16px; }
  #breadcrumb { padding: 6px 14px; font-size: 11px; }

  /* Cards */
  .card-grid, .card-grid-3, .person-grid { grid-template-columns: 1fr; }

  /* Tables : scroll horizontal */
  table.data-table { display: block; overflow-x: auto; max-width: 100%; }

  /* News */
  .news-list .news-img { display: none; }

  /* Partner logos */
  .partner-logos { gap: 14px; }
  .partner-logos img { height: 44px; max-width: 110px; }

  /* Annuaire */
  .annuaire-table-wrap { overflow-x: auto; }
}
