/* ===== RESET & BASE ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --or: #b4922e;
  --or-clair: #d4af37;
  --or-pale: #f3ead4;
  --or-fonce: #8a7020;
  --blanc: #ffffff;
  --vert: #179644;

  --monza: #d01128;
  --flamingo: #b00e22;
  --flamingo-clair: #e8293f;
  --bleu-fonce: #3d1218;
  --bleu-mid: #b00e22;
  --bleu-clair: #f08090;
  --gris-clair: #fdf4f5;
  --gris-texte: #4a3035;
  --texte: #200a0e;
  --border: #f0cdd2;
  --fond-sombre: #1a0508;
  --texte-sur-sombre: #fce8eb;
  --texte-sur-sombre-muted: #ffffff;
  --trio-a-rgb: 208, 17, 40;
  --trio-b-rgb: 176, 14, 34;
  --hero-stop-1: #3d1018;
  --hero-stop-2: #5c1a24;
  --hero-stop-3: #7a1e2c;
  --hero-stop-4: #901530;
  --bandeau-edge: #2a0810;
  --bandeau-mid: #48101e;
  --transp-grad-top: #300a14;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Segoe UI", Arial, sans-serif;
  color: var(--texte);
  background: var(--blanc);
}

/* ===== BANDEAU MAQUETTE ===== */
.mockup-banner {
  background: linear-gradient(
    90deg,
    var(--bandeau-edge) 0%,
    var(--bandeau-mid) 50%,
    var(--bandeau-edge) 100%
  );
  color: var(--texte-sur-sombre);
  text-align: center;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;
  position: sticky;
  top: 0;
  z-index: 9999;
  border-bottom: 2px solid rgba(212, 175, 55, 0.45);
}

.mockup-banner span {
  background: linear-gradient(180deg, var(--or-clair), var(--or));
  color: #1f1810;
  border-radius: 4px;
  padding: 2px 8px;
  margin-left: 8px;
  font-size: 11px;
  font-weight: 700;
}

/* ===== TOPBAR ===== */
.topbar {
  background: var(--fond-sombre);
  color: var(--texte-sur-sombre);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 40px;
  font-size: 12px;
  /* FIX : sticky juste sous le bandeau maquette */
  position: sticky;
  top: 0;
  z-index: 998;
}

/* Quand le bandeau maquette est présent, la topbar se décale */
.mockup-banner ~ .topbar {
  top: 34px;
  /* hauteur du bandeau */
}

.topbar a {
  color: var(--texte-sur-sombre);
  text-decoration: none;
  margin-left: 16px;
}

.topbar a:hover {
  color: var(--or-clair);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
}

