/* ============================================
   QUANTUM FRAMER-INSPIRED DESIGN
   Modern, spacious layout with quantum aesthetics
   ============================================ */

/* CSS Variables for Quantum Theme */
:root {
  --quantum-dark: #0a0a1a;
  --quantum-darker: #050510;
  --quantum-cyan: #00ffe7;
  --quantum-cyan-glow: rgba(0, 255, 231, 0.4);
  --quantum-blue: #1a73e8;
  --quantum-magenta: #ff00ff;
  --quantum-purple: #8b5cf6;
  --text-primary: #ffffff;
  --text-secondary: #b3e6ff;
  --text-muted: #8892b0;
  --glass-bg: rgba(20, 24, 48, 0.4);
  --glass-border: rgba(255, 255, 255, 0.1);
}

/* Reset & Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  background: var(--quantum-darker);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
  position: relative;
}

/* Quantum Background Animation */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 20% 50%, rgba(0, 255, 231, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(26, 115, 232, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 40% 20%, rgba(139, 92, 246, 0.08) 0%, transparent 50%),
    linear-gradient(180deg, var(--quantum-darker) 0%, var(--quantum-dark) 100%);
  z-index: -2;
  animation: quantumPulse 20s ease-in-out infinite;
}

@keyframes quantumPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}

/* Quantum Grid Pattern */
body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(0, 255, 231, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 255, 231, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  z-index: -1;
  animation: gridMove 30s linear infinite;
  pointer-events: none;
}

@keyframes gridMove {
  0% { transform: translate(0, 0); }
  100% { transform: translate(50px, 50px); }
}

/* Canvas for Three.js */
canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  opacity: 0.3;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 24px 80px;
  position: relative;
  overflow: hidden;
}

.hero-content {
  max-width: 900px;
  text-align: center;
  z-index: 1;
  animation: fadeInUp 1s ease-out;
}

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

.hero-title {
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 700;
  background: linear-gradient(135deg, var(--quantum-cyan) 0%, var(--quantum-blue) 50%, var(--quantum-purple) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
  line-height: 1.1;
  text-shadow: 0 0 40px var(--quantum-cyan-glow);
  animation: quantumGlow 3s ease-in-out infinite;
}

@keyframes quantumGlow {
  0%, 100% {
    filter: drop-shadow(0 0 20px var(--quantum-cyan-glow));
  }
  50% {
    filter: drop-shadow(0 0 40px var(--quantum-cyan-glow));
  }
}

.hero-slogan {
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  color: var(--text-secondary);
  margin-bottom: 32px;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.hero-description {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 48px;
  line-height: 1.8;
}

.hero-cta {
  display: inline-block;
  padding: 18px 48px;
  background: linear-gradient(135deg, var(--quantum-cyan) 0%, var(--quantum-blue) 100%);
  color: var(--quantum-dark);
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  border-radius: 12px;
  transition: all 0.3s ease;
  box-shadow: 0 8px 32px rgba(0, 255, 231, 0.3);
  position: relative;
  overflow: hidden;
}

.hero-cta::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s;
}

.hero-cta:hover::before {
  left: 100%;
}

.hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 48px rgba(0, 255, 231, 0.5);
}

/* ============================================
   FEATURES SECTION
   ============================================ */
.features {
  padding: 120px 24px;
  position: relative;
}

.features-container {
  max-width: 1200px;
  margin: 0 auto;
}

.features-title {
  font-size: clamp(2rem, 5vw, 3rem);
  text-align: center;
  margin-bottom: 80px;
  color: var(--text-primary);
  font-weight: 600;
  line-height: 1.3;
  background: linear-gradient(135deg, var(--quantum-cyan) 0%, var(--quantum-blue) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
  margin-top: 64px;
}

.feature-card {
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 48px 32px;
  text-align: center;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(0, 255, 231, 0.1) 0%, rgba(26, 115, 232, 0.1) 100%);
  opacity: 0;
  transition: opacity 0.4s;
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-card:hover {
  transform: translateY(-8px);
  border-color: var(--quantum-cyan);
  box-shadow: 0 20px 60px rgba(0, 255, 231, 0.2);
}

.feature-icon {
  font-size: 3.5rem;
  margin-bottom: 24px;
  filter: drop-shadow(0 0 20px var(--quantum-cyan-glow));
  animation: iconFloat 3s ease-in-out infinite;
}

@keyframes iconFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.feature-card:nth-child(2) .feature-icon {
  animation-delay: 0.5s;
}

.feature-card:nth-child(3) .feature-icon {
  animation-delay: 1s;
}

.feature-card h3 {
  font-size: 1.5rem;
  margin-bottom: 16px;
  color: var(--quantum-cyan);
  font-weight: 600;
  position: relative;
  z-index: 1;
}

.feature-card p {
  color: var(--text-secondary);
  line-height: 1.7;
  position: relative;
  z-index: 1;
}

/* ============================================
   CONTACT SECTION
   ============================================ */
.contact {
  padding: 120px 24px;
  position: relative;
}

.contact-container {
  max-width: 700px;
  margin: 0 auto;
}

.contact-title {
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  text-align: center;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--quantum-cyan) 0%, var(--quantum-blue) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}

