/* ===== Tokens ===== */
:root {
  /* color — Fluxinum: Basis-Blau, Strömungs-Blau, alchemistisches/flüssiges Silber */
  --deep: #0a192f;
  --flow: #1e3a8a;
  --silver: #cbd5e1;
  --silver-bright: #e2e8f0;

  --bg: var(--deep);
  --surface: rgba(30, 58, 138, 0.22);
  --surface-raised: rgba(30, 58, 138, 0.34);
  --line: rgba(30, 58, 138, 0.55);
  --text: var(--silver);
  --text-muted: #a8b8ce;
  --text-faint: #93a4bd;
  --accent: var(--silver-bright);
  --accent-hover: #ffffff;
  --accent-text: var(--deep);

  --gradient-flow: linear-gradient(135deg, var(--deep), var(--flow), var(--silver));
  --gradient-key: linear-gradient(135deg, var(--flow), var(--silver), var(--silver-bright));
  --gradient-btn: linear-gradient(135deg, var(--deep), var(--flow));
  --gradient-btn-hover: linear-gradient(135deg, #132449, #28459c);

  /* spacing (8px grid, with 4px half-step) */
  --sp-1: 0.25rem;  /* 4  */
  --sp-2: 0.5rem;   /* 8  */
  --sp-3: 1rem;     /* 16 */
  --sp-4: 1.5rem;   /* 24 */
  --sp-5: 2rem;     /* 32 */
  --sp-6: 3rem;     /* 48 */
  --sp-7: 4rem;     /* 64 */
  --sp-8: 6rem;     /* 96 */

  /* type scale */
  --text-xs: 0.8125rem;
  --text-sm: 0.9375rem;
  --text-base: 1.0625rem;
  --text-lg: 1.25rem;
  --text-xl: 1.5rem;
  --text-2xl: 2rem;
  --text-3xl: clamp(2.25rem, 4vw, 3rem);
  --text-4xl: clamp(2.75rem, 6vw, 4.25rem);

  --font-display: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-body: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;

  --max-width: 1180px;
  --radius-sm: 4px;
  --radius: 8px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* ===== Base ===== */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

p {
  margin: 0;
}

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

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: var(--accent-text);
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--radius-sm);
  z-index: 100;
}

.skip-link:focus {
  left: var(--sp-3);
  top: var(--sp-3);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* ===== Overline ===== */
.overline {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--sp-3);
}

.overline-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

/* ===== Header ===== */
.site-header {
  background: linear-gradient(var(--surface), var(--surface)), var(--bg);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}

.navbar {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--sp-2) var(--sp-4);
}

.logo {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  letter-spacing: -0.01em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--sp-5);
}

.nav-links a {
  position: relative;
  font-size: var(--text-sm);
  color: var(--text-muted);
  padding: var(--sp-1) 0;
  transition: color 0.2s var(--ease);
}

.nav-links a::after {
  content: '';
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -2px;
  height: 1px;
  background: var(--accent);
  transition: right 0.25s var(--ease);
}

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

.nav-links a:hover::after {
  right: 0;
}

.nav-links a.nav-cta {
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: var(--sp-2) var(--sp-3);
}

.nav-links a.nav-cta::after {
  display: none;
}

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

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--sp-2);
}

.nav-toggle span {
  width: 22px;
  height: 1.5px;
  background: var(--text);
}

/* ===== Hero ===== */
.hero {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--sp-8) var(--sp-4);
}

.hero-mark {
  margin: 0 0 var(--sp-4) 0;
  font-weight: 800;
  font-size: clamp(3rem, 9vw, 6.5rem);
  line-height: 1;
  letter-spacing: -0.03em;
  background: var(--gradient-key);
  background-clip: text;
  -webkit-background-clip: text;
  color: var(--accent);
  -webkit-text-fill-color: transparent;
  transform-origin: top left;
  will-change: transform, opacity;
}

.hero-text {
  max-width: 640px;
}

