:root {
  --primary: #1c1f26;
  --accent: #ab5ea3;
  --accent-light: #e3b0de;
  --secondary: #597b7d;
  --separator: #8f0e82; /* Nouvelle couleur bordure */
  --bg-light: #f6f6f9;
  --amma-bg: #8c92a2;   /* Nouveau fond AMMA */
  --pratique-bg: #545d73; /* Fond En Pratique */
  --text-main: #333;
  --text-light: #fff;
  --transition: all 0.3s ease;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* Reset & Global */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Questrial', sans-serif; color: var(--text-main); line-height: 1.6; background: var(--bg-light); }
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }

/* Header & Nav */
header {
  position: sticky; top: 0; z-index: 1000;
  background: var(--primary); padding: 0.5rem 1rem;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  border-bottom: 2px solid var(--separator); /* Ajout bordure violette */
}
nav {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
}
.logo { height: 60px; }
.nav-links { display: flex; gap: 20px; list-style: none; }
.nav-links a {
  color: var(--accent-light); font-weight: bold; padding: 5px 10px;
  border-radius: 4px; transition: var(--transition);
}
.nav-links a:hover, .nav-links a.active { background: var(--accent); color: #fff; }
.burger { display: none; color: var(--accent-light); font-size: 1.5rem; cursor: pointer; }

/* Back to Top Button */
#backToTop {
  display: none; /* Caché par défaut */
  position: fixed; bottom: 20px; right: 20px; z-index: 999;
  background: var(--accent); color: white; border: none;
  width: 50px; height: 50px; border-radius: 50%;
  font-size: 24px; cursor: pointer; box-shadow: var(--shadow);
  transition: var(--transition);
}
#backToTop:hover { transform: translateY(-3px); background: var(--separator); }

/* Sections Global */
section { padding: 80px 20px; max-width: 100%; margin: 0 auto; }
.content-wrapper { max-width: 1200px; margin: 0 auto; } /* Wrapper pour centrer le contenu */

.section-title {
  text-align: center; color: var(--accent); font-size: 2.5rem;
  margin-bottom: 3rem; text-transform: uppercase; letter-spacing: 2px;
}

/* Hero Section */
#home {
  min-height: 80vh;
  background: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), url('images/home.jpg') center/cover;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  color: #fff; text-align: center;
}
#home h1 { font-size: 4rem; margin-bottom: 1rem; color: var(--accent); }
#home p { font-size: 1.5rem; color: #d9fafc; }

/* AMMA Section (Modifiée) */
#amma {
  background-color: var(--amma-bg);
  color: #fff;
}
.amma-container {
  display: flex; /* Flex pour gérer l'ordre */
  flex-direction: row;
  gap: 40px; align-items: center; justify-content: center;
  max-width: 1000px; margin: 0 auto;
}
.amma-img { flex: 1; } /* Image à gauche par défaut (ordre HTML) */
.amma-img img { border-radius: 12px; box-shadow: var(--shadow); }

.amma-text { 
  flex: 0 0 400px; /* Largeur fixe demandée */
  max-width: 400px;
}
.amma-text h2 { color: #fff; margin-bottom: 1rem; }

/* Benefits Grid */
.grid-benefits {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 15px;
}
.benefit-card {
  background: var(--accent); color: #fff;
  height: 200px; display: flex; align-items: center; justify-content: center;
  text-align: center; padding: 20px; border-radius: 8px;
  font-weight: bold; transition: var(--transition); overflow: hidden;
}
.benefit-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.benefit-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.benefit-card:hover img { transform: scale(1.1); }

/* En Pratique Section (Nouvelle) */
#en-pratique {
  background: linear-gradient(rgba(84, 93, 115, 0.9), rgba(84, 93, 115, 0.9)), url('images/en-pratique.png') center/cover;
  background-color: var(--pratique-bg);
  color: #fff; text-align: center;
  min-height: 400px; display: flex; align-items: center; justify-content: center;
}
.pratique-title {
  background: rgba(255,255,255,0.1); padding: 15px 30px;
  border-radius: 8px; font-size: 2.5rem; letter-spacing: 2px; text-transform: uppercase;
  border: 1px solid rgba(255,255,255,0.3);
}

/* Team Cards */
.team-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 30px;
}
.member-card {
  background: #fff; border-radius: 12px; overflow: hidden;
  box-shadow: var(--shadow); text-align: center; padding-bottom: 20px;
  transition: var(--transition);
}
.member-card:hover { transform: translateY(-10px); }
.member-img-wrapper {
  height: 150px; width: 150px; margin: 30px auto;
  border-radius: 50%; overflow: hidden; border: 4px solid var(--accent-light);
}
.member-img-wrapper img { width: 100%; height: 100%; object-fit: cover; }
.member-name { color: var(--secondary); margin-bottom: 5px; }
.member-role { color: var(--accent); font-weight: bold; font-size: 0.9rem; margin-bottom: 15px; }
.member-desc { padding: 0 20px; font-size: 0.9rem; color: #666; }

/* Testimonials */
.testimonials-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px;
}
.quote-card {
  background: #fff; padding: 30px; border-radius: 12px;
  border-left: 5px solid var(--accent); box-shadow: var(--shadow);
  font-style: italic;
}
.quote-author {
  display: block; margin-top: 15px; font-weight: bold;
  color: var(--secondary); font-style: normal; text-align: right;
}

/* Contact Form */
.form-container { max-width: 700px; margin: 0 auto; background: #fff; padding: 40px; border-radius: 12px; box-shadow: var(--shadow); }
.form-row { display: flex; gap: 20px; margin-bottom: 20px; } /* Ligne pour nom/prénom */
.form-col { flex: 1; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; color: var(--primary); font-weight: bold; }
.form-group input, .form-group textarea {
  width: 100%; padding: 12px; border: 2px solid #eee; border-radius: 6px;
  font-family: inherit; transition: var(--transition);
}
.form-group input:focus, .form-group textarea:focus { border-color: var(--accent); outline: none; }

button[type="submit"] {
  width: 100%; padding: 15px; background: var(--accent); color: #fff;
  border: none; border-radius: 6px; font-size: 1.1rem; cursor: pointer;
  transition: var(--transition);
}
button[type="submit"]:hover { background: var(--primary); }

/* Success Message (Hidden by default) */
#success-message {
  display: none; text-align: center; padding: 40px; background: #d4edda;
  color: #155724; border-radius: 12px; border: 1px solid #c3e6cb;
}
#success-message h3 { margin-bottom: 10px; }

/* Utility Classes */
.hidden { opacity: 0; transform: translateY(30px); transition: all 0.8s ease-out; }
.show { opacity: 1; transform: translateY(0); }

/* Responsive Mobile */
@media (max-width: 768px) {
  .burger { display: block; }
  .nav-links {
    position: absolute; top: 70px; right: 0; width: 100%; background: var(--primary);
    flex-direction: column; padding: 20px; text-align: center;
    clip-path: circle(0px at 100% 0px); transition: clip-path 0.5s ease-in-out;
  }
  .nav-links.nav-active { clip-path: circle(150% at 100% 0px); }
  
  .amma-container { flex-direction: column-reverse; /* Texte au dessus image en mobile, ou column pour inverse */ }
  .amma-text { max-width: 100%; flex: auto; }
  .form-row { flex-direction: column; gap: 0; }
  #home h1 { font-size: 2.5rem; }
}