/* ==============================================================================
   GENOFIN.TECH — INSTITUTIONAL QUANTITATIVE PORTAL DESIGN SYSTEM
   Theme: Obsidian Glassmorphism, Titanium White, Electric Cyan & Emerald
   ============================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600;700&family=Outfit:wght@400;500;600;700;800;900&display=swap');

:root {
  /* Color Palette */
  --bg-black: #030712;
  --bg-deep: #070c18;
  --bg-card: rgba(13, 19, 33, 0.72);
  --bg-card-hover: rgba(20, 29, 48, 0.85);
  --bg-surface: rgba(255, 255, 255, 0.03);
  
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-card: rgba(255, 255, 255, 0.12);
  --border-glow: rgba(0, 240, 255, 0.35);
  --border-green: rgba(16, 185, 129, 0.4);

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-highlight: #ffffff;

  /* Quant Accent Colors */
  --cyan-accent: #00f0ff;
  --cyan-glow: rgba(0, 240, 255, 0.25);
  --green-quant: #10b981;
  --green-glow: rgba(16, 185, 129, 0.25);
  --amber-accent: #f59e0b;
  --purple-accent: #8b5cf6;
  --red-loss: #ef4444;

  /* Typography */
  --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Dimensions & Spacing */
  --max-width: 1240px;
  --header-height: 80px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  /* Transitions */
  --trans-fast: 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  --trans-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base Reset & Smooth Scroll */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-black);
  color: var(--text-primary);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  background: radial-gradient(circle at 50% 0%, #0e172a 0%, #030712 55%, #02040a 100%);
  line-height: 1.6;
}

/* Background Atmosphere & Grid overlay */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    radial-gradient(ellipse 60% 40% at 50% -10%, rgba(0, 240, 255, 0.12), transparent 70%);
  background-size: 32px 32px, 100% 100%;
  pointer-events: none;
  z-index: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

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

button, input {
  font-family: inherit;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
  position: relative;
  z-index: 1;
}

/* ==============================================================================
   TYPOGRAPHY & UTILITIES
   ============================================================================== */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-highlight);
  line-height: 1.2;
}

.mono {
  font-family: var(--font-mono);
}

.gradient-text {
  background: linear-gradient(135deg, #ffffff 20%, #94a3b8 60%, var(--cyan-accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.cyan-text {
  color: var(--cyan-accent);
}

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

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  backdrop-filter: blur(12px);
}

.badge-glow {
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.3);
  color: var(--cyan-accent);
  box-shadow: 0 0 16px rgba(0, 240, 255, 0.15);
}

.badge-live {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: var(--green-quant);
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--green-quant);
  box-shadow: 0 0 8px var(--green-quant);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1.15); box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 26px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--trans-normal);
  border: 1px solid transparent;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, #00f0ff 0%, #0099ff 100%);
  color: #030712;
  font-weight: 700;
  box-shadow: 0 4px 20px rgba(0, 240, 255, 0.35);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 240, 255, 0.55);
}

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

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
}

.btn-binance {
  background: #f0b90b;
  color: #181a20;
  font-weight: 700;
  box-shadow: 0 4px 18px rgba(240, 185, 11, 0.3);
}

.btn-binance:hover {
  background: #fcd535;
  transform: translateY(-2px);
  box-shadow: 0 8px 26px rgba(240, 185, 11, 0.45);
}

/* Glassmorphism Cards */
.glass-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 32px;
  transition: all var(--trans-normal);
  position: relative;
  overflow: hidden;
}

.glass-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-glow);
  transform: translateY(-4px);
  box-shadow: 0 16px 36px -10px rgba(0, 240, 255, 0.15);
}

/* ==============================================================================
   HEADER & NAVBAR
   ============================================================================== */
.site-header {
  position: sticky;
  top: 0;
  width: 100%;
  height: var(--header-height);
  background: rgba(3, 7, 18, 0.82);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  z-index: 100;
  display: flex;
  align-items: center;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo-img {
  height: 38px;
  width: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--trans-fast);
}

