:root {
  color-scheme: light;
  --bg: #f7f8fb;
  --ink: #16202a;
  --muted: #5f6b7a;
  --line: #d8dee8;
  --panel: #ffffff;
  --primary: #1264d8;
  --primary-dark: #0d4ea9;
  --danger: #b3261e;
}

* {
  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(--primary);
  text-decoration: none;
}

.topbar {
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(16px, 4vw, 48px);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
}

.brand {
  color: var(--ink);
  font-weight: 800;
}

.shell {
  width: min(1100px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0 64px;
}

.hero {
  min-height: calc(100vh - 140px);
  display: grid;
  align-content: center;
  gap: 20px;
}

.hero h1,
.page-head h1,
.panel h1 {
  margin: 0;
  font-size: clamp(32px, 6vw, 64px);
  line-height: 1.02;
  letter-spacing: 0;
}

.panel h1,
.page-head h1 {
  font-size: clamp(28px, 4vw, 42px);
}

.hero p,
.muted,
.item p,
.page-head p {
  color: var(--muted);
  max-width: 680px;
}

.eyebrow {
  margin: 0;
  color: var(--primary);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 12px;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: clamp(18px, 4vw, 32px);
}

.narrow {
  max-width: 520px;
  margin: 40px auto;
}

.page-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 24px;
}

.actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 14px;
  background: white;
  color: var(--ink);
  font-weight: 700;
  cursor: pointer;
}

.button.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
}

.button.primary:hover {
  background: var(--primary-dark);
}

.button.ghost {
  background: transparent;
}

.button.danger {
  color: white;
  background: var(--danger);
  border-color: var(--danger);
}

.stack {
  display: grid;
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
  font-weight: 700;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  font: inherit;
  background: white;
  color: var(--ink);
}

textarea {
  resize: vertical;
}

.hint,
.error,
.empty {
  border-radius: 8px;
  padding: 12px;
}

.hint,
.empty {
  background: #eef4ff;
  color: #31506f;
}

.error {
  background: #fff0ef;
  color: var(--danger);
}

.list {
  display: grid;
  gap: 12px;
}

.item {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
}

.item h2 {
  margin: 0;
}

.table-wrap {
  overflow: auto;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

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

th {
  background: #f0f3f8;
}

.required {
  color: var(--danger);
}

.checks {
  display: grid;
  gap: 8px;
}

.check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}

.check input {
  width: auto;
}

@media (max-width: 720px) {
  .page-head,
  .item {
    display: grid;
  }
}
