/**
 * 首页样式规范系统 (Modern Crisp Light & Cohesive Design System)
 * 采用系统 UI 中文字体栈 + 系统等宽字体
 * 遵循统一的 Design Tokens、网格节奏、微质感光影与协调色彩系统
 * 绿色玻璃拟态 (Glassmorphism) 首页视觉
 */

/* ==========================================================================
   1. Design Tokens 设计令牌体系 (全局调色板、间距与物理微阴影)
   ========================================================================== */
:root {
  /* 背景与表面层级 (绿色玻璃拟态) */
  --hx-bg: #d8f0e6;
  --hx-content-top: #ecfdf5;
  --hx-content-mid: #d1fae5;
  --hx-content-bottom: rgba(216, 240, 230, 0);
  --hx-hub-surface: linear-gradient(152deg, rgba(255, 255, 255, 0.72) 0%, rgba(236, 253, 245, 0.48) 48%, rgba(167, 243, 208, 0.28) 100%);
  --hx-bg-subtle: rgba(236, 253, 245, 0.45);
  --hx-bg-muted: rgba(110, 231, 183, 0.18);
  --hx-surface: rgba(255, 255, 255, 0.42);
  --hx-surface-elevated: rgba(255, 255, 255, 0.58);
  --hx-surface-subtle: rgba(236, 253, 245, 0.35);
  --hx-surface-hover: rgba(255, 255, 255, 0.62);
  --hx-glass: rgba(255, 255, 255, 0.38);
  --hx-glass-tint: rgba(167, 243, 208, 0.22);
  --hx-glass-border: rgba(255, 255, 255, 0.72);
  --hx-glass-edge: rgba(5, 150, 105, 0.14);

  /* 边框体系 */
  --hx-border: rgba(6, 78, 59, 0.08);
  --hx-border-strong: rgba(6, 78, 59, 0.12);
  --hx-border-hover: rgba(5, 150, 105, 0.28);
  --hx-border-focus: rgba(5, 150, 105, 0.45);

  /* 字体色彩层级 (Slate 灰阶体系) */
  --hx-text-1: #0f172a;        /* 主标题、强调文字、高对比文本 */
  --hx-text-2: #334155;        /* 正文、表单标签、主要交互文字 */
  --hx-text-3: #64748b;        /* 辅助说明、副标题、次要文字 */
  --hx-text-muted: #94a3b8;    /* 占位符、弱化提示、禁用状态 */

  /* 主品牌色 (翡翠绿) */
  --hx-brand: #059669;
  --hx-brand-hover: #047857;
  --hx-brand-active: #065f46;
  --hx-brand-subtle: #ecfdf5;
  --hx-brand-border: #a7f3d0;
  --hx-brand-glow: rgba(5, 150, 105, 0.16);

  /* 辅助强调色 (青绿) */
  --hx-accent: #14b8a6;
  --hx-accent-subtle: #f0fdfa;
  --hx-accent-border: #99f6e4;

  /* 状态指示色 (克制收敛、微量点缀) */
  --hx-success: #10b981;
  --hx-success-subtle: #f0fdf4;
  --hx-success-border: #bbf7d0;
  --hx-success-text: #166534;

  --hx-danger: #ef4444;
  --hx-danger-subtle: #fef2f2;
  --hx-danger-border: #fecaca;
  --hx-danger-text: #991b1b;

  --hx-warning: #f59e0b;
  --hx-warning-subtle: #fffbeb;
  --hx-warning-border: #fde68a;

  /* 几何半径系统 */
  --hx-radius-xs: 5px;
  --hx-radius-sm: 8px;
  --hx-radius-md: 10px;
  --hx-radius-lg: 14px;
  --hx-radius-xl: 18px;
  --hx-radius-full: 9999px;

  /* 多层漫射物理微阴影 */
  --hx-shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.03);
  --hx-shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.04), 0 1px 2px rgba(15, 23, 42, 0.02);
  --hx-shadow-md: 0 8px 32px -8px rgba(5, 150, 105, 0.14);
  --hx-shadow-lg: 0 16px 48px -12px rgba(5, 150, 105, 0.18);
  --hx-shadow-float: 0 24px 64px -16px rgba(15, 23, 42, 0.18);

  /* 字体系统 */
  --hx-font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --hx-font-display: "Alipuhui", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", ui-sans-serif, system-ui, sans-serif;
  --hx-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* 顶栏与主内容区统一最大宽度 */
  --hx-layout-max: 860px;
  --hx-layout-gutter: 16px;
}

/* ==========================================================================
   2. 全局重置与基础布局
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
  max-width: 100%;
  overflow-x: clip;
}

body.hx {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--hx-font);
  font-size: 13px;
  line-height: 1.5;
  color: var(--hx-text-2);
  background-color: var(--hx-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  position: relative;
  max-width: 100%;
  overflow-x: clip;
}

body.hx button,
body.hx input,
body.hx select,
body.hx textarea {
  font: inherit;
  color: inherit;
}

body.hx button {
  cursor: pointer;
  border: none;
  background: none;
}

body.hx a {
  color: inherit;
  text-decoration: none;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hx-wrap {
  width: 100%;
  max-width: var(--hx-layout-max);
  margin: 0 auto;
  padding: 0 var(--hx-layout-gutter);
  position: relative;
  z-index: 2;
  min-width: 0;
  box-sizing: border-box;
}

.hx-main {
  flex: 1 0 auto;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: clip;
}

/* 上半区内容渐变幕布（至「全球骨干」之前） */
.hx-content-zone {
  position: relative;
  isolation: isolate;
  padding: 104px 0 0;
  margin-bottom: 0;
  width: 100%;
  max-width: 100%;
  overflow-x: clip;
}

.hx-content-zone__gradient {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(
      180deg,
      rgba(243, 251, 247, 0.55) 0%,
      rgba(232, 246, 239, 0.28) 42%,
      rgba(214, 238, 228, 0.12) 72%,
      transparent 100%
    );
}

.hx-content-zone__gradient::after {
  display: none;
}

.hx-content-zone__glow {
  position: absolute;
  width: min(520px, 70vw);
  height: min(520px, 70vw);
  border-radius: 50%;
  filter: blur(64px);
  opacity: 0.55;
  pointer-events: none;
  z-index: 0;
}

.hx-content-zone__glow--tl {
  top: -12%;
  left: -8%;
  background: radial-gradient(circle, rgba(52, 211, 153, 0.35) 0%, transparent 68%);
}

.hx-content-zone__glow--br {
  bottom: 8%;
  right: -10%;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.28) 0%, transparent 70%);
}

.hx-content-zone .hx-wrap {
  position: relative;
  z-index: 1;
}

