/* =========================================================================
   TURABO SELF — SITE DE PRÉSENTATION
   Design system repris à l'identique du site Campus Rosa Parks :
   hommage typographique aux affiches du mouvement des droits civiques
   (bleu nuit, or, brique), sur papier réglé couleur parchemin.
   ========================================================================= */

:root {
  /* --- Palette --------------------------------------------------------- */
  --ink:        #17233C; /* bleu nuit — texte, fonds sombres            */
  --ink-soft:   #29385A; /* bleu nuit clair — dégradés, survols          */
  --paper:      #F5EFE1; /* parchemin chaud — fond de page               */
  --paper-high: #FFFFFF; /* blanc — cartes                               */
  --gold:       #D9A441; /* or — accents, hover, liens actifs            */
  --gold-dark:  #B9852E;
  --brick:      #B23A2E; /* brique — appels à l'action, alertes          */
  --brick-dark: #8E2C22;
  --slate:      #4A5A72; /* gris bleuté — texte secondaire               */
  --line:       #DCD2B8; /* lignes de séparation sur papier              */
  --line-dark:  rgba(255,255,255,0.14);

  /* --- Typographie ------------------------------------------------------ */
  --font-display: "Big Shoulders Display", "Arial Narrow", sans-serif;
  --font-body: "Work Sans", "Segoe UI", sans-serif;

  /* --- Rythme ------------------------------------------------------------ */
  --radius-s: 6px;
  --radius-m: 14px;
  --radius-l: 26px;
  --shadow-card: 0 1px 0 var(--line), 0 18px 30px -22px rgba(23,35,60,0.35);
  --shadow-pop: 0 24px 48px -20px rgba(23,35,60,0.45);
  --ease: cubic-bezier(.22,.68,0,1.01);
}

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

html, body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

body {
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px);
  background-size: 100% 44px;
  background-attachment: local;
}

img, svg { max-width: 100%; display: block; }

a { color: inherit; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 0.98;
  margin: 0;
  letter-spacing: 0.2px;
}

p { line-height: 1.65; margin: 0; color: var(--slate); max-width: 62ch; }

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 28px;
}

button { font-family: var(--font-body); cursor: pointer; }

:focus-visible {
  outline: 3px solid var(--gold-dark);
  outline-offset: 3px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

/* =========================================================================
   EN-TÊTE / NAVIGATION — fixe
   ========================================================================= */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  border-bottom: 3px solid var(--gold);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 78px;
}

.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-mark { width: 46px; height: 46px; flex-shrink: 0; }
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-text .school { font-family: var(--font-display); font-size: 1.32rem; letter-spacing: 0.3px; }
.brand-text .place { font-size: 0.72rem; color: var(--gold); letter-spacing: 1.5px; margin-top: 3px; }

