/* ══════════════════════════════════════════════════════
   CORRECTIFS CRITIQUES — 16 avril 2026
   ══════════════════════════════════════════════════════ */

/* ── FIX 1: Performance — Supprimer background-attachment: fixed ── */
.hero,
#services,
#flotte,
#destinations,
section:nth-of-type(5),
section:nth-of-type(6) {
  background-attachment: scroll !important;
}

/* ── FIX 2: Selecteur de langue visible sur navbar sombre ── */
nav.scrolled .lang-current {
  color: var(--gold) !important;
}
nav.scrolled .lang-current::after {
  color: var(--gold) !important;
}
nav.scrolled .lang-switcher:hover .lang-current {
  color: var(--gold-lt) !important;
}

/* ── FIX 3: Pages Services — Contenu avec max-width lisible ── */
body > section.service-content {
  max-width: 900px !important;
  margin: 0 auto !important;
  padding: 4rem 2rem !important;
}

/* ── FIX 4: Service Hero — Fond sombre ── */
.service-hero {
  background-color: #0a0a0a !important;
  background-image: url('../images/mercedes-interior-ambient.jpg') !important;
  background-size: cover !important;
  background-position: center center !important;
  position: relative !important;
}
.service-hero::before {
  content: '' !important;
  position: absolute !important;
  inset: 0 !important;
  background: linear-gradient(135deg, rgba(0,0,0,0.6) 0%, rgba(20,15,5,0.5) 40%, rgba(0,0,0,0.65) 100%) !important;
  z-index: 0 !important;
}
.service-hero > * {
  position: relative !important;
  z-index: 1 !important;
}
.service-hero h1 {
  color: #fff !important;
}
.service-hero p,
.service-hero .service-subtitle {
  color: rgba(255,255,255,0.85) !important;
}

/* ── FIX 5: Reduire les backdrop-filter pour performance ── */
section::before {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

/* ── FIX 6: service-content texte (override du conflit card) ── */
body > section.service-content h2 {
  font-family: var(--font-display) !important;
  font-size: 2.2rem !important;
  color: #1a1a1a !important;
  margin-bottom: 1rem !important;
  margin-top: 2.5rem !important;
}
body > section.service-content h2:first-child {
  margin-top: 0 !important;
}
body > section.service-content h3 {
  font-family: var(--font-display) !important;
  font-size: 1.4rem !important;
  color: #1a1a1a !important;
}
body > section.service-content p {
  font-size: 1.05rem !important;
  line-height: 1.8 !important;
  color: #444 !important;
  margin-bottom: 1.2rem !important;
}


/* — FIX 7: Header — Navigation alignée à droite, logo à gauche — */
nav {
    justify-content: flex-end !important;
    gap: 2rem !important;
}
nav .nav-logo {
    margin-right: auto !important;
}
nav .nav-links {
    margin-right: 0 !important;
    margin-left: 0 !important;
}

/* ============================================================
   FIX 8: REFONTE PREMIUM — Section Services Home
   Design: Full-image overlay cards — Tendance 2025/2026
   ============================================================ */

/* --- Section background & spacing --- */
#services {
  background: #0a0a0a !important;
  padding: 120px 60px !important;
}
#services::before {
  display: none !important;
}

/* --- Section header on dark bg --- */
#services .section-label {
  color: var(--gold) !important;
  letter-spacing: .25em !important;
}
#services .section-title {
  color: #fff !important;
  font-size: 3.2rem !important;
  line-height: 1.15 !important;
}
#services .section-subtitle {
  color: rgba(255,255,255,.55) !important;
  max-width: 540px !important;
}
#services .divider {
  background: var(--gold) !important;
  opacity: 1 !important;
}

/* --- Grid layout: 3 top + 2 bottom centered --- */
#services .services-showcase {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 20px !important;
  margin-top: 60px !important;
  padding: 0 !important;
}
#services .service-item:nth-child(4),
#services .service-item:nth-child(5) {
  grid-column: span 1;
}
/* Center the last 2 cards */
#services .services-showcase::after {
  content: '';
  grid-column: span 1;
  display: none;
}

/* --- Card: full-image immersive overlay --- */
#services .service-item {
  position: relative !important;
  display: flex !important;
  flex-direction: column !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  background: #111 !important;
  color: #fff !important;
  text-decoration: none !important;
  min-height: 480px !important;
  box-shadow: 0 4px 30px rgba(0,0,0,.4) !important;
  transition: transform .55s cubic-bezier(.22,1,.36,1),
              box-shadow .55s cubic-bezier(.22,1,.36,1) !important;
  cursor: pointer !important;
}
#services .service-item:hover {
  transform: translateY(-8px) !important;
  box-shadow: 0 24px 64px rgba(0,0,0,.6), 0 0 0 1px rgba(74,144,217,.15) !important;
}