/* 全球骨干区：全宽舞台，主栏之上另设更宽上限 */
.cf-earth-band {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: none;
  margin: 0 auto;
  padding: clamp(36px, 6vw, 52px) clamp(20px, 5vw, 64px) 40px;
  box-sizing: border-box;
}

/* 页面背景：浅色底 + 缓慢柔光（光斑由 canvas 绘制） */
.hx-scene {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background: linear-gradient(180deg, #f4fbf8 0%, #e5f4ec 48%, #d5eee3 100%);
}

.hx-scene__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hx-scene__vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 90% 70% at 50% 18%, transparent 46%, rgba(213, 238, 227, 0.55) 100%);
}

/* ==========================================================================
   2. 顶栏 Navigation（悬浮胶囊）
   ========================================================================== */
.hx-nav {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: min(var(--hx-layout-max), calc(100% - var(--hx-layout-gutter) * 2));
  z-index: 200;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(18px) saturate(1.55);
  -webkit-backdrop-filter: blur(18px) saturate(1.55);
  border: 1px solid rgba(255, 255, 255, 0.82);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.92) inset,
    0 14px 40px -18px rgba(6, 78, 59, 0.38);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}

.hx-nav.is-scrolled {
  background: rgba(255, 255, 255, 0.82);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 18px 48px -16px rgba(6, 78, 59, 0.46);
}

.hx-nav > .hx-wrap {
  max-width: none;
  width: 100%;
  padding: 0 8px 0 16px;
}

.hx-nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 48px;
  gap: 16px;
}

.hx-brand {
  display: inline-flex;
  align-items: center;
  color: var(--hx-text-1);
  transition: opacity 0.16s ease, transform 0.16s ease;
  flex-shrink: 0;
  line-height: 0;
}

.hx-brand:hover {
  opacity: 0.85;
  transform: translateY(-0.5px);
}

.hx-brand__img {
  display: block;
  height: 20px;
  max-height: 20px;
  max-width: 80px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.hx-brand__mark {
  width: 22px;
  height: 22px;
  border-radius: var(--hx-radius-xs);
  background: linear-gradient(135deg, var(--hx-brand), #10b981);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(5, 150, 105, 0.25);
  flex-shrink: 0;
}

.hx-nav__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hx-nav-icon-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--hx-radius-sm);
  background: var(--hx-glass);
  border: 1px solid var(--hx-glass-border);
  color: var(--hx-text-2);
  box-shadow: none;
  cursor: pointer;
  user-select: none;
  transition: all 0.16s cubic-bezier(0.16, 1, 0.3, 1);
}

.hx-nav-icon-btn:hover {
  color: var(--hx-brand);
  background: #ffffff;
  border-color: var(--hx-border-hover);
  box-shadow: var(--hx-shadow-sm);
  transform: translateY(-1px);
}

.hx-nav-icon-btn:active {
  transform: scale(0.96);
}

.hx-nav-icon-btn--login .hx-nav-icon-btn__login-svg {
  transition: transform 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.hx-nav-icon-btn--login:hover .hx-nav-icon-btn__login-svg {
  transform: translateX(1.5px);
  color: var(--hx-brand);
}

.hx-nav-icon-btn__indicator {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--hx-success);
  box-shadow: 0 0 0 1.5px #ffffff, 0 0 4px rgba(16, 185, 129, 0.5);
  pointer-events: none;
}

/* ==========================================================================
   2. 通用按钮规范系统 (Unified Tactile Buttons)
   ========================================================================== */
.hx-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 32px;
  padding: 0 14px;
  font-size: 12.5px;
  font-weight: 500;
  line-height: 1.35;
  border-radius: var(--hx-radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: all 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}

.hx-btn:active {
  transform: scale(0.98);
}

/* 主操作按钮 */
.hx-btn--primary {
  color: #ffffff !important;
  background: linear-gradient(135deg, #047857 0%, #059669 48%, #14b8a6 100%) !important;
  border-color: transparent !important;
  box-shadow: 0 8px 22px -10px rgba(5, 150, 105, 0.65);
}

.hx-btn--primary:hover {
  background: linear-gradient(135deg, #065f46 0%, #047857 50%, #0d9488 100%) !important;
  box-shadow: 0 12px 28px -10px rgba(5, 150, 105, 0.75);
  transform: translateY(-1px);
}

/* 品牌动作按钮：品牌科技蓝 */
.hx-btn--brand {
  color: #ffffff !important;
  background: var(--hx-brand) !important;
  border-color: var(--hx-brand) !important;
  box-shadow: 0 1px 3px rgba(5, 150, 105, 0.28);
}

.hx-btn--brand:hover {
  background: var(--hx-brand-hover) !important;
  border-color: var(--hx-brand-hover) !important;
  box-shadow: 0 3px 10px rgba(5, 150, 105, 0.32);
  transform: translateY(-0.5px);
}

/* 次要轮廓/中性按钮 */
.hx-btn--default {
  color: var(--hx-text-1) !important;
  background: var(--hx-glass) !important;
  border-color: var(--hx-glass-border) !important;
  box-shadow: none;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.hx-btn--default:hover {
  background: rgba(255, 255, 255, 0.72) !important;
  border-color: rgba(5, 150, 105, 0.25) !important;
  color: var(--hx-brand) !important;
}

/* 紧凑尺寸按钮 */
.hx-btn--compact {
  min-height: 28px;
  padding: 0 10px;
  font-size: 11.5px;
  border-radius: var(--hx-radius-xs);
}

/* 行内微型工具按钮 (如一键粘贴) */
.hx-tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 26px;
  padding: 0 8px;
  border-radius: var(--hx-radius-xs);
  font-size: 11.5px;
  font-weight: 500;
  color: var(--hx-text-3);
  background: var(--hx-bg-subtle);
  border: 1px solid var(--hx-border);
  transition: all 0.14s ease;
  user-select: none;
}

.hx-tool-btn:hover {
  color: var(--hx-text-1);
  background: #e2e8f0;
  border-color: var(--hx-border-strong);
}

/* ==========================================================================
   分享纸：一张表面，文字切换内容
   ========================================================================== */
.hx-share-hub,
.hx-workspace {
  position: relative;
  margin: 24px auto 48px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.hx-sheet {
  padding: 26px 26px 22px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.92);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 24px 60px -36px rgba(6, 78, 59, 0.4);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
}

/* 区块头：浮在分享纸之外的标题与动态说明 */
.hx-hub-head {
  margin: 0 0 14px;
  padding: 0 4px;
}

.hx-hub-head__title {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 5px;
  font-family: var(--hx-font-display);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--hx-text-1);
}

.hx-hub-head__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border-radius: 9px;
  color: var(--hx-brand);
  background: linear-gradient(150deg, rgba(167, 243, 208, 0.62), rgba(255, 255, 255, 0.9));
  border: 1px solid rgba(5, 150, 105, 0.18);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
}

