:root {
  /* Color Palette - Light theme with Navy & Golden Yellow */
  --bg-color: #f2f5fb;
  --bg-card: #ffffff;
  --bg-nav: rgba(255, 255, 255, 0.97);
  --text-primary: #1a2340;
  --text-secondary: #4a6080;
  --accent-blue: #1a5fa8;
  --accent-yellow: #c9921a;
  --accent-gold: #b07c12;
  --accent-yellow-soft: #d4a043;
  --success: #057a55;
  --border-color: #dde4f0;
  --border-yellow: rgba(201, 146, 26, 0.35);
  --shadow-sm: 0 1px 4px rgba(30, 50, 100, 0.07);
  --shadow-md: 0 8px 28px rgba(30, 50, 100, 0.12);
  --shadow-yellow: 0 0 20px rgba(201, 146, 26, 0.18);
  --transition-fast: 0.2s ease;
  --radius-md: 8px;
  --radius-lg: 12px;
  --primary-accent: #c9921a;
}

/* Global resets */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
  color: var(--accent-blue);
  margin-top: 0;
}

a {
  color: var(--accent-blue);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  text-decoration: underline;
  color: var(--accent-yellow);
}

/* Layout */
.container {
  max-width: 1600px !important;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Header & Nav */
/* Cibler UNIQUEMENT le header de site (enfant direct de <body>) : un
   sélecteur `header` nu rendait aussi sticky les <header> internes
   (ex. .page-header d'un article), qui flottaient sur la page au scroll. */
body > header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: var(--bg-nav);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  padding: 0.5rem 0;
}

nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.nav-links a,
.dropdown-trigger {
  font-weight: 500;
  color: var(--text-secondary);
  font-size: 0.9rem;
  padding: 0.5rem 0;
  cursor: pointer;
}

.nav-links a.active,
.nav-links a:hover,
.dropdown-trigger:hover {
  color: var(--accent-yellow);
  text-decoration: none;
}

/* Hamburger toggle button */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
  color: var(--text-primary);
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
}

.nav-toggle:hover {
  background: rgba(201, 146, 26, 0.1);
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
    order: 3;
  }

  nav {
    flex-wrap: wrap;
  }

  .logo {
    flex: 1;
    order: 1;
  }

  .lang-switcher {
    order: 2;
    margin-right: 0.5rem;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    order: 4;
    gap: 0;
    padding: 0.5rem 0 0.75rem;
    border-top: 1px solid var(--border-color);
    margin-top: 0.5rem;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links > a,
  .nav-links > .dropdown > .dropdown-trigger {
    display: block;
    padding: 0.55rem 0;
    border-bottom: 1px solid var(--border-color);
  }

  .dropdown-content {
    position: static;
    box-shadow: none;
    border: none;
    border-left: 2px solid var(--border-color);
    margin-left: 1rem;
    padding: 0.25rem 0;
    border-radius: 0;
    min-width: unset;
    display: none;
  }

  .dropdown:hover .dropdown-content {
    display: none;
  }

  .dropdown.open .dropdown-content {
    display: block;
  }
}

/* Dropdown */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background-color: var(--bg-card);
  min-width: 200px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  z-index: 1001;
  padding: 0.5rem 0;
}

.dropdown:hover .dropdown-content {
  display: block;
}

.dropdown-content a {
  padding: 0.75rem 1.5rem;
  display: block;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.dropdown-content a:hover {
  background-color: rgba(201, 146, 26, 0.1);
  color: var(--accent-yellow);
  text-decoration: none;
}

.logo {
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -1px;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-yellow));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.logo a {
  font-style: italic;
}

.lang-switcher select {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-md);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.lang-switcher select:hover {
  border-color: var(--accent-blue);
  color: var(--text-primary);
}

.lang-switcher form {
  padding: 0;
  margin: 0;
  background: transparent;
  border: none;
}

/* Layout Grid */
.main-layout {
  display: grid;
  grid-template-columns: 150px 1fr 350px;
  gap: 2rem;
  margin-top: 2rem;
}

.layout-spacer {
  grid-column: 1;
}

.content-area {
  grid-column: 2;
}

.sidebar {
  grid-column: 3;
}

