/* raschko.at — styles
   Keine externen Ressourcen: Schriften kommen aus dem System-Stack. */

:root {
  --bg: #05070b;
  --panel: #0b1017;
  --line: #1a2430;
  --fg: #d5dfea;
  --dim: #5f6f82;
  --accent: #3aa8e8;

  /* Partikelfeld */
  --p-base: #cdd9e6;
  --p-hot: #3aa8e8;
  --p-mid: #1f77ae;
  --p-dust: #4f7396;

  --mono: "JetBrains Mono", "Cascadia Code", "Cascadia Mono", "Fira Code",
    ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "DejaVu Sans Mono", monospace;
  --sans: "Source Sans 3", "Source Sans Pro", "Segoe UI", "Helvetica Neue",
    Roboto, "Noto Sans", system-ui, sans-serif;

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100dvh;
  background-color: var(--bg);
  /* feines Punktraster + Vignette */
  background-image:
    radial-gradient(ellipse 85% 65% at 50% 45%, transparent 30%, var(--bg) 100%),
    radial-gradient(circle, color-mix(in srgb, var(--dim) 26%, transparent) 1px, transparent 1.5px);
  background-size: 100% 100%, 28px 28px;
  background-position: 0 0, 14px 14px;
  background-attachment: fixed;
  color: var(--fg);
  font-family: var(--mono);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

main, footer { position: relative; z-index: 1; }

a { color: var(--accent); text-underline-offset: 3px; }
.sr {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }

/* ---------- Szenen ---------- */

.sec {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: clamp(56px, 10vh, 110px) 24px;
  text-align: center;
}
.sec-in { width: 100%; max-width: 820px; margin: 0 auto; }
.sec-in.wide { max-width: 1100px; }

.stage { width: 100%; margin: 0 auto; }
.st-logo {
  height: clamp(100px, 24vh, 210px);
  display: grid;
  place-items: center;
  font: inherit;
}
.st-chart { height: clamp(200px, 40vh, 360px); }
.st-band { height: clamp(110px, 22vh, 200px); }

.wordmark {
  font-family: var(--sans);
  font-size: clamp(56px, 15vw, 140px);
  line-height: 1;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.wordmark .w-a { font-weight: 300; color: var(--fg); }
.wordmark .w-b { font-weight: 900; color: var(--accent); }
/* Mit JS zeichnet das Partikelfeld das Logo; der Text bleibt für Screenreader. */
.js .wordmark { opacity: 0; user-select: none; }

/* Sätze */
.say {
  margin: clamp(22px, 5vh, 44px) auto 0;
  max-width: 24ch;
  font-family: var(--sans);
  font-size: clamp(24px, 3.6vw, 42px);
  font-weight: 300;
  line-height: 1.2;
  letter-spacing: 0.005em;
  text-wrap: balance;
}
.js .say:not(.ready) { visibility: hidden; }
.say .w { display: inline-block; white-space: nowrap; }
.say .ch {
  display: inline-block;
  opacity: 0;
  filter: blur(7px);
  transform: translateY(var(--y, 0));
  transition: opacity .5s ease, filter .5s ease, transform .5s ease;
}
.sec.on .say .ch {
  opacity: 1;
  filter: blur(0);
  transform: none;
  transition: opacity .9s ease, filter 1.1s ease, transform 1.1s ease;
  transition-delay: calc(.45s + var(--d, 0s));
}

/* Randnotizen */
.note {
  margin: 18px 0 0;
  font-size: 11px;
  letter-spacing: .22em;
  color: var(--dim);
  white-space: pre-wrap;
  font-variant-numeric: tabular-nums;
  transition: opacity .6s ease;
}
.js .note { opacity: 0; }
.js .sec.on .note { opacity: 1; transition-delay: .4s; }

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 24px;
  width: 20px;
  height: 34px;
  margin-left: -10px;
  border: 1px solid var(--dim);
  border-radius: 11px;
  opacity: .7;
}
.scroll-cue span {
  position: absolute; left: 50%; top: 7px; width: 2px; height: 6px; margin-left: -1px;
  border-radius: 2px; background: var(--accent); animation: cue 2.2s ease-in-out infinite;
}

/* ---------- Sprachschalter ---------- */

.lang {
  position: fixed;
  top: 18px;
  right: 22px;
  z-index: 6;
  display: flex;
  gap: 14px;
  font-size: 11px;
  letter-spacing: .18em;
}
.lang a { color: var(--dim); text-decoration: none; transition: color .15s; }
.lang a:hover { color: var(--accent); }
.lang a[aria-current] { color: var(--fg); }
.lang a.hint { color: var(--accent); animation: hint 2.4s ease-in-out 1.2s 3; }

/* ---------- Szenen-Leiste (ein kleines Balkendiagramm) ---------- */

.rail {
  position: fixed;
  right: 22px;
  top: 50%;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  transform: translateY(-50%);
}
.rail a {
  position: relative;
  display: block;
  width: var(--w);
  height: 3px;
  border-radius: 2px;
  background: color-mix(in srgb, var(--dim) 45%, transparent);
  transition: background-color .3s, width .3s;
}
.rail a::after { content: ""; position: absolute; inset: -6px -4px; }
.rail a:hover { background: var(--dim); }
.rail a.on { background: var(--accent); width: calc(var(--w) + 10px); }

/* ---------- Footer ---------- */

footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 20px;
  padding: 16px 24px 20px;
  font-size: 11px;
  letter-spacing: .06em;
  color: var(--dim);
}
footer .what { margin: 0; }
footer nav { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; }
footer a, footer button {
  all: unset;
  color: var(--dim);
  cursor: pointer;
  transition: color .15s;
}
footer a:hover, footer button:hover { color: var(--accent); }
footer a:focus-visible, footer button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Impressum-Dialog ---------- */