.hx-hub-head__lead {
  margin: 0;
  min-height: 1.4em;
  padding-left: 35px;
  font-size: 13px;
  color: var(--hx-text-3);
}

/* 内容类型切换器：分享纸左上角的分段控件 */
.hx-modes {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin: 0 0 18px;
  padding: 3px;
  background: rgba(236, 253, 245, 0.72);
  border: 1px solid rgba(6, 78, 59, 0.07);
  border-radius: var(--hx-radius-full);
  box-shadow: inset 0 1px 2px rgba(6, 78, 59, 0.05);
}

.hx-mode {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 0;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 550;
  letter-spacing: -0.01em;
  color: var(--hx-text-3);
  background: transparent;
  border: none;
  border-radius: var(--hx-radius-full);
  cursor: pointer;
  transition: color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.hx-mode svg {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  opacity: 0.7;
}

.hx-mode:hover {
  color: var(--hx-text-1);
  background: rgba(255, 255, 255, 0.6);
}

.hx-mode:focus-visible {
  outline: 2px solid var(--hx-border-focus);
  outline-offset: 1px;
}

.hx-mode.is-active {
  color: var(--hx-brand-active);
  font-weight: 650;
  background: #fff;
  box-shadow:
    0 1px 2px rgba(6, 78, 59, 0.08),
    0 8px 18px -12px rgba(6, 78, 59, 0.5);
}

.hx-mode.is-active svg {
  opacity: 1;
  color: var(--hx-brand);
}

.hx-share-stage,
.hx-workspace-body {
  position: relative;
  padding: 0;
  margin: 0;
  border: none;
  background: transparent;
}

.hx-panel {
  display: none;
}

.hx-panel.is-active {
  display: block;
  animation: hx-sheet-in 0.22s ease;
}

@keyframes hx-sheet-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.hx-sheet .hx-dropzone-box {
  min-height: 188px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px dashed rgba(5, 150, 105, 0.28);
  box-shadow: none;
}

.hx-sheet .hx-upload-stage {
  padding: 0;
}

@media (prefers-reduced-motion: reduce) {
  .hx-panel.is-active {
    animation: none;
  }
}

/* 生成结果条 */
.hx-result-strip,
.hx-result-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 12px;
  margin-bottom: 12px;
  border-radius: 12px;
  background: linear-gradient(120deg, rgba(16, 185, 129, 0.08) 0%, rgba(255, 255, 255, 0.55) 55%);
  border: 1px solid rgba(16, 185, 129, 0.2);
  box-shadow: 0 8px 28px -24px rgba(16, 185, 129, 0.4);
  animation: hx-result-reveal 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.hx-result-strip__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

.hx-result-strip__close {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  padding: 0;
  border: none;
  border-radius: var(--hx-radius-xs);
  color: var(--hx-text-muted);
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: color 0.14s ease, background 0.14s ease;
}

.hx-result-strip__close:hover {
  color: var(--hx-text-1);
  background: rgba(255, 255, 255, 0.65);
}

.hx-result-strip__close:active {
  transform: scale(0.96);
}

@keyframes hx-result-reveal {
  from { opacity: 0; transform: scale(0.99); }
  to { opacity: 1; transform: scale(1); }
}

.hx-result-strip__badge,
.hx-result-card__lead {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--hx-success-text);
}

.hx-result-strip__main {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

.hx-result-strip__url,
.hx-result-card__url {
  flex: 1 1 200px;
  min-width: 0;
  height: 38px;
  padding: 0 12px;
  font-family: var(--hx-mono);
  font-size: 12.5px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 10px;
  color: var(--hx-text-1);
  outline: none;
  transition: border-color 0.14s ease, box-shadow 0.14s ease;
}

.hx-result-strip__url:focus,
.hx-result-card__url:focus {
  border-color: var(--hx-brand);
  box-shadow: 0 0 0 3px var(--hx-brand-glow);
}

.hx-result-strip__tools,
.hx-result-card__tools {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

/* ==========================================================================
   2. 面板表单与控件规范系统 (Unified Form Elements)
   ========================================================================== */
/* 短链输入条 */
.hx-input-box {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid var(--hx-glass-edge);
  border-radius: 12px;
  padding: 6px 8px 6px 12px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  min-height: 48px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.hx-input-box:focus-within {
  border-color: rgba(5, 150, 105, 0.45);
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.12);
  transform: none;
}

.hx-input-box__prefix {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
  font-size: 12px;
  font-family: var(--hx-mono);
  color: var(--hx-text-muted);
  user-select: none;
  padding-right: 8px;
  border-right: 1px solid rgba(15, 23, 42, 0.08);
  margin-right: 2px;
}

.hx-input-box__prefix.is-secure {
  color: #64748b;
}

.hx-input-box__field {
  flex: 1;
  min-width: 0;
  max-width: 100%;
  border: none;
  outline: none;
  font-size: 13px;
  color: var(--hx-text-1);
  padding: 6px 0;
  background: transparent;
}

.hx-input-box__field,
.hx-result-strip__url {
  overflow: hidden;
  text-overflow: ellipsis;
}

.hx-input-box__field::placeholder {
  color: var(--hx-text-muted);
}

.hx-input-box__actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

/* 高级设置折叠抽屉 */
.hx-drawer {
  margin-top: 12px;
}

.hx-text-btn,
.hx-drawer__toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 500;
  color: var(--hx-text-3);
  padding: 4px 0;
  border-radius: 0;
  transition: color 0.14s ease;
}

.hx-text-btn:hover,
.hx-drawer__toggle:hover {
  color: var(--hx-brand);
  background: transparent;
}

.hx-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  color: var(--hx-text-3);
  background: rgba(15, 23, 42, 0.04);
  border: 1px solid transparent;
  transition: color 0.14s ease, background 0.14s ease, border-color 0.14s ease;
}

.hx-icon-btn:hover {
  color: var(--hx-text-1);
  background: rgba(15, 23, 42, 0.06);
  border-color: rgba(15, 23, 42, 0.06);
}