/* --- Image fills entire card --- */
#services .service-img-wrap {
  position: absolute !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  aspect-ratio: auto !important;
  z-index: 1 !important;
}
#services .service-img-wrap img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform .8s cubic-bezier(.22,1,.36,1),
              filter .8s cubic-bezier(.22,1,.36,1) !important;
  filter: brightness(.75) !important;
}
#services .service-item:hover .service-img-wrap img {
  transform: scale(1.06) !important;
  filter: brightness(.55) !important;
}

/* --- Overlay gradient — rich bottom fade --- */
#services .service-overlay {
  position: absolute !important;
  inset: 0 !important;
  z-index: 2 !important;
  background: linear-gradient(
    180deg,
    transparent 20%,
    rgba(0,0,0,.15) 45%,
    rgba(0,0,0,.7) 75%,
    rgba(0,0,0,.92) 100%
  ) !important;
  transition: opacity .5s !important;
  opacity: 1 !important;
}
#services .service-item:hover .service-overlay {
  background: linear-gradient(
    180deg,
    rgba(0,0,0,.1) 0%,
    rgba(0,0,0,.25) 40%,
    rgba(0,0,0,.8) 75%,
    rgba(0,0,0,.95) 100%
  ) !important;
}

/* --- Content positioned at bottom over image --- */
#services .service-content {
  position: relative !important;
  z-index: 3 !important;
  margin-top: auto !important;
  padding: 0 32px 36px !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 0 !important;
}

/* --- Number — small accent top-left of content --- */
#services .service-number {
  font-family: var(--font-body) !important;
  font-size: .75rem !important;
  font-weight: 600 !important;
  letter-spacing: .15em !important;
  color: var(--gold) !important;
  opacity: .9 !important;
  margin-bottom: 12px !important;
  display: inline-block !important;
  padding-bottom: 10px !important;
  border-bottom: 1px solid rgba(74,144,217,.3) !important;
  width: fit-content !important;
}

/* --- Title h3 --- */
#services .service-item .service-content h3 {
  color: #fff !important;
  font-family: var(--font-display) !important;
  font-size: 1.65rem !important;
  font-weight: 500 !important;
  line-height: 1.25 !important;
  margin: 0 0 10px 0 !important;
  transition: transform .4s cubic-bezier(.22,1,.36,1) !important;
  transform: translateY(0) !important;
}
#services .service-item:hover .service-content h3 {
  transform: translateY(-4px) !important;
}

/* --- Description p --- */
#services .service-item .service-content p {
  color: rgba(255,255,255,.65) !important;
  font-family: var(--font-body) !important;
  font-size: .92rem !important;
  line-height: 1.65 !important;
  margin: 0 0 16px 0 !important;
  max-height: 0 !important;
  overflow: hidden !important;
  opacity: 0 !important;
  transition: max-height .5s cubic-bezier(.22,1,.36,1),
              opacity .4s .05s !important;
}
#services .service-item:hover .service-content p {
  max-height: 120px !important;
  opacity: 1 !important;
}

/* --- CTA link "Découvrir" --- */
#services .service-link {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  color: var(--gold) !important;
  font-family: var(--font-body) !important;
  font-size: .82rem !important;
  font-weight: 600 !important;
  letter-spacing: .12em !important;
  text-transform: uppercase !important;
  transition: gap .4s cubic-bezier(.22,1,.36,1),
              opacity .3s !important;
  opacity: 0 !important;
  transform: translateY(0) !important;
}
#services .service-item:hover .service-link {
  opacity: 1 !important;
  gap: 12px !important;
}
#services .service-link .arrow {
  display: inline-block !important;
  transition: transform .4s cubic-bezier(.22,1,.36,1) !important;
  font-size: 1.1rem !important;
}
#services .service-item:hover .service-link .arrow {
  transform: translateX(4px) !important;
}

/* --- Accent line on hover (gold top border) --- */
#services .service-item::after {
  content: '' !important;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  height: 3px !important;
  background: var(--gold) !important;
  z-index: 10 !important;
  transform: scaleX(0) !important;
  transform-origin: left !important;
  transition: transform .5s cubic-bezier(.22,1,.36,1) !important;
}
#services .service-item:hover::after {
  transform: scaleX(1) !important;
}

/* --- Remove old color overrides --- */
#services .service-item,
#services .service-item * {
  color: unset !important;
}

/* --- Responsive: 2 cols on tablet, 1 on mobile --- */
@media (max-width: 1024px) {
  #services .services-showcase {
    grid-template-columns: repeat(2, 1fr) !important;
  }
  #services .service-item {
    min-height: 420px !important;
  }
}
@media (max-width: 640px) {
  #services {
    padding: 80px 20px !important;
  }
  #services .services-showcase {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  #services .service-item {
    min-height: 380px !important;
  }
  #services .section-title {
    font-size: 2.2rem !important;
  }
}
