/* Farben, Schriften, Maße */
:root {
  color-scheme: dark;

  --bg:        #06070e;
  --panel:     #12141f;
  --panel-hi:  #191c2b;
  --line:      #272c40;
  --line-soft: #1b1f2f;

  --ink:       #e8eaf4;
  --muted:     #8e94ae;
  --dim:       #5c6280;

  --pink:      #ff2e88;
  --cyan:      #25e2ff;
  --sodium:    #ffb23f;
  --green:     #2ee88a;
  --red:       #ff4f6b;
  --violet:    #9d5cff;

  --hit-bg:    rgba(46, 232, 138, .12);
  --hit-line:  rgba(46, 232, 138, .55);
  --hit-ink:   #8bf5c2;

  --near-bg:   rgba(255, 178, 63, .12);
  --near-line: rgba(255, 178, 63, .5);
  --near-ink:  #ffd396;

  --miss-bg:   rgba(255, 79, 107, .09);
  --miss-line: rgba(255, 79, 107, .34);
  --miss-ink:  #ffa3b2;

  --void-bg:   rgba(140, 148, 178, .07);
  --void-line: rgba(140, 148, 178, .26);
  --void-ink:  #9aa0ba;

  --far-bg:    rgba(157, 92, 255, .12);
  --far-line:  rgba(157, 92, 255, .45);
  --far-ink:   #c9a8ff;

  --radius:     12px;
  --radius-sm:  8px;
  --gap:        clamp(14px, 2.6vw, 22px);
  --pad:        clamp(.85rem, 2.1vw, 1.15rem);

  --shadow:
    0 1px 0 rgba(255, 255, 255, .045) inset,
    0 18px 40px rgba(0, 0, 0, .45);

  --display: "Bahnschrift", "Arial Narrow", "Avenir Next Condensed",
             "Liberation Sans Narrow", "Segoe UI", system-ui, sans-serif;
  --sans:    ui-sans-serif, "Segoe UI Variable Text", "Segoe UI", Roboto,
             "Helvetica Neue", Arial, sans-serif;
  --mono:    ui-monospace, "Cascadia Mono", "SF Mono", "Segoe UI Mono",
             Consolas, monospace;
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  background: var(--bg);
}

/* Untergrund */
body {
  margin: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  min-height: 100dvh;
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  inset: -25%;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(38% 42% at 22% 18%, rgba(255, 46, 136, .22), transparent 70%),
    radial-gradient(42% 46% at 82% 78%, rgba(37, 226, 255, .16), transparent 72%),
    radial-gradient(50% 50% at 55% 105%, rgba(157, 92, 255, .14), transparent 70%);
  animation: drift 46s ease-in-out infinite alternate;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: .5;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='.42'/%3E%3C/svg%3E"),
    repeating-linear-gradient(180deg,
      rgba(255, 255, 255, .016) 0 1px, transparent 1px 3px);
}

@keyframes drift {
  from { transform: translate3d(-2%, -1.5%, 0) scale(1); }
  to   { transform: translate3d(2.5%, 2%, 0) scale(1.06); }
}

.wrap {
  width: min(100% - 1.75rem, 1100px);
  margin-inline: auto;
}

main.wrap { padding-top: var(--gap); }

::selection {
  background: rgba(255, 46, 136, .32);
  color: #fff;
}

/* Header */
.top {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(9, 10, 18, .92), rgba(9, 10, 18, .72));
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--line-soft);
}

.top::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: -1px;
  height: 2px;
  background:
    linear-gradient(90deg,
      transparent 0%, var(--pink) 18%, var(--violet) 38%,
      var(--cyan) 58%, var(--pink) 82%, transparent 100%);
  background-size: 220% 100%;
  opacity: .85;
  animation: chase 9s linear infinite;
}

@keyframes chase {
  from { background-position: 0% 0; }
  to   { background-position: 220% 0; }
}

.top__inner {
  display: flex;
  align-items: center;
  gap: .9rem;
  flex-wrap: wrap;
  padding: .85rem 0;
}

/* Schriftzug */
.brand {
  display: flex;
  align-items: center;
  gap: .6rem;
  margin: 0;
  font-family: var(--display);
  font-size: clamp(1.45rem, 4.2vw, 2rem);
  font-weight: 700;
  font-stretch: condensed;
  letter-spacing: .045em;
  text-transform: uppercase;
  line-height: 1;
}

