:root {
  --bg: #f6f1e9;
  --card: #fffdf9;
  --ink: #2a2420;
  --muted: #7a6f66;
  --line: #e4dacd;
  --accent: #b4472d;
  --accent-ink: #fff;
  --ok: #2f6b4a;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

.page {
  max-width: 560px;
  margin: 0 auto;
  padding: 32px 16px 64px;
}

.hero {
  margin-bottom: 24px;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1 {
  margin: 0 0 8px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(30px, 8vw, 42px);
  line-height: 1.15;
}

.meta {
  margin: 0 0 8px;
  font-weight: 600;
}

.desc {
  margin: 0;
  color: var(--muted);
}

.card {
  margin-bottom: 16px;
  padding: 20px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
}

h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  font-size: 18px;
}

.step {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--card);
  font-size: 14px;
}

label {
  display: block;
  margin: 14px 0 6px;
  font-size: 14px;
  font-weight: 600;
}

.optional {
  color: var(--muted);
  font-weight: 400;
}

input[type="text"],
input[type="tel"],
input[type="email"],
select,
textarea {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

input:focus,
select:focus,
textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

input[type="file"] {
  width: 100%;
  font: inherit;
}

.hint {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.pay {
  margin: 0;
}

.pay div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line);
}

.pay div:last-child {
  border-bottom: 0;
}

.pay dt {
  color: var(--muted);
}

.pay dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
  overflow-wrap: anywhere;
}

.pay .amount {
  color: var(--accent);
  font-size: 20px;
}

.qr,
.preview {
  display: block;
  max-width: 100%;
  margin: 16px auto 0;
  border-radius: 10px;
}

.qr {
  width: 240px;
}

.preview {
  max-height: 320px;
  border: 1px solid var(--line);
}

[hidden] {
  display: none !important;
}

.error {
  margin: 0 0 12px;
  padding: 12px 14px;
  border-radius: 10px;
  background: #fbe9e4;
  color: #8f2c16;
}

button {
  width: 100%;
  padding: 14px;
  border: 0;
  border-radius: 12px;
  background: var(--accent);
  color: var(--accent-ink);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

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

.success {
  border-color: var(--ok);
}

.success h2 {
  color: var(--ok);
}

.success p {
  margin: 0;
}
