/* ======================================================================
   RESET DE BASE & TYPOGRAPHIE GLOBALE (inspiré de Bootstrap 5)
   ====================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue",
               Arial, "Noto Sans", sans-serif;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

body {
  margin: 0;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.5;
  color: #212529;
  background-color: #ffffff;
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-weight: 500;
  line-height: 1.2;
}

p {
  margin-top: 0;
  margin-bottom: 1rem;
}

ul, ol {
  margin-top: 0;
  margin-bottom: 1rem;
  padding-left: 2rem;
}

small {
  font-size: 0.875em;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  text-decoration: underline;
}

/* Titres / tailles (classes .h1..h6 + éléments) */

.h1, h1 {
  font-size: 2.5rem;
}

.h2, h2 {
  font-size: 2rem;
}

.h3, h3 {
  font-size: 1.75rem;
}

.h4, h4 {
  font-size: 1.5rem;
}

.h5, h5 {
  font-size: 1.25rem;
}

.h6, h6 {
  font-size: 1rem;
}

/* Display title utilisé sur la page d’accueil */

.display-5 {
  font-size: 3rem;
  font-weight: 300;
  line-height: 1.2;
}

.lead {
  font-size: 1.25rem;
  font-weight: 300;
}

/* Poids de texte */

.fw-bold {
  font-weight: 700 !important;
}

.fw-semibold {
  font-weight: 600 !important;
}

/* Texte utilitaires */

.small {
  font-size: 0.875rem !important;
}

/* ======================================================================
   CONTENEURS & GRILLE (subset Bootstrap)
   ====================================================================== */

.container {
  width: 100%;
  padding-right: 1rem;
  padding-left: 1rem;
  margin-right: auto;
  margin-left: auto;
}

@media (min-width: 576px) {
  .container {
    max-width: 540px;
  }
}

@media (min-width: 768px) {
  .container {
    max-width: 720px;
  }
}

@media (min-width: 992px) {
  .container {
    max-width: 960px;
  }
}

@media (min-width: 1200px) {
  .container {
    max-width: 1140px;
  }
}

@media (min-width: 1400px) {
  .container {
    max-width: 1320px;
  }
}

/* Ligne de grille */

.row {
  display: flex;
  flex-wrap: wrap;
  margin-right: -0.75rem;
  margin-left: -0.75rem;
}

/* Colonnes génériques */

[class*="col-"] {
  position: relative;
  width: 100%;
  padding-right: 0.75rem;
  padding-left: 0.75rem;
}

/* col-md-6 : 2 colonnes à partir de 768px */

.col-md-6 {
  flex: 0 0 auto;
  width: 100%;
}

@media (min-width: 768px) {
  .col-md-6 {
    width: 50%;
  }
}

/* col-lg-7 et col-lg-5 : layout sur la home */

.col-lg-7,
.col-lg-5 {
  flex: 0 0 auto;
  width: 100%;
}

@media (min-width: 992px) {
  .col-lg-7 {
    width: 58.333333%;
  }
  .col-lg-5 {
    width: 41.666667%;
  }
}

/* Gouttières .g-4 (gap dans la ligne) */

.row.g-4 {
  gap: 1.5rem;
}

/* Hauteur utilitaire */

.h-100 {
  height: 100% !important;
}

/* ======================================================================
   FLEX & ALIGNEMENTS (utils Bootstrap utilisés)
   ====================================================================== */

.d-flex {
  display: flex !important;
}

.d-none {
  display: none !important;
}

.flex-column {
  flex-direction: column !important;
}

@media (min-width: 768px) {
  .flex-md-row {
    flex-direction: row !important;
  }
}

.align-items-center {
  align-items: center !important;
}

.justify-content-between {
  justify-content: space-between !important;
}

.justify-content-center {
  justify-content: center !important;
}

/* Alignement vertical des cellules de tableau */

.align-middle {
  vertical-align: middle !important;
}

/* ======================================================================
   ESPACEMENTS (subset des .m*/.p* utilisés sur le site)
   ====================================================================== */

/* Échelle Bootstrap : 0, 0.25, 0.5, 1, 1.5, 3 rem */

.mt-0 { margin-top: 0 !important; }
.mt-2 { margin-top: 0.5rem !important; }
.mt-3 { margin-top: 1rem !important; }
.mt-4 { margin-top: 1.5rem !important; }
.mt-5 { margin-top: 3rem !important; }
.mt-auto { margin-top: auto !important; }

.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: 0.25rem !important; }
.mb-2 { margin-bottom: 0.5rem !important; }
.mb-3 { margin-bottom: 1rem !important; }
.mb-4 { margin-bottom: 1.5rem !important; }
.mb-5 { margin-bottom: 3rem !important; }

