/* IMMERSIVE INDIA EXPERIENCE CSS */

/* 1. Audio Start Button */
#start-audio-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1000;
  background: linear-gradient(135deg, var(--accent-blue, #ff9933), var(--accent-cyan, #e91e63));
  color: #fff;
  border: none;
  padding: 12px 20px;
  border-radius: 30px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(255, 153, 51, 0.5);
  transition: all 0.3s ease;
  font-family: var(--font-sans);
  letter-spacing: 0.04em;
}
#start-audio-btn:hover {
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 8px 30px rgba(255, 153, 51, 0.7), 0 0 15px rgba(233, 30, 99, 0.4);
}
#start-audio-btn.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(20px);
}

/* 2. Peacock cursor trails are handled in styles.css */

/* 3. Weather / Terrain Overlay */
#weather-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1; /* Below content, above background */
  opacity: 0;
  transition: opacity 1.5s ease, background 1.5s ease;
}
#weather-overlay.dust {
  opacity: 0.15;
  background: linear-gradient(to bottom, #d35400, #f39c12);
  mix-blend-mode: color-dodge;
}
#weather-overlay.rain {
  opacity: 0.2;
  background: linear-gradient(to bottom, #004d40, #001f1a);
  mix-blend-mode: multiply;
}
/* Rain animation */
.raindrop {
  position: absolute;
  background: rgba(255, 255, 255, 0.4);
  width: 1px;
  height: 20px;
  animation: rainDropAnim 0.5s linear infinite;
}
@keyframes rainDropAnim {
  0% { transform: translateY(-100vh); opacity: 0; }
  50% { opacity: 1; }
  100% { transform: translateY(100vh); opacity: 0; }
}

/* 4. The Unpredictable Cow */
#datagap {
  position: relative;
  overflow: hidden;
}
#cow-walker {
  position: absolute;
  bottom: 5%;
  left: -250px;
  width: 200px;
  height: auto;
  z-index: 50;
  opacity: 1;
  pointer-events: none;
  animation: walkAcross 18s linear infinite;
}
@keyframes walkAcross {
  0% { left: -250px; transform: scaleX(1); }
  45% { left: 45%; }
  50% { left: 50%; transform: scaleX(1); }
  55% { left: 50%; transform: scaleX(-1); } /* Looks around */
  100% { left: 110%; transform: scaleX(1); }
}

/* 5. Street Vendor Easter Egg */
#chai-walla {
  position: fixed;
  bottom: 0;
  left: -250px;
  width: 200px;
  height: auto;
  z-index: 100;
  transition: left 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  pointer-events: none;
}
#chai-walla.peek {
  left: -20px; /* Peeks into screen */
}

/* 6. Diwali Firecrackers */
.firecracker {
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-orange, #ffb300);
  box-shadow: 0 0 12px var(--accent-orange, #ffb300), 0 0 24px var(--holi-pink, #ff1493);
  pointer-events: none;
  animation: explode 1.8s ease-out forwards;
}
@keyframes explode {
  0% { transform: scale(1); opacity: 1; }
  30% { transform: scale(8); opacity: 0.9; background: var(--holi-pink, #ff1493); }
  60% { transform: scale(18); opacity: 0.5; background: var(--marigold, #FFD700); }
  100% { transform: scale(30); opacity: 0; }
}

/* 7. Rangoli Loading Animation */
#rangoli-loader-container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 10;
  transition: opacity 1s ease;
}
#rangoli-loader {
  width: 150px;
  height: 150px;
  animation: spinRangoli 8s linear infinite;
  filter: drop-shadow(0 0 20px var(--brand-accent));
}
#rangoli-text {
  margin-top: 20px;
  color: var(--brand-accent);
  font-family: var(--font-display);
  letter-spacing: 2px;
  text-transform: uppercase;
  font-size: 14px;
  animation: pulseText 2s infinite;
}
@keyframes spinRangoli {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
@keyframes pulseText {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}
.sim-loaded #rangoli-loader-container {
  opacity: 0;
  pointer-events: none;
}
.sim-loaded #splatCanvas {
  transition: opacity 2s ease 1s;
  opacity: 1 !important;
}

/* 8. Pothole Scroll Glitch */
body.pothole-glitch {
  animation: potholeBump 0.4s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}
@keyframes potholeBump {
  0% { transform: translateY(0); }
  20% { transform: translateY(15px); }
  40% { transform: translateY(-10px); }
  60% { transform: translateY(5px); }
  80% { transform: translateY(-2px); }
  100% { transform: translateY(0); }
}

/* 9. Auto-Rickshaw Fare Meter Ticker */
.fare-meter {
  font-family: 'Courier New', Courier, monospace !important;
  background: #222;
  color: var(--accent-orange) !important;
  padding: 4px 12px;
  border: 2px solid #333;
  border-radius: 4px;
  box-shadow: inset 0 0 10px rgba(0,0,0,0.8);
  display: inline-block;
  min-width: 120px;
  text-align: right;
  letter-spacing: 2px;
}
#fare-ticker {
  font-weight: bold;
}