.brand__name {
  color: #ffe9f3;
  text-shadow:
    0 0 1px rgba(255, 255, 255, .9),
    0 0 10px rgba(255, 46, 136, .6),
    0 0 26px rgba(255, 46, 136, .35),
    0 0 60px rgba(255, 46, 136, .18);
  animation: signon 1.5s steps(1, end) 1;
}

@keyframes signon {
  0%, 12%  { opacity: .18; }
  14%      { opacity: 1; }
  18%      { opacity: .25; }
  22%      { opacity: 1; }
  26%      { opacity: .4; }
  30%, 100%{ opacity: 1; }
}

.brand__mark {
  position: relative;
  font-family: var(--mono);
  font-size: .58em;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--cyan);
  background: linear-gradient(180deg, #182034, #0a0e18);
  border: 1px solid rgba(37, 226, 255, .45);
  border-radius: 6px;
  padding: .34em .55em .3em;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .1),
    0 0 14px rgba(37, 226, 255, .28);
  text-shadow: 0 0 8px rgba(37, 226, 255, .7);
}
.brand__mark::before,
.brand__mark::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: rgba(37, 226, 255, .5);
  translate: 0 -50%;
}
.brand__mark::before { left: 3px; }
.brand__mark::after  { right: 3px; }

.brand__sub {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  margin: 0;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}
.brand__sub::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: blip 2.6s ease-in-out infinite;
}
@keyframes blip {
  0%, 100% { opacity: 1; }
  50%      { opacity: .3; }
}

/* Panels */
.viewer,
.guessbox,
.board,
.result {
  position: relative;
  margin-bottom: var(--gap);
  padding: var(--pad);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(25, 28, 43, .74), rgba(14, 16, 26, .78));
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.guessbox { z-index: 30; }

.eyebrow {
  margin: 0 0 .6rem;
  font-family: var(--mono);
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--dim);
}

/* Umschalter Fahrzeug/Preis */
.games {
  display: flex;
  gap: .4rem;
  margin-bottom: var(--gap);
  padding: 4px;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  background: rgba(12, 14, 22, .7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  width: fit-content;
  max-width: 100%;
}

.game {
  font: inherit;
  font-family: var(--display);
  font-size: .95rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: .5rem 1.15rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: color .18s ease, background .18s ease, box-shadow .18s ease;
}
.game:hover { color: var(--ink); background: rgba(255, 255, 255, .04); }
.game[aria-pressed="true"] {
  color: #fff;
  background: linear-gradient(180deg, rgba(255, 46, 136, .95), rgba(198, 24, 104, .95));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .28),
    0 0 18px rgba(255, 46, 136, .45);
}

/* Knöpfe */
.btn {
  position: relative;
  font: inherit;
  font-size: .88rem;
  font-weight: 650;
  padding: .55rem 1.05rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 46, 136, .55);
  background: linear-gradient(180deg, rgba(255, 46, 136, .92), rgba(190, 22, 100, .92));
  color: #fff;
  cursor: pointer;
  transition: transform .12s ease, box-shadow .2s ease, filter .2s ease;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .25),
    0 0 0 rgba(255, 46, 136, 0);
}
.btn:hover {
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .3),
    0 6px 22px rgba(255, 46, 136, .38);
}
.btn:active { transform: translateY(1px); filter: brightness(.92); }

.btn--ghost {
  background: rgba(255, 255, 255, .03);
  border-color: var(--line);
  color: var(--cyan);
  box-shadow: none;
}
.btn--ghost:hover {
  border-color: rgba(37, 226, 255, .5);
  background: rgba(37, 226, 255, .08);
  box-shadow: 0 4px 18px rgba(37, 226, 255, .18);
}

.btn--small {
  font-size: .78rem;
  font-weight: 600;
  padding: .36rem .8rem;
}

/* Eingabefeld */
.combo { position: relative; }

