/**
 * Navigation System Styles
 * Boutons de navigation, transitions, cartes de section
 */

/* Container des boutons de navigation */
.navigation-buttons-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 1000;
  opacity: 0.6;
  transform: translateY(0);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Afficher les boutons au survol ou si le slide a un parentId (sous-slide) */
.slide-container:hover .navigation-buttons-container,
.slide-container:focus-within .navigation-buttons-container,
.slide.active .navigation-buttons-container {
  opacity: 1;
  transform: translateY(0);
}

/* Boutons de navigation */
.nav-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(220, 38, 38, 0.15);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  color: #DC2626;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  font-family: 'Montserrat', sans-serif;
  min-width: auto;
  justify-content: flex-start;
}

.nav-btn:hover {
  background: rgba(220, 38, 38, 0.95);
  color: white;
  transform: translateX(-2px);
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.25);
  opacity: 1;
}

.nav-btn:active {
  transform: translateX(-1px);
}

.nav-btn svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.nav-btn span {
  white-space: nowrap;
}

/* Variantes de boutons */
.nav-btn-global {
  border-color: rgba(220, 38, 38, 0.3);
}

.nav-btn-section {
  border-color: rgba(5, 150, 105, 0.3);
  color: #059669;
}

.nav-btn-section:hover {
  background: #059669;
  color: white;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.3);
}

.nav-btn-parent {
  border-color: rgba(37, 99, 235, 0.2);
  color: #2563EB;
  background: rgba(255, 255, 255, 0.85);
}

.nav-btn-parent:hover {
  background: rgba(37, 99, 235, 0.95);
  color: white;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}

/* Slide de navigation globale - DOIT ÊTRE UNE SLIDE NORMALE */
.slide-navigation-global {
  /* Pas de display: flex ici, c'est géré par .slide.active */
  padding: 80px 60px;
  min-height: 100vh;
  background: #ffffff;
}

.navigation-global-content {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

.navigation-global-title {
  font-size: 42px;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 12px;
  text-align: center;
  font-family: 'Montserrat', sans-serif;
  letter-spacing: -0.5px;
}

.navigation-global-subtitle {
  font-size: 18px;
  color: #64748b;
  margin-bottom: 48px;
  text-align: center;
  font-family: 'Open Sans', sans-serif;
  font-weight: 400;
}

.navigation-sections-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  width: 100%;
  padding: 0;
}

.section-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 28px;
  cursor: pointer;
  transition: all 0.25s ease;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  position: relative;
  overflow: hidden;
}

.section-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--section-color, #DC2626);
  transform: scaleY(0);
  transition: transform 0.25s ease;
}

.section-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  border-color: var(--section-color, #DC2626);
}

.section-card:hover::before {
  transform: scaleY(1);
}

.section-card-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 16px;
  color: var(--section-color, #DC2626);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(220, 38, 38, 0.08);
  border-radius: 10px;
}

