    :root {
      --bg-color: linear-gradient(135deg, #0f172a, #1e293b);
      --text-color: #e2e8f0;
      --desc-color: #cbd5e1;
      --primary-color: #3b82f6;
      --primary-dark: #2563eb;
      --border-color: #60a5fa;
      --light-bg: #f9fafb;
      --light-text: #1e293b;
    }

    * {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    body {
      font-family: 'Inter', sans-serif;
      background: var(--bg-color);
      color: var(--text-color);
      padding-top: 70px;
      transition: 0.3s;
    }

    body.light-mode {
      background: var(--light-bg);
      color: var(--light-text);
    }

    
    header {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 70px;
      background-color: rgba(15, 23, 42, 0.95);
      backdrop-filter: blur(6px);
      z-index: 1000;
    }

    body.light-mode header {
      background-color: rgba(249, 250, 251, 0.95);
    }

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  position: relative;
  padding: 0 1.5rem;
}

.logo {
  font-size: 1.88rem;
  font-weight: bold;
  color: var(--primary-color);
  margin-right: auto; 
}

    .theme-switch {
      position: absolute;
      right: 1.5rem;
      display: flex;
      align-items: center;
      gap: 0.5rem;
      color: inherit;
      user-select: none;
    }

    .switch {
      position: relative;
      display: inline-block;
      width: 40px;
      height: 22px;
    }
    .switch input {
      opacity: 0;
      width: 0;
      height: 0;
    }
    .slider {
      position: absolute;
      cursor: pointer;
      background-color: #ccc;
      border-radius: 34px;
      top: 0; left: 0;
      right: 0; bottom: 0;
      transition: .4s;
    }
    .slider:before {
      position: absolute;
      content: "";
      height: 16px;
      width: 16px;
      left: 3px;
      bottom: 3px;
      background-color: white;
      border-radius: 50%;
      transition: .4s;
    }
    input:checked + .slider {
      background-color: var(--primary-color);
    }
    input:checked + .slider:before {
      transform: translateX(18px);
    }

    
.container {
  max-width: 600px;      /* un peu plus étroit pour un contenu plus concentré */
  margin: 3rem auto;
    margin-top: 1rem;
  padding: 1rem 1rem;  /* légèrement moins de padding */
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  text-align: center;
  margin-bottom: 1rem; /* réduit un peu l'espace sous le texte */

}

.description {
  font-size: 1rem;       /* un peu plus petit */
  line-height: 1.6;      /* légèrement moins espacé */
  color: var(--desc-color);
  margin-bottom: 2rem;
  max-width: 580px;      /* un peu plus étroit */
  margin-left: auto;
  margin-right: auto;
  text-align: justify;
  margin-bottom: 1rem; /* réduit un peu l'espace sous le texte */
  line-height: 1.5;      /* compacte un peu la hauteur des lignes */
}
.bienvenue {
  display: block;
  text-align: center;
  margin-bottom: 1rem;
  font-size: 1.2rem; /* optionnel : ajuste la taille du titre */
  color: var(--primary-color, #3b82f6); /* ou la couleur que tu souhaites */
    margin-bottom: 0rem;
    font-weight: bold;
}


body.light-mode .description {
  color: #374151;
}

    .actions {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      gap: 1rem;
    }

    .btn {
      padding: 0.8rem 2rem;
      font-weight: 600;
      border-radius: 8px;
      text-decoration: none;
      transition: 0.3s ease;
    }

    .btn-connexion {
      background-color: var(--primary-color);
      color: white;
    }
    .btn-connexion:hover {
      background-color: var(--primary-dark);
    }

    .btn-inscription {
      border: 2px solid var(--primary-color);
      background-color: transparent;
      color: var(--primary-color);
    }
    .btn-inscription:hover {
      background-color: var(--primary-color);
      color: white;
    }

 
    @media (max-width: 600px) {
      .logo {
        font-size: 1.5rem;
      }

      .btn {
        width: 100%;
        max-width: 300px;
      }
    }




body.light-mode .offcanvas-body {
  background-color: #fff;
  color: #000;
}
body.light-mode .offcanvas-body .nav-link {
  color: #007bff; /* lien bleu */
}
body.light-mode .offcanvas-body .nav-link:hover {
  background-color: #f0f0f0;
  color: #0056b3; /* bleu plus foncé au survol */
}


body:not(.light-mode) .offcanvas-body {
  background-color: #1e293b;
  color: #e0e7ff;
}
body:not(.light-mode) .offcanvas-body .nav-link {
  color: #60a5fa; /* bleu clair */
}
body:not(.light-mode) .offcanvas-body .nav-link:hover {
  background-color: #374151;
  color: #93c5fd; /* bleu plus clair au survol */
}

/* SIDEBAR - clair */
body.light-mode .sidebar {
  background-color: #f8f9fa !important;
  color: #333 !important;
}
body.light-mode .sidebar .nav-link {
  color: #007bff; /* lien bleu */
  background-color: transparent;
  padding: 0.75rem 1.2rem;
  border-radius: 0;
  transition: background 0.2s, color 0.2s;
}

body.light-mode .sidebar .nav-link.active {
  background-color: #e9f2ff;             
  color: #0d6efd;                        
  font-weight: 600;
  border-radius: 8px;                    
  box-shadow:
    inset 2px 2px 4px rgba(255, 255, 255, 0.8),   
    inset -2px -2px 6px rgba(0, 0, 0, 0.1),        
    0 5px 15px rgba(13, 110, 253, 0.3);            
  transition: background 0.4s ease, box-shadow 0.4s ease, transform 0.3s ease;
  transform-style: preserve-3d;
  cursor: pointer;
}

body.light-mode .sidebar .nav-link.active:hover {
  background-color: #c9deff;             
  box-shadow:
    inset 3px 3px 6px rgba(255, 255, 255, 0.9),     
    inset -3px -3px 8px rgba(0, 0, 0, 0.12),       
    0 8px 20px rgba(13, 110, 253, 0.5);             
  transform: translateZ(3px) scale(1.03);          
}

body.light-mode .sidebar .nav-link {
  color: #0d6efd;                  
  border-radius: 6px;
  padding: 0.5rem 1rem;
  transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

body.light-mode .sidebar .nav-link:hover {
  background-color: #f0f5ff;      
  color: #0d6efd;                  
  box-shadow:
    0 4px 10px rgba(13, 110, 253, 0.15);   
  transform: translateX(5px);       
}

body:not(.light-mode) .sidebar {
  background-color: #1e293b !important;  /* fond sombre */
  color: #e0e7ff !important;
  border-right: 1px solid #374151;
}

/* On reprend le style animé du light mode, adapté en couleurs pour dark */
body:not(.light-mode) .sidebar .nav-link {
  color: #a0c4ff;                   /* bleu clair plus doux pour fond sombre */
  background-color: transparent;
  border-radius: 6px;
  padding: 0.5rem 1rem;
  transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

body:not(.light-mode) .sidebar .nav-link:hover {
  background-color: #2c3e70;        /* bleu foncé un peu plus clair que le fond */
  color: #82aaff;                   /* bleu vif clair */
  box-shadow: 0 4px 10px rgba(130, 170, 255, 0.3);
  transform: translateX(5px);
}

/* Style actif avec effet 3D du light mode mais adapté dark */
body:not(.light-mode) .sidebar .nav-link.active {
  background-color: #3a52a5;  /* bleu profond */
  color: #dce7ff;             /* texte clair */
  font-weight: 600;
  border-radius: 8px;
  box-shadow:
    inset 2px 2px 4px rgba(255, 255, 255, 0.3),
    inset -2px -2px 6px rgba(0, 0, 0, 0.5),
    0 5px 15px rgba(130, 170, 255, 0.5);
  transition: background 0.4s ease, box-shadow 0.4s ease, transform 0.3s ease;
  transform-style: preserve-3d;
  cursor: pointer;
}

body:not(.light-mode) .sidebar .nav-link.active:hover {
  background-color: #5374d4;  /* bleu un peu plus clair */
  box-shadow:
    inset 3px 3px 6px rgba(255, 255, 255, 0.4),
    inset -3px -3px 8px rgba(0, 0, 0, 0.6),
    0 8px 20px rgba(130, 170, 255, 0.7);
  transform: translateZ(3px) scale(1.03);
}



.sidebar .nav-tabs {
  flex-direction: column;
  border: none;
}
