/* Polices et base */
body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  line-height: 1.6;
  color: #333;
}

/* Header */
header {
  background: #f44336;
  color: white;
  padding: 10px 20px;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo-group { display: flex; align-items: center; gap: 10px; }
.logo {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.5em;
  font-weight: bold;
}
.logo-img {
  width: 60px;
  height: 60px;
  margin-right: 10px;
}

/* Menu principal */
nav ul {
  list-style: none;
  display: flex;
  gap: 15px;
}
nav ul li a {
  color: white;
  text-decoration: none;
  font-weight: 600;
}
.menu-toggle {
  display: none;
  font-size: 1.5em;
  background: none;
  border: none;
  color: white;
}

/* Effet hover menu */
#mainmenu li a {
  position: relative;
  padding: 6px 14px;
  border-radius: 8px;
  transition: 0.3s;
}
#mainmenu li a::after {
  content: '';
  position: absolute;
  left: 20%;
  right: 20%;
  bottom: 4px;
  height: 3px;
  background: linear-gradient(90deg, #ff9800, #f44336);
  border-radius: 2px;
  transform: scaleX(0);
  transition: transform 0.3s;
}
#mainmenu li a:hover {
  background: linear-gradient(90deg, #f44336 60%, #ff9800 100%);
  transform: scale(1.08);
}
#mainmenu li a:hover::after { transform: scaleX(1); }

/* Hero */
.hero {
  background: url('images/banner.jpg') center/cover no-repeat, #f44336;
  color: white;
  text-align: center;
  padding: 100px 20px;
}
.hero h1 { font-size: 2.5em; margin-bottom: 10px; }
.btn {
  display: inline-block;
  background: orange;
  color: white;
  padding: 10px 20px;
  border-radius: 25px;
  text-decoration: none;
  transition: 0.3s;
}
.btn:hover { background: darkorange; }

/* Sections */
section { padding: 50px 20px; text-align: center; }
.cards {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}
.card {
  background: #f5f5f5;
  padding: 20px;
  border-radius: 10px;
  flex: 1 1 200px;
  transition: 0.3s;
}
.card:hover { background: #ffe0b2; }

/* Carrousel (portée limitée à la section Actualités) */
.news .carousel { position: relative; max-width: 600px; margin: 0 auto; }
.slide {
  display: none;
  padding: 20px;
  background: #eee;
  border-radius: 10px;
}
.slide.active { display: block; }

/* Formulaire */
form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 400px;
  margin: auto;
}
input, textarea {
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
}
button[type="submit"] {
  background: #f44336;
  color: white;
  border: none;
  padding: 10px;
  border-radius: 5px;
  cursor: pointer;
}
button[type="submit"]:hover { background: #d32f2f; }

/* Footer */
footer {
  background: #333;
  color: white;
  text-align: center;
  padding: 20px;
}
footer a { color: orange; text-decoration: none; }
footer a:hover { color: #ffd180; }

/* Bouton retour en haut */
#backToTop {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #f44336;
  color: white;
  border: none;
  padding: 10px 15px;
  border-radius: 50%;
  font-size: 1.2em;
  display: none;
  cursor: pointer;
}

/* Améliorations d'accessibilité & confort */
html { scroll-behavior: smooth; }
a.card { text-decoration: none; color: inherit; }
a.card:focus-visible { outline: 2px solid #f44336; outline-offset: 2px; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid #ff9800; outline-offset: 2px;
}
img { max-width: 100%; height: auto; }

/* ==== Effets HERO (sans modifier le HTML) ==== */
.hero {
  position: relative;
  isolation: isolate;           /* évite que l’overlay affecte le contenu */
  overflow: hidden;
}
/* Overlay animé très léger (glow + teinte rouge/orange) */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(80% 60% at 50% 40%, rgba(255,255,255,0.12), rgba(255,255,255,0) 60%),
    linear-gradient(120deg, rgba(244,67,54,0.35), rgba(255,152,0,0.25));
  mix-blend-mode: screen;
  animation: heroGlow 12s ease-in-out infinite alternate;
}
@keyframes heroGlow {
  0%   { opacity: .35; filter: blur(0px); }
  100% { opacity: .6;  filter: blur(6px); }
}
/* Apparition douce des éléments */
.hero h1,
.hero p,
.hero .btn {
  position: relative;
  z-index: 1;  /* au-dessus de l’overlay */
  opacity: 0;
  transform: translateY(14px);
  animation: heroFadeUp .8s ease forwards;
}
.hero h1 { animation-delay: .05s; }
.hero p  { animation-delay: .20s; }
.hero .btn { animation-delay: .40s; }
@keyframes heroFadeUp {
  to { opacity: 1; transform: none; }
}
/* Améliore le bouton (léger lift + lueur) */
.hero .btn {
  box-shadow: 0 10px 24px rgba(0,0,0,0.15);
  transition: transform .25s ease, box-shadow .25s ease, background .3s;
}
.hero .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(0,0,0,0.18);
}
/* Parallax (desktop) — fixe le fond pour plus de profondeur */
@media (min-width: 992px) {
  .hero { background-attachment: fixed; }
}
/* Accessibilité : désactive les animations si l’utilisateur préfère réduire */
@media (prefers-reduced-motion: reduce) {
  .hero::before,
  .hero h1,
  .hero p,
  .hero .btn {
    animation: none !important;
    transition: none !important;
  }
}

