/* =========================================================
   CAROUSELS CSS
   Fichier commun pour :
   - propriétés
   - agences
   - destinations
   - activités
   ========================================================= */

/* =========================================================
   SECTION GÉNÉRALE
   ========================================================= */
.home-props {
  margin: 5px 0 10px;
  position: relative;
}

@media (max-width: 768px) {
  .home-props {
    margin: 5px 0 5px;
    position: relative;
  }
}

.home-props__head {
  display: flex;
  align-items: baseline;
  justify-content: flex-start;
  margin: 8px 0 10px;
}

.home-props__title {
  margin: -5px;
  margin-left: 2px;
  font-weight: 700;
}

@media (max-width: 768px) {
  .home-props__title {
    margin: -5px;
    margin-left: 2px;
    font-weight: 700;
  }
}

.home-props__cta {
  display: flex;
  justify-content: flex-start;
  margin-top: 10px;
  margin-bottom: 10px;
}

.home-props__cta-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 5px;
  padding: 8px 14px;
  max-width: 100%;
  border: 1px solid #ED1C24;
  border-radius: 8px;
  background: #ED1C24;
  color: #fff;
  text-decoration: none;
  text-align: center;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.1;
}

.home-props__cta-link:hover {
  background: #CE1126;
  color: #fff;
  border-color: #CE1126;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .08);
}

@media (max-width: 480px) {
  .home-props__cta-link {
    font-size: 0.95rem;
    padding: 7px 12px;
  }
}

/* =========================================================
   CARROUSEL PROPRIÉTÉS / HOME (.hp-carousel)
   ========================================================= */
.hp-carousel {
  --hp-gap: 48px;
  position: relative;
  width: 100%;
  overflow: hidden;
}

.hp-track {
  display: flex;
  width: 100%;
  gap: var(--hp-gap);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding: 6px 0 12px;
  scrollbar-gutter: stable;
}

.hp-card {
  box-sizing: border-box;
  flex: 0 0 calc((100% - 3 * var(--hp-gap)) / 4 - .5px);
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

@media (max-width: 1280px) {
  .hp-card {
    flex: 0 0 calc((100% - 2 * var(--hp-gap)) / 3 - .5px);
  }
}

@media (max-width: 1024px) {
  .hp-card {
    flex: 0 0 calc((100% - 1 * var(--hp-gap)) / 2 - .5px);
  }
}

@media (max-width: 640px) {
  .hp-card {
    flex: 0 0 100%;
  }
}

.hp-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 999px;
  appearance: none;
  background: rgba(0, 0, 0, .45);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
  transition: background .15s ease;
}

.hp-nav:hover {
  background: rgba(0, 0, 0, .65);
}

.hp-nav:disabled {
  opacity: .4;
  cursor: default;
}

.hp-nav--prev {
  left: 10px;
}

.hp-nav--next {
  right: 10px;
}

/* Cartes propriétés */
.mc-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  color: inherit;
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .06);
  border-bottom: 3px solid #002244;
  transition: transform .18s ease, box-shadow .18s ease;
  will-change: transform;
}

.mc-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, .08);
}

.mc-photo {
  position: relative;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: #f3f4f6;
}

.mc-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: none;
}

.mc-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 14px 14px;
}

.mc-city {
  font-size: 1.05rem;
  font-weight: 700;
  color: #000;
}

.mc-cat {
  font-size: .95rem;
  font-weight: 700;
  color: #000;
}

.mc-specs {
  font-size: .95rem;
  color: #6a6a6a;
  line-height: 1.45;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.mc-price-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 6px;
}

.mc-price {
  font-size: 1rem;
  font-weight: 700;
  color: #000;
}

.mc-agency-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.mc-agency-logo img {
  width: auto;
  height: auto;
  max-height: 22px;
  max-width: 80px;
  object-fit: contain;
  opacity: .9;
  margin-top: 5px;
}

/* Variante logo destination dans les cartes home */
.hp-carousel .mc-agency-logo {
  width: 100%;
  margin-top: 8px;
  text-align: center;
}

