/* Apedys 56 — feuille de style commune */

@font-face { font-family: "Lexend"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/lexend-400.woff2") format("woff2"); }
@font-face { font-family: "Lexend"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/lexend-500.woff2") format("woff2"); }
@font-face { font-family: "Lexend"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/lexend-600.woff2") format("woff2"); }
@font-face { font-family: "Lexend"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/lexend-700.woff2") format("woff2"); }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: #FBF8F3; }
img { max-width: 100%; height: auto; }
[hidden] { display: none !important; }

a { color: #1A6C96; }
a:hover { color: #13506F; }
a:focus-visible, button:focus-visible { outline: 3px solid #B85410; outline-offset: 3px; }

ul { margin: 0; padding-left: 22px; }
li { margin-bottom: 6px; }

.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 10px; background: #1F2A44; color: #FFFFFF; font-family: "Lexend", system-ui, sans-serif; text-decoration: none; }
.skip-link:focus { top: 12px; color: #FFFFFF; }

/* Bandeau « Rejoignez-nous » */
.join-bg { background-image: linear-gradient(rgba(19, 80, 111, 0.85), rgba(19, 80, 111, 0.85)), url("../img/phare.webp"); background-size: cover; background-position: center; }

/* Animations */
@keyframes floaty { 0% { transform: translateY(0); } 50% { transform: translateY(-14px); } 100% { transform: translateY(0); } }
@keyframes fadeup { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.trouble-panel, .etape, .faq-a, .article { animation: fadeup 0.35s ease-out; }
[data-rotate] { display: inline-block; transition: opacity 0.25s ease, transform 0.25s ease; }
[data-rotate].sortie { opacity: 0; transform: translateY(-8px); }

/* Questions fréquentes */
.faq-q { width: 100%; min-height: 64px; padding: 18px 4px; display: flex; align-items: center; justify-content: space-between; gap: 16px; background: none; border: none; cursor: pointer; text-align: left; font-family: inherit; font-size: 19px; font-weight: 600; color: #1F2A44; }
.faq-icon { flex-shrink: 0; width: 36px; height: 36px; border-radius: 999px; background: #E3F2FA; color: #13506F; display: flex; align-items: center; justify-content: center; font-size: 22px; transition: background 0.2s ease, color 0.2s ease; }
.faq-q[aria-expanded="true"] .faq-icon { background: #1A6C96; color: #FFFFFF; }

/* Pastilles (années, filtres) */
.pill { min-height: 48px; padding: 10px 20px; border-radius: 999px; border: 2px solid #CDE6F3; background: #FFFFFF; color: #1F2A44; font-family: inherit; font-size: 17px; font-weight: 600; cursor: pointer; transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease; }
.pill:hover { border-color: #1A6C96; }
.pill[aria-selected="true"], .pill[aria-pressed="true"] { background: #1A6C96; border-color: #1A6C96; color: #FFFFFF; font-weight: 700; }
.filtre { min-height: 44px; padding: 8px 18px; font-size: 16px; border-color: #D9D2C5; }
.filtre[aria-pressed="true"] { background: #1F2A44; border-color: #1F2A44; }

/* Onglets des troubles */
.tab { min-height: 48px; padding: 10px 18px; border-radius: 14px; border: none; background: transparent; color: #1F2A44; font-family: inherit; font-size: 16px; font-weight: 500; cursor: pointer; transition: background 0.2s ease; }
.tab:hover { background: #E3F2FA; }
.tab[aria-selected="true"] { background: #1A6C96; color: #FFFFFF; font-weight: 700; }

/* Cartes qui se soulèvent */
.soutien { transition: transform 0.25s ease, box-shadow 0.25s ease; }
.soutien:hover { transform: translateY(-6px); box-shadow: 0 16px 36px rgba(31, 42, 68, 0.12); }

/* Menu mobile */
.menu-toggle { display: none; align-items: center; gap: 8px; min-height: 44px; padding: 8px 16px; border-radius: 12px; border: 2px solid #1F2A44; background: #FFFFFF; color: #1F2A44; font-family: "Lexend", system-ui, sans-serif; font-size: 16px; font-weight: 600; cursor: pointer; }

@media (max-width: 960px) {
  .menu-toggle { display: inline-flex; }
  .nav-principale { display: none !important; width: 100%; flex-direction: column; align-items: stretch !important; gap: 4px; padding-top: 8px; }
  .nav-principale.ouvert { display: flex !important; }
  .nav-principale a { margin-left: 0 !important; }
}

@media (max-width: 640px) {
  .logo-sous-titre { display: none; }
  h1 { font-size: 36px !important; }
  h2 { font-size: 26px !important; }
  .trouble-titre { font-size: 32px !important; }
  .annee { font-size: 48px !important; }
  .hist-card, .trouble-panel > div:first-child { padding: 28px !important; }
  section { padding-left: 16px !important; padding-right: 16px !important; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
