/* ============================================================
   myip — 墨与信号（Ink & Signal）
   坐标纸底、1px 发丝线、软阴影、信号绿角标、仪表牌序号
   数据用等宽，结论用颜色，其余一律退到背景里
   色板只有两个方向：墨（中性带一点绿）与信号（青绿），警示色只做语义补充
   ============================================================ */

:root {
  /* 纸与墨：三段纸面（底 / 卡 / 凹面）与四级墨色，每一段都拉开一档 */
  --paper: #edeee9;
  --card: #fbfbf8;
  --panel: #e5e8e1;
  --ink: #101614;
  --ink-soft: #3a4642;
  --ink-muted: #57655f;
  --ink-faint: #67766f;

  /* 线与面 */
  --edge: 1px;
  --line: rgba(16, 22, 20, 0.24);
  --line-soft: rgba(16, 22, 20, 0.12);
  --line-dash: rgba(16, 22, 20, 0.26);

  /* 坐标纸：细网格 + 五格一条主格，像工程纸而不只是底纹 */
  --grid: rgba(16, 22, 20, 0.05);
  --grid-major: rgba(16, 22, 20, 0.09);
  --glow: rgba(12, 115, 96, 0.1);
  --header-bg: rgba(237, 238, 233, 0.86);

  /* 信号色：只给动作、读数与结论 */
  --signal: #0c7360;
  --signal-deep: #085649;
  --signal-ink: #f3fbf8;
  --signal-ring: rgba(12, 115, 96, 0.35);

  /* 读数块：整张反色的卡，字、线、面自成一套，不借用纸面的 token */
  --block: #13211d;
  --block-face: #081411;
  --block-ink: #e8f3ee;
  --block-ink-soft: #9cb3a9;
  --block-line: rgba(232, 243, 238, 0.2);
  --block-signal: #4fd7ae;

  /* 状态：只做文字色，不铺面 */
  --ok-ink: #0f6a4d;
  --warn-ink: #855700;
  --danger: #ab3527;
  --danger-soft: #f6ded7;

  /* 色带与淡面：同一族（青绿 / 中性 / 暖沙），只差色相，亮度对齐 */
  --tint-good: #a9dcc2;
  --tint-warn: #e8cf8d;
  --tint-hot: #eeb9a4;
  --tint-flag: #bd802c;
  --wash-good: #e3f0ea;
  --wash-neutral: #e6e9e4;
  --wash-warn: #f7efe1;

  /* 阴影：全部是光，不是黑块 */
  --shadow-xs: 0 1px 1px rgba(16, 22, 20, 0.14);
  --shadow-sm: 0 1px 2px rgba(16, 22, 20, 0.14);
  --shadow-md: 0 5px 12px -7px rgba(16, 22, 20, 0.42);
  --shadow: 0 1px 0 var(--line-soft), 0 14px 28px -20px rgba(16, 22, 20, 0.5);

  --radius-card: 12px;
  --radius-panel: 8px;
  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB',
    'Microsoft YaHei', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas,
    'Liberation Mono', monospace;

  /* 全球网络背景（globe.js 主题感知变量，浅色默认） */
  --globe-accent: #0fa3c4;       /* 请求方向（向页面青绿色相靠拢） */
  --globe-accent-soft: #7fd6e2;  /* 陆地点阵 / 节点光晕 */
  --globe-response: #7c5cd6;     /* 响应方向 */
  --globe-citylight: #ffffff;    /* 城市灯光点缀 */
  --globe-body: #0e3f55;         /* 球体体质（深青蓝，与纸面青绿同族） */
  --globe-limb: #38a8c6;         /* 临边增亮 / 大气辉光（青调，不与纸面冲突） */
  color-scheme: light;
}

:root[data-theme='dark'] {
  --paper: #090f0d;
  --card: #101917;
  --panel: #16211d;
  --ink: #e9f0ec;
  --ink-soft: #c2cfc8;
  --ink-muted: #8fa199;
  --ink-faint: #7b8d85;

  --line: rgba(233, 240, 236, 0.26);
  --line-soft: rgba(233, 240, 236, 0.12);
  --line-dash: rgba(233, 240, 236, 0.22);
  --grid: rgba(233, 240, 236, 0.045);
  --grid-major: rgba(233, 240, 236, 0.08);
  --glow: rgba(70, 214, 169, 0.09);
  --header-bg: rgba(9, 15, 13, 0.84);

  --signal: #46d6a9;
  --signal-deep: #79e3c0;
  --signal-ink: #05201a;
  --signal-ring: rgba(70, 214, 169, 0.32);
  /* 暗色下纸面本身就深，读数块要再往下坑一层，不然和周围的卡分不开 */
  --block: #061310;
  --block-face: #020c0a;
  --block-ink: #dbece4;
  --block-ink-soft: #85a397;
  --block-line: rgba(219, 236, 228, 0.18);
  --block-signal: #5fe0b6;

  --ok-ink: #6fe3b2;
  --warn-ink: #ecc470;
  --danger: #ff9f89;
  --danger-soft: #3a1f1a;

  --tint-good: #193a2e;
  --tint-warn: #3d3118;
  --tint-hot: #3f2821;
  --tint-flag: #cfa25b;
  --wash-good: #13241e;
  --wash-neutral: #18231f;
  --wash-warn: #262014;

  --shadow-xs: 0 1px 1px rgba(0, 0, 0, 0.5);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.45);
  --shadow-md: 0 6px 14px -8px rgba(0, 0, 0, 0.75);
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.05), 0 16px 30px -22px #000;

  /* 全球网络背景（globe.js 主题感知变量，深色覆盖） */
  --globe-accent: #4fd7ff;
  --globe-accent-soft: #a5e9f8;
  --globe-response: #a78bfa;
  --globe-citylight: #f2feff;
  --globe-body: #0d2c4e;
  --globe-limb: #3fb6e8;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

/* hidden 属性必须无条件生效：任何 author display 规则（flex/grid/inline-flex）
   都会覆盖 UA 的 [hidden]{display:none}，导致 JS 用 hidden 开关的空态/徽章失效 */
[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

[id] {
  scroll-margin-top: 96px;
}

body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  background-color: var(--paper);
  /* 坐标纸：细格 26px，每五格一条主格 130px；顶部一层信号光 */
  background-image:
    linear-gradient(var(--grid-major) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-major) 1px, transparent 1px),
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px),
    radial-gradient(140% 52% at 50% -12%, var(--glow), transparent 68%);
  background-size:
    130px 130px,
    130px 130px,
    26px 26px,
    26px 26px,
    100% 100%;
  background-position: 0 0;
  background-attachment: scroll, scroll, scroll, scroll, fixed;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.mono,
#header-ip,
.ip-capsule-value,
.summary-ip,
.summary-path,
.row-value,
.live-value,
.map-tip,
.footer-meta,
.stat dd,
code {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
}

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

a {
  color: inherit;
}

/* ---------------- 顶栏 ---------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 28px;
  height: 64px;
  padding: 0 34px;
  background: var(--header-bg);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: var(--edge) solid var(--line);
}

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

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--signal);
  color: var(--signal-ink);
}

.brand-mark svg {
  width: 22px;
  height: 22px;
}

.brand-mark-sm {
  width: 22px;
  height: 22px;
  border-radius: 6px;
}

.brand-mark-sm svg {
  width: 15px;
  height: 15px;
}

.brand-name {
  font-family: var(--mono);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  position: relative;
  padding: 8px 12px;
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.15s ease;
}

/* 导航选中态用一条信号下划线，不用胶囊底，免得顶栏看起来也是一堆便当卡 */
.nav-link::after {
  content: '';
  position: absolute;
  right: 12px;
  bottom: -5px;
  left: 12px;
  height: 2px;
  background: var(--signal);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.18s ease;
}

.nav-link:hover {
  color: var(--ink);
}

.nav-link:hover::after {
  transform: scaleX(0.35);
}

.nav-link.is-active {
  color: var(--ink);
  font-weight: 700;
}

.nav-link.is-active::after {
  transform: scaleX(1);
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.ip-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  height: 34px;
  padding: 0 13px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--card);
  font-size: 13px;
  box-shadow: var(--shadow-xs);
}

.ip-pill-dot {
  position: relative;
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--signal);
}

/* 顶栏的 IP 是持续读数，用一个慢速扩散环表示「还在监听」 */
.ip-pill-dot::after {
  content: '';
  position: absolute;
  inset: -3px;
  border: 1px solid var(--signal-ring);
  border-radius: 50%;
  animation: signal-ping 2.6s ease-out infinite;
}

