* {
  box-sizing: border-box;
}

:root {
  --bg: #f3f5f7;
  --paper: #ffffff;
  --ink: #1d2733;
  --muted: #647181;
  --line: #d8e0e8;
  --deep: #18212d;
  --blue: #2458a6;
  --green: #17694f;
  --amber: #94610a;
  --red: #9b3b32;
  --soft-blue: #edf4ff;
  --soft-green: #edf7f2;
  --soft-amber: #fff8e7;
  --soft-red: #fff0ee;
  font-family: "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", sans-serif;
  color: var(--ink);
}

body {
  margin: 0;
  background:
    linear-gradient(90deg, rgba(24, 33, 45, 0.05) 1px, transparent 1px),
    linear-gradient(0deg, rgba(24, 33, 45, 0.04) 1px, transparent 1px),
    var(--bg);
  background-size: 28px 28px;
}

a {
  color: var(--blue);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.site-header {
  background: var(--deep);
  color: #fff;
  border-bottom: 5px solid #c9a35b;
}

.header-inner {
  width: min(1220px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 30px 0 28px;
}

.eyebrow {
  color: #d6c08a;
  font-size: 14px;
  margin-bottom: 12px;
}

h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.16;
}

.site-header p {
  max-width: 960px;
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.75;
}

.shell {
  width: min(1220px, calc(100vw - 32px));
  margin: 18px auto 56px;
}

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

.stat,
.filter-panel,
.project-card,
.detail-panel,
.method-panel {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.stat {
  padding: 14px;
}

.stat span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.stat strong {
  display: block;
  margin-top: 7px;
  font-size: 26px;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) repeat(6, minmax(108px, 1fr)) auto;
  gap: 10px;
  padding: 12px;
  position: sticky;
  top: 0;
  z-index: 5;
  box-shadow: 0 8px 18px rgba(24, 33, 45, 0.06);
}

label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
}

input,
select,
button {
  width: 100%;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  padding: 0 10px;
  font: inherit;
}

button {
  align-self: end;
  cursor: pointer;
  background: var(--deep);
  color: #fff;
  border-color: var(--deep);
}

.main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 14px;
  align-items: start;
  margin-top: 14px;
}

.section-title {
  margin: 4px 0 10px;
}

.section-title h2 {
  margin: 0;
  font-size: 20px;
}

.section-title p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

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

.project-card {
  padding: 15px;
  cursor: pointer;
  transition: border-color 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;
}

.project-card:hover,
.project-card.selected {
  border-color: var(--blue);
  box-shadow: 0 10px 22px rgba(36, 88, 166, 0.12);
}

.project-card.selected {
  transform: translateX(3px);
}

.project-card-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.project-card h2 {
  margin: 0;
  font-size: 19px;
  line-height: 1.35;
}

.project-card p {
  margin: 8px 0 0;
  line-height: 1.68;
  color: #344054;
}

.priority {
  min-width: 34px;
  text-align: center;
  padding: 5px 8px;
  border-radius: 6px;
  background: #f5f7fa;
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
}

.priority.high {
  background: var(--soft-red);
  color: var(--red);
}

.meta-line,
.tag-line {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 11px;
}

.meta-line span,
.tag {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f8fafc;
  color: #475467;
  font-size: 12px;
}

.meta-line .good {
  background: var(--soft-green);
  color: var(--green);
}

.meta-line .warn {
  background: var(--soft-amber);
  color: var(--amber);
}

.meta-line .bad {
  background: var(--soft-red);
  color: var(--red);
}

.detail-panel {
  padding: 16px;
  position: sticky;
  top: 78px;
}

.detail-kicker {
  color: var(--blue);
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 8px;
}

.detail-body h2 {
  margin: 0;
  font-size: 24px;
}

.detail-conclusion {
  margin: 10px 0 0;
  padding: 11px 12px;
  border-left: 4px solid var(--blue);
  background: var(--soft-blue);
  line-height: 1.7;
  font-weight: 700;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.detail-grid div {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #fbfcfe;
}

.detail-grid span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.detail-grid strong {
  display: block;
  margin-top: 5px;
  line-height: 1.35;
}

.detail-body h3 {
  margin: 16px 0 8px;
  font-size: 15px;
}

ul,
ol {
  padding-left: 20px;
}

li {
  line-height: 1.68;
  margin: 4px 0;
}

.primary-link {
  display: inline-flex;
  margin-top: 12px;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border-radius: 6px;
  background: var(--deep);
  color: #fff;
  text-decoration: none;
}

.primary-link:hover {
  text-decoration: none;
  background: #233247;
}

.method-panel {
  margin-top: 14px;
  padding: 18px;
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 18px;
}

.method-panel h2 {
  margin: 0 0 8px;
}

.method-panel p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.method-panel ol {
  margin: 0;
}

.empty {
  padding: 20px;
  color: var(--muted);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
}

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

@media (max-width: 980px) {
  .filter-panel,
  .main-grid,
  .method-panel {
    grid-template-columns: 1fr;
  }

  .detail-panel {
    position: static;
  }
}

@media (max-width: 680px) {
  .header-inner,
  .shell {
    width: calc(100vw - 20px);
  }

  .header-inner {
    padding: 22px 0;
  }

  .stat-grid,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .filter-panel {
    position: static;
  }

  .project-card-head {
    display: grid;
  }

  .project-card.selected {
    transform: none;
  }
}
