/* ========================================
   CSS MOBILE POUR PAGES LÉGALES
   À ajouter dans cgv.html, mentions-legales.html,
   politique-confidentialite.html, etc.
   ======================================== */

/* ========== MENU BURGER - EXACT SAME AS INDEX.HTML ========== */

/* Bouton burger - visible uniquement sur mobile */
.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  background: none;
  border: none;
}

.mobile-menu-toggle span {
  width: 25px;
  height: 3px;
  background: linear-gradient(135deg, #8b5cf6, #6366f1);
  border-radius: 3px;
  transition: all 0.3s;
  box-shadow: 0 0 10px rgba(139, 92, 246, 0.5);
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translateY(10px);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translateY(-10px);
}

/* Menu mobile */
.mobile-menu {
  display: none;
  position: fixed;
  top: 68px;
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.98);
  backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 2px solid rgba(139, 92, 246, 0.3);
  z-index: 1000;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.mobile-menu.active {
  max-height: 80vh;
  overflow-y: auto;
}

.mobile-menu::-webkit-scrollbar {
  width: 6px;
}

.mobile-menu::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.5);
}

.mobile-menu::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, #8b5cf6, #6366f1);
  border-radius: 3px;
  box-shadow: 0 0 10px rgba(139, 92, 246, 0.5);
}

.mobile-menu ul {
  list-style: none;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.mobile-menu ul li a {
  display: block;
  padding: 12px;
  border-radius: 8px;
  transition: all 0.3s;
}

.mobile-menu ul li a:hover {
  background: linear-gradient(90deg, rgba(139, 92, 246, 0.15), rgba(99, 102, 241, 0.15));
  transform: translateX(5px);
  border-left: 3px solid #8b5cf6;
}

/* Mobile Responsive - Pages Légales */
@media (max-width: 768px) {
  /* Cache le menu desktop sur mobile */
  nav ul {
    display: none !important;
  }

  /* Afficher le bouton burger */
  .mobile-menu-toggle {
    display: flex;
  }

  /* Afficher le menu mobile */
  .mobile-menu {
    display: block;
  }

  /* Cache aussi le bouton Commander du nav desktop sur mobile */
  .nav > .btn.primary {
    display: none !important;
  }
  /* Body & Container */
  body {
    padding: 0 !important;
    font-size: 15px !important;
    line-height: 1.7 !important;
  }

  .container {
    max-width: 100% !important;
    padding: 15px !important;
    margin: 0 !important;
  }

  /* Header */
  header,
  .header {
    padding: 15px !important;
  }

  .brand,
  .logo {
    font-size: 20px !important;
  }

  /* Titres */
  h1 {
    font-size: 26px !important;
    line-height: 1.3 !important;
    margin: 20px 0 15px 0 !important;
    word-wrap: break-word !important;
  }

  h2 {
    font-size: 20px !important;
    line-height: 1.4 !important;
    margin: 25px 0 12px 0 !important;
  }

  h3 {
    font-size: 18px !important;
    line-height: 1.4 !important;
    margin: 20px 0 10px 0 !important;
  }

  h4 {
    font-size: 16px !important;
    margin: 15px 0 8px 0 !important;
  }

  /* Paragraphes */
  p {
    font-size: 14px !important;
    line-height: 1.7 !important;
    margin-bottom: 15px !important;
    text-align: justify !important;
  }

  /* Listes */
  ul, ol {
    padding-left: 20px !important;
    margin: 15px 0 !important;
  }

  li {
    font-size: 14px !important;
    line-height: 1.7 !important;
    margin-bottom: 10px !important;
  }

  /* Cards/Sections */
  .card,
  .section,
  article {
    padding: 20px 15px !important;
    margin: 15px 0 !important;
    border-radius: 10px !important;
  }

  /* Tables */
  table {
    display: block !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    font-size: 13px !important;
  }

  th, td {
    padding: 8px !important;
    font-size: 13px !important;
  }

  /* Links */
  a {
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
  }

  /* Buttons */
  .btn,
  button {
    width: 100% !important;
    padding: 12px !important;
    font-size: 14px !important;
    margin: 10px 0 !important;
  }

  /* Footer */
  footer {
    padding: 20px 15px !important;
  }

  footer .foot {
    flex-direction: column !important;
    gap: 20px !important;
  }

  footer h4 {
    font-size: 16px !important;
    margin-bottom: 10px !important;
  }

  footer ul {
    padding-left: 0 !important;
  }

  footer li {
    font-size: 13px !important;
    margin-bottom: 8px !important;
  }

  /* Navigation */
  nav {
    flex-direction: column !important;
    gap: 10px !important;
  }

  nav a {
    padding: 10px !important;
    font-size: 14px !important;
  }

  /* Images */
  img {
    max-width: 100% !important;
    height: auto !important;
  }

  /* Text Content */
  .text-content,
  .content {
    padding: 15px !important;
  }

  /* Boxes avec bordures */
  .box,
  .notice,
  .alert {
    padding: 15px !important;
    margin: 15px 0 !important;
    font-size: 14px !important;
  }

  /* Spacing */
  .muted {
    font-size: 13px !important;
  }

  /* Prevent horizontal scroll */
  * {
    max-width: 100% !important;
    overflow-wrap: break-word !important;
  }

  html, body {
    overflow-x: hidden !important;
  }

  /* Strong/Bold text */
  strong, b {
    font-weight: 600 !important;
  }

  /* Code blocks */
  code, pre {
    font-size: 12px !important;
    overflow-x: auto !important;
    display: block !important;
    padding: 10px !important;
  }

  /* Blockquotes */
  blockquote {
    padding: 10px 15px !important;
    margin: 15px 0 !important;
    font-size: 14px !important;
    border-left-width: 3px !important;
  }

  /* Article spacing */
  article + article {
    margin-top: 30px !important;
  }

  /* Last updated date */
  .last-updated,
  .date {
    font-size: 12px !important;
  }

  /* Contact info */
  .contact-info {
    font-size: 14px !important;
    line-height: 1.8 !important;
  }

  /* Hide desktop-only elements */
  .desktop-only {
    display: none !important;
  }

  /* Show mobile-only elements */
  .mobile-only {
    display: block !important;
  }
}

/* Very small screens (< 480px) */
@media (max-width: 480px) {
  h1 {
    font-size: 22px !important;
  }

  h2 {
    font-size: 18px !important;
  }

  h3 {
    font-size: 16px !important;
  }

  p, li {
    font-size: 13px !important;
  }

  .container {
    padding: 10px !important;
  }

  .card,
  .section {
    padding: 15px 10px !important;
  }
}

/* Landscape mode mobile */
@media (max-width: 896px) and (orientation: landscape) {
  body {
    font-size: 14px !important;
  }

  h1 {
    font-size: 24px !important;
  }

  h2 {
    font-size: 19px !important;
  }
}
