:root {
  --bg: #f6f8fb;
  --paper: #ffffff;
  --ink: #111827;
  --muted: #657287;
  --line: #dbe3ee;
  --line-strong: #b8c4d6;
  --blue: #225cff;
  --acid: #d9f85d;
  --green: #18a058;
  --orange: #ff6a3d;
  --dark: #08111f;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-display: "Fraunces", "Noto Sans SC", serif;
  --shadow: 10px 12px 0 rgba(17, 24, 39, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: 16px;
  z-index: 20;
  transform: translateY(-140%);
  border: 1px solid var(--ink);
  background: white;
  color: var(--ink);
  opacity: 0;
  padding: 10px 12px;
  pointer-events: none;
  text-decoration: none;
  font-weight: 800;
}

.skip-link:focus-visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.hero {
  position: relative;
  min-height: 92vh;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.radar-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(34, 92, 255, 0.14) 1px, transparent 1px),
    linear-gradient(90deg, rgba(34, 92, 255, 0.14) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(circle at 50% 32%, black 0, rgba(0, 0, 0, 0.7) 34%, transparent 72%);
}

.radar-grid::before,
.radar-grid::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(34, 92, 255, 0.22);
  inset: 12% 22%;
  transform: rotate(-6deg);
}

.radar-grid::after {
  inset: 20% 30%;
  border-color: rgba(255, 106, 61, 0.28);
  transform: rotate(8deg);
}

.shell {
  position: relative;
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 78px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
}

.brand-mark {
  width: 20px;
  height: 20px;
  border: 2px solid var(--ink);
  background:
    linear-gradient(90deg, transparent 45%, var(--ink) 45% 55%, transparent 55%),
    linear-gradient(0deg, transparent 45%, var(--ink) 45% 55%, transparent 55%),
    var(--acid);
  box-shadow: 4px 4px 0 var(--blue);
}

.topnav,
.segmented {
  display: inline-flex;
  gap: 0;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.88);
  padding: 4px;
}

.topnav a,
.segmented button {
  min-height: 34px;
  border: 0;
  background: transparent;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.segmented button {
  cursor: pointer;
}

.topnav a:hover,
.segmented button.active {
  background: var(--ink);
  color: white;
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 54px;
  align-items: center;
  min-height: calc(92vh - 78px);
  padding: 36px 0 80px;
}

.kicker {
  margin: 0 0 14px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 20px;
  font-family: var(--font-display);
  font-size: clamp(54px, 9vw, 112px);
  line-height: 0.9;
  max-width: 760px;
}

h1 span {
  display: block;
}

.hero-lede {
  max-width: 710px;
  color: #303b4d;
  font-size: 18px;
  line-height: 1.8;
}

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

.primary-link,
.ghost-button,
.source-link,
.repo-link {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ink);
  padding: 0 16px;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.primary-link,
.repo-link {
  background: var(--acid);
  color: var(--ink);
  box-shadow: 5px 5px 0 var(--ink);
}

.ghost-button,
.source-link {
  background: white;
  color: var(--ink);
  cursor: pointer;
}

.ghost-button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.hero-panel {
  border: 1px solid var(--ink);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  padding: 18px;
}

.score-box {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.score-box span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.score-box strong {
  font-family: var(--font-display);
  font-size: 34px;
}

.hero-panel p {
  margin: 16px 0 0;
  color: var(--muted);
  line-height: 1.6;
  font-size: 13px;
}

.star-band {
  background: var(--dark);
  color: white;
  padding: 64px 0;
}

.star-shell {
  display: grid;
  gap: 24px;
}

.section-head,
.board-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.section-head h2,
.board-toolbar h2 {
  margin: 0;
  font-size: clamp(28px, 5vw, 48px);
  line-height: 1;
}

.star-band .kicker {
  color: var(--acid);
}

.source-link {
  border-color: white;
  color: white;
  background: transparent;
}

.star-showcase {
  display: grid;
  grid-template-columns: minmax(280px, 1.08fr) minmax(320px, 0.92fr);
  gap: 18px;
}

.lead-card,
.project-card,
.mini-card,
.loading-block {
  border: 1px solid var(--line-strong);
  background: var(--paper);
  color: var(--ink);
}

.lead-card {
  min-height: 360px;
  padding: 24px;
}

.lead-card h3 {
  margin: 22px 0 14px;
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 56px);
  line-height: 0.98;
  overflow-wrap: anywhere;
}

.lead-card p,
.project-card p {
  color: #3e4a5d;
  line-height: 1.7;
}

.lead-card .why-line {
  margin: 18px 0;
  border-left: 4px solid var(--acid);
  padding-left: 12px;
  color: #1f2a3a;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.65;
}

.card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.card-topline span {
  color: var(--ink);
  background: var(--acid);
  border: 1px solid var(--ink);
  padding: 4px 8px;
}

.card-topline em {
  color: var(--blue);
  font-style: normal;
}

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

.mini-card {
  display: grid;
  grid-template-columns: 46px 1fr auto;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 12px;
  text-decoration: none;
}

.mini-card span,
.mini-card em {
  font-weight: 900;
}

.mini-card strong {
  overflow-wrap: anywhere;
}

.mini-card em {
  color: var(--green);
  font-style: normal;
}

.board-section {
  padding: 70px 0 90px;
}

.toolbar-controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}

.search-label input {
  width: min(300px, 72vw);
  min-height: 44px;
  border: 1px solid var(--line-strong);
  background: white;
  color: var(--ink);
  padding: 0 14px;
  font-weight: 700;
}

.status-row {
  margin: 22px 0 18px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 12px 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

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

.project-card {
  min-height: 334px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 0 0 0 transparent;
}

.project-card:nth-child(3n + 1) {
  border-top: 4px solid var(--blue);
}

.project-card:nth-child(3n + 2) {
  border-top: 4px solid var(--green);
}

.project-card:nth-child(3n) {
  border-top: 4px solid var(--orange);
}

.project-card h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.project-card p {
  margin: 0;
  flex: 1;
}

.signal-line {
  border-left: 4px solid var(--acid);
  padding-left: 10px;
  color: #2d3748;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.58;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag-row span {
  border: 1px solid var(--line-strong);
  background: #f8fafc;
  color: #334155;
  padding: 5px 7px;
  font-size: 12px;
  font-weight: 800;
}

.card-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.card-footer a {
  margin-left: auto;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 2px solid var(--acid);
}

.loading-block {
  min-height: 180px;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 900;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 920px) {
  .topbar,
  .section-head,
  .board-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero-layout,
  .star-showcase {
    grid-template-columns: 1fr;
  }

  .hero-layout {
    gap: 28px;
  }

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

@media (max-width: 640px) {
  .shell {
    width: min(100% - 28px, 1180px);
  }

  .hero {
    min-height: auto;
  }

  .topnav {
    width: 100%;
    overflow-x: auto;
  }

  h1 {
    font-size: 48px;
  }

  .hero-layout {
    min-height: auto;
    padding: 28px 0 54px;
  }

  .hero-lede {
    font-size: 16px;
  }

  .toolbar-controls,
  .search-label,
  .search-label input,
  .segmented {
    width: 100%;
  }

  .segmented {
    overflow-x: auto;
  }

  .segmented button {
    flex: 1 0 auto;
  }

  .project-grid {
    grid-template-columns: 1fr;
  }

  .mini-card {
    grid-template-columns: 38px 1fr;
  }

  .mini-card em {
    grid-column: 2;
  }
}
