/* ========================================
   NAVIGATION - STYLES
   ======================================== */

/* ========================================
   4. NAVIGATION PRINCIPALE - OPTIMISÉE
   ======================================== */

/* Container principal de la navigation */
.main-navigation {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: var(--navigation-background);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--navigation-border);
  z-index: 1000;
  padding: 1rem 2rem;
  transition: all 0.3s ease;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 2rem;
}

.navigation-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ========================================
   4.1 LOGO/MARQUE
   ======================================== */

.navigation-brand {
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.5vw, 12px);
  justify-self: start;
  height: clamp(36px, 6vh, 42px);
  min-height: clamp(36px, 6vh, 42px);
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--navigation-text);
  text-decoration: none;
}

.navigation-brand img,
.brand-logo {
  width: clamp(32px, 5vh, 42px);
  height: clamp(32px, 5vh, 42px);
  object-fit: contain;
  flex-shrink: 0;
}

.navigation-brand a,
.brand-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: inherit;
  gap: clamp(8px, 1.5vw, 12px);
}

.brand-text {
  color: var(--navigation-text);
  font-size: var(--font-size-lg);
  font-weight: 300;
  font-family: var(--font-family-primary);
  letter-spacing: clamp(0.5px, 0.1vw, 0.8px);
  transition: color 0.6s ease;
  white-space: nowrap;
  margin: 0;
  line-height: 1;
  display: flex;
  align-items: center;
  height: 100%;
}

/* ========================================
   4.2 MENU DE NAVIGATION
   ======================================== */

.navigation-menu {
  display: flex;
  align-items: center;
  gap: clamp(1.5rem, 3vw, 2.5rem);
  justify-self: center;
  height: auto;
  margin-left: clamp(1rem, 3vw, 2rem);
  margin-right: clamp(1rem, 3vw, 2rem);
}

/* Navigation desktop - masquer les liens directs des opérations */
.navigation-link.mobile-ops {
  display: none !important;
}

.navigation-link {
  color: var(--navigation-text);
  text-decoration: none;
  font-size: var(--font-size-nav);
  font-weight: 400;
  font-family: var(--font-family-primary);
  padding: clamp(0.3rem, 1vh, 0.5rem) 0;
  position: relative;
  letter-spacing: clamp(0.2px, 0.05vw, 0.3px);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
  display: flex;
  align-items: center;
  height: clamp(36px, 6vh, 42px);
}

.navigation-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--navigation-text);
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.navigation-link:hover::after {
  width: 100%;
}

.navigation-link:hover {
  color: var(--accent-color);
  transform: translateY(-1px);
}

/* ========================================
   4.3 CONTRÔLES DE NAVIGATION
   ======================================== */

.navigation-controls {
  display: flex;
  align-items: center;
  gap: clamp(0.6rem, 1.2vw, 1rem);
  justify-self: end;
  height: 100%;
  min-height: clamp(36px, 6vh, 42px);
  margin-right: clamp(1rem, 2vw, 2rem);
}

/* Styles communs pour tous les boutons circulaires */
.language-switcher {
  width: clamp(36px, 6vh, 42px);
  height: clamp(36px, 6vh, 42px);
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.1);
  border: 1px solid rgba(15, 23, 42, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.language-switcher:hover {
  background: rgba(14, 165, 233, 0.1);
  border-color: rgba(14, 165, 233, 0.3);
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.2);
}


/* ========================================
   4.5 BOUTONS SPÉCIALISÉS
   ======================================== */



