/* ─────────────────────────────────────────────────────────────
   TradeAutonom Landingpage.
   Farben, Schrift, Radien und Easing kommen aus dem Design-System der App
   (frontend_ng/src/styles/ds, Theme web3universe). Die Seite ist dunkel
   wie die App; es gibt keinen hellen Modus.
   ───────────────────────────────────────────────────────────── */

:root {
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Space Grotesk", var(--font-body);
  --font-mono: ui-monospace, "JetBrains Mono", "SF Mono", Menlo, monospace;

  --bg: #121412;
  --bg-2: #1b1e1b;
  --card: rgba(255, 255, 255, 0.02);
  --card-hi: rgba(255, 255, 255, 0.04);
  --fg1: #e8e6df;
  --fg2: #a3a89e;
  --fg3: #7a7f77;
  --fg-on-brand: #121412;
  --line: #2a2e29;
  --line-2: #3a3f39;
  --brand: #7fc39a;
  --brand-bg: rgba(127, 195, 154, 0.15);
  --up: #64d17d;
  --down: #ff849c;

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 22px;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-app: cubic-bezier(0.12, 0.04, 0.20, 1.06);

  --max: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --nav-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--fg1);
  background: var(--bg);
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.02em; color: var(--fg1); }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 4px; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 38px; padding: 0 16px;
  font: 500 14px/1 var(--font-body);
  border-radius: 10px; border: 1px solid transparent;
  white-space: nowrap; cursor: pointer;
  transition: transform 160ms var(--ease-app), background 160ms var(--ease-app), border-color 160ms var(--ease-app), color 160ms var(--ease-app);
}
.btn:active { transform: translateY(1px) scale(0.985); }
.btn--primary { background: var(--brand); color: var(--fg-on-brand); }
.btn--primary:hover { background: #93d0ab; }
.btn--ghost { border-color: var(--line-2); color: var(--fg1); background: transparent; }
.btn--ghost:hover { background: var(--card-hi); border-color: #4a4f48; }
.btn--lg { height: 48px; padding: 0 22px; font-size: 15px; border-radius: 12px; }

/* ── Navigation ── */
.nav {
  position: sticky; top: 0; z-index: 40;
  background: rgba(18, 20, 18, 0.72);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms, background 200ms;
}
.nav.is-scrolled { border-bottom-color: var(--line); background: rgba(18, 20, 18, 0.86); }
.nav__inner {
  max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter);
  height: var(--nav-h); display: flex; align-items: center; gap: 28px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 600; font-size: 17px; letter-spacing: -0.2px; }
.brand__mark {
  width: 26px; height: 26px; border-radius: 7px; background: var(--brand); color: var(--fg-on-brand);
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.brand--sm { font-size: 15px; }
.brand--sm .brand__mark { width: 22px; height: 22px; border-radius: 6px; }
.nav__links { display: flex; gap: 24px; flex: 1; justify-content: center; }
.nav__links a { font-size: 14px; color: var(--fg2); padding: 6px 0; transition: color 160ms; }
.nav__links a:hover { color: var(--fg1); }
.nav__cta { display: flex; gap: 10px; }
.nav__burger { display: none; margin-left: auto; width: 40px; height: 40px; border: 0; background: transparent; cursor: pointer; flex-direction: column; justify-content: center; align-items: center; gap: 6px; }
.nav__burger span { width: 20px; height: 2px; background: var(--fg1); border-radius: 2px; transition: transform 220ms var(--ease-out); }
.nav__burger[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.nav__burger[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }
.nav__sheet { display: none; }

@media (max-width: 900px) {
  .nav__links, .nav__cta { display: none; }
  .nav__burger { display: flex; }
  .nav__sheet { display: none; flex-direction: column; gap: 4px; padding: 8px var(--gutter) 18px; border-top: 1px solid var(--line); }
  .nav__sheet.is-open { display: flex; }
  .nav__sheet a { padding: 12px 0; font-size: 16px; color: var(--fg1); border-bottom: 1px solid var(--line); }
  .nav__sheet .btn { margin-top: 10px; border-bottom: 0; }
}

/* ── Gemeinsame Abschnitte ── */
section { position: relative; }
.section-head { max-width: 820px; margin: 0 auto 48px; padding: 0 var(--gutter); text-align: center; }
.section-head h2 { font-size: clamp(28px, 4vw, 44px); line-height: 1.08; }
.section-head p { margin-top: 16px; font-size: 17px; color: var(--fg2); }
.section-head--left { margin-left: 0; text-align: left; padding: 0; }
.eyebrow { font: 500 12px/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--brand); }
.accent { color: var(--brand); }

/* ── Scroll-Reveal ── */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 700ms var(--ease-out) var(--d, 0s), transform 700ms var(--ease-out) var(--d, 0s); }
.reveal.is-in { opacity: 1; transform: none; }

/* ── Hero ── */
.hero { padding: 24px 0 0; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto; height: 120%; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 50% at 70% 20%, rgba(127, 195, 154, 0.14), transparent 60%),
    radial-gradient(40% 40% at 20% 60%, rgba(76, 154, 248, 0.08), transparent 60%);
}
.ticker { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.ticker__track { display: flex; gap: 34px; width: max-content; padding: 8px 0; animation: marquee 48s linear infinite; }
.ticker:hover .ticker__track { animation-play-state: paused; }
.tk { display: inline-flex; align-items: center; gap: 8px; font: 500 12.5px/1 var(--font-mono); color: var(--fg2); white-space: nowrap; }
.tk b { color: var(--fg1); font-weight: 600; }
.tk em { font-style: normal; }
.tk .up { color: var(--up); }
.tk .dim { color: var(--fg3); }
.tk__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--c, var(--brand)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c, var(--brand)) 20%, transparent); }
@keyframes marquee { to { transform: translateX(-50%); } }