dialog {
  width: min(92vw, 460px);
  padding: 22px 24px;
  background: var(--panel);
  color: var(--fg);
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .8);
}
dialog::backdrop { background: color-mix(in srgb, var(--bg) 82%, transparent); }
dialog h2 { margin: 0 0 14px; font: 600 14px/1.4 var(--mono); color: var(--accent); }
dialog address { font-style: normal; }
dialog p { margin: 0 0 12px; }
dialog .close {
  all: unset;
  margin-top: 6px;
  padding: 4px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--fg);
  cursor: pointer;
}
dialog .close:hover { border-color: var(--accent); color: var(--accent); }
dialog .close:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Textseiten (Datenschutz) ---------- */

.doc {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 78ch;
  margin: 0 auto;
  padding: clamp(20px, 6vh, 56px) 16px 24px;
}
.back { color: var(--accent); text-decoration: none; }
.back:hover { text-decoration: underline; }
.back.end { margin-top: 20px; }
.prose {
  margin-top: 20px;
  padding: clamp(18px, 4vw, 36px);
  background: color-mix(in srgb, var(--panel) 88%, transparent);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
.prose h1 { margin: 0 0 4px; font-size: 28px; line-height: 1.2; }
.prose h2 { margin: 36px 0 8px; font-size: 20px; line-height: 1.3; color: var(--accent); }
.prose h3 { margin: 26px 0 6px; font-size: 17px; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: 4px 0; }
.prose .seal { margin-top: 36px; font-size: 14px; color: var(--dim); }

/* ---------- Bewegung ---------- */

@keyframes cue {
  0% { opacity: 0; transform: translateY(0); }
  30% { opacity: 1; }
  100% { opacity: 0; transform: translateY(12px); }
}

@keyframes hint { 50% { opacity: .35; } }

@media (max-width: 900px) {
  .rail { display: none; }
}

@media (max-width: 560px) {
  .sec { padding: 56px 18px; }
  .st-logo { height: clamp(70px, 20vw, 120px); }
  .st-chart { height: clamp(180px, 34vh, 280px); }
  .note { letter-spacing: .14em; }
  footer { flex-direction: column; text-align: center; }
  footer nav { justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .scroll-cue span, .lang a.hint { animation: none; }
  .say .ch, .sec.on .say .ch, .note { transition: none; filter: none; transform: none; }
}
