/* ============================================================================
   tbd.software — v3 "tbd.software" landing page
   Design tokens, self-hosted fonts, layout & responsive behavior (spec_F1.9).
   Buildless: this file is served as-is by nginx (architecture/deployment.md).
   Copy/tokens/layout per requirements/reference/handoff-tbd-landing-v3.md.
   ============================================================================ */

/* ---------------------------------------------------------------------------
   Self-hosted fonts (spec_F1.9 B1.9.1-AC2) — no external font/CDN request.
   Relative URLs so the page works under any reverse-proxy subpath.
   --------------------------------------------------------------------------- */
@font-face {
  font-family: 'Newsreader';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/newsreader-400-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Newsreader';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/newsreader-500-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Newsreader';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/newsreader-400-italic.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/ibm-plex-sans-400-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/ibm-plex-sans-500-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/ibm-plex-sans-600-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/ibm-plex-mono-400-normal.woff2') format('woff2');
}

/* ---------------------------------------------------------------------------
   Design tokens (spec_F1.9 B1.9.1-AC1) — colors as CSS custom properties.
   v3 fuller Navy+Gold palette from handoff-tbd-landing-v3.md.
   --------------------------------------------------------------------------- */
:root {
  /* palette */
  --bg: #0a1119;
  --text: #d8e2ec;
  --heading: #f2ede2;
  --heading-bright: #f5f0e6;
  --invert-body: #e8eef4;
  --muted: #9db0c2;
  --muted-2: #8fa2b5;
  --muted-3: #7e93a6;
  --muted-4: #6f8397;
  --muted-5: #5c7085;
  --accent: #d4a94a;
  --accent-hover: #e0b962;
  --accent-card-body: #c3d2e0;

  /* accent-derived alphas */
  --field-bg: rgba(255, 255, 255, .04);
  --line-section: rgba(212, 169, 74, .16);
  --line-card: rgba(212, 169, 74, .16);
  --line-tile: rgba(212, 169, 74, .18);
  --line-field: rgba(212, 169, 74, .28);
  --line-faint: rgba(212, 169, 74, .12);
  --line-grid: rgba(212, 169, 74, .045);
  --tl-plain-fill: rgba(212, 169, 74, .03);
  --tl-plain-border: rgba(212, 169, 74, .14);
  --tl-accent-fill: rgba(212, 169, 74, .08);
  --tl-accent-border: rgba(212, 169, 74, .3);
  --spine: rgba(212, 169, 74, .45);
  --border-light: rgba(216, 226, 236, .22);

  /* fonts */
  --font-serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --font-sans: 'IBM Plex Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  /* layout */
  --pad-x: 52px;
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  position: relative;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }

h1, h2, h3 { margin: 0; font-weight: 400; }
[hidden] { display: none !important; }

/* Contour-grid overlay (spec_F1.9 B1.9.1-AC3): 64x64 repeating map grid,
   behind all content, non-interactive. Real element (not a pseudo) so the
   style-scan test can find its 64px 64px background-size. */
.contour-grid {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(var(--line-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-grid) 1px, transparent 1px);
  background-size: 64px 64px;
}

/* ---------------------------------------------------------------------------
   Section shell
   --------------------------------------------------------------------------- */
.sec {
  padding: 0 var(--pad-x);
  border-top: 1px solid var(--line-section);
}
.sec-inner {
  max-width: 1056px;
  margin: 0 auto;
  width: 100%;
}
.sec-head { text-align: center; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .2em;
  color: var(--accent);
  margin: 0 0 16px;
}

/* ---------------------------------------------------------------------------
   Display type — mobile-first (v3 scales UP on small screens, B1.9.2-AC3).
   The base (unqualified) sizes are the mobile sizes; the min-width:900px
   block shrinks them to their desktop sizes. This keeps the single 900px
   breakpoint honest and avoids specificity fights with the mobile sizes.
   --------------------------------------------------------------------------- */
.hh1 {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -.01em;
  color: var(--heading-bright);
  font-size: 76px;
  line-height: 1.02;
  margin: 0;
}
.accent-em { font-style: italic; color: var(--accent); }