.hx-icon-btn--primary {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  color: #fff;
  background: linear-gradient(135deg, var(--hx-brand) 0%, #10b981 55%, var(--hx-accent) 100%);
  border: 1px solid rgba(5, 150, 105, 0.35);
  box-shadow: 0 8px 22px -10px rgba(5, 150, 105, 0.65);
}

.hx-icon-btn--primary:hover {
  color: #fff;
  background: linear-gradient(135deg, #065f46 0%, #047857 50%, #0d9488 100%);
  border-color: rgba(5, 150, 105, 0.45);
  box-shadow: 0 12px 28px -10px rgba(5, 150, 105, 0.75);
  transform: translateY(-1px);
}

.hx-icon-btn--primary:active {
  transform: translateY(0);
}

.hx-icon-btn--primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.hx-panel,
.hx-upload-stage {
  min-width: 0;
  max-width: 100%;
}

.hx-drawer__chev {
  transition: transform 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.hx-drawer.is-open .hx-drawer__chev {
  transform: rotate(180deg);
}

.hx-drawer__content {
  display: none;
  margin-top: 10px;
  padding: 14px 14px 4px;
  background: rgba(248, 250, 252, 0.85);
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 12px;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.hx-drawer.is-open .hx-drawer__content {
  display: grid;
}

.hx-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.hx-label {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--hx-text-2);
}

.hx-form-row {
  margin-bottom: 10px;
}

/* 统一输入框与下拉框规范 (统一标准高度 32px) */
.hx-input-clean {
  width: 100%;
  height: 36px;
  padding: 0 12px;
  font-size: 12.5px;
  color: var(--hx-text-1);
  background: rgba(255, 255, 255, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: var(--hx-radius-sm);
  outline: none;
  transition: border-color 0.14s ease, box-shadow 0.14s ease, background 0.14s ease;
}

.hx-input-clean:focus {
  border-color: var(--hx-brand);
  box-shadow: 0 0 0 2.5px var(--hx-brand-glow);
}

.hx-select-clean {
  height: 36px;
  padding: 0 12px;
  font-size: 12px;
  color: var(--hx-text-1);
  background: rgba(255, 255, 255, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: var(--hx-radius-sm);
  outline: none;
  cursor: pointer;
  transition: border-color 0.14s ease, box-shadow 0.14s ease;
}

.hx-select-clean:focus {
  border-color: var(--hx-brand);
  box-shadow: 0 0 0 2.5px var(--hx-brand-glow);
}

/* ==========================================================================
   2. Panel 2: 文本与代码轻量编辑器 (Zen Editor)
   ========================================================================== */
.hx-zen-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  gap: 10px;
  flex-wrap: wrap;
}

.hx-zen-hint {
  font-size: 12px;
  color: var(--hx-text-muted);
}

.hx-format-chips {
  display: inline-flex;
  gap: 2.5px;
  background: var(--hx-glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 3px;
  border-radius: var(--hx-radius-full);
  border: 1px solid var(--hx-glass-border);
}

.hx-chip {
  padding: 3px 9px;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--hx-text-3);
  border-radius: calc(var(--hx-radius-sm) - 2px);
  border: 1px solid transparent;
  transition: all 0.14s ease;
}

.hx-chip:hover {
  color: var(--hx-text-1);
}

.hx-chip.is-active {
  color: var(--hx-text-1);
  background: #ffffff;
  box-shadow: var(--hx-shadow-xs);
  font-weight: 600;
  border-color: rgba(15, 23, 42, 0.05);
}

.hx-editor-card {
  border: none;
  border-radius: var(--hx-radius-lg);
  background: rgba(255, 255, 255, 0.32);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
  overflow: hidden;
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.hx-editor-card:focus-within {
  background: rgba(255, 255, 255, 0.48);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.75),
    0 16px 48px -24px rgba(5, 150, 105, 0.35);
}

.hx-editor-ta {
  width: 100%;
  min-height: 145px;
  border: none;
  outline: none;
  padding: 12px 14px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--hx-text-1);
  resize: vertical;
  background: transparent;
}

.hx-editor-ta.is-code {
  font-family: var(--hx-mono);
  font-size: 12.5px;
  background: rgba(15, 23, 42, 0.03);
  color: #1e293b;
}

.hx-editor-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.25);
  border-top: 1px solid rgba(255, 255, 255, 0.45);
  font-size: 11px;
  color: var(--hx-text-muted);
}

.hx-editor-bar__metrics {
  display: flex;
  gap: 12px;
}

.hx-editor-bar__hint {
  color: var(--hx-text-muted);
}

/* 文本面板：与分享纸一体，不再套第二层外框 */
.hx-text-panel__form {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin: 0;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
  border-radius: 0;
}

.hx-text-panel__header {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0;
  border: none;
}

.hx-text-panel__title {
  margin: 0 0 2px;
  font-family: var(--hx-font-display);
  font-size: 13px;
  font-weight: 650;
  letter-spacing: -0.01em;
  color: var(--hx-text-1);
}

.hx-text-panel__lead {
  margin: 0;
  font-size: 12px;
  line-height: 1.55;
  color: var(--hx-text-3);
}

.hx-text-panel__format {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.hx-text-panel__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.hx-text-panel__label {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--hx-text-2);
}

.hx-text-panel .hx-format-chips {
  width: 100%;
  padding: 3px;
  gap: 3px;
  background: var(--hx-glass);
  border: 1px solid var(--hx-glass-border);
  border-radius: var(--hx-radius-full);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: none;
}

.hx-text-panel .hx-chip {
  flex: 1 1 0;
  min-width: 0;
  padding: 6px 10px;
  font-size: 11.5px;
  font-weight: 550;
  text-align: center;
  color: var(--hx-text-2);
  border: 1px solid transparent;
  border-radius: calc(var(--hx-radius-sm) - 1px);
}

.hx-text-panel .hx-chip.is-active {
  color: var(--hx-text-1);
  background: rgba(255, 255, 255, 0.92);
  border-color: rgba(5, 150, 105, 0.22);
  box-shadow: var(--hx-shadow-xs);
  font-weight: 600;
}

.hx-text-panel__control {
  width: 100%;
  height: 36px;
  padding: 0 12px;
  font-size: 12.5px;
  font-family: inherit;
  color: var(--hx-text-1);
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid var(--hx-glass-edge);
  border-radius: var(--hx-radius-sm);
  outline: none;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: border-color 0.14s ease, box-shadow 0.14s ease, background 0.14s ease;
}

.hx-text-panel__control::placeholder {
  color: var(--hx-text-muted);
}

.hx-text-panel__control:focus {
  background: rgba(255, 255, 255, 0.78);
  border-color: var(--hx-brand);
  box-shadow: 0 0 0 2.5px var(--hx-brand-glow);
}

.hx-text-panel__control--select {
  width: auto;
  min-width: 9rem;
  max-width: 100%;
  cursor: pointer;
  padding-right: 28px;
}

.hx-text-panel__editor {
  border: none;
  border-radius: var(--hx-radius-md);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 0 0 1px rgba(6, 78, 59, 0.11);
  transition: box-shadow 0.14s ease, background 0.14s ease;
}

.hx-text-panel__editor:focus-within {
  background: rgba(255, 255, 255, 0.62);
  box-shadow:
    inset 0 0 0 1px rgba(5, 150, 105, 0.35),
    0 0 0 2.5px var(--hx-brand-glow);
}

.hx-text-panel__textarea {
  display: block;
  width: 100%;
  min-height: 168px;
  padding: 13px 14px;
  border: none;
  outline: none;
  resize: vertical;
  font-size: 13px;
  line-height: 1.58;
  color: var(--hx-text-1);
  background: transparent;
}

.hx-text-panel__textarea::placeholder {
  color: var(--hx-text-muted);
}

.hx-text-panel__textarea.is-code {
  font-family: var(--hx-mono);
  font-size: 12.5px;
  line-height: 1.55;
  color: #1e293b;
}

.hx-text-panel__editor-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.28);
  border-top: 1px solid rgba(6, 78, 59, 0.07);
  font-size: 11px;
  color: var(--hx-text-3);
}

