/* ==========================================================================
   SMARTIN SOINS - Design Système Global (Ambiance Douce & Organique)
   ========================================================================== */

:root {
  /* Fond & Cartes (Neutre & Naturel) */
  --bg-main: #f8f6f1;           /* Sable doux / Lin clair */
  --bg-card: rgba(255 255 255 / .8);          /* Blanc transparent */
  --bg-header: rgba(248, 246, 241, 0.8);
  --bg-section-dark: #e9e9dd;   /* Gris taupe très clair pour sections sombres */
  --bg-white: #FFF;
  --border-card: #e8e3d9;       /* Bordure lin doux */

  /* Typographie (Corps de texte) */
  --text-main: #223a23;         /* Vert Sauge  très sombre */
  --text-muted: #396939;

  /* Rôles des couleurs de marque */
  --primary: #5e7263;           /* Vert Sauge - Actions principales (Boutons, Liens) */
  --secondary: #9d392e;         /* Terre cuite / Terracotta - Survol & États secondaires */
  --tertiary: #C48B28;          /* Or Ambré - Lumière, Énergie & Titres principaux */

  /* Variantes d'interaction */
  --primary-light: #eef2ed;     /* Fond léger vert pour liens actifs/focus */

  /* Structure & Effets */
  --shadow-soft: 0 4px 20px rgba(37, 40, 54, 0.2);
  --radius-card: 14px;
  --radius-btn: 16px;
  --font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --transition: color .25s ease-in-out, background-color .25s ease-in-out, border-color .25s ease-in-out, transform .25s ease-in-out, box-shadow .25s ease-in-out;
}

/* --------------------------------------------------------------------------
   Base & Reset
   -------------------------------------------------------------------------- */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-family);
  line-height: 1.65;
  font-size: 1rem;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--primary);
  transition: var(--transition);
  font-weight: 600;
}

a:hover {
  color: var(--secondary);
}

.container {
  width: 90%;
  max-width: 1300px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   En-tête & Navigation
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--bg-header);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border-card);
  padding: 1rem 0;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-brand {
  display: flex;
  align-items: center;
  gap: .5rem;
  line-height: 1.5rem;
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--primary);
  text-decoration: none;
}

.logo-brand div span {
  color: var(--secondary);
  font-weight: 400;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.nav-link {
  color: var(--primary);
  font-size: 1rem;
  font-weight: 500;
  padding: 0.4rem 0.6rem;
  border-radius: var(--radius-btn);
  text-decoration: none;
  height: 50px; /* used for the svg background */
}

.nav-link:hover,
.nav-link.active {
  color: var(--secondary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 975 327'%3E%3Cpath fill='%239d392e' d='M9530 2114 c-460 -464 -1086 -845 -1752 -1065 -780 -258 -1633 -295 -2368 -103 -386 101 -674 211 -1381 529 -677 305 -1011 432 -1394 530 -331 85 -558 116 -850 116 -265 0 -433 -21 -670 -86 -359 -99 -670 -281 -885 -519 -48 -53 -40 -53 25 0 235 188 569 321 955 380 158 25 516 25 685 0 538 -77 944 -225 1945 -706 548 -263 802 -372 1128 -480 114 -38 261 -82 327 -99 1235 -310 2596 -7 3605 803 151 122 351 315 473 455 115 133 270 341 255 341 -2 0 -46 -43 -98 -96z' transform='translate(0,327) scale(0.1,-0.1)'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: bottom center;
  background-size: 100% 20px;
}

.burger-menu {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-main);
  cursor: pointer;
  margin: 0;
}

#backToTopBtn {
  display: none; /* Caché par défaut */
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 99;
  padding: 12px 15px;
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0,0,0,0.3);
  border:none;
}

/* --------------------------------------------------------------------------
   Structure & Titres
   -------------------------------------------------------------------------- */

p, ul, ol {
  margin-bottom: 1rem;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--tertiary);
  margin-bottom: 0.8rem;
  line-height: 1.3;
}

.columns-flex {
  display: flex;
  flex-direction: row;
  gap: 1.5rem;
}

/* --------------------------------------------------------------------------
   Formulaire
   -------------------------------------------------------------------------- */

form{
  max-width: 600px; 
  margin: 0 auto; 
  display: flex; 
  flex-direction: column; 
  gap: 1.2rem;
}

.btn-primary, .btn-secondary, button  {
  background-color: var(--primary);
  color: var(--primary-light);
  padding: 0.55rem 1.2rem;
  border-radius: var(--radius-btn);
  font-weight: 500;
  margin: 1rem auto;
  text-decoration: none;
  display: flex;
  align-items: center;
  max-width: max-content;
}

