/* sight 官网样式 —— 由 web/build.py 从 src/styles/ 合并生成，别直接改这里。
   源文件（按合并顺序）：00-tokens.css  10-base.css  20-layout.css  30-components.css  40-pages.css  50-home.css */

/* ==================== 00-tokens.css ==================== */

/* ==========================================================================
   sight 官网 · 设计基线（design tokens）
   2026-10-14 改版：深色像素风 -> 亮色现代风。
   ──────────────────────────────────────────────────────────────────────────
   纪律：
     · 颜色 / 圆角 / 阴影 只在这里定义，别在组件里写死 hex。
     · 零外部资源 —— 不引 web font、不引 CDN。
     · 对比度按 WCAG AA 取：正文 --ink 对 --bg 约 15:1；
       主色 --brand 对白底约 5.2:1（够 AA 正文）；浅底只做背景，不承载文字。
   ========================================================================== */

:root {
  color-scheme: light;

  /* —— 底色层 —— */
  --bg:        #f5f7fa;
  --bg-soft:   #eef1f6;
  --surface:   #ffffff;
  --surface-2: #f7f9fb;

  /* —— 分隔线 —— */
  --line:      #e4e8ef;
  --line-2:    #cfd6e0;

  /* —— 文字三层 —— */
  --ink:       #101828;
  --ink-2:     #475467;
  --ink-3:     #8b95a7;

  /* —— 主色：MC 草绿。压深到 #2e7d32 是为了在白底上过 AA —— */
  --brand:     #2e7d32;
  --brand-d:   #235c26;
  --brand-l:   #66bb6a;
  --brand-t:   #e7f4e8;   /* tint：只做底色，不在上面放正文 */
  --on-brand:  #ffffff;

  /* —— 语义色 —— */
  --gold:      #a15c00;
  --gold-t:    #fff5e5;
  --red:       #c0392b;
  --red-t:     #fdecea;
  --blue:      #1d4ed8;

  /* —— 阴影 —— */
  --sh-1: 0 1px 2px rgba(16, 24, 40, .05);
  --sh-2: 0 2px 6px rgba(16, 24, 40, .06), 0 1px 2px rgba(16, 24, 40, .04);
  --sh-3: 0 10px 26px rgba(16, 24, 40, .09), 0 2px 6px rgba(16, 24, 40, .05);

  /* —— 圆角 —— */
  --r-s:    8px;
  --r:      12px;
  --r-l:    16px;
  --r-pill: 999px;

  /* —— 字体：中文走系统字体，数字/代号走等宽 —— */
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
          "Hiragino Sans GB", "Microsoft YaHei", Roboto, "Helvetica Neue",
          Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono",
          monospace;
  /* 10-15 加：像素字体（Fusion Pixel 12px，自托管子集，见 50-home.css 头注）。
     只上固定文案标题，动态内容一律 --sans。缺失字形自动回退，不会开天窗。 */
  --pixel: "Sight Pixel", -apple-system, BlinkMacSystemFont, "Segoe UI",
           "PingFang SC", "Microsoft YaHei", sans-serif;

  /* —— 动效 tokens（taste-skill motion 标准，10-16）—— */
  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);   /* 入场/离场/揭示 */
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);   /* 屏内两点间移动 */
  --dur-press: 120ms;    /* 按压反馈 */
  --dur-hover: 180ms;    /* hover */
  --dur-reveal: 650ms;   /* 区块入场 */

  /* —— 版心 —— */
  --maxw:   1080px;
  --gutter: 20px;

  /* —— 页顶那层绿光（body 背景用；亮色淡、深色更淡）—— */
  --glow:   rgba(102, 187, 106, .30);
  --topbar: rgba(255, 255, 255, .82);
}

/* --------------------------------------------------------------------------
   深色主题钩子：默认不启用。
   要整站回深色，把 src/partials/head.html 的 <html> 改成
   <html lang="zh-CN" data-theme="dark"> 即可，样式不用重写。
   保留这一套是为了「以后想换回去，成本是一次点击」。
   -------------------------------------------------------------------------- */
html[data-theme="dark"] {
  color-scheme: dark;

  --bg:        #0e1116;
  --bg-soft:   #161a22;
  --surface:   #14181f;
  --surface-2: #1a1f28;

  --line:      #242a34;
  --line-2:    #333b47;

  --ink:       #e8ecf2;
  --ink-2:     #a3adbd;
  --ink-3:     #6e7987;

  --brand:     #5fb463;
  --brand-d:   #4c9a50;
  --brand-l:   #7ecb82;
  --brand-t:   #16281a;
  --on-brand:  #08170a;

  --gold:      #e0a83c;
  --gold-t:    #2a2110;
  --red:       #e57368;
  --red-t:     #2c1614;
  --blue:      #7aa7f0;

  --sh-1: 0 1px 2px rgba(0, 0, 0, .4);
  --sh-2: 0 2px 6px rgba(0, 0, 0, .45);
  --sh-3: 0 10px 26px rgba(0, 0, 0, .5);

  --glow:   rgba(95, 180, 99, .16);
  --topbar: rgba(14, 17, 22, .82);
}


/* ==================== 10-base.css ==================== */

/* ==========================================================================
   基础层：reset + 排版 + 全局元素
   ========================================================================== */

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background-color: var(--bg);
  /* 页顶一层极淡的绿光，给大块浅底一点纵深；固定住，滚动时不跟着跑 */
  background-image: radial-gradient(1100px 520px at 50% -220px,
                    var(--glow), transparent 70%);
  background-repeat: no-repeat;
  background-attachment: fixed;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 { line-height: 1.3; }

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}

::selection { background: rgba(102, 187, 106, .28); }

/* 行内代码 / 代号：浅底 + 细边，颜色跟正文走（不用担心对比度）。
   🔴 断行用 overflow-wrap 而不是 word-break:break-all —— 群号 / 地址是
   「一个整体」，break-all 会在任意字符处劈开（1121618123 变 112 / 1618123）。 */
code, .mono {
  font-family: var(--mono);
  font-size: .9em;
  background: var(--surface-2);
  border: 1px solid var(--line);
  padding: 2px 7px;
  border-radius: 6px;
  color: var(--ink);
  overflow-wrap: break-word;
  word-break: normal;
}

.muted { color: var(--ink-3); font-size: 13.5px; }
.err   { color: var(--gold); font-size: 14px; }

/* 动效敏感的人：关掉所有装饰性动画 */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; animation-iteration-count: 1 !important;
      transition-duration: .001ms !important; scroll-behavior: auto !important; }
}