.hx-text-panel__metrics {
  display: flex;
  gap: 12px;
  font-variant-numeric: tabular-nums;
}

.hx-text-panel__shortcut {
  color: var(--hx-text-muted);
  white-space: nowrap;
}

.hx-text-panel__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 14px;
  margin-top: 0;
  border-top: 1px dashed rgba(15, 23, 42, 0.08);
}

.hx-text-panel__expires {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 10px;
}

@media (min-width: 640px) {
  .hx-text-panel__header {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
  }

  .hx-text-panel__format {
    align-items: flex-end;
    flex: 0 1 auto;
    min-width: min(100%, 272px);
  }

  .hx-text-panel .hx-format-chips {
    width: auto;
    min-width: 232px;
  }
}

/* 统一面板底部操作栏 */
.hx-panel-footer,
.hx-zen-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed rgba(15, 23, 42, 0.08);
  gap: 12px;
  flex-wrap: wrap;
}

.hx-panel-footer__left,
.hx-panel-footer__right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hx-panel-footer__left .hx-label,
.hx-panel-footer__right .hx-label {
  margin: 0;
  white-space: nowrap;
}

.hx-checkbox-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  color: var(--hx-text-2);
  cursor: pointer;
  user-select: none;
}

.hx-checkbox-label input[type="checkbox"] {
  accent-color: var(--hx-brand);
  width: 14px;
  height: 14px;
  cursor: pointer;
}

/* 文件上传舞台 */
.hx-upload-stage {
  position: relative;
  padding: 8px 0 4px;
}

.hx-upload-stage__aura {
  position: absolute;
  left: 50%;
  top: 42%;
  width: min(420px, 90%);
  height: 180px;
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse, rgba(5, 150, 105, 0.22) 0%, transparent 70%);
  filter: blur(18px);
  pointer-events: none;
  opacity: 0.85;
}

.hx-upload-stage__rings {
  position: absolute;
  left: 50%;
  top: 38%;
  width: 200px;
  height: 200px;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.hx-upload-stage__rings span {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid rgba(5, 150, 105, 0.14);
  animation: hx-ring-pulse 4.5s ease-out infinite;
}

.hx-upload-stage__rings span:nth-child(2) {
  animation-delay: 1.2s;
  opacity: 0.7;
}

.hx-upload-stage__rings span:nth-child(3) {
  animation-delay: 2.4s;
  opacity: 0.45;
}

@keyframes hx-ring-pulse {
  0% { transform: scale(0.55); opacity: 0.65; }
  100% { transform: scale(1.15); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .hx-upload-stage__rings span {
    animation: none;
    opacity: 0.25;
    transform: scale(0.9);
  }
}

.hx-dropzone-box {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 200px;
  padding: 28px 20px 22px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.82) 0%, rgba(239, 246, 255, 0.55) 100%);
  cursor: pointer;
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.22s ease, box-shadow 0.22s ease;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 24px 64px -36px rgba(5, 150, 105, 0.35);
}

.hx-dropzone-box::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(52, 211, 153, 0.12) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.6s ease;
  pointer-events: none;
}

.hx-dropzone-box:hover::before,
.hx-dropzone-box.is-dragover::before {
  transform: translateX(120%);
}

.hx-dropzone-box:hover,
.hx-dropzone-box.is-dragover {
  transform: translateY(-3px);
  border-color: rgba(5, 150, 105, 0.35);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 1) inset,
    0 0 0 4px rgba(5, 150, 105, 0.1),
    0 28px 72px -32px rgba(5, 150, 105, 0.45);
}

.hx-dropzone-box--guest {
  cursor: default;
}

.hx-dropzone-box--guest:hover {
  transform: none;
}

.hx-dropzone-box__icon {
  width: 56px;
  height: 56px;
  margin-bottom: 12px;
  border-radius: 50%;
  background: linear-gradient(145deg, #ffffff 0%, #d1fae5 100%);
  color: var(--hx-brand);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 32px -12px rgba(5, 150, 105, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.95);
  transition: transform 0.22s ease;
}

.hx-dropzone-box:hover .hx-dropzone-box__icon {
  transform: translateY(-2px);
}

.hx-dropzone-box--guest:hover .hx-dropzone-box__icon {
  transform: none;
}

.hx-dropzone-box__title {
  font-size: 14px;
  font-weight: 650;
  color: var(--hx-text-1);
  margin-bottom: 4px;
  letter-spacing: -0.01em;
}

.hx-dropzone-box__hint {
  font-size: 12px;
  color: var(--hx-text-3);
  max-width: 360px;
  line-height: 1.5;
}

.hx-upload-methods {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.hx-upload-methods li {
  font-size: 11px;
  color: var(--hx-text-3);
  padding: 4px 10px;
  border-radius: var(--hx-radius-full);
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.8);
}

.hx-upload-methods__key {
  display: inline-block;
  margin-right: 4px;
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 600;
  font-family: var(--hx-mono);
  color: var(--hx-brand);
  background: rgba(5, 150, 105, 0.1);
}

.hx-dropzone-box__action {
  margin-top: 14px;
}

.hx-upload-bar {
  display: none;
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.85);
}

.hx-upload-bar.is-active {
  display: block;
}

.hx-upload-bar__header {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  color: var(--hx-text-2);
  margin-bottom: 6px;
}

.hx-upload-bar__track {
  width: 100%;
  height: 8px;
  border-radius: 6px;
  background: rgba(15, 23, 42, 0.06);
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.06);
}

.hx-upload-bar__fill {
  width: 0%;
  height: 100%;
  border-radius: 6px;
  background: linear-gradient(90deg, #047857, #059669, #34d399, #2dd4bf);
  background-size: 200% 100%;
  animation: hx-upload-shimmer 1.8s linear infinite;
  transition: width 0.15s ease;
}

@keyframes hx-upload-shimmer {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

/* ==========================================================================
   产品能力 Bento 卡片
   ========================================================================== */
.hx-capabilities {
  margin: 4px auto 0;
  max-width: 100%;
  padding: 28px 0 clamp(8px, 2vw, 16px);
}

.hx-capabilities__head {
  margin-bottom: 16px;
}

.hx-capabilities__title {
  margin: 0 0 6px;
  font-family: var(--hx-font-display);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--hx-text-1);
}

.hx-capabilities__desc {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--hx-text-3);
}

