:root{color-scheme:dark;--bg:#090f1d;--card:#121f30;--line:#253a50;--blue:#38bdf8;--muted:#9eb3c8}*{box-sizing:border-box}body{margin:0;background:radial-gradient(circle at 50% -10%,#15314c,#090f1d 58%);font:15px/1.5 system-ui,-apple-system,"Microsoft YaHei",sans-serif;color:#f0f7ff;min-height:100vh}main{max-width:930px;margin:auto;padding:56px 18px}header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:27px}h1{font-size:clamp(23px,4vw,32px);margin:0}.sub,.dim{color:var(--muted)}.sub{margin-top:5px}.mark{font-size:13px;color:#8bc8ea;border:1px solid #285073;padding:8px 13px;border-radius:999px}.panel{background:rgba(18,31,48,.95);border:1px solid var(--line);border-radius:22px;padding:clamp(20px,4vw,36px);box-shadow:0 24px 75px #0004}.ip{border:1px solid #2b4661;background:#16293f;padding:14px 18px;border-radius:12px;display:flex;align-items:center;justify-content:space-between;gap:12px}.ip strong{font-size:clamp(17px,3vw,22px);font-variant-numeric:tabular-nums;overflow-wrap:anywhere}.eyebrow{font-size:13px;color:#abc5dc}.speed{text-align:center;padding:33px 0 24px}.number{font-size:clamp(64px,13vw,112px);line-height:1.2;font-variant-numeric:tabular-nums;font-weight:750;letter-spacing:-5px}.unit{color:#93c8ea;font-size:20px}.state{color:var(--muted)}.bar{height:8px;background:#293b52;border-radius:100px;overflow:hidden;margin-top:15px}.fill{height:100%;width:0;background:linear-gradient(90deg,#1f9dca,#48d4ff);transition:width .16s}.metrics{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin:24px 0}.metric{background:#172a3e;border:1px solid #2b455e;padding:18px;border-radius:14px}.metric strong{font-size:clamp(23px,4vw,34px);display:block;font-variant-numeric:tabular-nums}.metric span{display:block;color:var(--muted);font-size:13px}button{background:#38bdf8;border:0;color:#051625;font:700 17px inherit;font-size:17px;font-weight:700;padding:15px 30px;border-radius:12px;width:100%;cursor:pointer}button:disabled{opacity:.55;cursor:default}.note{color:#9cb4c9;font-size:13px;margin-top:20px;line-height:1.7}.status{text-align:center;min-height:22px;margin-top:15px;color:#a7c8df}footer{text-align:center;color:#687f96;font-size:12px;margin-top:24px}.small{font-size:12px}@media(max-width:600px){header{align-items:start;flex-direction:column}.metrics{grid-template-columns:1fr}.metric{padding:13px 16px}.metric strong{display:inline}.metric span{display:inline;margin-right:10px}.number{letter-spacing:-2px}}
.consent{display:flex;align-items:flex-start;gap:10px;color:#b6d0e0;font-size:13px;line-height:1.55;margin:10px 0 17px}.consent input{margin-top:3px;width:17px;height:17px;accent-color:#38bdf8;flex:none}.secondary{margin-top:12px;background:#253d55;color:#d8f2ff}#codebox{margin:8px 0 14px;color:#a8c5db}#codebox input{width:100%;padding:10px;border-radius:9px;background:#0a1726;color:#fff;border:1px solid #37536e;margin-top:6px}

.network-info{background:#16293f;border:1px solid #2b4661;border-radius:13px;overflow:hidden}.network-row{display:flex;justify-content:space-between;align-items:center;gap:15px;padding:13px 20px}.network-row+.network-row{border-top:1px solid #2c425a}.network-label{font-size:14px;color:#b7d1e8;min-width:170px}.network-label small{display:block;font-size:11px;color:#7797b4;font-weight:400}.network-row strong{font-size:clamp(15px,2.6vw,21px);text-align:right;overflow-wrap:anywhere;max-width:66%;font-weight:700}.network-row:first-child strong{font-size:clamp(19px,3vw,25px)}.detail-note{font-size:12px;color:#86a0b7;margin-top:10px}.number{font-variant-numeric:tabular-nums;will-change:contents}@media(max-width:600px){.network-row{align-items:flex-start;flex-direction:column;gap:3px}.network-row strong{text-align:left;max-width:100%}}

.submit-hint{padding:14px 16px;margin-top:14px;border:1px solid #247b9c;background:rgba(28,113,149,.19);color:#e0f6ff;border-radius:12px;text-align:center;font-size:15px;font-weight:650}.submit-hint small{display:block;font-weight:400;font-size:12px;color:#a9c9dc;margin-top:4px}

.test-time{display:flex;justify-content:center;align-items:center;gap:10px;flex-wrap:wrap;margin:14px 0 0;padding:11px 15px;border:1px solid #34536c;border-radius:10px;background:#152a40;color:#b3cee0;font-size:14px}.test-time strong{font-size:17px;color:#f0f7ff;font-variant-numeric:tabular-nums}.test-time small{color:#8db1cd;font-size:12px}

/* V4.5 手机一屏截图模式：测速结束隐藏重复的大数字，保留三项实测。 */
@media(max-width:600px){
  body{font-size:13px;line-height:1.35}
  main{padding:9px 9px 14px;max-width:100%}
  header{display:flex;flex-direction:row;align-items:center;justify-content:space-between;margin-bottom:7px;gap:5px}
  h1{font-size:18px;line-height:1.25;letter-spacing:-.4px}
  .sub{font-size:10px;margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:255px}
  .mark{font-size:10px;padding:4px 7px;white-space:nowrap}
  .panel{padding:10px;border-radius:12px;box-shadow:none}
  .network-info{border-radius:9px}
  .network-row{padding:7px 9px;display:flex;align-items:center;flex-direction:row;gap:6px;min-height:38px}
  .network-label{font-size:11px;min-width:57px;max-width:65px;flex:none;line-height:1.1}
  .network-label small{display:none}
  .network-row strong,.network-row:first-child strong{font-size:13px;max-width:none;text-align:right;line-height:1.18;overflow-wrap:anywhere;min-width:0}
  .speed{padding:8px 0 5px}
  .number{font-size:clamp(40px,13vw,58px);letter-spacing:-2px;line-height:1.1}
  .unit{font-size:13px}
  .state{font-size:11px}
  .bar{height:5px;margin-top:5px}
  .metrics{grid-template-columns:repeat(3,minmax(0,1fr));gap:5px;margin:9px 0}
  .metric{padding:7px 5px;border-radius:8px;text-align:center;min-width:0}
  .metric span{display:block;font-size:10px;margin:0}
  .metric strong{display:block;font-size:clamp(17px,5vw,24px);line-height:1.35;font-variant-numeric:tabular-nums}
  #start{padding:10px;font-size:14px;border-radius:8px}
  .status{font-size:11px;line-height:1.25;min-height:0;margin-top:7px}
  .test-time{padding:7px 8px;margin-top:7px;font-size:11px;gap:6px;flex-wrap:nowrap}
  .test-time strong{font-size:12px}
  .test-time small{display:none}
  .submit-hint{padding:8px;margin-top:7px;border-radius:8px;font-size:12px}
  .submit-hint small{display:none}
  .note{font-size:10px;line-height:1.35;margin-top:10px}
  .detail-note{display:none}
  footer{font-size:10px;margin-top:10px}
  body.completed .speed{display:none}
  body.completed .metrics{margin-top:11px}
}
@media(max-width:360px){h1{font-size:16px}.sub{font-size:9px}.mark{font-size:9px}.network-row strong,.network-row:first-child strong{font-size:12px}.metric strong{font-size:17px}}

/* 最终版：简短测速提示，避免覆盖测速结果 */
.simple-notice{max-width:850px;margin:15px auto 2px;text-align:center;font-size:12px;line-height:1.7;color:#8fa9c6;font-weight:400}
@media(max-width:600px){.simple-notice{font-size:11px;line-height:1.5;margin:9px auto 2px;padding:0 2px}}
/* Respect the HTML hidden attribute even when components set display:flex */
[hidden]{display:none!important}

/* 可切换的红色联系公告；与源码 CSP 兼容 */
.wechat-notice{text-align:center;color:#ff6655;font-size:12px;font-weight:700;line-height:1.6;margin:10px auto 2px;overflow-wrap:anywhere}
.wechat-notice strong{font-weight:800;color:inherit}
@media(max-width:600px){.wechat-notice{font-size:11px;margin:7px auto 2px}}
