/* Navigation rapide pour remonter (voir section-nav.js). Couleurs de la marque : anthracite, argent, champagne. */
.bsn {
  position: fixed;
  z-index: 900;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  font-family: Inter, -apple-system, "Segoe UI", Roboto, sans-serif;
  transition: opacity 0.25s ease, visibility 0s linear 0.25s;
}
.bsn[data-show="1"] {
  opacity: 1;
  visibility: visible;
  transition-delay: 0s;
}
.bsn *,
.bsn *::before,
.bsn *::after {
  box-sizing: border-box;
}

/* Ordinateur : colonne de points sur le bord droit (zone cliquable de 32 × 32 px par point), dans la marge : ni le contenu ni les boutons
   ne sont recouverts. Le nom de la section s'affiche au survol et au focus. */
.bsn-dots {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  pointer-events: auto;
}
.bsn-dot {
  position: relative;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  color: #d4b896;
  cursor: pointer;
  text-decoration: none;
}
.bsn-dot i {
  display: block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.62;
  transition: transform 0.15s ease, opacity 0.15s ease, box-shadow 0.15s ease;
}
.bsn-dot svg {
  width: 16px;
  height: 16px;
  opacity: 0.8;
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.bsn-dot:hover i,
.bsn-dot:focus-visible i {
  opacity: 1;
  transform: scale(1.35);
}
.bsn-dot:hover svg,
.bsn-dot:focus-visible svg {
  opacity: 1;
  transform: translateY(-1px);
}
/* le point de la section la plus proche au-dessus : légèrement mis en valeur (plein et cerclé) */
.bsn-near i {
  opacity: 1;
  box-shadow: 0 0 0 4px rgba(212, 184, 150, 0.28);
}
.bsn-near svg {
  opacity: 1;
}
.bsn-dot:focus-visible,
.bsn-fab:focus-visible,
.bsn-item:focus-visible {
  outline: 2px solid #e8e8ed;
  outline-offset: 1px;
}
/* étiquette lisible : texte plus grand, fond argent contrasté */
.bsn-tip {
  position: absolute;
  right: calc(100% + 6px);
  top: 50%;
  padding: 8px 14px;
  border-radius: 10px;
  background: #e8e8ed;
  color: #16171c;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.42);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  opacity: 0;
  transform: translate(6px, -50%);
  pointer-events: none;
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.bsn-dot:hover .bsn-tip,
.bsn-dot:focus-visible .bsn-tip {
  opacity: 1;
  transform: translate(0, -50%);
}
.bsn-fab,
.bsn-menu {
  display: none;
}

/* Téléphone : bouton rond flottant (au-dessus des barres fixes du bas) + petit menu */
@media (max-width: 819.98px) {
  .bsn {
    top: auto;
    right: 14px;
    bottom: calc(env(safe-area-inset-bottom, 0px) + 18px + var(--bsn-lift, 0px));
    transform: none;
  }
  .bsn-dots {
    display: none;
  }
  .bsn-fab {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    margin-left: auto;
    border: 1px solid rgba(212, 184, 150, 0.4);
    border-radius: 50%;
    background: rgba(22, 23, 28, 0.62);
    color: #d4b896;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(8px);
    cursor: pointer;
    pointer-events: auto;
    transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  }
  .bsn-fab:active,
  .bsn-fab.is-down,
  .bsn-fab[aria-expanded="true"] {
    border-color: rgba(212, 184, 150, 0.75);
    background: rgb(22, 23, 28);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.5);
  }
  .bsn-fab svg {
    width: 20px;
    height: 20px;
  }
  .bsn-menu {
    position: absolute;
    right: 0;
    bottom: 54px;
    display: block;
    min-width: 210px;
    max-width: calc(100vw - 28px);
    margin: 0;
    padding: 6px;
    list-style: none;
    border: 1px solid rgba(212, 184, 150, 0.35);
    border-radius: 14px;
    background: rgba(28, 29, 35, 0.98);
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.5);
    pointer-events: auto;
  }
  .bsn-menu[hidden] {
    display: none;
  }
  .bsn-item {
    width: 100%;
    min-height: 44px;
    padding: 0 14px;
    border: 0;
    border-radius: 10px;
    background: none;
    color: #e8e8ed;
    font: 600 14.5px/1.2 Inter, -apple-system, "Segoe UI", sans-serif;
    text-align: left;
    cursor: pointer;
  }
  .bsn-item:hover,
  .bsn-item:active {
    background: rgba(212, 184, 150, 0.14);
  }
}

@media (prefers-reduced-motion: reduce) {
  .bsn,
  .bsn-fab,
  .bsn-dot i,
  .bsn-dot svg,
  .bsn-tip {
    transition: none;
  }
}