@keyframes signal-ping {
  0% {
    transform: scale(0.55);
    opacity: 1;
  }

  70%,
  100% {
    transform: scale(1.9);
    opacity: 0;
  }
}

.ip-pill-value {
  font-size: 13px;
  font-weight: 500;
}

/* 唯一头部工具按钮：隐私开关（主题固定夜间，不再提供切换） */
.privacy-btn {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: var(--edge) solid var(--line);
  border-radius: 10px;
  background: var(--card);
  color: var(--ink);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: background 0.15s ease, transform 0.12s ease, box-shadow 0.12s ease;
}

.privacy-btn:hover {
  background: var(--panel);
  transform: translate(-1px, -1px);
  box-shadow: var(--shadow-md);
}

.privacy-btn:active {
  transform: translate(1px, 1px);
  box-shadow: var(--shadow-xs);
}

.privacy-btn svg {
  width: 17px;
  height: 17px;
}

/* 隐私模式按钮：图标随开关在睁眼 / 闭眼间切换 */
.privacy-btn[aria-pressed='true'] {
  border-color: var(--signal);
  color: var(--signal);
}

.privacy-btn .icon-eye-off,
.privacy-btn[aria-pressed='true'] .icon-eye {
  display: none;
}

.privacy-btn[aria-pressed='true'] .icon-eye-off {
  display: block;
}

/* 隐私模式：把敏感读数模糊成一团柔光。
   相比圆点掩码，原排版的宽度、位置、颜色都保留，视觉上自然得多，
   又不会透出可读轮廓；filter 同时作用于旗标等子元素，无需逐个隐藏。 */
[data-privacy='on'] [data-private] {
  filter: blur(6px);
  opacity: 0.45;
  user-select: none;
  pointer-events: none;
}

/* 大号 IP 字重高、原带光晕，需要更大的模糊半径才不露数字轮廓 */
[data-privacy='on'] #globe-ip {
  filter: blur(14px);
  opacity: 0.38;
}

/* 焦点统一：一圈信号色，比原来那种粗黑描边更准也更克制 */
a:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 2px;
}

/* iOS 横竖屏切换时不会擅自放大字号，保持移动端排版稳定 */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* 去掉移动端点击 300ms 延迟与灰色高亮块 */
.btn,
.nav-link,
a,
summary,
input,
.privacy-btn {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

/* ---------------- 便当网格 ---------------- */

.bento {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 22px;
  max-width: 1320px;
  margin: 0 auto;
  padding: 26px 34px 0;
  align-items: stretch;
  counter-reset: card;
}

/* 卡壳：发丝线轮廓 + 左上、右下两个信号角标，像仪表盘的定位框 */
.card {
  position: relative;
  min-width: 0;
  padding: 22px 24px;
  background: var(--card);
  border: var(--edge) solid var(--line-soft);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
}

.card::before,
.card::after {
  content: '';
  position: absolute;
  width: 11px;
  height: 11px;
  border: 0 solid var(--signal);
  opacity: 0.7;
  pointer-events: none;
}

.card::before {
  top: -1px;
  left: -1px;
  border-top-width: 2px;
  border-left-width: 2px;
  border-top-left-radius: var(--radius-card);
}

.card::after {
  right: -1px;
  bottom: -1px;
  border-right-width: 2px;
  border-bottom-width: 2px;
  border-bottom-right-radius: var(--radius-card);
}

.card-hero {
  grid-column: span 8;
  display: flex;
  flex-direction: column;
  padding: 22px 24px 20px;
}

.card-live {
  grid-column: span 4;
  display: flex;
  flex-direction: column;
  background: var(--block);
  border-color: var(--block-line);
  color: var(--block-ink);
}

.card-live::before,
.card-live::after {
  opacity: 1;
  border-color: var(--block-signal);
}

.card-live .btn-block {
  margin-top: auto;
}

.card-live .footnote {
  padding-top: 14px;
  color: var(--block-ink-soft);
}

.card-live .card-title {
  color: var(--block-ink);
}

.card-detail {
  grid-column: span 5;
  display: flex;
  flex-direction: column;
}

.card-map {
  grid-column: span 7;
  display: flex;
  flex-direction: column;
}

.card-alias,
.card-time,
.card-risk,
.card-webrtc,
.card-dns,
.card-net,
.card-status,
.card-ai,
.card-lime,
.card-lav {
  display: flex;
  flex-direction: column;
  align-self: stretch;
}

.card-alias {
  grid-column: span 3;
}

.card-time {
  grid-column: span 5;
}

/* 风险信号：卡面保持中性，预警色只给标签本身，不整块刷黄 */
.card-risk {
  grid-column: span 4;
}

.card-net {
  grid-column: span 7;
}

/* 两张泄露卡各占整行，上下摞着读：一次看四台 STUN，解析器也能铺开成两列 */
.card-webrtc {
  grid-column: span 12;
}

.card-dns {
  grid-column: span 12;
}

.card-status {
  grid-column: span 5;
}

.card-ai {
  grid-column: span 7;
}

/* 会话卡不再铺色：卡面回到瓷白，身份交给信号色的读数和凹面的 chip */
.card-lime {
  grid-column: span 5;
}

.card-lime .stat dd {
  color: var(--signal);
  font-weight: 700;
}

.card-lime .chip {
  background: var(--panel);
}

/* 整行的参考块往下坑一层，靠明度而不是色相分层 */
.card-lav {
  grid-column: span 12;
  background: var(--panel);
}

/* 段落带：一格拉通整行，用等宽序号 + 小节名 + 发丝线，把十四张卡分成四组 */
.band {
  grid-column: span 12;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
}

.band:first-child {
  margin-top: 0;
}

.band-index {
  color: var(--signal);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

.band-label {
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  white-space: nowrap;
}

.band-rule {
  flex: 1;
  height: 1px;
  background: var(--line-soft);
}

/* ---------------- 标题与文字 ---------------- */

.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 22px;
  color: var(--ink-soft);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.eyebrow-mark {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--signal);
  box-shadow: 0 0 0 3px var(--signal-ring);
}

.hero-title {
  margin: 0;
  font-size: clamp(34px, 4.1vw, 52px);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
}

.hero-line {
  display: block;
}

/* 关键词不整块刷色，只在字底压一道记号笔色带 */
.mark {
  display: inline-block;
  margin: 0 0.02em;
  padding: 0 0.06em 0.02em;
  color: var(--ink);
  line-height: 1.05;
  /* 得显式清掉 UA 的 background-color: yellow，否则只剩色带叠在黄块上 */
  background-color: transparent;
  background-image: linear-gradient(var(--mark-tint), var(--mark-tint));
  background-repeat: no-repeat;
  background-size: 100% 0.32em;
  background-position: 0 94%;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.mark-pink {
  --mark-tint: var(--tint-hot);
}

.mark-lemon {
  --mark-tint: var(--tint-warn);
}

.mark-lime {
  --mark-tint: var(--tint-good);
}

.sep {
  display: inline-block;
  margin: 0 0.02em;
  color: var(--ink);
  font-weight: 500;
}

.lede {
  max-width: 58ch;
  margin: 20px 0 0;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.75;
}

/* 卡头自动编号：序号交给 CSS 计数器，插卡、删卡都不用手工改标号 */
.card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: var(--edge) solid var(--line-soft);
  counter-increment: card;
}

.card-head::before {
  content: counter(card, decimal-leading-zero);
  flex: none;
  padding: 1px 6px;
  border: var(--edge) solid var(--line-soft);
  border-radius: 5px;
  color: var(--ink-muted);
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.card-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 16px;
  font-weight: 700;
}

.card-title svg {
  width: 18px;
  height: 18px;
}

.card-live .card-head::before {
  border-color: var(--block-line);
  color: var(--block-ink-soft);
}

.card-live .card-head {
  border-bottom-color: var(--block-line);
}

.head-actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

.footnote {
  margin: 12px 0 0;
  font-size: 11px;
  line-height: 1.65;
  color: var(--ink-muted);
}

/* ---------------- 按钮 ---------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 20px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--card);
  color: var(--ink);
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--shadow-xs);
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.15s ease,
    border-color 0.15s ease, color 0.15s ease;
}

/* 悬停只抬起 1px 并把描边换成信号色，不做原来那种整体斜推 + 硬阴影 */
.btn:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: var(--signal);
  box-shadow: var(--shadow-md);
}