.contact-subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 1.25rem;
  margin-bottom: 64px;
}

.contact-form {
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 48px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.contact-form label {
  display: block;
  margin-bottom: 8px;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.95rem;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  padding: 16px 20px;
  margin-bottom: 24px;
  background: rgba(10, 10, 26, 0.6);
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: var(--text-primary);
  font-size: 1rem;
  font-family: inherit;
  transition: all 0.3s ease;
  outline: none;
}

.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
  border-color: var(--quantum-cyan);
  box-shadow: 0 0 20px rgba(0, 255, 231, 0.3);
  background: rgba(10, 10, 26, 0.8);
}

.contact-form textarea {
  min-height: 120px;
  resize: vertical;
}

.contact-form select {
  appearance: none;
  background-image: url('data:image/svg+xml;utf8,<svg fill="%2300ffe7" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/></svg>');
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 20px;
  cursor: pointer;
}

.phone-row {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
}

.phone-row select#countryCode {
  min-width: 100px;
  max-width: 120px;
}

.phone-row input#phoneInput {
  flex: 1;
}

.contact-form button {
  width: 100%;
  padding: 18px 32px;
  background: linear-gradient(135deg, var(--quantum-cyan) 0%, var(--quantum-blue) 100%);
  color: var(--quantum-dark);
  border: none;
  border-radius: 12px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 32px rgba(0, 255, 231, 0.3);
  margin-top: 8px;
}

.contact-form button:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 48px rgba(0, 255, 231, 0.5);
}

/* ============================================
   FOOTER
   ============================================ */
footer {
  margin-top: auto;
  background: rgba(10, 10, 26, 0.8);
  backdrop-filter: blur(20px);
  padding: 32px 24px;
  text-align: center;
  border-top: 1px solid var(--glass-border);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 24px;
  font-size: 0.9rem;
}

footer a {
  color: var(--quantum-cyan);
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 500;
}

footer a:hover {
  color: var(--quantum-blue);
  text-shadow: 0 0 10px var(--quantum-cyan-glow);
}

footer span {
  color: var(--text-muted);
}

.lang-dropdown {
  display: inline-block;
  position: relative;
}

.lang-dropdown select {
  background: rgba(10, 10, 26, 0.8);
  color: var(--quantum-cyan);
  border: 1.5px solid rgba(0, 255, 231, 0.3);
  border-radius: 8px;
  padding: 8px 36px 8px 16px;
  font-size: 0.9rem;
  font-family: inherit;
  font-weight: 500;
  outline: none;
  appearance: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.lang-dropdown select:focus {
  border-color: var(--quantum-cyan);
  box-shadow: 0 0 12px rgba(0, 255, 231, 0.3);
}

.lang-dropdown .dropdown-arrow-up {
  pointer-events: none;
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-bottom: 7px solid var(--quantum-cyan);
  border-top: none;
  filter: drop-shadow(0 0 4px var(--quantum-cyan));
}

/* ============================================
   ALERT BOX
   ============================================ */
#alertBox {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  color: var(--text-primary);
  padding: 40px;
  border-radius: 24px;
  border: 1px solid var(--glass-border);
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(0, 255, 231, 0.2);
  font-family: inherit;
  font-size: 1.1rem;
  line-height: 1.6;
  font-weight: 500;
  max-width: 500px;
  min-width: 350px;
  z-index: 10000;
  cursor: default;
  text-align: center;
  animation: alertSlideIn 0.4s ease-out;
}

#alertBox.success {
  border-color: var(--quantum-cyan);
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(0, 255, 231, 0.4);
}

#alertBox.error {
  border-color: #ff4757;
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(255, 71, 87, 0.4);
}

#alertBox .alert-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 24px;
}

#alertBox .alert-icon {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 18px;
}

#alertBox .alert-icon.success {
  background: linear-gradient(135deg, var(--quantum-cyan) 0%, var(--quantum-blue) 100%);
  color: var(--quantum-dark);
}

#alertBox .alert-icon.error {
  background: linear-gradient(135deg, #ff4757 0%, #ff6b7a 100%);
  color: white;
}

#alertBox .alert-message {
  flex: 1;
  text-align: left;
}