.h2-xl {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -.01em;
  color: var(--heading);
  font-size: 58px;
  line-height: 1.05;
  margin: 0 0 18px;
}
.h2-lg {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -.01em;
  color: var(--heading);
  font-size: 54px;
  line-height: 1.06;
  margin: 0 0 16px;
}
.sec-sub {
  font-size: 26px;
  line-height: 1.55;
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto;
}
.route-sub { max-width: 540px; }

@media (min-width: 900px) {
  .hh1 { font-size: 72px; line-height: 1.05; }
  .h2-xl { font-size: 44px; }
  .h2-lg { font-size: 40px; line-height: 1.1; }
  #transparenz .kb-h2 { font-size: 37px; line-height: 1.14; }
  #kontakt .h2-lg { font-size: 42px; line-height: 1.08; }
  .sec-sub { font-size: 16px; line-height: 1.55; }
  #wert .sec-sub { line-height: 1.6; max-width: 600px; }
  .feat-title { font-size: 19px; }
  .feat-body { font-size: 14.5px; }
}

/* ---------------------------------------------------------------------------
   Buttons / CTAs (hover states — spec_F1.9 B1.9.3-AC1)
   --------------------------------------------------------------------------- */
.btn {
  display: inline-block;
  cursor: pointer;
  font-family: var(--font-sans);
  border-radius: 6px;
  border: 1px solid transparent;
  /* Only the subtle lift is animated; color/border/background change instantly
     on hover so the state change is immediately observable (B1.9.3-AC1). */
  transition: transform .15s ease;
}
.btn-primary {
  background-color: var(--accent);
  color: var(--bg);
  font-weight: 600;
  font-size: 14.5px;
  padding: 16px 30px;
}
.btn-primary:hover { background-color: var(--accent-hover); transform: translateY(-1px); }

.btn-outline-light {
  border: 1px solid var(--border-light);
  color: var(--text);
  font-size: 14.5px;
  padding: 16px 28px;
}
.btn-outline-light:hover {
  border-color: rgba(216, 226, 236, .5);
  color: #ffffff;
  transform: translateY(-1px);
}

/* ---------------------------------------------------------------------------
   1 · Navigation
   --------------------------------------------------------------------------- */
.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px var(--pad-x);
  border-bottom: 1px solid var(--line-section);
}
.logo { display: flex; align-items: center; gap: 11px; }
.wordmark {
  font-family: var(--font-serif);
  font-size: 19px;
  font-weight: 500;
  letter-spacing: .01em;
  color: var(--heading);
}
.navlinks { display: flex; align-items: center; gap: 26px; }
.navmid { display: flex; align-items: center; gap: 26px; }
.nav-link {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: .02em;
  color: var(--muted-3);
  transition: color .15s ease;
}
.nav-link:hover { color: var(--heading); cursor: pointer; }
.nav-cta {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: .02em;
  color: var(--accent);
  border: 1px solid var(--accent);
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  /* Instant color/border/background change on hover (B1.9.3-AC1). */
}
.nav-cta:hover {
  color: var(--accent-hover);
  border-color: var(--accent-hover);
  background-color: rgba(212, 169, 74, .08);
}

/* Compass-ring glyph (logo + route row 0 + vision) — CSS only, no image. */
.compass-ring {
  width: 24px;
  height: 24px;
  border: 1.5px solid var(--accent);
  border-radius: 50%;
  position: relative;
  flex: none;
  display: inline-block;
}
.compass-ring::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1.5px;
  height: 52%;
  background: var(--accent);
  transform: translate(-50%, -50%) rotate(38deg);
  border-radius: 1px;
}
.compass-ring::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 3.5px;
  height: 3.5px;
  background: var(--accent);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}
.compass-lg { width: 34px; height: 34px; }
/* Navy compass inside the gold-filled route row-0 node. */
.compass-node { width: 20px; height: 20px; border-color: var(--bg); }
.compass-node::after,
.compass-node::before { background: var(--bg); }

/* ---------------------------------------------------------------------------
   2 · Hero
   --------------------------------------------------------------------------- */
