/*
 * main.css — Main kiosk page styles
 * Responsibility: video background, top header, mascot stage, orbital bubbles, search dock
 */

/* ── Video Background ── */
#video-bg {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.65;
}

/* Dark gradient overlay on video */
#video-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(180deg,
      rgba(3, 7, 18, 0.60) 0%,
      rgba(3, 7, 18, 0.20) 40%,
      rgba(3, 7, 18, 0.60) 100%);
}

/* ── Top Header ── */
#top-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  padding: clamp(14px, 3vh, 28px) clamp(16px, 4vw, 32px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 10;
  background: linear-gradient(180deg, rgba(3, 7, 18, 0.90) 0%, rgba(3, 7, 18, 0) 100%);
}

#header-logo-text {
  font-size: clamp(18px, 3.5vw, 28px);
  font-weight: 800;
  letter-spacing: 0.05em;
  background: linear-gradient(135deg, #00E5FF 0%, #00A8FF 50%, #7B2CBF 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

#header-clock {
  font-size: clamp(12px, 2vw, 16px);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.50);
  letter-spacing: 0.08em;
}

/* ── Mascot center stage ── */
#mascot-stage {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 55%;
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 5;
}

#mascot-avatar {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  background: radial-gradient(circle at 35% 30%,
      rgba(255, 255, 255, 0.18) 0%,
      rgba(0, 165, 255, 0.12) 50%,
      rgba(0, 229, 255, 0.08) 100%);
  border: 1.5px solid rgba(0, 229, 255, 0.25);
  box-shadow:
    0 0 40px rgba(0, 165, 255, 0.20),
    0 0 80px rgba(0, 229, 255, 0.10),
    inset 0 0 30px rgba(0, 165, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: mascotFloat 5s ease-in-out infinite;
}

#mascot-avatar img {
  width: 75%;
  height: 75%;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.50));
  pointer-events: none;
}

#mascot-avatar .mascot-fallback {
  font-size: clamp(60px, 12vw, 100px);
  line-height: 1;
  pointer-events: none;
}

@keyframes mascotFloat {

  0%,
  100% {
    transform: translateY(0px) scale(1);
  }

  50% {
    transform: translateY(-12px) scale(1.02);
  }
}

#mascot-label {
  margin-top: clamp(10px, 2vh, 18px);
  font-size: clamp(13px, 2.2vw, 18px);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.55);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* ── Orbital action bubbles ── */
.orbit-bubble {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(6px, 1vh, 10px);
  cursor: pointer;
  z-index: 6;
  opacity: 0;
  pointer-events: none;
  border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1.5px solid rgba(255, 255, 255, 0.60);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease;
}

/* Bombastic Entrance & Organic Liquid Wiggle Trigger */
.orbit-bubble.pop-in {
  pointer-events: all;
}

#bubble-destination.pop-in {
  animation: bombasticPop 1.1s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.15s forwards,
             morphBlob 8s ease-in-out 1.25s infinite alternate,
             bubbleFloat 5s ease-in-out 1.25s infinite alternate;
}

#bubble-promotion.pop-in {
  animation: bombasticPop 1.1s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.35s forwards,
             morphBlob 7s ease-in-out 1.45s infinite alternate,
             bubbleFloat 4.5s ease-in-out 1.45s infinite alternate;
}

/* 🌀 540-degree spin and pop animation */
@keyframes bombasticPop {
  0% {
    opacity: 0;
    transform: scale(0) rotate(-540deg) translateY(200px);
  }

  70% {
    opacity: 1;
    transform: scale(1.2) rotate(15deg) translateY(-10px);
  }

  100% {
    opacity: 1;
    transform: scale(1) rotate(0deg) translateY(0);
  }
}

/* Subtle continuous vertical float keyframes */
@keyframes bubbleFloat {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }

  50% {
    transform: translateY(-10px) rotate(2deg);
  }
}

/* UI Fade In Helper */
.ui-fade {
  opacity: 0;
  transition: opacity 0.8s ease;
}

.ui-fade.show {
  opacity: 1;
}

.orbit-bubble:hover,
.orbit-bubble:active {
  transform: scale(1.12) translateY(-4px) !important;
}

/* Destination — top-left, cyan (Bigger, brighter & balanced) */
#bubble-destination {
  width: clamp(140px, 24vw, 210px);
  height: clamp(140px, 24vw, 210px);
  top: 16%;
  left: 3%;
  background: radial-gradient(circle at 32% 32%,
      rgba(255, 255, 255, 0.50) 0%,
      rgba(255, 255, 255, 0.12) 40%,
      rgba(0, 229, 255, 0.30) 80%,
      rgba(0, 229, 255, 0.65) 100%);
  box-shadow:
    inset -8px -8px 18px rgba(255, 255, 255, 0.40),
    inset 8px 8px 22px rgba(0, 229, 255, 0.55),
    0 0 30px #00E5FF,
    0 0 60px rgba(0, 229, 255, 0.35);
}

