:root {
  --accent: #2f4fe0;
  --accent-dark: #2340c0;
  --accent-soft: #eef1fd;
  --text: #1c2230;
  --muted: #5d667a;
  --line: #d7dbe6;
  --error: #b3261e;
  --radius: 10px;
}

* { box-sizing: border-box; }

html, body { margin: 0; }

body {
  font-family: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  color: var(--text);
  background: transparent;
  line-height: 1.45;
}

.card {
  max-width: 860px;
  margin: 0 auto;
  padding: 24px 16px 32px;
}

.title {
  margin: 0 0 6px;
  text-align: center;
  font-size: 1.6rem;
  font-weight: 650;
}

.meta {
  margin: 0 0 22px;
  text-align: center;
  color: var(--muted);
  font-size: 0.95rem;
}
.meta a { color: var(--accent); }

.section-title {
  margin: 20px 0 10px;
  text-align: center;
  font-size: 1.05rem;
  font-weight: 600;
}
.section-title.left { text-align: left; margin-top: 0; }

.tz {
  margin: -4px 0 12px;
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
}

.chip {
  min-width: 96px;
  min-height: 48px;
  padding: 8px 14px;
  font: inherit;
  font-weight: 600;
  color: var(--accent);
  background: #fff;
  border: 1.5px solid var(--accent);
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}
.chip small { display: block; font-weight: 500; font-size: 0.78rem; opacity: 0.85; }
.chip:hover { background: var(--accent-soft); }
.chip[aria-pressed='true'] { background: var(--accent); color: #fff; }

button:focus-visible, input:focus-visible, textarea:focus-visible, a:focus-visible, .done:focus-visible {
  outline: 3px solid #9db0ff;
  outline-offset: 2px;
}

.actions { display: flex; margin-top: 22px; }
.actions.center { justify-content: center; }
.actions.end { justify-content: flex-end; }

.primary {
  min-height: 46px;
  padding: 10px 22px;
  font: inherit;
  font-weight: 600;
  color: #fff;
  background: var(--accent);
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
}
.primary:hover:not(:disabled) { background: var(--accent-dark); }
.primary:disabled { background: #b8c1ec; cursor: not-allowed; }

.error, .field-error { color: var(--error); font-size: 0.9rem; margin: 8px 0 0; }
.error { text-align: center; }
.field-error { text-align: left; margin-top: 4px; }

.empty { color: var(--muted); text-align: center; margin: 12px 0; }

/* Step 2 */
.two-panel { display: grid; gap: 20px; grid-template-columns: 1fr; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
@media (min-width: 720px) {
  .two-panel { grid-template-columns: 260px 1fr; gap: 0; padding: 0; }
  .summary { padding: 24px; border-right: 1px solid var(--line); }
  .form { padding: 24px; }
}
.two-panel[hidden] { display: none; }

.back {
  width: 40px; height: 40px;
  margin-bottom: 12px;
  font-size: 1.2rem;
  color: var(--accent);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 50%;
  cursor: pointer;
}
.summary-title { margin: 0 0 10px; font-size: 1.15rem; font-weight: 650; }
.summary-list { list-style: none; margin: 0; padding: 0; color: var(--muted); font-size: 0.92rem; }
.summary-list li { margin: 6px 0; }
.summary-list a { color: var(--accent); }

.grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 560px) { .grid { grid-template-columns: 1fr 1fr; } }

.field { margin-bottom: 14px; }
.field label { display: block; margin-bottom: 4px; font-size: 0.9rem; font-weight: 600; }

input:not([type='checkbox']), textarea {
  width: 100%;
  min-height: 44px;
  padding: 9px 12px;
  font: inherit;
  color: var(--text);
  background: #fff;
  border: 1px solid #b9bfcf;
  border-radius: 8px;
}
textarea { resize: vertical; }
input[aria-invalid='true'], textarea[aria-invalid='true'] { border-color: var(--error); }

.check { display: flex; gap: 10px; align-items: flex-start; font-size: 0.9rem; font-weight: 400 !important; }
.check input { width: 20px; height: 20px; margin-top: 2px; flex: none; }

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* Confirmation */
.done { text-align: center; padding: 20px 0; }
.done:focus { outline: none; }
.done-icon {
  width: 56px; height: 56px; margin: 0 auto 8px;
  display: grid; place-items: center;
  font-size: 1.6rem; color: #fff; background: #1e8e4f; border-radius: 50%;
}
.done-when { font-size: 1.2rem; font-weight: 650; margin: 6px 0; }
.muted { color: var(--muted); }

/* Loading */
.skeleton { display: inline-block; background: linear-gradient(90deg, #eceef5, #f6f7fb, #eceef5); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: var(--radius); }
.chip-skeleton { width: 96px; height: 48px; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .skeleton { animation: none; } .chip { transition: none; } }

.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

[hidden] { display: none !important; }
