@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* Reset et base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #f8fafc;
  color: #1f2937;
  line-height: 1.6;
  scroll-behavior: smooth;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header moderne */
.header {
  background: rgba(30, 64, 175, 0.95);
  backdrop-filter: blur(10px);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 15px 0;
  transition: all 0.3s ease;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.header.scrolled {
  background: rgba(30, 64, 175, 0.98);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header .logo {
  width: 140px;
  height: auto;
  transition: transform 0.3s ease;
}

.header .logo:hover {
  transform: scale(1.05);
}

.navbar ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.navbar a {
  text-decoration: none;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
  font-size: 14px;
  padding: 8px 16px;
  border-radius: 8px;
  transition: all 0.3s ease;
  position: relative;
}

.navbar a:hover, .navbar a.active {
  color: #ffffff;
  background: rgba(245, 158, 11, 0.2);
  transform: translateY(-1px);
}

.navbar a.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  width: 20px;
  height: 2px;
  background: #f59e0b;
  transform: translateX(-50%);
  border-radius: 1px;
}

/* Menu mobile */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  padding: 8px;
}

@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: block;
  }
  
  .navbar {
    position: fixed;
    top: 70px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 70px);
    background: rgba(30, 64, 175, 0.98);
    backdrop-filter: blur(10px);
    transition: left 0.3s ease;
    padding: 2rem;
  }
  
  .navbar.active {
    left: 0;
  }
  
  .navbar ul {
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
  }
  
  .navbar a {
    font-size: 18px;
    padding: 12px 0;
    width: 100%;
  }
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
  color: white;
  text-align: center;
  padding: 140px 20px 100px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='m36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.1;
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  margin-bottom: 1.5rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  animation: fadeInUp 1s ease-out;
}

.hero p {
  font-size: clamp(1.1rem, 2vw, 1.3rem);
  margin-bottom: 2.5rem;
  opacity: 0.95;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  animation: fadeInUp 1s ease-out 0.2s both;
}