.hp-carousel .mc-agency-logo img[src*="/destination/logo-destination/"] {
  display: block;
  width: auto;
  height: auto;
  max-height: 75px;
  max-width: 200px;
  min-width: 24px;
  min-height: 16px;
  object-fit: contain;
  image-rendering: auto;
}

@media (max-width: 640px) {
  .hp-carousel .mc-agency-logo img[src*="/destination/logo-destination/"] {
    max-height: 65px;
    max-width: 200px;
  }
}

/* Scrollbar home */
.hp-track::-webkit-scrollbar {
  height: 10px;
}

.hp-track::-webkit-scrollbar-thumb {
  background: #c7c7c7;
  border-radius: 8px;
}

.hp-track::-webkit-scrollbar-track {
  background: transparent;
}

.hp-track {
  scrollbar-width: thin;
}

/* =========================================================
   CARROUSEL AGENCES (.agc-carousel)
   ========================================================= */
.agc-section {
  margin: 0;
}

.agc-carousel {
  --agc-gap: 48px;
  position: relative;
  width: 100%;
  overflow: hidden;
}

.agc-track {
  display: flex;
  gap: var(--agc-gap);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding: 4px 0 12px;
  scrollbar-gutter: stable;
}

.agc-card {
  box-sizing: border-box;
  flex: 0 0 calc((100% - 2 * var(--agc-gap)) / 3 - .5px);
  max-width: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

@media (max-width: 1024px) {
  .agc-card {
    flex-basis: calc((100% - 1 * var(--agc-gap)) / 2 - .5px);
  }
}

@media (max-width: 640px) {
  .agc-card {
    flex-basis: 100%;
  }
}

.agence-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  color: inherit;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .06);
  border-bottom: 3px solid #002244;
  transition: transform .18s ease, box-shadow .18s ease;
}

.agence-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, .08);
}

.agence-photo {
  position: relative;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: #f3f4f6;
}

.agence-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  backface-visibility: hidden;
  transform: none;
  image-rendering: auto;
}

.agence-body {
  padding: 8px 10px 20px;
  font-size: .92rem;
}

.agence-logo {
  display: flex;
  align-items: center;
  margin-bottom: 6px;
}

.agence-logo img {
  width: auto;
  height: auto;
  max-height: 28px;
  max-width: 140px;
  margin-top: 10px;
  margin-bottom: 10px;
  object-fit: contain;
  opacity: .95;
}

.agence-contact {
  margin: 0 !important;
  font-size: .92rem;
  line-height: 1.24;
}

.agence-contact--name {
  margin: 0 !important;
}

.agence-body > *:first-child {
  margin-top: 0 !important;
}

.agence-body > *:last-child {
  margin-bottom: 0 !important;
}

.agc-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 999px;
  appearance: none;
  background: rgba(0, 0, 0, .45);
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  transition: background .15s ease;
}

.agc-nav:hover {
  background: rgba(0, 0, 0, .65);
}

.agc-nav:disabled {
  opacity: .4;
  cursor: default;
}

.agc-nav--prev {
  left: 10px;
}

.agc-nav--next {
  right: 10px;
}

.agence-card.is-hidden {
  display: none !important;
}

/* =========================================================
   CARROUSEL DESTINATIONS / ACTIVITÉS (.dest-carousel)
   ========================================================= */
.dest-carousel {
  --dest-gap: 48px;
  position: relative;
  width: 100%;
  overflow: hidden;
  margin: 6px 0 0;
}

.dest-track {
  display: flex;
  gap: var(--dest-gap);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding: 6px 0 12px;
  scrollbar-gutter: stable;
}

.dest-card {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  flex: 0 0 calc((100% - 2 * var(--dest-gap)) / 3 - .5px);
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: #fff;
  color: inherit;
  text-decoration: none;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .06);
  border-bottom: 3px solid #002244;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  transition: transform .18s ease, box-shadow .18s ease;
}

