/* ==========================================================================
   Product Launch Experience Styles
   MEGHRIKH SHIKSHA EVAM KALYAN SANSTHAN JODHPUR
   ========================================================================== */

:root {
  --launch-bg-dark: #070C18;
  --launch-bg-gradient: radial-gradient(circle at 50% 20%, #15254A 0%, #080D1A 65%, #050811 100%);
  --launch-gold: #D4AF37;
  --launch-gold-glow: rgba(212, 175, 55, 0.35);
  --launch-blue: #2563EB;
  --launch-blue-glow: rgba(37, 99, 235, 0.45);
  --launch-text: #F8FAFC;
  --launch-muted: #94A3B8;
  --launch-card-bg: rgba(255, 255, 255, 0.04);
  --launch-card-border: rgba(255, 255, 255, 0.09);
  --launch-glass-blur: blur(16px);
}

/* FOUC Prevention & Initial Visibility Controls */
html.app-pre-launch body {
  overflow: hidden !important;
}

html.app-pre-launch .normal-app-content {
  display: none !important;
}

html.app-launched #productLaunchOverlay {
  display: none !important;
}

html.app-launched .normal-app-content {
  display: block;
  animation: launchFadeIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes launchFadeIn {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --------------------------------------------------------------------------
   Launch Overlay Screen
   -------------------------------------------------------------------------- */
#productLaunchOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 9999999;
  background: var(--launch-bg-gradient);
  color: var(--launch-text);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 2.5rem 1.25rem;
  transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.75s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.75s ease;
}

#productLaunchOverlay.launching-active {
  pointer-events: none;
}

#productLaunchOverlay.launch-screen-exiting {
  opacity: 0;
  filter: blur(12px);
  transform: scale(1.05);
  pointer-events: none;
}

/* Ambient Radial Glows */
.launch-glow-sphere {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  pointer-events: none;
  z-index: 0;
}
.launch-glow-1 {
  top: 15%;
  left: 50%;
  transform: translateX(-50%);
  width: 480px;
  height: 320px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.22) 0%, transparent 70%);
}
.launch-glow-2 {
  bottom: 10%;
  left: 30%;
  width: 380px;
  height: 260px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.12) 0%, transparent 70%);
}

/* Subtle Animated Background Grid */
.launch-grid-pattern {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(circle at center, black 40%, transparent 85%);
  -webkit-mask-image: radial-gradient(circle at center, black 40%, transparent 85%);
  pointer-events: none;
  z-index: 0;
}

/* Launch Content Container */
.launch-content {
  position: relative;
  z-index: 1;
  max-width: 780px;
  width: 100%;
  text-align: center;
  margin: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Brand Logo Emblem */
.launch-logo-wrap {
  position: relative;
  display: inline-block;
  margin-bottom: 1.2rem;
}

.launch-logo-img {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--launch-gold);
  box-shadow: 0 0 35px var(--launch-gold-glow), 0 10px 25px rgba(0, 0, 0, 0.6);
  position: relative;
  z-index: 2;
  transition: transform 0.4s ease;
}

.launch-logo-wrap:hover .launch-logo-img {
  transform: scale(1.04);
}

.launch-logo-aura {
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--launch-gold-glow) 0%, transparent 70%);
  animation: logoPulse 3s ease-in-out infinite alternate;
  z-index: 1;
}

@keyframes logoPulse {
  0% { transform: scale(0.95); opacity: 0.5; }
  100% { transform: scale(1.15); opacity: 0.9; }
}

/* Launch Badge */
.launch-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1.1rem;
  background: rgba(37, 99, 235, 0.12);
  border: 1px solid rgba(37, 99, 235, 0.35);
  border-radius: 9999px;
  color: #93C5FD;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.15);
}

.launch-badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #38BDF8;
  box-shadow: 0 0 8px #38BDF8;
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.6; }
}

/* Headings */
.launch-title-hi {
  font-size: clamp(1.6rem, 3.5vw, 2.5rem);
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 0.6rem;
  color: #FFFFFF;
  letter-spacing: -0.5px;
}

