/* 星群 · 全站控件层（2026-10-22）
 * 所有主要按钮统一为可点击的玻璃表面，并补上按压反馈。
 * 真折射由 space/liquid-glass.js 在 Chromium 上叠加；这里保证 Safari/Firefox
 * 至少保留半透明、边缘高光和 active 手感。
 */

/* 按钮统一收小圆角，避免全站都是胶囊形 */
.btn,.pill,.mini,.c-link,.ch-submit,.ch-login,.feedtab,.chip,.dlgo{border-radius:10px}
.hero-btn{border-radius:8px}
.upload-thumb button{border-radius:6px}
.creator-links a{border-radius:8px}

.btn,.pill,.mini,.c-link,.hero-btn,.theme-toggle,.ch-submit,.ch-login,
.feedtab,.chip,.dlgo,.upload-thumb button,.creator-links a,.ch-my-login{
  -webkit-tap-highlight-color:transparent;
  touch-action:manipulation;
  transition:transform .14s var(--ease,ease),
    background-color .18s var(--ease,ease),
    border-color .18s var(--ease,ease),
    box-shadow .18s var(--ease,ease);
}
.btn:active:not(:disabled),
.pill:active:not(:disabled),
.mini:active:not(:disabled),
.c-link:active:not(:disabled),
.hero-btn:active:not(:disabled),
.theme-toggle:active:not(:disabled),
.ch-submit:active:not(:disabled),
.ch-login:active:not(:disabled),
.feedtab:active:not(:disabled),
.chip:active:not(:disabled),
.dlgo:active:not(:disabled),
.upload-thumb button:active:not(:disabled),
.creator-links a:active,
.ch-my-login:active,
.wlink:active,.qbtn:active,.anchorbar a:active,.adm-tab:active,.adm-btn:active,
.ch-chip:active,.ch-invite a:active,.skinfab:active,.reload:active{
  transform:translateY(1px) scale(.985);
  filter:brightness(.97);
}
.nav .links a:active,.nav .brand:active,.ch-top-link:active{
  transform:translateY(1px);opacity:.72;
}
button:not(:disabled){
  -webkit-tap-highlight-color:transparent;
  touch-action:manipulation;
}
button:not(:disabled):active{
  transform:translateY(1px) scale(.985);
  filter:brightness(.97);
}

/* 真折射层的通用边缘高光（索引页的 glass.css 也会给同一元素叠一层） */
.lg-refract{
  box-shadow:inset 0 1px 0 rgba(255,255,255,.32),
    inset 0 -1px 0 rgba(0,0,0,.2),
    inset 1px 0 0 rgba(255,255,255,.08),
    inset -1px 0 0 rgba(255,255,255,.08),
    0 8px 24px rgba(0,0,0,.12);
}

@supports ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))){
  /* 非首页的固定导航也做成轻玻璃；首页有自己的悬浮圆角版本。 */
  body:not(.home) .nav{
    background:color-mix(in srgb,var(--bg,#fff) 78%,transparent);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.65),0 10px 30px rgba(0,0,0,.06);
    -webkit-backdrop-filter:blur(14px) saturate(1.18);
    backdrop-filter:blur(14px) saturate(1.18);
  }
  html[data-theme="dark"] body:not(.home) .nav{
    background:color-mix(in srgb,var(--bg,#09090B) 76%,transparent);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.08),0 10px 30px rgba(0,0,0,.2);
  }
  body:not(.home) .theme-toggle{
    background:color-mix(in srgb,var(--panel,#fff) 72%,transparent);
    border-color:color-mix(in srgb,var(--line2,#D6D6D1) 78%,transparent);
    -webkit-backdrop-filter:blur(8px) saturate(1.2);
    backdrop-filter:blur(8px) saturate(1.2);
  }
  body:not(.home) .pill:not(.solid){
    background:color-mix(in srgb,var(--panel,#fff) 72%,transparent);
    border-color:color-mix(in srgb,var(--line2,#D6D6D1) 78%,transparent);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.55);
    -webkit-backdrop-filter:blur(8px) saturate(1.18);
    backdrop-filter:blur(8px) saturate(1.18);
  }
  body:not(.home) .pill.solid{
    background:color-mix(in srgb,var(--accent,#111113) 86%,transparent);
    border-color:color-mix(in srgb,var(--accent,#111113) 62%,transparent);
    color:var(--on-accent,#fff)!important;
    box-shadow:inset 0 1px 0 rgba(255,255,255,.26),
      0 6px 18px rgba(0,0,0,.12);
  }
  .btn--primary{
    background:color-mix(in srgb,var(--accent,#111113) 86%,transparent);
    color:var(--on-accent,#fff);
    border-color:color-mix(in srgb,var(--accent,#111113) 56%,transparent);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.28),
      inset 0 -1px 0 rgba(0,0,0,.22),
      0 8px 22px rgba(0,0,0,.12);
    -webkit-backdrop-filter:blur(10px) saturate(1.25);
    backdrop-filter:blur(10px) saturate(1.25);
  }
  .btn--ghost,.c-link--src,.creator-links a{
    background:color-mix(in srgb,var(--panel,#fff) 72%,transparent);
    border-color:color-mix(in srgb,var(--line2,#D6D6D1) 82%,transparent);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.6),
      0 8px 22px rgba(0,0,0,.07);
    -webkit-backdrop-filter:blur(10px) saturate(1.18);
    backdrop-filter:blur(10px) saturate(1.18);
  }
  .c-link--go{
    background:color-mix(in srgb,var(--accent,#8A5A2B) 86%,transparent);
    border-color:color-mix(in srgb,var(--accent,#8A5A2B) 64%,transparent);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.26),
      0 8px 22px rgba(0,0,0,.10);
    -webkit-backdrop-filter:blur(9px) saturate(1.2);
    backdrop-filter:blur(9px) saturate(1.2);
  }
  .feedtab,.chip{
    background:color-mix(in srgb,var(--panel,#fff) 68%,transparent);
    box-shadow:inset 0 1px 0 rgba(255,255,255,.55);
    -webkit-backdrop-filter:blur(8px) saturate(1.12);
    backdrop-filter:blur(8px) saturate(1.12);
  }
  .feedtab.is-on,.chip.is-on{
    box-shadow:inset 0 1px 0 rgba(255,255,255,.4),
      0 4px 14px rgba(0,0,0,.10);
  }
}

@media (prefers-reduced-motion:reduce){
  .btn,.pill,.mini,.c-link,.hero-btn,.theme-toggle,.ch-submit,.ch-login,
  .feedtab,.chip,.dlgo,.upload-thumb button{transition:none}
  .btn:active:not(:disabled),.pill:active:not(:disabled),
  .mini:active:not(:disabled),.c-link:active:not(:disabled),
  .hero-btn:active:not(:disabled),.theme-toggle:active:not(:disabled),
  .ch-submit:active:not(:disabled),.ch-login:active:not(:disabled),
  .feedtab:active:not(:disabled),.chip:active:not(:disabled),
  .dlgo:active:not(:disabled),.upload-thumb button:active:not(:disabled),
  button:not(:disabled):active{
    transform:none;filter:none;
  }
}
