/* ============================================
   MT5 Portal DE — Liquid Velocity Design System
   ============================================ */

:root {
  --bg:                  #111318;
  --bg-low:               #0c0e12;
  --surface:              #1e2024;
  --surface-high:         #282a2e;
  --surface-highest:      #333539;
  --glass:                rgba(255,255,255,0.03);
  --glass-hover:           rgba(255,255,255,0.08);
  --border-glass:         rgba(255,255,255,0.10);
  --on-surface:           #e2e2e8;
  --on-surface-dim:       #c2c6d4;
  --outline:              #8c919d;
  --primary:              #a9c7ff;
  --primary-container:    #5591e9;
  --secondary:            #e6feff;
  --secondary-container:  #00f4fe;
  --neon-orange:          #FF8A00;
  --risk-bg:              #1A0B0B;
  --risk-border:          #ff4b89;
  --success:              #28A745;

  --font-head: 'Montserrat', sans-serif;
  --font-body: 'Inter', sans-serif;

  --max-width: 1280px;
  --unit: 4px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--on-surface);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

ul { list-style: none; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 64px;
}

@media (max-width: 1279px) {
  .container { padding: 0 24px; }
}
@media (max-width: 767px) {
  .container { padding: 0 16px; }
}

/* ---------- Typography ---------- */
h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--on-surface);
}

h1 {
  font-size: 48px;
  line-height: 56px;
  letter-spacing: -0.02em;
  font-weight: 700;
}

h2 {
  font-size: 32px;
  line-height: 40px;
  font-weight: 600;
}

h3 {
  font-size: 24px;
  line-height: 32px;
  font-weight: 600;
}

.body-lg { font-size: 18px; line-height: 28px; }
.body-md { font-size: 16px; line-height: 24px; }

.data-text {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 20px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.label-sm {
  font-family: var(--font-body);
  font-size: 12px;
  line-height: 16px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--outline);
}

@media (max-width: 767px) {
  h1 { font-size: 32px; line-height: 38px; }
  h2 { font-size: 26px; line-height: 32px; }
  h3 { font-size: 20px; line-height: 28px; }
}

.section-label {
  color: var(--secondary-container);
  margin-bottom: 12px;
  display: block;
}

.section-sub {
  color: var(--on-surface-dim);
  max-width: 640px;
  margin-top: 12px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  padding: 12px 28px;
  border-radius: 24px;
  cursor: pointer;
  border: none;
  transition: box-shadow .25s ease, transform .15s ease;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(90deg, var(--primary-container), var(--secondary-container));
  color: #06131f;
}

.btn-primary:hover {
  box-shadow: 0 0 22px 2px rgba(0, 244, 254, 0.45);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  border: 1.5px solid var(--secondary-container);
  color: var(--secondary);
}

.btn-secondary:hover {
  box-shadow: 0 0 15px -3px var(--secondary-container);
  background: rgba(0, 244, 254, 0.06);
}

.btn svg { width: 18px; height: 18px; }

.btn-lg {
  padding: 16px 40px;
  font-size: 17px;
}

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