.hero {
  padding: 82px var(--pad-x) 90px;
  text-align: center;
  border-top: none;
}
.hero-inner { max-width: 820px; margin: 0 auto; }
.hero-eyebrow { letter-spacing: .22em; margin-bottom: 30px; }
.hero-cta {
  display: flex;
  gap: 14px;
  justify-content: center;
  margin-top: 40px;
}

/* ---------------------------------------------------------------------------
   3 · Route (7-phase vertical timeline)
   --------------------------------------------------------------------------- */
#route { padding-top: 74px; padding-bottom: 84px; }
.route-inner { max-width: 820px; }
.route-head { margin-bottom: 56px; }
.route-head .eyebrow { letter-spacing: .2em; margin-bottom: 14px; }

.timeline { position: relative; max-width: 660px; margin: 0 auto; }
.tl-spine {
  position: absolute;
  left: 23px;
  top: 34px;
  bottom: 34px;
  width: 1px;
  background: repeating-linear-gradient(180deg, var(--spine) 0 6px, transparent 6px 14px);
}
.tl-row {
  display: flex;
  gap: 26px;
  align-items: flex-start;
  padding: 9px 0;
  position: relative;
}
.tl-node {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1.5px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
  font-family: var(--font-serif);
  font-size: 19px;
  background: var(--bg);
  color: var(--accent);
}
.tl-node--accent {
  background: var(--accent);
  color: var(--bg);
  font-weight: 500;
  box-shadow: 0 0 22px rgba(212, 169, 74, .35);
}
.tl-card {
  flex: 1;
  background: var(--tl-plain-fill);
  border: 1px solid var(--tl-plain-border);
  border-radius: 12px;
  padding: 18px 24px;
}
.tl-card--accent {
  background: var(--tl-accent-fill);
  border: 1px solid var(--tl-accent-border);
}
.tl-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .16em;
  color: var(--accent);
  margin: 0 0 8px;
}
.tl-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--heading);
  margin: 0 0 8px;
}
.tl-title--accent {
  font-family: var(--font-serif);
  font-size: 23px;
  font-weight: 400;
  color: var(--heading-bright);
  margin: 0 0 6px;
}
.tl-body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted-2);
  margin: 0;
}
.tl-body--accent { line-height: 1.55; color: var(--accent-card-body); }
.tl-res { color: var(--accent); }

/* ---------------------------------------------------------------------------
   4 · Wo Dein Aufwand hinfließt (feature grid) + 5 · Sicherheit
   --------------------------------------------------------------------------- */
#wert { padding-top: 80px; padding-bottom: 80px; }
.sec-head { margin-bottom: 52px; }
#wert .sec-head .eyebrow { margin-bottom: 16px; }

.g2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.feat-card {
  background: var(--tl-plain-fill);
  border: 1px solid var(--line-card);
  border-radius: 12px;
  padding: 28px 30px;
}
.feat-title {
  font-size: 32px;
  font-weight: 600;
  color: var(--heading);
  margin: 0 0 12px;
}
.feat-body {
  font-size: 22px;
  line-height: 1.6;
  color: var(--muted-2);
  margin: 0;
}

#sicherheit {
  padding-top: 78px;
  padding-bottom: 78px;
  background: linear-gradient(180deg, rgba(212, 169, 74, .03), transparent);
}
#sicherheit .sec-head { margin-bottom: 48px; }
.g2-sec { gap: 16px; }
.sec-card {
  border: 1px solid var(--line-tile);
  border-radius: 10px;
  padding: 26px 28px;
}
.sec-label {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .04em;
  color: var(--accent);
  margin: 0 0 14px;
}
.sec-title {
  font-size: 17px;
  font-weight: 600;
  color: var(--heading);
  margin: 0 0 9px;
}
.sec-body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted-2);
  margin: 0;
}

/* ---------------------------------------------------------------------------
   6 · Keine Blackbox (asymmetric 2-column)
   --------------------------------------------------------------------------- */