.launch-title-en {
  font-size: clamp(0.85rem, 1.8vw, 1.05rem);
  font-weight: 600;
  color: var(--launch-gold);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.launch-desc {
  font-size: clamp(0.95rem, 1.8vw, 1.12rem);
  color: var(--launch-muted);
  line-height: 1.65;
  max-width: 620px;
  margin-bottom: 2.25rem;
}

/* Countdown Clock Component */
.launch-countdown {
  display: flex;
  gap: 1rem;
  margin-bottom: 2.5rem;
  justify-content: center;
  flex-wrap: wrap;
}

.countdown-box {
  background: var(--launch-card-bg);
  border: 1px solid var(--launch-card-border);
  backdrop-filter: var(--launch-glass-blur);
  -webkit-backdrop-filter: var(--launch-glass-blur);
  border-radius: 14px;
  min-width: 82px;
  padding: 0.9rem 0.75rem;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.countdown-box:hover {
  transform: translateY(-3px);
  border-color: rgba(212, 175, 55, 0.3);
}

.countdown-num {
  font-size: 1.85rem;
  font-weight: 800;
  color: #FFFFFF;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
  letter-spacing: -0.5px;
}

.countdown-lbl {
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--launch-muted);
  letter-spacing: 1px;
  margin-top: 0.35rem;
}

/* Primary "Launch Now" Button */
.launch-cta-wrap {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.btn-launch-now {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: linear-gradient(135deg, #1E40AF 0%, #2563EB 50%, #3B82F6 100%);
  color: #FFFFFF !important;
  font-size: 1.15rem;
  font-weight: 700;
  padding: 1rem 2.6rem;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 0 25px var(--launch-blue-glow), 0 10px 30px rgba(0, 0, 0, 0.5);
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.btn-launch-now:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 0 35px rgba(37, 99, 235, 0.7), 0 14px 35px rgba(0, 0, 0, 0.6);
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-launch-now:active {
  transform: translateY(1px) scale(0.99);
}

.btn-launch-now:focus-visible {
  outline: 3px solid var(--launch-gold);
  outline-offset: 3px;
}

/* Button Shimmer Sweep Effect */
.btn-launch-now::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -60%;
  width: 50%;
  height: 200%;
  background: linear-gradient(
    60deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transform: rotate(25deg);
  animation: btnShimmer 3.5s infinite;
}

@keyframes btnShimmer {
  0% { left: -60%; }
  35% { left: 140%; }
  100% { left: 140%; }
}

/* Launch Sequence State (LAUNCHING) */
.launching-state-active .btn-launch-now {
  background: linear-gradient(135deg, #047857 0%, #10B981 100%) !important;
  box-shadow: 0 0 40px rgba(16, 185, 129, 0.7) !important;
  transform: scale(1.03) !important;
  pointer-events: none;
}

.launch-progress-bar {
  width: 220px;
  height: 4px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 9999px;
  overflow: hidden;
  margin-top: 0.5rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.launching-state-active .launch-progress-bar {
  opacity: 1;
}

.launch-progress-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #38BDF8, #D4AF37);
  border-radius: 9999px;
  transition: width 1.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.launch-micro-note {
  font-size: 0.8rem;
  color: var(--launch-muted);
  opacity: 0.8;
}

/* Key Highlights Pills */
.launch-pillars {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  justify-content: center;
  margin-top: 2.25rem;
  max-width: 650px;
}

.pillar-pill {
  font-size: 0.78rem;
  font-weight: 500;
  padding: 0.35rem 0.85rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 9999px;
  color: #CBD5E1;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: background 0.25s ease, border-color 0.25s ease;
}

.pillar-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
}

.pillar-pill i {
  color: var(--launch-gold);
  font-size: 0.85rem;
}

/* Developer Mode Reset Floating Trigger */
.launch-reset-trigger {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 99999999;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.4rem 0.85rem;
  background: rgba(15, 23, 42, 0.85);
  color: #94A3B8;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 9999px;
  backdrop-filter: blur(8px);
  cursor: pointer;
  transition: all 0.25s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.launch-reset-trigger:hover {
  background: #1E293B;
  color: #F8FAFC;
  border-color: rgba(255, 255, 255, 0.35);
  transform: translateY(-2px);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  #productLaunchOverlay {
    padding: 1.5rem 1rem;
  }
  .launch-logo-img {
    width: 90px;
    height: 90px;
  }
  .countdown-box {
    min-width: 68px;
    padding: 0.75rem 0.5rem;
  }
  .countdown-num {
    font-size: 1.45rem;
  }
  .countdown-lbl {
    font-size: 0.6rem;
  }
  .btn-launch-now {
    font-size: 1rem;
    padding: 0.85rem 2rem;
  }
}
