@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400;1,600&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

:root {
  --bg-main: #060b0e;
  --bg-card: #0c1419;
  --bg-surface: #111b22;
  --bg-surface-hover: #16242e;
  --text-white: #FFFFFF;
  --text-gray: #9ba8b2;
  --text-muted: #60707c;
  
  /* Neon Mint / Emerald Accent */
  --accent-neon: #00e599;
  --accent-neon-hover: #0df2a4;
  --accent-neon-glow: rgba(0, 229, 153, 0.35);
  --accent-neon-soft: rgba(0, 229, 153, 0.12);
  
  /* Amber / Gold Accent */
  --accent-yellow: #f59e0b;
  --accent-amber: #fbbf24;
  
  --border-subtle: rgba(255, 255, 255, 0.07);
  --border-card: rgba(255, 255, 255, 0.1);
  --border-neon: rgba(0, 229, 153, 0.3);
  --border-neon-hover: rgba(0, 229, 153, 0.6);
  
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-white);
  color-scheme: dark;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  overflow-x: hidden;
  line-height: 1.6;
  background-color: var(--bg-main);
  background-image: 
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(0, 229, 153, 0.12), transparent),
    linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 100% 100%, 48px 48px, 48px 48px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: #192630;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-neon);
}

/* Floating Animations */
@keyframes floatGentle {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-6px); }
}

@keyframes floatBadge1 {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-5px) rotate(0.5deg); }
}

.animate-float {
  animation: floatGentle 5s ease-in-out infinite;
}

.animate-float-badge-1 {
  animation: floatBadge1 4.5s ease-in-out infinite;
}

/* Modern Glowing Neon Buttons */
.btn-neon-primary {
  background: var(--accent-neon);
  color: #04100c;
  font-weight: 700;
  font-size: 0.9375rem;
  padding: 0.85rem 1.5rem;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 25px rgba(0, 229, 153, 0.35), 0 4px 12px rgba(0, 0, 0, 0.5);
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  min-height: 46px;
}

.btn-neon-primary:hover {
  background: var(--accent-neon-hover);
  transform: translateY(-2px);
  box-shadow: 0 0 35px rgba(0, 229, 153, 0.55), 0 8px 20px rgba(0, 0, 0, 0.6);
}

.btn-neon-primary .btn-arrow {
  transition: transform 0.2s ease;
}

.btn-neon-primary:hover .btn-arrow {
  transform: translateX(4px);
}

.btn-neon-secondary {
  background: #111b22;
  color: #FFFFFF;
  font-weight: 600;
  font-size: 0.9375rem;
  padding: 0.85rem 1.5rem;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  cursor: pointer;
  min-height: 46px;
}

.btn-neon-secondary:hover {
  background: #17242e;
  border-color: rgba(0, 229, 153, 0.4);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* PREMIUM POOL TRADING BUTTON WITH AMBER GLOW & SHIMMER */
.btn-pool-trading {
  position: relative;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12) 0%, #121c23 40%, #0e171e 100%);
  color: #FFFFFF;
  font-weight: 700;
  font-size: 0.9375rem;
  padding: 0.75rem 1.4rem;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  border: 1px solid rgba(245, 158, 11, 0.55);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.2), 0 4px 14px rgba(0, 0, 0, 0.6);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  cursor: pointer;
  min-height: 46px;
  overflow: hidden;
}

/* Shimmer overlay effect */
.btn-pool-trading::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    60deg,
    transparent,
    rgba(255, 255, 255, 0.08),
    rgba(245, 158, 11, 0.15),
    transparent
  );
  transform: rotate(25deg);
  transition: transform 0.75s ease;
  pointer-events: none;
}

.btn-pool-trading:hover::before {
  transform: rotate(25deg) translate(30%, 30%);
}

.btn-pool-trading:hover {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25) 0%, #192731 50%, #131e26 100%);
  border-color: #f59e0b;
  box-shadow: 0 0 32px rgba(245, 158, 11, 0.45), 0 8px 24px rgba(0, 0, 0, 0.7);
  transform: translateY(-2px);
  color: #FFFFFF;
}

.btn-pool-trading .pool-icon-wrap {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.18);
  border: 1px solid rgba(245, 158, 11, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #f59e0b;
  transition: transform 0.25s ease, background-color 0.25s ease;
}

.btn-pool-trading:hover .pool-icon-wrap {
  transform: scale(1.08);
  background: rgba(245, 158, 11, 0.3);
}

.btn-pool-trading .pool-tag {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.35);
  font-size: 0.65rem;
  font-family: var(--font-mono);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.15rem 0.5rem;
  border-radius: 9999px;
  transition: all 0.2s ease;
}