/* ---------- Glass cards ---------- */
.glass-card {
  background: var(--glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  transition: background .25s ease, box-shadow .25s ease;
}

.glass-card:hover {
  background: var(--glass-hover);
  box-shadow: 0 0 15px -5px var(--secondary-container);
}

/* ---------- Risk / compliance box ---------- */
.risk-box {
  background: var(--risk-bg);
  border-left: 2px solid var(--risk-border);
  padding: 16px;
  font-size: 16px;
  line-height: 24px;
  color: var(--on-surface-dim);
  display: flex;
  gap: 12px;
  border-radius: 0 8px 8px 0;
}

.risk-box svg {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: var(--risk-border);
  margin-top: 2px;
}

/* ---------- OS Chips ---------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(169, 199, 255, 0.14);
  color: var(--primary);
  border-radius: 999px;
  padding: 6px 14px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.chip svg { width: 14px; height: 14px; }

/* ---------- Inputs ---------- */
.input-field, select.input-field {
  background: transparent;
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  color: var(--on-surface);
  padding: 12px 16px;
  font-family: var(--font-body);
  font-size: 16px;
  width: 100%;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.input-field:focus {
  outline: none;
  border-color: var(--secondary-container);
  box-shadow: 0 0 10px -2px var(--secondary-container);
}

select.input-field {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%238c919d' stroke-width='2'><polyline points='6 9 12 15 18 9'/></svg>");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
  cursor: pointer;
}

/* ---------- Tables ---------- */
.data-table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid var(--border-glass);
}

.data-table th {
  background: rgba(255,255,255,0.15);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 13px;
  text-align: left;
  padding: 14px 16px;
  color: var(--on-surface);
}

.data-table td {
  padding: 14px 16px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
  border-top: 1px solid var(--border-glass);
  color: var(--on-surface-dim);
}

.data-table tr:nth-child(even) td {
  background: rgba(255,255,255,0.05);
}

.data-table td:first-child, .data-table th:first-child {
  color: var(--on-surface);
  font-weight: 600;
}

@media (max-width: 767px) {
  .data-table { display: block; overflow-x: auto; white-space: nowrap; }
}

/* ============================================
   HEADER
   ============================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg-low);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-glass);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 18px;
  color: var(--on-surface);
}

.brand svg { color: var(--primary); width: 26px; height: 26px; }

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

.main-nav a {
  font-size: 15px;
  font-weight: 500;
  color: var(--on-surface-dim);
  transition: color .2s ease;
}

.main-nav a:hover { color: var(--secondary-container); }

.header-cta { display: flex; align-items: center; gap: 20px; }

.hamburger {
  display: none;
  background: none;
  border: none;
  color: var(--on-surface);
  cursor: pointer;
}

.hamburger svg { width: 26px; height: 26px; }

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 16px 0 24px;
  border-top: 1px solid var(--border-glass);
}

.mobile-menu a {
  padding: 12px 0;
  font-size: 16px;
  color: var(--on-surface-dim);
  border-bottom: 1px solid var(--border-glass);
}

.mobile-menu.open { display: flex; }

@media (max-width: 900px) {
  .main-nav { display: none; }
  .hamburger { display: block; }
}

/* ============================================
   HERO
   ============================================ */
.hero {
  padding: 80px 0 64px;
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 60% 40%;
  gap: 48px;
  align-items: center;
}

.hero-sub {
  color: var(--on-surface-dim);
  margin: 20px 0 32px;
  max-width: 560px;
}

.hero-ctas {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.live-rate-box {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
  background: var(--glass);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 24px;
  backdrop-filter: blur(20px);
}

.rate-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
}

.rate-item svg { width: 18px; height: 18px; color: var(--secondary-container); }

.rate-value {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 18px;
}

.rate-delta {
  font-size: 14px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.rate-delta.up { color: var(--success); }
.rate-delta.down { color: var(--risk-border); }

.rate-timestamp {
  color: var(--outline);
  font-size: 13px;
}

.hero-visual {
  position: relative;
  aspect-ratio: 1/1;
  max-width: 460px;
  margin: 0 auto;
}

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { max-width: 320px; order: -1; margin-bottom: 24px; }
}

/* ============================================
   SECTION GENERIC
   ============================================ */
.section {
  padding: 80px 0;
}

.section-alt {
  background: var(--bg-low);
}

.section-head {
  margin-bottom: 48px;
  max-width: 760px;
}

.section-head.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

@media (max-width: 767px) {
  .section { padding: 56px 0; }
  .section-head { margin-bottom: 32px; }
}

/* ============================================
   BLOCK 2 — Platform cards
   ============================================ */
.platform-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.platform-card {
  padding: 28px 24px;
  position: relative;
}

.platform-card .chip {
  position: absolute;
  top: 20px;
  right: 20px;
}

.platform-card svg.platform-icon {
  width: 32px;
  height: 32px;
  color: var(--primary);
  margin-bottom: 20px;
}

.platform-card h3 { margin-bottom: 4px; font-size: 20px; }

.platform-card .platform-meta {
  color: var(--outline);
  font-size: 14px;
  margin-bottom: 24px;
}

@media (max-width: 1000px) {
  .platform-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .platform-grid { grid-template-columns: 1fr; }
}

/* ============================================
   BLOCK 3 — MT4 vs MT5 infographic
   ============================================ */
.compare-infographic {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-glass);
  margin-bottom: 40px;
}