.btn:active:not(:disabled) {
  transform: translateY(1px);
  box-shadow: var(--shadow-xs);
}

.btn:focus-visible {
  outline-offset: 2px;
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: var(--shadow-xs);
}

.btn-primary {
  background: var(--signal);
  border-color: var(--signal);
  color: var(--signal-ink);
}

.btn-primary:hover:not(:disabled) {
  background: var(--signal-deep);
  border-color: var(--signal-deep);
}

.btn-ghost {
  background: var(--card);
  color: var(--signal-deep);
}

.btn-paper {
  background: var(--card);
  color: var(--ink);
}

.btn-block {
  width: 100%;
  margin-top: 16px;
}

.btn-small {
  padding: 8px 14px;
  font-size: 12px;
}

/* 反色块里的按钮自成一套，不跟着纸面 token 走 */
.card-live .btn-paper {
  background: var(--block-face);
  border-color: var(--block-line);
  color: var(--block-ink);
  box-shadow: none;
}

.card-live .btn-paper:hover:not(:disabled) {
  background: var(--block);
  border-color: var(--block-signal);
  color: var(--block-signal);
}

.pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 13px;
  border: var(--edge) solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink);
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.pill-btn:hover:not(:disabled) {
  border-color: var(--signal);
  background: var(--wash-good);
}

.pill-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  background: var(--card);
}

.pill-btn svg {
  width: 13px;
  height: 13px;
}

.pill-btn.is-done {
  background: var(--tint-good);
  border-color: var(--signal);
}

/* ---------------- 查询台 ---------------- */

/* 查询条是凹进去的操作台，不是又一张卡 */
.search {
  display: flex;
  gap: 10px;
  margin-top: 24px;
  padding: 8px;
  border: var(--edge) solid var(--line-soft);
  border-radius: var(--radius-panel);
  background: var(--panel);
  box-shadow: var(--shadow-xs);
}

.search-field {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  min-width: 0;
}

.search-icon {
  position: absolute;
  left: 15px;
  width: 18px;
  height: 18px;
  color: var(--ink-soft);
  pointer-events: none;
}

.search-field input {
  width: 100%;
  min-width: 0;
  padding: 13px 14px 13px 44px;
  border: var(--edge) solid var(--line);
  border-radius: 6px;
  background: var(--card);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 500;
  transition: border-color 0.15s ease;
}

.search-field input::placeholder {
  color: var(--ink-faint);
  font-family: var(--sans);
  font-size: 14px;
}

.search-field input:focus {
  outline: 2px solid var(--signal);
  outline-offset: 1px;
  border-color: var(--signal);
}

.search-field input[aria-invalid='true'] {
  border-color: var(--danger);
  box-shadow: inset 0 0 0 1px var(--danger);
}

.search .btn {
  padding: 13px 20px;
  box-shadow: none;
}

.search .btn:hover:not(:disabled) {
  transform: none;
  box-shadow: none;
  background: var(--card);
}

.search .btn-primary:hover:not(:disabled) {
  background: var(--signal-deep);
}

.spinner {
  display: none;
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.is-loading .spinner {
  display: block;
}

.is-loading .btn-label {
  opacity: 0.7;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ---------------- 示例 chip ---------------- */

.chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
}

.chips-label {
  color: var(--ink-muted);
  font-size: 12px;
}

.chips-tight {
  margin-top: 8px;
}

.card-lime #recent-chips {
  flex: 1;
  align-content: flex-start;
  margin-top: 6px;
}

.card-time .footnote {
  padding-top: 12px;
}

.chips-empty {
  color: var(--ink-muted);
  font-size: 12px;
}

.chip {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 6px 12px;
  border: var(--edge) solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink);
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.12s ease;
}

.chip:hover {
  border-color: var(--signal);
  background: var(--wash-good);
  transform: translateY(-1px);
}

.chip b {
  font-family: var(--mono);
  font-weight: 600;
}

.chip i {
  color: var(--ink-muted);
  font-style: normal;
  font-size: 11px;
  font-weight: 500;
}

/* ---------------- 状态 / 错误 ---------------- */

.status {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 16px 0 0;
  color: var(--ink-muted);
  font-size: 12.5px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--signal);
  flex: none;
}

.status.is-error {
  color: var(--danger);
}

.status.is-error .status-dot {
  background: var(--danger);
}

.form-error {
  display: block;
  margin-top: 14px;
  padding: 12px 14px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--danger-soft);
  color: var(--danger);
  font-size: 13px;
}

.form-error[hidden] {
  display: none;
}

.form-error strong {
  display: block;
  font-weight: 700;
}

.form-error span {
  display: block;
  margin-top: 3px;
  opacity: 0.92;
}

.form-error code {
  display: table;
  margin-top: 8px;
  padding: 2px 7px;
  border: var(--edge) solid currentColor;
  border-radius: 5px;
  font-size: 11px;
}

/* ---------------- 读数块 ---------------- */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border: var(--edge) solid var(--line-soft);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.badge-lime {
  background: var(--wash-good);
  color: var(--ok-ink);
}

.badge-ice {
  background: var(--wash-neutral);
  color: var(--ink-soft);
}

.badge-amber {
  background: var(--wash-warn);
  color: var(--warn-ink);
}

.ip-capsule {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 16px;
  margin-bottom: 10px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--card);
  color: var(--ink);
  box-shadow: var(--shadow-md);
}

/* 公网 IP 当成仪表窗口来读：窗口本身压暗，数字用信号色 */
.card-live .ip-capsule {
  border-color: var(--block-line);
  background: var(--block-face);
  box-shadow: none;
}

.card-live .ip-capsule-value {
  color: var(--block-signal);
}

.ip-capsule-value {
  min-width: 0;
  font-size: clamp(19px, 2vw, 25px);
  font-weight: 700;
  letter-spacing: -0.02em;
  overflow-wrap: anywhere;
}

.flag {
  font-size: 20px;
  line-height: 1;
  flex: none;
}

.flag-lg {
  font-size: 30px;
}

.live-geo {
  margin: 0 0 14px;
  padding-left: 2px;
  color: var(--block-ink-soft);
  font-family: var(--mono);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.live-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin: 0;
}

.live-cell {
  padding: 11px 0;
  border-top: 1px dashed var(--block-line);
}

.live-cell:nth-child(odd) {
  padding-right: 12px;
}

.live-cell:nth-child(even) {
  padding-left: 12px;
  text-align: right;
}

.live-label {
  display: block;
  color: var(--block-ink-soft);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.live-value {
  display: block;
  margin-top: 2px;
  font-size: 12.5px;
  font-weight: 500;
  overflow-wrap: anywhere;
}

.card-live .badge {
  border-color: var(--block-line);
  background: var(--block-face);
  color: var(--block-signal);
}

/* ---------------- 明细卡 ---------------- */

.summary {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--panel);
}

.summary-main {
  min-width: 0;
  flex: 1;
}

.summary-ip {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.02em;
  overflow-wrap: anywhere;
}

.summary-country {
  margin: 1px 0 0;
  font-size: 12.5px;
  font-weight: 600;
}

.summary-path {
  margin: 2px 0 0;
  color: var(--ink-muted);
  font-size: 11.5px;
  overflow-wrap: anywhere;
}

.rows {
  margin: 14px 0 0;
}

.rows:empty::after,
.rows-flat:empty::after {
  content: 'Filled in once you run a lookup';
  display: block;
  padding: 14px 0;
  color: var(--ink-muted);
  font-size: 12px;
}

.row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--line-dash);
}

.row:last-child {
  border-bottom: 0;
}

.row-label {
  flex: none;
  color: var(--ink-soft);
  font-size: 12.5px;
}

/* 行标签前的小图标：与卡头图标同族，弱化不抢数据 */
.row-ico {
  display: inline-flex;
  flex: none;
  width: 12px;
  height: 12px;
  margin-right: 6px;
  color: var(--signal);
  opacity: 0.72;
  vertical-align: -1.5px;
}

.row-ico svg {
  display: block;
  width: 100%;
  height: 100%;
}

.row-value {
  min-width: 0;
  margin: 0;
  text-align: right;
  font-size: 13px;
  font-weight: 500;
  overflow-wrap: anywhere;
}

.row-value .flag {
  margin-right: 6px;
}

.row-value a {
  color: inherit;
  text-decoration: underline dotted;
  text-underline-offset: 3px;
}

