:root {
  --bg: #f6f3ec;
  --paper: #fffdf8;
  --ink: #1f2933;
  --muted: #5f6c7b;
  --accent: #b3261e;
  --accent2: #0f766e;
  --line: #e2d8c8;
  --shadow: 0 14px 35px rgba(58, 43, 24, .10);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(circle at top left, #fff7d6 0, transparent 34rem), var(--bg);
  color: var(--ink);
  line-height: 1.5;
}

.hero {
  padding: 3rem 1.2rem 2rem;
  background: linear-gradient(135deg, #7f1d1d, #b3261e 55%, #d97706);
  color: white;
}
.hero > div, main, footer { max-width: 1120px; margin: 0 auto; }
.tag { text-transform: uppercase; letter-spacing: .08em; font-size: .82rem; opacity: .9; font-weight: 700; }
h1 { font-size: clamp(2rem, 6vw, 4.4rem); line-height: .95; margin: .4rem 0 1rem; }
.lead { font-size: 1.2rem; max-width: 760px; opacity: .95; }

main { padding: 1.2rem; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 1.2rem;
  box-shadow: var(--shadow);
  margin-bottom: 1rem;
}
.wide { grid-column: 1 / -1; }
.intro { margin-top: -2.2rem; position: relative; }
h2 { margin-top: 0; color: #7f1d1d; }

label { display: block; font-weight: 700; margin: .85rem 0; }
input, select, textarea {
  width: 100%;
  margin-top: .35rem;
  border: 1px solid #cbbda8;
  border-radius: 14px;
  padding: .8rem .9rem;
  font: inherit;
  color: var(--ink);
  background: #fffefa;
}
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 3px solid rgba(15, 118, 110, .18); border-color: var(--accent2); }
.twoCols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1rem; }
.check { display: flex; gap: .65rem; align-items: center; font-weight: 650; }
.check input { width: auto; transform: scale(1.2); }

.actions { display: flex; gap: .8rem; flex-wrap: wrap; margin-bottom: 1rem; }
button {
  border: 0;
  border-radius: 999px;
  padding: .9rem 1.25rem;
  font-weight: 800;
  cursor: pointer;
  background: var(--accent2);
  color: white;
  box-shadow: var(--shadow);
}
button:hover { filter: brightness(.96); transform: translateY(-1px); }
.secondary { background: #7f1d1d; }
.ghost { background: transparent; color: #7f1d1d; border: 1px solid #cbbda8; }
.outputHead { display: flex; justify-content: space-between; gap: 1rem; align-items: center; }
#status { color: var(--accent2); font-weight: 800; }
#result { min-height: 18rem; background: #ffffff; }
.note ul { padding-left: 1.2rem; }
.note li { margin: .45rem 0; }
footer { padding: 1rem 1.2rem 2rem; color: var(--muted); }

@media (max-width: 760px) {
  .grid, .twoCols { grid-template-columns: 1fr; }
  .intro { margin-top: 0; }
}