.nav-links a:hover {
  color: var(--cyan-accent);
}

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

.mobile-toggle {
  display: none;
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
}

/* ==============================================================================
   HERO SECTION
   ============================================================================== */
.hero-section {
  padding-top: 70px;
  padding-bottom: 60px;
  text-align: center;
}

.hero-content {
  max-width: 940px;
  margin: 0 auto;
}

.hero-pill-wrap {
  margin-bottom: 24px;
}

.hero-title {
  font-size: clamp(2.4rem, 5.5vw, 4.4rem);
  font-weight: 900;
  letter-spacing: -0.035em;
  margin-bottom: 24px;
  line-height: 1.1;
}

.hero-desc {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 760px;
  margin: 0 auto 36px;
}

.hero-cta-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.hero-trust-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 36px;
  padding-top: 36px;
  border-top: 1px solid var(--border-subtle);
}

.trust-item h4 {
  font-family: var(--font-mono);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-highlight);
  margin-bottom: 4px;
}

.trust-item p {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

/* ==============================================================================
   LIVE TELEMETRY RIBBON
   ============================================================================== */
.telemetry-bar {
  margin-top: 24px;
  background: rgba(11, 16, 28, 0.85);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.telemetry-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
  font-family: var(--font-mono);
  color: var(--text-secondary);
}

.ticker-grid {
  display: flex;
  align-items: center;
  gap: 28px;
  flex-wrap: wrap;
}

.ticker-item {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.95rem;
}

.ticker-symbol {
  font-weight: 700;
  color: var(--text-secondary);
}

.ticker-price {
  font-weight: 700;
  color: var(--text-highlight);
}

.ticker-change {
  font-size: 0.85rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
}

.ticker-change.pos {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
}

.ticker-change.neg {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
}

/* ==============================================================================
   SECTION HEADERS
   ============================================================================== */
.section {
  padding: 90px 0;
  position: relative;
}

.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 56px;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--cyan-accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  margin-bottom: 16px;
}

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

/* ==============================================================================
   NON-CUSTODIAL PILLARS
   ============================================================================== */
.pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.pillar-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: rgba(0, 240, 255, 0.1);
  border: 1px solid rgba(0, 240, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 20px;
}

.pillar-card h3 {
  font-size: 1.35rem;
  margin-bottom: 12px;
}

.pillar-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ==============================================================================
   STRATEGIES MATRIX
   ============================================================================== */
.strategies-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.strategy-badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--cyan-accent);
  margin-bottom: 12px;
  display: block;
}

.strategy-card h3 {
  font-size: 1.25rem;
  margin-bottom: 10px;
}

.strategy-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
  margin-bottom: 16px;
}

.strategy-meta {
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ==============================================================================
   INTERACTIVE COMPOUNDING SIMULATOR
   ============================================================================== */
.simulator-box {
  background: linear-gradient(145deg, rgba(13, 20, 36, 0.9) 0%, rgba(7, 12, 24, 0.95) 100%);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  padding: 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.sim-controls h3 {
  font-size: 1.5rem;
  margin-bottom: 24px;
}

.control-group {
  margin-bottom: 24px;
}

.control-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  font-size: 0.95rem;
  font-weight: 500;
}

.control-val {
  font-family: var(--font-mono);
  color: var(--cyan-accent);
  font-weight: 700;
  font-size: 1.1rem;
}

.range-slider {
  width: 100%;
  -webkit-appearance: none;
  height: 6px;
  border-radius: 4px;
  background: #1e293b;
  outline: none;
  transition: background var(--trans-fast);
}

.range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--cyan-accent);
  cursor: pointer;
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.6);
  border: 2px solid #ffffff;
}

.radio-pill-group {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}

.radio-pill {
  flex: 1;
  text-align: center;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--trans-fast);
}