.btn-pool-trading:hover .pool-tag {
  background: #f59e0b;
  color: #04100c;
  border-color: #f59e0b;
}

.btn-pool-trading .pool-arrow {
  transition: transform 0.25s ease;
  color: #f59e0b;
  font-size: 1rem;
}

.btn-pool-trading:hover .pool-arrow {
  transform: translate(3px, -3px);
  color: #FFFFFF;
}

/* Service & Feature Cards */
.modern-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 22px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.modern-card:hover {
  transform: translateY(-4px);
  background: #0f1a21;
  border-color: var(--border-neon);
  box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.7), 0 0 25px rgba(0, 229, 153, 0.08);
}

.modern-card.popular-card {
  background: linear-gradient(180deg, #101c24 0%, #0c1419 100%);
  border: 1px solid rgba(0, 229, 153, 0.4);
  box-shadow: 0 0 35px rgba(0, 229, 153, 0.1);
  overflow: visible !important;
}

.modern-card.popular-card:hover {
  border-color: rgba(0, 229, 153, 0.8);
  box-shadow: 0 20px 45px -10px rgba(0, 0, 0, 0.8), 0 0 45px rgba(0, 229, 153, 0.25);
}

/* Editorial Card Image Headers */
.card-img-header {
  position: relative;
  height: 140px;
  overflow: hidden;
  border-top-left-radius: 21px;
  border-top-right-radius: 21px;
}

.card-img-header img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  filter: brightness(0.65) contrast(1.15);
}

.modern-card:hover .card-img-header img {
  transform: scale(1.06);
}

.card-img-gradient-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(12, 20, 25, 0.1) 0%, rgba(12, 20, 25, 0.95) 90%, #0c1419 100%);
}

/* Floating UI Badges */
.floating-badge {
  background: rgba(14, 23, 29, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.8), 0 0 20px rgba(0, 229, 153, 0.1);
}

/* MT5 Terminal UI Styles */
.mt5-terminal-container {
  background: #081015;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.9), 0 0 30px rgba(0, 229, 153, 0.06);
  font-family: var(--font-mono);
}

.mt5-tab-btn {
  transition: all 0.2s ease;
}

.mt5-tab-btn.active {
  background-color: #111b22;
  color: #FFFFFF;
  border-color: rgba(0, 229, 153, 0.5);
}

.mt5-trade-row {
  transition: background-color 0.15s ease;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.mt5-trade-row:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

/* Multi-step Application Form Styles */
.app-step-indicator {
  position: relative;
  transition: all 0.25s ease;
}

.app-step-indicator.active {
  color: #FFFFFF;
  border-color: var(--accent-neon);
}

.app-step-indicator.active .step-num {
  background-color: var(--accent-neon);
  color: #04100c;
  font-weight: 800;
  box-shadow: 0 0 15px rgba(0, 229, 153, 0.4);
}

.app-step-indicator.completed .step-num {
  background-color: #05cd81;
  color: #04100c;
}

.app-step-pane {
  display: none;
  animation: fadeInStep 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.app-step-pane.active {
  display: block;
}

@keyframes fadeInStep {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.form-input-field {
  width: 100%;
  padding: 0.8rem 1rem;
  border-radius: 12px;
  background-color: #0f181f;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #FFFFFF;
  font-size: 1rem; /* 16px to prevent iOS auto-zoom */
  transition: all 0.2s ease;
  min-height: 44px;
}

@media (min-width: 640px) {
  .form-input-field {
    font-size: 0.875rem;
  }
}

.form-input-field:focus {
  outline: none;
  border-color: var(--accent-neon);
  background-color: #131e26;
  box-shadow: 0 0 0 3px rgba(0, 229, 153, 0.15);
}

.form-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0.875rem;
  border-radius: 12px;
  background-color: #0f181f;
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #FFFFFF;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 44px;
}

.form-checkbox-label:hover {
  background-color: #142028;
  border-color: rgba(0, 229, 153, 0.35);
}

.form-checkbox-label input[type="checkbox"]:checked ~ span,
.form-checkbox-label input[type="radio"]:checked ~ span {
  color: var(--accent-neon);
  font-weight: 600;
}

.form-checkbox-label:has(input:checked) {
  border-color: rgba(0, 229, 153, 0.5);
  background-color: rgba(0, 229, 153, 0.08);
}

/* Problem Items Interactive Reveal */
.problem-card-item {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 18px;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
}

.problem-card-item:hover {
  background: var(--bg-surface);
  border-color: rgba(0, 229, 153, 0.4);
  transform: translateY(-3px);
}

.problem-hidden-desc {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.35s ease, opacity 0.25s ease, margin-top 0.25s ease;
}

.problem-card-item:hover .problem-hidden-desc,
.problem-card-item.active .problem-hidden-desc {
  max-height: 120px;
  opacity: 1;
  margin-top: 0.75rem;
}

/* FAQ Minimal Accordion */
.faq-item-row {
  border-bottom: 1px solid var(--border-subtle);
  transition: all 0.2s ease;
}

.faq-item-row:hover {
  border-color: rgba(0, 229, 153, 0.3);
}

.faq-body-content {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
}

.faq-item-row.active .faq-body-content {
  opacity: 1;
}

.faq-item-row.active .faq-chevron {
  transform: rotate(180deg);
  color: var(--accent-neon);
}

/* Founder Portrait Stylized Frame */
.founder-portrait-container {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.8), 0 0 30px rgba(0, 229, 153, 0.08);
}

.founder-portrait-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: contrast(1.1) brightness(0.9);
}

