/* =============================================
   Terra Flux LLC - Custom Styles
   Dark Theme with Neon Green Accents
   ============================================= */

:root {
  --bg-primary: #0a0a0a;
  --bg-secondary: #0d1117;
  --bg-card: #161b22;
  --border-color: #21262d;
  --border-hover: #30363d;
  --text-primary: #ffffff;
  --text-secondary: #b0b0b0;
  --text-muted: #6e7681;
  --accent: #00ff88;
  --accent-hover: #00cc6a;
  --accent-dim: rgba(0, 255, 136, 0.1);
  --accent-glow: rgba(0, 255, 136, 0.4);
  --danger: #ff4444;
  --warning: #ffaa00;
  --font-main: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 16px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { font-family: var(--font-main); background: var(--bg-primary); color: var(--text-primary); line-height: 1.6; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--accent-hover); }
img { max-width: 100%; height: auto; }
::selection { background: var(--accent-dim); color: var(--accent); }

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb { background: var(--border-color); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* Navbar */
.navbar { background: rgba(10,10,10,0.95) !important; backdrop-filter: blur(20px); border-bottom: 1px solid var(--border-color); padding: 0.75rem 0; transition: var(--transition); }
.navbar.scrolled { padding: 0.5rem 0; box-shadow: 0 4px 20px rgba(0,0,0,0.5); }
.navbar-brand img { max-height: 45px; width: auto; }
.navbar-nav .nav-link { color: var(--text-secondary) !important; font-weight: 500; font-size: 0.95rem; padding: 0.5rem 1rem !important; position: relative; transition: var(--transition); }
.navbar-nav .nav-link:hover, .navbar-nav .nav-link.active { color: var(--accent) !important; }
.navbar-nav .nav-link::after { content: ''; position: absolute; bottom: 0; left: 50%; width: 0; height: 2px; background: var(--accent); transition: var(--transition); transform: translateX(-50%); }
.navbar-nav .nav-link:hover::after, .navbar-nav .nav-link.active::after { width: 60%; }
.btn-nav-cta { background: var(--accent); color: var(--bg-primary) !important; border: none; padding: 0.5rem 1.5rem !important; border-radius: var(--radius-sm); font-weight: 600; font-size: 0.9rem; transition: var(--transition); }
.btn-nav-cta:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 4px 15px var(--accent-glow); }
.navbar-toggler { border-color: var(--border-color); }

/* Buttons */
.btn { padding: 0.75rem 2rem; border-radius: var(--radius-sm); font-weight: 600; transition: var(--transition); border: none; }
.btn-primary-custom { background: var(--accent); color: var(--bg-primary); }
.btn-primary-custom:hover { background: var(--accent-hover); transform: translateY(-2px); box-shadow: 0 8px 25px var(--accent-glow); }
.btn-outline-custom { background: transparent; color: var(--accent); border: 2px solid var(--accent); }
.btn-outline-custom:hover { background: var(--accent); color: var(--bg-primary); transform: translateY(-2px); }
.btn-lg-custom { padding: 1rem 2.5rem; font-size: 1.1rem; }

/* Hero */
.hero-section { min-height: 100vh; display: flex; align-items: center; position: relative; overflow: hidden; background: var(--bg-primary); padding-top: 80px; }
.hero-bg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(ellipse at 20% 50%, rgba(0,255,136,0.05) 0%, transparent 50%), radial-gradient(ellipse at 80% 30%, rgba(0,255,136,0.03) 0%, transparent 50%); z-index: 1; }
.hero-grid { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-image: linear-gradient(rgba(33,38,61,0.3) 1px, transparent 1px), linear-gradient(90deg, rgba(33,38,61,0.3) 1px, transparent 1px); background-size: 60px 60px; z-index: 1; opacity: 0.5; }
.hero-content { position: relative; z-index: 2; }
.hero-badge { display: inline-flex; align-items: center; gap: 0.5rem; background: var(--accent-dim); border: 1px solid rgba(0,255,136,0.2); color: var(--accent); padding: 0.5rem 1rem; border-radius: 100px; font-size: 0.85rem; font-weight: 500; }
.hero-badge .pulse-dot { width: 8px; height: 8px; background: var(--accent); border-radius: 50%; animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.2); } }
.hero-title { font-size: clamp(2.5rem, 5vw, 4.5rem); font-weight: 800; line-height: 1.1; background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-secondary) 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-title span { background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-subtitle { font-size: clamp(1rem, 2vw, 1.25rem); color: var(--text-secondary); max-width: 600px; margin-bottom: 2.5rem; }
.hero-cta-group { display: flex; gap: 1rem; flex-wrap: wrap; }
.hero-stats { display: flex; gap: 2.5rem; margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--border-color); }
.hero-stat-item { text-align: center; }
.hero-stat-value { font-size: 1.75rem; font-weight: 700; color: var(--accent); display: block; }
.hero-stat-label { font-size: 0.85rem; color: var(--text-muted); }

