/* CDH Website — Modern Professional Redesign */

:root {
  --navy:      #0d2d4e;
  --blue:      #1a4980;
  --teal:      #0891b2;
  --teal-dark: #0e7490;
  --white:     #ffffff;
  --gray-50:   #f8fafc;
  --gray-100:  #f1f5f9;
  --gray-200:  #e2e8f0;
  --gray-400:  #94a3b8;
  --gray-600:  #475569;
  --gray-900:  #0f172a;
  --success:   #16a34a;
  --error:     #dc2626;
  --radius:    8px;
  --radius-lg: 14px;
  --shadow:    0 2px 8px rgba(13,45,78,0.10);
  --shadow-md: 0 6px 20px rgba(13,45,78,0.13);
  --shadow-lg: 0 12px 40px rgba(13,45,78,0.18);
  --ease:      0.25s cubic-bezier(0.4,0,0.2,1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', Arial, sans-serif;
  color: var(--gray-900);
  background: var(--white);
  line-height: 1.7;
}

/* ── HEADER ─────────────────────────────────── */

.site-header {
  background: var(--navy);
  color: #fff;
  padding: 0 1.5rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 16px rgba(0,0,0,0.18);
}

.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 0;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.brand img {
  display: block;
  border-radius: 50%;
  background: #fff;
  padding: 3px;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.2);
}

.brand-text { display: flex; flex-direction: column; }

.brand-title {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #fff;
}

.brand-sub {
  font-size: 0.68rem;
  opacity: 0.7;
  letter-spacing: 0.01em;
}

/* Nav */

.main-nav {
  display: flex;
  align-items: center;
}

.main-nav ul {
  list-style: none;
  display: flex;
  gap: 0.15rem;
}

.main-nav a {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  padding: 0.45rem 0.7rem;
  border-radius: 6px;
  transition: background var(--ease), color var(--ease);
  white-space: nowrap;
}

.main-nav a:hover {
  background: rgba(255,255,255,0.1);
  color: #fff;
}

/* Lang switcher */

.lang-switcher {
  display: flex;
  gap: 0.25rem;
  margin-left: 1.25rem;
  border-left: 1px solid rgba(255,255,255,0.15);
  padding-left: 1.25rem;
}

.lang-btn {
  background: transparent;
  border: 1.5px solid rgba(255,255,255,0.2);
  padding: 0.25rem 0.35rem;
  border-radius: 5px;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  transition: all var(--ease);
  opacity: 0.7;
}

.lang-btn:hover { border-color: rgba(255,255,255,0.6); opacity: 1; transform: scale(1.1); }
.lang-btn.active { border-color: #fff; opacity: 1; background: rgba(255,255,255,0.15); }

/* Hamburger */

.hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
  flex-direction: column;
  gap: 5px;
  margin-left: 0.75rem;
  flex-shrink: 0;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: all var(--ease);
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── HERO ────────────────────────────────────── */

.hero {
  background: linear-gradient(135deg, #0d2d4e 0%, #1a4980 55%, #0891b2 100%);
  color: #fff;
  padding: 6rem 1.5rem 5.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.035'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.hero-inner {
  position: relative;
  max-width: 780px;
  margin: 0 auto;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
  line-height: 1.2;
}

.hero-line {
  display: block;
  width: 56px;
  height: 4px;
  background: var(--teal);
  border-radius: 2px;
  margin: 0 auto 1.5rem;
}

.hero p {
  font-size: 1.1rem;
  color: rgba(255,255,255,0.88);
  max-width: 580px;
  margin: 0 auto 2.25rem;
  line-height: 1.8;
}

/* ── BUTTON ──────────────────────────────────── */

.btn {
  display: inline-block;
  background: var(--teal);
  color: #fff;
  padding: 0.75rem 1.9rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  font-family: 'Inter', Arial, sans-serif;
  transition: background var(--ease), transform var(--ease), box-shadow var(--ease);
  box-shadow: 0 4px 14px rgba(8,145,178,0.4);
  letter-spacing: 0.02em;
}

.btn:hover {
  background: var(--teal-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(8,145,178,0.5);
}

/* ── SECTIONS ─────────────────────────────────── */

.content-section { padding: 5rem 1.5rem; }

.section-inner {
  max-width: 1280px;
  margin: 0 auto;
}

.section-label {
  display: inline-block;
  background: #e0f2fe;
  color: var(--teal-dark);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.28rem 0.8rem;
  border-radius: 20px;
  margin-bottom: 0.75rem;
}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--gray-600);
  max-width: 660px;
  margin-bottom: 3rem;
  line-height: 1.8;
}

/* ── ABOUT ────────────────────────────────────── */

.about { background: var(--white); }

.about-text p {
  font-size: 1.05rem;
  color: var(--gray-600);
  max-width: 800px;
  margin-bottom: 1rem;
  line-height: 1.85;
}

.about-highlight {
  background: linear-gradient(135deg, #e0f2fe, #f0fdf4);
  border-left: 4px solid var(--teal);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.2rem 1.5rem;
  margin: 1.5rem 0;
  font-size: 1.05rem;
  color: var(--navy);
  max-width: 800px;
}

.engagement-heading {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy);
  margin: 2.5rem 0 1rem;
}

.engagement-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  max-width: 800px;
}