.row-value small {
  display: block;
  color: var(--ink-faint);
  font-family: var(--sans);
  font-size: 11px;
}

.callout {
  margin: 14px 0 0;
  padding: 10px 13px;
  border: var(--edge) solid var(--line-soft);
  border-left: 2px solid var(--warn-ink);
  border-radius: var(--radius-panel);
  background: var(--wash-warn);
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 600;
}

.detail-empty {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 16px;
  padding: 22px 20px;
  border: 1px dashed var(--line-dash);
  border-radius: var(--radius-panel);
  background: var(--panel);
  text-align: center;
}

.detail-empty[hidden] {
  display: none;
}

.detail-empty b {
  font-size: 13px;
}

.detail-empty p {
  max-width: 30ch;
  margin: 0;
  color: var(--ink-muted);
  font-size: 12px;
  line-height: 1.7;
}

.panel-note {
  margin: 0;
  color: var(--ink-muted);
  font-size: 11px;
}

.rows-flat {
  margin-top: 6px;
}

.rows-flat .row {
  padding: 8px 0;
}

.card-alias .rows {
  margin-top: 10px;
}

.card-alias .row {
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 11px 0;
}

.card-alias .row-value {
  text-align: left;
  font-size: 12px;
}

.card-alias .footnote {
  margin-top: auto;
  padding-top: 14px;
}

/* ---------------- 风险信号 ---------------- */

.risk-list {
  list-style: none;
  margin: 2px 0 0;
  padding: 0;
}

.risk-list:empty::after {
  content: 'Filled in once you run a lookup';
  display: block;
  padding: 10px 0;
  color: var(--ink-muted);
  font-size: 12px;
}

.risk-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line-dash);
}

.risk-item:last-child {
  border-bottom: 0;
}

.risk-tag {
  /* 与全局 wash / tone 共用一套，不再用糖果色实心 */
  --risk-tone: var(--ink-muted);
  --risk-wash: var(--wash-neutral);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 20px;
  margin-top: 1px;
  padding: 0 7px;
  border: var(--edge) solid var(--line-soft);
  border-radius: 999px;
  background: var(--risk-wash);
  color: var(--risk-tone);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.risk-tag.is-low {
  --risk-tone: var(--ok-ink);
  --risk-wash: var(--wash-good);
}

.risk-tag.is-mid {
  --risk-tone: var(--warn-ink);
  --risk-wash: var(--wash-warn);
}

.risk-tag.is-unknown {
  --risk-tone: var(--ink-muted);
  --risk-wash: var(--wash-neutral);
}

.risk-name {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.45;
}

.risk-note {
  display: block;
  margin-top: 1px;
  color: var(--ink-muted);
  font-size: 11px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

/* ---------------- 连通性与服务状态 ---------------- */

.probe-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.probe {
  --probe-tone: var(--ink-muted);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 3px 8px;
  padding: 10px 11px 9px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--panel);
}

.probe.is-fast,
.probe-row.is-fast {
  --probe-tone: var(--ok-ink);
}

.probe.is-mid,
.probe-row.is-mid {
  --probe-tone: var(--warn-ink);
}

.probe.is-slow,
.probe.is-fail,
.probe-row.is-slow,
.probe-row.is-fail {
  --probe-tone: var(--danger);
}

.probe-mark {
  display: grid;
  place-items: center;
  width: 23px;
  height: 23px;
  border: var(--edge) solid var(--line);
  border-radius: 7px;
  background: var(--card);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 700;
  line-height: 1;
}

/* 官方品牌标志（Simple Icons 单色 path，currentColor 随主题） */
.probe-mark.is-brand svg {
  display: block;
  width: 14px;
  height: 14px;
}

.probe-name {
  min-width: 0;
  font-size: 12.5px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.probe-ms {
  color: var(--probe-tone);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.probe-bars {
  grid-column: 1 / -1;
  display: flex;
  gap: 4px;
  margin-top: 3px;
}

.probe-bars i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--line-dash);
}

.probe-bars i.on {
  background: var(--probe-tone);
}

.probe.is-pending .probe-name,
.probe.is-pending .probe-ms,
.probe-row.is-pending .probe-name,
.probe-row.is-pending .probe-ms {
  color: var(--ink-faint);
}

.probe-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 26px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.probe-row {
  --probe-tone: var(--ink-muted);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  color: inherit;
  text-decoration: none;
}

.probe-row:focus-visible {
  outline-offset: 3px;
  border-radius: 6px;
}

.probe-row .probe-ms {
  font-size: 12px;
}

.probe-row:hover .probe-name {
  text-decoration: underline dotted;
  text-underline-offset: 3px;
}

.probe-state {
  --state-tone: var(--ink-faint);
  color: var(--state-tone);
  font-size: 11.5px;
  font-weight: 700;
  white-space: nowrap;
}

.probe-state.is-ok {
  --state-tone: var(--ok-ink);
}

.probe-state.is-minor {
  --state-tone: var(--warn-ink);
}

.probe-state.is-major {
  --state-tone: var(--danger);
}

.probe-state.is-maintenance {
  --state-tone: var(--ink-muted);
}

.card-net .footnote,
.card-status .footnote,
.card-ai .footnote {
  margin-top: auto;
  padding-top: 12px;
}

.probe-list-log {
  flex: 1;
  align-content: start;
}

.probe-list-log .probe-row {
  padding: 9px 0;
}

.probe-list-log li:nth-child(n + 3) .probe-row {
  border-top: 1px dashed var(--line-dash);
}

.card-ai .probe-list {
  flex: 1;
  align-content: space-between;
}

/* ---------------- 泄露测试 ---------------- */

.stun-grid {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
  /* 四张 STUN 卡平分卡内高度，不然跑完后下面留一大块空白 */
  align-content: space-between;
}

/* 通栏之后一行放得下四张，正好一台 STUN 一格 */
@media (min-width: 1081px) {
  .stun-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.stun {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 11px 12px 10px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--panel);
}

.stun-head {
  display: flex;
  align-items: center;
  gap: 6px;
}

.stun-head svg {
  width: 13px;
  height: 13px;
  color: var(--ink-soft);
}

.stun-label {
  font-size: 11.5px;
  font-weight: 700;
}

.stun-index {
  margin-left: auto;
  color: var(--ink-faint);
  font-family: var(--mono);
  font-size: 11px;
}

.stun-server {
  margin: 0;
  color: var(--ink-muted);
  font-family: var(--mono);
  font-size: 10.5px;
  overflow-wrap: anywhere;
}

.stun-ip {
  margin: 1px 0 0;
  color: var(--ok-ink);
  font-family: var(--mono);
  font-size: 13.5px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.stun-ip.is-fail {
  color: var(--danger);
  font-family: var(--sans);
  font-size: 11.5px;
  font-weight: 600;
}

.stun.is-pending .stun-ip {
  color: var(--ink-muted);
}

.stun-meta {
  display: grid;
  gap: 4px;
  margin: 3px 0 0;
  padding-top: 7px;
  border-top: 1px dashed var(--line-dash);
}

.stun-meta div {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr);
  gap: 6px;
}

.stun-meta dt {
  color: var(--ink-soft);
  font-size: 10.5px;
}

.stun-meta dd {
  margin: 0;
  font-size: 11.5px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.stun-log {
  margin-top: 4px;
}

.stun-log summary {
  color: var(--ink-muted);
  font-size: 10.5px;
  cursor: pointer;
}

.stun-log pre {
  max-height: 110px;
  margin: 6px 0 0;
  overflow: auto;
  color: var(--ink-soft);
  font-family: var(--mono);
  font-size: 10px;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* DNS 泄露检测：四个固定观测点各占一格（宽屏 4 列，中屏 2 列，窄屏单列） */
.dns-grid {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  align-content: start;
}

@media (max-width: 1080px) {
  .dns-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

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

.dns-tile {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 12px 14px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--panel);
}

.dns-tile-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.dns-tile-title {
  font-size: 12px;
  font-weight: 700;
}

.dns-tile-index {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
}

.dns-tile-host {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-muted);
}

.dns-tile-ip {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--signal);
  overflow-wrap: anywhere;
}

.dns-tile.is-error .dns-tile-ip {
  color: var(--danger, #e5484d);
}

.dns-tile-rows {
  margin: 0;
  border-top: 1px dashed var(--line-dash);
}

.dns-tile-rows > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 5px 0;
  border-bottom: 1px dashed var(--line-dash);
  font-size: 12px;
}

.dns-tile-rows > div:last-child {
  border-bottom: none;
}

.dns-tile-rows dt {
  color: var(--ink-muted);
  white-space: nowrap;
}

.dns-tile-rows dd {
  margin: 0;
  font-family: var(--mono);
  font-weight: 600;
  text-align: right;
  overflow-wrap: anywhere;
}

.dns-empty {
  padding: 10px 0;
  color: var(--ink-soft);
  font-size: 11.5px;
  line-height: 1.7;
}

.card-webrtc .footnote,
.card-dns .footnote {
  margin-top: auto;
  padding-top: 12px;
}

/* ---------------- 地图 ---------------- */

.map-frame {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 260px;
  margin-top: 2px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--card);
  overflow: hidden;
}