#search {
  width: 100%;
  font: inherit;
  font-size: 1.05rem;
  padding: .85rem 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(6, 8, 14, .75);
  color: var(--ink);
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, .5);
}
#search::placeholder { color: var(--dim); }
#search:hover { border-color: rgba(37, 226, 255, .3); }
#search:focus-visible {
  outline: none;
  border-color: rgba(37, 226, 255, .7);
  background: rgba(8, 12, 20, .85);
  box-shadow:
    inset 0 2px 8px rgba(0, 0, 0, .5),
    0 0 0 3px rgba(37, 226, 255, .16),
    0 0 24px rgba(37, 226, 255, .2);
}
#search:disabled { opacity: .45; cursor: not-allowed; }

/* Vorschlagsliste */
.suggest {
  position: absolute;
  z-index: 20;
  inset-inline: 0;
  top: calc(100% + 6px);
  margin: 0;
  padding: 5px;
  list-style: none;
  max-height: 20rem;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: rgba(14, 16, 26, .97);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  box-shadow: 0 24px 48px rgba(0, 0, 0, .6);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  animation: dropin .16s cubic-bezier(.2, .8, .3, 1);
}

@keyframes dropin {
  from { opacity: 0; transform: translateY(-8px) scale(.99); }
  to   { opacity: 1; transform: none; }
}

.suggest li {
  position: relative;
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .45rem .6rem;
  border-radius: 6px;
  cursor: pointer;
  transition: background .12s ease;
}
.suggest li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 18%;
  bottom: 18%;
  width: 2px;
  border-radius: 2px;
  background: var(--cyan);
  opacity: 0;
  transition: opacity .12s ease;
}
.suggest li[aria-selected="true"],
.suggest li:hover {
  background: rgba(37, 226, 255, .09);
}
.suggest li[aria-selected="true"]::before,
.suggest li:hover::before { opacity: 1; box-shadow: 0 0 10px var(--cyan); }

.suggest img {
  width: 56px;
  height: 34px;
  object-fit: cover;
  border-radius: 4px;
  background: var(--panel-hi);
  border: 1px solid var(--line-soft);
  flex: none;
}

.suggest b { font-weight: 650; }
.suggest small {
  display: block;
  color: var(--muted);
  font-size: .74rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.suggest::-webkit-scrollbar { width: 8px; }
.suggest::-webkit-scrollbar-track { background: transparent; }
.suggest::-webkit-scrollbar-thumb {
  background: var(--line);
  border-radius: 99px;
}

/* Hinweiszeilen */
.hint {
  margin: .6rem 0 0;
  font-size: .84rem;
  color: var(--muted);
}

.guessfoot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  flex-wrap: wrap;
}
.guessfoot .hint { flex: 1 1 12rem; }

.loading {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  color: var(--muted);
  font-family: var(--mono);
  font-size: .82rem;
  letter-spacing: .06em;
}
.loading::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--sodium);
  box-shadow: 0 0 12px var(--sodium);
  animation: blip 1.1s ease-in-out infinite;
}

/* Bildbereich */
.viewer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: .7rem;
}
.viewer__head .eyebrow { margin-bottom: 0; }

.modes { display: flex; gap: .3rem; }

.mode {
  font: inherit;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .04em;
  padding: .34rem .8rem;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .03);
  color: var(--muted);
  border-radius: 999px;
  cursor: pointer;
  transition: color .16s ease, border-color .16s ease,
              background .16s ease, box-shadow .16s ease;
}
.mode:hover { color: var(--ink); border-color: rgba(37, 226, 255, .4); }
.mode[aria-pressed="true"] {
  color: #061018;
  background: linear-gradient(180deg, #5cecff, var(--cyan));
  border-color: rgba(37, 226, 255, .8);
  box-shadow: 0 0 16px rgba(37, 226, 255, .45);
}

.mode.is-done {
  border-color: rgba(46, 232, 138, .45);
  color: var(--hit-ink);
}
.mode.is-done::after {
  content: "✓";
  margin-left: .4rem;
  font-weight: 700;
}
.mode[aria-pressed="true"].is-done { color: #061018; }

/* Bildrahmen */
.plate-frame {
  position: relative;
  background:
    radial-gradient(120% 110% at 50% 0%, #171b2b 0%, #090b13 70%);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  box-shadow:
    inset 0 0 40px rgba(0, 0, 0, .35),
    inset 0 1px 0 rgba(255, 255, 255, .05);
}

.plate-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(var(--cyan), var(--cyan)) left 10px top 10px / 16px 2px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) left 10px top 10px / 2px 16px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) right 10px top 10px / 16px 2px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) right 10px top 10px / 2px 16px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) left 10px bottom 10px / 16px 2px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) left 10px bottom 10px / 2px 16px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) right 10px bottom 10px / 16px 2px no-repeat,
    linear-gradient(var(--cyan), var(--cyan)) right 10px bottom 10px / 2px 16px no-repeat;
  opacity: .7;
}

