/* RedBoxVM Website - Main Styles */

/* CSS Custom Properties */
:root {
  /* Colors */
  --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --accent-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  
  --primary-color: #667eea;
  --secondary-color: #764ba2;
  --accent-color: #4facfe;
  
  --text-primary: #1a1a1a;
  --text-secondary: #666666;
  --text-muted: #999999;
  --text-inverse: #ffffff;
  
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-tertiary: #f1f5f9;
  --bg-dark: #0f172a;
  --bg-card: rgba(255, 255, 255, 0.8);
  
  --border-color: rgba(0, 0, 0, 0.1);
  --border-light: rgba(255, 255, 255, 0.1);
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  
  /* Typography */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', Consolas, monospace;
  
  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;
  
  /* Breakpoints */
  --bp-sm: 640px;
  --bp-md: 768px;
  --bp-lg: 1024px;
  --bp-xl: 1280px;
  --bp-2xl: 1536px;
  
  /* Transitions */
  --transition-fast: 0.15s ease-out;
  --transition-normal: 0.3s ease-out;
  --transition-slow: 0.5s ease-out;
  
  /* Z-index */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal: 1040;
  --z-popover: 1050;
  --z-tooltip: 1060;
  --z-toast: 1070;
}

/* Reset and Base Styles */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-family);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-md);
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2rem); }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.125rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: var(--space-md);
  color: var(--text-secondary);
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--secondary-color);
}

/* Utility Classes */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.gradient-text {
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Loading Screen */
.loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}

.loader.hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-content {
  text-align: center;
  color: white;
}

.loader-logo {
  margin-bottom: var(--space-lg);
}

.loader-icon {
  width: 80px;
  height: 80px;
  animation: pulse 2s ease-in-out infinite;
}

.loader-text h2 {
  font-size: 2rem;
  margin-bottom: var(--space-sm);
}

.loader-text p {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: var(--space-xl);
}

.loader-progress {
  width: 200px;
  height: 4px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  overflow: hidden;
  margin: 0 auto;
}

.loader-bar {
  height: 100%;
  background: white;
  border-radius: 2px;
  animation: loading 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.1); opacity: 0.8; }
}

@keyframes loading {
  0% { width: 0%; }
  50% { width: 70%; }
  100% { width: 100%; }
}

/* Navigation */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  z-index: var(--z-fixed);
  transition: all var(--transition-normal);
}

.nav.scrolled {
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--shadow-md);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text-primary);
}

.nav-logo {
  width: 32px;
  height: 32px;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
}

.nav-link {
  position: relative;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary-color);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-gradient);
  transition: width var(--transition-normal);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.nav-github {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-secondary);
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.nav-github:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

.nav-github svg {
  width: 20px;
  height: 20px;
}

.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.theme-toggle:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.theme-toggle svg {
  width: 18px;
  height: 18px;
  position: absolute;
  transition: all var(--transition-fast);
}

.theme-toggle .sun-icon {
  opacity: 1;
  transform: rotate(0deg);
}

.theme-toggle .moon-icon {
  opacity: 0;
  transform: rotate(180deg);
}

[data-theme="dark"] .theme-toggle .sun-icon {
  opacity: 0;
  transform: rotate(180deg);
}

[data-theme="dark"] .theme-toggle .moon-icon {
  opacity: 1;
  transform: rotate(0deg);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-sm);
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  transition: all var(--transition-fast);
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
}

.hero-gradient {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  opacity: 0.1;
}

.hero-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4xl);
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--space-4xl) var(--space-lg);
}

.hero-content {
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-sm) var(--space-lg);
  background: rgba(102, 126, 234, 0.1);
  border: 1px solid rgba(102, 126, 234, 0.2);
  border-radius: 50px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--primary-color);
  margin-bottom: var(--space-xl);
}

.hero-title {
  font-size: clamp(3rem, 6vw, 5rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: var(--space-xl);
}

.title-line {
  display: block;
}

.hero-description {
  font-size: 1.25rem;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: var(--space-2xl);
  max-width: 500px;
}

.hero-actions {
  display: flex;
  gap: var(--space-lg);
  margin-bottom: var(--space-4xl);
}

.hero-stats {
  display: flex;
  gap: var(--space-2xl);
}

.stat {
  text-align: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: 800;
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-xs);
}

