html {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino, serif;
  background:
    radial-gradient(circle at top left, rgba(209, 228, 201, 0.6), transparent 32%),
    linear-gradient(180deg, #f4efe7 0%, #e0d5c1 100%);
  color: #201913;
}

body {
  margin: 0;
}

.page {
  max-width: 1040px;
  margin: 0 auto;
  padding: 32px 20px 72px;
}

.panel {
  background: rgba(255, 250, 241, 0.92);
  border: 1px solid #b7a58b;
  border-radius: 20px;
  box-shadow: 0 18px 36px rgba(72, 52, 32, 0.12);
  padding: 28px;
  margin-bottom: 24px;
}

h1,
h2,
h3 {
  margin-top: 0;
  font-weight: 600;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 4.2rem);
  line-height: 0.95;
  margin-bottom: 16px;
}

.eyebrow {
  margin: 0 0 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  color: #6d5b44;
}

.intro {
  max-width: 56ch;
  margin-bottom: 24px;
  font-size: 1.05rem;
}

label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
}

textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 16px;
  border-radius: 14px;
  border: 1px solid #9c8a6d;
  background: #fffdf8;
  color: inherit;
  font: inherit;
  resize: vertical;
  min-height: 168px;
}

fieldset {
  margin: 0;
  padding: 14px 16px 16px;
  border: 1px solid #d3c4af;
  border-radius: 16px;
  background: rgba(247, 239, 226, 0.74);
}

legend {
  padding: 0 8px;
  font-weight: 600;
}

fieldset label {
  font-weight: 400;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 8px 0 0;
}

input[type="radio"] {
  accent-color: #3f6a52;
}

.form-block + .form-block {
  margin-top: 24px;
}

.section-note {
  margin-top: -4px;
  margin-bottom: 16px;
  color: #57473a;
}

.radio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.actions {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

button {
  border: 0;
  border-radius: 999px;
  padding: 12px 20px;
  background: #3f6a52;
  color: #f7f2e9;
  font: inherit;
  cursor: pointer;
}

.secondary-button {
  background: #8b5e3c;
}

.ghost-button {
  background: transparent;
  color: #3f6a52;
  border: 1px solid #3f6a52;
}

button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.status {
  margin: 0;
}

.error {
  color: #8d1f1f;
}

.hidden {
  display: none;
}

.status-panel {
  min-height: 120px;
}

.result-block + .result-block {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid #d4c6b2;
}

pre {
  margin: 0;
  overflow-x: auto;
  padding: 14px;
  border-radius: 12px;
  background: #f7efe2;
  border: 1px solid #d3c4af;
}

ul {
  margin-top: 0;
}

.hero-result {
  background:
    linear-gradient(135deg, rgba(63, 106, 82, 0.1), rgba(110, 82, 57, 0.12)),
    #fff8ee;
}

.result-label {
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.78rem;
  color: #6d5b44;
}

.primary-risk {
  margin: 0 0 18px;
  font-size: clamp(2.4rem, 7vw, 4.8rem);
  line-height: 0.92;
  color: #274536;
}

.supporting-risks {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin: 0;
}

.supporting-risks div,
.advice-card {
  padding: 14px;
  border-radius: 12px;
  background: #efe4d3;
}

.supporting-risks dt {
  font-weight: 600;
}

.supporting-risks dd {
  margin: 6px 0 0;
  font-size: 1.15rem;
}

.advice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.advice-card h3 {
  margin-bottom: 8px;
}

.advice-card p,
.disclaimer-block p {
  margin-bottom: 0;
}

.explanation-note {
  margin: 10px 0 0;
  font-size: 0.92rem;
  color: #6d5b44;
}

.warning-block {
  border-left: 4px solid #8b5e3c;
  padding-left: 20px;
}

.technical-details {
  margin-top: 24px;
  border-top: 1px solid #d4c6b2;
  padding-top: 20px;
}

.technical-details summary {
  cursor: pointer;
  font-weight: 600;
  margin-bottom: 16px;
}

.detail-block + .detail-block {
  margin-top: 16px;
}

@media (max-width: 640px) {
  .page {
    padding: 20px 14px 48px;
  }

  .panel {
    padding: 20px;
  }

  .hero h1 {
    max-width: none;
  }
}