.hx-cap-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.hx-cap-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  padding: 16px 16px 14px;
  border-radius: var(--hx-radius-lg);
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--hx-border-strong);
  box-shadow: var(--hx-shadow-xs);
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.hx-cap-card:hover {
  border-color: var(--hx-border-hover);
  box-shadow: var(--hx-shadow-sm);
}

.hx-cap-card--wide {
  grid-column: 1 / -1;
}

.hx-cap-card__top {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hx-cap-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  color: var(--hx-brand);
  background: var(--hx-brand-subtle);
  border: 1px solid var(--hx-brand-border);
}

.hx-cap-card__title {
  margin: 0;
  font-size: 14px;
  font-weight: 650;
  letter-spacing: -0.02em;
  color: var(--hx-text-1);
}

.hx-cap-card__text {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.62;
  color: var(--hx-text-3);
}

.hx-cap-card__foot {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 10px;
  margin-top: 2px;
  padding-top: 10px;
  border-top: 1px solid var(--hx-border);
}

.hx-cap-chip {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--hx-text-muted);
}

.hx-cap-code {
  font-family: var(--hx-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--hx-brand-active);
}

.hx-cap-card__meta {
  margin: 0;
  font-size: 11.5px;
  color: var(--hx-text-muted);
  line-height: 1.45;
}

.hx-cap-card__meta--ok {
  color: var(--hx-success-text);
  font-weight: 600;
}

/* ==========================================================================
   2. 全球骨干加速与云存储分布 (Cloudflare / Precision Architecture)
       全站风格协调统一重构版：消解突兀橙色，融入高品质科技蓝与冷灰
   ========================================================================== */
.cf-earth-section {
  width: 100%;
  max-width: min(1240px, 100%);
  margin: 0 auto 36px;
  min-width: 0;
  overflow-x: clip;
}

.cf-earth-header {
  text-align: center;
  margin-bottom: clamp(16px, 3vw, 24px);
}

.cf-earth-title {
  font-family: var(--hx-font-display);
  font-size: clamp(1.35rem, 2.4vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  color: var(--hx-text-1);
  margin: 0 0 8px;
  line-height: 1.25;
}

.cf-earth-subtitle {
  font-size: 13px;
  color: var(--hx-text-3);
  max-width: 34em;
  margin: 0 auto;
  line-height: 1.62;
}

.cf-earth-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-height: 420px;
  width: 100%;
}

.cf-earth-grid-bg {
  position: absolute;
  inset: 8% 10%;
  pointer-events: none;
  z-index: 0;
  border-radius: 50%;
  background: radial-gradient(
    ellipse 80% 70% at 50% 50%,
    rgba(5, 150, 105, 0.12) 0%,
    rgba(5, 150, 105, 0.04) 42%,
    transparent 72%
  );
}

/* 3D 旋转地球仪居中视口 */
.cf-globe-canvas-wrap {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 100%;
  min-height: 350px;
  padding: 4px 0 6px;
  user-select: none;
  overflow: visible;
}

.cf-globe-canvas-wrap canvas {
  display: block;
  max-width: 100%;
}

.cf-hud {
  position: absolute;
  z-index: 5;
  width: min(220px, 26vw);
  padding: 0 0 0 14px;
  border-left: 2px solid rgba(5, 150, 105, 0.45);
  pointer-events: none;
}

.cf-hud--left {
  left: clamp(8px, 3vw, 48px);
  top: 50%;
  transform: translateY(-58%);
}

.cf-hud--right {
  right: clamp(8px, 3vw, 48px);
  top: 50%;
  transform: translateY(-42%);
  padding-left: 0;
  padding-right: 14px;
  border-left: none;
  border-right: 2px solid rgba(5, 150, 105, 0.45);
  text-align: right;
}

.cf-hud__stat {
  margin: 0 0 2px;
  font-family: var(--hx-font-display);
  font-size: clamp(1.35rem, 2.5vw, 1.65rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.1;
  color: var(--hx-brand);
}

.cf-hud__headline {
  margin: 0 0 8px;
  font-size: 12.5px;
  font-weight: 650;
  letter-spacing: -0.01em;
  color: var(--hx-text-1);
}

.cf-hud__text {
  margin: 0;
  font-size: 11.5px;
  line-height: 1.55;
  color: var(--hx-text-3);
  max-width: 20em;
}

.cf-hud--right .cf-hud__text {
  margin-left: auto;
}

.cf-earth-status-bar {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin-top: -6px;
  padding: 4px 12px 10px;
}

.cf-status-pill {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 8px;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.36);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: var(--hx-radius-full);
  font-size: 11.5px;
  color: var(--hx-text-2);
  box-shadow: 0 8px 28px -18px rgba(5, 150, 105, 0.35);
}

.cf-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--hx-success);
  box-shadow: 0 0 0 2px var(--hx-success-border);
  flex-shrink: 0;
}

.cf-status-sep {
  color: rgba(100, 116, 139, 0.45);
  user-select: none;
}

.cf-status-latency {
  font-family: var(--hx-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--hx-brand-active);
}

.cf-status-hint {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 0;
  font-size: 11px;
  color: var(--hx-text-muted);
}

.cf-earth-features {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px clamp(24px, 5vw, 56px);
  margin-top: 4px;
  padding: clamp(20px, 4vw, 28px) clamp(4px, 2vw, 16px) 4px;
}

.cf-feat-col {
  min-width: 0;
}

.cf-feat-title {
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: -0.02em;
  color: var(--hx-text-1);
}

.cf-feat-desc {
  margin: 0;
  font-size: 12px;
  line-height: 1.62;
  color: var(--hx-text-3);
}

/* ==========================================================================
   2. 页脚 Footer (Clean Unified Minimal Footer)
   ========================================================================== */
.hx-footer {
  position: relative;
  z-index: 2;
  margin-top: auto;
  padding: 34px 0 18px;
  font-size: 12px;
  color: var(--hx-text-3);
  border-top: 1px solid rgba(255, 255, 255, 0.82);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.46) 0%, rgba(236, 253, 245, 0.72) 100%);
  box-shadow: 0 -1px 0 var(--hx-glass-edge);
  backdrop-filter: blur(16px) saturate(1.15);
  -webkit-backdrop-filter: blur(16px) saturate(1.15);
}

/* 上层：左侧品牌身份，右侧三组导航 */
.hx-footer__inner {
  display: grid;
  grid-template-columns: minmax(200px, 1fr) auto;
  align-items: start;
  gap: 30px 52px;
}