.hero-text h1 {
  font-size: var(--text-4xl);
  margin-bottom: var(--sp-4);
}

.hero-lede {
  color: var(--text-muted);
  font-size: var(--text-lg);
  max-width: 46ch;
  margin-bottom: var(--sp-5);
}

/* ===== Signup form ===== */
.signup-form {
  display: flex;
  gap: var(--sp-3);
  align-items: end;
  flex-wrap: wrap;
}

.field {
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  flex: 1;
  min-width: 220px;
}

.field label {
  font-size: var(--text-xs);
  color: var(--text-faint);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.field input {
  padding: var(--sp-3);
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: var(--text-base);
  transition: border-color 0.2s var(--ease);
}

.field input::placeholder {
  color: var(--text-faint);
}

.field input:focus {
  border-color: var(--accent);
}

.form-status {
  min-height: 1.4em;
  color: var(--accent);
  font-size: var(--text-sm);
  margin-top: var(--sp-3);
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--radius-sm);
  font-size: var(--text-base);
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.15s var(--ease), background 0.2s var(--ease);
  white-space: nowrap;
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: var(--gradient-btn);
  color: var(--text);
  border-color: rgba(203, 213, 225, 0.25);
}

.btn-primary:hover {
  background: var(--gradient-btn-hover);
  color: var(--accent-hover);
  border-color: rgba(226, 232, 240, 0.5);
}

/* ===== Sections ===== */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--sp-8) var(--sp-4);
  border-top: 1px solid var(--line);
}

.section-head {
  margin-bottom: var(--sp-6);
}

.section-head h2 {
  font-size: var(--text-3xl);
  max-width: 20ch;
}

/* ===== Steps ===== */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
}

.step {
  display: grid;
  grid-template-columns: 4rem 1fr;
  gap: var(--sp-5);
  padding: var(--sp-5) 0;
  border-top: 1px solid var(--line);
  align-items: baseline;
}

.step:last-child {
  border-bottom: 1px solid var(--line);
}

.step-index {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  color: var(--text-faint);
  font-variant-numeric: tabular-nums;
}

.step-body h3 {
  font-size: var(--text-xl);
  margin-bottom: var(--sp-1);
}

.step-body p {
  color: var(--text-muted);
  max-width: 56ch;
}

/* ===== Features ===== */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-5);
}

.feature {
  padding: var(--sp-4);
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 2px solid var(--flow);
  border-radius: var(--radius);
}

.feature h3 {
  font-size: var(--text-lg);
  margin-bottom: var(--sp-2);
}

.feature p {
  color: var(--text-muted);
  font-size: var(--text-sm);
}

/* ===== CTA ===== */
.cta-section {
  padding-bottom: var(--sp-8);
}

.cta-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--sp-7) var(--sp-5);
  text-align: center;
}

.cta-box h2 {
  font-size: var(--text-2xl);
  margin-bottom: var(--sp-2);
}

.cta-box p {
  color: var(--text-muted);
  margin-bottom: var(--sp-5);
}

.cta-box .signup-form {
  justify-content: center;
  max-width: 480px;
  margin: 0 auto;
}

/* ===== Footer ===== */
.site-footer {
  text-align: center;
  padding: var(--sp-6) var(--sp-4);
  color: var(--text-faint);
  font-size: var(--text-xs);
  border-top: 1px solid var(--line);
}

.site-footer p {
  margin: var(--sp-1) 0;
}

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

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: var(--sp-2) 0;
    border-bottom: 1px solid var(--line);
    display: none;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    width: 100%;
    padding: var(--sp-3) var(--sp-4);
  }

  .nav-links a.nav-cta {
    margin: var(--sp-2) var(--sp-4);
    text-align: center;
  }

  .step {
    grid-template-columns: 3rem 1fr;
    gap: var(--sp-3);
  }
}

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

  .signup-form {
    flex-direction: column;
    align-items: stretch;
  }

  .field {
    min-width: 0;
  }
}