.main-nav { display: flex; align-items: center; gap: 4px; }
.main-nav a {
  position: relative;
  display: inline-block;
  padding: 10px 16px;
  text-decoration: none;
  font-size: 0.95rem;
  color: rgba(245,239,225,0.82);
  transition: color 0.18s var(--ease);
}
.main-nav a::after {
  content: "";
  position: absolute;
  left: 16px; right: 16px; bottom: 6px;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s var(--ease);
}
.main-nav a:hover { color: #fff; }
.main-nav a:hover::after { transform: scaleX(1); }
.main-nav a.active { color: #fff; }
.main-nav a.active::after { transform: scaleX(1); }

.header-actions { display: flex; align-items: center; gap: 10px; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: none;
  padding: 11px 20px;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.16s var(--ease), box-shadow 0.16s var(--ease), background 0.16s var(--ease);
}
.btn:active { transform: translateY(1px) scale(0.98); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: #EAB955; box-shadow: 0 10px 22px -12px rgba(217,164,65,0.7); }
.btn-brick { background: var(--brick); color: #fff; }
.btn-brick:hover { background: var(--brick-dark); box-shadow: 0 10px 22px -12px rgba(178,58,46,0.6); }
.btn-ghost { background: transparent; border: 1.5px solid rgba(245,239,225,0.35); color: var(--paper); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }
.btn-outline-ink { background: transparent; border: 1.5px solid var(--ink); color: var(--ink); }
.btn-outline-ink:hover { background: var(--ink); color: var(--paper); }
.btn-sm { padding: 7px 14px; font-size: 0.82rem; }

.menu-toggle { display: none; background: none; border: none; color: var(--paper); }

/* Sélecteur de langue — même traitement que le bouton « ghost » de l'en-tête */
.lang-switch {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  border: 1.5px solid rgba(245,239,225,0.35);
}
.lang-switch button {
  background: none;
  border: none;
  padding: 4px 11px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: rgba(245,239,225,0.82);
  transition: background 0.18s var(--ease), color 0.18s var(--ease);
}
.lang-switch button:hover { color: #fff; }
.lang-switch button[aria-pressed="true"] { background: var(--gold); color: var(--ink); }

/* =========================================================================
   PAGES — une section par catégorie, une seule visible à la fois
   ========================================================================= */

.page { display: none; animation: page-in 0.5s var(--ease); }
.page.active { display: block; }

@keyframes page-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

section.block { padding: 84px 0; }
section.block + section.block { border-top: 1px solid var(--line); }

/* --- HÉRO ------------------------------------------------------------- */

.hero {
  background: var(--ink);
  color: var(--paper);
  position: relative;
  overflow: hidden;
  padding: 108px 0 96px;
}
.hero::before {
  content: "";
  position: absolute; inset: 0;
  background-image: radial-gradient(circle at 82% 18%, rgba(217,164,65,0.18), transparent 55%);
  pointer-events: none;
}
.hero .container { position: relative; display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 56px; align-items: center; }

.hero-kicker {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--gold); font-size: 0.85rem; letter-spacing: 0.4px; margin-bottom: 18px;
  opacity: 0; animation: rise-in 0.7s var(--ease) forwards; animation-delay: 0.05s;
}
.hero-kicker svg { width: 16px; height: 16px; flex-shrink: 0; }
.hero-title { font-size: clamp(2.6rem, 5vw, 4.1rem); overflow: hidden; }
.hero-title .line { display: block; overflow: hidden; }
.hero-title .line span {
  display: block;
  transform: translateY(105%);
  animation: rise-in 0.75s var(--ease) forwards;
}
.hero-title .line:nth-child(1) span { animation-delay: 0.12s; }
.hero-title .line:nth-child(2) span { animation-delay: 0.24s; color: var(--gold); }

.hero-sub {
  margin-top: 22px; color: rgba(245,239,225,0.78); font-size: 1.08rem; max-width: 46ch;
  opacity: 0; animation: rise-in 0.7s var(--ease) forwards; animation-delay: 0.4s;
}
.hero-cta { margin-top: 34px; display: flex; gap: 14px; flex-wrap: wrap;
  opacity: 0; animation: rise-in 0.7s var(--ease) forwards; animation-delay: 0.52s;
}

@keyframes rise-in { to { opacity: 1; transform: translateY(0); } from { opacity: 0; transform: translateY(16px); } }

.hero-figure {
  opacity: 0; animation: rise-in 0.9s var(--ease) forwards; animation-delay: 0.3s;
}

/* Icône signature : trait de vol animé en boucle lente, seul mouvement
   non déclenché par l'utilisateur du site (moment orchestré unique). */
.route-path {
  stroke-dasharray: 10 9;
  animation: route-move 5.5s linear infinite;
}
@keyframes route-move { to { stroke-dashoffset: -76; } }

.hero-stats { display: grid; grid-template-columns: repeat(3,1fr); gap: 18px; margin-top: 48px;
  opacity: 0; animation: rise-in 0.7s var(--ease) forwards; animation-delay: 0.62s;
}
.hero-stats .stat { border-top: 2px solid rgba(217,164,65,0.5); padding-top: 12px; }
.hero-stats .stat b { font-family: var(--font-display); font-size: 2rem; display: block; }
.hero-stats .stat span { font-size: 0.82rem; color: rgba(245,239,225,0.65); }

/* Chiffres clés posés sur le papier (hors héro) */
.stats-paper .stat { border-top-color: var(--gold); }
.stats-paper .stat b { color: var(--ink); }
.stats-paper .stat span { color: var(--slate); }

/* --- En-têtes de section génériques ------------------------------------ */

.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 44px; flex-wrap: wrap; }
.section-head h2 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); }
.section-head p { margin-top: 10px; }

/* --- Grilles de cartes -------------------------------------------------- */

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

.card {
  background: var(--paper-high);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  padding: 28px;
  box-shadow: var(--shadow-card);
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease);
  position: relative;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-pop); }