.founder-portrait-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(6, 11, 14, 0.95) 0%, rgba(6, 11, 14, 0.3) 50%, transparent 100%);
}

/* Mobile & Universal Device Responsiveness Enhancements */
:root {
  --sat: env(safe-area-inset-top, 0px);
  --sar: env(safe-area-inset-right, 0px);
  --sab: env(safe-area-inset-bottom, 0px);
  --sal: env(safe-area-inset-left, 0px);
}

/* Base Body Safe-Area & Touch Behavior */
body {
  padding-top: var(--sat);
  padding-left: var(--sal);
  padding-right: var(--sar);
  -webkit-overflow-scrolling: touch;
  touch-action: manipulation;
}

/* Safe interactive tap targets (Apple Human Interface & Material Design Guidelines) */
button, 
a, 
input, 
select, 
textarea, 
.form-checkbox-label {
  min-height: 44px;
  touch-action: manipulation;
}

/* Ensure no text zoom on mobile Safari / Chrome for inputs */
input, 
select, 
textarea {
  font-size: 16px !important;
}

@media (min-width: 640px) {
  input, 
  select, 
  textarea {
    font-size: 0.875rem !important;
  }
}

/* Glassmorphism fallbacks for older devices */
@supports not ((-webkit-backdrop-filter: blur(10px)) or (backdrop-filter: blur(10px))) {
  .floating-badge,
  #main-nav,
  #mobile-drawer {
    background-color: rgba(6, 11, 14, 0.98) !important;
  }
}

/* Small Screen Phones (e.g., iPhone SE, Galaxy Fold, screen widths <= 380px) */
@media (max-width: 380px) {
  .modern-card {
    padding: 1rem !important;
    border-radius: 16px !important;
  }
  
  .btn-neon-primary,
  .btn-neon-secondary,
  .btn-pool-trading {
    padding: 0.75rem 1rem !important;
    font-size: 0.8125rem !important;
    width: 100% !important;
  }

  h1 {
    font-size: 1.875rem !important;
    line-height: 2.25rem !important;
  }

  h2 {
    font-size: 1.5rem !important;
    line-height: 2rem !important;
  }

  .app-step-indicator span.hidden {
    display: none !important;
  }
}

/* Standard Mobile Devices (max-width: 640px) */
@media (max-width: 640px) {
  .modern-card {
    border-radius: 18px;
  }
  
  .card-img-header {
    height: 120px;
  }

  .floating-badge {
    padding: 0.6rem 0.85rem;
  }

  /* Problem cards show description clearly on mobile */
  .problem-hidden-desc {
    max-height: 100px;
    opacity: 0.95;
    margin-top: 0.5rem;
  }

  /* Table / Terminal scrollable touch indicator */
  .mt5-terminal-container,
  .overflow-x-auto {
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }
}

/* Tablets & Foldables (min-width: 641px and max-width: 1024px) */
@media (min-width: 641px) and (max-width: 1024px) {
  .modern-card {
    padding: 1.5rem;
  }
}

/* Landscape Mobile Orientation Fixes */
@media (orientation: landscape) and (max-height: 500px) {
  #mobile-drawer {
    padding-top: 1rem;
    padding-bottom: 1rem;
    overflow-y: auto;
  }
  
  .card-img-header {
    height: 100px;
  }
}

/* High-DPI / Retina Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .modern-card img {
    image-rendering: -webkit-optimize-contrast;
  }
}

/* Accessibility: Reduced Motion Preference */
@media (prefers-reduced-motion: reduce) {
  *,
  ::before,
  ::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

