/* Beta-Zugang Norwyn: Key-Seite im Stil des Spiels (Rankenrahmen, Holzbrett, Goldknopf, Pixelschrift).
   Bewusst nur dunkel, wie Norwyn selbst. Grafiken aus Norwyn Online (public/assets). */
@font-face { font-family: "Minecraft"; src: url("Minecraft.ttf?v=1") format("truetype"); font-display: swap; }
:root {
  color-scheme: dark;
  --w-ink: #3d2936;
  --w-wine: #8f4d57;
  --w-cream: #ffe9dc;
  --w-text2: #efc2b4;
  --gold: #f0b541;
  --gold-lt: #ffee83;
  --leaf: #9fdc6f;
  --rose: #ff9c8a;
  --w-outline: 2px 0 0 var(--w-ink), -2px 0 0 var(--w-ink), 0 2px 0 var(--w-ink), 0 -2px 0 var(--w-ink);
  --font-pixel: "Minecraft", ui-monospace, "SF Mono", Menlo, monospace;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { min-height: 100%; background: #141220; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: max(28px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(34px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  font: 14px/1.45 var(--font-pixel);
  color: var(--w-cream);
  background:
    radial-gradient(ellipse 85% 75% at 50% 35%, rgba(12, 10, 20, 0) 0%, rgba(8, 7, 14, .7) 100%),
    linear-gradient(rgba(14, 12, 22, .45), rgba(14, 12, 22, .72)),
    url("hero.jpg?v=1") center / cover no-repeat, #141220;
  image-rendering: pixelated;
  -webkit-text-size-adjust: 100%;
}
h1, h2, p { margin: 0; }
a { color: var(--gold-lt); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

.n-stack { width: 100%; max-width: 380px; display: grid; justify-items: center; gap: 18px; }
.n-logo { width: 190px; max-width: 60%; height: auto; display: block; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .55)); }
.tor-begleiter .n-logo { width: 170px; border-radius: 26px; background: #18291f; box-shadow: 0 0 0 4px #5b3a49; }
.n-panel {
  width: 100%;
  border: 4px solid transparent;
  border-image: url("frame.png?v=1") 16 fill / 16px / 10px round;
  padding: 22px 16px 16px;
  display: grid;
  gap: 12px;
  color: var(--w-cream);
}
.n-plank {
  justify-self: start;
  border: 4px solid transparent;
  border-image: url("banner.png?v=1") 9 12 13 12 fill / 18px 24px 26px 24px / 8px 6px 16px 6px stretch;
  padding: 2px 14px 6px;
  margin: -30px 0 2px -8px;
  color: var(--gold);
  font: 15px/1.45 var(--font-pixel);
  text-transform: uppercase;
  letter-spacing: .05em;
  text-shadow: var(--w-outline);
}
.n-panel p { color: var(--w-text2); font-size: 12px; }
.n-label { color: var(--gold); font-size: 12px; display: block; margin-bottom: -6px; }
.n-input {
  width: 100%;
  min-height: 48px;
  padding: 8px 12px;
  font: 22px var(--font-pixel);
  letter-spacing: .08em;
  text-align: center;
  background: var(--w-cream);
  color: var(--w-ink);
  border: 2px solid var(--w-ink);
  box-shadow: inset 2px 2px 0 rgba(143, 77, 87, .3);
  border-radius: 0;
  -webkit-appearance: none;
  appearance: none;
}
.n-input::placeholder { color: rgba(61, 41, 54, .35); }
.n-input:focus { outline: 2px solid var(--gold); outline-offset: 0; }
.n-input[aria-invalid="true"] { border-color: #b4232f; }
.n-input:disabled { opacity: .6; }
.n-input--text { font-size: 16px; letter-spacing: .02em; text-align: left; min-height: 42px; }
.n-message { min-height: 18px; font-size: 12px; color: var(--rose) !important; text-shadow: var(--w-outline); }
.n-message:empty { min-height: 0; margin-top: -12px; }
.n-message a { color: var(--gold-lt); }
.n-btn {
  width: 100%;
  min-height: 46px;
  padding: 4px 18px 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font: 16px var(--font-pixel);
  color: #4a2400;
  text-decoration: none;
  text-align: center;
  text-shadow: 0 1px 0 rgba(255, 245, 200, .6);
  background: transparent;
  border: 2px solid transparent;
  border-image: url("button-gold.png?v=1") 6 fill / 12px stretch;
  -webkit-tap-highlight-color: transparent;
}
.n-btn:active:not(:disabled) { border-image-source: url("button-gold-down.png?v=1"); transform: translateY(1px); }
.n-btn:disabled, .n-btn[aria-busy="true"] { filter: grayscale(.6) opacity(.55); cursor: default; }
.n-btn--stone { filter: hue-rotate(-28deg) saturate(.55) brightness(.92); font-size: 14px; min-height: 40px; }
.n-small { font-size: 11px !important; color: #e8b9ab !important; }
.n-or { display: flex; align-items: center; gap: 10px; color: var(--w-text2); font-size: 11px !important; margin-top: 2px; }
.n-or::before, .n-or::after { content: ""; flex: 1; height: 2px; background: rgba(61, 41, 54, .55); }
.n-link { padding: 4px 0; font: 12px var(--font-pixel); color: var(--gold-lt); text-decoration: underline; text-underline-offset: 3px; justify-self: center; }
.n-done { display: grid; gap: 12px; justify-items: center; text-align: center; padding: 8px 0 4px; }
.n-done strong { font-size: 18px; font-weight: normal; color: var(--gold); text-shadow: var(--w-outline); overflow-wrap: anywhere; }
.n-done p { color: var(--w-text2); font-size: 12px; }
.n-bar { width: 100%; height: 12px; border: 2px solid var(--w-ink); background: #3a2430; position: relative; overflow: hidden; }
.n-bar::after { content: ""; position: absolute; inset: 0; width: 0; background: linear-gradient(#9fdc6f, #63ab3f); animation: fill 1.6s steps(12) forwards; }
@keyframes fill { to { width: 100%; } }
@media (prefers-reduced-motion: reduce) { .n-bar::after { animation: none; width: 100%; } }
@media (max-width: 460px) {
  .n-input:not(.n-input--text) { font-size: 18px; letter-spacing: .03em; padding-inline: 8px; }
}