/* Section common */
.section-padding { padding: 6rem 0; }
.section-header { text-align: center; max-width: 700px; margin: 0 auto 3.5rem; }
.section-label { display: inline-block; color: var(--accent); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 2px; margin-bottom: 1rem; }
.section-title { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; margin-bottom: 1rem; color: var(--text-primary); }
.section-desc { color: var(--text-secondary); font-size: 1.1rem; line-height: 1.7; }

/* Highlights */
.highlights-section { background: var(--bg-secondary); border-top: 1px solid var(--border-color); border-bottom: 1px solid var(--border-color); }
.highlight-card { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 2.5rem 2rem; text-align: center; transition: var(--transition); height: 100%; }
.highlight-card:hover { border-color: var(--border-hover); transform: translateY(-5px); box-shadow: 0 20px 40px rgba(0,0,0,0.4); }
.highlight-icon { width: 70px; height: 70px; background: var(--accent-dim); border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; margin: 0 auto 1.5rem; color: var(--accent); font-size: 1.75rem; transition: var(--transition); }
.highlight-card:hover .highlight-icon { background: var(--accent); color: var(--bg-primary); }
.highlight-card h3 { font-size: 1.25rem; font-weight: 600; margin-bottom: 0.75rem; color: var(--text-primary); }
.highlight-card p { color: var(--text-secondary); font-size: 0.95rem; line-height: 1.6; }

/* Platforms */
.platform-card { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 2.5rem; transition: var(--transition); height: 100%; }
.platform-card:hover { border-color: var(--accent); box-shadow: 0 10px 30px rgba(0,255,136,0.08); }
.platform-icon { font-size: 2.5rem; color: var(--accent); margin-bottom: 1.5rem; }
.platform-card h3 { font-size: 1.3rem; margin-bottom: 0.75rem; color: var(--text-primary); }
.platform-card p { color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 1.5rem; }
.platform-features { list-style: none; padding: 0; margin: 0; }
.platform-features li { color: var(--text-muted); font-size: 0.9rem; padding: 0.35rem 0; display: flex; align-items: center; gap: 0.5rem; }
.platform-features li::before { content: ''; width: 6px; height: 6px; background: var(--accent); border-radius: 50%; flex-shrink: 0; }

/* Markets */
.markets-section { background: var(--bg-secondary); }
.market-tab-nav { display: flex; justify-content: center; gap: 0.5rem; margin-bottom: 2.5rem; flex-wrap: wrap; }
.market-tab-btn { padding: 0.75rem 1.5rem; background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-sm); color: var(--text-secondary); font-weight: 500; cursor: pointer; transition: var(--transition); }
.market-tab-btn:hover { border-color: var(--border-hover); color: var(--text-primary); }
.market-tab-btn.active { background: var(--accent); color: var(--bg-primary); border-color: var(--accent); }
.market-card { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 1.5rem; transition: var(--transition); }
.market-card:hover { border-color: var(--accent); transform: translateY(-3px); }
.market-pair { font-size: 1.2rem; font-weight: 600; color: var(--text-primary); margin-bottom: 0.5rem; }
.market-price { font-size: 1.5rem; font-weight: 700; color: var(--accent); }
.market-change { font-size: 0.9rem; }
.market-change.positive { color: var(--accent); }
.market-change.negative { color: var(--danger); }
.market-chart-spark { height: 60px; margin-top: 1rem; opacity: 0.6; }
.market-tab-panel { display: none; }
.market-tab-panel.active { display: block; }