.hero__inner { max-width: var(--max); margin: 0 auto; padding: 56px var(--gutter) 0; }
.hero__copy { max-width: 860px; }
.hero h1 { margin-top: 16px; font-size: clamp(32px, 5vw, 56px); line-height: 1.04; letter-spacing: -0.03em; }
.lead { margin-top: 20px; max-width: 600px; font-size: clamp(16px, 1.6vw, 19px); color: var(--fg2); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

.hero__shot { position: relative; margin: 56px 0 0; perspective: 1600px; }
.hero__shot .frame { transform-origin: 50% 0; transform: rotateX(9deg) translateY(0); animation: hero-flat 1.3s var(--ease-out) 0.25s both; }
@keyframes hero-flat { from { transform: rotateX(16deg) translateY(28px); opacity: 0; } to { transform: rotateX(9deg) translateY(0); opacity: 1; } }
@supports (animation-timeline: view()) {
  .hero__shot .frame { animation: hero-flat 1.3s var(--ease-out) 0.25s both, hero-settle linear both; animation-timeline: auto, view(); animation-range: normal, entry 0% cover 45%; }
  @keyframes hero-settle { to { transform: rotateX(0deg); } }
}
.hero__glow { position: absolute; inset: 20% 10% -10%; z-index: -1; filter: blur(60px); background: radial-gradient(50% 50% at 50% 50%, rgba(127, 195, 154, 0.22), transparent 70%); pointer-events: none; }

/* Browser-Rahmen um Screenshots */
.frame { border-radius: var(--r-xl); border: 1px solid var(--line-2); background: var(--bg-2); overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.06); }
.frame__bar { display: flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; border-bottom: 1px solid var(--line); background: #171a17; }
.frame__bar i { width: 10px; height: 10px; border-radius: 50%; background: #2f342f; }
.frame__bar span { margin-left: 10px; min-width: 0; font: 500 11.5px/1 var(--font-mono); color: var(--fg3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.frame img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top; }

/* ── Börsen ── */
.venues { max-width: var(--max); margin: 72px auto 0; padding: 0 var(--gutter); text-align: center; }
.venues__label { font: 500 12px/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--fg3); }
.venues__row { margin-top: 18px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 26px; }
.venues__row li { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px 8px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); font-size: 14px; color: var(--fg2); transition: border-color 160ms, color 160ms, transform 160ms var(--ease-out); }
.venues__row li:hover { border-color: var(--line-2); color: var(--fg1); transform: translateY(-2px); }
.venues__row img { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; }

/* ── Zahlen ── */
.stats { max-width: var(--max); margin: 64px auto 0; padding: 0 var(--gutter); }
.stats__grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stat { padding: 26px 20px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; }
.stat strong { display: block; font: 700 clamp(30px, 3.6vw, 44px)/1 var(--font-display); letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.stat span { display: block; margin-top: 8px; font-size: 13.5px; color: var(--fg2); }
@media (max-width: 760px) {
  .stats__grid { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* ── Funktionen (Bento) ── */
.features { max-width: var(--max); margin: 0 auto; padding: 120px var(--gutter) 0; }
.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.cell { position: relative; padding: 26px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--card); overflow: hidden; min-height: 190px; }
.cell::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 300ms;
  background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 50%), rgba(127, 195, 154, 0.12), transparent 60%); }
