/* ==================================================
   泓斐全站共享样式 v1.0（2026-10-15）
   Nginx sub_filter 注入，覆盖 platform / saas / console / group
   ================================================== */

/* ---------- 全站按钮胶囊化 ---------- */
button:not(.hf-no-pill):not(.ant-btn),
.hf-pill,
.hf-btn {
  border-radius: 999px !important;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  cursor: pointer;
  font-family: inherit;
}

button:not(.hf-no-pill):not(.ant-btn)::before,
.hf-pill::before,
.hf-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, #00C2FF 0%, #2DA4FF 50%, #003FCC 100%);
  opacity: 0;
  transform: scaleX(0);
  transform-origin: left center;
  transition: opacity 0.35s ease, transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: -1;
  pointer-events: none;
}

button:not(.hf-no-pill):not(.ant-btn):hover::before,
.hf-pill:hover::before,
.hf-btn:hover::before {
  opacity: 0.2;
  transform: scaleX(1);
}

button:not(.hf-no-pill):not(.ant-btn):hover,
.hf-pill:hover,
.hf-btn:hover {
  box-shadow: 0 4px 16px rgba(0, 194, 255, 0.28);
  transform: translateY(-1px);
}

button:not(.hf-no-pill):not(.ant-btn):active,
.hf-pill:active {
  transform: translateY(0);
  transition-duration: 0.08s;
}

/* 深色模式略亮 */
[data-theme="dark"] button:not(.hf-no-pill):not(.ant-btn):hover::before,
[data-theme="dark"] .hf-pill:hover::before {
  opacity: 0.25;
}

/* 明确跳过 */
.hf-no-pill,
.hf-no-pill::before {
  border-radius: inherit !important;
  overflow: visible;
}
.hf-no-pill::before { display: none; }

/* antd 按钮单独处理（保持品牌色，只加胶囊圆角） */
.ant-btn:not(.ant-btn-circle):not(.ant-btn-round) {
  border-radius: 999px !important;
}
.ant-btn-primary {
  box-shadow: 0 2px 10px rgba(0, 194, 255, 0.25);
}
.ant-btn-primary:hover {
  box-shadow: 0 4px 18px rgba(0, 194, 255, 0.4) !important;
}

/* ---------- emoji 隐藏（可选，通过 body.hf-no-emoji 控制） ---------- */
body.hf-no-emoji .hf-emoji,
body.hf-no-emoji .nav-emoji {
  display: none !important;
}