.card-map .callout {
  margin-top: 12px;
  font-size: 11.5px;
  line-height: 1.55;
}

.map-coords {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 0;
  padding-top: 14px;
}

.map-coord {
  padding: 8px 0 0;
  border-top: 1px dashed var(--line-dash);
}

.map-coord + .map-coord {
  padding-left: 14px;
  text-align: right;
  border-left: 1px dashed var(--line-dash);
}

.map-coord dt {
  color: var(--ink-soft);
  font-size: 11px;
}

/* 地图坐标行的国旗 emoji */
.coord-flag {
  margin-right: 5px;
}

.map-coord dd {
  margin: 2px 0 0;
  font-size: 12.5px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.map-svg {
  display: block;
  width: 100%;
  height: auto;
  max-height: 100%;
}

.map-frame .graticule {
  fill: none;
  stroke: var(--line-dash);
  stroke-width: 0.28;
  opacity: 0.62;
}

.map-frame .graticule-major {
  fill: none;
  stroke: var(--ink-faint);
  stroke-width: 0.34;
  stroke-dasharray: 1.5 1.5;
  opacity: 0.55;
}

.map-frame .land {
  stroke: var(--ink-soft);
  stroke-width: 0.9;
  stroke-linecap: round;
}

/* 点阵跑马灯：与 .land 同形状的信号色点阵，由纵横穿梭的光带遮罩点亮 */
.map-frame .land-sweep {
  stroke: var(--signal);
  stroke-opacity: 0.9;
}

.map-frame .self-ring {
  fill: none;
  stroke: var(--signal);
  stroke-width: 0.55;
}

.map-frame .self-dot {
  fill: var(--signal);
}

.map-frame .target-ring {
  fill: var(--tint-flag);
  fill-opacity: 0.3;
  stroke: var(--ink-soft);
  stroke-width: 0.25;
}

.map-frame .target-dot {
  fill: var(--tint-flag);
  stroke: var(--ink);
  stroke-width: 0.22;
}

.map-frame .drop {
  stroke: var(--ink-faint);
  stroke-width: 0.2;
  stroke-dasharray: 0.6 0.6;
}

/* 十字定位线：跟着指针走的经纬读数，只负责定位，不抢标记的风头 */
.map-frame .cross {
  stroke: var(--signal);
  stroke-width: 0.2;
  opacity: 0.5;
  pointer-events: none;
}

.map-frame .cross-dot {
  fill: var(--card);
  stroke: var(--signal);
  stroke-width: 0.3;
  opacity: 0.95;
  pointer-events: none;
}

.map-legend {
  position: absolute;
  right: 10px;
  bottom: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: var(--edge) solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink);
  font-size: 10.5px;
  font-weight: 600;
}

.map-legend[hidden],
.legend-item[hidden] {
  display: none;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.legend-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: var(--edge) solid var(--line);
}

.legend-self {
  background: var(--signal);
}

.legend-target {
  background: var(--tint-flag);
  margin-left: 4px;
}

.map-tip {
  position: absolute;
  z-index: 3;
  padding: 3px 9px;
  border: var(--edge) solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  font-size: 10.5px;
  font-weight: 600;
  white-space: nowrap;
  transform: translate(-50%, -135%);
  pointer-events: none;
}

.map-empty {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  padding: 7px 14px;
  border: var(--edge) solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
  text-align: center;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

.map-empty[hidden] {
  display: none;
}

/* 指针在图上时十字线和读数优先，占位提示让位，别叠在一起 */
.map-frame:hover .map-empty {
  opacity: 0;
}

.map-hint {
  position: absolute;
  left: 10px;
  bottom: 10px;
  padding: 4px 11px;
  border: var(--edge) solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink);
  font-size: 10.5px;
  font-weight: 600;
  pointer-events: none;
}

.map-caption {
  margin: 14px 0 0;
  color: var(--ink-muted);
  font-size: 11.5px;
  line-height: 1.7;
  text-wrap: pretty;
}

/* ---------------- 统计列表 ---------------- */

.stat-list {
  margin: 0;
}

.card-time .stat-list {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.card-time .stat {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-content: center;
  align-items: baseline;
  column-gap: 12px;
  row-gap: 2px;
}

.card-time .stat dt {
  grid-column: 1;
  grid-row: 1;
}

.card-time .stat > dd:not(.stat-sub) {
  grid-column: 2;
  grid-row: 1;
}

.card-time .stat .stat-sub {
  grid-column: 1 / -1;
  grid-row: 2;
}

.stat {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 10px 0;
  border-bottom: 1px dashed var(--line-dash);
}

.stat:last-child {
  border-bottom: 0;
}

.stat dt {
  color: var(--ink-soft);
  font-size: 12.5px;
}

.stat dd {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  text-align: right;
}

.stat dd small {
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 500;
  color: var(--ink-muted);
}

.stat-sub {
  display: block;
  flex-basis: 100%;
  margin-top: 1px;
  color: var(--ink-muted);
  font-family: var(--sans) !important;
  font-size: 11px;
  font-weight: 400;
  text-align: right;
  overflow-wrap: anywhere;
}

.notes-list {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 12px;
  line-height: 1.7;
  color: var(--ink-soft);
}

.notes-list li {
  position: relative;
  padding-left: 14px;
  margin-bottom: 9px;
}

.notes-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 5px;
  height: 5px;
  border-radius: 1px;
  background: var(--signal);
}

.notes-list b {
  color: var(--ink);
  margin-right: 4px;
}

/* ---------------- 页脚 ---------------- */

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  max-width: 1320px;
  margin: 26px auto 0;
  padding: 20px 34px 34px;
  border-top: var(--edge) solid var(--line);
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 9px;
}

.footer-sub {
  color: var(--ink-muted);
  font-size: 12px;
}

.footer-meta {
  display: flex;
  gap: 8px;
  color: var(--ink-muted);
  font-size: 11.5px;
}

.footer-meta a {
  text-decoration: underline dotted;
  text-underline-offset: 3px;
}

/* ---------------- 响应式 ---------------- */

@media (max-width: 1080px) {
  .card-hero,
  .card-live,
  .card-detail,
  .card-map,
  .card-alias,
  .card-time,
  .card-risk,
  .card-net,
  .card-status,
  .card-ai,
  .card-lime,
  .card-lav {
    grid-column: span 12;
  }
}

@media (min-width: 1081px) {
  .card-lav .notes-list {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-content: space-between;
    column-gap: 34px;
  }

  .card-lav .notes-list li {
    margin-bottom: 0;
  }
}

