/* ==========================================================================
   DESKTOP SHOWCASE PRESENTATION LAYER (min-width: 1024px)
   "Zero-Touch" 3-Column Luxury Dining Presentation with Native Iframe Simulator
   Locked Viewport Edition: Outer canvas never scrolls; 100% internal iframe scroll
   ========================================================================== */

/* --------------------------------------------------------------------------
   0. UNIVERSAL SCROLLBAR KILLER (CROSS-BROWSER)
   Eliminates all default white/grey desktop scrollbars inside iframe & simulator
   -------------------------------------------------------------------------- */
html::-webkit-scrollbar,
body::-webkit-scrollbar,
*::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
  background: transparent !important;
}

html,
body,
* {
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
}

/* --------------------------------------------------------------------------
   1. MOBILE INTEGRITY LOCK (max-width: 1023px)
   Active on physical mobile devices AND inside the 412px simulator iframe.
   Completely hides the showcase desktop chrome and renders native mobile app.
   -------------------------------------------------------------------------- */
@media (max-width: 1023px) {
  #desktop-showcase-wrapper {
    display: none !important;
  }

  #mobile-app-root {
    display: block !important;
  }
}

/* --------------------------------------------------------------------------
   2. DESKTOP SHOWCASE PRESENTATION (min-width: 1024px)
   Active ONLY on top-level desktop viewports.
   -------------------------------------------------------------------------- */