.stage__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;

  transform-origin: 50% 50%;
  transition: transform .6s cubic-bezier(.22, .75, .25, 1);
  will-change: transform;
  backface-visibility: hidden;
}

.stage__img[hidden],
.stage__blind[hidden] { display: none; }

.stage__blind {
  margin: 0;
  left: 0;
  right: 0;
  z-index: 2;
  padding: .6rem 1rem;
  text-align: center;
  color: var(--muted);
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .04em;
  background: linear-gradient(180deg,
    rgba(6, 8, 14, 0), rgba(6, 8, 14, .92) 45%) !important;
  max-width: none;
}

/* Ergebnis */
.result {
  overflow: hidden;
  isolation: isolate;
  background: transparent;
  border: 0;
}
.result::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 190%;
  aspect-ratio: 1;
  translate: -50% -50%;
  z-index: -2;
  background: conic-gradient(from 0deg,
    var(--pink), var(--violet), var(--cyan), var(--green), var(--sodium), var(--pink));
  animation: ringspin 8s linear infinite;
}

.result::after {
  content: "";
  position: absolute;
  inset: 1.5px;
  z-index: -1;
  border-radius: calc(var(--radius) - 1px);
  background: linear-gradient(180deg, rgba(19, 21, 33, .97), rgba(11, 13, 21, .97));
}
@keyframes ringspin {
  to { rotate: 360deg; }
}

.result__line {
  margin: 0 0 .85rem;
  font-size: 1.05rem;
}
.result__line b {
  font-weight: 750;
  color: var(--green);
  text-shadow: 0 0 16px rgba(46, 232, 138, .4);
}
.result__actions { display: flex; gap: .5rem; flex-wrap: wrap; }

/* Tabelle */
#game-vehicle .board {
  --bleed: clamp(0px, (100vw - 100% - 3rem) / 2, 15rem);
  width: calc(100% + var(--bleed) * 2);
  margin-inline: calc(var(--bleed) * -1);
}

.scroller {
  overflow-x: auto;
  overscroll-behavior-x: contain;
  padding-bottom: 6px;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.scroller::-webkit-scrollbar { height: 9px; }
.scroller::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, .03);
  border-radius: 99px;
}
.scroller::-webkit-scrollbar-thumb {
  background: linear-gradient(90deg, var(--pink), var(--violet));
  border-radius: 99px;
}

.grid {
  display: grid;
  gap: 5px;
  min-width: min-content;
}

.row {
  display: grid;
  grid-template-columns: var(--cols);
  gap: 5px;
}

.cell {
  padding: .5rem .55rem;
  border-radius: 7px;
  background: rgba(255, 255, 255, .035);
  border: 1px solid var(--line-soft);
  font-size: .82rem;
  line-height: 1.25;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 3.3rem;
  text-align: center;
}

.row--head .cell {
  background: transparent;
  border-color: transparent;
  min-height: 0;
  padding-block: .15rem;
  font-family: var(--mono);
  font-size: .62rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--dim);
}

