/* hero-portrait-3d.css — toggle button & canvas styling
 * Paired with /static/js/hero-portrait-3d.js
 */

.hero3d-toggle {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 20;
  min-width: 30px;
  height: 22px;
  padding: 0 7px;
  border-radius: 11px;
  background: rgba(6, 10, 22, 0.72);
  border: 1px solid rgba(201, 169, 110, 0.55);
  color: rgba(224, 200, 140, 0.95);
  font: 700 10px/1 'Share Tech Mono', 'Courier New', monospace;
  letter-spacing: 0.8px;
  cursor: pointer;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: transform 0.15s, background 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  opacity: 0.82;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
  user-select: none;
  -webkit-user-select: none;
}

.hero3d-toggle:hover {
  opacity: 1;
  transform: scale(1.08);
  background: rgba(10, 14, 26, 0.85);
  border-color: rgba(232, 200, 140, 0.9);
  color: #f5d896;
  box-shadow: 0 0 10px rgba(201, 169, 110, 0.4);
}

.hero3d-toggle:active {
  transform: scale(0.96);
}

.hero3d-toggle.active {
  background: rgba(79, 195, 232, 0.22);
  border-color: rgba(79, 195, 232, 0.85);
  color: #b4e8ff;
  box-shadow: 0 0 10px rgba(79, 195, 232, 0.35);
}

.hero3d-toggle.active:hover {
  background: rgba(79, 195, 232, 0.35);
  border-color: #6cd8ff;
  box-shadow: 0 0 14px rgba(79, 195, 232, 0.55);
}

.hero3d-toggle .hero3d-ico {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 4px currentColor;
  opacity: 0.9;
  animation: hero3d-pulse 2s ease-in-out infinite;
}
.hero3d-toggle.active .hero3d-ico {
  animation-duration: 1s;
}

@keyframes hero3d-pulse {
  0%, 100% { opacity: 0.55; transform: scale(1); }
  50%      { opacity: 1;    transform: scale(1.3); }
}

.hero3d-toggle .hero3d-lbl {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
}

/* The live 3D canvas sits absolutely over the hidden <img> */
.hero3d-canvas {
  background: transparent;
  display: block;
  cursor: grab;
  touch-action: none;
}
.hero3d-canvas:active {
  cursor: grabbing;
}

/* Responsive: even smaller button on tight screens */
@media (max-width: 600px) {
  .hero3d-toggle {
    min-width: 26px;
    height: 20px;
    padding: 0 5px;
    top: 4px;
    right: 4px;
  }
  .hero3d-toggle .hero3d-lbl { font-size: 9px; }
}
