/* High-contrast, large-type, keyboard-first. */

:root {
  --bg: #101014;
  --fg: #f2f2f2;
  --accent: #ffd75e;
  --button-bg: #23232b;
  --button-border: #4a4a58;
}

* { box-sizing: border-box; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: system-ui, sans-serif;
  font-size: 1.25rem;
  line-height: 1.5;
  max-width: 42rem;
  margin: 0 auto;
  padding: 1rem;
}

h1 { color: var(--accent); font-size: 1.6rem; }
h1 small { font-size: 0.9rem; color: var(--fg); opacity: 0.6; }
h2:focus, h3:focus { outline: none; }

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

button, input, select {
  font: inherit;
  color: var(--fg);
  background: var(--button-bg);
  border: 2px solid var(--button-border);
  border-radius: 0.5rem;
  padding: 0.6em 1em;
}

button { cursor: pointer; min-height: 48px; }
button:hover { border-color: var(--accent); }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.button-column {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin: 1rem 0;
}
.button-column button { text-align: left; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

#status {
  display: flex;
  gap: 1.5rem;
  font-weight: bold;
  color: var(--accent);
  min-height: 1.5em;
}

#prompt {
  font-size: 1.6rem;
  min-height: 3em;
  margin: 1rem 0;
}

#answer-form {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}
#answer-input { flex: 1; min-width: 12rem; }

#riddle-controls {
  display: flex;
  gap: 0.75rem;
  margin-top: 1rem;
}

#pause-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.setting-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  margin: 1rem 0;
}
.setting-row label { flex: 1; }

#screen-settings button, #screen-help button { margin-top: 1rem; }

@media (prefers-reduced-motion: no-preference) {
  button { transition: border-color 120ms; }
}
