:root {
  color: #1c1917;
  background: #f6f3ee;
  font-family: "Segoe UI", system-ui, sans-serif;
  line-height: 1.45;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
}

main {
  width: min(40rem, calc(100% - 2rem));
  margin: 0 auto;
  padding: 2rem 0 3rem;
}

h1 {
  font-family: Georgia, "Iowan Old Style", serif;
  font-size: 2rem;
  font-weight: 600;
  margin: 0 0 0.4rem;
}

.lede, .idea, .nota {
  margin: 0 0 1rem;
}

.nota { color: #57534e; }

form { display: grid; gap: 0.7rem; }

label { font-weight: 650; }

input, textarea, button {
  font: inherit;
}

input, textarea {
  width: 100%;
  border: 1px solid #d6d3d1;
  border-radius: 0.6rem;
  background: #fff;
  padding: 0.75rem 0.8rem;
}

textarea {
  min-height: 9rem;
  resize: vertical;
  font-family: Consolas, "Courier New", monospace;
}

button, .text-button {
  border: 0;
  border-radius: 999px;
  padding: 0.75rem 1rem;
  background: #1c1917;
  color: #fff;
  cursor: pointer;
}

.text-button {
  background: transparent;
  color: #44403c;
  justify-self: start;
  padding-left: 0;
}

button:focus-visible, input:focus-visible, textarea:focus-visible, .text-button:focus-visible {
  outline: 3px solid #2563eb;
  outline-offset: 2px;
}

.mapa, .codigo, .ejemplo {
  white-space: pre-wrap;
  border-radius: 0.7rem;
  padding: 0.9rem 1rem;
}

.mapa {
  background: #fff;
  border: 1px solid #e7e5e4;
  margin: 0 0 1rem;
}

.pregunta {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0 0 0.8rem;
}

.codigo {
  background: #eef3f8;
  color: #1e293b;
  border: 1px solid #d5e1ee;
  font-family: Consolas, "Courier New", monospace;
  margin: 0 0 1rem;
}

.aviso {
  min-height: 1.4rem;
  font-weight: 650;
}

.ejemplo {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  margin: 0.8rem 0 0;
}

@media (max-width: 640px) {
  main { width: min(40rem, calc(100% - 1.25rem)); padding-top: 1.25rem; }
  h1 { font-size: 1.7rem; }
  button { width: 100%; }
}
