:root {
  color-scheme: light;
  --bg: #f5f6f8;
  --surface: #ffffff;
  --surface-alt: #f1f5f9;
  --ink: #111827;
  --muted: #647084;
  --line: #d9dee8;
  --accent: #2563eb;
  --accent-strong: #1744a7;
  --good: #0f7b55;
  --warn: #a75b00;
  --bad: #b42318;
  --shadow: 0 16px 38px rgba(22, 31, 48, 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;
  line-height: 1.45;
}

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

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

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

.topbar {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.brand {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  color: var(--ink);
  text-decoration: none;
}

.mark {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: flex-end;
}

nav a {
  text-decoration: none;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: stretch;
  margin-bottom: 16px;
}

.hero > div,
.metric-card,
.panel,
.notes article {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero > div {
  padding: 20px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 8px;
  font-size: clamp(2.3rem, 5vw, 4.2rem);
  line-height: 0.98;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 1rem;
}

.lede {
  max-width: 760px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1rem;
  font-weight: 650;
}

.metric-card {
  display: grid;
  gap: 5px;
  padding: 20px;
  background: linear-gradient(135deg, #ffffff 0%, #edf4ff 100%);
}

.metric-card span,
.metric-card small,
label,
.check-item small {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.metric-card strong {
  align-self: center;
  color: var(--accent-strong);
  font-size: 3.3rem;
  line-height: 1;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(440px, 1fr);
  gap: 16px;
  align-items: start;
}

.workspace > *,
.notes > * {
  min-width: 0;
}

.panel {
  padding: 18px;
}

.panel-header {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

button {
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  font-weight: 900;
}

button:hover {
  border-color: var(--accent);
  color: var(--accent-strong);
}

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

.grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

label {
  display: grid;
  gap: 7px;
  margin-bottom: 13px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  font-weight: 800;
}

input,
select {
  min-height: 42px;
  padding: 0 12px;
}

textarea {
  resize: vertical;
  padding: 12px;
}

input:focus,
select:focus,
textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.disclaimer,
.notice {
  padding: 13px;
  border: 1px solid #bed3ff;
  border-radius: 8px;
  color: var(--accent-strong);
  background: #eef4ff;
  font-size: 0.9rem;
  font-weight: 800;
}

.notice {
  margin-bottom: 16px;
}

.notice.warn {
  border-color: #eed2a7;
  color: var(--warn);
  background: #fff7e8;
}

.notice.bad {
  border-color: #efc8c4;
  color: var(--bad);
  background: #fff3f1;
}

.checklist {
  display: grid;
  gap: 10px;
}

.check-item {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-alt);
}

.check-item input {
  width: 18px;
  height: 18px;
  min-height: auto;
  margin-top: 2px;
  accent-color: var(--accent);
}

.check-item strong {
  display: block;
  margin-bottom: 3px;
  font-size: 0.96rem;
}

.packet {
  margin-top: 18px;
}

pre {
  min-height: 280px;
  max-height: 520px;
  overflow: auto;
  white-space: pre-wrap;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fff;
  color: var(--ink);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 0.88rem;
}

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

.notes article {
  padding: 18px;
}

.notes p {
  margin-bottom: 10px;
  color: var(--muted);
}

.notes p:last-child {
  margin-bottom: 0;
}

@media (max-width: 980px) {
  .hero,
  .workspace,
  .notes {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .shell {
    width: min(100% - 20px, 1240px);
    padding-top: 14px;
  }

  .topbar,
  .panel-header {
    align-items: flex-start;
    flex-direction: column;
  }

  nav {
    justify-content: flex-start;
  }

  .grid.two {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 2.7rem;
  }

  .hero > div,
  .metric-card,
  .panel,
  .notes article {
    padding: 15px;
  }

  button {
    width: 100%;
  }
}