.engagement-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 1.02rem;
  color: var(--gray-600);
  padding: 0.75rem 1rem;
  background: var(--gray-50);
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
}

.engagement-list li::before {
  content: "→";
  color: var(--teal);
  font-weight: 700;
  flex-shrink: 0;
}

/* ── ÉQUIPE ───────────────────────────────────── */

.equipe { background: var(--gray-50); }

.equipe-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: center;
}

.equipe-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 2rem 1.5rem 1.5rem;
  text-align: center;
  width: 185px;
  transition: box-shadow var(--ease), transform var(--ease), border-color var(--ease);
  box-shadow: var(--shadow);
}

.equipe-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-5px);
  border-color: var(--teal);
}

.equipe-avatar {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--navy), var(--blue));
  color: #fff;
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  letter-spacing: 0.05em;
}

.equipe-photo {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  display: block;
  margin: 0 auto 1rem;
  border: 3px solid var(--gray-200);
  box-shadow: var(--shadow);
  transition: border-color var(--ease);
}

.equipe-card:hover .equipe-photo { border-color: var(--teal); }

.equipe-card h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.35rem;
}

.equipe-card p {
  font-size: 0.78rem;
  color: var(--teal-dark);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

/* ── PROGRAMMES ───────────────────────────────── */

.programmes { background: var(--white); }

.programmes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.prog-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 1.75rem 1.5rem;
  transition: box-shadow var(--ease), transform var(--ease), border-color var(--ease);
  box-shadow: var(--shadow);
}

.prog-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  border-color: var(--teal);
}

.prog-icon {
  font-size: 2rem;
  margin-bottom: 0.75rem;
  display: block;
}

.prog-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.5rem;
}

.prog-card p {
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.65;
}

/* ── CONTACT ──────────────────────────────────── */

.contact { background: var(--gray-50); }

.contact-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  align-items: start;
}

.contact-info {
  background: var(--navy);
  color: #fff;
  padding: 2rem 1.75rem;
  border-radius: var(--radius-lg);
  position: sticky;
  top: 90px;
}

.contact-info h3 {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--teal);
  margin-bottom: 1.5rem;
}

.contact-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.contact-list li {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.contact-list strong {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal);
  font-weight: 600;
}

.contact-list span,
.contact-list a {
  font-size: 0.95rem;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  line-height: 1.5;
}

.contact-list a:hover { color: #fff; text-decoration: underline; }

/* ── FORMULAIRES ──────────────────────────────── */

#form-contact,
#form-benevole {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 720px;
}

.form-row { display: flex; gap: 1rem; }
.form-row .form-group { flex: 1; }

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.form-group label {
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--gray-900);
  letter-spacing: 0.01em;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 0.65rem 0.9rem;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-family: 'Inter', Arial, sans-serif;
  color: var(--gray-900);
  background: var(--white);
  transition: border-color var(--ease), box-shadow var(--ease);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(8,145,178,0.12);
}

.form-group textarea { resize: vertical; }

.checkbox-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem 1.5rem;
}

.checkbox-group label {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--gray-600);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--teal);
  flex-shrink: 0;
}

#form-status,
#contact-status {
  font-size: 0.9rem;
  margin-top: 0.25rem;
  padding: 0.65rem 1rem;
  border-radius: var(--radius);
}

#form-status:empty,
#contact-status:empty { display: none; }

