/* ========================================
   EA NATION - MAIN STYLESHEET
   Premium Fintech Mobile-First Experience
   ======================================== */

/* === IMPORTS === */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* === CSS CUSTOM PROPERTIES === */
:root {
  /* Brand Colors */
  --green: #55BB52;
  --green-hover: #4aa947;
  --green-light: rgba(85, 187, 82, 0.1);
  
  /* Dark Theme */
  --bg: #0a0e1a;
  --bg-secondary: #121828;
  --surface: rgba(255, 255, 255, 0.05);
  --surface-hover: rgba(255, 255, 255, 0.08);
  --border: rgba(255, 255, 255, 0.1);
  
  /* Accent Colors */
  --gold: #d4af37;
  --gold-muted: rgba(212, 175, 55, 0.15);
  
  /* Typography */
  --text-primary: #ffffff;
  --text-secondary: rgba(255, 255, 255, 0.7);
  --text-muted: rgba(255, 255, 255, 0.5);
  
  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  --spacing-xl: 3rem;
  
  /* Border Radius */
  --radius-sm: 0.5rem;
  --radius-md: 1rem;
  --radius-lg: 1.5rem;
  --radius-xl: 2rem;
  
  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.15);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.3);
  --shadow-green: 0 4px 20px rgba(85, 187, 82, 0.3);
  
  /* Layout */
  --max-width: 1200px;
  --nav-height: 72px;
  --header-height: 64px;
  
  /* Z-index Stack */
  --z-nav: 1000;
  --z-fab: 999;
  --z-messenger: 1001;
  --z-modal: 1100;
}

/* === RESET & BASE === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  padding-bottom: var(--nav-height);
}

/* === TYPOGRAPHY === */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--spacing-sm);
}

h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  letter-spacing: -0.015em;
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

h4 {
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
}

p {
  margin-bottom: var(--spacing-sm);
  color: var(--text-secondary);
}

a {
  color: var(--green);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

/* === HEADER === */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: rgba(10, 14, 26, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  z-index: var(--z-nav);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--spacing-md);
}

.logo {
  height: 40px;
  width: auto;
  object-fit: contain;
}

/* === MAIN CONTAINER === */
.app-container {
  min-height: 100vh;
  padding-top: var(--header-height);
}

#app {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--spacing-md);
  padding-bottom: 10rem;
}

/* === GLASSMORPHISM CARDS === */
.card {
  background: var(--surface);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--spacing-md);
  box-shadow: var(--shadow-md);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card:hover {
  background: var(--surface-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.card-grid {
  display: grid;
  gap: var(--spacing-md);
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

/* === BUTTONS === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-xs);
  padding: 1rem 2rem;
  border: none;
  border-radius: var(--radius-lg);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
  white-space: nowrap;
  font-family: inherit;
}

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

.btn-primary:hover {
  background: var(--green-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(85, 187, 82, 0.4);
}

.btn-secondary {
  background: var(--surface);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--surface-hover);
  border-color: var(--green);
}

.btn-icon {
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: 50%;
}

/* === FLOATING ACTION BUTTONS === */
.fab {
  position: fixed;
  bottom: calc(var(--nav-height) + 1.5rem);
  left: 50%;
  transform: translateX(-50%);
  z-index: var(--z-fab);
  max-width: 200px;
  width: auto;
  padding: 0.875rem 2rem;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.fab-messenger {
  position: fixed;
  bottom: calc(var(--nav-height) + 5rem);
  right: var(--spacing-md);
  z-index: var(--z-messenger);
  background: white;
  color: #0084ff;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(0, 132, 255, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
}

.fab-messenger:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 28px rgba(0, 132, 255, 0.5);
}

.fab-messenger svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

/* === BOTTOM NAVIGATION === */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  background: rgba(10, 14, 26, 0.98);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  z-index: var(--z-nav);
  display: flex;
  justify-content: space-around;
  padding: 0.5rem 0;
  box-shadow: 0 -2px 20px rgba(0, 0, 0, 0.3);
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  flex: 1;
  cursor: pointer;
  color: var(--text-muted);
  transition: all 0.3s ease;
  border: none;
  background: transparent;
  font-family: inherit;
  text-align: center;
  padding: 0.5rem 0.25rem;
  position: relative;
}

.nav-item:hover {
  color: var(--text-secondary);
}

.nav-item.active {
  color: var(--green);
}

.nav-item.active::before {
  content: '';
  position: absolute;
  top: 0;
  left: 10%;
  right: 10%;
  height: 3px;
  background: var(--green);
  border-radius: 0 0 3px 3px;
}

.nav-icon {
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-label {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  line-height: 1;
}

/* === SECTION SPACING === */
.section {
  padding: var(--spacing-xl) 0;
}

.section-title {
  text-align: center;
  margin-bottom: var(--spacing-lg);
}

.section-subtitle {
  text-align: center;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto var(--spacing-lg);
}

/* === HERO SECTION === */
.hero {
  text-align: center;
  padding: var(--spacing-xl) 0;
  position: relative;
}

.hero-title {
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--green) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--spacing-md);
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-lg);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: var(--spacing-xl);
}

.hero-visual {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  padding: var(--spacing-lg);
}