/* ==================== 20-layout.css ==================== */

/* ==========================================================================
   布局层：版心 / 顶栏 / Hero / 区块 / 页脚
   ========================================================================== */

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------------------------------------------------------------- 顶栏 */
.topbar {
  position: sticky; top: 0; z-index: 30;
  background: var(--topbar);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar .wrap {
  display: flex; align-items: center; gap: 14px;
  height: 60px;
}

.brand {
  display: inline-flex; align-items: center; gap: 9px;
  color: var(--ink);
}
.brand:hover { text-decoration: none; }
.brand-text { font-size: 17px; font-weight: 700; letter-spacing: -.01em; }

/* 品牌标记：服务器 logo 正本（static/logo.png，仓库根 icon_preview.png 同源）。
   10-15 起弃用自绘 CSS 绿方块 —— 老大指出目录里有现成 logo。 */
.brand-logo {
  width: 27px; height: 27px; flex: none;
  border-radius: 7px;
  display: block;
}

.nav { margin-left: auto; display: flex; gap: 2px; flex-wrap: wrap; }
.nav a {
  color: var(--ink-2); font-size: 14.5px; font-weight: 500;
  padding: 7px 13px; border-radius: var(--r-s);
  position: relative;
  transition: background var(--dur-hover, 180ms) ease, color var(--dur-hover, 180ms) ease;
}
/* 像素下划线：hover 时从中间长出的方块条（与站点的像素语言一致） */
.nav a::after {
  content: ""; position: absolute; left: 50%; bottom: 3px;
  width: 0; height: 3px; background: var(--brand);
  transform: translateX(-50%);
  transition: width var(--dur-hover, 180ms) var(--ease-out, ease-out);
}
.nav a:hover::after { width: 18px; }
.nav a:hover { color: var(--ink); background: var(--bg-soft); text-decoration: none; }
.nav a.on { color: var(--brand); background: var(--brand-t); font-weight: 600; }
.nav a.on::after { width: 18px; }

/* ---------------------------------------------------------------- Hero */
.hero { padding: 76px 0 56px; }
.hero h1 {
  margin: 0 0 10px;
  font-size: clamp(44px, 10vw, 76px);
  font-weight: 800; letter-spacing: -.035em; line-height: 1;
  color: var(--ink);
}
.hero h1 .dot { color: var(--brand-l); }
.hero .tag {
  margin: 0 0 12px;
  font-size: clamp(17px, 2.4vw, 21px); font-weight: 600; color: var(--ink);
}
.hero .sub {
  margin: 0 0 28px; max-width: 640px;
  font-size: 15.5px; color: var(--ink-2);
}
.hero-meta {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  margin-bottom: 26px;
}
.hero-meta-sep { width: 1px; height: 18px; background: var(--line-2); }
.hero-meta-wl { font-size: 14px; color: var(--ink-3); }
.hero-meta-wl b { font-family: var(--mono); color: var(--ink); font-size: 16px; }

/* ---------------------------------------------------------------- 内页题头 */
.page-head { padding: 52px 0 0; }
.page-head h1 {
  margin: 0 0 8px;
  font-size: clamp(30px, 6vw, 46px);
  font-weight: 800; letter-spacing: -.03em; line-height: 1.1;
}
.page-head .sub { margin: 0; color: var(--ink-2); font-size: 15.5px; }

/* ---------------------------------------------------------------- 区块 */
section { padding: 52px 0; }
section + section { border-top: 1px solid var(--line); }
/* 紧贴题头的那块（查询框所在），不画分隔线 */
.section-tight { padding: 22px 0 44px; border-top: none; }

h2.sec {
  margin: 0 0 22px;
  font-size: 22px; font-weight: 700; letter-spacing: -.01em; color: var(--ink);
}
h2.sec::before {
  content: ""; display: block;
  width: 30px; height: 3px; border-radius: 2px;
  background: var(--brand);
  margin-bottom: 12px;
}
.sec-note { margin: -8px 0 22px; color: var(--ink-2); font-size: 14.5px; }

/* 「标题 + 右上角更多」 */
.sec-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
}
.sec-more { font-size: 14px; color: var(--ink-2); white-space: nowrap; }
.sec-more:hover { color: var(--brand); text-decoration: none; }

/* ---------------------------------------------------------------- 页脚 */
.footer {
  margin-top: 24px; padding: 44px 0 56px;
  border-top: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-2);
}
.foot-grid {
  display: grid; gap: 24px;
  grid-template-columns: 1.5fr 1fr 1fr;
}
.foot-brand {
  display: flex; align-items: center; gap: 9px;
  font-weight: 700; color: var(--ink); margin-bottom: 8px;
}
.foot-note { margin: 0; font-size: 14px; color: var(--ink-3); max-width: 290px; }
.foot-col h4 {
  margin: 0 0 10px;
  font-size: 12.5px; font-weight: 600; letter-spacing: .05em; color: var(--ink-3);
}
.foot-col p { margin: 0 0 8px; font-size: 14px; }
.foot-col code { font-size: 12.5px; }

.footer .dis {
  margin: 30px 0 0; padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 13px; line-height: 1.85; color: var(--ink-3); max-width: 720px;
}

/* ---------------------------------------------------------------- 断点 */
@media (max-width: 760px) {
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-col-brand { grid-column: 1 / -1; }
}

@media (max-width: 560px) {
  .hero { padding: 52px 0 40px; }
  .page-head { padding: 36px 0 0; }
  section { padding: 40px 0; }
  .section-tight { padding: 18px 0 34px; }
  .topbar .wrap { height: auto; padding: 10px var(--gutter); flex-wrap: wrap; }
  .nav { margin-left: 0; width: 100%; }
  .nav a { padding: 6px 10px; font-size: 13.5px; }
  .foot-grid { grid-template-columns: 1fr; gap: 20px; }
}


/* ==================== 30-components.css ==================== */

/* ==========================================================================
   组件层：按钮 / 在线胶囊 / 卡片 / 步骤 / 表单 / 结果块 / 徽章 / 公告
   ========================================================================== */