.status-success { background: #f0fdf4; color: var(--success); border: 1px solid #bbf7d0; }
.status-error   { background: #fef2f2; color: var(--error);   border: 1px solid #fecaca; }

/* ── BÉNÉVOLES ────────────────────────────────── */

.benevoles { background: var(--white); }

/* ── BACK TO TOP ──────────────────────────────── */

#back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 46px;
  height: 46px;
  background: var(--teal);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 1.2rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity var(--ease), transform var(--ease), background var(--ease);
  z-index: 99;
}

#back-to-top.visible { opacity: 1; transform: translateY(0); }
#back-to-top:hover   { background: var(--teal-dark); }

/* ── FOOTER ───────────────────────────────────── */

.site-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.55);
  font-size: 0.85rem;
  font-family: 'Inter', Arial, sans-serif;
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 3rem 1.5rem 2rem;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2.5rem;
  flex-wrap: wrap;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-shrink: 0;
}

.footer-brand img {
  border-radius: 50%;
  background: #fff;
  padding: 3px;
  flex-shrink: 0;
}

.footer-brand > div {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.footer-brand-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.06em;
}

.footer-brand-sub {
  font-size: 0.68rem;
  color: rgba(255,255,255,0.45);
  max-width: 220px;
  line-height: 1.4;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-links a {
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color var(--ease);
}

.footer-links a:hover { color: #fff; }

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

.social-link {
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.08);
  border: 1.5px solid rgba(255,255,255,0.15);
  border-radius: 50%;
  color: rgba(255,255,255,0.75);
  transition: background var(--ease), border-color var(--ease), color var(--ease), transform var(--ease);
  flex-shrink: 0;
}

.social-link svg {
  width: 17px;
  height: 17px;
}

.social-link:hover {
  background: var(--teal);
  border-color: var(--teal);
  color: #fff;
  transform: translateY(-2px);
}

.footer-copy {
  text-align: center;
  padding: 1.25rem 1.5rem;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.35);
}

/* ── ANIMATIONS ───────────────────────────────── */

.fade-in {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── RESPONSIVE ───────────────────────────────── */

@media (max-width: 960px) {
  .contact-layout { grid-template-columns: 1fr; }
  .contact-info   { position: static; }
}

@media (max-width: 1024px) {
  .hamburger { display: flex; }

  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--navy);
    flex-direction: column;
    align-items: stretch;
    padding: 1rem 1.5rem 1.5rem;
    box-shadow: 0 8px 24px rgba(0,0,0,0.22);
    display: none;
    border-top: 1px solid rgba(255,255,255,0.08);
  }

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

  .main-nav ul {
    flex-direction: column;
    gap: 0;
  }

  .main-nav a {
    display: block;
    padding: 0.75rem 0.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
  }

  .lang-switcher {
    margin-left: 0;
    padding-left: 0;
    border-left: none;
  }
}

@media (max-width: 768px) {
  .content-section { padding: 3.5rem 1.25rem; }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 2rem;
    padding: 2.5rem 1.25rem 1.5rem;
  }
}

@media (max-width: 700px) {
  .programmes-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
  .programmes-grid { grid-template-columns: 1fr; }
  .checkbox-group  { grid-template-columns: 1fr; }
  .form-row        { flex-direction: column; }
  .equipe-card     { width: 155px; }
}

/* ── RTL (Arabe) ──────────────────────────────── */

[dir="rtl"] body {
  font-family: 'Cairo', Arial, sans-serif;
  font-size: 1.05rem;
}

[dir="rtl"] h1,
[dir="rtl"] h2,
[dir="rtl"] h3 {
  font-family: 'Cairo', Arial, sans-serif;
  font-weight: 700;
}

[dir="rtl"] .form-group label,
[dir="rtl"] .main-nav a,
[dir="rtl"] .btn,
[dir="rtl"] p,
[dir="rtl"] li {
  font-family: 'Cairo', Arial, sans-serif;
}

[dir="rtl"] .about-highlight {
  border-left: none;
  border-right: 4px solid var(--teal);
  border-radius: var(--radius) 0 0 var(--radius);
}

[dir="rtl"] .engagement-list li::before { content: "←"; }

[dir="rtl"] .lang-switcher {
  margin-left: 0;
  margin-right: 1.25rem;
  border-left: none;
  border-right: 1px solid rgba(255,255,255,0.15);
  padding-left: 0;
  padding-right: 1.25rem;
}

[dir="rtl"] .footer-brand-sub { max-width: 240px; }
[dir="rtl"] .footer-inner { direction: rtl; }

/* ── NOUVELLES ────────────────────────────────── */

.nouvelles { background: var(--white); }