@media (max-width: 760px) {
  .site-header {
    gap: 14px;
    padding: 0 16px;
    overflow-x: auto;
    scrollbar-width: none; /* 头部极端情况横向滚动时不显滚动条 */
  }

  .site-header::-webkit-scrollbar {
    display: none;
  }

  .header-tools {
    gap: 8px;
  }

  /* IPv6 较长，限制宽度并省略，避免把主题按钮挤出头部 */
  .ip-pill {
    max-width: 46vw;
  }

  .ip-pill-value {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .privacy-btn {
    flex: none;
  }

  .site-nav {
    display: none;
  }

  .bento {
    padding: 16px 16px 0;
    gap: 16px;
  }

  .card {
    padding: 18px 16px;
    box-shadow: var(--shadow-md);
  }

  /* 移动端点按热区 ≥ 44px，符合拇指操作 */
  .btn {
    min-height: 44px;
  }

  .search .btn {
    flex: 1;
    min-height: 46px;
  }

  .hero-title {
    font-size: clamp(28px, 8vw, 38px);
  }

  .search {
    flex-wrap: wrap;
    margin-top: 18px;
  }

  .search-field {
    flex-basis: 100%;
  }

  .search .btn {
    flex: 1;
  }

  .probe-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .probe {
    padding: 9px 10px 8px;
  }

  /* 标题、徽标、按钮在窄屏放不进一行，宁可换行也不让标题被挤成两行。 */
  .card-head {
    flex-wrap: wrap;
    row-gap: 10px;
  }

  .card-title {
    flex: 1 1 auto;
  }

  .head-actions {
    flex-wrap: wrap;
  }

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

  .probe-list {
    grid-template-columns: 1fr;
  }

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

  /* 地图在窄屏不用那么高，避免大片留白 */
  .map-frame {
    min-height: 210px;
  }

  .site-footer {
    padding: 18px 16px 28px;
  }
}

@media (max-width: 460px) {
  .ip-pill {
    display: none;
  }

  .row {
    flex-direction: column;
    gap: 3px;
  }

  .row-value {
    text-align: left;
  }

  /* 小屏（多数手机竖屏）下探针卡与实时指标改为单列，避免挤压换行 */
  .probe-grid {
    grid-template-columns: 1fr;
  }

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

  .live-cell,
  .live-cell:nth-child(odd),
  .live-cell:nth-child(even) {
    padding: 9px 0;
    text-align: left;
  }

  .bento {
    padding: 14px 14px 0;
    gap: 14px;
  }

  .card {
    padding: 16px 14px;
  }

  .hero-title {
    font-size: clamp(26px, 9vw, 34px);
  }

  .ip-capsule {
    padding: 12px 14px;
  }

  .search {
    padding: 6px;
  }

  .search-field input {
    padding: 12px 14px 12px 42px;
  }

  /* 地图框进一步收小，坐标 You/Target 改为上下排布更清楚 */
  .map-frame {
    min-height: 180px;
  }
}

@media (max-width: 380px) {
  .bento {
    padding: 12px 12px 0;
  }

  .card {
    padding: 15px 13px;
  }

  .brand-name {
    font-size: 15px;
  }

  .hero-title {
    font-size: 26px;
  }

  .lede {
    font-size: 14px;
  }

  .map-frame {
    min-height: 165px;
  }

  /* You / Target 坐标在极窄屏上下排布，避免 150px 内硬塞两列 */
  .map-coords {
    grid-template-columns: 1fr;
  }

  .map-coord + .map-coord {
    padding-left: 0;
    border-left: 0;
    text-align: left;
  }

  .search-field input {
    padding: 11px 12px 11px 38px;
  }

  .stat,
  .row {
    font-size: 12px;
  }
}

@media (hover: none) {
  .map-hint {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    /* 让无限循环的动画干净地跑完一次后回到静态，而不是定格/狂闪 */
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  /* 扫描氛围是本站的主体视觉：减弱动态时不完全静止，
     改为放慢的柔和版本（都是慢速位移，无快速闪烁）。
     类选择器优先级高于上面的通配符，天然覆盖冻结规则。 */
  .ambient::before,
  .radar-sweep,
  .radar-rotor,
  .radar-blip,
  .hero-scanline,
  .bg-particle,
  .bg-node,
  .bg-link {
    animation-iteration-count: infinite !important;
    animation-duration: 18s !important;
  }

  .radar-blip {
    animation-duration: 5.2s !important;
  }

  /* 扇面 + 前缘线是核心观感，减弱动态下也保持可感知的转速（两者必须同速） */
  .radar-sweep,
  .radar-beam {
    animation-duration: 9s !important;
  }
}

/* ============================================================
   扫描氛围（新增视觉，不占布局）
   扫描主题色 = 青蓝（--scan-cyan），与品牌信号绿区分：扫描是青蓝，品牌是绿
   1. 背景：细网格（沿用 body）+ 稀疏粒子 + 少量网络节点 + 中心径向光晕
   2. 扫描主视觉：页头雷达（圆环缓旋 + 青蓝扇面 + 回波点）+ 缓慢扫描线
   3. 查询卡片：搜索台聚焦扫光、检测开始一次完整扫描、查询步骤依次点亮
   4. 状态动画：状态点呼吸 + 扩散环，待定徽标微脉冲
   5. 结果卡片：细腻边框高光 + 轻微悬浮；复制成功克制光效；IP 显现确认光
   ============================================================ */

:root {
  --scan: 4.5s;
  --scan-cyan: #46bcd6;
  --scan-cyan-soft: rgba(70, 188, 214, 0.55);
  --scan-cyan-faint: rgba(70, 188, 214, 0.16);
}

/* ---------------- 1. 背景 ---------------- */

.ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

/* 背景里的粒子 / 节点 / 连线（由 scan-fx.js 生成），始终在内容之下 */
.ambient .bg-net {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  /* 中心（卡片所在区域）淡出，只在页面边栏与上下留白透出，
     让星座退到四周背景、不跟卡片内容抢视线 */
  -webkit-mask: radial-gradient(ellipse 44% 56% at 50% 44%, transparent 58%, #000 100%);
  mask: radial-gradient(ellipse 44% 56% at 50% 44%, transparent 58%, #000 100%);
}

.bg-particle {
  fill: var(--scan-cyan);
  opacity: 0.09;
  animation: drift 18s ease-in-out infinite;
}

.bg-node {
  fill: var(--scan-cyan);
  opacity: 0.4;
  animation: node-blink 7s ease-in-out infinite;
}

.bg-link {
  stroke: var(--scan-cyan-soft);
  stroke-width: 0.14;
  stroke-linecap: round;
  fill: none;
  stroke-dasharray: 0.9 2.8;
  opacity: 0.32;
  animation: link-flow 11s linear infinite;
}

@keyframes drift {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-0.5px);
  }
}

@keyframes node-blink {
  0%,
  100% {
    opacity: 0.2;
  }
  50% {
    opacity: 0.6;
  }
}

@keyframes link-flow {
  to {
    stroke-dashoffset: -22;
  }
}

/* 背景「扇形光晕」：以页面顶部中央为圆心的雷达扫掠，持续缓慢转动 */
.ambient::before {
  content: '';
  position: absolute;
  left: calc(50% - 48vmax);
  top: -26vmax;
  width: 96vmax;
  height: 96vmax;
  background: conic-gradient(
    from 0deg at 50% 0%,
    var(--scan-cyan-soft) 0deg,
    transparent 22deg,
    transparent 338deg,
    var(--scan-cyan-soft) 360deg
  );
  opacity: 0.45;
  transform-origin: 50% 0;
  transform: rotate(var(--spin, 0deg));
  will-change: transform;
}

/* 顶部 + 中心的局部径向光晕，让页面中心更有层次（压在网格之上、内容之下） */
.ambient::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(58% 48% at 50% 40%, var(--scan-cyan-faint), transparent 70%),
    radial-gradient(150% 60% at 50% -18%, var(--glow), transparent 72%);
}

/* ---------------- 2. 扫描主视觉（页头雷达） ---------------- */

/* 卡片内容压在雷达之上，雷达只在右侧透出，不影响文字与流程 */
.card-hero > :not(.hero-radar) {
  position: relative;
  z-index: 1;
}

.hero-radar {
  position: absolute;
  top: 40%;
  right: 16px;
  width: 236px;
  height: 236px;
  transform: translateY(-50%);
  z-index: 0;
  pointer-events: none;
  opacity: 0.75;
}

/* 雷达后方的柔和青蓝辉光，把「仪表盘」从纸面托起来 */
.hero-radar .radar-glow {
  position: absolute;
  inset: -26%;
  border-radius: 50%;
  background: radial-gradient(circle, var(--scan-cyan-faint), transparent 65%);
}

.hero-radar .radar-grid {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid var(--scan-cyan-faint);
}

.hero-radar .radar-grid-2 {
  inset: 34px;
  border-color: var(--line);
  opacity: 0.7;
}

/* 缓慢旋转的虚线环，让「圆环在转」看得见 */
.hero-radar .radar-rotor {
  inset: 16px;
  border: 1px dashed var(--scan-cyan-soft);
  opacity: 0.45;
  transform: rotate(var(--spin-rotor, 0deg));
  will-change: transform;
}

/* 固定刻度环（仪表盘 bezel）：每 15° 一格短刻度 */
.hero-radar .radar-ticks {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: repeating-conic-gradient(
    from 0deg at 50% 50%,
    var(--scan-cyan-soft) 0deg 0.5deg,
    transparent 0.5deg 15deg
  );
  -webkit-mask: radial-gradient(circle at 50% 50%, transparent 0 91%, #000 91.5% 99%, transparent 100%);
  mask: radial-gradient(circle at 50% 50%, transparent 0 91%, #000 91.5% 99%, transparent 100%);
  opacity: 0.4;
}

/* 十字准线 */
.hero-radar .radar-cross {
  position: absolute;
  background: var(--scan-cyan-faint);
}

.hero-radar .radar-cross-h {
  left: 6%;
  right: 6%;
  top: 50%;
  height: 1px;
}

.hero-radar .radar-cross-v {
  top: 6%;
  bottom: 6%;
  left: 50%;
  width: 1px;
}

/* 余辉扇面：4.5s/圈持续旋转（减弱动态下 9s，见 reduced-motion 豁免） */
.hero-radar .radar-sweep {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg at 50% 50%,
    rgba(70, 188, 214, 0.42) 0deg,
    rgba(70, 188, 214, 0.2) 14deg,
    transparent 42deg
  );
  transform: rotate(var(--spin, 0deg));
  will-change: transform;
}

/* 亮前缘线，与扇面同速同相位旋转 */
.hero-radar .radar-beam {
  position: absolute;
  left: calc(50% - 0.5px);
  top: 7%;
  bottom: 50%;
  width: 1px;
  background: linear-gradient(to top, transparent, var(--scan-cyan-soft));
  transform-origin: 50% 100%;
  transform: rotate(var(--spin, 0deg));
  will-change: transform;
}

/* 中心点 */
.hero-radar .radar-center {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 5px;
  height: 5px;
  margin: -2.5px 0 0 -2.5px;
  border-radius: 50%;
  background: var(--scan-cyan-soft);
  box-shadow: 0 0 8px var(--scan-cyan-soft);
}

/* 检测开始时播放一次的完整扫描（仅在查询进行时出现） */
.hero-radar .radar-flash {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg at 50% 50%,
    transparent 0deg,
    var(--scan-cyan) 8deg,
    transparent 26deg
  );
  opacity: 0;
}

.card-hero:has(.search.is-loading) .radar-flash {
  animation: scan-once 1s cubic-bezier(0.3, 0, 0.2, 1);
}

@keyframes scan-once {
  0% {
    transform: rotate(0deg);
    opacity: 0.9;
  }
  100% {
    transform: rotate(360deg);
    opacity: 0;
  }
}

/* 缓慢横移的扫描线，常驻但极淡 */
.hero-scanline {
  position: absolute;
  left: 0;
  right: 0;
  top: 2%;
  height: 2px;
  z-index: 0;
  background: linear-gradient(90deg, transparent, var(--scan-cyan-soft), transparent);
  opacity: 0;
  animation: hero-scan 9s linear infinite;
}

@keyframes hero-scan {
  0% {
    top: 2%;
    opacity: 0;
  }
  12%,
  88% {
    opacity: 0.45;
  }
  100% {
    top: 96%;
    opacity: 0;
  }
}

/* 雷达上的回波点，错峰闪烁 */
.hero-radar .radar-blip {
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--scan-cyan);
  box-shadow: 0 0 9px var(--scan-cyan);
  top: 36%;
  left: 66%;
  animation: blip-ping 2.6s ease-out infinite;
}