.section-card-icon .lucide-icon {
  width: 22px;
  height: 22px;
  color: var(--section-color, #DC2626);
}

.section-card-title {
  font-size: 20px;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 8px;
  font-family: 'Montserrat', sans-serif;
  letter-spacing: -0.3px;
}

.section-card-description {
  font-size: 14px;
  color: #64748b;
  margin-bottom: 16px;
  line-height: 1.5;
  font-family: 'Open Sans', sans-serif;
}

.section-card-stats {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #94a3b8;
  font-weight: 600;
  font-family: 'Montserrat', sans-serif;
}

.section-card-stats .lucide-icon {
  width: 14px;
  height: 14px;
  color: #94a3b8;
}

/* Slide de sommaire de section - DOIT ÊTRE UNE SLIDE NORMALE */
.slide-navigation-section {
  /* Pas de display: flex ici, c'est géré par .slide.active */
  padding: 80px 60px;
  min-height: 100vh;
  background: #ffffff;
}

.navigation-section-content {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

.navigation-section-title {
  font-size: 40px;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 12px;
  text-align: center;
  font-family: 'Montserrat', sans-serif;
}

.navigation-section-subtitle {
  font-size: 18px;
  color: #64748b;
  margin-bottom: 40px;
  text-align: center;
  font-family: 'Open Sans', sans-serif;
}

.navigation-slides-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  width: 100%;
  padding: 0;
}

.slide-card {
  background: #ffffff;
  border-radius: 10px;
  padding: 20px;
  cursor: pointer;
  transition: all 0.25s ease;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.slide-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  border-color: #DC2626;
}

.slide-card-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-surface-elevated, #f8fafc);
  border-radius: var(--radius-md);
  margin-bottom: var(--spacing-md);
  border: 2px solid var(--somef-primary, #d22741);
  color: var(--somef-primary, #d22741);
}

.slide-card-icon i {
  width: 24px;
  height: 24px;
  stroke-width: 2;
}

.slide-card-id {
  font-size: 11px;
  font-weight: 600;
  color: #DC2626;
  margin-bottom: 8px;
  font-family: 'Montserrat', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.slide-card-title {
  font-size: 17px;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 6px;
  font-family: 'Montserrat', sans-serif;
  letter-spacing: -0.2px;
}

.slide-card-description {
  font-size: 13px;
  color: #64748b;
  line-height: 1.5;
  font-family: 'Open Sans', sans-serif;
}

/* Transitions de section */
.section-transition {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--section-color, #DC2626);
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.section-transition.active {
  opacity: 1;
  pointer-events: all;
}

.section-transition-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  color: white;
}

.section-transition-title {
  font-size: 48px;
  font-weight: 800;
  margin-bottom: 16px;
  font-family: 'Montserrat', sans-serif;
}

.section-transition-subtitle {
  font-size: 24px;
  font-weight: 400;
  opacity: 0.9;
  font-family: 'Open Sans', sans-serif;
}

/* Responsive */
@media (max-width: 768px) {
  .navigation-buttons-container {
    bottom: 60px;
    right: 10px;
    gap: 8px;
  }
}

/* Styles pour le sommaire global (agenda transformé) - Charte SOMEF */
.global-navigation-sections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: var(--spacing-md, 16px);
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: var(--spacing-sm, 12px) var(--spacing-lg, 24px);
  box-sizing: border-box;
}

.global-section-card {
  background: #ffffff;
  border-radius: var(--radius-md, 12px);
  padding: var(--spacing-lg, 20px);
  cursor: pointer;
  transition: all var(--transition-base, 0.3s ease);
  border: 1px solid #e2e8f0;
  box-shadow: var(--elevation-2, 0 2px 4px rgba(0, 0, 0, 0.06));
  position: relative;
  overflow: hidden;
}

.global-section-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: var(--somef-primary, #d22741);
  transform: scaleY(0);
  transition: transform var(--transition-base, 0.3s ease);
}

.global-section-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--elevation-4, 0 8px 16px rgba(0, 0, 0, 0.1));
  border-color: var(--somef-primary, #d22741);
}

.global-section-card:hover::before {
  transform: scaleY(1);
}

.global-section-card-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-md, 16px);
}

.global-section-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md, 12px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(210, 39, 65, 0.08);
  border: 1px solid rgba(210, 39, 65, 0.15);
  transition: all var(--transition-base, 0.3s ease);
}

.global-section-card:hover .global-section-icon {
  background: rgba(210, 39, 65, 0.12);
  border-color: var(--somef-primary, #d22741);
  transform: scale(1.05);
}

.global-section-icon i {
  width: 24px;
  height: 24px;
  color: var(--somef-primary, #d22741);
}

.global-section-info {
  flex: 1;
  min-width: 0;
}

.global-section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--somef-primary, #d22741);
  margin: 0 0 var(--spacing-xs, 6px) 0;
  font-family: 'Montserrat', sans-serif;
  line-height: 1.3;
}

.global-section-description {
  font-size: 14px;
  color: #64748b;
  margin: 0;
  line-height: 1.5;
  font-family: 'Open Sans', sans-serif;
}

.global-section-arrow {
  color: #94a3b8;
  transition: all var(--transition-base, 0.3s ease);
  flex-shrink: 0;
}

.global-section-arrow i {
  width: 20px;
  height: 20px;
}

.global-section-card:hover .global-section-arrow {
  color: var(--somef-primary, #d22741);
  transform: translateX(4px);
}

.global-agenda-section {
  width: 100%;
  max-width: 100%;
  margin: var(--spacing-xl, 40px) 0 0;
  padding-top: var(--spacing-xl, 40px);
  padding-left: var(--spacing-lg, 24px);
  padding-right: var(--spacing-lg, 24px);
  border-top: 2px solid #e2e8f0;
  box-sizing: border-box;
}

.global-agenda-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--somef-primary, #d22741);
  margin: 0 0 var(--spacing-lg, 24px) 0;
  font-family: 'Montserrat', sans-serif;
  display: flex;
  align-items: center;
  gap: var(--spacing-sm, 12px);
}

.global-agenda-title i {
  width: 24px;
  height: 24px;
  color: var(--somef-primary, #d22741);
}

/* Exception pour le slide agenda : utiliser toute la largeur */
.slide[data-slide-type="agenda"],
.slide.slide-agenda-fullwidth,
.slide:has(.agenda-timeline) {
  max-width: 100% !important;
  width: 100% !important;
}

.slide[data-slide-type="agenda"] .slide-content,
.slide.slide-agenda-fullwidth .slide-content,
.slide:has(.agenda-timeline) .slide-content {
  width: 100%;
  max-width: 100%;
  padding-left: 0;
  padding-right: 0;
}

/* Agenda - Accordéon vertical */
.agenda-accordion {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm, 12px);
  margin-top: var(--spacing-lg, 24px);
  width: 100%;
  max-width: 100%;
  margin-left: 0;
  margin-right: 0;
}

.agenda-accordion-item {
  background: #ffffff;
  border-radius: var(--radius-md, 12px);
  border: 1px solid #e2e8f0;
  box-shadow: var(--elevation-2, 0 2px 4px rgba(0, 0, 0, 0.06));
  overflow: hidden;
  transition: all var(--transition-base, 0.3s ease);
}

.agenda-accordion-item:hover {
  box-shadow: var(--elevation-3, 0 4px 8px rgba(0, 0, 0, 0.08));
  border-color: rgba(210, 39, 65, 0.3);
}

.agenda-accordion-item.active {
  border-color: var(--somef-primary, #d22741);
  box-shadow: var(--elevation-4, 0 8px 16px rgba(0, 0, 0, 0.1));
}

.agenda-accordion-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-md, 16px) var(--spacing-lg, 20px);
  cursor: pointer;
  user-select: none;
  transition: background-color var(--transition-base, 0.2s ease);
}

