/* KRIZ Labs – Fehlerseiten. Gleicher Stil wie krizlabs.io. Keine externen Requests, keine Inline-Styles. */

@font-face {
  font-family: "Organetto";
  src: url("/error_docs/fonts/organetto-ucnd-bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Exo 2";
  src: url("/error_docs/fonts/exo2-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --void: #05040a;
  --deep: #0d0a1c;
  --nebula: #1b1238;
  --violet: #8b5cf6;
  --violet-hot: #a66bff;
  --plasma: #cdbcff;
  --platinum: #e8e6ef;
  --steel: #a19eb2;
  --line: rgba(232, 230, 239, 0.12);
  --line-strong: rgba(232, 230, 239, 0.24);
  --font-display: "Organetto", "Arial Narrow", sans-serif;
  --font-body: "Exo 2", system-ui, sans-serif;
  --wrap: 1240px;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --header-h: 76px;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { overflow-x: clip; -webkit-text-size-adjust: 100%; color-scheme: dark; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: var(--void);
  color: var(--platinum);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-weight: 400;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2 { margin: 0; font-weight: 700; }
p { margin: 0 0 1em; }
::selection { background: var(--violet); color: #fff; }
:focus-visible { outline: 2px solid var(--plasma); outline-offset: 3px; border-radius: 4px; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

/* Kosmos-Hintergrund */
.cosmos { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: -1; pointer-events: none; display: block; }
body::before {
  content: ""; position: fixed; inset: 0; z-index: -2;
  background:
    radial-gradient(60vw 50vh at 78% 18%, rgba(139, 92, 246, 0.16), transparent 70%),
    radial-gradient(50vw 60vh at 8% 92%, rgba(80, 40, 160, 0.14), transparent 70%),
    var(--void);
}

/* Metall-Typo */
.metal {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.01em;
  background: linear-gradient(176deg, #ffffff 0%, #e4e1ec 34%, #8f8aa1 50%, #f1eff6 64%, #b9b4c8 100%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  padding-block: .16em .06em; margin-block: -.16em -.06em;
  filter: drop-shadow(0 0 18px rgba(139, 92, 246, 0.28)) drop-shadow(0 1px 0 rgba(166, 107, 255, 0.55));
}

/* Buttons */
.btn {
  --b: var(--line-strong);
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 48px; padding: 0 1.4rem;
  border-radius: 999px; border: 1px solid var(--b);
  font: 600 .98rem/1 var(--font-body); letter-spacing: .02em;
  text-decoration: none; cursor: pointer; color: var(--platinum);
  transition: background-color .25s var(--ease), border-color .25s var(--ease), box-shadow .25s var(--ease), color .25s var(--ease);
}
.btn--primary {
  --b: transparent;
  color: var(--void);
  background: linear-gradient(180deg, #ffffff, #cfcadc);
  box-shadow: 0 0 0 1px rgba(255,255,255,.4) inset, 0 8px 30px -8px rgba(139, 92, 246, .8);
}
.btn--primary:hover { box-shadow: 0 0 0 1px rgba(255,255,255,.6) inset, 0 10px 40px -6px rgba(166, 107, 255, 1); }
.btn--ghost { background: rgba(13, 10, 28, .5); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.btn--ghost:hover { --b: var(--violet); background: rgba(139, 92, 246, .14); }

/* Header: Logo wie auf der Website */
.head { position: absolute; inset: 0 0 auto; z-index: 5; height: var(--header-h); }
.head__inner { height: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); display: flex; align-items: center; }
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; }
.brand__k { width: 40px; height: 40px; filter: drop-shadow(0 0 10px rgba(139,92,246,.5)); }
.brand__word { display: flex; flex-direction: column; gap: 4px; }
.brand__word img { width: 92px; height: auto; }
.brand__labs { font-size: .62rem; letter-spacing: .62em; color: var(--steel); line-height: 1; padding-left: .1em; }

/* Fehlermeldung im Fokus */
.err { flex: 1; display: flex; align-items: center; padding: calc(var(--header-h) + 1.5rem) 0 3rem; }
.err__body { display: flex; flex-direction: column; align-items: flex-start; }
.err__kicker {
  display: inline-flex; align-items: center; gap: .7rem; margin: 0 0 .6rem;
  font-size: .8rem; font-weight: 600; letter-spacing: .34em; text-transform: uppercase; color: var(--plasma);
}
.err__node {
  width: 9px; height: 9px; border-radius: 50%;
  background: radial-gradient(circle, #fff 0 30%, rgba(205,188,255,.9) 50%, rgba(166,107,255,.5) 100%);
  box-shadow: 0 0 12px 3px rgba(166,107,255,.7);
  animation: node 3.6s ease-in-out infinite;
}
.err__code {
  font-size: clamp(7rem, 32vw, 17rem); line-height: .92;
  background:
    linear-gradient(105deg, transparent 42%, rgba(255,255,255,.85) 50%, rgba(205,188,255,.4) 54%, transparent 62%) 160% 0 / 260% 100% no-repeat,
    linear-gradient(176deg, #ffffff 0%, #e4e1ec 34%, #8f8aa1 50%, #f1eff6 64%, #b9b4c8 100%);
  -webkit-background-clip: text; background-clip: text;
  animation: sweep 8s ease-in-out 1.6s infinite;
}
.err__title {
  margin: 1.1rem 0 0;
  font-family: var(--font-display); text-transform: uppercase; letter-spacing: .02em; line-height: 1.05;
  font-size: clamp(1.9rem, 5vw, 3.2rem); color: var(--platinum);
}
.err__lead { margin: 1.2rem 0 0; max-width: 40rem; color: var(--steel); font-size: clamp(1rem, 1.6vw, 1.18rem); }
.err__lead a { color: var(--plasma); text-underline-offset: .18em; }
.err__lead a:hover { color: #fff; }
.err__actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2.2rem; padding-top: 2rem; border-top: 1px solid var(--line); width: min(100%, 40rem); }
.err__meta { margin: 1.4rem 0 0; font-size: .82rem; letter-spacing: .08em; color: var(--steel); }
.err__meta span:empty { display: none; }

/* Startseite (Standardseite der Domain): K-Monogramm im Fokus */
.err__body--split { display: grid; grid-template-columns: 1.15fr .85fr; align-items: center; gap: clamp(1.5rem, 5vw, 4rem); }
.err__copy { display: flex; flex-direction: column; align-items: flex-start; }
.err__host { display: inline-block; margin-top: 1.4rem; padding: .35rem .95rem; border: 1px solid var(--line-strong); border-radius: 999px; background: rgba(13,10,28,.55); color: var(--plasma); font-weight: 600; letter-spacing: .04em; font-size: .95rem; word-break: break-all; }
.err__host:empty { display: none; }
.kmark { position: relative; width: min(100%, 440px); justify-self: center; aspect-ratio: 728 / 702; animation: float 9s ease-in-out infinite; --k: url("/error_docs/img/k-mark.webp"); }
.kmark__img { width: 100%; height: 100%; filter: drop-shadow(0 0 40px rgba(139,92,246,.35)); }
.kmark__sweep { position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, transparent 42%, rgba(255,255,255,.75) 50%, rgba(205,188,255,.35) 54%, transparent 62%) no-repeat;
  background-size: 260% 100%; background-position: 160% 0;
  -webkit-mask: var(--k) center / contain no-repeat; mask: var(--k) center / contain no-repeat;
  mix-blend-mode: overlay; animation: sweep 8s ease-in-out 2.4s infinite; }
.kmark__node {
  position: absolute; width: 6%; aspect-ratio: 1; translate: -50% -50%; border-radius: 50%;
  background: radial-gradient(circle, #fff 0 22%, rgba(205,188,255,.85) 36%, rgba(166,107,255,.35) 58%, transparent 72%);
  mix-blend-mode: screen; opacity: .35; animation: node 3.6s ease-in-out infinite;
}
.kmark__node--1 { left: 33.9%; top: 32.3%; }
.kmark__node--2 { left: 33%; top: 54.4%; width: 7%; animation-delay: .35s; }
.kmark__node--3 { left: 30.6%; top: 78.3%; width: 5.5%; animation-delay: .7s; }

/* Footer */
.foot { position: relative; z-index: 5; border-top: 1px solid var(--line); background: rgba(5,4,10,.72); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.foot__inner { max-width: var(--wrap); margin-inline: auto; padding: 1.1rem var(--gutter); display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 1.5rem; color: var(--steel); font-size: .85rem; }
.foot a { color: var(--steel); text-decoration: none; transition: color .2s; }
.foot a:hover { color: var(--platinum); }

/* Animationen */
@keyframes sweep { 0% { background-position: 160% 0, 0 0; } 45%, 100% { background-position: -60% 0, 0 0; } }
@keyframes node { 0%, 100% { opacity: .3; scale: 1; } 18% { opacity: 1; scale: 1.7; } 40% { opacity: .45; scale: 1.05; } }
@keyframes float { 50% { transform: translateY(-14px); } }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.err__kicker, .err__title, .err__lead, .err__actions, .err__meta, .err__host { animation: rise 1s var(--ease) both; }
.err__title { animation-delay: .12s; }
.err__lead { animation-delay: .22s; }
.err__host { animation-delay: .26s; }
.err__actions { animation-delay: .32s; }
.err__meta { animation-delay: .4s; }
.err__code { animation: rise 1.1s var(--ease) both, sweep 8s ease-in-out 1.6s infinite; }

@media (max-width: 860px) {
  .err__body--split { grid-template-columns: 1fr; }
  .kmark { order: -1; width: min(52vw, 240px); justify-self: start; }
}
@media (max-width: 520px) {
  .err { align-items: flex-start; }
  .err__actions .btn { flex: 1 1 100%; }
  .foot__inner { justify-content: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

.err__title--lg { color: transparent; margin: 0; font-size: clamp(2.4rem, 6.4vw, 4.6rem); }