#transparenz { padding-top: 78px; padding-bottom: 78px; }
.gkb {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: 56px;
  align-items: start;
}
.kb-claim .eyebrow { margin-bottom: 16px; }
.kb-h2 { margin: 0 0 18px; }
.kb-claim-body {
  font-size: 15px;
  line-height: 1.65;
  color: var(--muted);
  margin: 0;
}
.kb-rows { display: flex; flex-direction: column; gap: 14px; }
.kb-row {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}
.kb-row:not(:last-child) {
  border-bottom: 1px solid var(--line-faint);
  padding-bottom: 16px;
}
.kb-star {
  font-family: var(--font-serif);
  font-size: 22px;
  color: var(--accent);
  line-height: 1;
  flex: none;
  width: 24px;
}
.kb-title {
  font-size: 17px;
  font-weight: 600;
  color: var(--heading);
  margin: 0 0 6px;
}
.kb-body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted-2);
  margin: 0;
}

/* ---------------------------------------------------------------------------
   7 · Vision
   --------------------------------------------------------------------------- */
#vision { padding-top: 82px; padding-bottom: 82px; }
.vision-inner {
  max-width: 780px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.vision-glyph { margin-bottom: 26px; }
.vision-eyebrow {
  font-size: 15px;
  letter-spacing: .16em;
  margin: 0 0 22px;
}
.vision-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 28px;
  line-height: 1.42;
  font-weight: 400;
  color: var(--invert-body);
  margin: 0;
}
.vision-prose {
  font-size: 16.5px;
  line-height: 1.72;
  color: var(--muted);
  max-width: 680px;
  text-align: left;
  margin: 34px auto 0;
}
.vision-prose + .vision-prose { margin-top: 22px; }

/* ---------------------------------------------------------------------------
   8 · Kontakt / Footer
   --------------------------------------------------------------------------- */
.sec-kontakt {
  padding-top: 70px;
  padding-bottom: 76px;
  text-align: center;
  background: radial-gradient(120% 130% at 50% 100%, rgba(212, 169, 74, .1), transparent 60%);
}
.kontakt-inner { max-width: 600px; margin: 0 auto; }
#kontakt .h2-lg { margin: 0 0 14px; }
.kontakt-sub {
  font-size: 16px;
  color: var(--muted);
  margin: 0 0 30px;
}

.kontakt-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 460px;
  margin: 0 auto;
  text-align: left;
}
.field {
  background-color: var(--field-bg);
  border: 1px solid var(--line-field);
  border-radius: 6px;
  padding: 15px 18px;
  color: var(--heading);
  font-family: var(--font-sans);
  font-size: 14px;
  width: 100%;
}
.field::placeholder { color: var(--muted-4); }
.field:focus { outline: none; border-color: var(--accent); }
#message { resize: vertical; min-height: 120px; }

.kontakt-submit {
  align-self: flex-start;
  background-color: var(--accent);
  color: var(--bg);
  font-weight: 600;
  font-size: 14.5px;
  padding: 15px 26px;
  border: none;
  border-radius: 6px;
}
.kontakt-submit:hover:not(:disabled) {
  background-color: var(--accent-hover);
  transform: translateY(-1px);
}
.kontakt-submit:disabled { opacity: .5; cursor: not-allowed; }

/* Honeypot (component-map D1): zero-size + off-screen so it is invisible to
   users, assistive tech AND layout/tests; bots that autofill it are dropped
   server-side. Zero box => Playwright reports it not visible. */