.me-2 { margin-right: 0.5rem !important; }
.me-3 { margin-right: 1rem !important; }

.ms-auto { margin-left: auto !important; }

.py-3 {
  padding-top: 1rem !important;
  padding-bottom: 1rem !important;
}

.py-5 {
  padding-top: 3rem !important;
  padding-bottom: 3rem !important;
}

.p-4 {
  padding: 1.5rem !important;
}

/* Espacements responsives utilisés : mt-md-0, mt-lg-0, mb-lg-0 */

@media (min-width: 768px) {
  .mt-md-0 { margin-top: 0 !important; }
}

@media (min-width: 992px) {
  .mt-lg-0 { margin-top: 0 !important; }
  .mb-lg-0 { margin-bottom: 0 !important; }
}

/* ======================================================================
   COULEURS, FONDS & BORDURES
   ====================================================================== */

.bg-light {
  background-color: #f8f9fa !important;
}

.bg-dark {
  background-color: #212529 !important;
}

.text-light {
  color: #f8f9fa !important;
}

.text-muted {
  color: #6c757d !important;
}

.text-decoration-none {
  text-decoration: none !important;
}

.border-0 {
  border: 0 !important;
}

.rounded-3 {
  border-radius: 1rem !important;
}

.rounded-circle {
  border-radius: 50% !important;
}

.shadow-sm {
  box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
}

/* ======================================================================
   BOUTONS (subset Bootstrap + override plus bas pour les couleurs)
   ====================================================================== */

.btn {
  display: inline-block;
  font-weight: 400;
  line-height: 1.5;
  color: #212529;
  text-align: center;
  text-decoration: none;
  vertical-align: middle;
  cursor: pointer;
  user-select: none;
  background-color: transparent;
  border: 1px solid transparent;
  padding: 0.375rem 0.75rem;
  font-size: 1rem;
  border-radius: 0.375rem;
  transition:
    color 0.15s ease-in-out,
    background-color 0.15s ease-in-out,
    border-color 0.15s ease-in-out,
    box-shadow 0.15s ease-in-out;
}

.btn:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.btn-sm {
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  border-radius: 0.25rem;
}

/* Variantes par défaut (avant override couleur du site) */

.btn-primary {
  color: #ffffff;
  background-color: #0d6efd;
  border-color: #0d6efd;
}

.btn-primary:hover {
  color: #ffffff;
  background-color: #0b5ed7;
  border-color: #0a58ca;
}

.btn-outline-primary {
  color: #0d6efd;
  border-color: #0d6efd;
  background-color: transparent;
}

.btn-outline-primary:hover {
  color: #ffffff;
  background-color: #0d6efd;
  border-color: #0d6efd;
}

/* ======================================================================
   NAVBAR (subset Bootstrap 5)
   ====================================================================== */

.navbar {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 1rem;
}

.navbar-brand {
  padding-top: 0.3125rem;
  padding-bottom: 0.3125rem;
  margin-right: 1rem;
  font-size: 1.25rem;
  text-decoration: none;
  white-space: nowrap;
}

.navbar-nav {
  display: flex;
  flex-direction: column;
  padding-left: 0;
  margin-bottom: 0;
  list-style: none;
}

.navbar-nav .nav-link {
  padding: 0.5rem 0;
  text-decoration: none;
}

/* Layout responsive de la barre de navigation */

.navbar-collapse {
  flex-basis: 100%;
  flex-grow: 1;
  align-items: center;
}

.collapse:not(.show) {
  display: none;
}

/* .navbar-expand-lg : menu horizontal à partir de 992px */

@media (min-width: 992px) {
  .navbar-expand-lg {
    flex-wrap: nowrap;
    justify-content: flex-start;
  }

  .navbar-expand-lg .navbar-nav {
    flex-direction: row;
  }

  .navbar-expand-lg .navbar-nav .nav-link {
    padding-right: 0.5rem;
    padding-left: 0.5rem;
  }

  .navbar-expand-lg .navbar-collapse {
    display: flex !important;
    flex-basis: auto;
  }

  .navbar-expand-lg .navbar-toggler {
    display: none;
  }
}

/* Thème foncé (navbar-dark) */

.navbar-dark .navbar-brand {
  color: #ffffff;
}

.navbar-dark .navbar-brand:hover,
.navbar-dark .navbar-brand:focus {
  color: #ffffff;
}

.navbar-dark .navbar-nav .nav-link {
  color: rgba(255, 255, 255, 0.55);
}

.navbar-dark .navbar-nav .nav-link:focus,
.navbar-dark .navbar-nav .nav-link:hover {
  color: #ffffff;
}

.navbar-dark .navbar-nav .nav-link.active {
  color: #ffffff;
}

