/* ==========================================================================
   Modal de consentement aux cookies - Bon Air Club
   ========================================================================== */

html.bac-cookie-open,
html.bac-cookie-open body {
  overflow: hidden;
}

/* Masque la barre Avada native lorsque la modal est active */
body.bac-cookie-active .fusion-privacy-bar {
  display: none !important;
}

.bac-cookie-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background-color: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  opacity: 0;
  transition: opacity 0.25s ease;
  box-sizing: border-box;
}

.bac-cookie-overlay.is-open {
  display: flex;
  opacity: 1;
}

.bac-cookie-modal {
  width: 100%;
  max-width: 960px;
  max-height: calc(100vh - 40px);
  background-color: #FBF7F0;
  border-radius: 18px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 35.5% 64.5%;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  color: #241911;
  font-family: "Roobert Arabic", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  box-sizing: border-box;
}

.bac-cookie-modal *,
.bac-cookie-modal *::before,
.bac-cookie-modal *::after {
  box-sizing: border-box;
}

/* Colonne image à gauche */
.bac-cookie-modal__media {
  position: relative;
  min-height: 100%;
  background-color: #E8DFD1;
  overflow: hidden;
}

.bac-cookie-modal__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Colonne contenu à droite */
.bac-cookie-modal__body {
  padding: 34px 42px 32px;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.bac-cookie-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.bac-cookie-modal__brand {
  display: inline-flex;
  align-items: center;
}

.bac-cookie-modal__logo {
  display: block;
  height: 34px;
  width: auto;
  margin: 0;
}

.bac-cookie-modal__skip {
  appearance: none;
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 500;
  color: #241911;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.bac-cookie-modal__skip:hover,
.bac-cookie-modal__skip:focus-visible {
  opacity: 0.7;
}

.bac-cookie-modal__view {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.bac-cookie-modal__view[hidden] {
  display: none;
}

.bac-cookie-modal__title {
  margin: 22px 0 12px;
  font-size: clamp(25px, 2.8vw, 34px);
  font-weight: 700;
}

.bac-cookie-modal__intro {
  margin: 0 0 24px;
  font-size: 15.5px;
  line-height: 1.5;
  color: #2C2118;
}

/* Liste des 3 points */
.bac-cookie-modal__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bac-cookie-modal__item {
  display: grid;
  grid-template-columns: 32px 1px 1fr;
  align-items: center;
  gap: 16px;
}

.bac-cookie-modal__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}

.bac-cookie-modal__icon img {
  display: block;
  width: 26px;
  height: 26px;
  object-fit: contain;
  /* Teinte brun chaud assortie à la maquette */
  filter: brightness(0) saturate(100%) invert(24%) sepia(24%) saturate(850%) hue-rotate(344deg) brightness(92%) contrast(90%);
}

.bac-cookie-modal__divider {
  display: block;
  width: 1px;
  height: 36px;
  background-color: #C9B9A6;
}

.bac-cookie-modal__item-text {
  font-size: 14px;
  line-height: 1.45;
  color: #2C2118;
}

.bac-cookie-modal__item-text strong {
  font-weight: 700;
  color: #1F150D;
}

/* Pied de la modal */
.bac-cookie-modal__footer {
  margin-top: 28px;
  padding-top: 4px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  row-gap: 14px;
  column-gap: 16px;
}

.bac-cookie-modal__links {
  grid-column: 1;
  grid-row: 2;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.bac-cookie-modal__link {
  appearance: none;
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font-family: inherit;
  font-size: 12.5px;
  color: #2C2118;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.bac-cookie-modal__link:hover,
.bac-cookie-modal__link:focus-visible {
  opacity: 0.7;
}

.bac-cookie-modal__actions {
  display: contents;
}

.bac-cookie-btn-wrap[data-bac-cookie-action="accept"] {
  grid-column: 1 / -1;
  grid-row: 1;
  justify-self: end;
  order: -1;
}

.bac-cookie-modal__actions .bac-cookie-modal__skip {
  grid-column: 2;
  grid-row: 2;
  justify-self: end;
}

.bac-cookie-btn-wrap {
  display: inline-flex;
}

body .bac-cookie-modal .fusion-button {
  margin: 0;
  white-space: nowrap;
  padding-top: 5px;
  padding-right: 15px;
  padding-bottom: 5px;
  padding-left: 15px;
  line-height: var(--button_line_height, 1);
  font-size: 13px;
  letter-spacing: 4px;
}

.bac-cookie-modal .fusion-button.red {
  --button_gradient_top_color: var(--awb-color6);
  --button_gradient_bottom_color: var(--awb-color6);
  --button_gradient_top_color_hover: var(--awb-color6);
  --button_gradient_bottom_color_hover: var(--awb-color6);
  --button_border_color: #d44924;
  --button_border_hover_color: #d44924;
  --button_accent_color: #ffffff;
  --button_accent_hover_color: #ffffff;
  background: var(--awb-color6);
  border-color: #d44924;
  color: #ffffff;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media only screen and (max-width: 900px) {
  .bac-cookie-modal {
    grid-template-columns: 32% 68%;
  }

  .bac-cookie-modal__body {
    padding: 26px 28px;
  }
}

@media only screen and (max-width: 720px) {
  .bac-cookie-overlay {
    padding: 14px;
  }

  .bac-cookie-modal {
    grid-template-columns: 1fr;
    max-height: calc(100vh - 28px);
    overflow-y: auto;
    border-radius: 16px;
  }

  .bac-cookie-modal__media {
    display: none;
  }

  .bac-cookie-modal__body {
    padding: 20px 20px 24px;
    overflow-y: visible;
  }

  .bac-cookie-modal__logo {
    height: 34px;
  }

  .bac-cookie-modal__title {
    margin: 16px 0 10px;
  }

  .bac-cookie-modal__intro {
    font-size: 14.5px;
    margin-bottom: 18px;
  }

  .bac-cookie-modal__list {
    gap: 14px;
  }

  .bac-cookie-modal__item {
    grid-template-columns: 28px 1px 1fr;
    gap: 12px;
  }

  .bac-cookie-modal__icon {
    width: 28px;
    height: 28px;
  }

  .bac-cookie-modal__icon img {
    width: 22px;
    height: 22px;
  }

  .bac-cookie-modal__divider {
    height: 30px;
  }

  .bac-cookie-modal__item-text {
    font-size: 13.5px;
  }

  .bac-cookie-modal__footer {
    margin-top: 22px;
    display: flex;
    flex-direction: column-reverse;
    align-items: stretch;
    gap: 14px;
  }

  .bac-cookie-modal__actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-left: 0;
  }

  .bac-cookie-btn-wrap,
  .bac-cookie-modal .fusion-button {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .bac-cookie-modal__links {
    justify-content: center;
  }
}