/* ==========================================================================
   Wudcaso Home Studio - Ultra-Premium Motion Design & Interactive Engine
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400;1,700&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

:root {
  --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  
  --color-gold: #e5a952;
  --color-gold-glow: rgba(229, 169, 82, 0.4);
  --color-amber-accent: #c67d3b;
  --color-dark-obsidian: #090a0d;
  --color-dark-surface: #12141a;
  --color-dark-card: #181b23;
  --color-glass-border: rgba(255, 255, 255, 0.08);
  --color-glass-bg: rgba(18, 20, 26, 0.75);

  --color-white-bg: #fcfbf9;
  --color-white-card: #ffffff;
  --color-white-border: rgba(0, 0, 0, 0.08);
  --color-dark-text: #111318;
}

/* --------------------------------------------------
   Lenis Smooth Scrolling
-------------------------------------------------- */
html.lenis, html.lenis body {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}

.lenis.lenis-stopped {
  overflow: hidden;
}

.lenis.lenis-scrolling iframe {
  pointer-events: none;
}

/* --------------------------------------------------
   Global Base & Typography
-------------------------------------------------- */
body {
  font-family: var(--font-sans);
  background-color: var(--color-dark-obsidian);
  color: #f3f4f6;
  overflow-x: hidden;
}

.font-display {
  font-family: var(--font-display);
}

.font-sans {
  font-family: var(--font-sans);
}

/* --------------------------------------------------
   Motion Viewport & Storytelling Canvas
-------------------------------------------------- */
#motion-canvas-wrapper {
  position: relative;
  width: 100%;
  background-color: var(--color-dark-obsidian);
  z-index: 10;
}

.motion-stage {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1200px;
  background: radial-gradient(circle at 50% 30%, #1c1813 0%, #0c0d10 80%);
}

.motion-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  will-change: transform, opacity;
  transform-style: preserve-3d;
}

.motion-layer-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Custom gradient overlays for cinematic lighting */
.layer-sky-gradient {
  background: linear-gradient(180deg, rgba(9, 10, 13, 0.4) 0%, rgba(9, 10, 13, 0.1) 40%, rgba(9, 10, 13, 0.9) 100%);
}

.layer-vignette {
  background: radial-gradient(circle at 50% 50%, rgba(0, 0, 0, 0) 30%, rgba(9, 10, 13, 0.85) 100%);
}

.glow-ambient-gold {
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(229, 169, 82, 0.15) 0%, rgba(229, 169, 82, 0) 70%);
  filter: blur(60px);
  pointer-events: none;
}

.glow-ambient-cyan {
  position: absolute;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.08) 0%, rgba(56, 189, 248, 0) 70%);
  filter: blur(80px);
  pointer-events: none;
}

/* --------------------------------------------------
   Glassmorphism & Luxury Cards
-------------------------------------------------- */
.glass-panel {
  background: rgba(20, 23, 31, 0.65);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--color-glass-border);
}

.glass-panel-gold {
  background: linear-gradient(135deg, rgba(24, 27, 35, 0.8) 0%, rgba(35, 27, 20, 0.8) 100%);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(229, 169, 82, 0.25);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(229, 169, 82, 0.3);
}