/* Boutons modernes */
.btn-primary {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  padding: 14px 28px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.3s ease;
  display: inline-block;
  border: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(245, 158, 11, 0.4);
  background: linear-gradient(135deg, #d97706, #b45309);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: transparent;
  color: #1e40af;
  padding: 14px 28px;
  border: 2px solid #1e40af;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.3s ease;
  display: inline-block;
}

.btn-secondary:hover {
  background: #1e40af;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(30, 64, 175, 0.3);
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

/* Carousel moderne avec défilement horizontal */
.carousel {
  margin: 0;
  position: relative;
  overflow: hidden;
  border-radius: 0;
  height: 500px;
}

.carousel-wrapper {
  position: relative;
  height: 100%;
  overflow: hidden;
  border-radius: 0;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.carousel-container {
  display: flex;
  width: 400%; /* 4 images donc 400% */
  height: 100%;
  animation: slideCarousel 16s infinite linear;
}

@keyframes slideCarousel {
  0% { transform: translateX(0); }
  20% { transform: translateX(0); }
  25% { transform: translateX(-25%); }
  45% { transform: translateX(-25%); }
  50% { transform: translateX(-50%); }
  70% { transform: translateX(-50%); }
  75% { transform: translateX(-75%); }
  95% { transform: translateX(-75%); }
  100% { transform: translateX(0); }
}

.carousel-slide {
  min-width: 25%; /* Chaque image prend 25% de la largeur totale */
  height: 100%;
  object-fit: cover;
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

.carousel-slide:hover {
  transform: scale(1.02);
}

/* Boutons carousel modernes */
button.prev, button.next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.95);
  color: #1f2937;
  border: none;
  padding: 12px 16px;
  cursor: pointer;
  font-size: 20px;
  z-index: 10;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

button.prev {
  left: 20px;
}

button.next {
  right: 20px;
}

button.prev:hover, button.next:hover {
  background: white;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

/* Indicateurs carousel */
.carousel-indicators {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.carousel-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s ease;
}

.carousel-indicator.active {
  background: white;
  transform: scale(1.2);
}

/* Sections principales */
.features {
  background: white;
  padding: 80px 20px;
}

.features .container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.feature-card {
  text-align: center;
  padding: 2rem;
  border-radius: 16px;
  transition: all 0.3s ease;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  background: white;
}

.feature-card img {
  width: 60px;
  height: 60px;
  margin-bottom: 1rem;
  transition: transform 0.3s ease;
}

.feature-card:hover img {
  transform: scale(1.1);
}

.feature-card h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #1f2937;
}

.feature-card p {
  color: #6b7280;
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

/* Cartes de formation */
.formation-card {
  background: white;
  padding: 2rem;
  border-radius: 16px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  text-align: center;
  transition: all 0.3s ease;
  border: 1px solid #e5e7eb;
  position: relative;
  overflow: hidden;
}

.formation-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.formation-card:hover::before {
  transform: scaleX(1);
}

.formation-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
  border-color: #f59e0b;
}

.formation-card.promo {
  border: 2px solid #10b981;
  position: relative;
}

.formation-card.promo::before {
  background: linear-gradient(135deg, #10b981, #059669);
}

.formation-card.promo::after {
  content: '🔥 OFFRE PROMO';
  position: absolute;
  top: 15px;
  right: -25px;
  background: #10b981;
  color: white;
  padding: 5px 30px;
  font-size: 12px;
  font-weight: 700;
  transform: rotate(45deg);
}

.icon-wrapper {
  font-size: 3rem;
  margin-bottom: 1rem;
  transition: all 0.3s ease;
  display: inline-block;
}

.formation-card:hover .icon-wrapper {
  transform: scale(1.15) rotate(5deg);
}

.formation-card h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #1f2937;
}

.formation-card p {
  color: #6b7280;
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

/* Couleurs des icônes */
.icon-dev { color: #3b82f6; }
.icon-design { color: #f59e0b; }
.icon-marketing { color: #ef4444; }
.icon-gestion { color: #10b981; }
.icon-langues { color: #8b5cf6; }
.icon-bureautique { color: #06b6d4; }

/* Logo carousel */
.logos-carousel {
  background: white;
  padding: 60px 20px;
  overflow: hidden;
  position: relative;
}

.logos-carousel::before,
.logos-carousel::after {
  content: '';
  position: absolute;
  top: 0;
  width: 100px;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.logos-carousel::before {
  left: 0;
  background: linear-gradient(to right, white, transparent);
}

.logos-carousel::after {
  right: 0;
  background: linear-gradient(to left, white, transparent);
}

.logos-wrapper {
  display: flex;
  align-items: center;
  animation: scroll-left 20s linear infinite;
}

.logos-wrapper img {
  height: 60px;
  margin: 0 3rem;
  filter: grayscale(100%) opacity(0.7);
  transition: all 0.3s ease;
}

.logos-wrapper img:hover {
  filter: grayscale(0) opacity(1);
  transform: scale(1.1);
}

@keyframes scroll-left {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Footer moderne */
.site-footer {
  background: linear-gradient(135deg, #1e40af, #1e3a8a);
  color: white;
  padding: 60px 20px 30px;
  position: relative;
}

.site-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='m36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.site-footer > * {
  position: relative;
  z-index: 1;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #f59e0b;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 0.5rem;
}

.footer-section ul li a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-section ul li a:hover {
  color: #f59e0b;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
}

/* Modales */
.modal {
  display: none;
  position: fixed;
  z-index: 10000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
}

.modal-content {
  background-color: white;
  margin: 5% auto;
  padding: 0;
  border-radius: 16px;
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(-50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  padding: 2rem 2rem 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.modal-header h2 {
  margin: 0;
  color: #1f2937;
  font-size: 1.5rem;
  font-weight: 700;
}

.close {
  color: #6b7280;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.3s ease;
}

.close:hover {
  color: #ef4444;
}

.modal-body {
  padding: 2rem;
}

/* Formulaires */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: #374151;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 16px;
  transition: all 0.3s ease;
  background: #f9fafb;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #f59e0b;
  background: white;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .carousel-slide {
    height: 400px;
  }
  
  .hero {
    padding: 120px 20px 80px;
  }
}

@media (max-width: 768px) {
  .form-row {
    grid-template-columns: 1fr;
  }
  
  .carousel-slide {
    height: 300px;
  }
  
  button.prev, button.next {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
  
  button.prev {
    left: 10px;
  }
  
  button.next {
    right: 10px;
  }
  
  .hero {
    padding: 100px 20px 60px;
  }
  
  .features {
    padding: 60px 20px;
  }
  
  .modal-content {
    width: 95%;
    margin: 10% auto;
  }
  
  .modal-body {
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .carousel-slide {
    height: 250px;
  }
  
  .hero h1 {
    font-size: 2rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  .formation-card {
    padding: 1.5rem;
  }
}