/* Bouton langue */
.language-text {
  font-size: var(--font-size-xs);
  font-weight: 600;
  color: var(--navigation-text);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  line-height: 1;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Remove hover rotation/blur on language */
.language-switcher:hover .language-text {
  transform: none;
  color: var(--navigation-text);
  font-weight: 600;
}

/* Mobile burger button */
.mobile-menu-button {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.burger-line {
  width: 24px;
  height: 2px;
  background: var(--navigation-text);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-menu-button.active .burger-line:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.mobile-menu-button.active .burger-line:nth-child(2) { opacity: 0; }
.mobile-menu-button.active .burger-line:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* Mobile panel */
.mobile-nav-panel {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.98);
  backdrop-filter: blur(18px);
  transform: translateY(-100%);
  transition: transform 0.35s ease;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  color: #ffffff;
}

.mobile-nav-panel.open { transform: translateY(0); }
.mobile-nav-header { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.25rem; border-bottom: 1px solid rgba(255,255,255,0.1); }
.mobile-close { background: transparent; border: 1px solid rgba(255,255,255,0.35); color: #fff; border-radius: 10px; width: 40px; height: 40px; cursor: pointer; }
.mobile-brand { display: flex; align-items: center; gap: 0.5rem; color: #fff; }
.mobile-brand .brand-text { font-size: 0.95rem; opacity: 0.9; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #fff; }
.mobile-nav-body { overflow-y: auto; padding: 1.25rem; }
.mobile-lang { display: flex; gap: 0.75rem; margin-bottom: 0.9rem; justify-content: center; }
.mobile-lang-link { display: inline-block; padding: 0.42rem 0.7rem; border: 1px solid rgba(255,255,255,0.28); border-radius: 999px; color: #fff; text-decoration: none; font-weight: 700; font-size: 0.86rem; background: rgba(255,255,255,0.12); }
.mobile-lang-link:hover { background: rgba(255,255,255,0.2); border-color: rgba(255,255,255,0.34); }
.mobile-nav-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.mobile-link { display: block; padding: 0.95rem 1.1rem; color: #fff; text-decoration: none; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.18); border-radius: 12px; font-size: 1rem; line-height: 1.4; font-weight: 500; }
.mobile-group-toggle { width: 100%; text-align: left; padding: 0.95rem 1.1rem; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.18); border-radius: 12px; color: #fff; cursor: pointer; font-weight: 600; }
.mobile-sublist { list-style: none; margin: 0.25rem 0 0.5rem 0; padding-left: 0; display: none; }
.mobile-group.open .mobile-sublist { display: block; }
.mobile-sublink { display: block; padding: 0.75rem 1rem 0.75rem 1.25rem; color: #fff; text-decoration: none; opacity: 0.95; font-size: 0.95rem; line-height: 1.4; border-left: 2px solid rgba(255,255,255,0.15); margin-left: 0.25rem; }
.mobile-link:hover, .mobile-sublink:hover, .mobile-group-toggle:hover { background: rgba(255,255,255,0.14); border-color: rgba(255,255,255,0.24); color: #fff; }

/* Bouton CTA navbar */
.appointment-button {
  background: linear-gradient(135deg, var(--accent-color) 0%, var(--accent-color-hover) 100%);
  color: #ffffff;
  font-size: var(--font-size-button);
  font-weight: 600;
  text-decoration: none;
  border-radius: 50px;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
  box-shadow: 0 8px 24px rgba(14, 165, 233, 0.25);
  border: none;
  position: relative;
  overflow: hidden;
  letter-spacing: 0.5px;
  height: clamp(36px, 6vh, 42px);
  padding: 0 clamp(20px, 3.5vw, 32px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 1;
  margin: 0;
  vertical-align: middle;
  font-family: inherit;
  align-self: center;
}

.appointment-button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.8s ease;
  z-index: 1;
}

.appointment-button:hover::before {
  left: 100%;
}

.appointment-button:hover {
  background: linear-gradient(135deg, var(--accent-color-hover) 0%, var(--accent-color) 100%);
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 12px 32px rgba(14, 165, 233, 0.4);
  color: #ffffff;
}

/* ========================================
   4.6 MENU DÉROULANT DES OPÉRATIONS
   ======================================== */
/* 
   Les styles du dropdown ont été déplacés dans dropdown.css
   pour éviter les conflits avec Bootstrap et faciliter la maintenance.
   Voir assets/css/dropdown.css pour les styles complets.
*/

 

/* ========================================
   5.2 RESPONSIVE PRINCIPAL
   ======================================== */

/* MOBILE (jusqu'à 768px) */
@media (max-width: 480px) {
  .main-navigation {
    padding: 0.8rem 1rem;
    min-height: 56px;
  }
  
  .navigation-brand img {
    width: 28px;
    height: 28px;
  }
  
  .brand-text {
    font-size: 1rem;
    display: block;
  }
  
  .navigation-controls {
    gap: 0.5rem;
  }
  
  
}

@media (max-width: 768px) {
  .main-navigation {
    display: flex;
    justify-content: space-between;
    padding: clamp(0.8rem, 2vw, 1.2rem) clamp(1rem, 3vw, 1.5rem);
    min-height: clamp(56px, 10vh, 65px);
    gap: 0;
  }
  .mobile-menu-button { display: flex; margin-left: auto; order: 3; }
  .navigation-brand { order: 1; }
  .navigation-controls { display: none; }
  .mobile-brand .brand-logo { width: 28px; height: 28px; }
  
  .navigation-brand {
    gap: clamp(6px, 2vw, 10px);
    justify-self: auto;
    height: clamp(32px, 8vh, 36px);
    min-height: clamp(32px, 8vh, 36px);
  }
  
  .brand-text {
    display: none;
  }
  
  .navigation-menu { display: none; }
  
  .navigation-link {
    font-size: var(--font-size-lg);
    padding: clamp(0.8rem, 2vh, 1.2rem) clamp(1.5rem, 4vw, 2rem);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff;
    text-align: center;
    min-width: clamp(180px, 40vw, 220px);
    transform: translateY(20px);
    opacity: 0; /* hidden by default; shown when menu active */
    transition: all 0.4s ease;
    height: auto;
  }

  /* Ensure all menu items become visible when the menu opens (works for nested links too) */
  .navigation-menu.active .navigation-link,
  .navigation-menu.active .nav-dropdown-toggle {
    opacity: 1 !important;
    transform: translateY(0) !important;
  }
  
  .navigation-controls {
    gap: clamp(0.5rem, 1.5vw, 0.8rem);
    justify-self: auto;
    height: clamp(32px, 8vh, 36px);
    min-height: clamp(32px, 8vh, 36px);
    margin-right: clamp(0.5rem, 1.5vw, 1rem);
  }
  
  .appointment-button {
    display: none;
  }
}

/* TABLETTE ET DESKTOP */
@media (min-width: 769px) {
  
  /* Hide mobile submenu panel on desktop */
  .mobile-submenu-panel {
    display: none !important;
  }
  
  .main-navigation {
    display: grid !important;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
  }
  
  .navigation-menu {
    justify-self: center;
    display: flex !important;
    flex-direction: row;
    align-items: center;
    gap: clamp(1.5rem, 3vw, 2.5rem);
    height: auto;
    width: auto;
    background: none;
    backdrop-filter: none;
    padding: 0;
    position: static;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
  
  .navigation-link {
    color: var(--navigation-text);
    font-size: var(--font-size-nav);
    font-weight: 400;
    padding: clamp(0.3rem, 1vh, 0.5rem) 0;
    background: none;
    border: none;
    min-width: auto;
    text-align: left;
    opacity: 1;
    transform: none;
  }
  
/* 
   Les styles de persistance du dropdown ont été déplacés dans dropdown.css
   pour éviter les conflits avec Bootstrap et faciliter la maintenance.
*/
}

/* TABLETTE SPÉCIFIQUE */
@media (min-width: 769px) and (max-width: 1024px) {
  .main-navigation {
    padding: clamp(0.8rem, 1.5vw, 1rem) clamp(1.5rem, 3vw, 2rem);
  }
  
  .navigation-menu {
    gap: clamp(1.8rem, 2.5vw, 2.2rem);
  }
  
  .navigation-link {
    font-size: var(--font-size-nav);
  }
  
  .appointment-button {
    font-size: var(--font-size-button);
    padding: 0 clamp(18px, 2.8vw, 24px);
    height: clamp(36px, 6vh, 40px);
  }
}

/* DESKTOP STANDARD */
@media (min-width: 1025px) and (max-width: 1440px) {
  .main-navigation {
    padding: 1rem clamp(2rem, 4vw, 3rem);
  }
  
  .navigation-menu {
    gap: clamp(2rem, 2.8vw, 2.5rem);
  }
}

/* GRAND ÉCRAN */
@media (min-width: 1441px) {
  .main-navigation {
    padding: 1.2rem clamp(3rem, 5vw, 4rem);
    width: 100%;
    max-width: none;
    margin: 0;
    left: 0;
    transform: none;
  }
  
  .navigation-menu {
    gap: 2.8rem;
  }
  
  .navigation-link {
    font-size: var(--font-size-nav);
  }
}

/* ========================================
   6. ANIMATIONS ET EFFETS
   ======================================== */

/* Animation de glissement pour la navigation cachée */
.main-navigation.navbar-hidden {
  transform: translateY(-100%);
  opacity: 0.9;
}

/* (Section 7 mobile menu corrections removed as mobile menu was deleted) */