/* ============================================================
   INCOME ARCHITECT — GLOBAL STYLES
   ============================================================ */

:root {
  --primary: #F5A623;
  --secondary: #1a1a2e;
  --accent: #e94560;
  --bg: #0f0f23;
  --surface: #16213e;
  --text: #ffffff;
  --text-muted: #94a3b8;
  --gradient: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 48px rgba(0,0,0,0.6);
  --transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
  --font: 'Inter', system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { opacity: 0.85; }

img { max-width: 100%; display: block; }

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
h1 { font-size: clamp(2.2rem, 5vw, 4rem); font-weight: 800; line-height: 1.1; }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 700; }
h3 { font-size: clamp(1.2rem, 2vw, 1.6rem); font-weight: 600; }
h4 { font-size: 1.1rem; font-weight: 600; }
p { color: var(--text-muted); }

/* ============================================================
   LAYOUT UTILITIES
   ============================================================ */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.container-sm { max-width: 800px; margin: 0 auto; padding: 0 24px; }
.container-xs { max-width: 560px; margin: 0 auto; padding: 0 24px; }

.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-col { display: flex; flex-direction: column; }
.gap-4 { gap: 4px; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-24 { gap: 24px; }
.gap-32 { gap: 32px; }

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

.text-center { text-align: center; }
.text-right { text-align: right; }

.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mt-48 { margin-top: 48px; }
.mt-64 { margin-top: 64px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }
.pt-80 { padding-top: 80px; }
.pb-80 { padding-bottom: 80px; }

/* ============================================================
   CARD
   ============================================================ */
.card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255,255,255,0.06);
  transition: var(--transition);
}
.card:hover { border-color: rgba(245,166,35,0.25); box-shadow: var(--shadow-lg); }
.card-sm { padding: 20px; border-radius: var(--radius); }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
  font-family: var(--font);
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #e8920a);
  color: #000;
  box-shadow: 0 4px 20px rgba(245,166,35,0.4);
}
.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(245,166,35,0.6);
}

.btn-secondary {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}
.btn-secondary:hover:not(:disabled) { background: rgba(245,166,35,0.1); }

.btn-accent {
  background: linear-gradient(135deg, var(--accent), #c73250);
  color: #fff;
}
.btn-accent:hover:not(:disabled) { transform: translateY(-2px); opacity: 0.9; }

.btn-ghost {
  background: rgba(255,255,255,0.08);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.12);
}
.btn-ghost:hover:not(:disabled) { background: rgba(255,255,255,0.14); }

.btn-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
}
.btn-sm { padding: 8px 18px; font-size: 0.875rem; }
.btn-lg { padding: 18px 40px; font-size: 1.125rem; }
.btn-xl { padding: 22px 52px; font-size: 1.25rem; }
.btn-full { width: 100%; }
.btn-icon { width: 44px; height: 44px; padding: 0; border-radius: 50%; }

/* ============================================================
   FORMS
   ============================================================ */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 8px;
}
.form-label span { color: var(--accent); }

.form-control {
  width: 100%;
  padding: 14px 18px;
  background: rgba(255,255,255,0.06);
  border: 1.5px solid rgba(255,255,255,0.12);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  transition: var(--transition);
  outline: none;
}
.form-control:focus {
  border-color: var(--primary);
  background: rgba(245,166,35,0.06);
  box-shadow: 0 0 0 3px rgba(245,166,35,0.12);
}
.form-control::placeholder { color: var(--text-muted); }

select.form-control { cursor: pointer; }
select.form-control option { background: var(--surface); color: var(--text); }

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

.form-hint { font-size: 0.8rem; color: var(--text-muted); margin-top: 6px; }

/* Choice buttons */
.choice-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
.choice-btn {
  padding: 14px 16px;
  background: rgba(255,255,255,0.05);
  border: 2px solid rgba(255,255,255,0.1);
  border-radius: var(--radius);
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  font-size: 0.9rem;
  font-weight: 500;
  user-select: none;
}
.choice-btn:hover { border-color: var(--primary); color: var(--primary); }
.choice-btn.selected {
  border-color: var(--primary);
  background: rgba(245,166,35,0.12);
  color: var(--primary);
}

/* Range slider */
.range-wrap { position: relative; }
.form-range {
  width: 100%;
  -webkit-appearance: none;
  height: 6px;
  border-radius: 3px;
  background: rgba(255,255,255,0.1);
  outline: none;
}
.form-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(245,166,35,0.5);
}
.range-value {
  text-align: center;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary);
  margin-top: 8px;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 16px 0;
  transition: var(--transition);
  background: transparent;
}
.navbar.scrolled {
  background: rgba(15,15,35,0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  padding: 12px 0;
}
.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}
.logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo span { color: var(--primary); }
.logo-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), #e8920a);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: #000;
  font-weight: 900;
}