@media (min-width: 1024px) {
  /* Hide the raw top-level app DOM on desktop so only the iframe runs */
  #mobile-app-root {
    display: none !important;
  }

  /* Luxury Dark Dining Theme Ambient Canvas - LOCKED TO VIEWPORT */
  html {
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    overflow: hidden !important;
    background-color: #070709 !important;
  }

  body {
    margin: 0 !important;
    padding: 0 !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    overflow: hidden !important; /* Outer page NEVER scrolls */
    background-color: #070709 !important;
    background-image: 
      radial-gradient(ellipse 60% 45% at 50% 28%, rgba(212, 175, 55, 0.08) 0%, transparent 70%),
      radial-gradient(circle at 12% 20%, rgba(185, 140, 35, 0.04) 0%, transparent 45%),
      radial-gradient(circle at 88% 75%, rgba(212, 175, 55, 0.05) 0%, transparent 45%),
      linear-gradient(180deg, #060608 0%, #0d0e14 45%, #050507 100%) !important;
    background-attachment: fixed !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-family: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  }

  /* 3-Column Presentation Wrapper - STRICT 100vh LOCK */
  #desktop-showcase-wrapper {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    max-width: 1560px !important;
    height: 100vh !important;
    height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    padding: 18px 48px !important;
    gap: 64px !important;
    box-sizing: border-box !important;
    position: relative !important;
    z-index: 10 !important;
    overflow: hidden !important; /* Strictly lock outer viewport */
  }

  /* --------------------------------------------------------------------------
     3. LEFT & RIGHT GLASSMORPHIC PRESENTATION PANELS
     -------------------------------------------------------------------------- */
  .desktop-showcase-panel {
    display: flex !important;
    flex-direction: column !important;
    flex: 1 1 330px !important;
    max-width: 380px !important;
    min-width: 270px !important;
    box-sizing: border-box !important;
    z-index: 12 !important;
    max-height: calc(100vh - 40px) !important;
    max-height: calc(100dvh - 40px) !important;
  }

  .showcase-card {
    background: rgba(18, 19, 26, 0.72) !important;
    backdrop-filter: blur(28px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(28px) saturate(180%) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-top: 1px solid rgba(212, 175, 55, 0.35) !important;
    border-radius: 24px !important;
    padding: 24px 24px !important;
    box-shadow: 
      0 24px 60px -12px rgba(0, 0, 0, 0.65),
      0 0 0 1px rgba(255, 215, 0, 0.06),
      inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
    color: #e5e7eb !important;
    box-sizing: border-box !important;
    position: relative !important;
    overflow: hidden !important;
  }

  .showcase-card:hover {
    transform: translateY(-2px) !important;
    box-shadow: 
      0 28px 65px -10px rgba(0, 0, 0, 0.75),
      0 0 0 1px rgba(212, 175, 55, 0.2),
      inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  }

  /* Subtle card top ambient highlight */
  .showcase-card::before {
    content: "" !important;
    position: absolute !important;
    top: 0 !important;
    left: 20% !important;
    width: 60% !important;
    height: 1px !important;
    background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.7), transparent) !important;
    pointer-events: none !important;
  }

  /* Luxury Gold Badge */
  .showcase-badge {
    display: inline-flex !important;
    align-items: center !important;
    gap: 7px !important;
    padding: 5px 12px !important;
    background: rgba(212, 175, 55, 0.1) !important;
    border: 1px solid rgba(212, 175, 55, 0.28) !important;
    border-radius: 9999px !important;
    margin-bottom: 14px !important;
  }

  .showcase-badge-dot {
    width: 7px !important;
    height: 7px !important;
    border-radius: 50% !important;
    background-color: #22c55e !important;
    box-shadow: 0 0 8px #22c55e, 0 0 3px #22c55e !important;
    display: inline-block !important;
    animation: showcasePulse 2s infinite ease-in-out !important;
  }

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

  .showcase-badge-icon {
    font-size: 0.8rem !important;
    line-height: 1 !important;
  }

  .showcase-badge-text {
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.08em !important;
    text-transform: uppercase !important;
    color: #f1cf75 !important;
  }

  /* Headings & Subtexts */
  .showcase-header {
    margin-bottom: 16px !important;
  }

  .showcase-title {
    font-size: 1.7rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.025em !important;
    line-height: 1.2 !important;
    margin: 0 0 6px 0 !important;
    background: linear-gradient(135deg, #ffffff 0%, #f6df9d 55%, #c89e3a 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    text-shadow: 0 2px 20px rgba(212, 175, 55, 0.15) !important;
  }

  .showcase-title--secondary {
    font-size: 1.45rem !important;
    margin-bottom: 8px !important;
  }

  .showcase-subtitle {
    font-size: 0.88rem !important;
    font-weight: 500 !important;
    color: #a0a6b5 !important;
    line-height: 1.4 !important;
    margin: 0 !important;
  }

  .showcase-divider {
    height: 1px !important;
    width: 100% !important;
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.35) 0%, rgba(255, 255, 255, 0.06) 60%, transparent 100%) !important;
    margin-bottom: 18px !important;
  }

  /* Left Panel Feature Items */
  .showcase-features {
    display: flex !important;
    flex-direction: column !important;
    gap: 13px !important;
    margin-bottom: 18px !important;
  }

  .showcase-feature-item {
    display: flex !important;
    align-items: flex-start !important;
    gap: 12px !important;
    padding: 10px 12px !important;
    border-radius: 14px !important;
    background: rgba(255, 255, 255, 0.025) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease !important;
  }

  .showcase-feature-item:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(212, 175, 55, 0.25) !important;
    transform: translateX(3px) !important;
  }

  .feature-icon-box {
    flex-shrink: 0 !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 10px !important;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.22) 0%, rgba(20, 20, 26, 0.7) 100%) !important;
    border: 1px solid rgba(212, 175, 55, 0.3) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #e6c56b !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
  }

  .feature-content {
    flex: 1 !important;
  }

  .feature-title {
    font-size: 0.9rem !important;
    font-weight: 700 !important;
    color: #f3f4f6 !important;
    margin: 0 0 2px 0 !important;
    letter-spacing: -0.01em !important;
  }

  .feature-desc {
    font-size: 0.77rem !important;
    color: #9499a8 !important;
    line-height: 1.4 !important;
    margin: 0 !important;
  }

  /* Left Panel Footer Pills */
  .showcase-footer-pill {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
    padding-top: 12px !important;
    border-top: 1px solid rgba(255, 255, 255, 0.06) !important;
    font-size: 0.74rem !important;
    color: #8c92a4 !important;
    font-weight: 600 !important;
  }

  .footer-pill-item {
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
  }

  .status-indicator {
    width: 6px !important;
    height: 6px !important;
    border-radius: 50% !important;
    background: #e5c365 !important;
    box-shadow: 0 0 6px rgba(229, 195, 101, 0.8) !important;
  }

  /* Right Panel CTA Texts */
  .showcase-cta-primary {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #eed58b !important;
    margin: 0 0 4px 0 !important;
    letter-spacing: -0.01em !important;
  }

  .showcase-cta-sub {
    font-size: 0.8rem !important;
    color: #99a0b2 !important;
    line-height: 1.4 !important;
    margin: 0 !important;
  }

  /* Dedicated Luxury QR Code Card */
  .qr-container-outer {
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    margin: 14px 0 !important;
  }

  .qr-container-card {
    background: #ffffff !important;
    padding: 12px !important;
    border-radius: 18px !important;
    box-shadow: 
      0 14px 32px rgba(0, 0, 0, 0.55),
      0 0 0 1px rgba(212, 175, 55, 0.35),
      0 0 25px rgba(212, 175, 55, 0.15) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    transition: transform 0.25s ease, box-shadow 0.25s ease !important;
  }

  .qr-container-card:hover {
    transform: scale(1.02) !important;
    box-shadow: 
      0 18px 40px rgba(0, 0, 0, 0.65),
      0 0 0 1.5px rgba(212, 175, 55, 0.6),
      0 0 35px rgba(212, 175, 55, 0.25) !important;
  }

  .qr-code-wrapper {
    width: 155px !important;
    height: 155px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .qr-code-img {
    width: 100% !important;
    height: 100% !important;
    display: block !important;
    object-fit: contain !important;
    border-radius: 6px !important;
  }

  .qr-url-badge {
    margin-top: 8px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
    background: #121318 !important;
    border: 1px solid rgba(212, 175, 55, 0.35) !important;
    border-radius: 999px !important;
    padding: 3px 10px !important;
    color: #f1cf75 !important;
    font-size: 0.7rem !important;
    font-weight: 600 !important;
    letter-spacing: 0.01em !important;
    transition: background 0.2s ease, border-color 0.2s ease !important;
  }

  .qr-url-badge:hover {
    background: #1c1e26 !important;
    border-color: rgba(212, 175, 55, 0.7) !important;
    color: #ffffff !important;
  }

  .qr-url-icon {
    color: #e5c365 !important;
  }

  /* Right Panel Device Compatibility Tags */
  .device-pill-list {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 7px !important;
    padding-top: 12px !important;
    border-top: 1px solid rgba(255, 255, 255, 0.06) !important;
  }

  .device-tag {
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
    background: rgba(255, 255, 255, 0.035) !important;
    border: 1px solid rgba(255, 255, 255, 0.06) !important;
    border-radius: 8px !important;
    padding: 4px 9px !important;
    font-size: 0.72rem !important;
    color: #9ea4b5 !important;
    font-weight: 500 !important;
  }

  /* --------------------------------------------------------------------------
     4. CENTER COLUMN: RESPONSIVE PHONE SIMULATOR & NATIVE IFRAME
     -------------------------------------------------------------------------- */
  .desktop-simulator-wrapper {
    position: relative !important;
    flex-shrink: 0 !important;
    z-index: 20 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    max-height: 100% !important;
  }

  /* Hardware Volume & Power Side Buttons */
  .simulator-hw-button {
    position: absolute !important;
    background: linear-gradient(180deg, #32333b 0%, #1f2026 100%) !important;
    box-shadow: -1px 0 2px rgba(0, 0, 0, 0.6) !important;
    pointer-events: none !important;
    z-index: 1 !important;
  }

  .simulator-btn-volume-up {
    width: 3.5px !important;
    height: 48px !important;
    left: -15px !important;
    top: 120px !important;
    border-radius: 3px 0 0 3px !important;
  }

  .simulator-btn-volume-down {
    width: 3.5px !important;
    height: 48px !important;
    left: -15px !important;
    top: 180px !important;
    border-radius: 3px 0 0 3px !important;
  }

  .simulator-btn-power {
    width: 3.5px !important;
    height: 70px !important;
    right: -15px !important;
    top: 145px !important;
    border-radius: 0 3px 3px 0 !important;
  }

  /* Pure CSS Matte Titanium Phone Chassis - SAFE RESPONSIVE HEIGHT */
  .desktop-simulator-device {
    width: 400px !important;
    max-width: 414px !important;
    /* Responsive safe height: fits completely inside viewport without triggering parent scroll */
    height: calc(100vh - 64px) !important;
    height: calc(100dvh - 64px) !important;
    max-height: min(88vh, 850px) !important;
    min-height: 560px !important;
    position: relative !important;
    background-color: #121316 !important;
    /* Clean titanium frame */
    border: 12px solid #1c1d22 !important;
    border-radius: 44px !important;
    box-sizing: border-box !important;
    /* Heavy elevation drop shadow + ambient gold aura */
    box-shadow: 
      0 0 0 1px rgba(255, 255, 255, 0.12),
      0 0 0 2.5px #111215,
      0 30px 80px -12px rgba(0, 0, 0, 0.95),
      0 12px 30px -6px rgba(0, 0, 0, 0.8),
      0 0 80px rgba(212, 175, 55, 0.08) !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
  }

  /* Native Mobile Simulation Iframe: smooth internal scrolling without desktop scrollbars */
  .simulator-iframe {
    width: 100% !important;
    height: 100% !important;
    border: none !important;
    outline: none !important;
    display: block !important;
    background-color: var(--bg-page, #f8f9fa) !important;
    border-radius: 32px !important; /* Smooth flush fit inside the 44px outer bezel */
    overflow-y: auto !important;
    overflow-x: hidden !important;
  }
}

/* --------------------------------------------------------------------------
   5. RESPONSIVE COMPACTING FOR 1024px - 1280px VIEWPORTS
   -------------------------------------------------------------------------- */
@media (min-width: 1024px) and (max-width: 1280px) {
  #desktop-showcase-wrapper {
    gap: 36px !important;
    padding: 14px 24px !important;
  }

  .desktop-showcase-panel {
    flex: 1 1 250px !important;
    max-width: 300px !important;
    min-width: 230px !important;
  }

  .showcase-card {
    padding: 18px 16px !important;
  }

  .showcase-title {
    font-size: 1.45rem !important;
  }

  .qr-code-wrapper {
    width: 135px !important;
    height: 135px !important;
  }

  .desktop-simulator-device {
    width: 380px !important;
    height: calc(100vh - 48px) !important;
    height: calc(100dvh - 48px) !important;
    max-height: min(88vh, 780px) !important;
  }
}