.card-icon {
  width: 52px; height: 52px; margin-bottom: 18px;
  color: var(--brick);
  transition: transform 0.35s var(--ease);
}
.card:hover .card-icon { transform: rotate(-6deg) scale(1.08); }

.card h3 { font-size: 1.22rem; margin-bottom: 8px; }
.card p { font-size: 0.95rem; }

/* --- Valeurs / rôles ---------------------------------------------------- */

.values-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 20px; }
.value-item { text-align: left; }
.value-item svg { width: 38px; height: 38px; color: var(--brick); }
.value-item h4 { font-size: 1rem; margin: 12px 0 6px; }
.value-item p { font-size: 0.88rem; }

.split {
  display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center;
}
.timeline { border-left: 3px solid var(--gold); padding-left: 24px; display: flex; flex-direction: column; gap: 26px; }
.timeline .t-item b { font-family: var(--font-display); font-size: 1.15rem; }
.timeline .t-item p { font-size: 0.92rem; margin-top: 4px; }

/* --- CTA bandeau -------------------------------------------------------- */

.cta-band {
  background: var(--ink); color: var(--paper); border-radius: var(--radius-l);
  padding: 54px 56px; display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap;
}
.cta-band h3 { font-size: 1.9rem; max-width: 18ch; }
.cta-band p { color: rgba(245,239,225,0.72); margin-top: 8px; }

/* --- Galerie (cartes du site, capture d'écran dans un cadre papier) ------ */

.gallery { display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(6, 110px); gap: 22px; }
.shot {
  position: relative; margin: 0; overflow: hidden;
  background: var(--paper-high);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-card);
  cursor: zoom-in;
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease);
}
.shot:hover { transform: translateY(-4px); box-shadow: var(--shadow-pop); }
.s1 { grid-column: 1; grid-row: 1 / span 4; } .s4 { grid-column: 1; grid-row: 5 / span 2; }
.s2 { grid-column: 2; grid-row: 1 / span 2; } .s5 { grid-column: 2; grid-row: 3 / span 4; }
.s3 { grid-column: 3; grid-row: 1 / span 3; } .s6 { grid-column: 3; grid-row: 4 / span 3; }
.shot img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; transition: transform 0.6s var(--ease); }
.shot:hover img { transform: scale(1.05); }
.shot figcaption {
  position: absolute; left: 14px; bottom: 14px; z-index: 2;
  padding: 6px 14px; border-radius: 999px;
  background: var(--ink); color: var(--paper);
  font-size: 0.8rem; font-weight: 600;
}
.shot .ph {
  position: absolute; inset: 0; display: none;
  flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  text-align: center; padding: 20px; color: var(--slate); font-size: 0.8rem;
  background: rgba(217,164,65,0.06);
  border: 2px dashed var(--gold-dark); border-radius: var(--radius-m); margin: 10px 10px 56px;
  font-weight: 600;
}
.shot.empty .ph { display: flex; }
.shot.empty { cursor: default; }
.shot.empty img { display: none; }
.shot .ph svg { width: 30px; height: 30px; color: var(--gold-dark); }
.shot .ph code { font-size: 0.74rem; background: var(--paper); padding: 2px 8px; border-radius: var(--radius-s); border: 1px solid var(--line); color: var(--ink); }

/* --- FAQ ------------------------------------------------------------------ */

