/* =============================================================
   Mayou Voyages — styles partagés (carrousel, animations, calendrier)
   Chargé par toutes les pages après le <style> inline de chaque page.
   ============================================================= */

/* ---------- Animations d'apparition au défilement ---------- */
/* La propriété "translate" (et non "transform") évite d'écraser l'effet hover des cartes. */
.js .mv-reveal { opacity: 0; translate: 0 22px; transition: opacity .6s ease, translate .6s ease; }
.js .mv-reveal.is-in { opacity: 1; translate: 0 0; }
@media (prefers-reduced-motion: reduce) {
  .js .mv-reveal { opacity: 1; translate: none; transition: none; }
}

/* ---------- Carrousel d'accueil ---------- */
.mv-hero { position: relative; overflow: hidden; background: #241B1A; color: #FFFFFF; }
.mv-slides { position: relative; height: 540px; }
.mv-slide {
  position: absolute; inset: 0; opacity: 0; visibility: hidden;
  transition: opacity .9s ease, visibility .9s;
  background-size: cover; background-position: center;
}
.mv-slide.is-active { opacity: 1; visibility: visible; z-index: 1; }
.mv-slide-art { position: absolute; inset: 0; }
.mv-slide-art svg { width: 100%; height: 100%; display: block; }
.mv-slide.has-photo .mv-slide-art { display: none; }
.mv-slide::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, rgba(36,27,26,.78) 0%, rgba(36,27,26,.45) 45%, rgba(36,27,26,0) 78%);
}
.mv-slide-text {
  position: relative; z-index: 2; height: 100%;
  max-width: 1160px; margin: 0 auto; padding: 0 64px 118px;
  display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
}
.mv-slide-kicker { font-size: 13px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: #FFD9C7; margin-bottom: 14px; }
.mv-slide-title { font-family: 'Yeseva One', serif; font-weight: 400; font-size: 46px; line-height: 1.13; margin: 0 0 14px; max-width: 640px; text-wrap: balance; color: #FFFFFF; }
.mv-slide-sub { font-size: 17px; line-height: 1.6; max-width: 520px; margin: 0 0 26px; color: #F3E9E4; }
.mv-slide-cta {
  display: inline-flex; align-items: center; gap: 8px; background: #C7182F; color: #FFFFFF !important;
  font-weight: 700; font-size: 15px; padding: 14px 26px; border-radius: 8px; text-decoration: none;
}
.mv-slide-cta:hover { background: #9E1224; color: #FFFFFF; }

/* animations d'entrée du texte et léger zoom du visuel sur la diapositive active */
.mv-slide .mv-slide-text > * { opacity: 0; translate: 0 18px; }
.mv-slide.is-active .mv-slide-text > * { animation: mvRise .8s ease forwards; }
.mv-slide.is-active .mv-slide-text > *:nth-child(2) { animation-delay: .12s; }
.mv-slide.is-active .mv-slide-text > *:nth-child(3) { animation-delay: .24s; }
.mv-slide.is-active .mv-slide-text > *:nth-child(4) { animation-delay: .36s; }
@keyframes mvRise { to { opacity: 1; translate: 0 0; } }
.mv-slide.is-active .mv-slide-art, .mv-slide.is-active.has-photo { animation: mvZoom 9s ease-out forwards; }
@keyframes mvZoom { from { scale: 1; } to { scale: 1.06; } }
.mv-slide.has-photo { background-size: cover; }

.mv-hero-arrow {
  position: absolute; top: 50%; translate: 0 -50%; z-index: 5; width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.55); background: rgba(36,27,26,.35); color: #FFFFFF; cursor: pointer;
  display: flex; align-items: center; justify-content: center; padding: 0;
}
.mv-hero-arrow:hover { background: rgba(199,24,47,.85); border-color: #C7182F; }
.mv-hero-arrow.prev { left: 22px; }
.mv-hero-arrow.next { right: 22px; }
.mv-hero-dots { position: absolute; left: 0; right: 0; bottom: 104px; z-index: 5; display: flex; justify-content: center; gap: 9px; }
.mv-hero-dot { width: 10px; height: 10px; border-radius: 50%; border: 1.5px solid #FFFFFF; background: transparent; cursor: pointer; padding: 0; transition: background .2s, width .2s; }
.mv-hero-dot.is-active { background: #FFFFFF; width: 26px; border-radius: 6px; }

/* carte "sélecteur de service" qui chevauche le bas du carrousel */
.mv-selector-wrap { position: relative; z-index: 6; display: flex; justify-content: center; padding: 0 64px; margin-top: -78px; }
.mv-selector-wrap > div { width: 100%; max-width: 900px; }

/* onglets du sélecteur avec icônes */
.mv-tab { display: flex !important; flex-direction: column; align-items: center; justify-content: center; gap: 7px; line-height: 1.25; }
.mv-tab svg { width: 24px; height: 24px; flex: none; }

/* ---------- Calendrier (date picker) ---------- */
.mv-date { cursor: pointer; }
.mv-date-err { color: #C7182F; font-size: 12px; margin-top: 4px; font-weight: 600; }
.mv-cal {
  position: absolute; z-index: 9000; width: 292px; background: #FFFFFF; border: 1px solid #E3DCD5; border-radius: 12px;
  box-shadow: 0 18px 44px rgba(61,46,44,.22); padding: 14px; font-family: 'Urbanist', sans-serif; color: #3D2E2C; display: none;
}
.mv-cal.is-open { display: block; }
.mv-cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.mv-cal-title { font-weight: 800; font-size: 14.5px; text-transform: capitalize; }
.mv-cal-nav { width: 30px; height: 30px; border-radius: 8px; border: 1px solid #E3DCD5; background: #FFFFFF; cursor: pointer; font-size: 16px; line-height: 1; color: #3D2E2C; }
.mv-cal-nav:hover:not(:disabled) { border-color: #C7182F; color: #C7182F; }
.mv-cal-nav:disabled { opacity: .35; cursor: not-allowed; }
.mv-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.mv-cal-dow { font-size: 11px; font-weight: 700; color: #93857D; text-align: center; padding: 4px 0; text-transform: uppercase; }
.mv-cal-day { height: 34px; border: none; background: transparent; border-radius: 8px; font-family: inherit; font-size: 13.5px; font-weight: 600; color: #3D2E2C; cursor: pointer; }
.mv-cal-day:hover:not(:disabled) { background: #FBEAEC; color: #C7182F; }
.mv-cal-day.is-today { box-shadow: inset 0 0 0 1.5px #C7182F; }
.mv-cal-day.is-selected { background: #C7182F; color: #FFFFFF; }
.mv-cal-day:disabled { color: #CFC6C1; cursor: not-allowed; text-decoration: line-through; text-decoration-color: rgba(207,198,193,.6); }
.mv-cal-day.is-empty { visibility: hidden; }
.mv-cal-foot { display: flex; justify-content: space-between; margin-top: 10px; padding-top: 10px; border-top: 1px solid #EDE7E2; }
.mv-cal-foot button { border: none; background: none; font-family: inherit; font-weight: 700; font-size: 12.5px; color: #C7182F; cursor: pointer; padding: 4px 6px; }

/* ---------- Pages rubriques (pèlerinages, activités, séjours) ---------- */
.mv-offer-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 22px; }
.mv-offer { border: 1px solid #EDE7E2; border-radius: 14px; overflow: hidden; background: #FFFFFF; display: flex; flex-direction: column; }
.mv-offer-art { height: 150px; position: relative; }
.mv-offer-art svg { width: 100%; height: 100%; display: block; }
.mv-offer-body { padding: 22px 24px 24px; display: flex; flex-direction: column; flex: 1; }
.mv-offer-body h3 { font-family: 'Yeseva One', serif; font-weight: 400; font-size: 21px; margin: 0 0 8px; color: #3D2E2C; }
.mv-offer-body p { font-size: 14px; line-height: 1.6; color: #6b6b6b; margin: 0 0 16px; flex: 1; }
.mv-offer-body .mv-offer-btn {
  align-self: flex-start; border: none; cursor: pointer; background: #C7182F; color: #FFFFFF; font-family: inherit;
  font-weight: 700; font-size: 14px; padding: 11px 20px; border-radius: 8px;
}
.mv-offer-body .mv-offer-btn:hover { background: #9E1224; }
.mv-pill { display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; padding: 4px 10px; border-radius: 14px; background: #FBEAEC; color: #9E1224; margin-bottom: 10px; align-self: flex-start; }

@media (max-width: 900px) {
  .mv-slides { height: 580px; }
  .mv-slide-text { padding: 0 24px 128px; }
  .mv-slide-title { font-size: 32px; }
  .mv-slide-sub { font-size: 15px; }
  .mv-hero-arrow { display: none; }
  .mv-hero-dots { bottom: 118px; }
  .mv-selector-wrap { padding: 0 16px; margin-top: -84px; }
  .mv-offer-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .mv-slide-title { font-size: 27px; }
  .mv-tab { font-size: 10.5px !important; }
  .mv-tab svg { width: 20px; height: 20px; }
}

/* en-tête : on libère de la place entre 900 et 1240 px quand six liens de navigation cohabitent avec le téléphone */
@media (max-width: 1400px) and (min-width: 901px) {
  header a[href^="tel:"] { display: none !important; }
  header nav { gap: 18px !important; }
  header nav a { white-space: nowrap; font-size: 14.5px !important; }
}
@media (max-width: 1240px) and (min-width: 901px) {
  header { padding-left: 24px !important; padding-right: 24px !important; }
  header nav { gap: 16px !important; }
  header nav a { font-size: 14px !important; }
  header a[href^="https://wa.me"] { font-size: 0 !important; padding: 11px !important; border-radius: 50% !important; gap: 0 !important; }
}