/* ---------------------------------------------------------------- 按钮 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  font-family: inherit; font-size: 15px; font-weight: 600;
  padding: 12px 22px; border-radius: var(--r);
  cursor: pointer;
  border: 1px solid var(--line-2);
  background: var(--surface); color: var(--ink);
  box-shadow: var(--sh-1);
  transition: transform var(--dur-hover, 180ms) var(--ease-out, ease-out),
              background var(--dur-hover, 180ms) ease,
              border-color var(--dur-hover, 180ms) ease,
              box-shadow var(--dur-hover, 180ms) ease;
}
.btn:hover {
  background: var(--surface-2); text-decoration: none;
  box-shadow: var(--sh-2);
  transform: translateY(-2px);
}
.btn:active { transform: translateY(1px); box-shadow: var(--sh-1); transition-duration: var(--dur-press, 120ms); }
.btn:disabled { opacity: .55; cursor: not-allowed; box-shadow: none; }

.btn-primary {
  background: var(--brand); border-color: var(--brand); color: var(--on-brand);
  box-shadow: 0 2px 8px rgba(46, 125, 50, .24);
}
.btn-primary:hover {
  background: var(--brand-d); border-color: var(--brand-d); color: var(--on-brand);
  box-shadow: 0 4px 14px rgba(46, 125, 50, .30);
}
.btn-ghost { background: var(--surface); color: var(--ink); }

.cta { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------------------------------------------------------------- 在线胶囊 */
.live {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 9px 16px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-pill);
  box-shadow: var(--sh-1);
  font-size: 15px; color: var(--ink-2);
}
.live b { font-family: var(--mono); font-size: 17px; color: var(--brand); }
.live .src { color: var(--ink-3); font-size: 12px; }
.live .pulse {
  position: relative; width: 9px; height: 9px; flex: none;
  border-radius: 50%; background: #43a047;
}
.live .pulse::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: #43a047;
  animation: sight-ping 2.2s cubic-bezier(0, 0, .2, 1) infinite;
}
@keyframes sight-ping {
  75%, 100% { transform: scale(2.6); opacity: 0; }
}

/* ---------------------------------------------------------------- 卡片网格 */
.grid {
  display: grid; gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-l); padding: 22px;
  box-shadow: var(--sh-1);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--sh-3);
  border-color: var(--line-2);
}
.card h3 {
  margin: 0 0 10px; font-size: 16px; font-weight: 700; color: var(--ink);
  display: flex; align-items: center; gap: 11px;
}
.card h3 .ic {
  width: 36px; height: 36px; flex: none;
  display: grid; place-items: center;
  background: var(--brand-t); border-radius: 11px; font-size: 18px;
}
.card p { margin: 0; color: var(--ink-2); font-size: 14.5px; }

/* ---------------------------------------------------------------- 步骤 */
.steps {
  display: grid; gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.step {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-l); padding: 22px;
  box-shadow: var(--sh-1);
}
.step .n {
  display: inline-block; margin-bottom: 12px;
  font-family: var(--mono); font-size: 11px; font-weight: 700;
  letter-spacing: .14em; color: var(--brand); background: var(--brand-t);
  padding: 3px 10px; border-radius: var(--r-pill);
}
.step h3 { margin: 0 0 8px; font-size: 16px; color: var(--ink); }
.step p { margin: 0; color: var(--ink-2); font-size: 14.5px; }

