/* ==========================================================================
   Trading Bot — Design-Tokens
   Farbwelt: biolumineszentes Labor. Tiefschwarz mit Blaugrün-Stich als
   Grundton, Teal und Violett als die beiden DNA-Stränge, die sich durch
   das ganze Interface ziehen.
   ========================================================================== */

:root {
  --void: #050A0E;
  --strata: #0B1319;
  --membrane: #101C23;
  --edge: #1B2D37;
  --edge-lit: #24404E;

  --helix-a: #2DD4BF;
  --helix-b: #A78BFA;

  --signal: #4ADE80;
  --loss: #FB7185;
  --warn: #FBBF24;

  --text: #E6F1F4;
  --text-dim: #9CB3BC;
  --muted: #5F7783;

  --font-display: 'Bricolage Grotesque', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;

  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--void);
  color: var(--text);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* --- DNA-Hintergrund ---------------------------------------------------- */

#dna-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* Vignette über der Animation, damit Text immer lesbar bleibt */
.veil {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 80% 60% at 50% 40%, transparent 0%, rgba(5,10,14,0.82) 100%),
    linear-gradient(180deg, rgba(5,10,14,0.5) 0%, transparent 25%, transparent 70%, rgba(5,10,14,0.75) 100%);
}

.stage {
  position: relative;
  z-index: 2;
}

/* --- Typografie --------------------------------------------------------- */

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0;
}

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

.eyebrow {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

/* --- Karten / Flächen --------------------------------------------------- */

.panel {
  background: color-mix(in srgb, var(--strata) 88%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--edge);
  border-radius: var(--r-md);
}

/* --- Formular-Elemente -------------------------------------------------- */

label {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 18px 0 7px;
}

input[type="text"],
input[type="password"] {
  width: 100%;
  padding: 11px 13px;
  background: rgba(5, 10, 14, 0.7);
  border: 1px solid var(--edge);
  border-radius: var(--r-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 14px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

input[type="text"]:focus,
input[type="password"]:focus {
  outline: none;
  border-color: var(--helix-a);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--helix-a) 14%, transparent);
}

input.code-input {
  font-size: 22px;
  letter-spacing: 0.34em;
  text-align: center;
  padding: 13px;
}

button, .btn {
  display: block;
  width: 100%;
  margin-top: 22px;
  padding: 12px;
  border: none;
  border-radius: var(--r-sm);
  background: linear-gradient(120deg, var(--helix-a) 0%, var(--helix-b) 100%);
  color: #05131A;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: transform 140ms ease, filter 140ms ease;
}

button:hover, .btn:hover { filter: brightness(1.1); }
button:active { transform: translateY(1px); }

button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 2px solid var(--helix-a);
  outline-offset: 2px;
}

/* --- Meldungen ---------------------------------------------------------- */

.notice {
  margin-top: 16px;
  padding: 11px 13px;
  border-radius: var(--r-sm);
  font-size: 13px;
  line-height: 1.45;
  border: 1px solid;
}

.notice.error {
  background: color-mix(in srgb, var(--loss) 12%, transparent);
  border-color: color-mix(in srgb, var(--loss) 38%, transparent);
  color: var(--loss);
}

/* --- Auth-Seiten Layout ------------------------------------------------- */

.auth-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px 20px;
}

.auth-card {
  width: 100%;
  max-width: 380px;
  padding: 34px;
}

.auth-card.wide { max-width: 440px; }

.auth-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 3px;
}

.auth-head h1 { font-size: 23px; }

.auth-sub {
  color: var(--text-dim);
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 4px;
}

/* Kleines Doppelhelix-Zeichen neben der Überschrift */
.mark {
  width: 15px;
  height: 22px;
  flex: none;
  opacity: 0.9;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