/* ===== PANNEAU THÈME ===== */
.theme-switcher {
  position: fixed;
  top: 50%;
  right: 0;
  transform: translateY(-50%);
  z-index: 9980;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  width: min(212px, calc(100vw - 16px));
  padding: 14px 14px 14px 16px;
  background: linear-gradient(
    165deg,
    color-mix(in srgb, var(--fond-sombre) 92%, #000) 0%,
    var(--fond-sombre) 100%
  );
  border: 1px solid rgba(212, 175, 55, 0.4);
  border-right: none;
  border-radius: 14px 0 0 14px;
  box-shadow:
    -6px 0 28px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.theme-switcher label {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--or-clair);
  text-align: center;
  opacity: 0.95;
}

.theme-switcher-divider {
  border: none;
  border-top: 1px solid rgba(212, 175, 55, 0.28);
  margin: 6px 0 2px;
}

.theme-select {
  font: inherit;
  font-size: 11px;
  font-weight: 600;
  width: 100%;
  padding: 8px 26px 8px 10px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background-color: rgba(0, 0, 0, 0.28);
  color: var(--texte-sur-sombre);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23d4af37' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

.theme-select:focus {
  outline: 2px solid rgba(212, 175, 55, 0.55);
  outline-offset: 2px;
}

.theme-select option {
  background: var(--fond-sombre);
  color: var(--texte-sur-sombre);
}

.lang-btn {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: var(--texte-sur-sombre);
  padding: 2px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
}

.lang-btn.active {
  background: var(--vert);
  border-color: white;
  color: #ffffff;
}

/* ===== NAVBAR ===== */
nav {
  background: var(--blanc);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  position: sticky;
  /* FIX : topbar (34px) + bandeau (34px) = 68px quand les deux sont présents */
  top: 68px;
  z-index: 999;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

/* Sans bandeau maquette, la nav se place juste sous la topbar */
body:not(:has(.mockup-banner)) nav {
  top: 32px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  text-decoration: none;
}

/* ===== FOOTER LOGO CERCLE ===== */
.footer-logo-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.footer-logo-circle img {
  width: 34px;
  /* 34/44 = légère marge intérieure pour ne pas coller au bord */
  height: 34px;
  object-fit: contain;
  display: block;
}

.logo-text {
  line-height: 1.2;
}

.logo-text strong {
  display: block;
  font-size: 15px;
  color: var(--bleu-fonce);
  font-weight: 700;
}

.logo-text small {
  font-size: 11px;
  color: var(--gris-texte);
  letter-spacing: 0.5px;
}

.nav-logo-img {
  width: 100%;
  object-fit: contain;
  flex-shrink: 0;
}

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

.nav-links a {
  display: block;
  padding: 20px 16px 22px;
  text-decoration: none;
  color: var(--texte);
  font-size: 14px;
  font-weight: 500;
  position: relative;
  transition: color 0.2s;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 10px;
  width: 48px;
  height: 7px;
  transform: translateX(-50%) scaleX(0.35);
  transform-origin: center;
  opacity: 0;
  transition:
    opacity 0.2s,
    transform 0.2s ease;
  background: linear-gradient(
    90deg,
    var(--or-fonce),
    var(--or-clair) 45%,
    var(--or-pale)
  );
  clip-path: polygon(0 0, 100% 0, 78% 100%, 0 100%);
  box-shadow: 0 2px 8px rgba(212, 175, 55, 0.22);
  pointer-events: none;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--bleu-mid);
}

.nav-links a:hover::after,
.nav-links a.active::after,
.nav-links a:focus-visible::after {
  opacity: 1;
  transform: translateX(-50%) scaleX(1);
}

.nav-links a:focus-visible {
  outline: 2px solid var(--or-clair);
  outline-offset: 2px;
}

.nav-links a:focus:not(:focus-visible) {
  outline: none;
}

.nav-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-search input {
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 7px 14px;
  font-size: 13px;
  width: 180px;
  outline: none;
  transition: border 0.2s;
}

.nav-search input:focus {
  border-color: var(--bleu-clair);
}

.btn-search {
  background: var(--bleu-mid);
  color: #fff;
  border: none;
  border-radius: 20px;
  padding: 7px 16px;
  font-size: 13px;
  cursor: pointer;
}

.btn-espace {
  background: var(--vert);
  color: #ffffff;
  border: 1px solid white;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 13px;
  cursor: pointer;
  font-weight: 600;
  margin-left: 8px;
  white-space: nowrap;
}

/* ===== HAMBURGER — caché par défaut, visible sur mobile ===== */
.nav-hamburger {
  display: none;
  /* FIX : masqué sur desktop */
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  font-size: 20px;
  margin-left: auto;
  flex-shrink: 0;
}

/* ===== HERO ===== */
.hero {
  background:
    linear-gradient(160deg, rgba(var(--trio-a-rgb), 0.14) 0%, transparent 42%),
    linear-gradient(
      135deg,
      var(--hero-stop-1) 0%,
      var(--hero-stop-2) 38%,
      var(--hero-stop-3) 72%,
      var(--hero-stop-4) 100%
    );
  position: relative;
  overflow: hidden;
  min-height: 460px;
  display: flex;
  align-items: center;
}

.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='none' fill-rule='evenodd'%3E%3Cg fill='%23d4af37' 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/g%3E%3C/svg%3E");
}

html[data-hero="photo"] .hero {
  background-color: var(--fond-sombre);
  background-image:
    linear-gradient(
      100deg,
      rgba(12, 10, 11, 0.88) 0%,
      rgba(12, 10, 11, 0.5) 38%,
      rgba(12, 10, 11, 0.22) 58%,
      rgba(12, 10, 11, 0.45) 100%
    ),
    url("hero-bg.png");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  min-height: min(520px, 58vh);
}

html[data-hero="photo"] .hero::before {
  display: none;
}

html[data-hero="photo"] .hero-visual-wrap {
  display: none;
}

.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 40px;
  display: flex;
  gap: 60px;
  align-items: center;
  width: 100%;
  position: relative;
  z-index: 1;
}

