:root {
  color-scheme: light;
  --bg: #f4f7f6;
  --ink: #13201c;
  --muted: #63736d;
  --line: #d8e1dd;
  --panel: #ffffff;
  --green: #0f8f72;
  --teal: #0b6470;
  --amber: #b66b13;
  --rose: #b83955;
  --blue: #2557a7;
}

* {
  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;
}

.topbar {
  align-items: center;
  background: #ffffff;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  min-height: 76px;
  padding: 14px 32px;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: 26px;
}

h2 {
  font-size: clamp(30px, 5vw, 58px);
  line-height: 1.03;
  max-width: 960px;
}

h3 {
  font-size: 21px;
}

.eyebrow {
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  margin-bottom: 6px;
  text-transform: uppercase;
}

.url-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--teal);
  font-size: 14px;
  padding: 10px 14px;
  white-space: nowrap;
}

.shell {
  display: grid;
  gap: 20px;
  padding: 24px 32px 40px;
}

.hero {
  align-items: stretch;
  display: grid;
  gap: 20px;
  grid-template-columns: minmax(0, 1fr) 280px;
}

.hero-copy {
  background: linear-gradient(135deg, #dff4ee, #ffffff 62%);
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 300px;
  padding: 42px;
}

.hero-panel,
.filters,
.table-panel,
.detail,
.metric {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.hero-panel {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
}

.hero-panel strong {
  color: var(--green);
  font-size: 74px;
  line-height: 1;
  margin: 8px 0 14px;
}

.panel-label,
.muted {
  color: var(--muted);
}

.metrics {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.metric {
  min-height: 112px;
  padding: 18px;
}

.metric span {
  color: var(--muted);
  display: block;
  font-size: 13px;
  margin-bottom: 12px;
}

.metric strong {
  font-size: 30px;
}

.workspace {
  display: grid;
  gap: 20px;
  grid-template-columns: 240px minmax(0, 1fr) 360px;
}

.filters,
.detail {
  padding: 20px;
}

label {
  color: var(--muted);
  display: grid;
  font-size: 13px;
  font-weight: 700;
  gap: 8px;
  margin-bottom: 18px;
}

input,
select,
button {
  border: 1px solid var(--line);
  border-radius: 8px;
  font: inherit;
  min-height: 40px;
}

input,
select {
  background: #ffffff;
  color: var(--ink);
  padding: 0 12px;
  width: 100%;
}

button {
  background: var(--ink);
  color: #ffffff;
  cursor: pointer;
  font-weight: 800;
  padding: 0 14px;
}

.table-panel {
  overflow: hidden;
}

.section-head {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  padding: 18px 20px;
}

.table-wrap {
  overflow-x: auto;
}

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

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

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

tr {
  cursor: pointer;
}

tr:hover {
  background: #eef7f3;
}

.score {
  border-radius: 999px;
  color: #ffffff;
  display: inline-block;
  font-weight: 900;
  min-width: 52px;
  padding: 6px 10px;
  text-align: center;
}

.score.high {
  background: var(--rose);
}

.score.mid {
  background: var(--amber);
}

.score.low {
  background: var(--teal);
}

.detail h3 {
  margin-bottom: 10px;
}

.detail-block {
  border-top: 1px solid var(--line);
  margin-top: 16px;
  padding-top: 16px;
}

.detail-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, 1fr);
}

.mini {
  background: #f7faf9;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
}

.mini span {
  color: var(--muted);
  display: block;
  font-size: 12px;
  margin-bottom: 3px;
}

.mini strong {
  font-size: 18px;
}

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

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

@media (max-width: 640px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
    padding: 16px;
  }

  .shell {
    padding: 16px;
  }

  .hero-copy {
    min-height: auto;
    padding: 24px;
  }

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