.btn-primary:hover, .btn-secondary:hover, button:hover {
  color: var(--primary-light);
  background-color: var(--secondary);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  border-color: var(--secondary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
  cursor: pointer;
}

.btn-secondary{
  background-color: transparent;
  color: var(--primary);
  padding: 0.8rem 1.2rem;
  border: 2px solid var(--border-card);
}

input, select, textarea{
  width: 100%; 
  padding: 0.8rem; 
  border-radius: var(--radius-btn); 
  border: 1px solid var(--border-card); 
}

/* --------------------------------------------------------------------------
   Bannières & Cartes
   -------------------------------------------------------------------------- */

.hero-section {
  padding: 3rem 0;
  text-align: center;
}

.hero-section .section-subtitle {
  margin: 0 auto 2rem auto;
}

.hero-section .container.box{
  max-width: 50%;
  background-color: var(--bg-card);
}

.section-title {
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 0.8rem;
}

.section-subtitle {
  color: var(--text-muted);
  max-width: 680px;
  font-size: 1.05rem;
  margin-bottom: 2rem;
}

.hero-img{
  max-width: 300px; 
  margin: 0 auto;
}
.hero-img img{
  border-radius: 16px;
}

.dark-bg {
  background-color: var(--bg-section-dark);
}

.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.card, .box, .faq-item {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-card);
  padding: 1.8rem;
  transition: var(--transition);
}

.card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
}

.card h3, .box h3 {
  font-size: 1.2rem;
  margin-bottom: 0.6rem;
}

.card p, .box p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.card img{
  margin: auto;
  margin-top: 0;
  margin-bottom: 1rem;
}

/* --------------------------------------------------------------------------
   Listes & Accordéons FAQ
   -------------------------------------------------------------------------- */

.list-benefits {
  list-style: none;
  margin-top: 1rem;
}

.list-benefits li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.6rem;
  color: var(--text-muted);
}

.list-benefits li::before {
  content: "•";
  color: var(--primary);
  font-weight: bold;
  font-size: 1.2rem;
  position: absolute;
  left: 0;
  top: -2px;
}

.faq-item {
  border-bottom: 1px solid var(--border-card);
  padding: 0;
  margin-bottom: .5rem;
}

.faq-trigger {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  padding: 1rem;
  max-width: none;    /* Remove <button> max-width */
  margin: 0;
}

.faq-trigger:hover  {
  color: var(--secondary);
  background-color: var(--bg-section-dark);
  border-radius: var(--radius-card);
}

.faq-content {
  display: none;
  padding: .75rem 0 0 .75rem;
  color: var(--text-muted);
}

.faq-item.open .faq-content {
  display: block;
}

.faq-item.open .faq-trigger  {
  color: var(--secondary);
  background-color: var(--bg-section-dark);
  border-radius: var(--radius-card) var(--radius-card) 0 0;
}

/* --------------------------------------------------------------------------
   Sections spécifiques & Formulaires
   -------------------------------------------------------------------------- */

section {
  padding: 3.5rem 0;
}

input, textarea {
  font-family: inherit;
  outline: none;
}

input:focus, textarea:focus {
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 3px var(--primary-light);
}

/* --------------------------------------------------------------------------
   Sections spécifiques aux pages
   -------------------------------------------------------------------------- */

.price {
  font-size: 1.4rem;
  font-weight: 700;
  margin: 0.5rem 0;
  color: var(--primary);
}

.priceDetails {
  font-weight: 400;
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   Pied de page
   -------------------------------------------------------------------------- */

.site-footer {
  background-color: #262423; /* Taupe très sombre pour structurer le bas */
  color: #d1cbc5;
  padding: 3.5rem 0 2rem 0;
  margin-top: 4rem;
}

.site-footer a {
  color: #e5e0d8;
}

.site-footer a:hover {
  color: #ffffff;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.footer-col h4 {
  color: #ffffff;
  margin-bottom: 1rem;
  font-size: 1.1rem;
}

.footer-col p {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  color: #b0aba5;
}

.footer-bottom {
  border-top: 1px solid #3b3836;
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: #8c8680;
}

/* --------------------------------------------------------------------------
   Responsive Mobile
   -------------------------------------------------------------------------- */

@media (max-width: 820px) {
  .burger-menu {
    display: block;
  }

  .desktop-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: var(--bg-white);
    flex-direction: column;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-card);
    box-shadow: var(--shadow-soft);
  }

  .desktop-nav.mobile-active {
    display: flex;
  }

  .desktop-nav .nav-link, 
  .desktop-nav .btn-primary {
    width: 100%;
    text-align: center;
  }

  .nav-link:hover, .nav-link.active{
    color: var(--secondary);
    background: #f6f4f0;
    border-radius: 0;
    border:0;
    font-weight: bold;
    font-size: 1.2rem;
  }

  .hero-section .container.box{
    max-width: 90%;
  }

  .columns-flex{
    flex-direction: column;
  }
}

/* ************************************ */
/* *********** DOTS SYSTEMS *********** */
/* ************************************ */
.hero-section {
    position: relative;
    overflow: hidden; /* Évite que les particules ne dépassent des bords */
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Le canvas se positionne en arrière-plan absolu de la section */
#bg-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0; /* Derrière le contenu, mais dans la section */
    pointer-events: none; /* Laisse passer les clics pour l'image ou les boutons */
}

/* Le contenu de la hero-section doit passer au premier plan */
.hero-section .container {
    position: relative;
    z-index: 1;
    text-align: center;
}