.hero-content {
  flex: 1;
  color: #fff;
}

.hero-badge {
  display: inline-block;
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid rgba(212, 175, 55, 0.55);
  color: var(--or-pale);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 16px;
  text-transform: uppercase;
}

.hero-content h1 {
  font-size: 38px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
}

.hero-content h1 span {
  color: var(--or-clair);
}

.hero-content p {
  font-size: 16px;
  color: #ffffff;
  line-height: 1.7;
  max-width: 520px;
  margin-bottom: 28px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-visual-wrap.shape {
  position: relative;
  padding: 20px 26px 22px 22px;
  box-sizing: border-box;
}

.hero-visual-wrap.shape .hero-visual-card {
  position: relative;
  z-index: 1;
}

.hero-visual-wrap.shape::before,
.hero-visual-wrap.shape::after {
  content: "";
  position: absolute;
  pointer-events: none;
  z-index: 0;
  height: 11px;
  max-width: min(72%, 300px);
  background: linear-gradient(
    90deg,
    var(--or-fonce),
    var(--or-clair) 45%,
    var(--or-pale)
  );
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.35);
}

.hero-visual-wrap.shape::before {
  top: 0;
  right: 0;
  width: min(68%, 290px);
  clip-path: polygon(22% 0, 100% 0, 100% 100%, 0 100%);
}

.hero-visual-wrap.shape::after {
  bottom: 0;
  left: 0;
  width: min(68%, 290px);
  clip-path: polygon(0 0, 100% 0, 78% 100%, 0 100%);
}

.btn-primary {
  background: var(--vert);
  color: #ffffff;
  padding: 12px 24px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  transition:
    filter 0.2s,
    box-shadow 0.2s;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.btn-primary:hover {
  filter: brightness(1.06);
  box-shadow: 0 4px 14px rgba(180, 146, 46, 0.35);
}

.btn-outline {
  background: transparent;
  color: var(--or-pale);
  padding: 11px 24px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  border: 2px solid rgba(212, 175, 55, 0.55);
  transition:
    border-color 0.2s,
    color 0.2s;
}

.btn-outline:hover {
  border-color: var(--or-clair);
  color: #fff;
}

.hero-visual-wrap {
  flex-shrink: 0;
  width: min(540px, 40vw);
}

.hero-visual-card {
  border-radius: 18px;
  overflow: hidden;
  border: 2px solid rgba(212, 175, 55, 0.42);
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  background: var(--fond-sombre);
}

.hero-visual-frame {
  aspect-ratio: 5 / 3;
  position: relative;
  overflow: hidden;
}

.hero-visual-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 38%;
}

/* ===== ACCÈS RAPIDE ===== */
.acces-rapide {
  background: #179644;
  padding: 0;
}

.acces-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.acces-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 24px;
  color: var(--texte-sur-sombre);
  text-decoration: none;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  transition: background 0.2s;
  background: rgba(255, 255, 255, 0.08);
}

.acces-item:last-child {
  border-right: none;
}

.acces-item:hover {
  background: rgba(255, 255, 255, 0.14);
}

.acces-icon {
  width: 42px;
  height: 42px;
  background: linear-gradient(145deg, var(--or-clair), var(--or));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.acces-text strong {
  display: block;
  font-size: 13px;
  color: #fff;
  font-weight: 600;
}

.acces-text small {
  font-size: 11px;
  color: var(--texte-sur-sombre-muted);
}

/* ===== SECTIONS GÉNÉRALES ===== */
.section {
  padding: 70px 40px;
}

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

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 36px;
}