/* Why Terra Flux */
.feature-row { align-items: center; }
.feature-image { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-lg); padding: 2rem; position: relative; overflow: hidden; }
.feature-image::before { content: ''; position: absolute; top: -50%; right: -50%; width: 100%; height: 100%; background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%); opacity: 0.3; }
.feature-content h3 { font-size: 1.75rem; font-weight: 700; margin-bottom: 1rem; color: var(--text-primary); }
.feature-content p { color: var(--text-secondary); line-height: 1.7; margin-bottom: 1.5rem; }
.feature-list { list-style: none; padding: 0; }
.feature-list li { display: flex; align-items: center; gap: 1rem; padding: 0.75rem 0; color: var(--text-secondary); font-size: 0.95rem; }
.feature-list li i { color: var(--accent); font-size: 1.1rem; width: 24px; text-align: center; }

/* Steps */
.steps-section { background: var(--bg-secondary); }
.steps-timeline { position: relative; max-width: 900px; margin: 0 auto; }
.steps-timeline::before { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; background: linear-gradient(to bottom, var(--accent), transparent); transform: translateX(-50%); }
.step-item { display: flex; align-items: center; margin-bottom: 3rem; position: relative; }
.step-item:nth-child(even) { flex-direction: row-reverse; }
.step-item:last-child { margin-bottom: 0; }
.step-number { width: 60px; height: 60px; background: var(--accent); color: var(--bg-primary); font-size: 1.5rem; font-weight: 700; border-radius: 50%; display: flex; align-items: center; justify-content: center; position: relative; z-index: 1; box-shadow: 0 0 20px var(--accent-glow); flex-shrink: 0; }
.step-content { flex: 1; background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 2rem; margin: 0 2rem; }
.step-content h3 { font-size: 1.3rem; font-weight: 600; margin-bottom: 0.5rem; color: var(--text-primary); }
.step-content p { color: var(--text-secondary); margin-bottom: 0; font-size: 0.95rem; }
@media (max-width: 767px) {
  .steps-timeline::before { left: 30px; }
  .step-item { flex-direction: column !important; align-items: flex-start; padding-left: 60px; }
  .step-item .step-number { position: absolute; left: 0; }
  .step-content { margin: 0; margin-top: 1rem; }
}

/* CTA */
.cta-section { background: var(--bg-secondary); position: relative; overflow: hidden; }
.cta-bg-glow { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 600px; height: 600px; background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%); opacity: 0.5; pointer-events: none; }
.cta-content { position: relative; z-index: 1; text-align: center; max-width: 700px; margin: 0 auto; }
.cta-content h2 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; margin-bottom: 1.25rem; color: var(--text-primary); }
.cta-content p { color: var(--text-secondary); font-size: 1.1rem; margin-bottom: 2rem; }

/* Footer */
.footer { background: var(--bg-primary); border-top: 1px solid var(--border-color); padding: 4rem 0 0; }
.footer-brand img { max-height: 40px; margin-bottom: 1rem; }
.footer-brand p { color: var(--text-muted); font-size: 0.9rem; max-width: 300px; }
.footer-heading { color: var(--text-primary); font-size: 1rem; font-weight: 600; margin-bottom: 1.25rem; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 0.75rem; }
.footer-links a { color: var(--text-muted); font-size: 0.9rem; transition: var(--transition); }
.footer-links a:hover { color: var(--accent); padding-left: 5px; }
.footer-social { display: flex; gap: 1rem; }
.footer-social a { width: 40px; height: 40px; background: var(--bg-card); border: 1px solid var(--border-color); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); font-size: 1rem; transition: var(--transition); }
.footer-social a:hover { background: var(--accent); color: var(--bg-primary); border-color: var(--accent); transform: translateY(-3px); }
.footer-bottom { margin-top: 3rem; padding: 1.5rem 0; border-top: 1px solid var(--border-color); text-align: center; }
.footer-bottom p { color: var(--text-muted); font-size: 0.85rem; }
.risk-disclaimer { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-sm); padding: 1rem 1.5rem; margin-top: 2rem; }
.risk-disclaimer p { color: var(--text-muted); font-size: 0.8rem; margin-bottom: 0; line-height: 1.6; }

