:root {
  --bg: #f8f5f2;
  --panel: #ffffff;
  --text: #2e2a27;
  --muted: #756f68;
  --line: #e7ded4;
  --accent: #2f8f83;
  --accent-strong: #197266;
  --warn: #a86816;
  --danger: #b34242;
  --shadow: 0 18px 44px rgba(71, 52, 37, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(47, 143, 131, 0.16), transparent 28rem),
    linear-gradient(135deg, #fbf8f3 0%, #f2eee9 48%, #eef5f3 100%);
  font-family:
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  line-height: 1.6;
}

button,
input,
select,
textarea {
  font: inherit;
}

.page-shell {
  width: min(980px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 48px;
}

.hero {
  padding: 32px;
  color: #ffffff;
  background: linear-gradient(135deg, #2f615c 0%, #496a86 100%);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.eyebrow {
  display: inline-flex;
  margin: 0 0 12px;
  padding: 4px 10px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.78rem;
  font-weight: 700;
}

h1,
h2 {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(2rem, 7vw, 4rem);
  line-height: 1.1;
}

h2 {
  font-size: 1.15rem;
}

.lead {
  max-width: 680px;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.9);
}

.report-form {
  display: grid;
  gap: 18px;
  margin-top: 22px;
}

.form-section,
.submit-area {
  padding: 22px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.service-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.severity-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.choice {
  position: relative;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfa;
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    background 0.15s ease,
    transform 0.15s ease;
}

.choice:hover {
  border-color: rgba(47, 143, 131, 0.55);
  transform: translateY(-1px);
}

.choice input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.choice span {
  display: flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  color: var(--text);
  font-weight: 700;
  text-align: center;
}

.choice input:checked + span {
  color: var(--accent-strong);
  background: rgba(47, 143, 131, 0.1);
  box-shadow: inset 0 0 0 2px var(--accent);
}

.choice.danger input:checked + span {
  color: var(--danger);
  background: rgba(179, 66, 66, 0.09);
  box-shadow: inset 0 0 0 2px var(--danger);
}

.detail-section {
  display: grid;
  gap: 16px;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.field-group {
  display: grid;
  gap: 7px;
}

label {
  color: var(--text);
  font-weight: 700;
}

.required {
  color: var(--danger);
  font-size: 0.82rem;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #d8cec2;
  border-radius: 8px;
  background: #fffefc;
  color: var(--text);
}

input,
select {
  min-height: 46px;
  padding: 0 12px;
}

textarea {
  min-height: 112px;
  padding: 12px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  outline: 3px solid rgba(47, 143, 131, 0.18);
}

.hint,
.privacy-note {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.file-drop {
  display: grid;
  min-height: 92px;
  margin-top: 14px;
  place-items: center;
  border: 1px dashed #cbbdae;
  border-radius: 8px;
  background: #fffdfa;
  color: var(--accent-strong);
  text-align: center;
  cursor: pointer;
}

.file-drop span {
  font-weight: 800;
}

.file-drop small {
  color: var(--muted);
}

.file-list {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.file-list li {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 10px;
  align-items: center;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.file-list span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-list small {
  color: var(--muted);
}

.file-list button {
  min-height: 32px;
  border: 1px solid #d8cec2;
  border-radius: 999px;
  background: #fffdfa;
  color: var(--text);
  cursor: pointer;
}

.submit-area {
  display: grid;
  gap: 12px;
}

.submit-button {
  min-height: 54px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

.submit-button:disabled {
  cursor: wait;
  opacity: 0.68;
}

.status-message {
  display: none;
  padding: 12px 14px;
  border-radius: 8px;
  font-weight: 700;
}

.status-message.pending,
.status-message.success,
.status-message.error {
  display: block;
}

.status-message.pending {
  background: rgba(168, 104, 22, 0.1);
  color: var(--warn);
}

.status-message.success {
  background: rgba(47, 143, 131, 0.12);
  color: var(--accent-strong);
}

.status-message.error {
  background: rgba(179, 66, 66, 0.11);
  color: var(--danger);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

@media (max-width: 760px) {
  .page-shell {
    width: min(100% - 20px, 980px);
    padding-top: 10px;
  }

  .hero,
  .form-section,
  .submit-area {
    padding: 18px;
  }

  .option-grid,
  .service-grid,
  .severity-grid,
  .field-row {
    grid-template-columns: 1fr;
  }

  .choice span {
    justify-content: flex-start;
    text-align: left;
  }
}
