* { box-sizing: border-box; }
  html, body { min-height: 100%; }
  :root {
    --bg: #05060a;
    --line: rgba(255,255,255,.09);
    --line-2: rgba(255,255,255,.16);
    --text: #e8ecf4;
    --dim: rgba(203,213,235,.5);
    --cyan: #22d3ee;
    --violet: #a78bfa;
  }
  body {
    margin: 0;
    min-height: 100vh;
    padding: 0 40px;
    color: var(--text);
    background: var(--bg);
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
      "PingFang SC", "Microsoft YaHei", monospace;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
  }

  /* 氛围层 */
  .ambient { position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background:
      radial-gradient(60% 50% at 50% 0%, rgba(34,211,238,.10), transparent 70%),
      radial-gradient(50% 45% at 82% 92%, rgba(167,139,250,.10), transparent 70%);
  }
  .grid { position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background-image:
      linear-gradient(rgba(255,255,255,.032) 1px, transparent 1px),
      linear-gradient(90deg, rgba(255,255,255,.032) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(circle at 50% 45%, #000 10%, transparent 78%);
    mask-image: radial-gradient(circle at 50% 45%, #000 10%, transparent 78%);
  }
  .horizon { position: fixed; left: 50%; top: 0; width: 1px; height: 100vh; z-index: 0;
    transform: translateX(-50%);
    background: linear-gradient(180deg, transparent, rgba(34,211,238,.22), transparent);
    opacity: .8;
  }

  .shell {
    position: relative; z-index: 1;
    max-width: 860px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex; flex-direction: column;
    padding: 30px 0 26px;
  }

  /* 顶栏 */
  header {
    display: flex; align-items: center; justify-content: space-between;
    padding-bottom: 22px;
    border-bottom: 1px solid var(--line);
    font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
  }
  .brand { display: flex; align-items: center; gap: 10px; color: #fff; }
  .mark {
    display: grid; place-items: center;
    width: 24px; height: 24px; border-radius: 6px;
    color: var(--cyan);
    background: linear-gradient(140deg, rgba(34,211,238,.18), rgba(167,139,250,.14));
    border: 1px solid rgba(34,211,238,.3);
    font-size: 12px;
    box-shadow: 0 0 20px -4px rgba(34,211,238,.5);
  }
  .brand small { color: var(--dim); font-size: 10px; letter-spacing: .24em; }
  .status { display: flex; align-items: center; gap: 10px; color: var(--dim); }
  .status b { color: rgba(232,236,244,.85); font-weight: 400; font-variant-numeric: tabular-nums; }
  /* 天气：加载失败时脚本会直接移除该节点 */
  .weather { display: inline-flex; align-items: center; gap: 6px; font-variant-numeric: tabular-nums; }
  .weather[hidden] { display: none; }
  .weather .w-temp { color: rgba(232,236,244,.85); }
  .weather .w-city { color: rgba(203,213,235,.38); }
  #weather { cursor: pointer; }
  #weather:hover { color: #fff; }
  #weather .w-city { text-decoration: underline dotted rgba(203,213,235,.4); text-underline-offset: 3px; }

  /* 城市选择面板 */
  .city-modal {
    position: fixed; inset: 0; z-index: 20;
    display: grid; place-items: center;
    padding: 24px;
    background: rgba(3,5,9,.72);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
  }
  .city-modal[hidden] { display: none; }
  .city-box {
    width: min(460px, 100%);
    max-height: min(82vh, 640px);
    display: flex; flex-direction: column;
    padding: 20px;
    border-radius: 12px;
    background: #0b0f17;
    border: 1px solid rgba(255,255,255,.14);
    box-shadow: 0 30px 90px -30px rgba(0,0,0,.95), 0 0 70px -32px rgba(34,211,238,.5);
  }
  .city-head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 14px;
    font-size: 11px; letter-spacing: .18em; text-transform: uppercase;
    color: rgba(232,236,244,.75);
  }
  .city-close {
    width: 26px; height: 26px;
    border: 1px solid rgba(255,255,255,.12); border-radius: 6px;
    background: transparent;
    color: rgba(203,213,235,.7);
    font: inherit; font-size: 14px; line-height: 1;
    cursor: pointer;
  }
  .city-close:hover { border-color: rgba(34,211,238,.5); color: #fff; }
  .city-auto {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    margin-bottom: 12px; padding: 10px 12px;
    border: 1px solid rgba(255,255,255,.08); border-radius: 8px;
    background: rgba(255,255,255,.03);
    font-size: 11px; letter-spacing: .04em;
    color: rgba(203,213,235,.55);
  }
  .city-auto button {
    border: 0; background: transparent;
    color: #22d3ee; font: inherit; font-size: 11px;
    letter-spacing: .06em; cursor: pointer;
  }
  .city-auto button:hover { color: #fff; }
  .city-search { display: flex; gap: 8px; margin-bottom: 12px; }
  .city-search input {
    flex: 1; min-width: 0; height: 38px;
    padding: 0 12px;
    border: 1px solid rgba(255,255,255,.12); border-radius: 8px;
    background: rgba(255,255,255,.04);
    color: #e8ecf4; font: inherit; font-size: 12.5px;
    outline: 0;
  }
  .city-search input:focus { border-color: rgba(34,211,238,.55); box-shadow: 0 0 24px -10px rgba(34,211,238,.5); }
  .city-search input::placeholder { color: rgba(203,213,235,.3); }
  .city-search button {
    flex: none; height: 38px; padding: 0 15px;
    border: 1px solid rgba(34,211,238,.35); border-radius: 8px;
    background: rgba(34,211,238,.1);
    color: #a5f3fc; font: inherit; font-size: 11.5px; letter-spacing: .08em;
    cursor: pointer;
  }
  .city-search button:hover { background: rgba(34,211,238,.18); color: #fff; }
  .city-list {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px;
    overflow-y: auto; padding-right: 2px;
  }
  .city-list button {
    height: 34px;
    border: 1px solid rgba(255,255,255,.08); border-radius: 6px;
    background: rgba(255,255,255,.03);
    color: rgba(232,236,244,.75);
    font: inherit; font-size: 12px;
    cursor: pointer;
    transition: border-color .2s, background .2s, color .2s;
  }
  .city-list button:hover { border-color: rgba(34,211,238,.45); background: rgba(34,211,238,.08); color: #fff; }
  .city-list button.on { border-color: rgba(34,211,238,.7); background: rgba(34,211,238,.14); color: #fff; }
  .city-tip {
    margin-top: 12px; min-height: 15px;
    font-size: 10.5px; line-height: 1.6; letter-spacing: .03em;
    color: rgba(203,213,235,.35);
  }
  @media (max-width: 640px) {
    .city-list { grid-template-columns: repeat(3, 1fr); }
    .city-box { padding: 16px; }
  }
  .dot { width: 6px; height: 6px; border-radius: 50%; background: #34d399;
    box-shadow: 0 0 10px 1px rgba(52,211,153,.8); animation: pulse 2.6s ease-in-out infinite; }
  @keyframes pulse { 50% { opacity: .35; } }
  .sep { color: rgba(255,255,255,.18); }

  /* 主体 */
  main { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 44px 0; }
  .eyebrow {
    margin: 0 0 18px;
    font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
    color: rgba(34,211,238,.7);
  }
  .eyebrow span { color: rgba(255,255,255,.25); margin-right: 8px; }

  h1 {
    margin: 0 0 30px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
      "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    font-size: clamp(34px, 5.6vw, 56px);
    font-weight: 200;
    line-height: 1.16;
    letter-spacing: -0.01em;
    background: linear-gradient(100deg, #ffffff 18%, #a5f3fc 58%, #c4b5fd 96%);
    -webkit-background-clip: text; background-clip: text;
    color: transparent;
  }
  h1 em {
    font-style: normal;
    background: linear-gradient(100deg, var(--cyan), var(--violet));
    -webkit-background-clip: text; background-clip: text;
    color: transparent;
  }

  /* 搜索框 */
  .search {
    position: relative;
    z-index: 10;
    display: flex; align-items: center;
    height: 66px;
    padding: 0 8px 0 20px;
    background: rgba(12,15,23,.85);
    border: 1px solid var(--line-2);
    border-radius: 12px;
    transition: border-color .3s, box-shadow .3s, background .3s;
  }
  .search::after {
    content: ""; position: absolute; inset: -1px; border-radius: 12px;
    padding: 1px; pointer-events: none;
    background: linear-gradient(100deg, rgba(34,211,238,.85), rgba(167,139,250,.7));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
    opacity: 0; transition: opacity .3s;
  }
  .search:focus-within { background: rgba(15,19,29,.95); box-shadow: 0 0 60px -18px rgba(34,211,238,.55); }
  .search:focus-within::after { opacity: 1; }
  .prompt { color: rgba(34,211,238,.75); font-size: 15px; margin-right: 12px; user-select: none; }
  .search input {
    flex: 1; min-width: 0; height: 100%;
    border: 0; outline: 0; background: transparent;
    color: var(--text); font: inherit; font-size: 15px; letter-spacing: .01em;
  }
  .search input::placeholder { color: rgba(203,213,235,.32); }
  .search .enter {
    flex: none;
    display: flex; align-items: center; gap: 7px;
    height: 50px; padding: 0 16px;
    border: 0; border-left: 1px solid var(--line);
    background: transparent; color: var(--dim);
    font: inherit; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase;
    cursor: pointer; transition: color .25s, background .25s;
  }
  .search .enter:hover { color: #fff; background: rgba(255,255,255,.04); }

  /* 搜索联想下拉 */
  .sug {
    position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 12;
    padding: 6px;
    max-height: min(420px, 46vh);
    overflow-y: auto;
    border-radius: 10px;
    background: #0b0f17;
    border: 1px solid rgba(255,255,255,.14);
    box-shadow: 0 26px 70px -26px rgba(0,0,0,.95), 0 0 60px -34px rgba(34,211,238,.55);
    animation: sugIn .18s ease both;
  }
  .sug[hidden] { display: none; }
  @keyframes sugIn { from { opacity: 0; transform: translateY(-4px); } }
  .sug-item {
    display: flex; align-items: center; gap: 10px;
    width: 100%; padding: 9px 12px;
    border: 0; border-left: 2px solid transparent; border-radius: 6px;
    background: transparent;
    color: rgba(232,236,244,.78);
    font: inherit; font-size: 12.5px; letter-spacing: .02em;
    text-align: left; cursor: pointer;
  }
  .sug-item .sug-ico { flex: none; color: rgba(34,211,238,.45); font-size: 11px; }
  .sug-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .sug-item:hover, .sug-item.on {
    border-left-color: #22d3ee;
    background: rgba(34,211,238,.09);
    color: #fff;
  }

  /* 引擎 */
  .engines {
    display: flex; align-items: center; gap: 22px;
    margin-top: 16px; padding-left: 2px;
    font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
  }
  .engines .label { color: rgba(255,255,255,.22); }
  .engines button {
    position: relative;
    padding: 4px 0; border: 0; background: transparent;
    color: var(--dim); font: inherit; font-size: 11px;
    letter-spacing: .14em; text-transform: uppercase; cursor: pointer;
    transition: color .22s;
  }
  .engines button::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: -3px; height: 1px;
    background: linear-gradient(90deg, var(--cyan), var(--violet));
    transform: scaleX(0); transform-origin: left;
    transition: transform .28s;
  }
  .engines button:hover { color: rgba(232,236,244,.9); }
  .engines button.active { color: #fff; }
  .engines button.active::after { transform: scaleX(1); }

  /* 链接列表 */
  .sites {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: 1px;
    margin-top: 40px;
    background: var(--line);
    border: 1px solid var(--line);
    border-radius: 12px;
    overflow: hidden;
  }
  .site {
    display: flex; align-items: center; gap: 14px;
    padding: 15px 18px;
    background: rgba(8,10,16,.88);
    text-decoration: none; color: inherit;
    transition: background .25s, transform .25s;
  }
  .site:hover { background: rgba(22,28,42,.95); }
  .site .num { font-size: 10px; letter-spacing: .08em; color: rgba(34,211,238,.5); }
  .site .ico { font-size: 15px; width: 22px; text-align: center; filter: saturate(.9); }
  .site .ico .site-ico { width: 17px; height: 17px; display: block; margin: 0 auto; border-radius: 3px; }
  .site .name { flex: 1; font-size: 13px; letter-spacing: .02em; color: rgba(232,236,244,.9); }
  .site .host { display: none; font-size: 10.5px; color: rgba(203,213,235,.3); letter-spacing: .04em; }
  .site .arrow { color: rgba(203,213,235,.28); font-size: 12px; transition: color .25s, transform .25s; }
  .site:hover .arrow { color: var(--cyan); transform: translate(2px, -2px); }

  /* 底栏 */
  footer {
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
    padding-top: 20px;
    border-top: 1px solid var(--line);
    font-size: 10.5px; letter-spacing: .1em; color: rgba(203,213,235,.3);
  }
  footer span b { color: rgba(203,213,235,.6); font-weight: 400; }
  .corner { display: flex; align-items: center; gap: 8px; }
  .corner::before, .corner::after { content: ""; width: 14px; height: 1px; background: rgba(255,255,255,.14); }

  /* 底部备案信息：号码换成你自己的即可 */
  .beian {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
    gap: 6px 16px;
    padding-top: 12px;
    font-size: 11.5px;
    line-height: 1.7;
    letter-spacing: .04em;
    color: rgba(203,213,235,.3);
  }
  .beian a { color: rgba(203,213,235,.32); text-decoration: none; transition: color .2s; }
  .beian a:hover { color: #22d3ee; }
  .beian .police { display: inline-flex; align-items: center; gap: 5px; }
  .beian .beian-ico { flex: none; width: 18px; height: 18px; border-radius: 2px; align-self: center; }

  .fade { animation: fade .9s cubic-bezier(.2,.8,.3,1) both; }
  @keyframes fade { from { opacity: 0; transform: translateY(10px); } }

  @media (min-width: 760px) { .site .host { display: block; } }
  @media (max-width: 640px) {
    body { padding: 0 20px; }
    .sites { grid-template-columns: 1fr; }
    .status .clock-text, .status .sep { display: none; }
    .site .host { display: none; }
    h1 { margin-bottom: 24px; }
    main { padding: 32px 0; }
  }
