:root {
  --bg: #f4f8f8;
  --surface: #ffffff;
  --ink: #111827;
  --muted: #5f6b7a;
  --line: #dce6e8;
  --accent: #e3183e;
  --accent-strong: #101827;
  --soft-accent: #fff0f3;
  --danger: #b91c1c;
  --shadow: 0 18px 48px rgba(17, 24, 39, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: var(--accent);
  font-weight: 700;
}

button,
.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  padding: 0 18px;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

button.secondary {
  background: #edf2f4;
  color: var(--accent-strong);
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 15px;
  margin-top: 8px;
  padding: 11px 12px;
}

textarea {
  resize: vertical;
}

label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 12px;
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0;
  text-transform: uppercase;
}

code {
  border-radius: 6px;
  background: #edf2f0;
  padding: 2px 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92em;
}

.shell {
  width: min(1120px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 34px 0 56px;
}

.hero {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  align-items: stretch;
  margin-bottom: 24px;
}

.hero > div,
.panel,
.claim-card,
.editor {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero > div {
  padding: 28px;
}

.safety {
  color: var(--muted);
  line-height: 1.7;
}

.mode {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  max-width: 760px;
  font-size: 44px;
  line-height: 1.05;
}

h2 {
  font-size: 22px;
}

.lede {
  max-width: 700px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.55;
}

.panel {
  margin-top: 22px;
  padding: 24px;
}

.grid-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.grid-form button {
  align-self: end;
}

.hint {
  color: var(--muted);
  font-size: 14px;
}

.status {
  display: inline-flex;
  border-radius: 6px;
  background: var(--soft-accent);
  color: var(--accent);
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 800;
}

.claim {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}

.attendee-landing,
.public-home {
  background:
    radial-gradient(circle at 86% 8%, rgba(227, 24, 62, 0.12), transparent 24%),
    linear-gradient(135deg, #ffffff 0%, #f5fbfc 58%, #edf5f6 100%);
}

.claim-card {
  width: min(640px, 100%);
  padding: 32px;
}

.simple-card {
  box-shadow: 0 22px 70px rgba(17, 24, 39, 0.12);
}

.claim-card dl {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin: 24px 0;
}

.person-summary div {
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.claim-card dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.claim-card dd {
  margin: 4px 0 0;
  font-weight: 700;
}

.preview-layout {
  display: grid;
  grid-template-columns: minmax(360px, 58vw) minmax(380px, 1fr);
  min-height: 100vh;
}

.badge-stage {
  display: grid;
  min-height: 100vh;
  place-items: center;
  background:
    radial-gradient(circle at 22% 18%, rgba(227, 24, 62, 0.1), transparent 26%),
    linear-gradient(135deg, #f8fbfb, #eaf2f3);
  padding: 36px;
}

.badge-stage img,
.empty-badge {
  width: min(720px, 100%);
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.2);
}

.empty-badge {
  display: grid;
  place-items: center;
  border: 2px dashed #94a3b8;
  color: var(--muted);
  font-weight: 800;
}

.editor {
  min-height: 100vh;
  border-radius: 0;
  box-shadow: none;
  padding: 40px;
}

.stack {
  display: grid;
  gap: 16px;
  margin: 22px 0;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.stack.compact {
  border-top: 1px solid var(--line);
  margin-top: 26px;
  padding-top: 22px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  margin-top: 18px;
}

.share-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 88% 16%, rgba(227, 24, 62, 0.11), transparent 24%),
    linear-gradient(135deg, #ffffff 0%, #f5fbfc 62%, #edf5f6 100%);
  padding: 36px;
}

.share-hero {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(320px, 1.35fr);
  gap: 32px;
  align-items: center;
  width: min(1180px, 100%);
  margin: 0 auto;
}

.share-copy {
  padding: 24px 0;
}

.share-badge {
  width: 100%;
  border-radius: 8px;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.18);
}

@media (max-width: 860px) {
  .hero,
  .grid-form,
  .preview-layout,
  .share-hero,
  .field-row {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 34px;
  }

  .badge-stage {
    min-height: auto;
  }

  .editor {
    min-height: auto;
    padding: 28px 22px;
  }
}