.radio-pill.active {
  background: rgba(0, 240, 255, 0.15);
  border-color: var(--cyan-accent);
  color: var(--cyan-accent);
  font-weight: 600;
}

.sim-results {
  background: rgba(3, 7, 18, 0.6);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.result-card-main {
  text-align: center;
  margin-bottom: 24px;
}

.result-caption {
  font-size: 0.85rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-family: var(--font-mono);
  margin-bottom: 8px;
}

.result-number {
  font-family: var(--font-mono);
  font-size: clamp(2.2rem, 3.5vw, 3rem);
  font-weight: 800;
  color: var(--green-quant);
  text-shadow: 0 0 20px rgba(16, 185, 129, 0.3);
}

.result-diff {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-top: 6px;
}

.result-breakdown {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding-top: 18px;
  border-top: 1px solid var(--border-subtle);
}

.breakdown-item p:first-child {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.breakdown-item p:last-child {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text-highlight);
}

/* ==============================================================================
   3-STEP ONBOARDING
   ============================================================================== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  position: relative;
}

.step-card {
  position: relative;
  padding-top: 48px;
}

.step-num {
  position: absolute;
  top: -20px;
  left: 32px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-deep);
  border: 2px solid var(--cyan-accent);
  color: var(--cyan-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.2rem;
  box-shadow: 0 0 16px rgba(0, 240, 255, 0.4);
}

.step-card h3 {
  font-size: 1.3rem;
  margin-bottom: 12px;
}

.step-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ==============================================================================
   FAQ ACCORDION
   ============================================================================== */
.faq-wrap {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.faq-item {
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  background: var(--bg-card);
  overflow: hidden;
  transition: all var(--trans-fast);
}

.faq-question {
  width: 100%;
  padding: 22px 28px;
  text-align: left;
  background: transparent;
  border: none;
  color: var(--text-highlight);
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.faq-icon {
  font-size: 1.2rem;
  color: var(--cyan-accent);
  transition: transform var(--trans-normal);
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
  padding: 0 28px;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
}

.faq-item.active .faq-answer {
  max-height: 280px;
  padding-bottom: 22px;
}

/* ==============================================================================
   CTA BANNER
   ============================================================================== */
.cta-banner {
  margin: 40px auto;
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.1) 0%, rgba(16, 185, 129, 0.08) 100%);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-lg);
  padding: 60px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-banner h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 16px;
}

.cta-banner p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  max-width: 640px;
  margin: 0 auto 32px;
}

/* ==============================================================================
   FOOTER
   ============================================================================== */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  background: #020408;
  padding: 70px 0 40px;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

.footer-brand p {
  margin-top: 14px;
  color: var(--text-muted);
  max-width: 320px;
  line-height: 1.6;
}

.footer-col h4 {
  color: var(--text-highlight);
  font-size: 0.95rem;
  margin-bottom: 18px;
}

.footer-col ul li {
  margin-bottom: 10px;
}

.footer-col a:hover {
  color: var(--cyan-accent);
}

.footer-bottom {
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.7;
}

.footer-bottom strong {
  color: var(--text-secondary);
}

/* ==============================================================================
   RESPONSIVE DESIGN (TABLET & MOBILE)
   ============================================================================== */
@media (max-width: 1024px) {
  .hero-trust-metrics {
    grid-template-columns: repeat(2, 1fr);
  }
  .pillars-grid, .strategies-grid, .steps-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .simulator-box {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .footer-top {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: #070c18;
    border-bottom: 1px solid var(--border-card);
    padding: 24px;
    gap: 20px;
  }
  .mobile-toggle {
    display: block;
  }
  .pillars-grid, .strategies-grid, .steps-grid {
    grid-template-columns: 1fr;
  }
  .hero-trust-metrics {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  .telemetry-bar {
    flex-direction: column;
    align-items: flex-start;
  }
  .ticker-grid {
    width: 100%;
    justify-content: space-between;
  }
  .footer-top {
    grid-template-columns: 1fr;
  }
}
