/* ==========================================================================
   NOVA SANTÉ — Feuille de style principale
   Palette : Teal médical (inspirée du logo)
   Approche : Mobile-first, accessible, sans framework
   ========================================================================== */

/* ---------- 1. RESET & VARIABLES ----------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* Couleurs de la marque */
  --color-primary:       #0F8B8D;   /* Teal principal */
  --color-primary-dark:  #0A5C5E;   /* Teal foncé (hover) */
  --color-primary-light: #5BC0BE;   /* Teal clair (accents) */
  --color-bg-soft:       #EAF3F3;   /* Fond teinté teal, plus présent */
  --color-bg-warm:       #F7FBFB;   /* Fond intermédiaire pour alterner */
  --color-white:         #FFFFFF;
  --color-text:          #1A2B3C;   /* Texte principal */
  --color-text-muted:    #5A6B7C;   /* Texte secondaire */
  --color-border:        #E4ECEC;   /* Bordures discrètes */

  /* Typographie */
  --font-main: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Espacements & rayons */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;

  /* Ombres douces */
  --shadow-sm: 0 2px 8px rgba(15, 139, 141, 0.08);
  --shadow-md: 0 8px 24px rgba(15, 139, 141, 0.12);
  --shadow-lg: 0 16px 40px rgba(15, 139, 141, 0.15);

  /* Transitions */
  --transition: all 0.25s ease;
}

/* ---------- 2. BASE TYPOGRAPHY -------------------------------------------- */
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg-warm);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
  line-height: 1.25;
  font-weight: 700;
  color: var(--color-text);
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2.5rem); margin-bottom: 1rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.5rem; }

p { color: var(--color-text-muted); }

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: var(--transition);
}
a:hover { color: var(--color-primary-dark); }

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ---------- 3. LAYOUT UTILITIES ------------------------------------------ */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

.section {
  padding: 4rem 0;
}

.section--soft {
  background-color: var(--color-bg-soft);
}

.section__header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 3rem;
}

.section__header p {
  font-size: 1.125rem;
}

/* ---------- 4. BUTTONS --------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  font-family: var(--font-main);
  font-size: 1rem;
  font-weight: 600;
  border: 2px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
}

.btn--primary {
  background-color: var(--color-primary);
  color: var(--color-white);
}
.btn--primary:hover {
  background-color: var(--color-primary-dark);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn--outline {
  background-color: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn--outline:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* ---------- 5. HEADER & NAVIGATION --------------------------------------- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--color-white);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}

.header__logo img {
  height: 78px;
  width: auto;
}

.nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav__list {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav__link {
  color: var(--color-text);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}
.nav__link:hover,
.nav__link.is-active {
  color: var(--color-primary);
}
.nav__link.is-active::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--color-primary);
  border-radius: 2px;
}

/* Burger button (mobile only) */
.nav__toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}
.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--color-text);
  margin: 5px 0;
  transition: var(--transition);
}

/* ---------- 6. HERO SECTION (Homepage) ----------------------------------- */
.hero {
  background: linear-gradient(135deg, #DDEEEE 0%, #E8F4F4 60%, #F0F7F7 100%);
  padding: 4rem 0;
  overflow: hidden;
}

.hero__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: center;
}

