@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@500;700&display=swap');

body {
  margin: 0;
  padding: 0;
  background-color: #27292c;
  color: #e2e2e2;
  font-family: 'Inter', sans-serif;
  overflow-x: hidden;
}

.hero {
  text-align: center;
  padding: 140px 20px 60px;
  background: linear-gradient(180deg, #6e6e6e 0%, #27292c 100%);
}

.hero-title {
  font-size: 80px;
  margin: 0;
  font-weight: 600;
  font-family: 'Syncopate', sans-serif;
  color: #ffffff;
  animation: colorPulse 6s infinite alternate;
}

.hero-subtitle {
  font-size: 24px;
  color: #747474;
  letter-spacing: 2px;
  margin-top: 10px;
  padding: 20px 80px;
}

.top-nav {
  background-color: #181818;
  height: 100px;
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
}

.top-nav .container {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
  padding: 0 20px;
}

.top-nav ul {
  list-style: none;
  display: flex;
  gap: 30px;
  margin: 0;
  padding: 0;
  text-align: center;
}

.top-nav a {
  text-decoration: none;
  font-weight: 600;
  color: #ccc;
  font-size: 20px;
  transition: color 0.3s;
  text-align: center;
}

.top-nav a:hover,
.top-nav a.active {
  color: white;
}


.top-nav .burger {
  display: none;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
}

.top-nav .burger span {
  display: block;
  width: 25px;
  height: 3px;
  background: white;
  border-radius: 2px;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  padding: 40px 20px 80px;
}

.car-card {
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  position: relative;
}

.car-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.car-card::after {
  content: "";
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  border-radius: 20px;
  box-shadow: 0 0 30px #9E9E9E;
  opacity: 0;
  transition: opacity 0.4s;
}

.car-card:hover::after {
  opacity: 1;
}

.car-card:hover {
  transform: scale(1.02);
  transition: transform 0.3s;
}

.gallery-text {
  grid-column: span 2;
  padding: 60px 30px;
  text-align: center;
  font-family: 'Playfair Display', serif;
  transform: rotate(-1.5deg);
}

.gallery-text h2 {
  color: #4f4f4f;
  font-size: 60px;
  margin: 0 0 20px;
  letter-spacing: 2px;
}

.gallery-text p {
  color: #d0d0d0;
  font-size: 28px;
  line-height: 1.6;
  margin: 0;
}


.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0; top: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(6px);
    opacity: 0;
    transition: opacity 0.4s;
  }

   .modal.show {
    display: block;
    opacity: 1;
  }

  .modal-content {
  display: block;
  max-width: 90%;
  max-height: 90%;
  margin: 5% auto;
  border-radius: 10px;
  animation: fadeInZoom 0.5s forwards;
  /* Assure-toi aussi que la couleur de fond ne masque rien */
}

.close {
  position: absolute;
  top: 15px;
  right: 30px;
  color: white;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  user-select: none;
  transition: color 0.3s ease;
  z-index: 2100; /* au-dessus de la modale */
}

.close:hover {
  color: red;
}



@keyframes fadeInZoom {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
  }
                                                                     

/* ----------- Mobile (max 600px) ----------- */
@media (max-width: 600px) {
  .top-nav {
    justify-content: space-between;
    padding: 0 20px;
  }

  .top-nav .burger {
    display: flex;
  }

  .top-nav ul {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 60px;
    left: 0;
    width: 100%;
    background: #181818;
    padding: 10px 0;
    gap: 10px;
    z-index: 1000;
  }

    .top-nav ul.active {
    display: flex;
  }

  .gallery {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-text {
    grid-column: span 2;
    padding: 40px 20px;
    transform: none;
  }

  .gallery-text h2 {
    font-size: 36px;
  }

  .gallery-text p {
    font-size: 20px;
  }
}