/* ==== EFFETS SECTION "ACTIONS" ==== */
.actions {
  position: relative;
  background: linear-gradient(180deg, #fff 0%, #fff7f5 100%);
  overflow: hidden;
}
/* Animation d’apparition des cartes */
.actions .card {
  position: relative;
  opacity: 0;
  transform: translateY(25px);
  animation: fadeUp .8s ease forwards;
}
.actions .card:nth-child(1) { animation-delay: .15s; }
.actions .card:nth-child(2) { animation-delay: .3s; }
.actions .card:nth-child(3) { animation-delay: .45s; }
@keyframes fadeUp {
  to { opacity: 1; transform: none; }
}
/* Effet 3D doux au survol */
.actions .card {
  background: #fffdf8;
  border: 2px solid rgba(255, 171, 64, 0.35);
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(255, 171, 64, 0.18);
  font-weight: 600;
  letter-spacing: 0.4px;
  overflow: hidden;
  transform: translateY(0) rotateX(0deg);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease, background 0.35s ease;
}
.actions .card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 171, 64, 0.12), rgba(255, 248, 225, 0.6));
  opacity: 0;
  transition: opacity 0.35s ease;
}
.actions .card:hover {
  background: #fff8e6;
  transform: translateY(-8px) rotateX(3deg);
  border-color: rgba(255, 152, 0, 0.7);
  box-shadow: 0 20px 36px rgba(255, 152, 0, 0.26);
  color: #e65100;
}
.actions .card:hover::after { opacity: 1; }
/* Animation lumineuse subtile sur le titre */
.actions h2 {
  position: relative;
  display: inline-block;
  color: #f44336;
  background: linear-gradient(90deg, #f44336, #ff9800);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shine 5s linear infinite;
}
@keyframes shine {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
/* Animation douce de l’image */
.actions img {
  opacity: 0;
  transform: scale(0.95);
  animation: zoomIn 1.2s ease forwards;
  animation-delay: 0.2s;
  border-radius: 12px;
}
@keyframes zoomIn {
  to { opacity: 1; transform: scale(1); }
}
/* Accessibilité : réduit les animations si préférence utilisateur */
@media (prefers-reduced-motion: reduce) {
  .actions .card, .actions img, .actions h2 {
    animation: none !important;
    transition: none !important;
  }
}

/* ==== EFFETS SECTION "GROUPES" ==== */
.groupes {
  position: relative;
  background: linear-gradient(180deg, #fff7f5 0%, #ffffff 100%);
  overflow: hidden;
}
/* Apparition séquentielle des cartes */
.groupes .card {
  opacity: 0;
  transform: translateY(30px) scale(0.96);
  animation: groupFadeUp 0.9s ease forwards;
}
.groupes .card:nth-child(1) { animation-delay: 0.15s; }
.groupes .card:nth-child(2) { animation-delay: 0.3s; }
.groupes .card:nth-child(3) { animation-delay: 0.45s; }
.groupes .card:nth-child(4) { animation-delay: 0.6s; }
@keyframes groupFadeUp {
  to { opacity: 1; transform: translateY(0) scale(1); }
}
/* Carte dynamique avec halo rouge/orange */
.groupes .card {
  position: relative;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
  border: 2px solid rgba(255, 152, 0, 0.15);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
  will-change: transform;
}
.groupes .card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, rgba(244,67,54,0.08), rgba(255,152,0,0.08));
  opacity: 0;
  border-radius: 14px;
  transition: opacity 0.35s ease;
}
.groupes .card:hover {
  transform: translateY(-10px);
  box-shadow: 0 24px 48px rgba(244, 67, 54, 0.25);
  border-color: rgba(244,67,54,0.6);
}
.groupes .card:hover::before { opacity: 1; }
/* Animation du titre principal */
.groupes h2 {
  position: relative;
  display: inline-block;
  margin-bottom: 20px;
  background: linear-gradient(90deg, #f44336, #ff9800);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradientShift 6s ease-in-out infinite alternate;
}
@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  100% { background-position: 100% 50%; }
}
/* Apparition du paragraphe avec fondu */
.groupes p {
  opacity: 0;
  transform: translateY(10px);
  animation: textFadeUp 1s ease forwards;
  animation-delay: 0.2s;
}
@keyframes textFadeUp {
  to { opacity: 1; transform: none; }
}
/* Accessibilité : désactive les animations si nécessaire */
@media (prefers-reduced-motion: reduce) {
  .groupes .card, .groupes h2, .groupes p {
    animation: none !important;
    transition: none !important;
  }
}

/* ==== EFFETS SECTION "ACTUALITÉS" ==== */
.news {
  position: relative;
  background: linear-gradient(180deg, #ffffff 0%, #fff7f5 100%);
  overflow: hidden;
}
/* Titre en dégradé animé */
.news h2 {
  position: relative;
  display: inline-block;
  margin-bottom: 14px;
  background: linear-gradient(90deg, #f44336, #ff9800);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: newsGradient 6s ease-in-out infinite alternate;
}
@keyframes newsGradient {
  0% { background-position: 0% 50%; }
  100% { background-position: 100% 50%; }
}
/* Paragraphe d'intro en fade-up */
.news > p {
  opacity: 0;
  transform: translateY(10px);
  animation: newsTextIn .9s ease forwards;
  animation-delay: .15s;
}
@keyframes newsTextIn { to { opacity: 1; transform: none; } }
/* Image d'illustration : zoom-in + léger reflet */
.news > img {
  opacity: 0;
  transform: scale(.96);
  border-radius: 12px;
  box-shadow: 0 12px 28px rgba(0,0,0,.12);
  animation: newsImgIn 1s ease forwards;
  animation-delay: .25s;
  position: relative;
}
@keyframes newsImgIn { to { opacity: 1; transform: scale(1); } }
/* Carousel : cadre doux + ombre (section actualités) */
.news .carousel {
  position: relative;
  border-radius: 14px;
  padding: 10px;
  margin-top: 10px;
  box-shadow: 0 10px 24px rgba(244,67,54,.14);
  background: #fff;
}
/* Slides : apparition animée lors de l'activation (compatible avec .active) */
.slide {
  display: none;
  padding: 20px;
  background: #fafafa;
  border-radius: 10px;
  box-shadow: inset 0 1px 0 rgba(0,0,0,.04);
  transform-origin: center top;
}
.slide.active {
  display: block;
  animation: slideIn .55s ease both;
}
@keyframes slideIn {
  from { opacity: 0; transform: translateY(8px) scale(.98); }
  to   { opacity: 1; transform: none; }
}
/* Subtile lueur du slide au survol (actu seulement) */
.news .carousel:hover .slide.active {
  box-shadow: inset 0 1px 0 rgba(0,0,0,.04), 0 12px 28px rgba(244,67,54,.12);
}
/* Accessibilité : réduire les animations si préférence utilisateur */
@media (prefers-reduced-motion: reduce) {
  .news h2,
  .news > p,
  .news > img,
  .slide.active {
    animation: none !important;
    transition: none !important;
  }
}

/* ==== EFFETS SECTION "CONTACT" ==== */
.contact {
  position: relative;
  background: linear-gradient(180deg, #fff7f5 0%, #ffffff 100%);
  overflow: hidden;
}
/* Titre en dégradé animé (cohérent avec les autres sections) */
.contact h2 {
  position: relative;
  display: inline-block;
  margin-bottom: 16px;
  background: linear-gradient(90deg, #f44336, #ff9800);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: contactGradient 6s ease-in-out infinite alternate;
}
@keyframes contactGradient {
  0% { background-position: 0% 50%; }
  100% { background-position: 100% 50%; }
}
/* Carte formulaire vivante */
.contact form {
  background: #ffffff;
  border: 2px solid rgba(244,67,54,0.12);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 16px 40px rgba(244,67,54,0.14);
  max-width: 520px;
  margin: 18px auto 0;
  animation: formIn .8s ease forwards;
  opacity: 0;
  transform: translateY(16px);
}
@keyframes formIn {
  to { opacity: 1; transform: none; }
}
/* Champs : focus glow + ligne active */
.contact input,
.contact textarea {
  background: #fff;
  border: 2px solid rgba(0,0,0,0.08);
  border-radius: 10px;
  transition: border-color .25s ease, box-shadow .25s ease, transform .2s ease;
  box-shadow: inset 0 1px 0 rgba(0,0,0,0.04);
}
.contact input:focus,
.contact textarea:focus {
  border-color: #f44336;
  box-shadow: 0 0 0 3px rgba(244,67,54,0.12), inset 0 1px 0 rgba(0,0,0,0.04);
  outline: none;
  transform: translateY(-1px);
}
/* Placeholder plus discret */
.contact ::placeholder {
  color: #9e9e9e;
  opacity: .9;
}
/* Retour visuel : valid / invalid (HTML5 required) */
.contact input:valid,
.contact textarea:valid {
  border-color: rgba(76,175,80,0.6); /* vert doux */
}
.contact input:invalid:not(:placeholder-shown),
.contact textarea:invalid:not(:placeholder-shown) {
  border-color: rgba(244,67,54,0.7);
}
/* Bouton : gradient + lueur + "shine" au hover */
.contact .btn {
  position: relative;
  border-radius: 28px;
  padding: 12px 22px;
  font-weight: 600;
  background: linear-gradient(90deg, #ff9800, #f44336);
  box-shadow: 0 10px 24px rgba(244,67,54,0.25);
  transition: transform .22s ease, box-shadow .22s ease, filter .22s ease;
}
.contact .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(244,67,54,0.28);
  filter: saturate(1.05);
}
/* reflet qui balaye */
.contact .btn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(120deg, transparent 0%, rgba(255,255,255,.35) 20%, transparent 40%);
  transform: translateX(-120%);
  transition: transform .7s ease;
  pointer-events: none;
}
.contact .btn:hover::after {
  transform: translateX(120%);
}
/* Accessibilité : si l’utilisateur préfère réduire les animations */
@media (prefers-reduced-motion: reduce) {
  .contact h2,
  .contact form,
  .contact .btn::after {
    animation: none !important;
    transition: none !important;
  }
}

/* ==== EFFETS SECTION "QUI SOMMES-NOUS" ==== */
.about {
  position: relative;
  background: linear-gradient(180deg, #ffffff 0%, #fff7f5 100%);
  overflow: hidden;
  padding-top: 60px;
  padding-bottom: 60px;
}
/* Fond avec halo subtil rouge/orange */
.about::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 70% 20%, rgba(244,67,54,0.08), transparent 60%),
              radial-gradient(circle at 20% 80%, rgba(255,152,0,0.08), transparent 60%);
  opacity: 0;
  animation: aboutBg 2.5s ease forwards;
}
@keyframes aboutBg {
  to { opacity: 1; }
}
/* Animation d’entrée du titre */
.about h2 {
  position: relative;
  display: inline-block;
  margin-bottom: 16px;
  background: linear-gradient(90deg, #f44336, #ff9800);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: aboutTitle 1s ease forwards;
  opacity: 0;
  transform: translateY(15px);
}
@keyframes aboutTitle {
  to { opacity: 1; transform: none; }
}
/* Paragraphe principal animé (fade + slide) */
.about p {
  max-width: 800px;
  margin: 0 auto;
  font-size: 1.05em;
  color: #444;
  opacity: 0;
  transform: translateY(15px);
  animation: aboutText 1.2s ease forwards;
  animation-delay: 0.25s;
}
@keyframes aboutText {
  to { opacity: 1; transform: none; }
}
/* Soulignement progressif sous le titre */
.about h2::after {
  content: "";
  display: block;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, #f44336, #ff9800);
  border-radius: 3px;
  margin: 8px auto 0;
  animation: underlineGrow 1s ease forwards;
  animation-delay: 0.4s;
}
@keyframes underlineGrow {
  to { width: 60%; }
}

/* Confort tactile : neutraliser les hover "collants" */
@media (hover: none) {
  #mainmenu li a:hover {
    background: none;
    transform: none;
  }
  .card:hover {
    background: #f5f5f5;
    transform: none;
    box-shadow: none;
  }
  .actions .card:hover,
  .groupes .card:hover {
    transform: none;
    box-shadow: none;
    color: inherit;
  }
}

/* Responsive */
@media(max-width: 768px) {
  nav ul {
    display: none;
    flex-direction: column;
    background: #f44336;
    position: absolute;
    top: 60px;
    right: 20px;
    padding: 10px;
  }
  nav ul.show { display: flex; }
  .menu-toggle { display: block; }
}