.hero__tagline {
  display: inline-block;
  background-color: rgba(15, 139, 141, 0.1);
  color: var(--color-primary);
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.hero__title {
  margin-bottom: 1.5rem;
}

.hero__title span {
  color: var(--color-primary);
}

.hero__desc {
  font-size: 1.125rem;
  margin-bottom: 2rem;
  max-width: 540px;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero__image {
  position: relative;
}

.hero__image img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

/* ---------- 7. STATS / KEY FIGURES --------------------------------------- */
.stats {
  background-color: var(--color-white);
  padding: 3rem 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.stats__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  text-align: center;
}

.stat__number {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.stat__label {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  font-weight: 500;
}

/* ---------- 8. SERVICES GRID --------------------------------------------- */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.service-card {
  background-color: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 2rem;
  transition: var(--transition);
  text-align: left;
}
.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-primary-light);
}

.service-card__icon {
  width: 56px;
  height: 56px;
  background-color: rgba(15, 139, 141, 0.1);
  color: var(--color-primary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}
.service-card__icon svg {
  width: 28px;
  height: 28px;
  stroke-width: 1.75;
}

.service-card h3 {
  color: var(--color-text);
  margin-bottom: 0.75rem;
}

.service-card p {
  font-size: 0.95rem;
  margin-bottom: 0;
}

/* ---------- 9. WHY US (4 pillars) ---------------------------------------- */
.pillars {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.pillar {
  text-align: center;
  padding: 1.5rem;
}

.pillar__icon {
  width: 72px;
  height: 72px;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  color: var(--color-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
  box-shadow: var(--shadow-md);
}
.pillar__icon svg {
  width: 32px;
  height: 32px;
  stroke-width: 1.75;
}

.pillar h3 {
  margin-bottom: 0.75rem;
}

/* ---------- 10. CTA BANNER (Bottom of pages) ----------------------------- */
.cta-banner {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: var(--color-white);
  padding: 4rem 0;
  text-align: center;
}

.cta-banner h2 {
  color: var(--color-white);
  margin-bottom: 1rem;
}

.cta-banner p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.125rem;
  max-width: 600px;
  margin: 0 auto 2rem;
}

.cta-banner .btn--primary {
  background-color: var(--color-white);
  color: var(--color-primary);
}
.cta-banner .btn--primary:hover {
  background-color: var(--color-bg-soft);
}

/* ---------- 11. PAGE HEADER (sub-pages) ---------------------------------- */
.page-header {
  background: linear-gradient(135deg, var(--color-bg-soft) 0%, #E8F4F4 100%);
  padding: 3.5rem 0;
  text-align: center;
}

.page-header h1 {
  margin-bottom: 1rem;
}

.page-header p {
  max-width: 700px;
  margin: 0 auto;
  font-size: 1.125rem;
}

/* ---------- 12. FOOTER --------------------------------------------------- */
.footer {
  background-color: var(--color-text);
  color: rgba(255, 255, 255, 0.8);
  padding: 3rem 0 1.5rem;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer__col h4 {
  color: var(--color-white);
  font-size: 1rem;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer__col ul { list-style: none; }
.footer__col li { margin-bottom: 0.5rem; }
.footer__col a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}
.footer__col a:hover { color: var(--color-primary-light); }

.footer__logo img {
  height: 72px;
  filter: brightness(0) invert(1);   /* Logo en blanc sur fond sombre */
  margin-bottom: 1rem;
}

.footer__bottom {
  text-align: center;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.5);
}

/* ---------- 13. CONTACT PAGE --------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

.contact-info__item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.75rem;
}

.contact-info__icon {
  width: 48px;
  height: 48px;
  background-color: rgba(15, 139, 141, 0.1);
  color: var(--color-primary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.contact-info__item h4 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.contact-info__item p {
  margin-bottom: 0;
  font-size: 0.95rem;
}

.contact-form {
  background-color: var(--color-white);
  padding: 2rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-family: var(--font-main);
  font-size: 1rem;
  background-color: var(--color-white);
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(15, 139, 141, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

/* ---------- 14. LEGAL PAGES (long text) ---------------------------------- */
.legal-content {
  max-width: 800px;
  margin: 0 auto;
}

.legal-content h2 {
  font-size: 1.5rem;
  margin: 2rem 0 1rem;
  color: var(--color-primary);
}

.legal-content p,
.legal-content li {
  color: var(--color-text);
  margin-bottom: 1rem;
}

.legal-content ul {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}

/* ==========================================================================
   15. RESPONSIVE — Tablette (≥ 640px)
   ========================================================================== */
@media (min-width: 640px) {
  .stats__grid {
    grid-template-columns: repeat(4, 1fr);
  }
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .pillars {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================================================
   16. RESPONSIVE — Desktop (≥ 960px)
   ========================================================================== */
@media (min-width: 960px) {
  .section {
    padding: 5.5rem 0;
  }
  .hero {
    padding: 5.5rem 0;
  }
  .hero__inner {
    grid-template-columns: 1.1fr 1fr;
  }
  .services-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .pillars {
    grid-template-columns: repeat(4, 1fr);
  }
  .footer__grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
  .contact-grid {
    grid-template-columns: 1fr 1.2fr;
  }
}

/* ==========================================================================
   17. RESPONSIVE — Mobile menu (< 960px)
   ========================================================================== */
@media (max-width: 959px) {
  .nav__toggle {
    display: block;
    z-index: 200;
  }
  .nav__list {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 320px;
    height: 100vh;
    background-color: var(--color-white);
    flex-direction: column;
    padding: 5rem 2rem 2rem;
    gap: 1.5rem;
    box-shadow: var(--shadow-lg);
    transition: right 0.3s ease;
  }
  .nav__list.is-open {
    right: 0;
  }
  /* Burger transformé en croix quand le menu est ouvert */
  .nav__toggle.is-open span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
  }
  .nav__toggle.is-open span:nth-child(2) {
    opacity: 0;
  }
  .nav__toggle.is-open span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }
}

/* ---------- 18. ABOUT PREVIEW (Homepage) --------------------------------- */
.about-preview {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: center;
}

.about-preview__image img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  width: 100%;
  height: 100%;
  object-fit: cover;
  max-height: 480px;
}

.about-preview__content h2 {
  margin: 1rem 0 1.25rem;
}

.about-preview__content p {
  margin-bottom: 1rem;
}

@media (min-width: 960px) {
  .about-preview {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
}

/* ---------- 19. ABOUT — Image reversed on the right (desktop only) ------ */
@media (min-width: 960px) {
  .about-preview--reverse .about-preview__image {
    order: 2;
  }
}

/* ---------- 20. ENGAGEMENT LIST (À propos) ------------------------------ */
.engagement-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
}
.engagement-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.5rem 0;
  color: var(--color-text);
  font-size: 1rem;
}
.engagement-list__check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  min-width: 24px;
  background-color: var(--color-primary);
  color: var(--color-white);
  border-radius: 50%;
  font-size: 0.85rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 2px;
}