/* gathering-reveal.css — GatheringReveal full-screen celebration overlay */
/* Travel colours are referenced directly in gathering-reveal.js */

/* Full-screen dimming overlay */
.gr-overlay {
  position: fixed;
  inset: 0;
  z-index: 9998;
  background: rgba(0, 0, 0, 0);
  pointer-events: all;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.8s ease;
}

.gr-overlay.gr-dimmed {
  background: rgba(0, 0, 0, 0.6);
}

/* Confetti canvas — sits above overlay, never intercepts clicks */
.gr-canvas {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
}

/* Central modal content */
.gr-modal {
  position: relative;
  z-index: 10000;
  text-align: center;
  color: #ffffff;
  user-select: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 32px;
  pointer-events: none;
}

/* Falling icon */
.gr-icon {
  font-size: 5rem;
  line-height: 1;
  transform: translateY(-120vh);
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: block;
  will-change: transform;
  pointer-events: none;
}

.gr-icon.landed {
  transform: translateY(0);
}

/* Pulse animation for icon after landing */
@keyframes gr-pulse {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.15); }
  100% { transform: scale(1); }
}

.gr-icon.pulsing {
  animation: gr-pulse 0.3s ease-in-out forwards;
}

/* Text reveal area */
.gr-text {
  font-size: 1.6rem;
  font-weight: 700;
  min-height: 2.5rem;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
  pointer-events: none;
}

/* "Amazing! Close" button — appears at phase 4 */
.gr-close-btn {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10001;
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 9999px;
  padding: 12px 28px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.4s ease, background 0.2s ease;
  backdrop-filter: blur(4px);
  min-height: 44px;
}

.gr-close-btn.visible {
  opacity: 1;
}

.gr-close-btn:hover {
  background: rgba(255, 255, 255, 0.25);
}

.gr-close-btn:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 3px;
}

/* Skip button — always visible when overlay shown */
.gr-skip-btn {
  position: fixed;
  top: 1rem;
  right: 1.2rem;
  z-index: 10001;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  padding: 6px 14px;
  font-size: 0.82rem;
  cursor: pointer;
  transition: background 0.2s ease;
  min-height: 36px;
}

.gr-skip-btn:hover {
  background: rgba(255, 255, 255, 0.16);
}

.gr-skip-btn:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 2px;
}

/* Spark elements launched during phase 1 */
.gr-spark {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  animation: gr-float var(--dur, 2s) var(--delay, 0s) ease-in forwards;
  opacity: 0;
}

@keyframes gr-float {
  0%   { transform: translateY(0) scale(1); opacity: 0.9; }
  80%  { opacity: 0.7; }
  100% { transform: translateY(-60vh) scale(0.4); opacity: 0; }
}

/* Reduced motion — collapse everything to instant */
@media (prefers-reduced-motion: reduce) {
  .gr-overlay,
  .gr-icon,
  .gr-close-btn,
  .gr-skip-btn,
  .gr-spark {
    transition: none !important;
    animation: none !important;
  }
  .gr-icon { transform: translateY(0) !important; }
  .gr-close-btn { opacity: 1 !important; }
}
