/* Share button — dark glass default, light glass hover */
.share-btn {
  --glass-dark-bg: rgba(0, 0, 0, 0.45);
  --glass-dark-brd: rgba(255, 255, 255, 0.2);
  --glass-light-bg: rgba(255, 255, 255, 0.6);
  --glass-light-brd: rgba(0, 0, 0, 0.18);

  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  min-width: 30px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--glass-dark-brd);
  background: var(--glass-dark-bg);
  color: #fff;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s,
    box-shadow 0.2s;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}
.share-btn--icon {
  width: 44px;
  padding: 0;
}
.share-btn svg {
  width: 12px;
  height: 12px;
  display: block;
}
@supports (
  (backdrop-filter: blur(8px)) or (-webkit-backdrop-filter: blur(8px))
) {
  .share-btn {
    backdrop-filter: blur(8px) saturate(140%);
    -webkit-backdrop-filter: blur(8px) saturate(140%);
  }
}
.share-btn:hover {
  background: var(--glass-light-bg);
  border-color: var(--glass-light-brd);
  color: #111;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
}
.share-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.8), 0 0 0 6px rgba(0, 0, 0, 0.35);
}
.share-btn:active {
  transform: translateY(1px);
}

/* Share sheet */
.share-sheet {
  position: fixed;
  inset: auto 0 0 0;
  background: #1a1a1a;
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.15);
  padding: 16px;
  max-height: 80vh;
}
.sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}
#closeShare {
  background: transparent;
  border: none;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
}
.sheet-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.share-item {
  display: block;
  text-align: center;
  text-decoration: none;
  color: #111;
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 10px 8px;
  font-size: 0.9rem;
}
.share-item:hover {
  background: #f6f6f6;
}
.sheet-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}
.copy-link {
  padding: 0.5rem 0.9rem;
  border-radius: 8px;
  border: 1px solid #000000;
  background: #000000;
  cursor: pointer;
}
.copy-link:hover {
  background: #383838;
}
.copy-status {
  font-size: 0.9rem;
  color: #07a;
}
@media (min-width: 768px) {
  .share-sheet {
    inset: 50% auto auto 50%;
    transform: translate(-50%, -50%);
    width: 520px;
    border-radius: 16px;
  }

  .share-btn svg {
    width: 22px;
    height: 22px;
  }

  .share-btn {
    height: 44px;
    min-width: 44px;
  }
}