.section-title {
  font-size: 26px;
  font-weight: 700;
  color: var(--bleu-fonce);
}

.section-title::after {
  content: "";
  display: block;
  width: 76px;
  height: 10px;
  margin-top: 10px;
  background: linear-gradient(
    90deg,
    var(--or-fonce),
    var(--or-clair) 45%,
    var(--or-pale)
  );
  clip-path: polygon(0 0, 100% 0, 78% 100%, 0 100%);
  box-shadow: 0 2px 10px rgba(212, 175, 55, 0.28);
}

.section-subtitle {
  font-size: 14px;
  color: var(--gris-texte);
  margin-top: 6px;
}

.voir-plus {
  color: var(--bleu-mid);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

.voir-plus:hover {
  text-decoration: underline;
}

/* ===== ACTUALITÉS ===== */
.actu-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.actu-main {
  background: var(--bleu-fonce);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  height: 380px;
  width: 100%;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  box-shadow:
    inset 0 0 0 1px rgba(212, 175, 55, 0.28),
    0 12px 32px rgba(0, 0, 0, 0.12);
}

.actu-main-img {
  position: absolute;
  inset: 0;
}

.actu-main-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.actu-main-img::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(
      to top,
      rgba(12, 10, 11, 0.92) 0%,
      rgba(12, 10, 11, 0.55) 32%,
      rgba(12, 10, 11, 0.2) 55%,
      transparent 78%
    ),
    linear-gradient(160deg, rgba(var(--trio-b-rgb), 0.18) 0%, transparent 48%);
}

.actu-main-content {
  position: relative;
  z-index: 1;
  padding: 28px;
  color: #fff;
}

.actu-tag {
  display: inline-block;
  background: var(--bleu-mid);
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.actu-main-content h3 {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 8px;
}

.actu-main-content p {
  font-size: 13px;
  color: #ffffff;
}

.actu-date {
  font-size: 11px;
  color: #ffffff;
  margin-top: 12px;
  font-weight: 600;
}

.actu-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.actu-card {
  background: var(--gris-clair);
  border-radius: 10px;
  padding: 20px;
  border-left: 4px solid var(--bleu-mid);
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}

.actu-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.actu-card .actu-tag {
  background: var(--bleu-mid);
}

.actu-card h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--texte);
  margin-bottom: 6px;
  line-height: 1.4;
}

.actu-card p {
  font-size: 12px;
  color: var(--gris-texte);
  line-height: 1.5;
}

.actu-card .actu-date {
  color: var(--gris-texte);
}

/* ===== ARRÊTS / JURISPRUDENCE ===== */
.arrets-section {
  background: var(--gris-clair);
}

.search-bar {
  display: flex;
  gap: 10px;
  margin-bottom: 28px;
  background: #fff;
  border-radius: 10px;
  padding: 16px 20px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  flex-wrap: wrap;
}

.search-bar input,
.search-bar select {
  flex: 1;
  min-width: 140px;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 9px 14px;
  font-size: 13px;
  outline: none;
}

.search-bar input:focus,
.search-bar select:focus {
  border-color: var(--bleu-clair);
}

.btn-rechercher {
  background: var(--vert);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 9px 22px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.arrets-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.arret-item {
  background: #fff;
  border-radius: 10px;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 20px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.2s;
}

.arret-item:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.arret-num {
  background: var(--or-fonce);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: 6px;
  white-space: nowrap;
  text-align: center;
  min-width: 80px;
}

.arret-info {
  flex: 1;
}

.arret-info h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--texte);
  margin-bottom: 4px;
}

.arret-info p {
  font-size: 12px;
  color: var(--texte);
}

.arret-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.arret-chambre {
  background: var(--or-fonce);
  color: #fff;
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 20px;
  font-weight: 600;
  white-space: nowrap;
}

