.lightbox-for-wp-link {
  display: block;
  cursor: zoom-in;
  position: relative;
}

.lightbox-for-wp-link img {
  transition:
    transform 0.3s ease,
    opacity 0.3s ease;
}

.lightbox-for-wp-link:hover img {
  opacity: 0.9;
}

.lightbox-for-wp-link::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0);
  width: 50px;
  height: 50px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3Cline x1='11' y1='8' x2='11' y2='14'/%3E%3Cline x1='8' y1='11' x2='14' y2='11'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0;
  transition:
    transform 0.3s ease,
    opacity 0.3s ease;
  pointer-events: none;
  z-index: 10;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.lightbox-for-wp-link:hover::before {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}

.wp-block-image.has-lightbox figure {
  cursor: zoom-in;
}

/* Lightbox Custom Styles */
.lwp-lightbox-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.lwp-lightbox-overlay.lwp-active {
  opacity: 1;
}

.lwp-lightbox-container {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lwp-lightbox-toolbar {
  position: fixed;
  top: 20px;
  right: 20px;
  display: flex;
  gap: 8px;
  z-index: 1000000;
}

.lwp-lightbox-btn {
  width: 44px;
  height: 44px;
  background: rgba(0, 0, 0, 0.6);
  border: none;
  border-radius: 8px;
  color: #fff;
  cursor: pointer;
  transition:
    background 0.2s ease,
    transform 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lwp-lightbox-btn:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: scale(1.05);
}

.lwp-lightbox-btn svg {
  width: 20px;
  height: 20px;
}

.lwp-lightbox-close:hover {
  background: rgba(220, 53, 69, 0.9);
}

.lwp-lightbox-content {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lwp-lightbox-content img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  transition: transform 0.2s ease;
  cursor: zoom-in;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
}

.lwp-lightbox-content img.lwp-zoomed {
  cursor: grab;
}

.lwp-lightbox-content img.lwp-zoomed:active {
  cursor: grabbing;
}

.lwp-lightbox-title {
  color: #fff;
  font-size: 16px;
  margin-top: 16px;
  text-align: center;
  max-width: 80%;
}
