:root {
  --bg: #f4efe8;
  --surface: rgba(255, 255, 255, 0.78);
  --surface-strong: rgba(255, 255, 255, 0.96);
  --ink: #132937;
  --muted: #627783;
  --line: rgba(19, 41, 55, 0.1);
  --accent: #ff6a3d;
  --accent-deep: #cb4d23;
  --safe: #1f8f58;
  --watch: #b77819;
  --risk: #ba4030;
  --navy: #173b4f;
  --shadow: 0 20px 50px rgba(28, 51, 65, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Avenir Next", "PingFang SC", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(255, 106, 61, 0.12), transparent 28%),
    linear-gradient(180deg, #fffaf4 0%, var(--bg) 100%);
  color: var(--ink);
  min-height: 100vh;
  overflow-x: hidden;
}

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

.bg-orb {
  position: fixed;
  width: 440px;
  height: 440px;
  border-radius: 50%;
  filter: blur(40px);
  pointer-events: none;
  z-index: -1;
}

.bg-orb-a {
  top: -140px;
  right: -80px;
  background: rgba(255, 106, 61, 0.12);
}

.bg-orb-b {
  bottom: 4%;
  left: -160px;
  background: rgba(23, 59, 79, 0.09);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.8fr);
  gap: 24px;
  align-items: end;
  padding: 10px 0 20px;
}

.hero-copy {
  max-width: 760px;
}

.eyebrow {
  display: inline-block;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 107, 53, 0.12);
  color: var(--accent-deep);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 12px;
}

h1, h2, h3 {
  margin: 0 0 12px;
}

h1 {
  margin-top: 18px;
  font-size: clamp(40px, 6vw, 76px);
  line-height: 0.92;
  letter-spacing: -0.04em;
}

.subtitle,
.muted,
.summary-list,
.empty-state,
table {
  color: var(--muted);
}

.subtitle {
  max-width: 760px;
  font-size: 18px;
  line-height: 1.55;
}

.hero-actions {
  display: flex;
  gap: 12px;
  margin-top: 26px;
}

.hero-aside {
  display: flex;
  justify-content: flex-end;
}

.hero-aside-card {
  width: 100%;
  max-width: 320px;
  min-height: 220px;
  padding: 22px;
  border-radius: 28px;
  background:
    linear-gradient(160deg, rgba(19, 41, 55, 0.98), rgba(26, 65, 88, 0.92));
  color: #f4f6f7;
  box-shadow: 0 24px 60px rgba(16, 33, 44, 0.18);
}

.mini-label,
.section-tag {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 12px;
  font-weight: 800;
}

.mini-label {
  color: rgba(255, 255, 255, 0.72);
}

.mini-flow {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}

.mini-flow span {
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.12);
  font-size: 13px;
}

.mini-copy {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.6;
}

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

.metric-tile {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 18px;
  box-shadow: var(--shadow);
}

.metric-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.metric-value {
  margin-top: 10px;
  font-size: 34px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.metric-foot {
  margin-top: 10px;
  font-size: 13px;
  color: var(--accent-deep);
  font-weight: 700;
}

.panel {
  margin-top: 22px;
}

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

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

.card {
  background: var(--surface);
  backdrop-filter: blur(16px);
  border: 1px solid var(--line);
  border-radius: 26px;
  box-shadow: var(--shadow);
  padding: 24px;
}

.field {
  display: block;
  margin-bottom: 16px;
}

.field span {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 8px;
}

select,
textarea,
button {
  font: inherit;
}

select,
textarea {
  width: 100%;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--surface-strong);
  padding: 14px 16px;
  color: var(--ink);
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.checkbox-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(23, 49, 63, 0.05);
  color: var(--ink);
}

.actions {
  display: flex;
  gap: 12px;
}

button {
  border: 0;
  border-radius: 16px;
  padding: 13px 18px;
  background: var(--accent);
  color: white;
  font-weight: 700;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, opacity 180ms ease;
  box-shadow: 0 12px 28px rgba(255, 106, 61, 0.24);
}

button.secondary {
  background: rgba(23, 49, 63, 0.12);
  color: var(--ink);
  box-shadow: none;
}

button:hover {
  transform: translateY(-1px);
}

.summary-list p,
.evidence-item,
.content-item,
.action-item {
  margin: 0 0 12px;
}

.summary-list p:last-child,
.evidence-item:last-child,
.content-item:last-child,
.action-item:last-child {
  margin-bottom: 0;
}

.hidden {
  display: none;
}

.section-tag {
  color: var(--accent-deep);
  margin-bottom: 6px;
}

.meta-row,
.decision-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 18px;
}

.meta-pill,
.stat-pill {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(23, 49, 63, 0.05);
  border: 1px solid rgba(23, 49, 63, 0.06);
  font-size: 13px;
}

.result-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 18px;
}

.top-sku {
  font-size: 28px;
  font-weight: 800;
}

.top-narrative {
  max-width: 680px;
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.6;
}

.risk-badge {
  min-width: 120px;
  text-align: center;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 800;
  text-transform: uppercase;
}

.risk-safe {
  background: rgba(44, 122, 75, 0.14);
  color: var(--safe);
}

.risk-watch {
  background: rgba(185, 121, 25, 0.14);
  color: var(--watch);
}

.risk-high_risk {
  background: rgba(176, 63, 47, 0.14);
  color: var(--risk);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

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

th {
  color: var(--ink);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.evidence-item,
.content-item,
.action-item {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.72);
}

.benchmark-highlight {
  margin-bottom: 18px;
  padding: 16px 18px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(255, 106, 61, 0.12), rgba(255, 255, 255, 0.65));
  color: var(--ink);
  border: 1px solid rgba(255, 106, 61, 0.12);
}

.kpi-good {
  color: var(--safe);
  font-weight: 700;
}

.kpi-cold {
  color: var(--accent-deep);
  font-weight: 700;
}

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

  .result-header {
    flex-direction: column;
  }

  .actions {
    flex-direction: column;
  }

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