.stat-label {
  font-size: 0.875rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Hero Visual */
.hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.phone-mockup {
  position: relative;
  width: 300px;
  height: 600px;
  background: linear-gradient(145deg, #f0f0f0, #ffffff);
  border-radius: 40px;
  padding: 20px;
  box-shadow: 
    0 0 0 8px rgba(0, 0, 0, 0.1),
    0 20px 40px rgba(0, 0, 0, 0.15);
  transform: perspective(1000px) rotateY(-15deg) rotateX(5deg);
  animation: float 6s ease-in-out infinite;
}

.phone-screen {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 30px;
  padding: 40px 20px;
  position: relative;
  overflow: hidden;
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  height: 100%;
  align-content: start;
}

.app-icon {
  width: 60px;
  height: 60px;
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  animation: appPulse 3s ease-in-out infinite;
}

.app-icon:nth-child(1) { animation-delay: 0s; }
.app-icon:nth-child(2) { animation-delay: 0.5s; }
.app-icon:nth-child(3) { animation-delay: 1s; }
.app-icon:nth-child(4) { animation-delay: 1.5s; }
.app-icon:nth-child(5) { animation-delay: 2s; }
.app-icon:nth-child(6) { animation-delay: 2.5s; }

@keyframes float {
  0%, 100% { transform: perspective(1000px) rotateY(-15deg) rotateX(5deg) translateY(0px); }
  50% { transform: perspective(1000px) rotateY(-15deg) rotateX(5deg) translateY(-20px); }
}

@keyframes appPulse {
  0%, 100% { transform: scale(1); opacity: 0.8; }
  50% { transform: scale(1.1); opacity: 1; }
}

.hero-scroll {
  position: absolute;
  bottom: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  color: var(--text-muted);
}

.scroll-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  font-size: 0.875rem;
  font-weight: 500;
}

.scroll-arrow {
  width: 20px;
  height: 20px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% { transform: rotate(45deg) translateY(0); }
  50% { transform: rotate(45deg) translateY(5px); }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 12px;
  transition: all var(--transition-normal);
  cursor: pointer;
  border: none;
  position: relative;
  overflow: hidden;
}

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

.btn:hover::before {
  left: 100%;
}

.btn-primary {
  background: var(--primary-gradient);
  color: white;
  box-shadow: var(--shadow-lg);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  backdrop-filter: blur(10px);
}

.btn-secondary:hover {
  background: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn svg {
  width: 20px;
  height: 20px;
}

/* Section Styles */
section {
  padding: var(--space-4xl) 0;
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-4xl);
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.section-badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-sm) var(--space-lg);
  background: rgba(102, 126, 234, 0.1);
  border: 1px solid rgba(102, 126, 234, 0.2);
  border-radius: 50px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--primary-color);
  margin-bottom: var(--space-lg);
}

.section-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  margin-bottom: var(--space-lg);
}

.section-description {
  font-size: 1.25rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Features Section */
.features {
  background: var(--bg-secondary);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: var(--space-xl);
}

.feature-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: var(--space-2xl);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--primary-gradient);
  opacity: 0;
  transition: opacity var(--transition-normal);
  z-index: -1;
}

.feature-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-2xl);
  border-color: transparent;
}

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

.feature-icon {
  width: 60px;
  height: 60px;
  background: var(--primary-gradient);
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-lg);
  color: white;
}

.feature-icon svg {
  width: 28px;
  height: 28px;
}

.feature-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.feature-description {
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
  line-height: 1.6;
}

.feature-details ul {
  list-style: none;
  padding: 0;
}

.feature-details li {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.feature-details li::before {
  content: '✓';
  color: var(--primary-color);
  font-weight: bold;
}

/* Architecture Section */
.architecture-diagram {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  margin-bottom: var(--space-4xl);
}

.arch-layer {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  padding: var(--space-xl);
  transition: all var(--transition-normal);
}

.arch-layer:hover {
  transform: translateX(10px);
  box-shadow: var(--shadow-lg);
}

.arch-layer h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: var(--space-lg);
  color: var(--primary-color);
}

.arch-components {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
}

.arch-component {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: var(--space-sm) var(--space-md);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.architecture-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-xl);
}

.arch-feature {
  text-align: center;
  padding: var(--space-xl);
}

.arch-feature-icon {
  width: 60px;
  height: 60px;
  background: var(--primary-gradient);
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-lg);
  color: white;
}

.arch-feature-icon svg {
  width: 28px;
  height: 28px;
}

.arch-feature h4 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.arch-feature p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Documentation Section */
.docs {
  background: var(--bg-secondary);
}

.docs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: var(--space-xl);
}

.doc-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: var(--space-2xl);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.doc-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
}

.doc-icon {
  width: 50px;
  height: 50px;
  background: var(--primary-gradient);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-lg);
  color: white;
}

.doc-icon svg {
  width: 24px;
  height: 24px;
}

.doc-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.doc-card p {
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
  line-height: 1.6;
}

.doc-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  color: var(--primary-color);
  font-weight: 600;
  transition: all var(--transition-fast);
}