.agenda-accordion-header:hover {
  background-color: rgba(210, 39, 65, 0.02);
}

.agenda-accordion-header-left {
  display: flex;
  align-items: center;
  gap: var(--spacing-md, 16px);
  flex: 1;
  min-width: 0;
}

.agenda-accordion-number {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--somef-primary, #d22741);
  color: white;
  border-radius: 50%;
  font-weight: 700;
  font-size: 16px;
  font-family: 'Montserrat', sans-serif;
  flex-shrink: 0;
}

.agenda-accordion-icon-wrapper {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(210, 39, 65, 0.08);
  border: 1px solid rgba(210, 39, 65, 0.15);
  border-radius: var(--radius-md, 10px);
  flex-shrink: 0;
}

.agenda-accordion-icon {
  width: 24px;
  height: 24px;
  color: var(--somef-primary, #d22741);
}

.agenda-accordion-title-wrapper {
  flex: 1;
  min-width: 0;
}

.agenda-accordion-title {
  font-family: 'Montserrat', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--somef-primary, #d22741);
  margin: 0 0 var(--spacing-xs, 4px) 0;
  line-height: 1.3;
}

.agenda-accordion-duration {
  display: inline-block;
  background: rgba(210, 39, 65, 0.08);
  color: var(--somef-primary, #d22741);
  padding: 3px var(--spacing-sm, 10px);
  border-radius: 10px;
  font-size: 12px;
  font-weight: 600;
  font-family: 'Open Sans', sans-serif;
}

.agenda-accordion-arrow {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--somef-primary, #d22741);
  transition: transform var(--transition-base, 0.3s ease);
  flex-shrink: 0;
}

.agenda-accordion-arrow i {
  width: 20px;
  height: 20px;
}

.agenda-accordion-item.active .agenda-accordion-arrow {
  transform: rotate(180deg);
}

.agenda-accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-base, 0.3s ease), padding var(--transition-base, 0.3s ease);
  padding: 0 var(--spacing-lg, 20px);
}

.agenda-accordion-item.active .agenda-accordion-content {
  max-height: 1000px;
  padding: 0 var(--spacing-lg, 20px) var(--spacing-lg, 20px);
}

.agenda-accordion-items {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm, 12px);
}

.agenda-accordion-item-line {
  display: flex;
  align-items: flex-start;
  gap: var(--spacing-sm, 12px);
  padding: var(--spacing-xs, 8px) 0;
  color: #1e293b;
  font-size: 14px;
  line-height: 1.6;
  font-family: 'Open Sans', sans-serif;
}

