/* ==========================================================================
   Style 01: Interaktive 3D Scroll-Animation & Studio Hero
   Felix & Felix Webagentur
   ========================================================================== */

.hero-animation-wrapper {
  position: relative;
  width: 100%;
  height: 400vh; /* Perfekte Scroll-Distanz für 240 Frames */
  background: radial-gradient(circle at 50% 12%, rgba(99, 102, 241, 0.14) 0%, transparent 60%),
              radial-gradient(circle at 85% 45%, rgba(56, 189, 248, 0.08) 0%, transparent 50%),
              #070a13;
}

.hero-sticky-container {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  margin: 0;
  padding: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

#hero-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 1;
}

/* Center Hero Content */
.hero-content {
  position: relative;
  z-index: 10;
  text-align: center;
  max-width: 960px;
  padding: 0 24px;
  pointer-events: none;
}

.hero-cta-group {
  pointer-events: auto;
}

.hero-pitch-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  border-radius: 9999px;
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(165, 180, 252, 0.28);
  color: #c7d2fe;
  font-family: var(--font-style-3d);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 24px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.hero-pitch-tag .pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #818cf8;
  box-shadow: 0 0 10px #818cf8;
}

.hero-headline {
  font-family: var(--font-style-3d);
  font-size: clamp(2.5rem, 6.2vw, 5.2rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
  color: #ffffff;
}

.hero-headline .text-gradient {
  background: linear-gradient(180deg, #ffffff 0%, #cbd5e1 50%, #93c5fd 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-description {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  color: #94a3b8;
  max-width: 760px;
  margin: 0 auto 36px;
  line-height: 1.65;
}

.hero-cta-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.btn-hero-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 36px;
  font-size: 1.02rem;
  font-weight: 700;
  border-radius: 9999px;
  background: var(--primary-gradient);
  color: #ffffff;
  border: 1px solid rgba(165, 180, 252, 0.3);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: var(--transition-smooth);
  text-decoration: none;
  cursor: pointer;
}

.btn-hero-primary:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #4338ca 0%, #4f46e5 50%, #6366f1 100%);
  color: #ffffff;
  border-color: rgba(199, 210, 254, 0.5);
  box-shadow: 0 8px 30px rgba(99, 102, 241, 0.6);
}

.btn-hero-secondary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 32px;
  font-size: 1.02rem;
  font-weight: 600;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #ffffff;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: var(--transition-smooth);
  text-decoration: none;
}

.btn-hero-secondary:hover {
  background: rgba(99, 102, 241, 0.12);
  border-color: rgba(165, 180, 252, 0.35);
  color: #ffffff;
}

/* Scroll Scrub Indicator */
.hero-scroll-indicator {
  position: absolute;
  bottom: 85px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-family: var(--font-mono);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.scroll-mouse-icon {
  width: 24px;
  height: 38px;
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-radius: 12px;
  position: relative;
}

.scroll-wheel-dot {
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 8px;
  border-radius: 2px;
  background: #ffffff;
  animation: scrollWheel 2s infinite ease-in-out;
}

@keyframes scrollWheel {
  0% { opacity: 0; transform: translate(-50%, 0); }
  40% { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, 14px); }
}

/* Default hidden on desktop */
.mobile-hero-container {
  display: none;
}

.btn-exit-mobile-3d {
  display: none;
}

/* ==========================================================================
   Mobile Responsive Rules (Smartphones & Tablets <= 768px)
   ========================================================================== */