.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-links a { color: var(--text-muted); font-weight: 500; font-size: 0.95rem; }
.nav-links a:hover { color: var(--primary); }

.nav-actions { display: flex; align-items: center; gap: 12px; }

/* Currency Switcher */
.currency-switcher {
  position: relative;
}
.currency-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 50px;
  color: var(--text);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font);
}
.currency-btn:hover { background: rgba(255,255,255,0.14); }
.currency-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius);
  padding: 8px;
  min-width: 200px;
  display: none;
  z-index: 200;
  box-shadow: var(--shadow-lg);
}
.currency-dropdown.open { display: block; }
.currency-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.9rem;
}
.currency-option:hover { background: rgba(255,255,255,0.08); }
.currency-option.active { color: var(--primary); }

/* Mobile nav */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: var(--transition);
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 80px;
  position: relative;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background: var(--gradient);
  z-index: 0;
}
.hero-particles {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}
.particle {
  position: absolute;
  border-radius: 50%;
  background: var(--primary);
  opacity: 0.08;
  animation: float 6s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-20px); }
}
.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  border-radius: 50px;
  background: rgba(245,166,35,0.12);
  border: 1px solid rgba(245,166,35,0.3);
  color: var(--primary);
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 24px;
}
.hero h1 { margin-bottom: 16px; }
.hero h1 em { font-style: normal; color: var(--primary); }
.hero-sub {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 40px;
}

/* Hero input box */
.hero-input-box {
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(20px);
  border: 2px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-lg);
  padding: 32px;
  max-width: 600px;
  margin: 0 auto;
  transition: var(--transition);
}
.hero-input-box:hover { border-color: rgba(245,166,35,0.3); }
.hero-input-label {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--text-muted);
}
.hero-input-row {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}
.hero-amount-input {
  flex: 1;
  padding: 16px 20px;
  background: rgba(255,255,255,0.08);
  border: 2px solid rgba(255,255,255,0.12);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 1.5rem;
  font-weight: 700;
  font-family: var(--font);
  outline: none;
  transition: var(--transition);
}
.hero-amount-input:focus {
  border-color: var(--primary);
  background: rgba(245,166,35,0.06);
}
.hero-amount-input::placeholder { color: rgba(255,255,255,0.2); font-weight: 400; font-size: 1.1rem; }

.quick-amounts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}
.quick-amount {
  padding: 8px 18px;
  border-radius: 50px;
  background: rgba(255,255,255,0.07);
  border: 1.5px solid rgba(255,255,255,0.1);
  color: var(--text-muted);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.quick-amount:hover, .quick-amount.active {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(245,166,35,0.1);
}

/* ============================================================
   STEP PROGRESS
   ============================================================ */
.progress-bar-wrap {
  background: rgba(255,255,255,0.08);
  border-radius: 50px;
  height: 6px;
  overflow: hidden;
  margin-bottom: 8px;
}
.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 50px;
  transition: width 0.5s ease;
}
.step-indicators {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  gap: 8px;
}
.step-dot {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  border: 2px solid rgba(255,255,255,0.15);
  color: var(--text-muted);
  transition: var(--transition);
  flex-shrink: 0;
}
.step-dot.active { border-color: var(--primary); color: var(--primary); background: rgba(245,166,35,0.12); }
.step-dot.done { border-color: #10b981; background: #10b981; color: #fff; }
.step-line { flex: 1; height: 2px; background: rgba(255,255,255,0.08); border-radius: 1px; }
.step-line.done { background: #10b981; }

/* ============================================================
   STEP FORM PAGE
   ============================================================ */
.step-form-page { display: none; animation: fadeIn 0.4s ease; }
.step-form-page.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

.step-title { margin-bottom: 8px; }
.step-description { color: var(--text-muted); margin-bottom: 32px; font-size: 1rem; }

/* ============================================================
   SKILL TAGS
   ============================================================ */
.tag-wrap { display: flex; flex-wrap: wrap; gap: 10px; }
.skill-tag {
  padding: 8px 18px;
  border-radius: 50px;
  background: rgba(255,255,255,0.06);
  border: 1.5px solid rgba(255,255,255,0.1);
  color: var(--text-muted);
  font-size: 0.875rem;
  cursor: pointer;
  transition: var(--transition);
}
.skill-tag:hover { border-color: var(--primary); color: var(--primary); }
.skill-tag.selected {
  border-color: var(--primary);
  background: rgba(245,166,35,0.12);
  color: var(--primary);
}

/* ============================================================
   RATING STARS / SCORE
   ============================================================ */
.score-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.score-label { font-size: 0.95rem; font-weight: 500; }
.score-dots { display: flex; gap: 6px; }
.score-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.15);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
}
.score-dot:hover, .score-dot.active { border-color: var(--primary); background: rgba(245,166,35,0.2); color: var(--primary); }