.glass-pill {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.text-gold-gradient {
  background: linear-gradient(135deg, #ffffff 0%, #f7d6a5 50%, #e5a952 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-bronze-gradient {
  background: linear-gradient(135deg, #111318 0%, #c67d3b 60%, #b87333 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* --------------------------------------------------
   WHITE BACKGROUND PRODUCT SHOWCASE STYLES
-------------------------------------------------- */
.showcase-white-wrapper {
  position: relative;
  background-color: var(--color-white-bg);
  color: var(--color-dark-text);
  overflow: hidden;
  z-index: 20;
}

.product-texture-stage {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.product-flying-canvas {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transform-style: preserve-3d;
  perspective: 1000px;
}

.product-texture-frame {
  position: relative;
  width: 100%;
  max-width: 520px;
  height: 480px;
  border-radius: 2rem;
  overflow: hidden;
  background: radial-gradient(circle at 50% 50%, #ffffff 0%, #f3f0e8 100%);
  border: 1px solid var(--color-white-border);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.12), 0 10px 20px rgba(198, 125, 59, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  will-change: transform;
}

.product-texture-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.1s linear;
  will-change: transform;
}

/* Floating Spec Callout Tooltip Dot */
.texture-callout-dot {
  position: absolute;
  z-index: 30;
  display: flex;
  items-center;
  gap: 0.5rem;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.texture-dot-ping {
  position: relative;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #c67d3b;
  box-shadow: 0 0 15px rgba(198, 125, 59, 0.6);
}

.texture-dot-ping::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid #c67d3b;
  animation: pingRing 2s infinite ease-out;
}

@keyframes pingRing {
  0% {
    transform: scale(0.8);
    opacity: 1;
  }
  100% {
    transform: scale(2.2);
    opacity: 0;
  }
}

.texture-tooltip-pill {
  background: rgba(17, 19, 24, 0.9);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.4rem 0.85rem;
  border-radius: 9999px;
  border: 1px solid rgba(229, 169, 82, 0.4);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
  white-space: nowrap;
  backdrop-filter: blur(10px);
}

.white-glass-card {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.05);
}

/* --------------------------------------------------
   Progress & Floating Navigation
-------------------------------------------------- */
.scroll-progress-line {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, #c67d3b, #e5a952, #ffd166);
  z-index: 100;
  transform-origin: left;
  transform: scaleX(0);
}

.stage-step-pill {
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.stage-step-pill.active {
  background: #e5a952;
  color: #090a0d;
  font-weight: 700;
  box-shadow: 0 0 20px rgba(229, 169, 82, 0.5);
}

.product-white-pill {
  transition: all 0.3s ease;
}

.product-white-pill.active {
  background: #c67d3b;
  color: #ffffff;
  box-shadow: 0 4px 15px rgba(198, 125, 59, 0.3);
}

/* --------------------------------------------------
   Interactive Buttons & Badges
-------------------------------------------------- */
.btn-gold {
  position: relative;
  background: linear-gradient(135deg, #e5a952 0%, #c67d3b 100%);
  color: #090a0d;
  font-weight: 700;
  box-shadow: 0 10px 25px rgba(229, 169, 82, 0.25);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.btn-gold:hover {
  box-shadow: 0 15px 35px rgba(229, 169, 82, 0.45);
  transform: translateY(-2px);
  color: #000000;
}

.btn-dark-action {
  background: #111318;
  color: #ffffff;
  font-weight: 700;
  transition: all 0.3s ease;
  box-shadow: 0 10px 25px rgba(17, 19, 24, 0.2);
}

.btn-dark-action:hover {
  background: #c67d3b;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(198, 125, 59, 0.35);
}

.btn-glass {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

/* --------------------------------------------------
   Pulse & Animations
-------------------------------------------------- */
@keyframes pulseGlow {
  0%, 100% {
    opacity: 0.3;
    transform: scale(1);
  }
  50% {
    opacity: 0.6;
    transform: scale(1.08);
  }
}

.animate-pulse-glow {
  animation: pulseGlow 6s ease-in-out infinite;
}

@keyframes floatSlow {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-10px) rotate(1deg);
  }
}

.animate-float {
  animation: floatSlow 5s ease-in-out infinite;
}

/* Custom Scrollbar for Luxury Dark Theme */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: #090a0d;
}

::-webkit-scrollbar-thumb {
  background: #2b303d;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #e5a952;
}

/* --------------------------------------------------
   RESPONSIVE MOBILE OVERRIDES (max-width: 767px)
-------------------------------------------------- */
@media (max-width: 767px) {
  /* 1. Prevent hero section pinning & blank areas on mobile */
  #motion-canvas-wrapper {
    position: relative !important;
    height: auto !important;
    overflow: visible !important;
    background: #090a0d !important;
  }

  .motion-stage {
    position: relative !important;
    height: auto !important;
    min-height: auto !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    padding: 5rem 1rem 3rem 1rem !important;
    background: #090a0d !important;
    overflow: visible !important;
  }

  .motion-layer {
    position: relative !important;
    height: auto !important;
    min-height: auto !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    opacity: 1 !important;
    transform: none !important;
    pointer-events: auto !important;
    margin-bottom: 4rem !important;
  }

  /* Specific Layer Overrides */
  #layer-sky {
    position: relative !important;
    min-height: 90vh !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    margin-bottom: 2rem !important;
  }

  #layer-sky .motion-layer-img {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    z-index: 1 !important;
  }

  #text-sky {
    position: relative !important;
    z-index: 20 !important;
    padding: 2rem 1rem !important;
    opacity: 1 !important;
    transform: none !important;
  }

  #layer-showroom {
    position: relative !important;
    width: 100% !important;
    max-width: 600px !important;
    margin: 0 auto 4rem auto !important;
  }

  #layer-showroom .motion-layer-img {
    height: 250px !important;
    border-radius: 1.5rem !important;
    object-fit: cover !important;
  }

  #text-showroom {
    position: relative !important;
    opacity: 1 !important;
    transform: none !important;
    padding: 1.5rem 0.5rem !important;
    display: flex !important;
  }

  #layer-all-products {
    position: relative !important;
    width: 100% !important;
    max-width: 600px !important;
    margin: 0 auto 2rem auto !important;
  }

  #layer-all-products .motion-layer-img {
    max-height: 280px !important;
    object-contain: cover !important;
  }

  #text-all-products {
    position: relative !important;
    opacity: 1 !important;
    transform: none !important;
    padding: 1.5rem 0.5rem !important;
    bottom: auto !important;
  }

  /* 2. White products showcase mobile compatibility */
  .showcase-white-wrapper {
    height: auto !important;
    overflow: visible !important;
  }

  #pinned-white-canvas {
    height: auto !important;
    display: flex !important;
    flex-direction: column !important;
  }

  .product-texture-stage {
    position: relative !important;
    height: auto !important;
    min-height: auto !important;
    padding: 4rem 1rem !important;
    display: block !important;
    overflow: visible !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
  }

  .product-texture-frame {
    height: 250px !important;
    max-width: 100% !important;
    margin: 0 auto 2rem auto !important;
    border-radius: 1.5rem !important;
  }

  /* Hide callout dots on mobile to keep texture visible */
  .texture-callout-dot {
    display: none !important;
  }

  #white-products-nav {
    display: none !important;
  }

  #texture-text-0,
  #texture-text-1,
  #texture-text-2,
  #texture-text-3,
  #texture-text-4,
  #texture-text-5 {
    opacity: 1 !important;
    transform: none !important;
  }
}
