:root {
  color-scheme: dark;
  --bg: #07110f;
  --panel: #101b18;
  --panel-2: #13231f;
  --line: #25423b;
  --text: #ecfff9;
  --muted: #9fbab1;
  --accent: #35e39c;
  --warn: #f5c451;
  --danger: #ff6b6b;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px 1fr;
}

.sidebar {
  border-right: 1px solid var(--line);
  padding: 28px 22px;
  background: #081612;
}

.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 42px;
}

.mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-weight: 800;
}

.brand small,
.eyebrow,
.panel p,
.metrics span {
  color: var(--muted);
}

nav {
  display: grid;
  gap: 8px;
}

nav a {
  color: var(--muted);
  text-decoration: none;
  padding: 12px 14px;
  border: 1px solid transparent;
}

nav a.active,
nav a:hover {
  color: var(--text);
  border-color: var(--line);
  background: var(--panel);
}

.workspace {
  padding: 28px;
}

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

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

h1 {
  max-width: 820px;
  font-size: clamp(34px, 5vw, 68px);
  line-height: 0.98;
  margin-bottom: 0;
}

h2 {
  margin-bottom: 10px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 10px;
}

button {
  border: 0;
  background: var(--accent);
  color: #03100c;
  font-weight: 800;
  padding: 13px 18px;
  cursor: pointer;
}

input {
  width: 100%;
  border: 1px solid var(--line);
  background: #081612;
  color: var(--text);
  padding: 13px 14px;
  font: inherit;
}

input[type="radio"] {
  width: auto;
}

.metrics,
.grid {
  display: grid;
  gap: 16px;
}

.metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
}

.metrics article,
.panel {
  border: 1px solid var(--line);
  background: var(--panel);
}

.metrics article {
  padding: 18px;
}

.metrics strong {
  display: block;
  font-size: 28px;
  color: var(--accent);
}

.panel {
  padding: 24px;
  margin-bottom: 18px;
}

.panel-head,
.form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.badge {
  color: #06120e;
  background: var(--warn);
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 900;
}

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

.compact {
  min-height: 210px;
}

.report-preview {
  margin-top: 18px;
  display: grid;
  gap: 16px;
}

.order-form {
  margin-top: 18px;
  border: 1px solid var(--line);
  background: #081612;
  padding: 22px;
  display: grid;
  gap: 16px;
}

.order-form[hidden] {
  display: none;
}

.tier-grid,
.buyer-grid {
  display: grid;
  gap: 12px;
}

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

.tier-grid label {
  display: grid;
  gap: 8px;
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 16px;
  cursor: pointer;
}

.tier-grid label:has(input:checked) {
  border-color: var(--accent);
  background: rgba(53, 227, 156, 0.08);
}

.tier-grid strong {
  font-size: 18px;
}

.tier-grid span {
  color: var(--accent);
  font-weight: 900;
}

.tier-grid small,
.order-status {
  color: var(--muted);
}

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

.order-status {
  margin: 0;
  line-height: 1.6;
}

.order-status a {
  color: var(--accent);
  font-weight: 900;
}

.report-cover,
.chart-card,
.locked-card {
  border: 1px solid var(--line);
  background: #081612;
}

.report-cover {
  min-height: 210px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 22px;
  padding: 24px;
  position: relative;
  overflow: hidden;
}

.report-cover::before {
  content: "";
  position: absolute;
  inset: auto -20% -55% 20%;
  height: 190px;
  background: rgba(53, 227, 156, 0.14);
  transform: rotate(-6deg);
}

.report-cover > * {
  position: relative;
}

.report-cover h3,
.chart-card h3,
.locked-card h3 {
  font-size: 28px;
  margin: 0 0 10px;
}

.wallet-line {
  overflow-wrap: anywhere;
  color: var(--text);
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.trust-row span {
  border: 1px solid var(--line);
  background: rgba(53, 227, 156, 0.08);
  color: var(--accent);
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 800;
}

.report-score {
  display: grid;
  justify-items: center;
  gap: 10px;
  color: var(--muted);
  font-weight: 800;
}

.score-ring {
  width: 132px;
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  font-size: 38px;
  font-weight: 900;
  color: var(--text);
  border: 12px solid var(--accent);
  background: #050b09;
}

.score-ring.medium {
  border-color: var(--warn);
}

.score-ring.high {
  border-color: var(--danger);
}

.score-ring.idle {
  border-color: var(--line);
  color: var(--muted);
}

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

.highlight-grid article {
  border: 1px solid var(--line);
  background: #081612;
  padding: 14px;
}

.highlight-grid span,
.sample-table td:first-child {
  color: var(--muted);
}

.highlight-grid strong {
  display: block;
  margin-top: 6px;
  color: var(--text);
}

.data-quality {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  border: 1px solid var(--line);
  background: #081612;
  padding: 18px;
}

.data-quality.live {
  border-color: var(--accent);
  background: rgba(53, 227, 156, 0.08);
}

.data-quality.demo {
  border-color: var(--warn);
  background: rgba(245, 196, 81, 0.08);
}

.data-quality h3 {
  margin: 0 0 8px;
}

.data-quality span,
.data-quality small {
  display: block;
  color: var(--muted);
}

.data-quality strong {
  display: block;
  margin: 6px 0;
  color: var(--text);
  font-size: 22px;
}

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

.report-grid article {
  border: 1px solid var(--line);
  background: var(--panel-2);
  padding: 18px;
}

.report-grid span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  font-weight: 800;
  margin-bottom: 8px;
}

