:root {
  --ink: #17201a;
  --muted: #66736b;
  --line: #dde5df;
  --paper: #fbfcf9;
  --panel: #ffffff;
  --green: #1f8a57;
  --gold: #b8872f;
  --red: #b23b3b;
  --blue: #2b6f9f;
  --shadow: 0 18px 45px rgba(24, 38, 28, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
}

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

button {
  border: 0;
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  padding: 12px 18px;
  cursor: pointer;
  font-weight: 700;
}

button:disabled {
  cursor: wait;
  opacity: 0.65;
}

button.secondary {
  background: #edf5ef;
  color: var(--green);
  border: 1px solid #c9dfd0;
}

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

.sidebar {
  background: #102017;
  color: #fff;
  padding: 24px 18px;
}

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--gold);
  font-weight: 900;
}

.brand span {
  display: block;
  color: #b8c7bd;
  font-size: 12px;
  margin-top: 3px;
}

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

.nav {
  color: #d6e1da;
  background: transparent;
  text-align: left;
  padding: 12px;
  border-radius: 8px;
}

.nav.active {
  background: #213a2a;
  color: #fff;
}

main {
  padding: 28px;
  overflow: auto;
}

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

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

h1 {
  font-size: 32px;
  line-height: 1.15;
  margin-bottom: 0;
}

h2 {
  font-size: 22px;
  margin-bottom: 8px;
}

.eyebrow {
  color: var(--gold);
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 6px;
}

.user-pill {
  padding: 9px 12px;
  background: #edf5ef;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--green);
  white-space: nowrap;
}

.auth-panel,
.guidance,
.panel,
.metrics > div {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.auth-panel {
  min-height: 360px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 28px;
  align-items: center;
  padding: 34px;
  background:
    linear-gradient(120deg, rgba(31, 138, 87, 0.12), transparent),
    linear-gradient(45deg, rgba(184, 135, 47, 0.18), transparent),
    #fff;
}

.auth-copy h2 {
  font-size: 34px;
}

.welcome-list {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.welcome-list span {
  width: fit-content;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  padding: 10px 12px;
  color: var(--ink);
  font-weight: 700;
}

.hidden {
  display: none !important;
}

.guidance {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 22px;
  margin-bottom: 18px;
}

.guidance p {
  color: var(--muted);
  margin-bottom: 0;
}

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

.cockpit {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1.1fr;
  gap: 14px;
  margin-bottom: 18px;
}

.target-card,
.team-card,
.done-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 20px;
}

.target-card span,
.team-card span,
.done-card span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 8px;
}

.target-card strong,
.team-card strong,
.done-card strong {
  display: block;
  font-size: 28px;
  margin-bottom: 10px;
}

.progress-bar {
  height: 10px;
  border-radius: 999px;
  background: #e8eee9;
  overflow: hidden;
  margin: 10px 0;
}

.progress-bar i {
  display: block;
  height: 100%;
  width: 0;
  background: var(--green);
}

.task-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.flow-step {
  border: 1px solid var(--line);
  border-left: 4px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
  box-shadow: var(--shadow);
}

.flow-step.active {
  border-left-color: var(--green);
}

.flow-step span {
  display: block;
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 8px;
}

.flow-step strong {
  display: block;
  margin-bottom: 8px;
}

.flow-step p {
  color: var(--muted);
  line-height: 1.55;
  margin-bottom: 0;
}

.metrics div {
  padding: 18px;
}

.metrics span,
.growth-board span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 8px;
}

.metrics strong,
.growth-board strong {
  font-size: 28px;
}

.two-col {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(360px, 1.1fr);
  gap: 18px;
}

.panel {
  padding: 22px;
}

.panel-head {
  margin-bottom: 16px;
}

.panel-head.inline {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.form {
  display: grid;
  gap: 13px;
}

.form.compact {
  gap: 10px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

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

textarea {
  min-height: 92px;
  resize: vertical;
}

.report {
  background: #f6f8f5;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  line-height: 1.75;
  white-space: pre-wrap;
}

.empty {
  color: var(--muted);
}

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

.asset,
.agent,
.growth-board > div,
.list-item,
.release-gate {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: #fff;
}

.agent-workflow {
  display: grid;
  gap: 14px;
}

.agent-card {
  display: grid;
  grid-template-columns: 56px 1.1fr 1fr;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
}

.avatar {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #102017;
  color: #fff;
  font-weight: 900;
  font-size: 20px;
}

.agent-head {
  grid-column: span 2;
}

.agent-head h3 {
  margin: 6px 0 6px;
}

.agent-head p {
  color: var(--muted);
  line-height: 1.55;
  margin-bottom: 0;
}

.agent-input {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #f8faf7;
}

.agent-input p {
  color: var(--muted);
  margin: 8px 0 0;
  line-height: 1.55;
}

.agent-result {
  grid-column: 1 / -1;
  min-height: 96px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f6f8f5;
  padding: 14px;
  white-space: pre-wrap;
  line-height: 1.7;
}

.agent-card .agent-next {
  grid-column: 1 / -1;
  justify-self: start;
}

.task-list {
  display: grid;
  gap: 10px;
}

.task-item {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 14px;
}

.task-item span {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #edf5ef;
  color: var(--green);
  font-weight: 900;
}

.task-item em {
  font-style: normal;
  color: var(--muted);
}

.task-item p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.task-item.done {
  border-left: 4px solid var(--green);
}

.startup-checklist {
  display: grid;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf7;
  padding: 14px;
  margin-bottom: 14px;
}

.startup-checklist p {
  margin-bottom: 4px;
  font-weight: 800;
}

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

.startup-checklist span.done {
  color: var(--green);
  font-weight: 800;
}

.asset h3,
.agent h3 {
  margin-bottom: 8px;
}

.asset p,
.agent p,
.list-item p {
  color: var(--muted);
  line-height: 1.65;
  margin-bottom: 0;
}

.agent .badge {
  display: inline-block;
  color: #fff;
  background: var(--blue);
  border-radius: 8px;
  padding: 4px 8px;
  font-size: 12px;
  margin-bottom: 10px;
}

.list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.growth-board {
  grid-template-columns: repeat(4, 1fr);
  margin-bottom: 16px;
}

.growth-board small {
  display: block;
  color: var(--muted);
  margin-top: 8px;
}

.release-gate {
  border-left: 4px solid var(--green);
}

#toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  background: #102017;
  color: #fff;
  padding: 12px 16px;
  border-radius: 8px;
  opacity: 0;
  transform: translateY(10px);
  transition: 0.2s ease;
  pointer-events: none;
}

#toast.show {
  opacity: 1;
  transform: translateY(0);
}

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

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 14px;
  }

  nav {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    overflow-x: auto;
  }

  .nav {
    text-align: center;
    white-space: nowrap;
  }

  .auth-panel,
  .two-col,
  .metrics,
  .task-flow,
  .asset-grid,
  .agent-grid,
  .agent-card,
  .growth-board {
    grid-template-columns: 1fr;
  }

  .topbar,
  .guidance,
  .panel-head.inline {
    flex-direction: column;
  }
}