.hx-footer__identity {
  max-width: 300px;
  min-width: 0;
}

.hx-footer__brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--hx-font-display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--hx-text-1);
}

.hx-footer__brand-img {
  display: block;
  height: 22px;
  width: auto;
}

.hx-footer__brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(145deg, var(--hx-brand) 0%, #34d399 100%);
  box-shadow: 0 6px 14px -9px rgba(5, 150, 105, 0.85);
}

.hx-footer__tagline {
  margin: 11px 0 0;
  font-size: 12px;
  line-height: 1.7;
  color: var(--hx-text-3);
}

.hx-footer__status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 13px 0 0;
  padding: 4px 11px 4px 9px;
  font-size: 11px;
  font-weight: 600;
  color: var(--hx-success-text);
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(16, 185, 129, 0.22);
  border-radius: var(--hx-radius-full);
}

.hx-footer__status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--hx-success);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.16);
}

.hx-footer__nav {
  display: grid;
  grid-template-columns: repeat(3, minmax(104px, auto));
  gap: 26px 34px;
}

.hx-footer__group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 9px;
  min-width: 0;
}

.hx-footer__group-title {
  margin: 0 0 2px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--hx-text-muted);
}

.hx-footer__group a {
  max-width: 100%;
  font-size: 12px;
  color: var(--hx-text-2);
  overflow-wrap: anywhere;
  transition: color 0.14s ease;
}

.hx-footer__group a:hover {
  color: var(--hx-brand);
}

.hx-footer__group a:focus-visible {
  outline: 2px solid var(--hx-border-focus);
  outline-offset: 2px;
  border-radius: var(--hx-radius-xs);
}

.hx-footer__nav .hx-footer__cta {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  font-weight: 600;
  color: var(--hx-brand-active);
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(5, 150, 105, 0.2);
  border-radius: var(--hx-radius-full);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 8px 18px -14px rgba(6, 78, 59, 0.6);
  transition: color 0.14s ease, background 0.14s ease, border-color 0.14s ease;
}

.hx-footer__nav .hx-footer__cta:hover {
  background: #fff;
  border-color: rgba(5, 150, 105, 0.36);
}

/* 下层：版权与服务承诺 */
.hx-footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin-top: 26px;
  padding-top: 14px;
  border-top: 1px solid rgba(6, 78, 59, 0.08);
  font-size: 11px;
  color: var(--hx-text-muted);
}

.hx-footer__copyright {
  margin: 0;
}

.hx-footer__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
}

.hx-footer__sep {
  color: rgba(6, 78, 59, 0.2);
}

/* ==========================================================================
   2. 二维码弹层 Modal、全局轻量 Toast 与 Alert
   ========================================================================== */
.hx-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: hx-fade-in 0.16s ease-out;
}

.hx-modal-backdrop.is-open {
  display: flex;
}