.compare-col {
  padding: 40px 32px;
  text-align: center;
}

.compare-col.mt4 { background: var(--surface); }

.compare-col.mt5 {
  background: rgba(169, 199, 255, 0.06);
  border-left: 1px solid var(--primary);
}

.compare-col svg.compare-icon {
  width: 40px;
  height: 40px;
  color: var(--primary);
  margin: 0 auto 16px;
}

.compare-col h3 { margin-bottom: 24px; }

.compare-stat {
  margin-bottom: 20px;
}

.compare-stat .counter {
  font-family: var(--font-head);
  font-size: 36px;
  font-weight: 700;
  color: var(--secondary-container);
  display: block;
}

.compare-stat .counter-label {
  font-size: 14px;
  color: var(--on-surface-dim);
}

.compare-tag {
  display: inline-block;
  margin-top: 8px;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--outline);
  font-weight: 600;
}

@media (max-width: 700px) {
  .compare-infographic { grid-template-columns: 1fr; }
  .compare-col.mt5 { border-left: none; border-top: 1px solid var(--primary); }
}

.compare-text {
  color: var(--on-surface-dim);
  max-width: 720px;
  margin-top: 24px;
}

/* ============================================
   BLOCK 4 — Requirements + steps
   ============================================ */
.reqs-grid {
  display: grid;
  grid-template-columns: 40% 60%;
  gap: 48px;
  align-items: start;
}

.reqs-table-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  font-weight: 600;
}

.reqs-table-head svg { width: 20px; height: 20px; color: var(--primary); }

.steps-list {
  position: relative;
  padding-left: 8px;
}

.step-item {
  display: flex;
  gap: 20px;
  position: relative;
  padding-bottom: 40px;
}

.step-item:last-child { padding-bottom: 0; }

.step-number {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-container), var(--secondary-container));
  color: #06131f;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 16px;
  position: relative;
  z-index: 2;
}

.step-item:not(:last-child)::before {
  content: '';
  position: absolute;
  left: 19px;
  top: 40px;
  width: 2px;
  height: calc(100% - 20px);
  background: var(--primary);
  opacity: 0.3;
}

.step-content h4 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 17px;
  margin-bottom: 6px;
  color: var(--on-surface);
}

.step-content .step-detail {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--on-surface-dim);
  font-size: 15px;
}

.step-content .step-detail svg {
  width: 16px;
  height: 16px;
  color: var(--primary);
  flex-shrink: 0;
}

@media (max-width: 900px) {
  .reqs-grid { grid-template-columns: 1fr; }
}

/* ============================================
   BLOCK 5 — WebTrader + Account split
   ============================================ */
.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.split-card {
  padding: 32px;
}

.split-card > svg {
  width: 40px;
  height: 40px;
  margin-bottom: 20px;
}

.split-card.card-a > svg { color: var(--secondary-container); }
.split-card.card-b > svg { color: var(--primary); }

.split-card h3 { margin-bottom: 14px; }

.split-card p { color: var(--on-surface-dim); margin-bottom: 20px; }

.check-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }

.check-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  color: var(--on-surface-dim);
}

.check-list li svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 2px; }