.dest-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, .08);
}

@media (max-width: 1024px) {
  .dest-card {
    flex-basis: calc((100% - 1 * var(--dest-gap)) / 2 - .5px);
  }
}

@media (max-width: 640px) {
  .dest-card {
    flex-basis: 100%;
  }
}

.dest-photo {
  position: relative;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: #f3f4f6;
}

.dest-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  backface-visibility: hidden;
  transform: none;
  image-rendering: auto;
}

.dest-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 14px 16px;
}

.dest-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin: 8px 0 0;
  overflow: hidden;
  text-align: center;
}

.dest-logo img {
  display: block;
  width: auto !important;
  height: auto !important;
  max-height: 75px;
  max-width: 200px;
  min-width: 24px;
  min-height: 16px;
  object-fit: contain;
  image-rendering: auto;
}

@media (max-width: 640px) {
  .dest-logo img {
    max-height: 65px;
    max-width: 200px;
  }
}

.dest-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 999px;
  appearance: none;
  background: rgba(0, 0, 0, .45);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
  transition: background .15s ease;
}

.dest-nav:hover {
  background: rgba(0, 0, 0, .65);
}

.dest-nav:disabled {
  opacity: .4;
  cursor: default;
}

.dest-nav--prev {
  left: 10px;
}

.dest-nav--next {
  right: 10px;
}

/* Scrollbar destinations */
.dest-track::-webkit-scrollbar {
  height: 10px;
}

.dest-track::-webkit-scrollbar-thumb {
  background: #c7c7c7;
  border-radius: 8px;
}

.dest-track {
  scrollbar-width: thin;
}

/* =========================================================
   CRÉDITS PHOTO
   ========================================================= */
.dest-credit,
.agence-credit {
  position: absolute;
  left: 8px;
  bottom: 5px;
  max-width: 60%;
  overflow: hidden;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.45);
  color: rgba(255, 255, 255, 0.9);
  font-size: 10px;
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: 0.2px;
  text-overflow: ellipsis;
  white-space: nowrap;
  backdrop-filter: blur(1.5px);
}

@media (max-width: 900px) {
  .dest-credit,
  .agence-credit {
    max-width: 65%;
    padding: 2px 5px;
    font-size: 9.5px;
  }
}

@media (max-width: 500px) {
  .dest-credit,
  .agence-credit {
    max-width: 70%;
    padding: 2px 5px;
    font-size: 9px;
    line-height: 1.2;
    white-space: normal;
  }
}

/* =========================================================
   CARROUSEL ACTIVITÉS
   ========================================================= */
.dest-body-activite {
  padding: 14px 16px 16px;
}

.agence-infos-wrap {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  width: 100%;
  gap: 12px;
}

.agence-infos-left {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  min-width: 0;
  gap: 10px;
  text-align: left;
}

.agence-societe {
  font-size: 1.05rem;
  font-weight: 700;
  color: #000;
  line-height: 1.25;
}

.agence-souscat {
  font-size: 0.98rem;
  color: #6a6a6a;
  line-height: 1.3;
}

.agence-ville {
  font-size: 1rem;
  font-weight: 700;
  color: #000;
  line-height: 1.3;
}

.agence-right-col {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-end;
  min-width: 90px;
}

.agence-badge-space {
  min-height: 20px;
}

.badge-activite {
  padding: 4px 7px;
  border-radius: 5px;
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: .3px;
  white-space: nowrap;
}

.badge-activite.premium {
  background: #ED1C24;
}

.agence-logo-corner {
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  width: 90px;
}

.agence-logo-corner img {
  display: block;
  max-height: 40px;
  max-width: 100px;
  object-fit: contain;
}

/* =========================================================
   ÉLÉMENTS OPTIONNELS
   ========================================================= */
.dest-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .04);
  cursor: pointer;
  user-select: none;
}

.dest-chip input {
  width: 16px;
  height: 16px;
  accent-color: #002244;
}

.dest-chip span {
  font-size: 14px;
  font-weight: 600;
}