:root {
  --brand: #b9323f;
  --brand-dark: #8f2732;
  --ink: #20252b;
  --muted: #68717d;
  --line: #e1e5e8;
  --ok: #16794c;
  --bg: #f5f6f7;
  font-family: Inter, system-ui, -apple-system, Segoe UI, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

.shell {
  max-width: 660px;
  margin: 0 auto;
  padding: 24px 16px 64px;
}

header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 40px;
}

.logo {
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.08em;
  color: var(--brand);
}
.logo span { font-size: 16px; letter-spacing: normal; }

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

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 32px;
  box-shadow: 0 16px 45px rgba(30, 41, 59, 0.07);
}

h1 {
  margin: 0 0 12px;
  font-size: clamp(25px, 5vw, 34px);
  line-height: 1.08;
  letter-spacing: -0.02em;
}
h2 { margin: 0 0 12px; color: var(--brand); }

.intro, .muted { color: var(--muted); line-height: 1.6; }
.intro { margin: 0 0 26px; }
.muted { font-size: 14px; }

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 16px;
}

label {
  display: grid;
  gap: 7px;
  margin: 16px 0;
  font-weight: 600;
  font-size: 15px;
}

input, select {
  width: 100%;
  border: 1px solid #cbd2d9;
  border-radius: 10px;
  padding: 13px 14px;
  font: inherit;
  font-weight: 400;
  background: #fff;
  color: var(--ink);
}
input:focus, select:focus {
  outline: 2px solid var(--brand);
  outline-offset: 1px;
  border-color: var(--brand);
}

fieldset {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 6px 18px 18px;
  margin: 22px 0;
}
legend {
  font-weight: 700;
  font-size: 15px;
  padding: 0 8px;
  color: var(--ink);
}

.hint {
  color: var(--muted);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
  margin: 4px 0 0;
}

small {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.5;
}

.field-error {
  color: var(--brand);
  font-size: 13px;
  font-style: normal;
  font-weight: 600;
  min-height: 0;
}
.field-error:not(:empty) { margin-top: 2px; }

.alert {
  background: #fdf2f3;
  border: 1px solid #f3c9cd;
  color: var(--brand-dark);
  border-radius: 10px;
  padding: 13px 15px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  margin-bottom: 18px;
}

.consent {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 11px;
  font-weight: 400;
  font-size: 14px;
  line-height: 1.55;
}
.consent input { width: auto; margin-top: 3px; }

button {
  width: 100%;
  border: 0;
  border-radius: 999px;
  padding: 15px 18px;
  background: var(--brand);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  margin-top: 14px;
}
button:hover:not(:disabled) { background: var(--brand-dark); }
button:disabled { opacity: 0.6; cursor: wait; }

.link-button {
  background: none;
  color: var(--muted);
  font-weight: 600;
  margin-top: 8px;
}
.link-button:hover:not(:disabled) { background: none; color: var(--ink); text-decoration: underline; }

.foot {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin-top: 28px;
}

.hidden { display: none !important; }

@media (max-width: 520px) {
  .card { padding: 22px; }
  header { margin-bottom: 26px; }
  .grid { grid-template-columns: 1fr; gap: 0; }
}
