/* ===========================================================
   JustSticky v6.9 – originale + patch desktop frecce
   =========================================================== */

/* === Barra principale === */
.just-sticky-bar {
  position: fixed;
  left: 50%;
  top: var(--juststicky-top, 0px);
  transform: translateX(-50%);
  opacity: 0;
  z-index: 999;
visibility: hidden;
  pointer-events: none;
  background: #ffffff;
  border-radius: 999px;
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.15);
  transition: opacity .45s ease, box-shadow .3s ease;
  width: auto;
  max-width: 92%;
  overflow: visible;
  padding: 4px;
}

/* Stato visibile */
.just-sticky-bar.visible {
  visibility: visible;
  pointer-events: auto;
  opacity: 1;
  transform: translate(-50%, 0);
}

/* === Contenuto interno === */
.just-sticky-inner {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0px 14px;
  overflow-x: auto;
  scrollbar-width: none;
  white-space: nowrap;
  scroll-behavior: smooth;
  border-radius: 999px;
  position: relative;
  z-index: 5;
}
.just-sticky-inner::-webkit-scrollbar { display: none; }

.just-sticky-item { flex: 0 0 auto; }
 a.just-sticky-link {
    font-size: 14px;
 }

/* === Link === */
.just-sticky-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 15px;
  color: #0B2E63;
  background: transparent;
  text-decoration: none;
  padding: 4px 14px 6px 14px;
  border-radius: 999px;
  transition: all 0.25s ease;
}
.just-sticky-link:hover,
.just-sticky-link.active {
  background: #E83E72;
  color: #fff;
}

/* === Frecce === */
.just-sticky-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  color: #0B2E63;
  font-size: 14px;
  z-index: 99;
  opacity: 1;
  cursor: pointer;
  pointer-events: auto;
  box-shadow: 0 1px 5px rgba(0, 0, 0, 0.09);
}

.just-sticky-arrow.right { right: 0px; }
.just-sticky-arrow.left  { left: 0px; }

.just-sticky-arrow.right::after {
  content: "\f105";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
}
.just-sticky-arrow.left::after {
  content: "\f104";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
}

/* === Visibilità frecce === */
.just-sticky-inner.can-right ~ .just-sticky-arrow.right { display: flex; }
.just-sticky-inner.can-left  ~ .just-sticky-arrow.left  { display: flex; }

/* spazio per frecce */
.just-sticky-inner.has-overflow {
  padding-right: 36px !important;
}

/* === DESKTOP PATCH === */
@media (min-width: 769px) {
  .just-sticky-bar {
    max-width: 800px !important;
    width: auto !important;
  }
}

/* === MOBILE === */
@media (max-width: 768px) {
  .just-sticky-bar {
    top: var(--juststicky-top, 50px);
    border-radius: 24px;
    max-width: 94%;
    padding: 0px;
  }
  .just-sticky-inner {
    padding: 4px 10px;
    gap: 0.3rem;
  }
  .just-sticky-link {
    font-size: 14px;
    padding: 6px 10px;
  }
  a.just-sticky-link {
    font-size: 14px;
 }
}

/* layering */
header,
.elementor-location-header,
.elementor-sticky--active {
  z-index: 1000 !important;
}
/* ===========================================================
   ANIMAZIONE FRECCE MENU STICKY – SOLO DESKTOP
   =========================================================== */

@media (min-width: 769px) {

  @keyframes stickyArrowWaveRight {
    0%   { transform: translateY(-50%) translateX(0); }
    50%  { transform: translateY(-50%) translateX(6px); }
    100% { transform: translateY(-50%) translateX(0); }
  }

  @keyframes stickyArrowWaveLeft {
    0%   { transform: translateY(-50%) translateX(0); }
    50%  { transform: translateY(-50%) translateX(-6px); }
    100% { transform: translateY(-50%) translateX(0); }
  }

  .just-sticky-arrow.right {
    animation: stickyArrowWaveRight 1.8s ease-in-out infinite;
  }

  .just-sticky-arrow.left {
    animation: stickyArrowWaveLeft 1.8s ease-in-out infinite;
  }

}