#alertBox .alert-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 28px;
  font-weight: 300;
  cursor: pointer;
  padding: 4px;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

#alertBox .alert-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--quantum-cyan);
  transform: scale(1.1);
}

#alertBox .alert-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 24px;
}

#alertBox .alert-button {
  background: linear-gradient(135deg, var(--quantum-cyan) 0%, var(--quantum-blue) 100%);
  color: var(--quantum-dark);
  border: none;
  border-radius: 12px;
  padding: 12px 24px;
  font-size: 1rem;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 16px rgba(0, 255, 231, 0.3);
}

#alertBox .alert-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 255, 231, 0.4);
}

@keyframes alertSlideIn {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

/* ============================================
   CONTENT PAGES (Datenschutz, Impressum)
   ============================================ */
.content {
  max-width: 900px;
  margin: 120px auto 80px;
  padding: 48px;
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  color: var(--text-primary);
  line-height: 1.8;
}

.content h1 {
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  margin-bottom: 32px;
  background: linear-gradient(135deg, var(--quantum-cyan) 0%, var(--quantum-blue) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
  text-align: center;
  padding-bottom: 24px;
  border-bottom: 2px solid rgba(0, 255, 231, 0.3);
}

.content h2 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin-top: 48px;
  margin-bottom: 24px;
  color: var(--quantum-cyan);
  font-weight: 600;
  border-left: 4px solid var(--quantum-cyan);
  padding-left: 20px;
  background: rgba(0, 255, 231, 0.05);
  padding: 16px 20px;
  border-radius: 0 12px 12px 0;
}

.content p {
  margin-bottom: 20px;
  color: var(--text-secondary);
  line-height: 1.8;
}

.content ul {
  margin: 24px 0;
  padding-left: 24px;
  color: var(--text-secondary);
}

.content li {
  margin-bottom: 12px;
  line-height: 1.8;
}

.content li::marker {
  color: var(--quantum-cyan);
}

.content strong {
  color: var(--quantum-cyan);
  font-weight: 600;
}

.content a {
  color: var(--quantum-cyan);
  text-decoration: none;
  border-bottom: 1px solid rgba(0, 255, 231, 0.3);
  transition: all 0.3s ease;
}

.content a:hover {
  color: var(--quantum-blue);
  border-bottom-color: var(--quantum-blue);
  text-shadow: 0 0 10px var(--quantum-cyan-glow);
}

.content h2 + p {
  margin-top: 0;
}

/* Back Navigation */
.back-navigation {
  position: fixed;
  top: 24px;
  left: 24px;
  z-index: 1000;
}

.back-link {
  display: inline-block;
  padding: 12px 20px;
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  color: var(--quantum-cyan);
  text-decoration: none;
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  font-family: inherit;
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.back-link:hover {
  background: rgba(0, 255, 231, 0.1);
  border-color: var(--quantum-cyan);
  box-shadow: 0 8px 24px rgba(0, 255, 231, 0.3);
  transform: translateY(-2px);
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 768px) {
  .hero {
    padding: 80px 20px 60px;
    min-height: 90vh;
  }

  .features {
    padding: 80px 20px;
  }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .contact {
    padding: 80px 20px;
  }

  .contact-form {
    padding: 32px 24px;
  }

  .phone-row {
    gap: 8px;
  }

  .phone-row select#countryCode {
    min-width: 90px;
    max-width: 110px;
  }

  footer {
    flex-direction: column;
    gap: 16px;
    padding: 24px 20px;
  }

  #alertBox {
    max-width: 90vw;
    min-width: 280px;
    padding: 32px 24px;
    font-size: 1rem;
  }

  #alertBox .alert-content {
    flex-direction: column;
    text-align: center;
  }

  #alertBox .alert-message {
    text-align: center;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2.5rem;
  }

  .hero-slogan {
    font-size: 1.1rem;
  }

  .hero-description {
    font-size: 0.95rem;
  }

  .features-title {
    font-size: 1.75rem;
    margin-bottom: 48px;
  }

  .contact-title {
    font-size: 2rem;
  }

  .contact-subtitle {
    font-size: 1rem;
  }

  .content {
    margin: 100px auto 60px;
    padding: 32px 24px;
  }

  .content h1 {
    font-size: 2rem;
    margin-bottom: 24px;
    padding-bottom: 16px;
  }

  .content h2 {
    font-size: 1.5rem;
    margin-top: 32px;
    margin-bottom: 16px;
    padding: 12px 16px;
  }

  .back-navigation {
    top: 16px;
    left: 16px;
  }

  .back-link {
    padding: 10px 16px;
    font-size: 0.9rem;
  }
}

/* Smooth scroll for anchor links */
@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}