#bubble-destination:hover {
  box-shadow:
    inset -8px -8px 20px rgba(255, 255, 255, 0.50),
    inset 8px 8px 24px rgba(0, 229, 255, 0.70),
    0 0 40px #00FFFF,
    0 0 80px rgba(0, 229, 255, 0.50);
}

/* Promotion — lower-right, magenta (Balanced slightly below Destination) */
#bubble-promotion {
  width: clamp(140px, 24vw, 210px);
  height: clamp(140px, 24vw, 210px);
  top: 56%;
  right: 3%;
  background: radial-gradient(circle at 32% 32%,
      rgba(255, 255, 255, 0.50) 0%,
      rgba(255, 255, 255, 0.12) 40%,
      rgba(255, 0, 127, 0.30) 80%,
      rgba(255, 0, 127, 0.65) 100%);
  box-shadow:
    inset -8px -8px 18px rgba(255, 255, 255, 0.40),
    inset 8px 8px 22px rgba(255, 0, 127, 0.55),
    0 0 30px #FF007F,
    0 0 60px rgba(255, 0, 127, 0.35);
}

#bubble-promotion:hover {
  box-shadow:
    inset -8px -8px 20px rgba(255, 255, 255, 0.50),
    inset 8px 8px 24px rgba(255, 0, 127, 0.70),
    0 0 40px #FF1493,
    0 0 80px rgba(255, 0, 127, 0.50);
}

/* Logos inside orbital bubbles */
#bubble-destination .orbit-bubble-logo {
  width: 52%;
  height: 52%;
  object-fit: contain;
  border-radius: 24px;
  box-shadow: 0 4px 15px rgba(0, 229, 255, 0.35);
  filter: drop-shadow(0 4px 12px rgba(0, 229, 255, 0.60)) drop-shadow(0 2px 6px rgba(0, 0, 0, 0.50));
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#bubble-destination:hover .orbit-bubble-logo {
  transform: scale(1.1) rotate(-5deg);
}

#bubble-promotion .orbit-bubble-logo {
  width: 52%;
  height: 52%;
  object-fit: contain;
  border-radius: 24px;
  box-shadow: 0 4px 15px rgba(255, 0, 127, 0.35);
  filter: drop-shadow(0 4px 12px rgba(255, 0, 127, 0.60)) drop-shadow(0 2px 6px rgba(0, 0, 0, 0.50));
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#bubble-promotion:hover .orbit-bubble-logo {
  transform: scale(1.1) rotate(5deg);
}

.orbit-bubble-icon {
  font-size: clamp(32px, 6.5vw, 52px);
  line-height: 1;
  pointer-events: none;
  filter: drop-shadow(0 3px 10px rgba(0, 229, 255, 0.60));
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#bubble-destination:hover .orbit-bubble-icon {
  transform: scale(1.15) rotate(-5deg);
}

.orbit-bubble-label {
  display: inline-block;
  font-size: clamp(14px, 2.7vw, 21px);
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  pointer-events: none;
}

/* Vibrant Colorful Labels */
#bubble-destination .orbit-bubble-label {
  color: #00FFFF;
  background: linear-gradient(135deg, #00FFFF 0%, #70F3FF 50%, #00BFFF 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 0 8px rgba(0, 240, 255, 0.9)) drop-shadow(0 2px 4px rgba(0, 0, 0, 0.9));
}

#bubble-promotion .orbit-bubble-label {
  color: #FF3399;
  background: linear-gradient(135deg, #FF3399 0%, #FF66B2 40%, #FFD700 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 0 8px rgba(255, 0, 127, 0.9)) drop-shadow(0 2px 4px rgba(0, 0, 0, 0.9));
}

@keyframes morphBlob {
  0% {
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
  }

  25% {
    border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
  }

  50% {
    border-radius: 50% 50% 30% 60% / 30% 70% 70% 40%;
  }

  75% {
    border-radius: 70% 30% 50% 50% / 60% 40% 60% 40%;
  }

  100% {
    border-radius: 40% 60% 60% 40% / 40% 60% 30% 70%;
  }
}

/* ── Bottom search dock ── */
#bottom-dock {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: clamp(16px, 3vh, 26px) clamp(18px, 4vw, 32px) clamp(20px, 4vh, 36px);
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(0deg, rgba(3, 7, 18, 0.95) 0%, rgba(3, 7, 18, 0) 100%);
  z-index: 10;
}

#search-bar {
  flex: 1;
  max-width: 420px;
  height: clamp(44px, 7vh, 60px);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  display: flex;
  align-items: center;
  padding: 0 clamp(14px, 3vw, 22px);
  gap: 10px;
  cursor: text;
  transition: border-color 0.3s ease, background 0.3s ease;
}

#search-bar:hover {
  border-color: rgba(0, 229, 255, 0.40);
  background: rgba(0, 229, 255, 0.05);
}

#search-icon {
  font-size: clamp(14px, 2.5vw, 20px);
  opacity: 0.50;
}

#search-placeholder {
  font-size: clamp(11px, 1.8vw, 15px);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 0.05em;
}