.check-list li.pos svg { color: var(--success); }
.check-list li.neg svg { color: var(--risk-border); }

.mini-schema {
  margin: 20px 0;
  padding: 20px;
  background: var(--bg-low);
  border-radius: 8px;
  border: 1px solid var(--border-glass);
}

.mini-schema svg { width: 100%; height: auto; }

@media (max-width: 900px) {
  .split-grid { grid-template-columns: 1fr; }
}

/* ============================================
   BLOCK 6 — Currency Converter
   ============================================ */
.converter-card {
  max-width: 560px;
  margin: 0 auto;
  padding: 36px;
}

.converter-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  font-weight: 600;
  font-size: 15px;
}

.converter-head svg { width: 20px; height: 20px; color: var(--secondary-container); }
.converter-head svg.spinning { animation: spin 1.2s linear infinite; }

.converter-row {
  display: grid;
  grid-template-columns: 1fr 110px;
  gap: 12px;
  margin-bottom: 16px;
}

.converter-swap {
  display: flex;
  justify-content: center;
  margin: 8px 0 20px;
}

.swap-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-container), var(--secondary-container));
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #06131f;
  transition: transform .3s ease;
}

.swap-btn:hover { transform: rotate(180deg); }
.swap-btn svg { width: 20px; height: 20px; }

.converter-meta {
  color: var(--on-surface-dim);
  font-size: 14px;
  margin: 20px 0;
  line-height: 1.6;
}

.converter-meta .rate-line { color: var(--on-surface); font-weight: 600; }

.converter-status {
  font-size: 13px;
  color: var(--neon-orange);
  margin-top: 8px;
  display: none;
}

.converter-status.show { display: block; }

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* ============================================
   BLOCK 7 — FAQ Accordion
   ============================================ */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 800px;
}

.faq-item {
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  background: var(--glass);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: none;
  border: none;
  color: var(--on-surface);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  text-align: left;
  cursor: pointer;
}

.faq-question svg {
  width: 20px;
  height: 20px;
  color: var(--primary);
  flex-shrink: 0;
  transition: transform .25s ease;
}

.faq-item.open .faq-question svg { transform: rotate(180deg); }

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}

.faq-answer-inner {
  padding: 0 24px 20px;
  color: var(--on-surface-dim);
  font-size: 15px;
  line-height: 1.6;
}

/* ============================================
   BLOCK 8 — Final CTA banner
   ============================================ */
.final-cta {
  background: radial-gradient(circle at 30% 30%, #003062 0%, var(--bg) 55%, #002021 100%);
  padding: 96px 0;
  text-align: center;
}

.final-cta h2 { margin-bottom: 16px; }

.final-cta .section-sub {
  margin: 0 auto 36px;
  max-width: 560px;
  text-align: center;
}

.final-cta-btn {
  margin-bottom: 28px;
}

.final-cta-btn .btn-primary {
  animation: pulse-glow 2.4s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 15px 0 rgba(0, 244, 254, 0.35); }
  50% { box-shadow: 0 0 30px 6px rgba(0, 244, 254, 0.55); }
}

.platform-chips {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.final-cta .risk-box {
  max-width: 720px;
  margin: 0 auto;
  text-align: left;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: var(--bg-low);
  border-top: 1px solid var(--border-glass);
  padding: 40px 0 32px;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-glass);
  margin-bottom: 20px;
}

.footer-brand {
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--on-surface);
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: var(--on-surface-dim);
  font-size: 14px;
}

.footer-links a:hover { color: var(--secondary-container); }

.footer-copy {
  color: var(--outline);
  font-size: 13px;
  margin-bottom: 12px;
}

.footer-risk {
  color: var(--outline);
  font-size: 13px;
  max-width: 900px;
  line-height: 1.6;
}

@media (max-width: 600px) {
  .footer-top { flex-direction: column; align-items: flex-start; }
}

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