.doc-link:hover {
  gap: var(--space-md);
}

.doc-link svg {
  width: 16px;
  height: 16px;
}

/* Download Section */
.download-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: var(--space-xl);
  margin-bottom: var(--space-4xl);
}

.download-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: var(--space-2xl);
  position: relative;
  transition: all var(--transition-normal);
}

.download-card.featured {
  border: 2px solid var(--primary-color);
  transform: scale(1.05);
}

.download-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
}

.download-card.featured:hover {
  transform: scale(1.05) translateY(-5px);
}

.download-badge {
  position: absolute;
  top: -10px;
  right: var(--space-lg);
  background: var(--primary-gradient);
  color: white;
  padding: var(--space-sm) var(--space-md);
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
}

.download-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-lg);
}

.download-header h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.download-version {
  background: var(--bg-secondary);
  color: var(--text-secondary);
  padding: var(--space-xs) var(--space-sm);
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: 500;
}

.download-description {
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
  line-height: 1.6;
}

.download-features {
  margin-bottom: var(--space-xl);
}

.download-features .feature {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.download-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.download-size {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.system-requirements {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: var(--space-2xl);
}

.system-requirements h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: var(--space-lg);
  color: var(--text-primary);
}

.requirements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-lg);
}

.requirement {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.requirement strong {
  color: var(--text-primary);
  font-weight: 600;
}

.requirement span {
  color: var(--text-secondary);
  font-size: 0.875rem;
}

/* Footer */
.footer {
  background: var(--bg-dark);
  color: var(--text-inverse);
  padding: var(--space-4xl) 0 var(--space-xl);
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: var(--space-4xl);
  margin-bottom: var(--space-4xl);
}

.footer-brand {
  max-width: 400px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.footer-logo-icon {
  width: 40px;
  height: 40px;
}

.footer-brand-text h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
}

.footer-brand-text p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.875rem;
  margin: 0;
}

.footer-description {
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.6;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
}

.footer-section h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: var(--space-lg);
  color: white;
}

.footer-section a {
  display: block;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: var(--space-sm);
  transition: color var(--transition-fast);
}

.footer-section a:hover {
  color: white;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-xl);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-copyright p {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.875rem;
  margin: 0;
}

.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: rgba(255, 255, 255, 0.7);
  transition: all var(--transition-fast);
}

.footer-social a:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