.nouvelles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.news-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition: box-shadow var(--ease), transform var(--ease), border-color var(--ease);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.news-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  border-color: var(--teal);
}

.news-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.news-cat {
  background: #e0f2fe;
  color: var(--teal-dark);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
}

.news-card time {
  font-size: 0.82rem;
  color: var(--gray-400);
}

.news-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.4;
}

.news-card p {
  font-size: 0.9rem;
  color: var(--gray-600);
  line-height: 1.65;
  flex: 1;
}

/* ── ARCHIVES ─────────────────────────────────── */

.archives { background: var(--gray-50); }

.archives-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.archive-item {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  box-shadow: var(--shadow);
  transition: box-shadow var(--ease), border-color var(--ease);
}

.archive-item:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--teal);
}

.archive-type {
  background: var(--navy);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.3rem 0.65rem;
  border-radius: 4px;
  white-space: nowrap;
  flex-shrink: 0;
}

.archive-date {
  font-size: 0.82rem;
  color: var(--gray-400);
  white-space: nowrap;
  flex-shrink: 0;
}

.archive-info { flex: 1; min-width: 0; }

.archive-info h3 {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.2rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.archive-info p {
  font-size: 0.85rem;
  color: var(--gray-600);
}

.archive-download {
  background: var(--teal);
  color: #fff;
  text-decoration: none;
  padding: 0.45rem 1rem;
  border-radius: var(--radius);
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background var(--ease);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.archive-download:hover { background: var(--teal-dark); }

/* ── GALERIE ──────────────────────────────────── */

.galerie { background: var(--white); }

.galerie-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.galerie-tab {
  background: transparent;
  border: 1.5px solid var(--gray-200);
  color: var(--gray-600);
  padding: 0.5rem 1.25rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'Inter', Arial, sans-serif;
  transition: all var(--ease);
}

.galerie-tab.active,
.galerie-tab:hover {
  background: var(--teal);
  border-color: var(--teal);
  color: #fff;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}

.photo-grid img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  cursor: zoom-in;
  transition: transform var(--ease), box-shadow var(--ease);
}

.photo-grid img:hover {
  transform: scale(1.04);
  box-shadow: var(--shadow-md);
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.video-embed {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16/9;
  background: #000;
}

.video-embed iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.video-placeholder {
  background: var(--gray-100);
  border: 2px dashed var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 3rem 1rem;
  text-align: center;
  color: var(--gray-400);
  font-size: 0.95rem;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.93);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.lightbox.open { opacity: 1; pointer-events: all; }

#lightbox-img {
  max-width: 88vw;
  max-height: 86vh;
  object-fit: contain;
  border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.lightbox-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: rgba(255,255,255,0.12);
  border: none;
  color: #fff;
  font-size: 1.3rem;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--ease);
  z-index: 1001;
}

.lightbox-close:hover { background: rgba(255,255,255,0.25); }

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.1);
  border: none;
  color: #fff;
  font-size: 2rem;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--ease);
  z-index: 1001;
}

.lightbox-prev { left: 1.25rem; }
.lightbox-next { right: 1.25rem; }
.lightbox-prev:hover,
.lightbox-next:hover { background: rgba(255,255,255,0.22); }

/* Empty state & loading */
.empty-state, .loading-text {
  text-align: center;
  color: var(--gray-400);
  font-size: 1rem;
  padding: 3rem 1rem;
  grid-column: 1 / -1;
}

@media (max-width: 900px) {
  .nouvelles-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nouvelles-grid  { grid-template-columns: 1fr; }
  .photo-grid      { grid-template-columns: repeat(3, 1fr); }
  .video-grid      { grid-template-columns: 1fr 1fr; }
  .archive-item    { flex-wrap: wrap; }
  .archive-info h3 { white-space: normal; }
}

@media (max-width: 480px) {
  .photo-grid { grid-template-columns: repeat(2, 1fr); }
  .video-grid { grid-template-columns: 1fr; }
}

/* ── COMMUNIQUÉS ──────────────────────────────── */
.communiques { background: var(--gray-50); }

/* ── REVUE DE PRESSE ──────────────────────────── */
.revue-presse { background: var(--white); }

.media-card-link {
  display: inline-block;
  margin-top: auto;
  padding: 0.42rem 1rem;
  background: var(--teal);
  color: #fff;
  border-radius: var(--radius);
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  transition: background var(--ease);
  align-self: flex-start;
}
.media-card-link:hover { background: var(--teal-dark); }