.cell--name {
  align-items: flex-start;
  text-align: left;
  font-family: var(--mono);
  font-size: .8rem;
  font-weight: 700;
  background: linear-gradient(180deg, #1a1e2e, #101321);
  border: 1px solid var(--line);
  color: var(--ink);
  position: sticky;
  left: 0;
  z-index: 2;
  box-shadow: 6px 0 14px rgba(0, 0, 0, .45);
}
.cell--name.is-hit {
  border-color: var(--hit-line);
  color: var(--hit-ink);
  box-shadow: 6px 0 14px rgba(0, 0, 0, .45), 0 0 22px rgba(46, 232, 138, .3);
}
.cell--name small {
  font-family: var(--sans);
  font-weight: 500;
  letter-spacing: .07em;
  color: var(--muted);
  text-transform: uppercase;
  font-size: .6rem;
}

.cell .val { font-family: var(--mono); font-weight: 600; }
.cell .dir { font-size: 1rem; line-height: 1; opacity: .9; }

.is-hit {
  background: var(--hit-bg);
  border-color: var(--hit-line);
  color: var(--hit-ink);
  box-shadow: inset 0 0 20px rgba(46, 232, 138, .12), 0 0 14px rgba(46, 232, 138, .18);
}
.is-near {
  background: var(--near-bg);
  border-color: var(--near-line);
  color: var(--near-ink);
  box-shadow: inset 0 0 20px rgba(255, 178, 63, .1), 0 0 12px rgba(255, 178, 63, .14);
}
.is-miss {
  background: var(--miss-bg);
  border-color: var(--miss-line);
  color: var(--miss-ink);
}
.is-void {
  background: var(--void-bg);
  border-color: var(--void-line);
  border-style: dashed;
  color: var(--void-ink);
}

.grid .row:nth-child(2) .cell {
  animation: lightup .5s cubic-bezier(.2, .85, .3, 1) backwards;
}
.grid .row:nth-child(2) .cell:nth-child(1)  { animation-delay: 0s; }
.grid .row:nth-child(2) .cell:nth-child(2)  { animation-delay: .06s; }
.grid .row:nth-child(2) .cell:nth-child(3)  { animation-delay: .12s; }
.grid .row:nth-child(2) .cell:nth-child(4)  { animation-delay: .18s; }
.grid .row:nth-child(2) .cell:nth-child(5)  { animation-delay: .24s; }
.grid .row:nth-child(2) .cell:nth-child(6)  { animation-delay: .30s; }
.grid .row:nth-child(2) .cell:nth-child(7)  { animation-delay: .36s; }
.grid .row:nth-child(2) .cell:nth-child(8)  { animation-delay: .42s; }
.grid .row:nth-child(2) .cell:nth-child(9)  { animation-delay: .48s; }
.grid .row:nth-child(2) .cell:nth-child(10) { animation-delay: .54s; }
.grid .row:nth-child(2) .cell:nth-child(11) { animation-delay: .60s; }
.grid .row:nth-child(2) .cell:nth-child(12) { animation-delay: .66s; }

@keyframes lightup {
  0%   { opacity: 0; transform: translateY(8px) scale(.94); filter: brightness(2.6) saturate(.3); }
  55%  { opacity: 1; filter: brightness(1.45) saturate(1.1); }
  100% { opacity: 1; transform: none; filter: none; }
}

/* Legende */
.legend {
  display: flex;
  align-items: center;
  gap: .45rem;
  flex-wrap: wrap;
  margin: .8rem 0 0;
  font-size: .76rem;
  color: var(--muted);
}
.legend em { font-style: normal; margin-left: .3rem; color: var(--dim); }

.key {
  width: .8rem;
  height: .8rem;
  border-radius: 3px;
  display: inline-block;
  border: 1px solid;
}
.key--hit  { background: var(--hit-bg);  border-color: var(--hit-line);  box-shadow: 0 0 8px rgba(46, 232, 138, .5); }
.key--near { background: var(--near-bg); border-color: var(--near-line); box-shadow: 0 0 8px rgba(255, 178, 63, .45); }
.key--miss { background: var(--miss-bg); border-color: var(--miss-line); }
.key--void { background: var(--void-bg); border-color: var(--void-line); border-style: dashed; }
.key--far  { background: var(--far-bg);  border-color: var(--far-line);  box-shadow: 0 0 8px rgba(157, 92, 255, .45); }

/* Preismodus */
.carname {
  display: flex;
  align-items: baseline;
  gap: .6rem;
  flex-wrap: wrap;
  margin: .8rem 0 0;
  font-family: var(--display);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 0 18px rgba(37, 226, 255, .28);
}
.carname small {
  font-family: var(--mono);
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--cyan);
  text-shadow: none;
}

.priceform {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
}

