:root {
  --bg: #f7f8fb;
  --panel: #ffffff;
  --line: #d8dce6;
  --ink: #121722;
  --muted: #5b6474;
  --accent: #165dff;
  --accent-soft: #eef4ff;
  --good: #18794e;
  --warn: #b47d00;
  --bad: #c33c54;
  --shadow: 0 10px 30px rgba(18, 23, 34, 0.07);
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(22, 93, 255, 0.04), transparent 220px),
    var(--bg);
  color: var(--ink);
}

.shell {
  max-width: 1500px;
  margin: 0 auto;
  padding: 22px;
}

.topbar,
.band,
.panel,
.metric,
.service,
.insight-card {
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  border-radius: 10px;
  padding: 20px 22px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

h1,
h2,
h3 {
  margin: 0;
}

h1 {
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  line-height: 1.04;
}

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

.actions.stack {
  flex-direction: column;
}

.button {
  border: 0;
  background: var(--accent);
  color: #fff;
  border-radius: 8px;
  padding: 11px 14px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}

.button.muted {
  background: #edf0f5;
  color: var(--ink);
}

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

.metric {
  border-radius: 8px;
  padding: 16px;
}

.metric strong {
  display: block;
  font-size: 1.8rem;
  margin-bottom: 6px;
}

.metric span {
  color: var(--muted);
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) 360px;
  gap: 16px;
  margin-top: 16px;
}

.main-column,
.side-column {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.band,
.panel {
  border-radius: 10px;
  padding: 18px;
}

.band-header {
  margin-bottom: 14px;
}

.band-header p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.decision-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.decision-strip article {
  border: 1px solid var(--line);
  background: #f9fbff;
  border-radius: 8px;
  padding: 14px;
}

.decision-strip strong,
.decision-strip span {
  display: block;
}

.decision-strip span {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.45;
}

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

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

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

th {
  background: #f3f6fc;
  position: sticky;
  top: 0;
}

.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 0.78rem;
  font-weight: 700;
}

.pill.good {
  background: rgba(24, 121, 78, 0.12);
  color: var(--good);
}

.pill.warn {
  background: rgba(180, 125, 0, 0.12);
  color: var(--warn);
}

.pill.bad {
  background: rgba(195, 60, 84, 0.12);
  color: var(--bad);
}

.checklist-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.checklist-group {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.checklist-group header {
  background: #f5f7fb;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
}

.checklist-items {
  padding: 8px 12px;
}

.check-item {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 0;
  border-bottom: 1px solid #edf0f5;
}

.check-item:last-child {
  border-bottom: 0;
}

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

.check-item small {
  display: block;
  color: var(--muted);
  margin-top: 3px;
  line-height: 1.35;
}

.insight-cards,
.service-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.insight-card,
.service {
  border-radius: 8px;
  padding: 14px;
}

.insight-card p,
.service p,
.service li,
.risk-list li,
.source-list li {
  color: var(--muted);
  line-height: 1.45;
}

.service ul,
.risk-list,
.source-list {
  margin: 10px 0 0;
  padding-left: 18px;
}

.risk-list li {
  margin-bottom: 10px;
}

.notes-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.notes-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.notes-form span {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--muted);
}

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

textarea {
  resize: vertical;
}

a {
  color: var(--accent);
}

@media (max-width: 1180px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .side-column {
    order: -1;
  }
}

@media (max-width: 860px) {
  .summary-grid,
  .decision-strip,
  .checklist-groups,
  .insight-cards,
  .service-grid {
    grid-template-columns: 1fr;
  }

  .topbar {
    flex-direction: column;
  }
}