.hero-radar .radar-blip-2 {
  top: 62%;
  left: 42%;
  animation-delay: 1.3s;
}

.hero-radar .radar-blip-3 {
  top: 28%;
  left: 30%;
  animation-delay: 2.1s;
}

@keyframes rotor-spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes blip-ping {
  0% {
    transform: scale(0.4);
    opacity: 0;
  }
  18% {
    opacity: 1;
  }
  100% {
    transform: scale(1.7);
    opacity: 0;
  }
}

/* ---------------- 3. 查询卡片 ---------------- */

.search {
  position: relative;
  overflow: hidden;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

/* 聚焦时整条搜索台描上信号边 + 内侧扫光 */
.search:focus-within {
  border-color: var(--signal);
  box-shadow: 0 0 0 1px var(--signal-ring), var(--shadow-xs);
}

.search::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--scan-cyan), transparent);
  opacity: 0;
}

.search:focus-within::after {
  opacity: 0.9;
  animation: scan-line 3.2s linear infinite;
}

@keyframes scan-line {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(64px);
  }
}

/* 查询步骤：仅在查询进行时出现，四项依次点亮，表示流程在走 */
.scan-steps {
  display: none;
  list-style: none;
  gap: 6px;
  margin: 14px 0 0;
  padding: 0;
}

.card-hero:has(.search.is-loading) .scan-steps {
  display: flex;
}

.scan-step {
  flex: 1;
  padding: 6px 4px;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  text-align: center;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ink-muted);
  opacity: 0.5;
}

.card-hero:has(.search.is-loading) .scan-step {
  animation: step-pulse 2.4s linear infinite;
}

.card-hero:has(.search.is-loading) .scan-step:nth-child(1) {
  animation-delay: 0s;
}
.card-hero:has(.search.is-loading) .scan-step:nth-child(2) {
  animation-delay: 0.6s;
}
.card-hero:has(.search.is-loading) .scan-step:nth-child(3) {
  animation-delay: 1.2s;
}
.card-hero:has(.search.is-loading) .scan-step:nth-child(4) {
  animation-delay: 1.8s;
}

@keyframes step-pulse {
  0%,
  100% {
    opacity: 0.5;
    border-color: var(--line-soft);
    color: var(--ink-muted);
    box-shadow: none;
  }
  20% {
    opacity: 1;
    border-color: var(--scan-cyan);
    color: var(--scan-cyan);
    box-shadow: 0 0 0 2px var(--scan-cyan-faint);
  }
}

/* ---------------- 4. 状态动画 ---------------- */

.status-dot {
  position: relative;
  animation: status-breathe 2.4s ease-in-out infinite;
}

/* 状态点外扩环，表示「仍在监听 / 读取中」 */
.status-dot::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1px solid var(--signal-ring);
  animation: status-ping 2.2s ease-out infinite;
}

.status.is-error .status-dot::after {
  border-color: var(--danger);
}

@keyframes status-breathe {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.45;
  }
}

@keyframes status-ping {
  0% {
    transform: scale(0.5);
    opacity: 1;
  }
  70%,
  100% {
    transform: scale(2);
    opacity: 0;
  }
}

/* 待定态徽标（awaiting / not tested / probing / reading）轻微脉冲，提示「进行中」 */
.badge-ice {
  animation: badge-breathe 2.8s ease-in-out infinite;
}

@keyframes badge-breathe {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(12, 115, 96, 0);
  }
  50% {
    box-shadow: 0 0 0 3px var(--signal-ring);
  }
}

/* ---------------- 5. 结果卡片 / 复制 / IP 显现 ---------------- */

/* 卡片：细腻边框高光 + 轻微悬浮反馈（不影响静态布局） */
.card {
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.card:hover {
  border-color: var(--line);
  box-shadow: var(--shadow), 0 0 0 1px var(--signal-ring);
  transform: translateY(-2px);
}

.card:hover::before,
.card:hover::after {
  border-color: var(--signal);
  opacity: 1;
}

.card-live:hover {
  box-shadow: var(--shadow), 0 0 0 1px var(--block-signal);
}

/* 复制成功：克制的青蓝光效，绝不做全屏动画 */
.pill-btn.is-done,
.pill-btn.is-copied,
.btn.is-copied {
  border-color: var(--scan-cyan);
  color: var(--ok-ink);
  box-shadow: 0 0 0 1px var(--scan-cyan), 0 0 12px var(--scan-cyan-faint);
  animation: copy-flash 0.5s ease;
}

@keyframes copy-flash {
  0% {
    box-shadow: 0 0 0 2px var(--scan-cyan-soft), 0 0 18px var(--scan-cyan-soft);
  }
  100% {
    box-shadow: 0 0 0 1px var(--scan-cyan), 0 0 12px var(--scan-cyan-faint);
  }
}

/* IP / 查询结果显现：平滑淡入 + 短暂确认光 */
.reveal {
  animation: ip-reveal 0.6s ease, ip-confirm 1s ease;
}

@keyframes ip-reveal {
  from {
    opacity: 0.2;
  }
  to {
    opacity: 1;
  }
}

@keyframes ip-confirm {
  0% {
    text-shadow: 0 0 0 transparent;
  }
  30% {
    text-shadow: 0 0 10px var(--scan-cyan-soft);
  }
  100% {
    text-shadow: 0 0 0 transparent;
  }
}

/* 窄屏收起主视觉雷达，避免与标题文字打架 */
@media (max-width: 1080px) {
  .hero-radar {
    display: none;
  }
}

/* ============================================================
   IPv4 / IPv6 双栈探针卡：两族地址各自独立读数
   ============================================================ */

.card-probe {
  grid-column: span 6;
  display: flex;
  flex-direction: column;
}

.probe-capsule {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: var(--edge) solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--panel);
}

