:root {
  --bg: #0a0e14;
  --bg-panel: #0e141f;
  --green: #5cff8f;
  --green-dim: #2f8f55;
  --amber: #ffcf5c;
  --red: #ff6b6b;
  --blue: #6cb6ff;
  --text: #c8d3e0;
  --muted: #6b7a8d;
  --line: #1c2733;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "SFMono-Regular", "JetBrains Mono", "Fira Code", Consolas, monospace;
  font-size: 16px;
  line-height: 1.6;
}

body {
  background-image:
    radial-gradient(circle at 20% 0%, rgba(92,255,143,0.06), transparent 40%),
    radial-gradient(circle at 80% 100%, rgba(108,182,255,0.06), transparent 40%);
  min-height: 100vh;
}

.wrap {
  max-width: 820px;
  margin: 0 auto;
  padding: 32px 20px 80px;
}

header.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
  margin-bottom: 28px;
}

.brand {
  color: var(--green);
  font-weight: 700;
  letter-spacing: 1px;
}
.brand .blink {
  animation: blink 1.1s steps(2, start) infinite;
}
@keyframes blink { to { opacity: 0; } }

.progress {
  display: flex;
  gap: 6px;
  align-items: center;
}
.pip {
  width: 26px;
  height: 6px;
  border-radius: 3px;
  background: var(--line);
}
.pip.done { background: var(--green); box-shadow: 0 0 8px rgba(92,255,143,0.5); }
.pip.active { background: var(--amber); }

.panel {
  background: var(--bg-panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 26px 28px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.35);
}

h1, h2 { color: var(--green); margin-top: 0; }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.2rem; }
.kicker {
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.75rem;
  margin-bottom: 4px;
}

a { color: var(--blue); }

pre.code, pre.xml {
  background: #060a10;
  border: 1px solid var(--line);
  border-left: 3px solid var(--green-dim);
  border-radius: 6px;
  padding: 16px 18px;
  overflow-x: auto;
  font-size: 0.9rem;
  color: #aeb9c7;
  white-space: pre;
}
pre .tag { color: var(--blue); }
pre .attr { color: var(--amber); }
pre .val { color: var(--green); }
pre .com { color: var(--muted); font-style: italic; }

.hint {
  color: var(--muted);
  font-size: 0.9rem;
  border-left: 2px solid var(--line);
  padding-left: 12px;
  margin: 18px 0;
}

form.answer {
  margin-top: 24px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
input[type="text"] {
  flex: 1;
  min-width: 240px;
  background: #060a10;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--green);
  padding: 12px 14px;
  font-family: inherit;
  font-size: 1rem;
}
input[type="text"]:focus {
  outline: none;
  border-color: var(--green-dim);
  box-shadow: 0 0 0 2px rgba(92,255,143,0.15);
}
button, .btn {
  background: var(--green);
  color: #04130a;
  border: none;
  border-radius: 6px;
  padding: 12px 22px;
  font-family: inherit;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}
button:hover, .btn:hover { filter: brightness(1.1); }
.btn.ghost {
  background: transparent;
  color: var(--green);
  border: 1px solid var(--green-dim);
}

.flash {
  border-radius: 6px;
  padding: 12px 16px;
  margin-bottom: 18px;
  font-size: 0.92rem;
}
.flash.error { background: rgba(255,107,107,0.1); border: 1px solid var(--red); color: var(--red); }
.flash.info  { background: rgba(108,182,255,0.1); border: 1px solid var(--blue); color: var(--blue); }

.footer {
  margin-top: 32px;
  color: var(--muted);
  font-size: 0.8rem;
  text-align: center;
}
.footer a { color: var(--muted); }

.reveal {
  text-align: center;
  padding: 20px 0;
}
.reveal .big {
  font-size: 2rem;
  color: var(--green);
  text-shadow: 0 0 24px rgba(92,255,143,0.4);
  margin: 10px 0;
}
.reveal .when {
  font-size: 1.4rem;
  color: var(--amber);
}
.reveal .where {
  font-size: 1.1rem;
  color: var(--blue);
}
.hidden-decoy { display: none; }

/* ---- Boot-Sequenz ---- */
.boot {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  background-image:
    radial-gradient(circle at 20% 0%, rgba(92,255,143,0.06), transparent 40%),
    radial-gradient(circle at 80% 100%, rgba(108,182,255,0.06), transparent 40%);
  cursor: pointer;
  transition: opacity 0.6s ease;
}
.boot.done { opacity: 0; pointer-events: none; }
.boot.hide { display: none; }

.boot-inner {
  width: min(640px, 88vw);
  padding: 0 8px;
}
.boot-log {
  margin: 0;
  color: var(--green);
  font-family: inherit;
  font-size: 0.95rem;
  line-height: 1.7;
  white-space: pre-wrap;
  text-shadow: 0 0 8px rgba(92,255,143,0.35);
  min-height: 13.5em;
}
.boot-log .caret {
  display: inline-block;
  animation: blink 1.05s steps(2, start) infinite;
}
.boot-skip {
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 1px;
}

/* ---- Lade-Overlay ---- */
.overlay {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(4, 7, 12, 0.82);
  backdrop-filter: blur(4px);
  z-index: 999;
}
.overlay.show { display: flex; }

.overlay-box {
  text-align: center;
  background: var(--bg-panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 34px 44px;
  box-shadow: 0 12px 60px rgba(0,0,0,0.6);
  min-width: 320px;
}
.overlay-title {
  color: var(--green);
  font-weight: 700;
  margin-top: 18px;
  font-size: 1.05rem;
}
.overlay-status {
  color: var(--muted);
  font-size: 0.88rem;
  margin-top: 6px;
  min-height: 1.2em;
}

.spinner {
  width: 46px;
  height: 46px;
  margin: 0 auto;
  border: 4px solid var(--line);
  border-top-color: var(--green);
  border-right-color: var(--green-dim);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.overlay-bar {
  margin-top: 20px;
  height: 6px;
  width: 240px;
  background: var(--line);
  border-radius: 3px;
  overflow: hidden;
}
.overlay-bar span {
  display: block;
  height: 100%;
  width: 40%;
  background: linear-gradient(90deg, var(--green-dim), var(--green));
  border-radius: 3px;
  animation: slide 1.1s ease-in-out infinite;
}
@keyframes slide {
  0%   { transform: translateX(-110%); }
  100% { transform: translateX(360%); }
}