.cell:hover::after { opacity: 1; }
.cell h3 { font-size: 19px; line-height: 1.25; }
.cell p { margin-top: 10px; font-size: 14.5px; color: var(--fg2); }
.cell--wide { grid-column: span 2; display: grid; grid-template-columns: 1fr 1.25fr; gap: 24px; align-items: center; padding-right: 0; }
.cell--wide img { width: 100%; border-radius: 12px 0 0 12px; border: 1px solid var(--line-2); border-right: 0; aspect-ratio: 16 / 10; object-fit: cover; object-position: left top; transform: translateX(6px); transition: transform 500ms var(--ease-out); }
.cell--wide:hover img { transform: translateX(0); }
.cell--full { grid-column: span 3; display: grid; grid-template-columns: 1.6fr 1fr; gap: 28px; align-items: center; min-height: 0; }
.cell--img-left { padding-right: 26px; padding-left: 0; }
.cell--img-left img { border-radius: 0 12px 12px 0; border-right: 1px solid var(--line-2); border-left: 0; object-position: right top; transform: translateX(-6px); }
@media (max-width: 960px) {
  .bento { grid-template-columns: 1fr 1fr; }
  .cell--wide, .cell--full { grid-column: span 2; }
}
@media (max-width: 640px) {
  .bento { grid-template-columns: 1fr; }
  .cell--wide, .cell--full, .cell--img-left { grid-column: span 1; grid-template-columns: 1fr; padding: 26px; }
  .cell--wide img, .cell--img-left img { border-radius: 12px; border: 1px solid var(--line-2); transform: none; }
  .cell--img-left img { order: 2; }
}