.dashboard-preview {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: var(--spacing-lg);
  backdrop-filter: blur(20px);
  box-shadow: var(--shadow-lg);
}

/* === FEATURE CARDS === */
.feature-icon {
  width: 48px;
  height: 48px;
  background: var(--green-light);
  color: var(--green);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: var(--spacing-sm);
}

.feature-title {
  font-size: 1.25rem;
  margin-bottom: var(--spacing-xs);
}

.feature-description {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* === STEPPER === */
.stepper {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
  max-width: 700px;
  margin: 0 auto;
}

.step {
  display: flex;
  gap: var(--spacing-md);
  align-items: flex-start;
}

.step-number {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  background: var(--green);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  font-weight: 700;
  box-shadow: var(--shadow-green);
}

.step-content h4 {
  margin-bottom: var(--spacing-xs);
}

.step-content p {
  margin: 0;
}

/* === IMAGE SLIDER === */
.slider {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--surface);
}

.slider-track {
  display: flex;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.slider-item {
  flex: 0 0 100%;
  position: relative;
}

.slider-item img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-lg);
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

.slider-controls {
  position: absolute;
  bottom: var(--spacing-md);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: var(--spacing-xs);
  z-index: 10;
}

.slider-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  padding: 0;
}

.slider-dot.active {
  background: var(--green);
  width: 24px;
  border-radius: 4px;
}

.slider-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.slider-nav:hover {
  background: rgba(0, 0, 0, 0.7);
}

.slider-nav.prev {
  left: var(--spacing-sm);
}

.slider-nav.next {
  right: var(--spacing-sm);
}

/* === ACCORDION === */
.accordion {
  max-width: 800px;
  margin: 0 auto;
}

.accordion-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-bottom: var(--spacing-sm);
  overflow: hidden;
  transition: all 0.3s ease;
}

.accordion-header {
  width: 100%;
  padding: var(--spacing-md);
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 1.1rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: inherit;
  transition: color 0.3s ease;
}

.accordion-header:hover {
  color: var(--green);
}

.accordion-icon {
  transition: transform 0.3s ease;
  font-size: 1.25rem;
}

.accordion-item.active .accordion-icon {
  transform: rotate(180deg);
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.accordion-item.active .accordion-content {
  max-height: 500px;
}

.accordion-body {
  padding: 0 var(--spacing-md) var(--spacing-md);
  color: var(--text-secondary);
}

/* === VIDEO CONTAINER === */
.video-container {
  position: relative;
  width: 100%;
  max-width: 800px;
  margin: 0 auto var(--spacing-lg);
  aspect-ratio: 16 / 9;
  background: var(--surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
}

.video-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-sm);
  color: var(--text-muted);
}

.video-placeholder svg {
  width: 64px;
  height: 64px;
  opacity: 0.5;
}

/* === STAT CARDS === */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--spacing-md);
  margin: var(--spacing-lg) 0;
}

.stat-card {
  text-align: center;
  padding: var(--spacing-lg);
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--green);
  margin-bottom: var(--spacing-xs);
  display: block;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* === RISK DISCLOSURE === */
.risk-disclosure {
  background: rgba(255, 193, 7, 0.1);
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: var(--radius-lg);
  padding: var(--spacing-md);
  margin: var(--spacing-lg) 0;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.risk-disclosure h4 {
  color: #ffc107;
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  margin-bottom: var(--spacing-sm);
}

.risk-disclosure p {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* === CALCULATOR === */
.calculator {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  max-width: 800px;
  margin: var(--spacing-lg) auto;
  backdrop-filter: blur(20px);
}

.calculator-inputs {
  display: grid;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
}

.input-group label {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.input-group input {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  color: var(--text-primary);
  font-size: 1rem;
  font-family: inherit;
  transition: all 0.3s ease;
}

.input-group input:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px var(--green-light);
}

.calculator-result {
  margin-top: var(--spacing-lg);
  text-align: center;
}

.calculator-chart {
  width: 100%;
  height: 300px;
  margin-top: var(--spacing-md);
  border-radius: var(--radius-md);
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  :root {
    --spacing-xl: 2rem;
    --spacing-lg: 1.5rem;
  }

  #app {
    padding: var(--spacing-sm);
  }

  .hero-cta {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .stats {
    grid-template-columns: 1fr;
  }

  .nav-label {
    font-size: 0.6rem;
  }

  .fab {
    bottom: calc(var(--nav-height) + var(--spacing-sm));
    left: 50%;
    transform: translateX(-50%);
  }

  .fab-messenger {
    bottom: calc(var(--nav-height) + 4rem);
    right: var(--spacing-sm);
  }
}

@media (max-width: 480px) {
  .nav-icon {
    font-size: 1.25rem;
  }

  .nav-label {
    font-size: 0.55rem;
  }

  .bottom-nav {
    padding: 0.25rem 0;
  }
}

/* === UTILITY CLASSES === */
.text-center {
  text-align: center;
}

.text-green {
  color: var(--green);
}

.text-muted {
  color: var(--text-muted);
}

.mb-sm {
  margin-bottom: var(--spacing-sm);
}

.mb-md {
  margin-bottom: var(--spacing-md);
}

.mb-lg {
  margin-bottom: var(--spacing-lg);
}

.hidden {
  display: none !important;
}

.fade-in {
  opacity: 0;
  animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}
