@font-face {
  font-family: "DIN Next";
  src: url("fonts/din-next-light.ttf") format("truetype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "DIN Next", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 300;
  background: #f5f3ef;
  color: #1f2d34;
  line-height: 1.5;
}

.app {
  width: min(920px, calc(100% - 32px));
  margin: 48px auto;
}

header {
  margin-bottom: 24px;
}

h1 {
  margin: 0 0 8px;
  font-size: clamp(2.2rem, 5vw, 4rem);
  font-weight: 300;
  letter-spacing: -0.04em;
}

h2 {
  margin-top: 0;
  font-size: 2rem;
  font-weight: 300;
  letter-spacing: -0.03em;
}

p {
  font-size: 1.08rem;
}

.card {
  background: rgba(255, 255, 255, 0.86);
  border-radius: 22px;
  padding: 32px;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.08);
}

.hidden {
  display: none;
}

label {
  display: grid;
  gap: 8px;
  margin: 18px 0;
  max-width: 360px;
  font-size: 1.05rem;
}

input,
select,
button,
textarea {
  font-family: "DIN Next", system-ui, sans-serif;
  font-weight: 300;
}

input[type="number"],
select {
  width: 100%;
  padding: 12px 14px;
  font-size: 1.05rem;
  border: 1px solid #d8d2c8;
  border-radius: 12px;
  background: #fffdf8;
  color: #1f2d34;
}

select:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

button {
  border: 0;
  border-radius: 999px;
  padding: 13px 22px;
  font-size: 1.05rem;
  cursor: pointer;
  background: #e6e1d8;
  color: #1f2d34;
  transition: transform 0.12s ease, opacity 0.12s ease;
}

button:hover {
  transform: translateY(-1px);
}

button.primary,
#startBtn {
  background: #1f4f6f;
  color: white;
}

button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.hint {
  color: #6b6258;
  margin-top: 18px;
}

.topline {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: #6b6258;
  margin-bottom: 18px;
  font-size: 1rem;
}

#questionText {
  font-size: 1.55rem;
  line-height: 1.4;
  margin-bottom: 22px;
}

.answer {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  margin: 12px 0;
  border: 1px solid #ddd5ca;
  border-radius: 14px;
  background: #fffdf8;
}

.answer input {
  margin-top: 6px;
}

.answer label {
  margin: 0;
  max-width: none;
  display: block;
  cursor: pointer;
}

.buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.resultItem {
  border-top: 1px solid #ddd5ca;
  padding: 18px 0;
}

.correct {
  color: #176b3a;
  font-weight: 700;
}

.wrong {
  color: #a62828;
  font-weight: 700;
}

#score {
  font-size: 1.35rem;
}

#status {
  margin-top: 0;
  color: #4d5b60;
}

.error,
.fehler {
  background: #ffe0e0;
  color: #7a0000;
  padding: 18px;
  border-radius: 12px;
  white-space: pre-wrap;
}

@media (max-width: 640px) {
  .app {
    width: min(100% - 24px, 920px);
    margin: 28px auto;
  }

  .card {
    padding: 24px;
  }

  h1 {
    font-size: 2.4rem;
  }

  h2 {
    font-size: 1.6rem;
  }

  .topline {
    flex-direction: column;
    gap: 4px;
  }
}