@media (max-width: 1450px) {
  .main-layout {
    grid-template-columns: 1fr 350px;
  }

  .layout-spacer {
    display: none;
  }

  .content-area {
    grid-column: 1;
  }

  .sidebar {
    grid-column: 2;
  }
}

@media (max-width: 1050px) {
  .main-layout {
    grid-template-columns: 1fr;
  }

  .content-area,
  .sidebar {
    grid-column: 1;
  }
}

/* Sidebar */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.sidebar-section {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
}

.sidebar-section h3 {
  font-size: 0.85rem;
  margin-bottom: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--accent-blue);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  padding-left: 0.75rem;
  border-left: 3px solid var(--accent-yellow);
}

.sidebar-section svg {
  color: var(--accent-yellow);
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

.sidebar-section > p {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: -0.5rem;
  margin-bottom: 1rem;
  font-style: italic;
}

.mini-event {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.mini-event:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.mini-event h4 {
  font-size: 0.9rem;
  margin-bottom: 0.3rem;
  color: var(--accent-blue);
}

.mini-event p {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin: 0;
}

/* Sidebar Form adjustments */
.sidebar form {
  padding: 0;
  border: none;
  background: transparent;
}

/* Components */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
  cursor: pointer;
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-yellow);
  box-shadow: var(--shadow-md), var(--shadow-yellow);
}

.card-image {
  width: 100%;
  height: 200px;
  overflow: hidden;
  border-bottom: 1px solid var(--border-color);
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.card:hover .card-image img {
  transform: scale(1.05);
}

.card--organisation .card-image,
.card--institution .card-image,
.card--projet .card-image {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: var(--bg-color);
}

.card--organisation .card-image img,
.card--institution .card-image img,
.card--projet .card-image img {
  object-fit: contain;
  width: auto;
  max-width: 100%;
  max-height: 100%;
  height: auto;
}

.card--organisation:hover .card-image img,
.card--institution:hover .card-image img,
.card--projet:hover .card-image img {
  transform: scale(1.03);
}

.card-content {
  padding: 1.5rem;
}

.card h2 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.card p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 0;
}

.card-meta {
  font-size: 0.8rem;
  color: var(--accent-yellow);
  margin-bottom: 0.5rem;
  display: block;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.05em;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.2rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: none;
}

.btn-primary {
  background-color: var(--accent-yellow);
  color: #080d1a;
  font-weight: 700;
}

.btn-primary:hover {
  background-color: var(--accent-yellow-soft);
  color: #080d1a;
  transform: scale(1.02);
  text-decoration: none;
  box-shadow: var(--shadow-yellow);
}

/* Forms */
form {
  max-width: 450px;
  margin: 0 auto;
  background-color: var(--bg-card);
  padding: 2rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
}

form p {
  margin-bottom: 1.2rem;
}

form label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

form input,
form textarea,
form select {
  width: 100%;
  padding: 0.75rem;
  background-color: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: inherit;
}

form input:focus {
  outline: none;
  border-color: var(--accent-yellow);
  box-shadow: 0 0 0 3px rgba(245, 197, 24, 0.2);
}

/* News Slider */
.slider-module {
  width: 70%;
  margin: 0 auto 2rem;
}

.slider-wrapper {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 16px;
}

.slider-container {
  display: flex;
  direction: ltr;
  transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

.slide-card {
  flex: 0 0 100%;
  min-width: 100%;
  height: 336px;
  position: relative;
  cursor: pointer;
  overflow: hidden;
}

.slide-image,
.slide-no-image {
  position: absolute;
  inset: 0;
}

.slide-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.08);
  filter: blur(18px) brightness(0.45) saturate(1.3);
}

.slide-fg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.6s ease;
}

.slide-card:hover .slide-fg {
  transform: scale(1.03);
}

.slide-no-image {
  background: linear-gradient(135deg, var(--bg-card) 0%, #d0dcf0 100%);
}

/* Auto-advance progress bar */
.slider-progress {
  position: absolute;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--primary-accent);
  z-index: 20;
  border-radius: 0 2px 2px 0;
}

@keyframes slideProgress {
  from { width: 0%; }
  to   { width: 100%; }
}

/* Controls */
.slider-controls {
  position: absolute;
  top: 50%;
  width: 100%;
  display: flex;
  justify-content: space-between;
  transform: translateY(-50%);
  pointer-events: none;
  padding: 0 1rem;
  z-index: 10;
}