/* ============================================================
   TOAST NOTIFICATION
   ============================================================ */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: var(--shadow-lg);
  min-width: 280px;
  animation: slideIn 0.3s ease;
}
.toast.success { border-left: 4px solid #10b981; }
.toast.error { border-left: 4px solid #ef4444; }
.toast.info { border-left: 4px solid var(--primary); }
@keyframes slideIn { from { transform: translateX(100px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.toast-icon { font-size: 1.2rem; }
.toast-message { font-size: 0.9rem; font-weight: 500; color: var(--text); }

/* ============================================================
   MODAL
   ============================================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(8px);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 40px;
  max-width: 560px;
  width: 100%;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(255,255,255,0.08);
  transform: translateY(20px);
  transition: var(--transition);
}
.modal-overlay.open .modal { transform: translateY(0); }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.modal-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  border: none;
  color: var(--text);
  cursor: pointer;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.modal-close:hover { background: rgba(255,255,255,0.15); }

/* ============================================================
   SECTIONS
   ============================================================ */
.section { padding: 80px 0; }
.section-title { margin-bottom: 48px; }
.section-tag {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 50px;
  background: rgba(245,166,35,0.12);
  color: var(--primary);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

/* Stats */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; }
.stat-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  border: 1px solid rgba(255,255,255,0.06);
}
.stat-number { font-size: 2.4rem; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 0.9rem; color: var(--text-muted); margin-top: 4px; }

/* How It Works steps */
.how-step {
  display: flex;
  gap: 24px;
  align-items: flex-start;
  margin-bottom: 32px;
}
.how-number {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #e8920a);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 800;
  color: #000;
  flex-shrink: 0;
}
.how-content h4 { margin-bottom: 6px; }
.how-content p { font-size: 0.95rem; }

/* Pricing card */
.pricing-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 40px;
  border: 2px solid rgba(255,255,255,0.08);
  transition: var(--transition);
  text-align: center;
  position: relative;
}
.pricing-card.featured {
  border-color: var(--primary);
  background: linear-gradient(135deg, rgba(245,166,35,0.08), rgba(245,166,35,0.02));
}
.pricing-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 20px;
  background: linear-gradient(135deg, var(--primary), #e8920a);
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 700;
  color: #000;
}
.pricing-price { font-size: 3rem; font-weight: 800; color: var(--primary); }
.pricing-price span { font-size: 1rem; color: var(--text-muted); font-weight: 400; }
.pricing-features { list-style: none; margin: 24px 0; text-align: left; }
.pricing-features li {
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-muted);
}
.pricing-features li::before { content: "✓"; color: #10b981; font-weight: 700; }

/* ============================================================
   FAQ ACCORDION
   ============================================================ */
.faq-item {
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.faq-q {
  width: 100%;
  padding: 20px 0;
  background: none;
  border: none;
  color: var(--text);
  font-size: 1rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-family: var(--font);
}
.faq-icon { font-size: 1.4rem; color: var(--primary); transition: var(--transition); }
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-a { display: none; padding-bottom: 20px; }
.faq-a p { font-size: 0.95rem; line-height: 1.7; }
.faq-item.open .faq-a { display: block; }

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  padding: 60px 0 30px;
  border-top: 1px solid rgba(255,255,255,0.06);
  background: rgba(0,0,0,0.3);
}
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; }
.footer-brand p { font-size: 0.9rem; margin-top: 16px; line-height: 1.7; }
.footer-col h5 { font-size: 0.9rem; font-weight: 700; margin-bottom: 16px; color: var(--text); }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul li a { color: var(--text-muted); font-size: 0.9rem; }
.footer-col ul li a:hover { color: var(--primary); }
.footer-bottom {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-bottom p { font-size: 0.85rem; }

/* ============================================================
   DISCLAIMER BANNER
   ============================================================ */
.disclaimer-bar {
  background: rgba(245,166,35,0.08);
  border: 1px solid rgba(245,166,35,0.2);
  border-radius: var(--radius);
  padding: 16px 20px;
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.6;
}
.disclaimer-bar strong { color: var(--primary); }

/* ============================================================
   LOADING SPINNER
   ============================================================ */
.spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(255,255,255,0.1);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto;
}
@keyframes spin { to { transform: rotate(360deg); } }

.loading-state {
  text-align: center;
  padding: 60px 20px;
}
.loading-state p { margin-top: 20px; color: var(--text-muted); }

/* ============================================================
   PLAN RESULT
   ============================================================ */
.plan-result {
  font-size: 0.95rem;
  line-height: 1.9;
}
.plan-result h2 { font-size: 1.5rem; margin: 32px 0 12px; color: var(--primary); }
.plan-result h3 { font-size: 1.2rem; margin: 24px 0 10px; color: var(--text); }
.plan-result h4 { margin: 16px 0 8px; }
.plan-result p { margin-bottom: 12px; }
.plan-result ul, .plan-result ol { padding-left: 24px; margin-bottom: 16px; }
.plan-result li { margin-bottom: 6px; color: var(--text-muted); }
.plan-result strong { color: var(--text); }
.plan-result table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 0.9rem;
}
.plan-result table th {
  background: rgba(245,166,35,0.12);
  padding: 12px 16px;
  text-align: left;
  color: var(--primary);
  font-weight: 600;
}
.plan-result table td {
  padding: 10px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  color: var(--text-muted);
}
.plan-result blockquote {
  border-left: 3px solid var(--primary);
  padding: 12px 20px;
  margin: 16px 0;
  background: rgba(245,166,35,0.06);
  border-radius: 0 var(--radius) var(--radius) 0;
}

/* ============================================================
   ADMIN STYLES
   ============================================================ */
.admin-layout {
  display: flex;
  min-height: 100vh;
}
.admin-sidebar {
  width: 260px;
  background: var(--surface);
  border-right: 1px solid rgba(255,255,255,0.06);
  padding: 24px 0;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 50;
  overflow-y: auto;
}
.admin-sidebar-header { padding: 0 20px 24px; border-bottom: 1px solid rgba(255,255,255,0.06); }
.admin-main { margin-left: 260px; flex: 1; padding: 32px; min-height: 100vh; }
.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  border-left: 3px solid transparent;
}
.admin-nav-item:hover { color: var(--text); background: rgba(255,255,255,0.04); }
.admin-nav-item.active { color: var(--primary); border-left-color: var(--primary); background: rgba(245,166,35,0.06); }
.admin-nav-section { padding: 12px 20px 4px; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: rgba(255,255,255,0.2); }
.admin-panel { display: none; }
.admin-panel.active { display: block; }
.admin-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
}
.admin-page-title { font-size: 1.6rem; font-weight: 700; }

