:root {
  --bg: #262220;
  --panel: #312b27;
  --panel-edge: #463c34;
  --ink: #f2e9df;
  --muted: #b7a99c;
  --coral: #ff7a63;
  --coral-soft: #5a3129;
  --coral-deep: #e05a45;
}

* { box-sizing: border-box; }

html { font-size: 16px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  line-height: 1.75;
}

.site-header {
  border-bottom: 1px solid var(--panel-edge);
  padding: 1rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  align-items: baseline;
  justify-content: space-between;
}

.site-name {
  margin: 0;
  color: var(--coral);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.top-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
}

.top-nav a {
  color: var(--muted);
  text-decoration: none;
}

.top-nav a:hover,
.top-nav a:focus-visible {
  color: var(--ink);
  text-decoration: underline;
}

main {
  max-width: 62rem;
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
}

h1 {
  font-size: 1.75rem;
  line-height: 1.35;
  margin: 0 0 1rem;
}

h2 {
  font-size: 1.25rem;
  margin: 0 0 0.75rem;
}

.lede {
  color: var(--muted);
  margin: 0 0 2rem;
  max-width: 46rem;
}

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

a:hover,
a:focus-visible {
  color: var(--coral-deep);
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--coral);
  outline-offset: 2px;
}

/* 原创流程示意：纯装饰性连接线在 SVG 内，文字在下方泳道中完整可读 */
.flow-svg {
  display: block;
  width: 100%;
  max-width: 900px;
  height: auto;
  margin: 0 auto 2rem;
}

/* 三泳道诊断看板 */
.board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.lane {
  background: var(--panel);
  border: 1px solid var(--panel-edge);
  border-top: 3px solid var(--coral);
  border-radius: 0.5rem;
  padding: 1.25rem 1.25rem 1rem;
  min-width: 0;
}

.lane p {
  margin: 0 0 0.75rem;
  min-width: 0;
  overflow-wrap: break-word;
  word-break: break-word;
}

.status {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 700;
  padding: 0.2rem 0.7rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
}

.status-fill { background: var(--coral-soft); color: var(--coral); }
.status-self { background: #3c4a3a; color: #9fd08f; }
.status-side { background: #4a3c3a; color: #e0a26f; }

.lane-limit {
  border-top: 1px dashed var(--panel-edge);
  padding-top: 0.75rem;
  color: var(--muted);
  font-size: 0.9375rem;
}

.template-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

button {
  font: inherit;
  background: var(--coral);
  color: #241d1a;
  border: none;
  border-radius: 0.375rem;
  padding: 0.5rem 1rem;
  cursor: pointer;
}

button:hover { background: var(--coral-deep); }
button:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

#copy-feedback { color: var(--muted); font-size: 0.875rem; }

.note {
  background: var(--panel);
  border: 1px solid var(--panel-edge);
  border-radius: 0.5rem;
  padding: 1.25rem 1.5rem;
  margin-top: 1.25rem;
}

.note p { min-width: 0; overflow-wrap: break-word; word-break: break-word; }

.note ul {
  margin: 0 0 0.75rem;
  padding-left: 1.25rem;
}

.note li { margin-bottom: 0.5rem; min-width: 0; overflow-wrap: break-word; word-break: break-word; }

.site-footer {
  border-top: 1px solid var(--panel-edge);
  padding: 1.25rem;
  color: var(--muted);
  font-size: 0.9375rem;
}

.site-footer p { margin: 0.25rem 0; min-width: 0; overflow-wrap: break-word; word-break: break-word; }

@media (max-width: 860px) {
  .board { grid-template-columns: minmax(0, 1fr); }
  .flow-svg { max-width: 480px; }
  h1 { font-size: 1.5rem; }
}
