/* Botón flotante en contenedores con posición relativa */
.has-share { position: relative; }

.share-btn {
    position: absolute;
    bottom: .5rem;
    right: .5rem;
    z-index: 3;
    background: #111;
    color: #fff;
    border: 0;
    padding: 0.3rem;
    border-radius: 100px;
    font: inherit;
    cursor: pointer;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.6;
    border: 1px solid transparent;
}

.share-btn:hover {
  opacity: 1 !important;
  border-color: #1c1c1c;
  background-color: #ffffffcc;
}
.share-btn:hover svg path {
  fill: #1c1c1c;
}
.share-btn svg {
  width: 1rem;
  height: 1rem;
}
.share-btn svg path {
  fill: #fff;
}

.share-btn:focus-visible { outline: 2px solid #0af; outline-offset: 2px; }

/* Menú fallback */
.share-menu {
  position: absolute;
  top: 2.4rem;
  right: .5rem;
  z-index: 4;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: .6rem;
  box-shadow: 0 10px 20px rgba(0,0,0,.12);
  min-width: 220px;
  display: none !important;
}
.share-menu[hidden] { display: none; }
.share-menu ul { list-style: none; margin: 0; padding: .25rem; }
.share-menu li { margin: 0; }
.share-menu a, .share-menu button {
  display: block;
  width: 100%;
  text-align: left;
  padding: .6rem .75rem;
  background: none;
  border: 0;
  font: inherit;
  color: #111;
  text-decoration: none;
  cursor: pointer;
}
.share-menu a:hover, .share-menu button:hover { background: #f5f5f5; }

/* Opcional: estiliza la banda de información de cada grid item */
.photo-grid-item .overlay-info {
  position: absolute;
  left: .5rem;
  bottom: .5rem;
  right: .5rem;
  z-index: 2;
  color: #fff;
  text-shadow: 0 2px 6px rgba(0,0,0,.5);
}
