:root {
  --bg: #08131f;
  --bg-raised: #0d1b2a;
  --panel: #0f2030;
  --panel-soft: #122739;
  --line: rgba(153, 198, 220, 0.16);
  --line-strong: rgba(153, 198, 220, 0.3);
  --text: #edf7fa;
  --muted: #91aab6;
  --cyan: #55d6e7;
  --lime: #b9e46b;
  --amber: #f3c46a;
  --pink: #ee8ab7;
  --font-ui: "Source Han Sans SC", "Noto Sans CJK SC", "思源黑体", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-display: "Source Han Serif SC", "Noto Serif CJK SC", "思源宋体", "STSong", "Songti SC", serif;
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--bg); }
body { margin: 0; color: var(--text); background: var(--bg); font-family: var(--font-ui); font-size: 16px; line-height: 1.5; }
body::before { content: ""; position: fixed; inset: 0; pointer-events: none; opacity: .32; background-image: linear-gradient(rgba(106, 172, 192, .055) 1px, transparent 1px), linear-gradient(90deg, rgba(106, 172, 192, .055) 1px, transparent 1px); background-size: 44px 44px; mask-image: linear-gradient(to bottom, black, transparent 80%); }
a { color: inherit; text-decoration: none; }
.app-shell { position: relative; z-index: 1; width: min(1320px, calc(100% - 48px)); margin: 0 auto; }
.topbar { min-height: 84px; display: flex; align-items: center; gap: 40px; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 11px; min-width: 250px; }
.brand img { display: block; }
.brand-copy { display: grid; gap: 0; }
.brand-copy strong { font-size: 18px; letter-spacing: .02em; }
.brand-copy small { color: var(--muted); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 9px; letter-spacing: .2em; }
.nav { display: flex; align-self: stretch; align-items: center; gap: 30px; }
.nav-link { position: relative; display: inline-flex; align-items: center; height: 100%; color: var(--muted); font-size: 16px; font-weight: 600; transition: color .2s ease; }
.nav-link:hover, .nav-link.is-active { color: var(--text); }
.nav-link.is-active::after { content: ""; position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; background: var(--cyan); }
.console-link { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; color: var(--cyan); font-size: 15px; font-weight: 700; }
.console-link svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.6; transition: transform .2s ease; }
.console-link:hover svg { transform: translateX(3px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) 390px; align-items: center; gap: 48px; min-height: 410px; padding: 68px 4px 58px; border-bottom: 1px solid var(--line); }
.eyebrow, .panel-kicker { margin: 0 0 14px; color: var(--cyan); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 11px; font-weight: 700; letter-spacing: .16em; }
.pulse-dot { display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 4px rgba(185, 228, 107, .12); vertical-align: 1px; }
h1 { max-width: 680px; margin: 0; font-family: var(--font-display); font-size: clamp(42px, 6vw, 76px); font-weight: 500; letter-spacing: 0; line-height: 1.06; }
h1 em { color: var(--cyan); font-style: normal; }
.hero-description { max-width: 490px; margin: 23px 0 0; color: var(--muted); font-size: 17px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 31px; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 18px; border: 1px solid var(--line-strong); font-size: 15px; font-weight: 700; transition: border-color .2s ease, background .2s ease, transform .2s ease; }
.button:hover { transform: translateY(-2px); border-color: var(--cyan); }
.button-primary { gap: 16px; color: #06131d; border-color: var(--cyan); background: var(--cyan); }
.button-primary span { font-size: 19px; line-height: 1; }
.button-quiet { color: var(--text); background: rgba(255, 255, 255, .02); }
.status-orbit { position: relative; width: 320px; height: 320px; margin: 0 auto; }
.orbit-ring { position: absolute; inset: 50%; border: 1px solid var(--line-strong); border-radius: 50%; transform: translate(-50%, -50%); }
.ring-one { width: 232px; height: 232px; border-color: rgba(85, 214, 231, .42); }
.ring-two { width: 316px; height: 316px; border-style: dashed; border-color: rgba(185, 228, 107, .24); }
.orbit-core { position: absolute; top: 50%; left: 50%; display: grid; width: 146px; height: 146px; align-content: center; justify-items: center; border: 1px solid var(--cyan); background: var(--panel); transform: translate(-50%, -50%); box-shadow: 0 0 35px rgba(85, 214, 231, .13); }
.core-label { color: var(--muted); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 10px; letter-spacing: .2em; }
.orbit-core strong { margin: 4px 0 0; color: var(--lime); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 29px; }
.orbit-core small { color: var(--muted); font-size: 12px; }
.orbit-node { position: absolute; width: 9px; height: 9px; border: 2px solid var(--bg); border-radius: 50%; }
.node-a { top: 24px; left: 154px; background: var(--cyan); box-shadow: 0 0 14px var(--cyan); }
.node-b { right: 11px; bottom: 88px; background: var(--amber); box-shadow: 0 0 14px var(--amber); }
.node-c { bottom: 19px; left: 79px; background: var(--pink); box-shadow: 0 0 14px var(--pink); }
.metrics-row { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--line); }
.metric-card { min-height: 142px; padding: 23px 23px 20px; border-right: 1px solid var(--line); }
.metric-card:first-child { border-left: 1px solid var(--line); }
.metric-card:last-child { border-right: 0; }
.metric-heading { display: flex; justify-content: space-between; color: var(--muted); font-size: 13px; }
.metric-index { color: var(--cyan); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 11px; }
.metric-card strong { display: block; margin-top: 17px; color: var(--text); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 28px; font-weight: 500; }
.metric-card strong small { color: var(--muted); font-size: 13px; }
.metric-card p { margin: 3px 0 0; color: var(--muted); font-size: 12px; }
.metric-accent strong { color: var(--amber); }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(310px, .85fr); gap: 18px; padding: 26px 0 30px; }
.panel { min-width: 0; border: 1px solid var(--line); background: rgba(15, 32, 48, .78); }
.panel-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 22px 24px 0; }
.panel-kicker { margin-bottom: 7px; color: var(--muted); font-size: 10px; }
h2 { margin: 0; font-family: var(--font-display); font-size: 25px; font-weight: 500; }
.live-tag, .panel-code { color: var(--lime); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 11px; letter-spacing: .08em; }
.chart-wrap { position: relative; min-height: 220px; margin: 16px 20px 0; }
#latency-chart { display: block; width: 100%; height: 220px; overflow: visible; }
.chart-grid-lines line { stroke: rgba(153, 198, 220, .12); stroke-width: 1; }
.chart-line { fill: none; stroke: var(--cyan); stroke-width: 2.5; vector-effect: non-scaling-stroke; }
.chart-area { fill: rgba(85, 214, 231, .08); }
.chart-points circle { fill: var(--cyan); stroke: var(--bg-raised); stroke-width: 2; }
.chart-empty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: 13px; pointer-events: none; }
.chart-empty[hidden] { display: none; }
.chart-footer { display: flex; justify-content: space-between; gap: 12px; padding: 0 24px 20px; color: var(--muted); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 10px; }
.route-list { padding: 19px 24px 8px; }
.route-item { display: grid; grid-template-columns: 31px 1fr auto; align-items: center; gap: 13px; min-height: 54px; }
.route-number { color: var(--cyan); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 11px; }
.route-item strong, .route-item small { display: block; }
.route-item strong { font-size: 15px; }
.route-item small { margin-top: 1px; color: var(--muted); font-size: 12px; }
.route-state { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 10px; letter-spacing: .06em; }
.route-state.is-ready { color: var(--lime); }
.route-state.is-config { color: var(--amber); }
.route-connector { width: 1px; height: 17px; margin-left: 15px; background: var(--line-strong); }
.panel-link { display: flex; justify-content: space-between; margin: 12px 24px 21px; padding-top: 14px; border-top: 1px solid var(--line); color: var(--cyan); font-size: 13px; font-weight: 700; }
.panel-link span { font-size: 18px; line-height: 1; }
.footer-strip { display: flex; justify-content: space-between; gap: 20px; padding: 19px 4px 28px; color: var(--muted); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 10px; letter-spacing: .08em; }
.footer-strip > div { display: flex; align-items: center; gap: 9px; }
.footer-mark { display: grid; width: 22px; height: 22px; place-items: center; color: var(--bg); background: var(--cyan); font-family: var(--font-display); font-size: 14px; font-weight: 700; }
.footer-strip strong { color: var(--text); font-weight: 500; }