/* Animations */
.reveal { opacity: 0; transform: translateY(30px); transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1); }
.reveal.active { opacity: 1; transform: translateY(0); }
.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.floating { animation: float 4s ease-in-out infinite; }
@keyframes glow-pulse { 0%,100% { box-shadow: 0 0 10px var(--accent-glow); } 50% { box-shadow: 0 0 20px var(--accent-glow), 0 0 40px rgba(0,255,136,0.2); } }
.glow-pulse { animation: glow-pulse 2s ease-in-out infinite; }

/* Auth Pages */
.auth-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: var(--bg-primary); position: relative; padding: 2rem; }
.auth-page::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(ellipse at 30% 20%, rgba(0,255,136,0.05) 0%, transparent 50%), radial-gradient(ellipse at 70% 80%, rgba(0,255,136,0.03) 0%, transparent 50%); }
.auth-container { position: relative; z-index: 1; width: 100%; max-width: 450px; }
.auth-card { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-lg); padding: 2.5rem; }
.auth-logo { text-align: center; margin-bottom: 2rem; }
.auth-logo img { max-height: 45px; }
.auth-logo h2 { font-size: 1.5rem; font-weight: 700; margin-top: 1rem; color: var(--text-primary); }
.auth-logo p { color: var(--text-muted); font-size: 0.9rem; }
.form-floating > .form-control, .form-floating > .form-select { background: var(--bg-secondary); border: 1px solid var(--border-color); color: var(--text-primary); border-radius: var(--radius-sm); }
.form-floating > .form-control:focus, .form-floating > .form-select:focus { background: var(--bg-secondary); border-color: var(--accent); box-shadow: 0 0 0 0.2rem var(--accent-dim); color: var(--text-primary); }
.form-floating > label { color: var(--text-muted); }
.form-floating > .form-control:focus ~ label, .form-floating > .form-control:not(:placeholder-shown) ~ label, .form-floating > .form-select ~ label { color: var(--accent); background: var(--bg-card); padding: 0 0.5rem; }
.form-check-input { background-color: var(--bg-secondary); border-color: var(--border-color); }
.form-check-input:checked { background-color: var(--accent); border-color: var(--accent); }
.form-check-label { color: var(--text-secondary); font-size: 0.9rem; }
.btn-auth { width: 100%; padding: 0.875rem; background: var(--accent); color: var(--bg-primary); border: none; border-radius: var(--radius-sm); font-weight: 600; font-size: 1rem; transition: var(--transition); }
.btn-auth:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 4px 15px var(--accent-glow); }
.auth-divider { display: flex; align-items: center; gap: 1rem; margin: 1.5rem 0; color: var(--text-muted); font-size: 0.85rem; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border-color); }
.auth-footer { text-align: center; margin-top: 1.5rem; color: var(--text-muted); font-size: 0.9rem; }
.alert-auth { background: rgba(255,68,68,0.1); border: 1px solid rgba(255,68,68,0.2); color: var(--danger); padding: 1rem; border-radius: var(--radius-sm); margin-bottom: 1.5rem; font-size: 0.9rem; }
.alert-auth.success { background: rgba(0,255,136,0.1); border: 1px solid rgba(0,255,136,0.2); color: var(--accent); }

/* Dashboard */
.dashboard-page { background: var(--bg-secondary); min-height: 100vh; padding-top: 100px; }
.dashboard-card { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 1.5rem; transition: var(--transition); }
.dashboard-card:hover { border-color: var(--border-hover); }
.dashboard-stat-value { font-size: 2rem; font-weight: 700; color: var(--accent); }
.dashboard-stat-label { font-size: 0.85rem; color: var(--text-muted); }
.account-badge { display: inline-block; padding: 0.25rem 0.75rem; border-radius: 100px; font-size: 0.75rem; font-weight: 600; text-transform: uppercase; }
.account-badge.demo { background: var(--accent-dim); color: var(--accent); border: 1px solid rgba(0,255,136,0.2); }
.account-badge.live { background: rgba(255,170,0,0.1); color: var(--warning); border: 1px solid rgba(255,170,0,0.2); }

/* Responsive */
@media (max-width: 991px) {
  .hero-stats { gap: 1.5rem; }
  .section-padding { padding: 4rem 0; }
}
@media (max-width: 575px) {
  .hero-stats { flex-wrap: wrap; justify-content: center; }
  .hero-stat-item { min-width: 45%; }
  .hero-cta-group { justify-content: center; }
  .btn { padding: 0.625rem 1.5rem; }
}