.probe-capsule .probe-ip {
  flex: 1;
  min-width: 0;
  font-family: var(--mono);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--signal);
  overflow-wrap: anywhere;
}

.probe-geo {
  margin: 10px 0 0;
  font-size: 12.5px;
  color: var(--ink-soft);
}

.probe-rows {
  margin: 12px 0 0;
  border-top: 1px dashed var(--line-dash);
}

.probe-rows > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 2px;
  border-bottom: 1px dashed var(--line-dash);
  font-size: 12.5px;
}

.probe-rows dt {
  color: var(--ink-muted);
}

/* 本次查询结果的标注行：标签用识别色，与「你自己的出口读数」区分开 */
.probe-target-row dt {
  color: var(--signal);
  font-weight: 600;
}

.probe-rows dd {
  margin: 0;
  font-family: var(--mono);
  font-weight: 600;
  text-align: right;
  overflow-wrap: anywhere;
}

/* 无路由时的空态：说明这是网络的事实，不是页面出错 */
.probe-empty {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
  padding: 26px 18px;
  border: 1px dashed var(--line-dash);
  border-radius: var(--radius-panel);
  text-align: center;
  color: var(--ink-muted);
}

.probe-empty b {
  font-size: 13px;
  color: var(--ink-soft);
}

.probe-empty span {
  max-width: 36ch;
  font-size: 12px;
  line-height: 1.6;
}

@media (max-width: 1080px) {
  .card-probe {
    grid-column: span 12;
  }
}

/* ============================================================
   数字地球总览卡：canvas 陆地点阵球 + 玻璃 IP 面板 + 图标信息卡
   ============================================================ */

/* 无卡片外壳：地球区是一片「深空舷窗」，直接融进页面（对标参考站的首屏观感） */
.card-globe {
  grid-column: span 12;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  /* 地球区占满第一屏（视口高 - 64px sticky header），01 Start here 从第二屏开始 */
  min-height: calc(100vh - 64px);
  min-height: calc(100svh - 64px);
  overflow: hidden;
  padding: 18px 0 0;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
  transition: none;
}

.card-globe::before {
  content: none;
}

/* 底部不再垫任何渐隐衬底：信息卡自带实色卡底，说明文字直接落在页面
   背景上，保持地球区最初「无卡片外壳、完全透明」的观感。
   content:none 同时抑制 .card::after 角标的级联残留（width/边框/圆角） */
.card-globe::after {
  content: none;
}

/* hover 不做任何边框/位移动效 */
.card-globe:hover,
.card-globe:hover::before,
.card-globe:hover::after {
  border-color: transparent;
  box-shadow: none;
  transform: none;
  opacity: 1;
}

#globe-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* 节点玻璃瓷片：canvas 每帧投影定位 */
.globe-chips {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
  pointer-events: none;
}

.globe-chip {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px 5px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--card) 84%, transparent);
  backdrop-filter: blur(4px);
  font-size: 11px;
  font-weight: 600;
  color: var(--ink-soft);
  white-space: nowrap;
  transform: translate(-50%, -135%);
  box-shadow: 0 4px 14px rgba(15, 40, 60, 0.12);
}

.globe-chip i {
  flex: none;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--scan-cyan);
  box-shadow: 0 0 8px var(--scan-cyan-soft);
}

.globe-chip.is-user {
  border-color: var(--signal);
  color: var(--ink);
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--signal) 30%, transparent),
    0 6px 18px rgba(15, 40, 60, 0.16);
}

.globe-chip.is-user i {
  background: var(--signal);
}

/* 真实数据层压在 canvas 与瓷片之上 */
.card-globe .card-head,
.globe-center,
.globe-foot {
  position: relative;
  z-index: 2;
}

.globe-center {
  display: flex;
  justify-content: center;
  margin: auto;
  padding: 0 16px;
  pointer-events: none;
}

.globe-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 22px 36px 20px;
  border: none;
  border-radius: 18px;
  background: color-mix(in srgb, var(--card) 80%, transparent);
  backdrop-filter: blur(8px);
  box-shadow: 0 24px 70px rgba(15, 40, 60, 0.18);
  text-align: center;
}

.globe-status {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.globe-spinner {
  width: 12px;
  height: 12px;
  border: 2px solid var(--line-dash);
  border-top-color: var(--signal);
  border-radius: 50%;
  animation: globe-spin 0.9s linear infinite;
}

.globe-status.is-live .globe-spinner {
  width: 7px;
  height: 7px;
  border: none;
  background: var(--signal);
  box-shadow: 0 0 8px var(--signal);
  animation: none;
}

@keyframes globe-spin {
  to {
    transform: rotate(360deg);
  }
}

.globe-ip {
  margin: 0;
  font-family: var(--mono);
  font-size: clamp(36px, 5vw, 62px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--signal);
  /* 等宽数字：IP 各位宽度一致，避免布局抖动 */
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 30px color-mix(in srgb, var(--signal) 40%, transparent);
  overflow-wrap: anywhere;
}

.globe-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.globe-center .pill-btn {
  pointer-events: auto;
}

.globe-foot {
  display: flex;
  flex-direction: column;
  gap: 10px;
  /* 上移：不再压着球体下缘，与球面留出呼吸空间 */
  padding-bottom: 96px;
}

/* 底部信息卡：与其他卡片同款卡壳（实色卡底 + 发丝线边框 + 同族圆角阴影），
   不再依赖整块半透明衬底 */
.globe-card {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px 22px;
  padding: 16px 20px;
  background: var(--card);
  border: var(--edge) solid var(--line-soft);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
  /* 默认淡出：压在球体下缘时把视觉焦点让给地球，
     Hover 或键盘聚焦时才恢复清晰，信息本身一个不少 */
  opacity: 0.55;
  transition: opacity 260ms ease;
}

.globe-card:hover,
.globe-card:focus-within {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .globe-card {
    transition: none;
  }
}

.globe-cell {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0;
  background: transparent;
  min-width: 0;
}

.g-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  /* 用稍深的 ink-soft 保证浅/深色主题下标签都清晰，不靠发光或描边 */
  color: var(--ink-soft);
}

.g-label svg {
  flex: none;
  width: 13px;
  height: 13px;
  color: var(--signal);
}

.g-value {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.g-value.is-mono {
  font-family: var(--mono);
  font-size: 13.5px;
  font-variant-numeric: tabular-nums;
}

.globe-note {
  /* 负下边距：统计块位置不动，说明文字单独下沉（96-44=52px），
     不再压着球体下缘 */
  margin: 14px 0 -44px;
  font-size: 11.5px;
  line-height: 1.6;
  text-align: center;
  color: var(--ink-muted);
}

@media (max-width: 1080px) {
  .card-globe {
    min-height: calc(100vh - 64px);
    min-height: calc(100svh - 64px);
  }

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

/* 地球卡的窄屏覆盖必须放在这里：.globe-* 基础规则定义在本文件更靠后的位置，
   同优先级按源码顺序后者胜出，放进前面的响应式区会被基础规则盖掉。
   背景：.globe-ip 的 clamp 下限 36px 在窄屏放不下 13 个等宽字符，
   IPv4 末位会被折到第二行。 */
@media (max-width: 760px) {
  .globe-ip {
    font-size: clamp(26px, 7.2vw, 44px);
  }

  .globe-panel {
    padding: 20px 24px 18px;
  }
}

@media (max-width: 460px) {
  .globe-ip {
    font-size: clamp(20px, 7vw, 32px);
  }

  .globe-panel {
    padding: 18px 18px 16px;
  }

  .globe-status {
    letter-spacing: 0.08em; /* 状态行字距收紧，窄屏少折一行 */
  }
}

@media (max-width: 380px) {
  /* 极窄屏固定小字号，保证 13 字符 IPv4 单行 */
  .globe-ip {
    font-size: 19px;
  }

  .globe-center {
    padding: 0 10px;
  }
}