.priceinput {
  flex: 1 1 12rem;
  display: flex;
  align-items: center;
  padding-left: .9rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: rgba(6, 8, 14, .75);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, .5);
  transition: border-color .18s ease, box-shadow .18s ease;
}
.priceinput:focus-within {
  border-color: rgba(46, 232, 138, .7);
  box-shadow:
    inset 0 2px 8px rgba(0, 0, 0, .5),
    0 0 0 3px rgba(46, 232, 138, .14),
    0 0 22px rgba(46, 232, 138, .18);
}
.priceinput__sign {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--green);
  text-shadow: 0 0 10px rgba(46, 232, 138, .5);
}

#pinput {
  flex: 1;
  min-width: 0;
  font: inherit;
  font-family: var(--mono);
  font-size: 1.1rem;
  letter-spacing: .03em;
  padding: .8rem .95rem .8rem .4rem;
  border: 0;
  background: transparent;
  color: var(--ink);
}
#pinput::placeholder { color: var(--dim); }
#pinput:focus-visible { outline: none; }
#pinput:disabled { opacity: .45; }

.priceform .btn { padding-inline: 1.2rem; }

/* Preistippliste */
.plist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 5px;
}

.plist li {
  position: relative;
  display: flex;
  align-items: center;
  gap: .8rem;
  padding: .65rem .9rem .65rem 1.05rem;
  border: 1px solid;
  border-radius: 7px;
  overflow: hidden;
}
.plist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: currentColor;
  opacity: .85;
}
.plist li:first-child {
  animation: lightup .45s cubic-bezier(.2, .85, .3, 1) backwards;
}

.plist .amount {
  font-family: var(--mono);
  font-size: 1.08rem;
  font-weight: 700;
  letter-spacing: .02em;
}
.plist .verdict { font-size: .8rem; opacity: .8; }
.plist .dir {
  margin-left: auto;
  font-family: var(--mono);
  font-size: .82rem;
  font-weight: 650;
  white-space: nowrap;
  opacity: .9;
}

.is-far {
  background: var(--far-bg);
  border-color: var(--far-line);
  color: var(--far-ink);
}

#pempty { margin-top: .6rem; }

/* Fußzeile */
.foot {
  margin-top: calc(var(--gap) * 2);
  padding: 1.4rem 0 2.4rem;
  border-top: 1px solid var(--line-soft);
  font-size: .76rem;
  color: var(--dim);
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, .35));
}
.foot p { margin: .25rem 0; }
.foot a { color: var(--muted); text-decoration-color: var(--line); }
.foot a:hover { color: var(--cyan); }

a { color: var(--cyan); text-underline-offset: 3px; }

:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Kleine Bildschirme */
@media (max-width: 640px) {
  .cell { font-size: .76rem; min-height: 3rem; }
  .plate-frame { aspect-ratio: 4 / 3; }
  .plate-frame::after { background-size:
      12px 2px, 2px 12px, 12px 2px, 2px 12px,
      12px 2px, 2px 12px, 12px 2px, 2px 12px; }
  .games { width: 100%; }
  .game { flex: 1; text-align: center; padding-inline: .6rem; }
  .priceform .btn { flex: 1 1 auto; }
  .carname { font-size: 1.15rem; }
  .top { position: static; }
}

/* Animationen abschalten */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

.brand__mark {
  cursor: default;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

/* Codewort-Fenster */
.secret {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--panel);
  color: var(--ink);
  padding: 1.4rem;
  max-width: min(22rem, calc(100vw - 2rem));
  box-shadow: 0 20px 60px rgba(0, 0, 0, .6);
}

.secret::backdrop {
  background: rgba(4, 5, 10, .72);
  backdrop-filter: blur(2px);
}

.secret__text {
  margin: .5rem 0 1rem;
  font-size: .84rem;
  color: var(--muted);
}

.secret input {
  width: 100%;
  box-sizing: border-box;
  padding: .7rem .85rem;
  font: inherit;
  color: inherit;
  background: rgba(0, 0, 0, .35);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  letter-spacing: .12em;
}

.secret__error {
  margin: .6rem 0 0;
  font-family: var(--mono);
  font-size: .76rem;
  color: var(--red);
}
.secret__error[hidden] { display: none; }

.secret__actions {
  display: flex;
  gap: .6rem;
  margin-top: 1.1rem;
}
.secret__actions .btn { flex: 1; }