@keyframes hx-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.hx-modal-box {
  background: #ffffff;
  border: 1px solid var(--hx-border);
  border-radius: var(--hx-radius-xl);
  padding: 22px 20px;
  width: 100%;
  max-width: 290px;
  box-shadow: var(--hx-shadow-float);
  text-align: center;
  position: relative;
  animation: hx-scale-up 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes hx-scale-up {
  from { transform: scale(0.96); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.hx-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 26px;
  height: 26px;
  border-radius: var(--hx-radius-xs);
  color: var(--hx-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.14s ease;
}

.hx-modal-close:hover {
  color: var(--hx-text-1);
  background: var(--hx-bg-subtle);
}

.hx-modal-title {
  margin: 0 0 12px;
  font-size: 13.5px;
  font-weight: 650;
  color: var(--hx-text-1);
}

.hx-qr-canvas-wrap {
  display: inline-block;
  padding: 8px;
  background: #ffffff;
  border: 1px solid var(--hx-border);
  border-radius: var(--hx-radius-sm);
  margin-bottom: 14px;
  box-shadow: var(--hx-shadow-xs);
}

.hx-qr-canvas-wrap canvas {
  display: block;
}

.hx-modal-actions {
  display: flex;
  gap: 8px;
  justify-content: center;
}

/* Toast 提示浮条 */
.hx-toast-container {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 6px;
  pointer-events: none;
}

.hx-toast {
  pointer-events: auto;
  padding: 7px 16px;
  border-radius: var(--hx-radius-full);
  font-size: 12px;
  font-weight: 500;
  box-shadow: var(--hx-shadow-md);
  animation: hx-toast-in 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.hx-toast.is-leaving {
  opacity: 0;
  transform: translateY(-6px);
}

@keyframes hx-toast-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

.hx-toast--info {
  background: #ffffff;
  color: var(--hx-text-1);
  border: 1px solid var(--hx-border);
}

.hx-toast--success {
  background: #ffffff;
  color: var(--hx-success-text);
  border: 1px solid var(--hx-success-border);
}

.hx-toast--error {
  background: #ffffff;
  color: var(--hx-danger-text);
  border: 1px solid var(--hx-danger-border);
}

/* 消息提示框 */
.hx-alert {
  padding: 9px 13px;
  border-radius: var(--hx-radius-sm);
  font-size: 12px;
  margin-bottom: 12px;
}

.hx-alert--err {
  color: var(--hx-danger-text);
  background: var(--hx-danger-subtle);
  border: 1px solid var(--hx-danger-border);
}

.hx-alert--ok {
  color: var(--hx-success-text);
  background: var(--hx-success-subtle);
  border: 1px solid var(--hx-success-border);
}

/* ==========================================================================
   2. 移动端与平板响应式适配 (Refined Mobile Breakdown)
   ========================================================================== */
@media (max-width: 1024px) {
  .cf-hud {
    position: static;
    width: auto;
    max-width: none;
    transform: none;
    padding: 0 0 0 12px;
    margin: 0 clamp(8px, 3vw, 24px);
  }

  .cf-hud--right {
    padding-right: 0;
    padding-left: 12px;
    border-right: none;
    border-left: 2px solid rgba(5, 150, 105, 0.45);
    text-align: left;
  }

  .cf-hud--right .cf-hud__text {
    margin-left: 0;
  }

  .cf-earth-stage {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px 20px;
    min-height: 0;
  }

  .cf-globe-canvas-wrap {
    grid-column: 1 / -1;
    grid-row: 1;
    min-height: 320px;
  }

  .cf-hud--left {
    grid-column: 1;
    grid-row: 2;
  }

  .cf-hud--right {
    grid-column: 2;
    grid-row: 2;
  }

  .cf-earth-status-bar {
    grid-column: 1 / -1;
    grid-row: 3;
    margin-top: 0;
  }

  .cf-earth-features {
    grid-column: 1 / -1;
    grid-row: 4;
  }
}

@media (max-width: 860px) {
  .hx-nav {
    top: 10px;
    width: min(var(--hx-layout-max), calc(100% - var(--hx-layout-gutter) * 2));
  }

  .hx-content-zone {
    padding-top: 88px;
  }

  .cf-globe-canvas-wrap {
    min-height: 300px;
  }

  .cf-earth-features {
    grid-template-columns: 1fr;
    gap: 20px;
    padding-top: 16px;
  }

  .cf-earth-status-bar {
    flex-direction: column;
  }

  .hx-cap-grid {
    grid-template-columns: 1fr;
  }

  .hx-cap-card--wide {
    grid-column: auto;
  }

  .hx-drawer__content {
    grid-template-columns: 1fr;
  }

  .hx-footer__inner {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .hx-footer__identity {
    max-width: none;
  }

  .hx-footer__nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 16px;
    width: 100%;
  }

  .hx-footer__group--account {
    grid-column: 1 / -1;
    padding-top: 4px;
  }

  .hx-footer__bottom {
    margin-top: 22px;
    padding-top: 16px;
  }
}

@media (max-width: 640px) {
  :root {
    --hx-layout-gutter: 16px;
  }

  .hx-wrap {
    padding: 0 var(--hx-layout-gutter);
  }

  .hx-capabilities {
    padding-top: 22px;
  }

  .hx-content-zone {
    padding-top: 84px;
    padding-bottom: 32px;
  }

  .hx-sheet {
    padding: 18px 14px 16px;
    border-radius: 22px;
  }

  .hx-hub-head {
    margin-bottom: 12px;
    padding: 0 2px;
  }

  .hx-hub-head__title {
    font-size: 1.08rem;
  }

  .hx-hub-head__lead {
    padding-left: 33px;
    font-size: 12px;
  }

  .hx-modes {
    width: 100%;
    margin-bottom: 14px;
  }

  .hx-mode {
    flex: 1 1 0;
    min-width: 0;
    padding: 8px 6px;
  }

  .hx-content-zone__glow {
    opacity: 0.35;
  }

  .cf-earth-stage {
    grid-template-columns: 1fr;
  }

  .cf-hud--left,
  .cf-hud--right {
    grid-column: 1;
  }

  .cf-hud--right {
    grid-row: 3;
  }

  .cf-hud--left {
    grid-row: 2;
  }

  .cf-earth-status-bar {
    grid-row: 4;
  }

  .cf-earth-features {
    grid-row: 5;
  }

  .hx-input-box {
    flex-wrap: wrap;
    padding: 8px;
    min-height: auto;
    gap: 8px;
  }

  .hx-input-box__prefix {
    width: 100%;
    border-right: none;
    padding-right: 0;
    margin-right: 0;
    padding-bottom: 4px;
    border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  }

  .hx-input-box__actions {
    width: 100%;
    justify-content: flex-end;
  }

  .hx-input-box__field {
    font-size: 12.5px;
  }

  .hx-input-box__field::placeholder {
    font-size: 11.5px;
  }

  #btn-submit-url {
    width: 36px;
    height: 36px;
  }

  .hx-drawer__content {
    grid-template-columns: 1fr;
  }

  .hx-text-panel__textarea {
    min-height: 140px;
    padding: 11px 12px;
    font-size: 12px;
  }

  .hx-text-panel__shortcut {
    display: none;
  }

  .hx-editor-bar > span:last-child,
  .hx-editor-bar__hint {
    display: none;
  }

  .hx-dropzone-box {
    min-height: 168px;
    padding: 20px 12px 16px;
  }

  .hx-dropzone-box__icon {
    width: 48px;
    height: 48px;
    margin-bottom: 8px;
  }

  .hx-upload-methods {
    gap: 6px;
  }

  .hx-upload-methods li {
    font-size: 10px;
    padding: 3px 8px;
  }

  .hx-dropzone-box__title {
    font-size: 12.5px;
  }

  .hx-dropzone-box__hint {
    font-size: 11px;
  }

  .hx-result-strip,
  .hx-result-card {
    gap: 6px;
    padding: 8px 10px;
    margin-bottom: 10px;
    border-radius: 10px;
  }

  .hx-result-strip__badge,
  .hx-result-card__lead {
    font-size: 11px;
    gap: 5px;
  }

  .hx-result-strip__close {
    width: 24px;
    height: 24px;
  }

  .hx-result-strip__main {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
  }

  .hx-result-strip__url,
  .hx-result-card__url {
    width: 100%;
    flex: none;
    font-size: 11px;
    height: 32px;
    padding: 0 10px;
    border-radius: 8px;
  }

  .hx-result-strip__tools,
  .hx-result-card__tools {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }

  .hx-result-strip__tools .hx-btn--compact,
  .hx-result-card__tools .hx-btn--compact {
    min-height: 32px;
    padding: 0 6px;
    font-size: 11px;
    justify-content: center;
  }

  .hx-result-strip__tools .hx-btn--compact span,
  .hx-result-card__tools .hx-btn--compact span {
    display: none;
  }

  .hx-result-strip__tools .hx-btn--compact svg,
  .hx-result-card__tools .hx-btn--compact svg {
    width: 15px;
    height: 15px;
  }

  /* 手机端页脚：顶部两侧圆角，像从屏幕底部升起的一张玻璃面板 */
  .hx-footer {
    padding: 22px 0 max(20px, env(safe-area-inset-bottom, 0px));
    border: 1px solid var(--hx-glass-edge);
    border-bottom: 0;
    border-radius: 22px 22px 0 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.78) 0%, rgba(236, 253, 245, 0.88) 100%);
    box-shadow:
      0 1px 0 rgba(255, 255, 255, 0.92) inset,
      0 -14px 34px -24px rgba(6, 78, 59, 0.55);
  }

  .hx-footer .hx-wrap {
    padding-left: 16px;
    padding-right: 16px;
  }

  .hx-footer__inner {
    gap: 20px;
  }

  .hx-footer__identity {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
  }

  .hx-footer__tagline {
    margin-top: 10px;
    max-width: 22em;
  }

  .hx-footer__nav {
    grid-template-columns: 1fr 1fr;
    gap: 18px 14px;
  }

  .hx-footer__group {
    gap: 8px;
  }

  .hx-footer__group--account {
    grid-column: 1 / -1;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    padding-top: 14px;
    margin-top: 2px;
    border-top: 1px dashed rgba(6, 78, 59, 0.1);
  }

  .hx-footer__group--account .hx-footer__group-title {
    width: 100%;
    margin-bottom: 0;
  }

  .hx-footer__bottom {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
    margin-top: 18px;
    padding-top: 16px;
  }

  .hx-footer__copyright {
    width: 100%;
  }

  .hx-footer__meta {
    justify-content: center;
    gap: 6px 8px;
    line-height: 1.5;
  }
}