/* Table */
.data-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.data-table th {
  padding: 12px 16px;
  text-align: left;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 2px solid rgba(255,255,255,0.08);
}
.data-table td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  color: var(--text-muted);
  vertical-align: middle;
}
.data-table tr:hover td { background: rgba(255,255,255,0.03); }

/* Status badges */
.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
}
.badge-success { background: rgba(16,185,129,0.15); color: #10b981; }
.badge-warning { background: rgba(245,166,35,0.15); color: var(--primary); }
.badge-danger { background: rgba(239,68,68,0.15); color: #ef4444; }
.badge-info { background: rgba(59,130,246,0.15); color: #3b82f6; }

/* Metric cards */
.metric-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid rgba(255,255,255,0.06);
}
.metric-value { font-size: 2rem; font-weight: 800; color: var(--text); margin: 8px 0 4px; }
.metric-label { font-size: 0.85rem; color: var(--text-muted); }
.metric-change { font-size: 0.8rem; font-weight: 600; }
.metric-change.up { color: #10b981; }
.metric-change.down { color: #ef4444; }

/* Color theme grid */
.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; }
.theme-card {
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  transition: var(--transition);
}
.theme-card:hover { border-color: rgba(255,255,255,0.2); }
.theme-card.active { border-color: var(--primary); }
.theme-preview {
  height: 80px;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.theme-name {
  background: var(--surface);
  padding: 10px 14px;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
}

/* Code editor */
.code-editor {
  background: #0d1117;
  border-radius: var(--radius);
  padding: 20px;
  font-family: 'Fira Code', 'Courier New', monospace;
  font-size: 0.875rem;
  line-height: 1.7;
  color: #e6edf3;
  border: 1px solid rgba(255,255,255,0.1);
  min-height: 400px;
  resize: vertical;
  width: 100%;
  outline: none;
}
.code-editor:focus { border-color: var(--primary); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .admin-sidebar { transform: translateX(-100%); transition: transform 0.3s ease; }
  .admin-sidebar.open { transform: translateX(0); }
  .admin-main { margin-left: 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .hero-input-row { flex-direction: column; }
  .step-indicators { gap: 4px; }
  .step-dot { width: 28px; height: 28px; font-size: 0.7rem; }
  .card { padding: 24px 20px; }
  .modal { padding: 28px 20px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .admin-top-bar { flex-direction: column; align-items: flex-start; gap: 12px; }
  .data-table { font-size: 0.8rem; }
  .data-table th, .data-table td { padding: 10px 10px; }
}

@media (max-width: 480px) {
  .hero-input-box { padding: 24px 16px; }
  .quick-amounts { justify-content: center; }
  .section { padding: 60px 0; }
}

/* ============================================================
   SCROLL ANIMATIONS
   ============================================================ */
.fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible { opacity: 1; transform: translateY(0); }

/* ============================================================
   CUSTOM SCROLLBAR
   ============================================================ */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }

/* ============================================================
   PRINT (for reports)
   ============================================================ */
@media print {
  body { background: #fff; color: #000; }
  .navbar, footer, .btn, .toast-container { display: none; }
  .plan-result { color: #000; }
  .plan-result h2 { color: #1a1a2e; }
}
/* ============================================================
   HOME PAGE — MOBILE RESPONSIVE FIX
   ============================================================ */

@media (max-width: 768px) {

  /* Prevent navbar contents from forcing the page wider */
  .navbar-inner {
    width: 100%;
    min-width: 0;
    padding-left: 16px;
    padding-right: 16px;
  }

  .logo {
    min-width: 0;
    white-space: nowrap;
    font-size: 1.25rem;
    gap: 7px;
  }

  .logo-icon {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
  }

  .nav-actions {
    flex-shrink: 0;
    gap: 8px;
  }

  /* Hide desktop CTA because the hamburger already contains it */
  .nav-actions > .btn-primary {
    display: none;
  }

  .currency-btn {
    padding: 7px 10px;
    font-size: 0.8rem;
  }

  /* HERO */
  .hero {
    width: 100%;
    min-width: 0;
    padding-top: 90px;
    padding-bottom: 50px;
  }

  .hero-content {
    width: 100%;
    max-width: 100%;
    padding-left: 16px;
    padding-right: 16px;
    min-width: 0;
  }

  .hero h1 {
    font-size: clamp(2rem, 9vw, 3rem);
    line-height: 1.08;
    overflow-wrap: break-word;
  }

  .hero-sub {
    width: 100%;
    max-width: 100%;
    font-size: 1rem;
  }

  /* HERO INPUT BOX */
  .hero-input-box {
    width: 100%;
    max-width: 100%;
    padding: 24px 16px;
    box-sizing: border-box;
  }

  /* Stack amount + period selector */
  .hero-input-row {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  /* Override the inline width:220px */
  .hero-input-row > div {
    width: 100% !important;
    flex: 1 1 auto !important;
  }

  .hero-amount-input {
    width: 100% !important;
    max-width: 100%;
    box-sizing: border-box;
  }

  /* Override inline width:auto */
  #periodSelect {
    width: 100% !important;
    max-width: 100%;
    box-sizing: border-box;
  }

  /* Quick amounts */
  .quick-amounts {
    width: 100%;
    justify-content: center;
  }

  .quick-amount {
    padding: 8px 14px;
  }

  /* CTA button */
  .hero-input-box .btn {
    width: 100%;
    max-width: 100%;
    white-space: normal;
    min-height: 52px;
  }

  /* Floating currencies */
  .floating-currencies {
    width: 100%;
    max-width: 100%;
    gap: 8px;
    margin-top: 28px;
  }

  .float-cur {
    padding: 7px 12px;
    font-size: 0.8rem;
  }
}


/* Extra-small phones */
@media (max-width: 380px) {

  .navbar-inner {
    padding-left: 12px;
    padding-right: 12px;
  }

  .logo {
    font-size: 1.1rem;
  }

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

  .currency-btn {
    padding: 6px 8px;
  }

  .hero-content {
    padding-left: 12px;
    padding-right: 12px;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero-input-box {
    padding: 20px 14px;
  }

  .quick-amount {
    padding: 7px 11px;
    font-size: 0.8rem;
  }

  .float-cur {
    padding: 6px 10px;
    font-size: 0.75rem;
  }
}