@import url("https://fonts.googleapis.com/css2?family=Fraunces:wght@500;700&family=Space+Grotesk:wght@400;500;700&display=swap");

:root {
  --bg: #f6f8fb;
  --surface: #ffffff;
  --surface-alt: #f8fbff;
  --text: #10243f;
  --muted: #4f627b;
  --line: #d5deea;
  --line-strong: #b8c6d9;
  --primary: #1f4a7c;
  --primary-soft: #e7eff8;
  --accent: #e8892e;
  --ok: #158a6a;
  --warn: #c23b35;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  font-size: 15px;
  line-height: 1.34;
  color: var(--text);
  background:
    radial-gradient(900px 520px at -10% -15%, #d9e7f8 0%, transparent 62%),
    radial-gradient(900px 600px at 112% -22%, #f8e5d2 0%, transparent 60%),
    var(--bg);
}

.shell {
  max-width: 940px;
  margin: 0 auto;
  padding: 0.72rem 0.82rem 0.84rem;
  display: grid;
  gap: 0.58rem;
}

.hero {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #f7fbff);
  padding: 0.68rem 0.82rem;
}

.eyebrow {
  margin: 0;
  color: var(--primary);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
}

h1 {
  margin: 0.24rem 0 0.2rem;
  font-family: "Fraunces", "Times New Roman", serif;
  font-size: clamp(1.2rem, 2.5vw, 1.75rem);
}

.lead {
  margin: 0;
  color: var(--muted);
  max-width: 62ch;
  font-size: 0.88rem;
}

.card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  padding: 0.62rem;
}

h2 {
  margin: 0 0 0.34rem;
  font-size: 0.92rem;
}

h3 {
  margin: 0.44rem 0 0.28rem;
  font-size: 0.86rem;
}

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

.stepper {
  display: flex;
  flex-wrap: wrap;
  gap: 0.28rem;
}

.step-pill {
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 0.21rem 0.48rem;
  font-size: 0.72rem;
  color: var(--muted);
  background: #fff;
}

.step-pill.active {
  border-color: color-mix(in srgb, var(--primary) 50%, white 50%);
  color: var(--primary);
  background: var(--primary-soft);
}

.form-step {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.52rem;
  background: var(--surface-alt);
  display: grid;
  gap: 0.38rem;
}

.hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.73rem;
}

.grid-two {
  display: grid;
  gap: 0.38rem;
}

label {
  display: grid;
  gap: 0.22rem;
  font-size: 0.81rem;
}

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

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  padding: 0.36rem 0.44rem;
  background: #fff;
  color: var(--text);
}

input:disabled,
textarea:disabled,
select:disabled {
  color: #748294;
  background: #eef2f7;
  border-color: #d0d8e5;
  cursor: not-allowed;
}

textarea {
  resize: vertical;
  line-height: 1.3;
}

input:focus,
textarea:focus,
select:focus,
button:focus {
  outline: 2px solid color-mix(in srgb, var(--primary) 60%, white 40%);
  outline-offset: 1px;
}

.segment {
  display: flex;
  flex-wrap: wrap;
  gap: 0.36rem;
}

.segment-option {
  position: relative;
  display: block;
}

.segment-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.segment-option span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 7.5rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: #fff;
  padding: 0.26rem 0.54rem;
  cursor: pointer;
  color: var(--muted);
  font-size: 0.78rem;
}

.segment-option input:checked + span {
  border-color: color-mix(in srgb, var(--primary) 55%, white 45%);
  background: var(--primary-soft);
  color: var(--primary);
}

.req-badge {
  display: inline-flex;
  width: fit-content;
  margin-top: 0.04rem;
  padding: 0.06rem 0.3rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--accent) 65%, white 35%);
  background: #fdf0e4;
  color: #7a450f;
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.future-badge {
  border-color: #c4ccd8;
  background: #f1f4f9;
  color: #5c6779;
}

.checkbox {
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 0.38rem;
}

.checkbox input {
  margin-top: 0.24rem;
}

.wizard-actions,
.actions,
.status-row,
.receipt-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.28rem;
}

.status-row {
  margin: 0.24rem 0 0.3rem;
}

#status-url {
  flex: 1 1 24rem;
  background: #f3f7fc;
}

button {
  border: 1px solid color-mix(in srgb, var(--primary) 28%, white 72%);
  border-radius: 8px;
  background: linear-gradient(180deg, #2a5a93, #1f4a7c);
  color: #ffffff;
  padding: 0.26rem 0.54rem;
  font-weight: 600;
  cursor: pointer;
  font-size: 0.79rem;
}

button:hover {
  border-color: color-mix(in srgb, var(--primary) 50%, white 50%);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.button-secondary {
  background: linear-gradient(180deg, #ffffff, #f3f8ff);
  color: var(--primary);
}

.review-summary {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 0.4rem;
  display: grid;
  gap: 0.2rem;
  font-size: 0.78rem;
}

.review-row {
  display: grid;
  grid-template-columns: 10.5rem 1fr;
  gap: 0.34rem;
}

.review-key {
  color: var(--muted);
  font-weight: 600;
}

.status-details {
  margin-top: 0.6rem;
}

.status-details summary {
  cursor: pointer;
  color: var(--primary);
  font-size: 0.78rem;
}

pre {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f5f8fc;
  color: #173252;
  padding: 0.4rem;
  white-space: pre-wrap;
  word-break: break-word;
  overflow-x: auto;
  font-size: 0.74rem;
}

.errors {
  color: var(--warn);
}

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

.debug-only {
  border-style: dashed;
}

.hidden {
  display: none !important;
}

@media (min-width: 760px) {
  .grid-two {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .shell {
    padding: 0.8rem;
  }

  .review-row {
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }
}