.faq { display: flex; flex-direction: column; gap: 14px; max-width: 820px; }
.faq details {
  background: var(--paper-high);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  padding: 0 26px;
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.22s var(--ease), border-color 0.22s var(--ease);
}
.faq details:hover { box-shadow: var(--shadow-pop); }
.faq details[open] { border-color: var(--gold-dark); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 0; cursor: pointer; list-style: none;
  font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; letter-spacing: 0.2px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { width: 20px; height: 20px; flex-shrink: 0; color: var(--brick); transition: transform 0.28s var(--ease); }
.faq details[open] summary svg { transform: rotate(45deg); }
.faq details p { padding-bottom: 22px; font-size: 0.95rem; }

/* --- Services / liens de sortie ------------------------------------------ */

.service-link {
  margin-top: 14px; display: inline-flex; align-items: center; gap: 6px;
  color: var(--brick); font-weight: 600; font-size: 0.9rem; text-decoration: none;
  padding-top: 10px; border-top: 1px dashed var(--line);
}
.service-link svg { width: 16px; height: 16px; transition: transform 0.2s var(--ease); }
.service-link:hover svg { transform: translate(3px,-3px); }

/* =========================================================================
   VISIONNEUSE D'IMAGES
   ========================================================================= */

.lightbox {
  position: fixed; inset: 0; z-index: 300;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  padding: 24px;
  background: rgba(23,35,60,0.88);
  backdrop-filter: blur(3px);
  opacity: 0; pointer-events: none;
  transition: opacity 0.22s var(--ease);
}
.lightbox.open { opacity: 1; pointer-events: auto; }
.lightbox img {
  max-width: min(94vw, 1100px); max-height: 78vh; width: auto;
  border-radius: var(--radius-m); box-shadow: var(--shadow-pop);
  border: 3px solid var(--gold);
  transform: scale(0.94) translateY(8px);
  transition: transform 0.24s var(--ease);
}
.lightbox.open img { transform: scale(1) translateY(0); }
.lightbox p { color: var(--paper); font-weight: 600; text-align: center; }
.lightbox-close {
  position: absolute; top: 20px; right: 22px;
  width: 42px; height: 42px; border-radius: 50%;
  background: transparent; border: 1.5px solid rgba(245,239,225,0.35); color: var(--paper);
  display: inline-flex; align-items: center; justify-content: center;
  transition: border-color 0.16s var(--ease), color 0.16s var(--ease);
}
.lightbox-close:hover { border-color: var(--gold); color: var(--gold); }

/* =========================================================================
   PIED DE PAGE
   ========================================================================= */

footer {
  background: var(--ink); color: rgba(245,239,225,0.65);
  padding: 56px 0 30px;
}
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; padding-bottom: 36px; border-bottom: 1px solid var(--line-dark); }
.footer-top .brand-text .school { color: var(--paper); }
footer h5 { font-family: var(--font-body); font-weight: 700; color: var(--paper); font-size: 0.9rem; margin: 0 0 14px; }
footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 9px; font-size: 0.88rem; }
footer ul a { text-decoration: none; color: rgba(245,239,225,0.65); transition: color 0.16s var(--ease); }
footer ul a:hover { color: var(--gold); }
.footer-bottom { display: flex; justify-content: space-between; padding-top: 22px; font-size: 0.8rem; flex-wrap: wrap; gap: 10px; }
.footer-text { margin-top: 14px; max-width: 38ch; color: rgba(251,248,241,0.62); }

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

@media (max-width: 980px) {
  .main-nav { display: none; }
  .menu-toggle { display: inline-flex; }
  .site-header.nav-open .main-nav {
    display: flex; position: absolute; top: 78px; left: 0; right: 0;
    background: var(--ink); flex-direction: column; align-items: stretch; padding: 10px 20px 20px; gap: 2px;
    border-bottom: 3px solid var(--gold);
  }
  .gallery { grid-template-rows: repeat(6, 84px); gap: 14px; }
}

@media (max-width: 920px) {
  .hero .container { grid-template-columns: 1fr; }
  .hero-figure { order: -1; max-width: 220px; }
  .grid-3, .grid-2, .values-row, .footer-top { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; gap: 30px; }
}

@media (max-width: 720px) {
  .header-actions .btn { display: none; }
  .grid-3, .grid-2, .values-row, .footer-top { grid-template-columns: 1fr; }
  .cta-band { padding: 36px 26px; flex-direction: column; align-items: flex-start; }
  section.block { padding: 56px 0; }
  .hero-stats { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, 1fr); grid-template-rows: none; grid-auto-rows: 150px; gap: 14px; }
  .s1, .s2, .s3, .s4, .s5, .s6 { grid-column: auto; grid-row: auto; }
  .s1 { grid-column: 1 / -1; grid-row: span 2; }
  .faq details { padding: 0 20px; }
}
