/* ============================================
   Memory Master Landing Page Styles
   Dark theme with space/constellation aesthetic
   ============================================ */

/* CSS Variables */
:root {
  --bg-primary: #0a0a1a;
  --bg-secondary: #12122a;
  --bg-card: #1a1a3a;
  --text-primary: #ffffff;
  --text-secondary: #b0b0c0;
  --accent-primary: #6366f1;
  --accent-secondary: #8b5cf6;
  --accent-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  --gold: #fbbf24;
  --success: #10b981;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
  --border-radius: 12px;
  --transition: all 0.3s ease;
}

/* Reset & Base */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Language Navigation */
.language-nav {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 1000;
  padding: 1rem;
}

.lang-switcher {
  display: flex;
  gap: 0.5rem;
  background: rgba(26, 26, 58, 0.9);
  backdrop-filter: blur(10px);
  padding: 0.5rem;
  border-radius: 30px;
  box-shadow: var(--shadow-md);
}

.lang-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  transition: var(--transition);
}

.lang-btn:hover {
  color: var(--text-primary);
  background: rgba(99, 102, 241, 0.2);
}

.lang-btn.active {
  background: var(--accent-gradient);
  color: white;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 2rem;
  overflow: hidden;
}

.hero-content {
  text-align: center;
  z-index: 10;
  max-width: 800px;
  animation: fadeInUp 1s ease-out;
}

.app-icon-container {
  margin-bottom: 2rem;
}

.app-icon {
  width: 150px;
  height: 150px;
  border-radius: 30px;
  box-shadow: var(--shadow-lg);
  animation: float 3s ease-in-out infinite;
}

.app-title {
  font-size: clamp(2.5rem, 8vw, 4rem);
  font-weight: 800;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1rem;
  letter-spacing: -1px;
}

.tagline {
  font-size: clamp(1.2rem, 4vw, 1.8rem);
  color: var(--gold);
  font-weight: 600;
  margin-bottom: 1rem;
}

.description {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 2rem;
}

/* Download Buttons */
.download-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  align-items: flex-start;
  margin-top: 2rem;
}

.store-btn {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  position: relative;
  transition: var(--transition);
  min-height: 70px;
}

.store-btn:hover {
  transform: translateY(-3px);
}

.store-badge {
  height: 50px;
  width: auto;
}

.store-btn.coming-soon {
  opacity: 0.6;
  cursor: not-allowed;
}

.store-btn.coming-soon:hover {
  transform: none;
}

.coming-soon-label,
.store-label-spacer {
  font-size: 0.75rem;
  color: var(--gold);
  margin-top: 0.25rem;
  min-height: 1.2em;
}

.store-label-spacer {
  visibility: hidden;
  font-weight: 600;
}

/* Animated Background */
.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
}

.stars, .stars2, .stars3 {
  position: absolute;
  width: 100%;
  height: 100%;
  background-repeat: repeat;
}

.stars {
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='400'%3E%3Ccircle cx='50' cy='50' r='1' fill='white' fill-opacity='0.8'/%3E%3Ccircle cx='150' cy='80' r='1.5' fill='white' fill-opacity='0.6'/%3E%3Ccircle cx='250' cy='30' r='1' fill='white' fill-opacity='0.7'/%3E%3Ccircle cx='350' cy='120' r='1.2' fill='white' fill-opacity='0.5'/%3E%3Ccircle cx='100' cy='200' r='1' fill='white' fill-opacity='0.6'/%3E%3Ccircle cx='300' cy='250' r='1.3' fill='white' fill-opacity='0.7'/%3E%3Ccircle cx='200' cy='150' r='0.8' fill='white' fill-opacity='0.5'/%3E%3Ccircle cx='80' cy='350' r='1.1' fill='white' fill-opacity='0.6'/%3E%3Ccircle cx='320' cy='380' r='1' fill='white' fill-opacity='0.8'/%3E%3C/svg%3E") repeat;
  animation: animateStars 150s linear infinite;
}

.stars2 {
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='500' height='500'%3E%3Ccircle cx='100' cy='100' r='2' fill='%236366f1' fill-opacity='0.4'/%3E%3Ccircle cx='300' cy='150' r='1.5' fill='%238b5cf6' fill-opacity='0.3'/%3E%3Ccircle cx='450' cy='300' r='2' fill='%236366f1' fill-opacity='0.4'/%3E%3Ccircle cx='200' cy='400' r='1.8' fill='%238b5cf6' fill-opacity='0.3'/%3E%3C/svg%3E") repeat;
  animation: animateStars 200s linear infinite;
}

.stars3 {
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='600'%3E%3Ccircle cx='150' cy='200' r='2.5' fill='%23fbbf24' fill-opacity='0.2'/%3E%3Ccircle cx='400' cy='100' r='2' fill='%23fbbf24' fill-opacity='0.15'/%3E%3Ccircle cx='500' cy='450' r='2.2' fill='%23fbbf24' fill-opacity='0.2'/%3E%3C/svg%3E") repeat;
  animation: animateStars 250s linear infinite;
}

/* Features Section */
.features {
  padding: 5rem 2rem;
  background: var(--bg-secondary);
}

.section-title {
  text-align: center;
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: 3rem;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.feature-card {
  background: var(--bg-card);
  padding: 2rem;
  border-radius: var(--border-radius);
  text-align: center;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.feature-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.feature-title {
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.feature-desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* How to Play Section */
.how-to-play {
  padding: 5rem 2rem;
  background: var(--bg-primary);
}

.steps-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 800px;
  margin: 0 auto;
}

.step {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  padding: 2rem;
  background: var(--bg-card);
  border-radius: var(--border-radius);
  transition: var(--transition);
}

.step:hover {
  transform: translateX(10px);
}

.step-number {
  width: 50px;
  height: 50px;
  background: var(--accent-gradient);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  flex-shrink: 0;
}

.step-content h3 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  color: var(--gold);
}

.step-content p {
  color: var(--text-secondary);
}

/* Footer */
.footer {
  background: var(--bg-secondary);
  padding: 2rem;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
  max-width: 800px;
  margin: 0 auto;
}

.footer-links {
  margin-bottom: 1rem;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--accent-primary);
}

.separator {
  margin: 0 1rem;
  color: var(--text-secondary);
  opacity: 0.5;
}

.copyright {
  font-size: 0.85rem;
  color: var(--text-secondary);
  opacity: 0.7;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

@keyframes animateStars {
  from {
    transform: translateY(0);
  }
  to {
    transform: translateY(-1000px);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .hero {
    padding: 1rem;
    padding-top: 4rem;
  }
  
  .app-icon {
    width: 120px;
    height: 120px;
  }
  
  .download-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .store-badge {
    height: 45px;
  }
  
  .features {
    padding: 3rem 1rem;
  }
  
  .features-grid {
    gap: 1rem;
  }
  
  .feature-card {
    padding: 1.5rem;
  }
  
  .how-to-play {
    padding: 3rem 1rem;
  }
  
  .step {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  
  .step:hover {
    transform: translateY(-5px);
  }
}

@media (max-width: 480px) {
  .language-nav {
    padding: 0.5rem;
  }
  
  .lang-btn {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
  }
  
  .app-icon {
    width: 100px;
    height: 100px;
  }
}

/* Print Styles */
@media print {
  .hero-bg,
  .language-nav {
    display: none;
  }
  
  body {
    background: white;
    color: black;
  }
}