.agenda-accordion-item-icon {
  width: 16px;
  height: 16px;
  color: var(--somef-primary, #d22741);
  flex-shrink: 0;
  margin-top: 2px;
}

@media (max-width: 768px) {
  .agenda-accordion {
    max-width: 100%;
  }
  
  .agenda-accordion-header {
    padding: var(--spacing-sm, 12px) var(--spacing-md, 16px);
  }
  
  .agenda-accordion-number {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }
  
  .agenda-accordion-icon-wrapper {
    width: 40px;
    height: 40px;
  }
  
  .agenda-accordion-icon {
    width: 20px;
    height: 20px;
  }
  
  .agenda-accordion-title {
    font-size: 14px;
  }
  
  .agenda-accordion-content {
    padding: 0 var(--spacing-md, 16px);
  }
  
  .agenda-accordion-item.active .agenda-accordion-content {
    padding: 0 var(--spacing-md, 16px) var(--spacing-md, 16px);
  }
}

.agenda-part-enhanced {
  padding: var(--spacing-md, 16px);
  background: #ffffff;
  border-radius: var(--radius-md, 12px);
  border: 1px solid #e2e8f0;
  box-shadow: var(--elevation-2, 0 2px 4px rgba(0, 0, 0, 0.06));
  transition: all var(--transition-base, 0.3s ease);
  display: flex;
  flex-direction: column;
  height: 100%;
  min-width: 0;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.agenda-part-enhanced:hover {
  box-shadow: var(--elevation-4, 0 8px 16px rgba(0, 0, 0, 0.1));
  transform: translateY(-2px);
  border-color: var(--somef-primary, #d22741);
}

.agenda-part-header {
  display: flex;
  align-items: flex-start;
  gap: var(--spacing-sm, 12px);
  margin-bottom: var(--spacing-sm, 12px);
}

.agenda-icon-wrapper {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(210, 39, 65, 0.08);
  border: 1px solid rgba(210, 39, 65, 0.15);
  border-radius: var(--radius-md, 10px);
  flex-shrink: 0;
}

.agenda-icon {
  width: 24px;
  height: 24px;
  color: var(--somef-primary, #d22741);
}

.agenda-part-info {
  flex: 1;
  min-width: 0;
}

.agenda-part-title {
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--somef-primary, #d22741);
  margin: 0 0 var(--spacing-xs, 6px) 0;
  line-height: 1.3;
  word-wrap: break-word;
  hyphens: auto;
}

.agenda-part-duration-badge {
  display: inline-block;
  background: rgba(210, 39, 65, 0.08);
  color: var(--somef-primary, #d22741);
  padding: 4px var(--spacing-sm, 10px);
  border-radius: 10px;
  font-size: 11px;
  font-weight: 600;
  font-family: 'Open Sans', sans-serif;
  line-height: 1.4;
  white-space: nowrap;
}

.agenda-items-container {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs, 6px);
  margin-top: var(--spacing-xs, 6px);
}

.agenda-item-badge {
  display: inline-flex;
  align-items: flex-start;
  gap: 6px;
  padding: 6px var(--spacing-sm, 10px);
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.5;
  color: #475569;
  font-family: 'Open Sans', sans-serif;
  transition: all var(--transition-base, 0.2s ease);
  width: 100%;
  box-sizing: border-box;
}

.agenda-item-badge:hover {
  background: rgba(210, 39, 65, 0.05);
  border-color: rgba(210, 39, 65, 0.2);
  color: var(--somef-primary, #d22741);
}

.agenda-item-icon {
  width: 12px;
  height: 12px;
  color: var(--somef-primary, #d22741);
  flex-shrink: 0;
  margin-top: 2px;
}

.agenda-item-text {
  flex: 1;
  min-width: 0;
  word-wrap: break-word;
  hyphens: auto;
}

@media (max-width: 768px) {
  .global-navigation-sections {
    grid-template-columns: 1fr;
    gap: var(--spacing-sm, 12px);
  }
  
  .global-section-card {
    padding: var(--spacing-md, 16px);
  }
  
  .global-section-icon {
    width: 44px;
    height: 44px;
  }
  
  .global-section-title {
    font-size: 16px;
  }
  
  .global-section-description {
    font-size: 13px;
  }
  
  .agenda-timeline {
    grid-template-columns: 1fr;
    gap: var(--spacing-sm, 12px);
  }
  
  .agenda-part-enhanced {
    padding: var(--spacing-sm, 12px);
  }
  
  .agenda-icon-wrapper {
    width: 40px;
    height: 40px;
  }
  
  .agenda-icon {
    width: 20px;
    height: 20px;
  }
  
  .agenda-part-title {
    font-size: 14px;
  }
  
  .agenda-item-badge {
    font-size: 11px;
    padding: 5px var(--spacing-xs, 8px);
  }
  
  .agenda-item-icon {
    width: 10px;
    height: 10px;
  }

  .nav-btn {
    padding: 10px 16px;
    font-size: 12px;
    min-width: 140px;
  }

  .navigation-global-title {
    font-size: 32px;
  }

  .navigation-global-subtitle {
    font-size: 16px;
    margin-bottom: 40px;
  }

  .navigation-sections-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .navigation-slides-list {
    grid-template-columns: 1fr;
  }
}