.slider-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: white;
  font-size: 1.6rem;
  cursor: pointer;
  pointer-events: auto;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.slider-btn:hover {
  background: var(--primary-accent);
  color: #000;
  transform: scale(1.1);
}

/* Dots */
.slider-dots {
  position: absolute;
  bottom: 0.8rem;
  right: 1rem;
  display: flex;
  gap: 6px;
  z-index: 10;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
}

.dot.active {
  background: var(--primary-accent);
  width: 24px;
  border-radius: 4px;
  border-color: transparent;
}

/* Caption area — below the slider */
.slide-captions {
  padding: 0.9rem 0.25rem 0;
  min-height: 6rem;
}

.slide-caption {
  display: none;
}

.slide-caption.active {
  display: block;
  animation: captionFadeIn 0.35s ease;
}

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

.slide-meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.45rem;
}

.slide-badge {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 0.18rem 0.65rem;
  border-radius: 20px;
  background: var(--primary-accent);
  color: #000;
}

.slide-badge--interview { background: var(--accent-blue); color: #000; }
.slide-badge--portrait  { background: #34d399; color: #000; }
.slide-badge--actualite { background: var(--primary-accent); color: #000; }

.slide-date {
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.slide-title {
  font-size: clamp(1rem, 2.2vw, 1.35rem);
  font-weight: 700;
  margin: 0 0 0.4rem;
  line-height: 1.35;
}

.slide-title a {
  color: var(--text-primary);
  text-decoration: none;
}

.slide-title a:hover {
  color: var(--accent-yellow);
  text-decoration: none;
}

.slide-lead {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (max-width: 992px) {
  .slider-module {
    width: 100%;
  }

  .slide-card {
    height: 240px;
  }
}

@media (max-width: 576px) {
  .slide-card {
    height: 200px;
  }

  .slide-lead {
    display: none;
  }
}

/* Sidebar Projet List */
.projet-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.projet-list li {
  margin-bottom: 0.5rem;
}

.projet-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0.75rem;
  background: rgba(26, 95, 168, 0.04);
  border-radius: 8px;
  text-decoration: none;
  color: var(--text-primary);
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.projet-item:hover {
  background: rgba(245, 197, 24, 0.07);
  border-color: var(--accent-yellow);
  transform: translateX(5px);
}

.projet-name {
  font-size: 0.9rem;
  font-weight: 500;
}

.projet-count {
  font-size: 0.8rem;
  background: var(--accent-yellow);
  color: #080d1a;
  padding: 2px 6px;
  border-radius: 12px;
  min-width: 20px;
  font-weight: 700;
  text-align: center;
}

/* Footer */
footer {
  padding: 4rem 0 3rem;
  border-top: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-top: 4rem;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.footer-links {
  display: flex;
  gap: 2rem;
}

.footer-links a {
  color: var(--text-secondary);
  font-weight: 500;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--accent-yellow);
  text-decoration: none;
}

.footer-social {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.footer-social span {
  color: var(--accent-yellow);
  font-weight: 600;
  font-size: 0.85rem;
  margin-right: 0.5rem;
  letter-spacing: 0.03em;
}

.footer-social a {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.footer-social a:hover {
  color: var(--accent-yellow);
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  text-align: center;
  opacity: 0.7;
}

.footer-brand {
  font-weight: 800;
  letter-spacing: -0.5px;
  font-style: italic;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-yellow));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-dev-tools {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.footer-dev-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  opacity: 0.7;
}

.footer-dev-tools a {
  font-size: 0.78rem;
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 0.2rem 0.7rem;
  transition: border-color var(--transition-fast), color var(--transition-fast);
}

.footer-dev-tools a:hover {
  border-color: var(--accent-yellow);
  color: var(--accent-yellow);
  text-decoration: none;
}

/* Helpers */
.text-accent {
  color: var(--accent-yellow);
}

.mt-4 {
  margin-top: 2rem;
}

.hero {
  text-align: center;
  padding: 2rem 1.5rem;
  background: radial-gradient(circle at top right, rgba(26, 95, 168, 0.07), transparent),
    radial-gradient(circle at bottom left, rgba(201, 146, 26, 0.07), transparent);
  border-radius: var(--radius-lg);
  margin-bottom: 1.5rem;
  border: 1px solid var(--border-color);
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.hero-tagline {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin: 0 0 2rem;
}

/* Priorities block inside hero */
.priorities-block {
  border-top: 1px solid var(--border-color);
  padding-top: 1.75rem;
}

.priorities-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-yellow);
  margin: 0 0 1.25rem;
  -webkit-text-fill-color: var(--accent-yellow);
}

.priorities-grid {
  display: flex;
  justify-content: center;
  gap: 2.5rem;
  flex-wrap: wrap;
}

.priority-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  max-width: 160px;
}

.priority-img {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: border-color var(--transition-fast), transform var(--transition-fast);
}

.priority-item:hover .priority-img {
  border-color: var(--accent-yellow);
  transform: scale(1.06);
}

.priority-item p {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.45;
  font-weight: 500;
}

@media (max-width: 576px) {
  .priorities-grid {
    gap: 1.5rem;
  }
  .priority-item {
    max-width: 130px;
  }
  .priority-img {
    width: 72px;
    height: 72px;
  }
}

/* Home — Nos Priorités */
.home-priorities {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  margin-bottom: 1.5rem;
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--accent-yellow);
  box-shadow: var(--shadow-sm);
}

.home-priorities h2 {
  color: var(--accent-blue);
  font-size: 1.3rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 1.25rem;
  -webkit-text-fill-color: var(--accent-blue);
}

.home-priorities .page-body {
  color: var(--text-primary);
  font-size: 0.95rem;
  line-height: 1.8;
}

.home-priorities .page-body a { color: var(--accent-yellow); font-weight: 600; }
.home-priorities .page-body a:hover { color: var(--accent-blue); text-decoration: none; }

/* Home — À propos */
.home-about {
  background: #eef3fb;
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  margin-bottom: 2rem;
  border: 1px solid rgba(26, 95, 168, 0.12);
  border-top: 4px solid var(--accent-blue);
}

.home-about h2 {
  color: var(--accent-blue);
  font-size: 1.3rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 1.25rem;
  -webkit-text-fill-color: var(--accent-blue);
}

.about-body-wrap {
  position: relative;
  max-height: 88px;
  overflow: hidden;
  transition: max-height 0.45s ease;
}

.about-body-wrap.expanded {
  max-height: 2000px;
}

.about-fade {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 52px;
  background: linear-gradient(to bottom, transparent, #eef3fb);
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.about-body-wrap.expanded .about-fade {
  opacity: 0;
}

.home-about .page-body {
  color: var(--text-primary);
  font-size: 0.95rem;
  line-height: 1.8;
}

.home-about .page-body a { color: var(--accent-blue); font-weight: 600; }
.home-about .page-body a:hover { color: var(--accent-yellow); text-decoration: none; }

.btn-expand {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.75rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent-blue);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: color var(--transition-fast);
}

.btn-expand:hover {
  color: var(--accent-yellow);
}

.btn-expand svg {
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.btn-expand.expanded svg {
  transform: rotate(180deg);
}

@media (max-width: 768px) {
  .home-priorities, .home-about { padding: 1.5rem; }
}

/* RSS & API Section */
.dev-tools {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.dev-tools li a {
  display: block;
  padding: 0.5rem 1rem;
  background-color: var(--bg-color);
  border-radius: 20px;
  font-size: 0.85rem;
  border: 1px solid var(--border-color);
  transition: border-color var(--transition-fast), color var(--transition-fast);
}

.dev-tools li a:hover {
  border-color: var(--accent-yellow);
  color: var(--accent-yellow);
  text-decoration: none;
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.35rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}

.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 0.6rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.page-btn:hover {
  border-color: var(--accent-yellow);
  color: var(--accent-yellow);
  text-decoration: none;
}

.page-btn--active {
  background: var(--accent-yellow);
  border-color: var(--accent-yellow);
  color: #fff;
  font-weight: 700;
  pointer-events: none;
}

.page-btn--disabled {
  opacity: 0.35;
  pointer-events: none;
  cursor: default;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.card {
  animation: fadeIn 0.4s ease-out forwards;
}

.card:nth-child(n) {
  animation-delay: calc(var(--i, 1) * 0.05s);
}

/* RTL Support */
[dir="rtl"] {
  text-align: right;
}

[dir="rtl"] .nav-links {
  flex-direction: row-reverse;
}

[dir="rtl"] .dropdown-content {
  left: auto;
  right: 0;
}

[dir="rtl"] .sidebar-section h3 {
  flex-direction: row-reverse;
}

[dir="rtl"] .mini-event h4,
[dir="rtl"] .mini-event p {
  text-align: right;
}

[dir="rtl"] .btn svg {
  margin-left: 0;
  margin-right: 0.5rem;
}

/* Category / List Page Header */
.list-header {
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.list-header h2 {
  font-size: 1.6rem;
  font-weight: 800;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-yellow));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 0;
  letter-spacing: -0.02em;
}

/* RTL: flip sidebar label border */
[dir="rtl"] .sidebar-section h3 {
  padding-left: 0;
  padding-right: 0.75rem;
  border-left: none;
  border-right: 3px solid var(--accent-yellow);
}

/* Messages / Alerts */
.alert {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
  font-size: 0.9rem;
  border: 1px solid var(--border-color);
  background-color: var(--bg-card);
  color: var(--text-primary);
}

.alert-success {
  border-color: var(--success);
  color: var(--success);
  background-color: rgba(52, 211, 153, 0.08);
}

.alert-error,
.alert-warning {
  border-color: var(--accent-yellow);
  color: var(--accent-yellow);
  background-color: rgba(201, 146, 26, 0.08);
}

/* ──────────────────────────────────────────
   Agenda — Detail Page
────────────────────────────────────────── */
.event-detail {
  max-width: 820px;
}

.event-back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  transition: color var(--transition-fast);
}

.event-back:hover {
  color: var(--accent-yellow);
  text-decoration: none;
}

.event-header {
  margin-bottom: 2rem;
}

.event-dates {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.event-date-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(79, 163, 232, 0.12);
  border: 1px solid rgba(79, 163, 232, 0.3);
  color: var(--accent-blue);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: 20px;
}

.event-date-badge svg {
  color: var(--accent-yellow);
}

.event-date-end {
  background: rgba(201, 146, 26, 0.1);
  border-color: rgba(201, 146, 26, 0.3);
  color: var(--accent-yellow);
}

.event-date-separator {
  color: var(--text-secondary);
  font-size: 1rem;
}

.event-title {
  font-size: 2.2rem;
  font-weight: 800;
  line-height: 1.2;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-yellow));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.event-location {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.event-location svg {
  color: var(--accent-yellow);
  flex-shrink: 0;
}

.event-body {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-left: 3px solid var(--accent-yellow);
  border-radius: var(--radius-lg);
  padding: 2rem;
  color: var(--text-primary);
  line-height: 1.8;
  font-size: 1rem;
  margin-bottom: 2rem;
}

.event-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.2rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  background: transparent;
  border: 1px solid var(--accent-blue);
  color: var(--accent-blue);
}

.btn-outline:hover {
  background: rgba(79, 163, 232, 0.12);
  color: var(--accent-blue);
  text-decoration: none;
}

/* ──────────────────────────────────────────
   Sidebar Mini-Event Link
────────────────────────────────────────── */
.mini-event-link {
  display: block;
  text-decoration: none;
  color: inherit;
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
  margin: -0.25rem;
  padding: 0.25rem;
}

.mini-event-link:hover {
  background: rgba(201, 146, 26, 0.07);
  text-decoration: none;
}

.mini-event-link:hover .mini-event h4 {
  color: var(--accent-yellow);
}

/* Inline location in list cards */
.event-location-inline {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin: 0.5rem 0 0;
}

.event-location-inline svg {
  color: var(--accent-yellow);
  flex-shrink: 0;
}
/* Tags / badges */
.tag {
  display: inline-block;
  background: var(--accent-blue);
  color: white;
  border-radius: 4px;
  padding: 0.2rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.03em;
}

/* Card footer meta (projets) */
.card-footer-meta {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin-top: 0.75rem;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.card-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.75rem;
}

/* Org chip (projet detail) */
.org-chip {
  display: inline-flex;
  align-items: center;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 24px;
  padding: 0.35rem 0.9rem;
  font-size: 0.88rem;
  text-decoration: none;
  color: var(--text-primary);
  transition: background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
}

.org-chip:hover {
  background: var(--accent-blue);
  color: white;
  border-color: var(--accent-blue);
}
