:root {
  --bg: #111111;
  --panel: #1a1a1a;
  --panel-2: #222222;
  --border: #4a4a4a;
  --border-soft: #333333;
  --text: #eeeeee;
  --muted: #b9b9b9;
  --ok: #9fd39f;
  --warn: #d6c58a;
  --bad: #ff9d9d;
  --link: #9fc3ff;
  --focus: #d8d8d8;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
  --radius: 0;
  --content-width: 58rem;
  --input-width: 42rem;
  --gap: 1rem;
  --font-ui: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

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

html {
  color-scheme: dark;
}

body {
  margin: 0;
  padding: 2rem;
  background:
    linear-gradient(rgba(255,255,255,0.02), rgba(255,255,255,0.02)),
    var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  line-height: 1.5;
}

main,
body > * {
  max-width: var(--content-width);
}

h1,
h2,
h3 {
  margin: 0 0 0.6rem;
  line-height: 1.2;
  font-weight: 600;
}

h1 {
  font-size: clamp(1.7rem, 2.5vw, 2.4rem);
  letter-spacing: 0.01em;
}

h2 {
  font-size: 1.15rem;
  color: var(--text);
}

p {
  margin: 0.4rem 0 0.8rem;
}

a {
  color: var(--link);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

.box {
  background: linear-gradient(180deg, var(--panel), #171717);
  border: 1px solid var(--border);
  padding: 1.1rem 1.1rem 1rem;
  margin: 1rem 0;
  box-shadow: var(--shadow);
}

.box + .box {
  margin-top: 1.2rem;
}

.muted {
  color: var(--muted);
}

label {
  display: block;
  margin: 0.9rem 0 0.3rem;
  font-size: 0.98rem;
  color: var(--text);
}

input,
select,
button,
textarea {
  width: 100%;
  max-width: var(--input-width);
  min-height: 2.8rem;
  padding: 0.72rem 0.8rem;
  border: 1px solid var(--border);
  background: var(--panel-2);
  color: var(--text);
  font: inherit;
  border-radius: var(--radius);
  appearance: none;
  -webkit-appearance: none;
}

input[type="checkbox"] {
  appearance: auto;
  -webkit-appearance: checkbox;
  accent-color: #d0d0d0;
}

input::placeholder,
textarea::placeholder {
  color: #8e8e8e;
}

input:hover,
select:hover,
textarea:hover {
  border-color: #6a6a6a;
}

input:focus,
select:focus,
textarea:focus,
button:focus,
a:focus {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

button {
  cursor: pointer;
  background:
    linear-gradient(180deg, #2a2a2a, #1f1f1f);
  border-color: #666666;
  color: var(--text);
  font-weight: 600;
  transition:
    background 120ms ease,
    border-color 120ms ease,
    transform 120ms ease;
}

button:hover {
  background: linear-gradient(180deg, #303030, #232323);
  border-color: #8a8a8a;
}

button:active {
  transform: translateY(1px);
}

button[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.wichtig {
  display: inline-block;
  padding: 0.15rem 0.4rem;
  margin: 0 0.1rem;
  background: linear-gradient(180deg, #2a2620, #1e1b17);
  border: 1px solid #6f6245;
  color: #f2e6c9;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.wichtig.block {
  display: block;
  margin: 0.6rem 0;
  padding: 0.6rem 0.7rem;
  background: linear-gradient(180deg, #2c281f, #201d17);
  border-left: 3px solid #c8b27a;
}


.slot {
  display: block;
  width: 100%;
  text-align: left;
  margin: 0.45rem 0;
  padding: 0.85rem 0.95rem;
  background: linear-gradient(180deg, #222222, #1d1d1d);
  color: var(--text);
  border: 1px solid #5b5b5b;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
}

.slot:hover {
  background: linear-gradient(180deg, #292929, #212121);
}

.slot.selected {
  border-color: #bdbdbd;
  outline: 2px solid rgba(230, 230, 230, 0.45);
  outline-offset: 1px;
  background: linear-gradient(180deg, #323232, #262626);
}

.inline-check {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  max-width: var(--input-width);
  margin: 1rem 0 0.3rem;
  padding: 0.2rem 0;
}

.inline-check input[type="checkbox"] {
  width: 1.1rem;
  min-width: 1.1rem;
  max-width: 1.1rem;
  min-height: 1.1rem;
  height: 1.1rem;
  margin: 0.18rem 0 0;
  padding: 0;
  border: 1px solid var(--border);
  background: var(--panel-2);
  accent-color: #d0d0d0;
}

.inline-check label {
  margin: 0;
  line-height: 1.4;
  color: var(--muted);
}

.msg {
  margin-top: 0.45rem;
  min-height: 1.25rem;
  font-size: 0.94rem;
}

.ok {
  color: var(--ok);
}

.bad {
  color: var(--bad);
}

.warn {
  color: var(--warn);
}

.msg.muted {
  color: var(--muted);
}

.hidden {
  display: none !important;
}

hr {
  border: 0;
  border-top: 1px solid var(--border-soft);
  margin: 1.2rem 0;
}

#slots {
  min-height: 2rem;
}

#status {
  margin-top: 1rem;
  padding-top: 0.2rem;
}

#drvLink {
  display: inline-block;
  margin-top: 0.2rem;
}

#successOverlay {
  backdrop-filter: blur(2px);
}

#successOverlay > div {
  box-shadow: 0 14px 42px rgba(0,0,0,0.42);
}

#successOverlayBody p {
  margin: 0.45rem 0;
}

code,
pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

@media (max-width: 720px) {
  body {
    padding: 1rem;
  }

  .box {
    padding: 0.95rem 0.9rem 0.9rem;
  }

  input,
  select,
  button,
  textarea {
    max-width: 100%;
  }

  .inline-check {
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}