.arret-date {
  font-size: 11px;
  color: var(--gris-texte);
}

.btn-pdf {
  background: transparent;
  border: 1px solid var(--or);
  color: var(--or);
  border-radius: 6px;
  padding: 5px 12px;
  font-size: 12px;
  cursor: pointer;
  font-weight: 600;
}

/* ===== TABS ARRÊTS / AVIS ===== */
.tabs-nav {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--border);
  margin-bottom: 28px;
}

.tab-btn {
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  padding: 12px 28px;
  font-size: 14px;
  font-weight: 600;
  color: var(--gris-texte);
  cursor: pointer;
  transition:
    color 0.2s,
    border-color 0.2s;
  letter-spacing: 0.2px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.tab-btn:hover {
  color: var(--bleu-mid);
}

.tab-btn.active {
  color: var(--bleu-mid);
  border-bottom-color: var(--bleu-mid);
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

.avis-num {
  background: var(--or-fonce) !important;
}

.avis-tag {
  background: var(--or-fonce) !important;
}

/* ===== PRÉSENTATION INSTITUTION ===== */
.institution-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.institution-img {
  border-radius: 16px;
  height: 380px;
  position: relative;
  overflow: hidden;
  background: var(--fond-sombre);
  box-shadow:
    inset 0 0 0 1px rgba(212, 175, 55, 0.28),
    0 12px 32px rgba(0, 0, 0, 0.12);
}

.institution-img-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.institution-content h2 {
  font-size: 28px;
  font-weight: 700;
  color: var(--bleu-fonce);
  margin-bottom: 16px;
}

.institution-content p {
  color: var(--gris-texte);
  font-size: 15px;
  line-height: 1.8;
  margin-bottom: 20px;
}

.chiffres-cles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 24px;
}

.chiffre-item {
  background: var(--gris-clair);
  border-radius: 10px;
  padding: 16px 20px;
}

.chiffre-item .num {
  font-size: 28px;
  font-weight: 800;
  color: var(--or-fonce);
}

.chiffre-item .lbl {
  font-size: 12px;
  color: var(--gris-texte);
  margin-top: 2px;
}

/* ===== TRANSPARENCE ===== */
.transparence-section {
  background:
    linear-gradient(160deg, rgba(var(--trio-a-rgb), 0.14) 0%, transparent 42%),
    linear-gradient(
      135deg,
      var(--hero-stop-1) 0%,
      var(--hero-stop-2) 38%,
      var(--hero-stop-3) 72%,
      var(--hero-stop-4) 100%
    );
  color: #fff;
}

.transparence-section .section-title {
  color: #fff;
}

.transp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.transp-card {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 28px 24px;
  transition: background 0.2s;
}

.transp-card:hover {
  background: rgba(255, 255, 255, 0.12);
}

.transp-card h3 {
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 10px;
}

.transp-card p {
  font-size: 13px;
  color: #ffffff;
  line-height: 1.6;
  margin-bottom: 16px;
}

.btn-transp {
  background: transparent;
  border: 1px solid #ffffff;
  color: #ffffff;
  border-radius: 6px;
  padding: 7px 16px;
  font-size: 12px;
  cursor: pointer;
  font-weight: 600;
  transition:
    background 0.2s,
    color 0.2s;
}

.btn-transp:hover {
  background: var(--or);
  color: #fff;
}

/* ===== ESPACE JUSTICIABLE ===== */
.justiciable-section {
  background:
    linear-gradient(160deg, rgba(var(--trio-a-rgb), 0.14) 0%, transparent 42%),
    linear-gradient(
      135deg,
      var(--hero-stop-1) 0%,
      var(--hero-stop-2) 38%,
      var(--hero-stop-3) 72%,
      var(--hero-stop-4) 100%
    );
}

.justiciable-section .section-title,
.justiciable-section .section-subtitle {
  color: #fff;
}

.justiciable-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.just-card {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 28px 24px;
  transition: background 0.2s;
  text-decoration: none;
}

.just-card:hover {
  transform: translateY(-4px);
  background: rgba(255, 255, 255, 0.12);
}

.just-card h3 {
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 10px;
}

.just-card p {
  font-size: 13px;
  color: #ffffff;
  line-height: 1.6;
  margin-bottom: 16px;
}

/* ===== CONTACT ===== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.contact-info h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--bleu-fonce);
  margin-bottom: 20px;
}

.contact-item {
  display: flex;
  gap: 14px;
  margin-bottom: 20px;
}

.contact-item .ico {
  font-size: 22px;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-item .details strong {
  display: block;
  font-size: 13px;
  color: var(--texte);
  font-weight: 600;
}

.contact-item .details span {
  font-size: 12px;
  color: var(--gris-texte);
}

.contact-form {
  background: var(--gris-clair);
  border-radius: 12px;
  padding: 32px;
}

.contact-form h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--bleu-fonce);
  margin-bottom: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}

.form-group {
  margin-bottom: 12px;
}

.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--gris-texte);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 14px;
  font-size: 13px;
  background: #fff;
  outline: none;
  transition: border 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--bleu-clair);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.btn-envoyer {
  width: 100%;
  background: var(--vert);
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 12px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: filter 0.2s;
}

.btn-envoyer:hover {
  filter: brightness(1.05);
}

/* ===== FOOTER ===== */
footer {
  background:
    linear-gradient(160deg, rgba(var(--trio-a-rgb), 0.14) 0%, transparent 42%),
    linear-gradient(
      135deg,
      var(--hero-stop-1) 0%,
      var(--hero-stop-2) 38%,
      var(--hero-stop-3) 72%,
      var(--hero-stop-4) 100%
    );
  color: #ffffff;
  padding: 50px 40px 0;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
}

.footer-brand p {
  font-size: 13px;
  line-height: 1.7;
  margin-top: 14px;
  max-width: 280px;
}

.footer-brand .socials {
  display: flex;
  gap: 10px;
  margin-top: 18px;
}

.social-btn {
  width: 34px;
  height: 34px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.2s;
}

.social-btn:hover {
  background: var(--or);
}

.footer-col h4 {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer-col a {
  display: block;
  font-size: 12px;
  color: #ffffff;
  text-decoration: none;
  margin-bottom: 8px;
  transition: color 0.2s;
}

.footer-col a:hover {
  color: var(--or-clair);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  padding: 20px 0;
  text-align: center;
  font-size: 11px;
  color: #ffffff;
  max-width: 1200px;
  margin: 40px auto 0;
}

/* ===== ANNOTATIONS MAQUETTE ===== */
.annotation {
  position: relative;
  outline: 1px solid rgba(255, 255, 255, 0.1);
  outline-offset: 4px;
}

.annotation::after {
  content: attr(data-note);
  position: absolute;
  top: -26px;
  left: 0;
  z-index: 100;
  background: var(--fond-sombre);
  color: var(--or-pale);
  border: 1px solid rgba(212, 175, 55, 0.4);
  font-size: 10px;
  padding: 3px 8px;
  border-radius: 4px;
  white-space: nowrap;
  font-family: monospace;
  pointer-events: none;
  display: none;
}

.annotation:hover::after {
  display: block;
}

.show-annotations .annotation::after {
  display: block;
}

/* ===== RESPONSIVE ===== */

@media (max-width: 960px) {
  .hero-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 36px;
    padding: 48px 24px;
  }

  .hero-visual-wrap {
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
  }

  .hero-visual-frame {
    aspect-ratio: 21 / 9;
  }

  .hero-visual-wrap.shape {
    padding: 16px 18px 18px 16px;
  }

  .hero-visual-wrap.shape::before,
  .hero-visual-wrap.shape::after {
    height: 9px;
    max-width: min(78%, 260px);
  }

  .actu-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .actu-main {
    height: min(380px, 78vw);
    max-height: 400px;
  }
}

@media (max-width: 768px) {
  /* Topbar */
  .topbar {
    flex-direction: column;
    gap: 6px;
    padding: 8px 16px;
    text-align: center;
    font-size: 11px;
  }

  .topbar > div:first-child {
    display: none;
  }

  .topbar-right {
    justify-content: center;
  }

  /* Navbar — recolle sous topbar, plus de bandeau */
  nav {
    padding: 0 16px;
    flex-wrap: wrap;
    gap: 0;
    top: 0;
    /* topbar n'est plus sticky sur mobile */
  }

  .nav-links {
    display: none;
  }

  .nav-search {
    display: none;
  }

  .nav-logo {
    padding: 10px 0;
  }

  /* FIX hamburger : visible sur mobile */
  .nav-hamburger {
    display: flex;
  }

  /* Menu mobile ouvert */
  .nav-mobile-open .nav-links {
    display: flex;
    flex-direction: column;
    width: 100%;
    border-top: 1px solid var(--border);
    padding: 8px 0 12px;
  }

  .nav-mobile-open .nav-links a {
    padding: 12px 4px;
    border-bottom: 1px solid var(--border);
    font-size: 15px;
  }

  .nav-mobile-open .nav-links a::after {
    display: none;
  }

  .nav-mobile-open .nav-search {
    display: flex;
    width: 100%;
    padding: 10px 0 12px;
    gap: 8px;
  }

  .nav-mobile-open .nav-search input {
    width: 0;
    flex: 1;
  }

  /* Hero */
  .hero-content h1 {
    font-size: 26px;
  }

  .hero-content p {
    font-size: 14px;
  }

  .hero-inner {
    padding: 36px 16px;
  }

  /* Accès rapide 2×2 */
  .acces-inner {
    grid-template-columns: repeat(2, 1fr);
  }

  .acces-item {
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .acces-item:nth-child(odd) {
    border-right: 1px solid rgba(255, 255, 255, 0.1);
  }

  .acces-item:nth-last-child(-n + 2) {
    border-bottom: none;
  }

  /* Actualités */
  .actu-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .actu-main {
    height: min(320px, 80vw);
    max-height: 320px;
  }

  .actu-side {
    gap: 12px;
  }

  .actu-card {
    padding: 16px;
  }

  .actu-main-content h3 {
    font-size: 17px;
  }

  /* Sections */
  .section {
    padding: 48px 16px;
  }

  /* Institution & Mot du président */
  .institution-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .institution-img {
    height: min(280px, 72vw);
    order: -1;
  }

  /* Arrêts */
  .search-bar {
    flex-direction: column;
  }

  .search-bar input,
  .search-bar select {
    min-width: 100%;
  }

  .arret-item {
    flex-wrap: wrap;
    gap: 12px;
  }

  .arret-num {
    min-width: 64px;
  }

  .arret-meta {
    flex-direction: row;
    align-items: center;
    width: 100%;
    justify-content: flex-start;
    gap: 8px;
  }

  /* Transparence */
  .transp-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  /* Justiciable 2×2 */
  .justiciable-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }

  /* Contact */
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  /* Footer */
  .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: 28px;
  }

  footer {
    padding: 36px 16px 0;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }

  .footer-brand p {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .mockup-banner {
    font-size: 11px;
    padding: 6px 10px;
  }

  .hero-content h1 {
    font-size: 22px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .hero-actions .btn-primary,
  .hero-actions .btn-outline {
    text-align: center;
    width: 100%;
  }

  /* Accès rapide 1 col */
  .acces-inner {
    grid-template-columns: 1fr;
  }

  .acces-item {
    border-right: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .acces-item:last-child {
    border-bottom: none;
  }

  /* Actualités */
  .actu-main {
    height: min(260px, 75vw);
    max-height: 260px;
  }

  .actu-main-content {
    padding: 18px;
  }

  .actu-main-content h3 {
    font-size: 15px;
  }

  .actu-main-content p {
    display: none;
  }

  /* Justiciable 1 col */
  .justiciable-grid {
    grid-template-columns: 1fr;
  }

  /* Footer 1 col */
  .footer-inner {
    grid-template-columns: 1fr;
  }
}