/* ── Showcase (Manual Trade) ── */
.showcase { max-width: var(--max); margin: 0 auto; padding: 120px var(--gutter) 0; }
.showcase__shot { margin: 0; perspective: 1600px; }
.showcase__shot .frame { transform-origin: 50% 100%; }
@supports (animation-timeline: view()) {
  .showcase__shot .frame { animation: rise-in linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
  @keyframes rise-in { from { transform: rotateX(-7deg) scale(0.96); opacity: 0.4; } to { transform: none; opacity: 1; } }
}

/* ── Ablauf (Sticky-Stapel) ── */
.steps { max-width: var(--max); margin: 0 auto; padding: 120px var(--gutter) 0; }
.stack { display: flex; flex-direction: column; gap: 24px; }
.stack__card {
  position: sticky; top: calc(var(--nav-h) + 16px);
  display: grid; grid-template-columns: 1fr 1.4fr; gap: 32px; align-items: center;
  padding: 32px; min-height: 420px;
  border-radius: var(--r-xl); border: 1px solid var(--line-2); background: #161916;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.35);
  transform-origin: 50% 0;
}
.stack__card:nth-child(2) { top: calc(var(--nav-h) + 32px); }
.stack__card:nth-child(3) { top: calc(var(--nav-h) + 48px); }
.stack__card:nth-child(4) { top: calc(var(--nav-h) + 64px); }
.stack__card:last-child { margin-bottom: 0; }
.stack__n { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; background: var(--brand-bg); color: var(--brand); font: 600 14px/1 var(--font-mono); }
.stack__text h3 { margin-top: 18px; font-size: clamp(22px, 2.6vw, 30px); line-height: 1.15; }
.stack__text p { margin-top: 12px; font-size: 15.5px; color: var(--fg2); max-width: 46ch; }
.stack__media { border-radius: var(--r-md); border: 1px solid var(--line-2); overflow: hidden; background: var(--bg); }
.stack__media img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: left top; }
.stack__media--login { aspect-ratio: 16 / 10; display: grid; place-items: center; background: radial-gradient(60% 60% at 50% 40%, rgba(127, 195, 154, 0.12), transparent 70%), var(--bg); }
.login { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 32px 36px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--bg-2); }
.login__mark { width: 44px; height: 44px; border-radius: 12px; background: var(--brand); color: var(--fg-on-brand); display: grid; place-items: center; margin-bottom: 8px; }
.login strong { font-family: var(--font-display); font-size: 18px; }
.login span { font: 500 12px/1 var(--font-mono); color: var(--fg3); }
.login__btn { margin-top: 18px; padding: 11px 18px; border-radius: 10px; background: var(--brand); color: var(--fg-on-brand); font-weight: 600; font-size: 14px; }
@supports (animation-timeline: view()) {
  .stack__card:not(:last-child) { animation: stack-away linear both; animation-timeline: view(); animation-range: exit -40% exit 60%; }
  @keyframes stack-away { to { transform: scale(0.94) translateY(-10px); opacity: 0.55; filter: brightness(0.8); } }
}
@media (max-width: 860px) {
  .stack__card { grid-template-columns: 1fr; min-height: 0; padding: 22px; position: relative; top: auto !important; }
  .stack__card { animation: none !important; }
  .stack__text p { max-width: none; }
}