.report-grid strong {
  display: block;
  margin-bottom: 10px;
  color: var(--accent);
  font-size: 20px;
}

.chart-card,
.locked-card {
  padding: 22px;
}

.report-columns {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 16px;
}

.mini-graph {
  min-height: 260px;
  position: relative;
  border: 1px solid var(--line);
  background: #050b09;
  overflow: hidden;
}

.mini-graph svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.mini-graph path {
  fill: none;
  stroke: rgba(53, 227, 156, 0.36);
  stroke-width: 3;
}

.graph-node {
  position: absolute;
  display: grid;
  place-items: center;
  width: 112px;
  min-height: 48px;
  padding: 8px;
  border: 1px solid var(--line);
  background: #101b18;
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.graph-node:nth-of-type(1) {
  left: 40px;
  top: 104px;
  border-color: var(--accent);
}

.graph-node:nth-of-type(2) {
  right: 38px;
  top: 72px;
}

.graph-node:nth-of-type(3) {
  left: calc(50% - 56px);
  top: 104px;
}

.graph-node:nth-of-type(4) {
  right: 38px;
  bottom: 64px;
  border-color: var(--warn);
}

.graph-node.danger {
  border-color: var(--danger);
}

.graph-lock {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  border: 1px dashed var(--line);
  background: rgba(5, 11, 9, 0.82);
  color: var(--muted);
  padding: 10px;
  text-align: center;
  font-size: 13px;
}

.timeline {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
  list-style: none;
}

.timeline li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--line);
  background: #081612;
  padding: 14px;
}

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

.timeline li.locked strong {
  filter: blur(3px);
  user-select: none;
}

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

.bar-row {
  display: grid;
  grid-template-columns: 150px 42px 1fr;
  align-items: center;
  gap: 12px;
  color: var(--muted);
}

.bar-row i {
  height: 10px;
  background: #07110f;
  border: 1px solid var(--line);
  position: relative;
}

.bar-row i::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--w);
  background: linear-gradient(90deg, var(--accent), var(--warn), var(--danger));
}

.confidence-meter {
  margin-top: 18px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px 14px;
  align-items: center;
}

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

.confidence-meter i {
  grid-column: 1 / -1;
  height: 12px;
  border: 1px solid var(--line);
  background: #07110f;
  position: relative;
}

.confidence-meter i::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--w);
  background: var(--accent);
}

.sample-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 18px;
  border: 1px solid var(--line);
}

.sample-table td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
}

.locked-card {
  display: grid;
  gap: 16px;
}

.locked-list {
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  list-style: none;
}

.locked-list li {
  border: 1px solid var(--line);
  padding: 12px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.025);
  position: relative;
  overflow: hidden;
}

.locked-list li::after {
  content: "Locked";
  position: absolute;
  right: 10px;
  top: 10px;
  color: var(--warn);
  font-size: 11px;
  font-weight: 900;
}

.purchase-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  border: 1px solid var(--line);
  background: rgba(53, 227, 156, 0.08);
  padding: 16px;
}

.purchase-strip span {
  display: block;
  color: var(--muted);
  margin-bottom: 6px;
}

.purchase-strip strong {
  font-size: 24px;
}

.purchase-strip s {
  color: var(--muted);
  font-size: 16px;
  margin-right: 8px;
}

.locked-card small {
  color: var(--muted);
}

@media (max-width: 920px) {
  .shell,
  .metrics,
  .grid,
  .report-grid,
  .highlight-grid,
  .report-columns,
  .locked-list,
  .tier-grid,
  .buyer-grid {
    grid-template-columns: 1fr;
  }

  .sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .topbar,
  .form-row,
  .report-cover,
  .purchase-strip,
  .data-quality {
    flex-direction: column;
    align-items: stretch;
  }
}