.footer-social svg {
  width: 20px;
  height: 20px;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
    text-align: center;
  }
  
  .hero-visual {
    order: -1;
  }
  
  .phone-mockup {
    transform: none;
    width: 250px;
    height: 500px;
  }
  
  .architecture-diagram {
    gap: var(--space-lg);
  }
  
  .arch-layer:hover {
    transform: none;
  }
  
  .footer-content {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
  }
  
  .footer-links {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-menu {
    display: none;
  }
  
  .nav-toggle {
    display: flex;
  }
  
  .hero-actions {
    flex-direction: column;
    align-items: center;
  }
  
  .hero-stats {
    justify-content: center;
  }
  
  .features-grid,
  .docs-grid {
    grid-template-columns: 1fr;
  }
  
  .download-options {
    grid-template-columns: 1fr;
  }
  
  .download-card.featured {
    transform: none;
  }
  
  .requirements-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-links {
    grid-template-columns: 1fr;
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: var(--space-lg);
    text-align: center;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 var(--space-md);
  }
  
  .nav-container {
    padding: 0 var(--space-md);
  }
  
  .hero-container {
    padding: var(--space-2xl) var(--space-md);
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .hero-title {
    font-size: 2.5rem;
  }
  
  .phone-mockup {
    width: 200px;
    height: 400px;
  }
}/*
 Enhanced Mobile Navigation */
.nav-menu.active {
  display: flex;
  position: fixed;
  top: 70px;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  flex-direction: column;
  padding: var(--space-lg);
  box-shadow: var(--shadow-xl);
  z-index: var(--z-modal);
  animation: slideDown 0.3s ease-out;
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Mobile-specific improvements */
@media (max-width: 768px) {
  .nav-menu a {
    padding: var(--space-md) 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 1.125rem;
  }
  
  .nav-menu a:last-child {
    border-bottom: none;
  }
  
  /* Improve touch targets */
  .btn {
    min-height: 48px;
    padding: var(--space-md) var(--space-xl);
  }
  
  /* Better spacing for mobile */
  .hero-container {
    padding: var(--space-xl) var(--space-lg);
  }
  
  .hero-title {
    font-size: 2.5rem;
    line-height: 1.1;
  }
  
  .hero-description {
    font-size: 1.125rem;
  }
  
  /* Improve card layouts on mobile */
  .feature-card,
  .doc-card {
    padding: var(--space-lg);
  }
  
  /* Better mobile typography */
  .section-title {
    font-size: 2rem;
    line-height: 1.2;
  }
  
  .section-description {
    font-size: 1.125rem;
  }
}

@media (max-width: 480px) {
  /* Extra small screens */
  .hero-badge {
    font-size: 0.75rem;
    padding: var(--space-xs) var(--space-md);
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .hero-actions {
    flex-direction: column;
    width: 100%;
  }
  
  .btn {
    width: 100%;
    justify-content: center;
  }
  
  .hero-stats {
    flex-direction: column;
    gap: var(--space-lg);
    text-align: center;
  }
  
  .stat-number {
    font-size: 1.5rem;
  }
  
  /* Improve mobile navigation */
  .nav-container {
    padding: 0 var(--space-md);
  }
  
  .nav-brand .nav-title {
    font-size: 1.125rem;
  }
  
  /* Better mobile cards */
  .feature-card,
  .doc-card,
  .download-card {
    padding: var(--space-md);
    margin-bottom: var(--space-lg);
  }
  
  /* Mobile-friendly architecture diagram */
  .architecture-diagram {
    overflow-x: auto;
    padding: var(--space-md);
  }
  
  .arch-layer {
    min-width: 280px;
  }
}

/* Landscape mobile improvements */
@media (max-width: 768px) and (orientation: landscape) {
  .hero {
    min-height: 80vh;
  }
  
  .hero-container {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
  }
  
  .hero-visual {
    order: 0;
  }
}

/* Touch device improvements */
@media (hover: none) and (pointer: coarse) {
  /* Remove hover effects on touch devices */
  .feature-card:hover,
  .doc-card:hover,
  .btn:hover {
    transform: none;
  }
  
  /* Add touch feedback */
  .feature-card:active,
  .doc-card:active,
  .btn:active {
    transform: scale(0.98);
    transition: transform 0.1s ease;
  }
  
  /* Improve touch targets */
  .nav-link,
  .btn,
  .doc-link {
    min-height: 44px;
    display: flex;
    align-items: center;
  }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  /* Optimize for retina displays */
  .nav-logo,
  .loader-icon {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
  /* Disable animations for users who prefer reduced motion */
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  
  .phone-mockup {
    animation: none !important;
  }
  
  .app-icon {
    animation: none !important;
  }
  
  .scroll-arrow {
    animation: none !important;
  }
}

/* Dark mode support */
[data-theme="dark"] {
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --text-inverse: #000000;
  
  --bg-primary: #0f172a;
  --bg-secondary: #1e293b;
  --bg-tertiary: #334155;
  --bg-dark: #000000;
  --bg-card: rgba(30, 41, 59, 0.8);
  
  --border-color: rgba(255, 255, 255, 0.1);
  --border-light: rgba(255, 255, 255, 0.2);
}

[data-theme="dark"] .nav {
  background: rgba(15, 23, 42, 0.95);
}

[data-theme="dark"] .nav.scrolled {
  background: rgba(15, 23, 42, 0.98);
}

[data-theme="dark"] .hero-gradient {
  opacity: 0.3;
}

[data-theme="dark"] .loader {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

[data-theme="dark"] .footer {
  background: #000000;
}

/* Auto dark mode based on system preference */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
    --text-inverse: #000000;
    
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --bg-dark: #000000;
    --bg-card: rgba(30, 41, 59, 0.8);
    
    --border-color: rgba(255, 255, 255, 0.1);
    --border-light: rgba(255, 255, 255, 0.2);
  }

  :root:not([data-theme="light"]) .nav {
    background: rgba(15, 23, 42, 0.95);
  }

  :root:not([data-theme="light"]) .nav.scrolled {
    background: rgba(15, 23, 42, 0.98);
  }

  :root:not([data-theme="light"]) .hero-gradient {
    opacity: 0.3;
  }

  :root:not([data-theme="light"]) .loader {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  }

  :root:not([data-theme="light"]) .footer {
    background: #000000;
  }
}

/* Print styles */
@media print {
  /* Optimize for printing */
  .nav,
  .hero-scroll,
  .footer {
    display: none;
  }
  
  .hero {
    min-height: auto;
    page-break-after: always;
  }
  
  .section {
    page-break-inside: avoid;
  }
  
  .feature-card,
  .doc-card {
    break-inside: avoid;
  }
  
  /* Ensure good contrast for printing */
  .gradient-text {
    color: #333 !important;
    -webkit-text-fill-color: #333 !important;
  }
  
  .btn {
    border: 2px solid #333 !important;
    color: #333 !important;
    background: white !important;
  }
}