@media (max-width: 900px) {
  .app-shell { width: min(100% - 32px, 720px); }
  .topbar { gap: 22px; }
  .brand { min-width: auto; }
  .brand-copy small { display: none; }
  .nav { gap: 19px; }
  .console-link span { display: none; }
  .hero-grid { grid-template-columns: 1fr; min-height: auto; padding-top: 50px; }
  .status-orbit { order: -1; width: 250px; height: 250px; }
  .ring-one { width: 185px; height: 185px; }
  .ring-two { width: 245px; height: 245px; }
  .orbit-core { width: 124px; height: 124px; }
  .node-a { top: 15px; left: 121px; }
  .node-b { right: 2px; bottom: 68px; }
  .node-c { bottom: 8px; left: 56px; }
  .dashboard-grid { grid-template-columns: 1fr; }
}

@media (max-width: 610px) {
  .app-shell { width: calc(100% - 24px); }
  .topbar { min-height: 70px; gap: 16px; }
  .brand-copy strong { font-size: 16px; }
  .nav { gap: 13px; }
  .nav-link { font-size: 14px; }
  .hero-grid { padding: 40px 0 45px; gap: 30px; }
  h1 { font-size: 43px; }
  .hero-description { font-size: 15px; }
  .metrics-row { grid-template-columns: repeat(2, 1fr); }
  .metric-card { min-height: 126px; padding: 17px 14px; }
  .metric-card:nth-child(2) { border-right: 0; }
  .metric-card:nth-child(3), .metric-card:nth-child(4) { border-top: 1px solid var(--line); }
  .metric-card strong { margin-top: 13px; font-size: 23px; }
  .panel-header { padding-left: 17px; padding-right: 17px; }
  .chart-wrap { margin-right: 12px; margin-left: 12px; }
  .chart-footer { padding-right: 17px; padding-left: 17px; }
  .route-list { padding-right: 17px; padding-left: 17px; }
  .panel-link { margin-right: 17px; margin-left: 17px; }
  .footer-strip { flex-direction: column; gap: 8px; padding-bottom: 21px; }
}