/* ---------------------------------------------------------------- 表单 */
.field { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.field input {
  flex: 1 1 240px; min-width: 0;
  background: var(--surface); border: 1px solid var(--line-2); color: var(--ink);
  font-family: var(--mono); font-size: 16px;
  padding: 13px 15px; border-radius: var(--r);
  box-shadow: var(--sh-1);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.field input:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(102, 187, 106, .20);
}
.field input::placeholder { color: var(--ink-3); font-family: var(--sans); }

/* ---------------------------------------------------------------- 结果块 */
.result {
  margin-top: 8px; padding: 20px 22px;
  background: var(--surface); border: 1px solid var(--line);
  border-left: 4px solid var(--line-2);
  border-radius: var(--r);
  box-shadow: var(--sh-1);
}
.result.ok   { border-left-color: var(--brand); }
.result.warn { border-left-color: #d9a017; }
.result.bad  { border-left-color: var(--red); }
.result.dead { border-left-color: var(--line-2); }
.result h3 { margin: 0 0 8px; font-size: 16.5px; color: var(--ink); }
.result p  { margin: 0 0 8px; color: var(--ink-2); font-size: 14.5px; }
.result p:last-child { margin-bottom: 0; }
.result ul { margin: 8px 0 0; padding-left: 20px; color: var(--ink-2); font-size: 14.5px; }
.result li { margin-bottom: 6px; }
.result li:last-child { margin-bottom: 0; }
/* 跟在卡片网格后面的结果块，拉开一点距离 */
.result-gap { margin-top: 22px; }

/* ---------------------------------------------------------------- 徽章 */
.badge {
  display: inline-block;
  font-family: var(--mono); font-size: 12px;
  padding: 3px 9px; border-radius: var(--r-pill);
  border: 1px solid var(--line-2); color: var(--ink-2); background: var(--surface-2);
}
.badge.active   { color: var(--brand); border-color: #a5d6a7; background: var(--brand-t); }
.badge.pending  { color: var(--gold);  border-color: #edcd95; background: var(--gold-t); }
.badge.rejected { color: var(--ink-3); }
.badge.banned   { color: var(--red);   border-color: #efb4ae; background: var(--red-t); }

/* ---------------------------------------------------------------- 公告 */
.news-list { list-style: none; margin: 0; padding: 0; }
.news-list li { padding: 16px 0; border-bottom: 1px solid var(--line); }
.news-list li:last-child { border-bottom: none; }
.news-list .t { font-weight: 600; font-size: 15.5px; color: var(--ink); }
.news-list .d {
  margin-left: 8px;
  color: var(--ink-3); font-size: 12px; font-family: var(--mono);
}
.news-list .b {
  margin-top: 5px;
  color: var(--ink-2); font-size: 14.5px; white-space: pre-wrap;
}

/* ---------------------------------------------------------------- 复制按钮 */
.copy {
  margin-left: 6px; vertical-align: middle;
  border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2);
  font-family: var(--mono); font-size: 11px;
  padding: 2px 8px; border-radius: 6px; cursor: pointer;
  position: relative; overflow: hidden;
  transition: color .15s ease, border-color .15s ease;
}
.copy:hover { color: var(--brand); border-color: var(--brand); }


/* ==================== 40-pages.css ==================== */

/* ==========================================================================
   页面层：只放「属于某一页的零碎」，通用件一律进 30-components.css
   ========================================================================== */

/* 「我的状态」页查询框下面那段说明 */
.note-gap { margin-top: 16px; }

/* Hero 后面那块（服务器特色）不需要再画一条分隔线 —— 上面就是 header */
.hero + section { border-top: none; padding-top: 34px; }

/* 降级：浏览器不支持毛玻璃（老 Safari / 关闭特效）时，顶栏换成实底，
   否则半透明底 + 深色文字会糊在一起。 */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .topbar { background: var(--surface); }
}

/* 打印：去掉底色与阴影，只留字 */
@media print {
  body { background: #fff; }
  .topbar, .cta, .copy, .footer { display: none; }
  .card, .step, .result, .live { box-shadow: none; border-color: #ccc; }
}

/* ==========================================================================
   公告管理页（/admin，10-15）
   ========================================================================== */

.adm-card { margin-bottom: 22px; }
.adm-card h3 { margin: 0 0 14px; }

/* 登录与发布的表单纵向排 */
#adm-login .field { margin-bottom: 4px; }
#adm-compose { display: grid; gap: 12px; }
#adm-compose input[type="text"],
#adm-title,
#adm-body {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line-2);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  padding: 12px 14px;
  border-radius: var(--r);
  box-shadow: var(--sh-1);
  transition: border-color .15s ease, box-shadow .15s ease;
}
#adm-title:focus, #adm-body:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(102, 187, 106, .20);
}
#adm-body { resize: vertical; min-height: 120px; line-height: 1.8; }

.adm-check {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; color: var(--ink-2);
  cursor: pointer;
}
.adm-check input { accent-color: var(--brand); }

.adm-compose-foot { display: flex; align-items: center; gap: 14px; }

.adm-err { min-height: 1.4em; margin: 10px 0 0; }

.adm-list-head { margin-bottom: 6px; }
.adm-list-head .sec { margin-bottom: 0; }

.adm-pin {
  display: inline-block;
  margin-right: 8px; padding: 2px 8px;
  font-size: 11.5px; font-weight: 600;
  color: var(--gold); background: var(--gold-t);
  border: 1px solid #edcd95; border-radius: var(--r-pill);
  vertical-align: 2px;
}

.adm-actions { margin-top: 8px; }
.adm-actions .copy { margin-left: 0; }

/* ---- 10-16 后台账号制：页签 / 登录格 / 审计 ---- */
.adm-tabs {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  margin-bottom: 18px;
}
.adm-tab {
  border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2);
  font-family: var(--pixel); font-size: 14px;
  padding: 8px 16px; border-radius: var(--r); cursor: pointer;
  transition: color .15s ease, border-color .15s ease, background .15s ease;
}
.adm-tab:hover { color: var(--ink); border-color: var(--brand); }
.adm-tab.on { color: var(--brand); border-color: var(--brand); background: var(--brand-t); }
.adm-tabs-spacer { flex: 1; }
#adm-me { font-size: 13px; }

.adm-login-grid {
  display: grid; gap: 10px;
  grid-template-columns: 1fr 1fr auto;
}
.adm-login-grid input {
  background: var(--surface); border: 1px solid var(--line-2); color: var(--ink);
  font-size: 15px; padding: 12px 14px; border-radius: var(--r);
  box-shadow: var(--sh-1);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.adm-login-grid input:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(102, 187, 106, .20);
}
@media (max-width: 640px) { .adm-login-grid { grid-template-columns: 1fr; } }

.adm-pin-ok { color: var(--brand); border-color: #a5d6a7; background: var(--brand-t); }

/* ---- 神人榜处罚公示表格（/thanks v2）---- */
.hall-sub { margin-left: 10px; font-size: 14px; color: var(--ink-3); font-family: var(--sans); }
.hall-table-wrap { overflow-x: auto; }
.hall-table {
  width: 100%; border-collapse: collapse;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r); overflow: hidden;
  box-shadow: var(--sh-1);
}
.hall-table th, .hall-table td {
  text-align: left; padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 14.5px; color: var(--ink-2);
}
.hall-table thead th {
  background: var(--surface-2); color: var(--ink-3);
  font-size: 12.5px; font-weight: 600; letter-spacing: .05em;
}
.hall-table tbody tr:last-child td { border-bottom: none; }
.hall-table .hall-id { font-family: var(--mono); font-weight: 700; color: var(--ink); }
.hall-table .hall-date { font-family: var(--mono); font-size: 13px; color: var(--ink-3); white-space: nowrap; }
.hall-clean { text-align: center; padding: 26px 16px !important; }

.sponsor-box { margin-bottom: 18px; }

/* ---- 后台：统计卡 / 审核列表 ---- */
.adm-stat { text-align: center; padding: 18px 12px; }
.adm-stat-n { font-family: var(--mono); font-size: 30px; font-weight: 700; color: var(--brand); }
.adm-stat-l { margin-top: 4px; font-size: 13px; color: var(--ink-3); }

/* ---- 游玩文档页（iframe 嵌腾讯文档）---- */
.guide-frame-wrap { max-width: 1080px; margin: 0 auto; padding: 0 var(--gutter) 40px; }
.guide-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 0;
}
.guide-bar .btn { padding: 7px 14px; font-size: 13.5px; }
.guide-frame {
  display: block; width: 100%;
  height: calc(100vh - 170px); min-height: 480px;
  border: 1px solid var(--line); border-radius: var(--r);
  background: #fff; box-shadow: var(--sh-1);
}
.guide-fallback { text-align: center; padding: 12px 0 0; font-size: 13.5px; }

/* ---- 白名单申请页 ---- */
.apply-card { max-width: 560px; margin: 0 auto; padding: 26px 28px; }
.apply-field { margin-bottom: 16px; }
.apply-field label {
  display: block; margin-bottom: 6px;
  font-size: 13.5px; font-weight: 600; color: var(--ink-2);
}
.apply-field input,
.apply-field select,
.apply-field textarea {
  width: 100%;
  background: var(--surface); border: 1px solid var(--line-2); color: var(--ink);
  font-family: var(--sans); font-size: 15px;
  padding: 12px 14px; border-radius: var(--r);
  box-shadow: var(--sh-1);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.apply-field select {
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%238b95a7' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
  cursor: pointer;
}
.apply-field textarea {
  resize: vertical; min-height: 110px; line-height: 1.8;
}
.apply-field input:focus,
.apply-field select:focus,
.apply-field textarea:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(102, 187, 106, .20);
}
.apply-field input::placeholder,
.apply-field textarea::placeholder { color: var(--ink-3); }
.apply-foot { display: flex; align-items: center; gap: 14px; }
.apply-note { max-width: 560px; margin: 18px auto 0; text-align: center; font-size: 13.5px; }

/* ---- 申请页勾选框（10-29 修复）----
   .apply-checks / .apply-check-inline 一直没有样式定义，裸 label/input 撞上
   本文件上方 .apply-field label{display:block}（40-pages.css:163）与
   .apply-field input{width:100%+padding+边框+阴影}（40-pages.css:167）的
   表单规则 → 每个选项独占一行、checkbox 被拉成通栏大框。这里显式接管。
   类名只在 apply.body.html 使用（src/ 全量 grep 过），不涉其他页面。 */
.apply-checks {
  display: flex; flex-wrap: wrap; gap: 10px 22px;
}
.apply-checks .apply-check-inline {
  display: inline-flex; align-items: center; gap: 7px;
  margin-bottom: 0;
  font-size: 14.5px; font-weight: 400; color: var(--ink);
  cursor: pointer;
}
/* 守则确认是长句 + 内嵌链接：用常规文本流让句子自然折行
   （inline-flex 会把「我已阅读」/链接/后半句拆成独立块，窄屏折行很难看）；
   checkbox 用 vertical-align 跟首行文字对齐。 */
.apply-consent .apply-check-inline {
  display: block;
  margin-bottom: 0;
  font-size: 14.5px; font-weight: 400; color: var(--ink);
  cursor: pointer;
}
/* checkbox 恢复原生外观：逐项抵消 .apply-field input 的拉宽/内距/边框/阴影。
   appearance:auto 下 Chromium 走原生绘制，accent-color 染勾选色。 */
.apply-check-inline input[type="checkbox"] {
  appearance: auto;
  width: 16px; height: 16px; flex: none;
  margin: 0; padding: 0;
  border: 0; background: none; box-shadow: none;
  accent-color: var(--brand);
  cursor: pointer;
  transition: none;
}
.apply-consent .apply-check-inline input[type="checkbox"] {
  margin-right: 7px; vertical-align: middle;
}
/* .apply-field input:focus 的 outline:none + 盒阴影环被上面的 reset 抵消了，
   键盘焦点指示在这里补回来 */
.apply-check-inline input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* ---- 个人中心：3D 角色展示 ---- */
.me-skin-grid {
  display: grid; gap: 16px;
  grid-template-columns: minmax(0, 340px) minmax(0, 1fr);
  align-items: start;
}
.me-skin-card { padding: 16px; }
.me-skin-stage {
  background: var(--bg-soft); border-radius: var(--r);
  display: flex; justify-content: center;
  overflow: hidden;
}
.me-skin-stage canvas { display: block; max-width: 100%; }
.me-skin-tip { margin: 10px 0 0; text-align: center; font-size: 13px; }
.me-skin-side { display: grid; gap: 16px; }
@media (max-width: 720px) { .me-skin-grid { grid-template-columns: 1fr; } }

/* ---- 鸣谢 · 神人榜（10-16 夜）---- */
.sec-gap-top { margin-top: 34px; }
.hall-list { list-style: none; margin: 0; padding: 0; }
.hall-item {
  display: flex; flex-direction: column; gap: 4px;
  padding: 16px 0; border-bottom: 1px solid var(--line);
}
.hall-item:last-child { border-bottom: none; }
.hall-item .t { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.hall-medal {
  width: 30px; height: 30px; flex: none;
  display: grid; place-items: center;
  font-size: 19px; line-height: 1;
}
.hall-medal-n {
  font-family: var(--mono); font-size: 13px; font-weight: 700;
  color: var(--ink-2); background: var(--bg-soft);
  border: 1px solid var(--line-2); border-radius: 8px;
}
.hall-name { font-size: 17px; font-weight: 700; color: var(--ink);
  font-family: var(--pixel); letter-spacing: .02em; }
.hall-title { margin-left: 2px; }
.hall-kind { margin-left: 10px; vertical-align: 2px; }
.hall-item .b { color: var(--ink-2); font-size: 14.5px; line-height: 1.85; }
.adm-thanks-form {
  display: grid; gap: 10px;
  grid-template-columns: auto 1fr 1fr;
}
.adm-thanks-form input, .adm-thanks-form select {
  background: var(--surface); border: 1px solid var(--line-2); color: var(--ink);
  font-size: 14px; padding: 11px 13px; border-radius: var(--r);
}
.adm-thanks-form input:focus, .adm-thanks-form select:focus {
  outline: none; border-color: var(--brand);
}
.adm-thanks-form button { grid-column: 1 / -1; justify-self: start; }
@media (max-width: 720px) { .adm-thanks-form { grid-template-columns: 1fr; } }
.adm-thanks-cols { display: grid; gap: 28px; grid-template-columns: 1fr 1fr; }
@media (max-width: 720px) { .adm-thanks-cols { grid-template-columns: 1fr; } }

/* ==========================================================================
   玩家登录页（/login，10-16）
   ========================================================================== */

.login-box {
  max-width: 560px; margin: 0 auto;
  padding: 28px;
}
.login-step-label {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--pixel); font-size: 17px; color: var(--ink);
  margin-bottom: 14px;
}
.login-step-num {
  width: 26px; height: 26px; flex: none;
  display: grid; place-items: center;
  background: var(--brand); color: var(--on-brand);
  font-family: var(--mono); font-size: 13px; font-weight: 700;
  border-radius: 7px;
}
.login-form { display: flex; gap: 10px; flex-wrap: wrap; }
.login-form input {
  flex: 1 1 220px; min-width: 0;
  background: var(--surface); border: 1px solid var(--line-2); color: var(--ink);
  font-family: var(--mono); font-size: 16px;
  padding: 13px 15px; border-radius: var(--r);
  box-shadow: var(--sh-1);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.login-form input:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(102, 187, 106, .20);
}
.login-msg { min-height: 1.5em; margin: 12px 0 0; }
.login-again { margin: 10px 0 0; font-size: 13.5px; color: var(--ink-3); }
.login-again a { color: var(--brand); font-weight: 600; }
.login-ok {
  margin: 0; font-size: 16px; font-weight: 700; color: var(--brand);
  text-align: center; padding: 10px 0;
}
.login-note { max-width: 560px; margin: 18px auto 0; text-align: center; font-size: 13.5px; }

/* ==========================================================================
   个人中心（/me，10-16）
   ========================================================================== */

.me-card { padding: 24px 26px; }
.me-head { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.me-head > div:first-child { flex: 1 1 200px; }
.me-avatar {
  width: 52px; height: 52px; flex: none;
  border-radius: 12px;
  background:
    linear-gradient(#fff, #fff) 10px 10px / 12px 12px no-repeat,
    linear-gradient(#a5d6a7, #a5d6a7) 30px 10px / 12px 12px no-repeat,
    linear-gradient(#a5d6a7, #a5d6a7) 10px 30px / 12px 12px no-repeat,
    linear-gradient(#fff, #fff) 30px 30px / 12px 12px no-repeat,
    var(--brand);
  image-rendering: pixelated;
}
.me-name {
  font-family: var(--pixel); font-size: 24px; color: var(--ink);
  letter-spacing: .02em; line-height: 1.2;
}
.me-sub { margin-top: 6px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.me-logout { margin-left: auto; }
.me-cta-btn { margin-left: auto; }
.me-rows {
  margin: 20px 0 0; padding: 0;
  border-top: 1px solid var(--line);
}
.me-row {
  display: grid; grid-template-columns: 140px 1fr; gap: 12px;
  padding: 12px 0; border-bottom: 1px solid var(--line);
}
.me-row:last-child { border-bottom: none; }
.me-row dt { color: var(--ink-3); font-size: 13.5px; }
.me-row dd { margin: 0; color: var(--ink); font-size: 14.5px; }
.me-more { margin: 14px 0 0; font-size: 13px; }
.sec-tight { margin-top: 6px; }
@media (max-width: 560px) {
  .me-row { grid-template-columns: 1fr; gap: 2px; }
  .me-logout, .me-cta-btn { margin-left: 0; }
}

/* 个人中心数据卡（10-17） */
.me-stat {
  margin: 6px 0 2px;
  font-family: var(--pixel); font-size: 26px; color: var(--brand);
}
.me-stat-sub { margin: 0; font-size: 12.5px; }

/* 称号徽章（MC 原色渲染，10-18） */
.me-title {
  display: inline-block;
  margin: 0 6px 6px 0; padding: 5px 10px;
  background: var(--surface-2);
  border: 1px solid var(--line); border-radius: 8px;
  font-family: var(--pixel); font-size: 14px;
}

/* /me 进服通知 & 小号绑定输入框（玩家页，无 Tabler——站点自己的样式） */
.jm-input {
  width: 100%;
  background: var(--surface); border: 1px solid var(--line-2); color: var(--ink);
  font-family: var(--sans); font-size: 15px;
  padding: 12px 14px; border-radius: var(--r);
  box-shadow: var(--sh-1);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.jm-input:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(102, 187, 106, .20);
}
.jm-input::placeholder { color: var(--ink-3); }

/* ---- 色块选择器（进服通知自定义，10-25）---- */
.jm-color-panel {
  background: var(--surface-2); border: 1px solid var(--line);
  border-radius: var(--r); padding: 12px 14px; margin-bottom: 12px;
}
.jm-color-title {
  font-size: 13px; font-weight: 600; color: var(--ink-2); margin-bottom: 8px;
}
.jm-swatches { display: flex; gap: 8px; flex-wrap: wrap; }
.jm-swatch {
  width: 34px; height: 34px; border-radius: 9px;
  border: 2px solid transparent; cursor: pointer;
  box-shadow: var(--sh-1), inset 0 0 0 1px rgba(0,0,0,.08);
  transition: transform .12s ease, border-color .12s ease;
}
.jm-swatch:hover { transform: scale(1.12); }
.jm-swatch.picked {
  border-color: var(--ink);
  box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--ink);
}
.jm-picked { margin-top: 10px; display: flex; align-items: center; gap: 6px; }
.jm-picked-dot {
  width: 22px; height: 22px; border-radius: 6px; display: inline-block;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.12);
}


/* ==================== 50-home.css ==================== */

/* ==========================================================================
   首页层（2026-10-15 新增）：像素字体 / Hero 双栏 / 像素小景 / 信任条 / 进服四步
   ──────────────────────────────────────────────────────────────────────────
   决策记录：
   · 像素字体 = Fusion Pixel 12px Proportional（缝合像素字体，OFL-1.1 开源）。
     自托管子集内嵌（由 web/make_font.py 按 src/ 文案收集字符集生成），
     仍然零外部请求 —— 不违反「不引 web font / CDN」的纪律，字体文件在
     static/fonts/ 本地。源字体与许可证留底在 web/fonts-src/。
     🔴 文案改了字出了新字形 → 重跑 python web/make_font.py 再 build；
        忘了跑也不算坏：缺失字回退系统字体，页面不会开天窗。
   · 像素字体只上「固定文案」（标题 / 卡片题 / 步骤徽标 / 品牌字），
     API 动态内容（公告正文 / 诊断结果 / 数字）一律系统字体 —— 一来动态字符
     未必在子集里，二来长文本用像素字可读性差。
   · .hero-art 的浮空岛是 Meowa 像素管线生成的 PNG（_meowa_island/ 有原稿与
     去底脚本），不是 UI 元素，不跟随主题 token。深色主题回切时保持原样，
     属于已知取舍。
   ========================================================================== */

@font-face {
  font-family: "Sight Pixel";
  src: url("/static/fonts/sight-pixel-12-sc.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ---------------------------------------------------------------- 字体应用 */
.wordmark,
.hero .tag,
h2.sec,
.page-head h1,
.card h3,
.step h3,
.step .n {
  font-family: var(--pixel);
  font-weight: 400;                       /* 像素字体自带头型，别再加粗 */
}

h2.sec { letter-spacing: .02em; }

/* ---------------------------------------------------------------- Hero 双栏 */
.hero { padding: 72px 0 60px; }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: 44px;
  align-items: center;
}

.wordmark {
  margin: 0 0 14px;
  font-size: clamp(48px, 8vw, 72px);      /* 72 = 12px 网格的 6 倍，像素最脆 */
  line-height: 1;
  color: var(--ink);
}

.hero .tag {
  margin: 0 0 14px;
  font-size: clamp(18px, 2.6vw, 24px);    /* 24 = 2 倍网格 */
  color: var(--brand);
}

.hero .sub {
  margin: 0 0 24px; max-width: 560px;
  font-size: 15.5px; line-height: 1.95; color: var(--ink-2);
}

.hero-meta { margin-bottom: 18px; }

/* 在线胶囊做成按钮（点开玩家名单） */
.live-btn {
  border: 1px solid var(--line); cursor: pointer;
  font-family: inherit;
  transition: border-color var(--dur-hover, 180ms) ease, box-shadow var(--dur-hover, 180ms) ease;
}
.live-btn:hover { border-color: var(--brand); box-shadow: var(--sh-2); }

/* 在线玩家名单面板：胶囊下方的浮层卡 */
.online-panel {
  margin: -8px 0 18px;
  max-width: 300px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: var(--sh-2);
  padding: 12px 16px;
}
.online-panel-head {
  display: flex; justify-content: space-between; align-items: baseline;
  font-family: var(--pixel); font-size: 15px; color: var(--ink);
  padding-bottom: 8px; border-bottom: 1px solid var(--line);
}
.online-names {
  list-style: none; margin: 8px 0 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: 4px 14px;
  max-height: 180px; overflow-y: auto;
}
.online-names li { font-family: var(--mono); font-size: 13.5px; color: var(--ink-2); }

/* 服务器地址条 */
.addr {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin-bottom: 24px;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px dashed var(--line-2);
  border-radius: var(--r);
  max-width: fit-content;
}
.addr-label { font-size: 13px; color: var(--ink-3); }
.addr-host {
  font-family: var(--mono); font-size: 15px; font-weight: 700; color: var(--ink);
}
.addr .copy { margin-left: 0; }

/* 像素小景：Meowa 生成的浮空岛（_meowa_island/ 有原稿）。
   图是 2x 最近邻放大过的，这里 display 尺寸落在整数倍附近 + pixelated，像素不糊。 */
.hero-art { display: flex; justify-content: center; }
.hero-art img {
  width: auto; height: auto;
  max-width: 100%;
  max-height: 460px;
  image-rendering: pixelated;
  filter: drop-shadow(0 18px 22px rgba(16, 24, 40, .10));
  animation: sight-bob 3.4s ease-in-out infinite;
}
@keyframes sight-bob {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-6px); }
}

/* ---------------------------------------------------------------- 信任条 */
.trust { padding: 0; }
.trust .wrap > .trust-list {
  list-style: none; margin: 0; padding: 14px 0;
  display: flex; flex-wrap: wrap; gap: 8px 28px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.trust-list li {
  position: relative;
  padding-left: 16px;
  font-size: 13.5px; color: var(--ink-2);
}
/* 像素方块符号，代替圆点 */
.trust-list li::before {
  content: ""; position: absolute; left: 0; top: 50%;
  width: 7px; height: 7px; transform: translateY(-50%);
  background: var(--brand);
  box-shadow: 2px 2px 0 var(--brand-t);
}
/* 信任条紧贴 hero，后面一块不再画线（trust 自己带了上下边） */
.trust + section { border-top: none; }

/* ---------------------------------------------------------------- 特色卡 */
.card h3 { font-size: 18px; letter-spacing: .02em; }
.card h3 .ic { border-radius: 9px; }
.card h3 .ic svg { width: 20px; height: 20px; display: block; }

/* ---------------------------------------------------------------- 进服四步 */
.steps.four {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}
.step .n { font-size: 12px; letter-spacing: .1em; }
.step h3 { font-size: 18px; letter-spacing: .02em; }
.steps-more {
  margin: 20px 0 0;
  font-size: 14px; color: var(--ink-2); line-height: 1.9;
}
.steps-more a { color: var(--brand); font-weight: 600; }

/* ---------------------------------------------------------------- 断点 */
@media (max-width: 920px) {
  .hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .hero-art { order: 2; }
  .hero-art img { max-height: 340px; }
}

@media (max-width: 560px) {
  .hero { padding: 44px 0 44px; }
  .hero .sub { font-size: 15px; }
  .addr { max-width: 100%; }
  .trust .wrap > .trust-list { gap: 6px 18px; padding: 12px 0; }
  .trust-list li { font-size: 13px; }
  .hero-art img { max-height: 280px; }
}

/* 尊重系统减动效偏好：小景停浮 */
@media (prefers-reduced-motion: reduce) {
  .hero-art img { animation: none; }
}

/* ---------------------------------------------------------------- 动效包（10-16 夜）
   全部零依赖、纯 CSS；JS 侧负责生成星星节点和 reveal 触发。 */

/* 像素星空：JS 往 #pixel-stars 里撒方块星。基线可见（0.5），闪烁到全亮。 */
.hero { position: relative; overflow: hidden; }
#pixel-stars {
  position: absolute; inset: -20px; pointer-events: none;
  transition: transform .2s linear;
}
.px-star {
  position: absolute; width: 4px; height: 4px;
  background: #9ccc65; opacity: .5;
  animation: px-twinkle 5s ease-in-out infinite;
}
.px-star.big { width: 6px; height: 6px; background: #66bb6a; }
.px-star:nth-child(3n) { background: #ffe9a8; }     /* 三分之一给暖白，夜空感 */
@keyframes px-twinkle {
  0%, 100% { opacity: .35; transform: translateY(0); }
  50%      { opacity: 1;   transform: translateY(-10px); }
}

/* 像素云 ×2：整块白云剪影横移，一层近快一层远慢，穿屏循环（常驻可见的「移动的画面」） */
.px-cloud {
  position: absolute; pointer-events: none; opacity: .9;
  width: 84px; height: 22px;
  background:
    linear-gradient(#fff,#fff) 12px 0 / 44px 10px no-repeat,
    linear-gradient(#fff,#fff) 0 10px / 84px 12px no-repeat;
  filter: drop-shadow(0 3px 0 rgba(16,24,40,.05));
}
.px-cloud.c1 { top: 12%; left: -90px; animation: cloud-drift 52s linear infinite; }
.px-cloud.c2 { top: 58%; left: -90px; transform: scale(.7);
  animation: cloud-drift 74s linear infinite; animation-delay: -30s; }
@keyframes cloud-drift {
  from { translate: 0 0; }
  to   { translate: calc(100vw + 180px) 0; }
}

/* 萤火虫 ×3：发光小方块绕岛游走（两层 keyframes 合成路径），夜里一样的呼吸灯 */
.firefly {
  position: absolute; width: 7px; height: 7px; pointer-events: none;
  background: #ffd54f; border-radius: 2px;
  box-shadow: 0 0 10px 3px rgba(255, 213, 79, .55);
  animation:
    firefly-glow 2.6s ease-in-out infinite,
    firefly-path-a 13s var(--ease-in-out) infinite;
}
.firefly.f2 { animation:
    firefly-glow 3.1s ease-in-out .7s infinite,
    firefly-path-b 17s var(--ease-in-out) infinite; }
.firefly.f3 { width: 5px; height: 5px; animation:
    firefly-glow 2.2s ease-in-out 1.3s infinite,
    firefly-path-c 21s var(--ease-in-out) infinite; }
@keyframes firefly-glow {
  0%, 100% { opacity: .25; }
  50%      { opacity: 1; }
}
@keyframes firefly-path-a {
  0%   { left: 14%; top: 58%; }
  30%  { left: 26%; top: 44%; }
  60%  { left: 18%; top: 34%; }
  100% { left: 14%; top: 58%; }
}
@keyframes firefly-path-b {
  0%   { left: 78%; top: 30%; }
  35%  { left: 88%; top: 46%; }
  70%  { left: 72%; top: 60%; }
  100% { left: 78%; top: 30%; }
}
@keyframes firefly-path-c {
  0%   { left: 46%; top: 20%; }
  40%  { left: 58%; top: 28%; }
  75%  { left: 40%; top: 36%; }
  100% { left: 46%; top: 20%; }
}

/* 减动效：装饰元素静止但保持可见（不消失），拖尾/视差由 JS 侧关闭 */
@media (prefers-reduced-motion: reduce) {
  .px-star, .px-cloud, .firefly { animation: none; }
  .px-star { opacity: .7; }
  .firefly { opacity: .8; }
}

/* 打字机：正在打字时尾巴上挂一块闪烁方块光标 */
.hero .tag.typing::after {
  content: ""; display: inline-block;
  width: .55em; height: 1em;
  background: var(--brand-l);
  margin-left: 3px; vertical-align: -0.12em;
  animation: tag-blink .8s steps(1) infinite;
}
@keyframes tag-blink { 50% { opacity: 0; } }

/* 滚动入场：编排式 stagger —— 同容器内元素按序号递进 80ms（taste-skill：入场的阅读顺序） */
.reveal { opacity: 0; transform: translateY(18px); }
.reveal-in {
  opacity: 1; transform: none;
  transition:
    opacity var(--dur-reveal) var(--ease-out),
    transform var(--dur-reveal) var(--ease-out);
  transition-delay: calc(var(--stagger-i, 0) * 80ms);
}

/* 顶栏滚动阴影 */
.topbar { transition: box-shadow .25s ease; }
.topbar.scrolled { box-shadow: 0 6px 18px rgba(16, 24, 40, .08); }

/* 浮空岛视差：JS 直接 transform 在 .hero-art 外层（bob 动画仍在 img 上，互不打架） */
/* ---------------------------------------------------------------- 滚动交互动效（10-17）
   ①hero 分层视差滚出（JS 写 --scroll-t，只动 transform）
   ②浮空岛随滚动微倾 ③区块标题下划线随入场延展 */

.hero-copy { will-change: transform; }
.hero-art { transition: transform .15s linear; will-change: transform; }

/* 区块标题下划线：进入视口时从左延展（scaleX 0→1） */
h2.sec::before { transform: scaleX(0); transform-origin: left; }
h2.sec.in::before {
  transform: scaleX(1);
  transition: transform .7s var(--ease-out) .1s;
}
/* 减动效：下划线直接显示 */
@media (prefers-reduced-motion: reduce) {
  h2.sec::before { transform: none; transition: none; }
  .hero-copy, .hero-art { transition: none; }
}

/* ---------------------------------------------------------------- Motion.Lab 配方（10-17）
   滚动进度条 / 3D 倾斜 / 按钮波纹 / 点击方块爆开 —— 配方来自 motion-lab skill，调参适配。 */

/* scroll-progress：顶部滚动进度条 */
#scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px;
  z-index: 60; pointer-events: none;
}
#scroll-progress .bar {
  height: 100%; width: 0;
  background: linear-gradient(90deg, var(--brand), var(--brand-l));
}

/* three-d-tilt：浮空岛 3D 倾斜层（hero-art=视差在父级，img=bob 在子级，三层不争用） */
.tilt-layer {
  transform-style: preserve-3d;
  transition: transform .2s ease-out;
  will-change: transform;
}

/* ripple-click：按钮点击波纹（JS 委托注入 .ripple） */
.btn { position: relative; overflow: hidden; }
.btn .ripple {
  position: absolute; border-radius: 50%;
  background: rgba(255, 255, 255, .45);
  transform: translate(-50%, -50%) scale(0);
  animation: btn-ripple .55s ease-out forwards;
  pointer-events: none;
}
@keyframes btn-ripple { to { transform: translate(-50%, -50%) scale(10); opacity: 0; } }

/* click-burst 像素变体：点击处爆开品牌绿方块 */
.px-burst-bit {
  position: fixed; width: 8px; height: 8px; z-index: 95;
  background: var(--brand); pointer-events: none;
  transition: transform .6s cubic-bezier(0.2, 0.8, 0.2, 1), opacity .6s;
}

/* ---------------------------------------------------------------- 互动动效（10-16 夜） */

/* 像素鼠标拖尾：#px-trail 是固定层，方块池复用 */
#px-trail { position: fixed; inset: 0; pointer-events: none; z-index: 90; }
.px-trail-bit {
  position: absolute; width: 6px; height: 6px;
  background: var(--brand-l); opacity: 0;
}
.px-trail-bit.go { animation: px-trail-fade .7s steps(6) forwards; }
@keyframes px-trail-fade {
  0%   { opacity: .85; transform: scale(1); }
  100% { opacity: 0;   transform: scale(.4) translateY(10px); }
}

/* 卡片 hover 光泽扫过 */
.card { position: relative; overflow: hidden; }
.card::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 30%,
              rgba(102, 187, 106, .10) 48%, transparent 62%);
  transform: translateX(-120%);
  pointer-events: none;
}
.card:hover::after { transform: translateX(120%); transition: transform .7s ease; }

/* 回顶按钮 */
#back-top {
  position: fixed; right: 22px; bottom: 26px; z-index: 80;
  width: 46px; height: 46px;
  border: 1px solid var(--line-2); border-radius: 12px;
  background: var(--surface); color: var(--brand);
  font-size: 15px; cursor: pointer;
  box-shadow: var(--sh-2);
  opacity: 0; pointer-events: none; transform: translateY(12px);
  transition: opacity .25s ease, transform .25s ease, border-color .15s ease;
}
#back-top.show { opacity: 1; pointer-events: auto; transform: none; }
#back-top:hover { border-color: var(--brand); }

@media (prefers-reduced-motion: reduce) {
  #px-trail { display: none; }
  #back-top { transition: none; }
}
