/* Navigation moderne et cohérente - SIA */
.topnav { 
  position: sticky; 
  top: 0; 
  z-index: 1020; 
  background: #0A0E1A; 
  backdrop-filter: blur(12px) saturate(180%); 
  border-bottom: 1px solid #1A1F2E; 
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.topnav-inner { 
  max-width: 1200px; 
  margin: 0 auto; 
  padding: 12px 24px; 
  display: flex; 
  align-items: center; 
  gap: 16px; 
  min-height: 80px;
}

.brand { 
  display: flex; 
  align-items: flex-start; 
  gap: 14px; 
  font-weight: 700; 
  font-size: 1.125rem; 
  color: #E6EBF0; 
  transition: opacity 0.2s;
  padding-top: 2px;
}

.brand:hover {
  opacity: 1;
}

.brand .logo { 
  width: auto; 
  height: 6rem; 
  aspect-ratio: 1;
  background: transparent;
  border: none;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 
    0 0 24px rgba(91, 111, 138, 0.2);
}

.brand .logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.brand .title { 
  font-weight: 700; 
  letter-spacing: 0.01em; 
  line-height: 1.2;
  display: flex;
  flex-direction: column;
}

.topnav a { 
  text-decoration: none; 
  color: #5B6F8A; 
  padding: 8px 16px; 
  border-radius: 9999px; 
  font-size: 0.875rem; 
  font-weight: 500; 
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid transparent;
}

.topnav a:hover { 
  background: rgba(91, 111, 138, 0.1); 
  border-color: #5B6F8A;
  color: #E6EBF0;
}

.topnav a.active { 
  background: #5B6F8A; 
  color: #E6EBF0; 
  font-weight: 600;
  box-shadow: 0 2px 4px rgba(91, 111, 138, 0.2);
}

/* ============================================
   SECTION HÉRO AVEC GRAND LOGO SIA
   Utilisable sur les pages principales
   ============================================ */

.sia-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 1.5rem;
  background: linear-gradient(135deg, #0A0E1A 0%, #1A1F2E 50%, #0A0E1A 100%);
  border-radius: 16px;
  margin-bottom: 1.5rem;
  position: relative;
  overflow: hidden;
}

/* Effet de particules subtil en arrière-plan */
.sia-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 80%, rgba(199, 163, 94, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(91, 111, 138, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.sia-hero-logo {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(199, 163, 94, 0.1);
  border: 3px solid #c7a35e;
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 
    0 0 30px rgba(199, 163, 94, 0.4),
    0 0 60px rgba(91, 111, 138, 0.25),
    inset 0 0 20px rgba(199, 163, 94, 0.1);
  animation: hero-logo-glow 4s ease-in-out infinite;
  position: relative;
  z-index: 1;
}

@keyframes hero-logo-glow {
  0%, 100% { 
    box-shadow: 
      0 0 30px rgba(199, 163, 94, 0.4),
      0 0 60px rgba(91, 111, 138, 0.25),
      inset 0 0 20px rgba(199, 163, 94, 0.1);
    transform: scale(1);
  }
  50% { 
    box-shadow: 
      0 0 40px rgba(199, 163, 94, 0.6),
      0 0 80px rgba(91, 111, 138, 0.35),
      inset 0 0 30px rgba(199, 163, 94, 0.15);
    transform: scale(1.02);
  }
}

.sia-hero-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3));
}

.sia-hero-title {
  margin-top: 1.25rem;
  font-size: 1.75rem;
  font-weight: 700;
  color: #E6EBF0;
  text-align: center;
  letter-spacing: 0.02em;
  position: relative;
  z-index: 1;
}

.sia-hero-subtitle {
  margin-top: 0.5rem;
  font-size: 1rem;
  color: #5B6F8A;
  text-align: center;
  font-weight: 500;
  position: relative;
  z-index: 1;
}

.sia-hero-tagline {
  margin-top: 0.75rem;
  font-size: 0.85rem;
  color: #c7a35e;
  text-align: center;
  font-style: italic;
  letter-spacing: 0.05em;
  position: relative;
  z-index: 1;
}

/* Animation d'entrée au chargement */
@keyframes hero-fade-in {
  0% {
    opacity: 0;
    transform: translateY(-20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.sia-hero-logo {
  animation: hero-fade-in 0.6s ease-out, hero-logo-glow 4s ease-in-out infinite 0.6s;
}

.sia-hero-title {
  animation: hero-fade-in 0.6s ease-out 0.2s both;
}

.sia-hero-subtitle {
  animation: hero-fade-in 0.6s ease-out 0.3s both;
}

.sia-hero-tagline {
  animation: hero-fade-in 0.6s ease-out 0.4s both;
}

/* ============================================
   NAVIGATION LIENS CONTAINER
   ============================================ */

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ============================================
   BOUTON BURGER (caché par défaut sur desktop)
   ============================================ */

.burger-menu {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 20px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1030;
}

.burger-bar {
  display: block;
  width: 100%;
  height: 3px;
  background: #E6EBF0;
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Animation du burger en X quand ouvert */
.burger-menu.open .burger-bar:nth-child(1) {
  transform: translateY(8.5px) rotate(45deg);
}

.burger-menu.open .burger-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.burger-menu.open .burger-bar:nth-child(3) {
  transform: translateY(-8.5px) rotate(-45deg);
}

/* ============================================
   MEDIA QUERIES - RESPONSIVE MOBILE
   ============================================ */

/* Tablette et mobile (≤ 768px) */
@media (max-width: 768px) {
  .topnav-inner {
    padding: 10px 16px;
    min-height: 56px;
    gap: 8px;
    flex-wrap: nowrap;              /* Force la barre sur une seule ligne */
    justify-content: space-between; /* Logo à gauche, burger à droite */
  }

  .brand {
    max-width: calc(100% - 60px);   /* Laisse toujours la place pour le burger */
    min-width: 0;
  }
  
  .brand .logo {
    height: 3.5rem;
  }
  
  .brand .title {
    font-size: 0.9rem;
  }
  
  /* Afficher le bouton burger */
  .burger-menu {
    display: flex;
  }
  
  /* Menu de navigation mobile : panneau déroulant sous la barre */
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #0A0E1A;
    border-top: 1px solid #1A1F2E;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
    padding: 12px 0 16px;
    gap: 4px;
    z-index: 1030;
  }
  
  .nav-links.open {
    display: flex;
  }
  
  .nav-links a {
    width: 100%;
    padding: 12px 20px;
    border-radius: 8px;
    text-align: left;
    font-size: 1rem;
  }
  
  .nav-links a:hover {
    background: rgba(91, 111, 138, 0.15);
  }
  
  .nav-links a.active {
    background: #5B6F8A;
  }
}

/* Petit mobile (≤ 480px) */
@media (max-width: 480px) {
  .topnav-inner {
    padding: 8px 12px;
  }
  
  .brand .logo {
    height: 3rem;
  }
  
  .brand .title {
    font-size: 0.8rem;
  }
  
  .brand .title small {
    display: none;
  }
  
  .nav-links a {
    padding: 14px 16px;
    font-size: 0.95rem;
  }
}