.honeypot {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 0;
  height: 0;
  padding: 0;
  border: 0;
  margin: 0;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.form-privacy {
  margin: 2px 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
}
.form-privacy a { color: var(--accent); text-decoration: underline; }
.form-privacy a:hover { color: var(--accent-hover); cursor: pointer; }

.form-status {
  margin: 8px 0 0;
  color: var(--accent);
  font-weight: 600;
}
.form-error {
  margin: 8px 0 0;
  color: #e88b7a;
  font-size: 14px;
}

.footer {
  margin-top: 46px;
  padding-top: 24px;
  border-top: 1px solid var(--line-faint);
  text-align: center;
}
.footer-line {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .05em;
  color: var(--muted-5);
}
.footer-links {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .05em;
  color: var(--muted-5);
  margin-top: 10px;
}
.footer-links a { color: var(--muted-3); transition: color .15s ease; }
.footer-links a:hover { color: var(--accent); cursor: pointer; }

/* ---------------------------------------------------------------------------
   Legal pages (Impressum / Datenschutz) — restyled to the v3 look; tokens
   are the same navy/gold, so this carries over from Increment 3 (F1.8).
   --------------------------------------------------------------------------- */
.legal {
  padding: 90px var(--pad-x) 40px;
  min-height: 70vh;
}
.legal .inner { max-width: 760px; margin: 0 auto; }
.legal h1 {
  font-family: var(--font-serif);
  font-size: 44px;
  color: var(--heading-bright);
  margin: 0 0 24px;
}
.legal h2 {
  font-family: var(--font-sans);
  font-size: 18px;
  color: var(--heading);
  margin: 28px 0 8px;
}
.legal p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}
.legal .back-link {
  display: inline-block;
  margin-top: 24px;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 13px;
}
.legal .back-link:hover { color: var(--accent-hover); cursor: pointer; }

/* ---------------------------------------------------------------------------
   Reversible scroll-reveal (spec_F1.9 B1.9.3-AC2/AC3/AC4) — transform-based
   slide-in per handoff-tbd-landing-v3.md's exact contract. The hidden state
   carries BOTH opacity:0 AND a per-element transform offset (--rv); the shown
   state animates BOTH back to opacity:1 / transform:none. NOT opacity-only.
   CSS transforms don't affect document layout, so sibling geometry is
   unperturbed while blocks slide into place.

   Progressive enhancement (B1.9.3-AC4, no-JS fallback): the hidden state is
   scoped to `.js-reveal`, which the head bootstrap in index.html adds only
   when JS runs. With JS disabled the class is absent → [data-reveal] elements
   keep their natural, fully-visible styling and are never stuck hidden.
   --------------------------------------------------------------------------- */
.js-reveal [data-reveal] {
  opacity: 0;
  /* per-element start offset; whole sections default to translateY(120px) */
  transform: var(--rv, translateY(120px));
  transition: opacity .95s ease,
              transform .95s cubic-bezier(.22, 1, .36, 1);
  will-change: opacity, transform;
}
.js-reveal [data-reveal][data-shown="1"] {
  opacity: 1;
  transform: none;
}

/* Per-group start offsets (--rv). Sub-blocks (section headers, grid cards,
   security tiles) rise 90px; the "Keine Blackbox" left column enters from the
   left and its rows from the right. The 7 route-timeline rows alternate L/R
   via an inline --rv set per row (see index.html). */
.route-head[data-reveal],
.sec-head[data-reveal],
.feat-card[data-reveal],
.sec-card[data-reveal] { --rv: translateY(90px); }
.kb-claim[data-reveal] { --rv: translateX(-90px); }
.kb-row[data-reveal]   { --rv: translateX(90px); }

/* Reduced motion (B1.9.3-AC4): no animation; every element fully visible from
   first paint regardless of JS. Placed last so it wins on equal specificity. */
@media (prefers-reduced-motion: reduce) {
  .js-reveal [data-reveal] {
    transition: none;
    opacity: 1;
    transform: none;
  }
}

/* ---------------------------------------------------------------------------
   Responsive collapse — single 900px breakpoint (spec_F1.9 B1.9.2).
   Layout collapses; the display type is scaled up in the mobile-first base
   above. "below 900px" excludes 900px itself, so max-width: 899.98px.
   --------------------------------------------------------------------------- */
@media (max-width: 899.98px) {
  :root { --pad-x: 12px; }

  /* nav: hide the 4 middle links; brand + "Anfrage" stay (no hamburger) */
  .navmid { display: none; }
  .navlinks { gap: 0; }

  .hero { padding-top: 64px; padding-bottom: 76px; }

  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn { font-size: 24px; padding: 26px 30px; text-align: center; }

  .g2 { grid-template-columns: 1fr; gap: 18px; }
  .gkb { grid-template-columns: 1fr; gap: 44px; }

  .feat-card { padding: 38px 36px; }
  .feat-title { margin-bottom: 16px; }

  .kontakt-form .field { font-size: 21px; padding: 24px 24px; }
}