/* ── Strategien (Scrollytelling) ── */
.strategies { max-width: var(--max); margin: 0 auto; padding: 120px var(--gutter) 0; }
.scrolly { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: start; }
.scrolly__media { position: sticky; top: calc(var(--nav-h) + 24px); }
.frame--stack .frame__imgs { position: relative; aspect-ratio: 16 / 10; }
.frame--stack img { position: absolute; inset: 0; opacity: 0; transform: scale(1.02); transition: opacity 500ms var(--ease-out), transform 700ms var(--ease-out); }
.frame--stack img.is-active { opacity: 1; transform: none; }
.scrolly__text { display: flex; flex-direction: column; }
.strat { padding: 11vh 0; border-top: 1px solid var(--line); opacity: 0.38; transition: opacity 400ms; }
.strat:first-child { border-top: 0; padding-top: 2vh; }
.strat.is-active { opacity: 1; }
.strat__n { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--line-2); color: var(--fg2); font: 600 13px/1 var(--font-mono); }
.strat.is-active .strat__n { border-color: var(--brand); color: var(--brand); background: var(--brand-bg); }
.strat h3 { margin-top: 16px; font-size: clamp(22px, 2.4vw, 28px); line-height: 1.15; }
.strat p { margin-top: 12px; font-size: 15.5px; color: var(--fg2); }
.strat ul { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.strat li { position: relative; padding-left: 18px; font-size: 14.5px; color: var(--fg1); }
.strat li::before { content: ""; position: absolute; left: 0; top: 9px; width: 8px; height: 8px; border-radius: 2px; background: var(--brand); opacity: 0.8; }
.strat__img { display: none; }
@media (max-width: 860px) {
  .scrolly { grid-template-columns: 1fr; }
  .scrolly__media { display: none; }
  .strat { opacity: 1; padding: 36px 0; }
  .strat__img { display: block; margin-top: 20px; border-radius: 12px; border: 1px solid var(--line-2); aspect-ratio: 16 / 10; object-fit: cover; object-position: left top; }
}

/* ── Sicherheit ── */
.security { margin-top: 120px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: linear-gradient(180deg, #151815, var(--bg)); }
.security__inner { max-width: var(--max); margin: 0 auto; padding: 96px var(--gutter); display: grid; grid-template-columns: 1fr 1.3fr; gap: 56px; align-items: start; }
.security__inner h2 { font-size: clamp(26px, 3.4vw, 40px); line-height: 1.1; }
.security__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px 32px; }
.sec h3 { font-size: 17px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.sec p { margin-top: 8px; font-size: 14.5px; color: var(--fg2); }
@media (max-width: 860px) {
  .security__inner { grid-template-columns: 1fr; gap: 32px; padding: 72px var(--gutter); }
}
@media (max-width: 560px) { .security__grid { grid-template-columns: 1fr; } }

/* ── FAQ ── */
.faq { max-width: 820px; margin: 0 auto; padding: 120px var(--gutter) 0; }
.faq__list { border-top: 1px solid var(--line); }
details { border-bottom: 1px solid var(--line); }
summary { list-style: none; cursor: pointer; padding: 20px 44px 20px 0; position: relative; font: 600 17px/1.35 var(--font-display); color: var(--fg1); }
summary::-webkit-details-marker { display: none; }
summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 10px; height: 10px; border-right: 2px solid var(--fg3); border-bottom: 2px solid var(--fg3); transform: translateY(-70%) rotate(45deg); transition: transform 240ms var(--ease-out), border-color 160ms; }
details[open] summary::after { transform: translateY(-30%) rotate(225deg); border-color: var(--brand); }
details p { padding: 0 0 22px; font-size: 15px; color: var(--fg2); max-width: 68ch; }
details .faq__body { overflow: hidden; }

/* ── Abschluss ── */
.final { max-width: var(--max); margin: 120px auto 0; padding: 0 var(--gutter); }
.final__inner { position: relative; overflow: hidden; text-align: center; padding: 72px var(--gutter); border-radius: var(--r-xl); border: 1px solid var(--line-2);
  background: radial-gradient(70% 90% at 50% 100%, rgba(127, 195, 154, 0.18), transparent 70%), #161916; }
.final h2 { font-size: clamp(26px, 3.6vw, 42px); line-height: 1.1; }
.final p { margin: 14px auto 0; max-width: 560px; font-size: 16px; color: var(--fg2); }
.final .hero__actions { justify-content: center; }

/* ── Footer ── */
.footer { margin-top: 64px; border-top: 1px solid var(--line); }
.footer__inner { max-width: var(--max); margin: 0 auto; padding: 32px var(--gutter) 40px; display: grid; grid-template-columns: auto 1fr; gap: 18px 40px; align-items: center; }
.footer__links { display: flex; flex-wrap: wrap; gap: 20px; justify-content: flex-end; }
.footer__links a { font-size: 14px; color: var(--fg2); }
.footer__links a:hover { color: var(--fg1); }
.footer__note { grid-column: 1 / -1; font-size: 12.5px; color: var(--fg3); max-width: 80ch; }
@media (max-width: 640px) {
  .footer__inner { grid-template-columns: 1fr; }
  .footer__links { justify-content: flex-start; }
}

/* ── Bewegung reduziert ── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker__track { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero__shot .frame, .showcase__shot .frame, .stack__card { animation: none !important; transform: none !important; }
  .frame--stack img { transition: opacity 200ms; transform: none; }
  .cell--wide img, .cell--img-left img { transform: none; transition: none; }
}
