/* --- Reset and base --- */
html, body {
  min-height: 100dvh;
}
body {
  margin: 0;
  font-family: sans-serif;
  background: #121212;
  color: #f4f4f4;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* Background image layer */
.background {
  position: fixed;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: -1;
  pointer-events: none;
}

/* Container */
.container {
  max-width: 800px;
  margin: clamp(12px, 4vh, 32px) auto;
  padding:
    clamp(16px, 3vh, 28px)
    clamp(12px, 4vw, 24px)
    calc(16px + env(safe-area-inset-bottom));
  text-align: center;
  background: rgba(0, 0, 0, 0.40);
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.6);
  backdrop-filter: blur(6px);
}

h1 {
  margin: 0 0 1rem 0;
  font-size: clamp(22px, 6vw, 42px);
  line-height: 1.1;
}

#excuse-box {
  margin: 1rem 0 1.25rem;
  padding: clamp(12px, 2.5vh, 18px);
  font-size: clamp(18px, 4.2vw, 28px);
  line-height: 1.25;
  color: #f0f0f0;
  border: 2px dashed #aaa;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(4px);
}

.controls-row {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
  justify-content: center;
  align-items: center;
}

button, select {
  font-size: clamp(14px, 3.8vw, 18px);
}

button {
  padding: 0.8rem 1.2rem;
  background-color: #0077cc;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
}
button:hover { background-color: #005fa3; }

.voice-wrap select {
  padding: .55rem .75rem;
  border-radius: .5rem;
  background: #111;
  color: #fff;
  border: 1px solid #444;
}

.toggle-container {
  margin-top: 1rem;
  font-size: 0.95rem;
}
.toggle-container input[type="checkbox"] {
  transform: scale(1.2);
  margin-right: 0.5rem;
}

@media (max-width: 420px) {
  .container { padding-left: 14px; padding-right: 14px; }
}