@media (max-width: 768px) {
  /* Default Clean Mobile View (Ultra-fast, bright, non-awkward) */
  .hero-animation-wrapper:not(.mobile-3d-active) {
    height: auto !important;
    min-height: 84vh;
    padding: 108px 20px 52px;
    background: #ffffff !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }

  .hero-animation-wrapper:not(.mobile-3d-active)::after {
    display: none;
  }

  .hero-animation-wrapper:not(.mobile-3d-active) .hero-sticky-container {
    display: none !important;
  }

  /* Dedicated High-Converting Mobile Hero */
  .mobile-hero-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 520px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 10;
  }

  .mobile-hero-title {
    font-family: var(--font-style-3d, 'Syne', sans-serif);
    font-size: clamp(2.2rem, 8.5vw, 2.9rem);
    font-weight: 800;
    line-height: 1.14;
    letter-spacing: -0.035em;
    color: #0f172a;
    margin: 0 0 16px 0;
  }

  .mobile-hero-highlight {
    background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
  }

  .mobile-hero-desc {
    font-size: 0.96rem;
    line-height: 1.58;
    color: #475569;
    margin: 0 0 24px 0;
    max-width: 440px;
  }

  .mobile-hero-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    max-width: 320px;
    margin-bottom: 26px;
  }

  .btn-mobile-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 24px;
    background: #0f172a;
    color: #ffffff;
    font-size: 0.96rem;
    font-weight: 600;
    border-radius: 12px;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.18);
    transition: transform 0.2s ease, background 0.2s ease;
  }
  .btn-mobile-primary:active {
    transform: scale(0.98);
  }

  .btn-mobile-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 22px;
    background: #f8fafc;
    color: #0f172a;
    font-size: 0.94rem;
    font-weight: 600;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.2s ease;
  }
  .btn-mobile-secondary:active {
    background: #e2e8f0;
  }

  /* 3D Teaser Card */
  .mobile-3d-teaser-card {
    width: 100%;
    background: linear-gradient(145deg, #0b0f19 0%, #151d2f 100%);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    padding: 20px 18px;
    box-shadow: 0 12px 28px -6px rgba(15, 23, 42, 0.25);
    margin-bottom: 24px;
    text-align: left;
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
  }

  .mobile-3d-teaser-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.18) 0%, transparent 70%);
    pointer-events: none;
  }

  .mobile-teaser-text {
    font-size: 0.88rem;
    line-height: 1.55;
    color: #94a3b8;
    margin: 0 0 16px 0;
  }

  .btn-teaser-launch {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 18px;
    background: linear-gradient(135deg, #2563eb 0%, #6366f1 100%);
    color: #ffffff;
    font-size: 0.88rem;
    font-weight: 600;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
  }
  .btn-teaser-launch:active {
    transform: scale(0.98);
  }

  /* Active 3D Mode on Mobile (When user clicks to launch 3D presentation) */
  .hero-animation-wrapper.mobile-3d-active {
    height: 220vh !important;
    padding: 0 !important;
    background: #070a13 !important;
    display: block !important;
  }

  .hero-animation-wrapper.mobile-3d-active .mobile-hero-container {
    display: none !important;
  }

  .hero-animation-wrapper.mobile-3d-active .hero-sticky-container {
    display: block !important;
    position: sticky;
    top: 0;
    width: 100%;
    height: 100vh;
  }

  .hero-animation-wrapper.mobile-3d-active .btn-exit-mobile-3d {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    position: absolute;
    top: 18px;
    right: 18px;
    z-index: 100;
    padding: 8px 14px;
    font-size: 0.78rem;
    font-weight: 600;
    font-family: var(--font-primary, sans-serif);
    color: #ffffff;
    background: rgba(15, 23, 42, 0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 9999px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
    transition: background 0.2s ease, transform 0.15s ease;
  }
  .hero-animation-wrapper.mobile-3d-active .btn-exit-mobile-3d:active {
    transform: scale(0.96);
  }
}

/* ==========================================================================
   Mobile 3D Info & Switcher Modal
   ========================================================================== */
.mobile-3d-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(11, 15, 25, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.28s ease, visibility 0.28s ease;
  box-sizing: border-box;
}

.mobile-3d-modal-backdrop.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.mobile-3d-modal-card {
  position: relative;
  background: #ffffff;
  border-radius: 20px;
  padding: 28px 22px;
  max-width: 380px;
  width: 100%;
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.9);
  text-align: center;
  transform: scale(0.94) translateY(10px);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.mobile-3d-modal-backdrop.active .mobile-3d-modal-card {
  transform: scale(1) translateY(0);
}

.mobile-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #f1f5f9;
  border: none;
  font-size: 1.25rem;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}
.mobile-modal-close:hover {
  background: #e2e8f0;
}

.mobile-modal-icon-wrap {
  width: 54px;
  height: 54px;
  margin: 0 auto 16px;
  border-radius: 16px;
  background: linear-gradient(135deg, #eff6ff 0%, #e0e7ff 100%);
  border: 1px solid #c7d2fe;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

.mobile-modal-title {
  font-family: var(--font-style-3d, 'Syne', sans-serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 6px 0;
  letter-spacing: -0.02em;
}

.mobile-modal-lead {
  font-size: 0.88rem;
  color: #2563eb;
  font-weight: 600;
  margin: 0 0 12px 0;
}

.mobile-modal-body {
  font-size: 0.86rem;
  line-height: 1.52;
  color: #475569;
  margin: 0 0 20px 0;
}

.mobile-modal-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.btn-modal-start-3d {
  width: 100%;
  padding: 13px 18px;
  background: linear-gradient(135deg, #2563eb 0%, #6366f1 100%);
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 600;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
  transition: opacity 0.2s ease, transform 0.15s ease;
}
.btn-modal-start-3d:active {
  transform: scale(0.98);
}

.btn-modal-cancel {
  width: 100%;
  padding: 11px 18px;
  background: #f8fafc;
  color: #475569;
  font-size: 0.88rem;
  font-weight: 600;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s ease;
}
.btn-modal-cancel:hover {
  background: #f1f5f9;
}

.mobile-modal-footer-note {
  font-size: 0.74rem;
  color: #94a3b8;
  line-height: 1.4;
}

/* Bottom transition gradient into light section (subtle, does not cover cards) */
.hero-animation-wrapper::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 48px;
  background: linear-gradient(180deg, transparent 0%, rgba(248, 250, 252, 0.4) 60%, #ffffff 100%);
  z-index: 5;
  pointer-events: none;
}