/* Bouton burger */

.navbar-toggler {
  padding: 0.25rem 0.75rem;
  font-size: 1.25rem;
  line-height: 1;
  background-color: transparent;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.375rem;
}

.navbar-toggler-icon {
  display: inline-block;
  width: 1.5em;
  height: 1.5em;
  vertical-align: middle;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 100% 100%;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255,255,255,0.8)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ======================================================================
   CARTES (cards)
   ====================================================================== */

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background-color: #ffffff;
  background-clip: border-box;
  border: 1px solid rgba(0, 0, 0, 0.125);
  border-radius: 0.375rem;
}

.card-body {
  flex: 1 1 auto;
  padding: 1.25rem;
}

.card-title {
  margin-bottom: 0.5rem;
}

.card-text:last-child {
  margin-bottom: 0;
}

/* ======================================================================
   TABLES
   ====================================================================== */

.table {
  width: 100%;
  margin-bottom: 1rem;
  color: inherit;
  border-collapse: collapse;
}

.table th,
.table td {
  padding: 0.5rem;
  border-top: 1px solid #dee2e6;
}

.table thead th {
  vertical-align: bottom;
  border-bottom: 2px solid #dee2e6;
}

.table tbody + tbody {
  border-top: 2px solid #dee2e6;
}

.table-sm th,
.table-sm td {
  padding: 0.25rem 0.5rem;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* ======================================================================
   ALERTES
   ====================================================================== */

.alert {
  position: relative;
  padding: 0.75rem 1.25rem;
  margin-bottom: 1rem;
  border: 1px solid transparent;
  border-radius: 0.375rem;
}

.alert-success {
  color: #0f5132;
  background-color: #d1e7dd;
  border-color: #badbcc;
}

.alert-danger {
  color: #842029;
  background-color: #f8d7da;
  border-color: #f5c2c7;
}

/* ======================================================================
   FORMULAIRES
   ====================================================================== */

.form-label {
  display: inline-block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.form-control {
  display: block;
  width: 100%;
  padding: 0.375rem 0.75rem;
  font-size: 1rem;
  line-height: 1.5;
  color: #212529;
  background-color: #ffffff;
  background-clip: padding-box;
  border: 1px solid #ced4da;
  border-radius: 0.375rem;
  transition:
    border-color 0.15s ease-in-out,
    box-shadow 0.15s ease-in-out;
}

.form-control::placeholder {
  color: #6c757d;
  opacity: 1;
}

.form-control:focus {
  color: #212529;
  background-color: #ffffff;
  border-color: #86b7fe;
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

textarea.form-control {
  min-height: calc(1.5em + 0.75rem + 2px);
}

/* ======================================================================
   STYLES SPÉCIFIQUES DU SITE (ancien style.css)
   ====================================================================== */

html, body {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  color: #3d4d58; /* couleur texte principale */
}

main {
  flex: 1 0 auto;
}

footer {
  flex-shrink: 0;
}

/* Logo dans le header */
.logo-img {
  height: 56px;
  width: auto;
  filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.2));
}

/* Bandeau haut : dégradé autour du #00bce4 */
header.navbar {
  background: linear-gradient(90deg, #0095b5 0%, #00bce4 50%, #33cffa 100%);
  color: #ffffff;
}

/* Liens généraux du site */
a {
  color: #00bce4;
}

a:hover,
a:focus {
  color: #0095b5;
}

/* Liens de la navbar : on garde du blanc pour le contraste */
.navbar .nav-link {
  color: rgba(255, 255, 255, 0.85) !important;
}

.navbar .nav-link.active {
  color: #ffffff !important;
  font-weight: 600;
}

.navbar .nav-link:hover {
  color: #ffffff !important;
}

/* Boutons principaux : même couleur que le logo */
.btn-primary {
  background-color: #00bce4;
  border-color: #00bce4;
}

.btn-primary:hover,
.btn-primary:focus {
  background-color: #0095b5;
  border-color: #0095b5;
}

/* Boutons outline principaux */
.btn-outline-primary {
  color: #00bce4;
  border-color: #00bce4;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  color: #ffffff;
  background-color: #00bce4;
  border-color: #00bce4;
}

/* Petites icônes rondes numérotées */
.service-icon {
  width: 40px;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.9);
  border: 2px solid rgba(255, 255, 255, 0.95);
  color: #00bce4;
}

.nav-link.texte-rouge-gras {
  color: #ff0000 !important;
  font-weight: bold;
}

/* Texte secondaire / muted */
small,
.text-muted {
  color: #98a5ae !important;
}

/* Ajustement titre sur mobile */
@media (max-width: 576px) {
  .display-5 {
    font-size: 2rem;
  }
}
