/* ============================================================
 * 暗夜玻璃皮肤（ink-night-20261109-r1 · 2026-11-09）
 *
 * 【开关机制】作用域 html.ink-on.night-glass:not(.dark)
 *   - .night-glass 由 ink-theme.js 按 localStorage 'ink-skin'==='night' 挂/摘
 *   - 与浅色毛玻璃（.glass-on）互斥：选 night 时 js 摘掉 glass-on
 *   - .dark（月亮深色）会话下本层失效，回深色兜底
 *
 * 【质感目标】手机控制中心那种深色磨砂玻璃：
 *   深色玻璃面 rgba(44,48,42,.52) + 大半径 blur + 暗背景彩色光斑
 *   （橄榄绿 / 琥珀 / 黛蓝 / 暗紫），文字暖白，描边浅色半透。
 *
 * 【设计语言保留】爱马仕橙开关钮、金豆豆选中胶囊、橄榄绿主按钮
 *   （奶油渐变+白字在暗底上依旧成立）全部不动。
 * ============================================================ */

/* ---------- 一、暗色基底 + 彩色光斑 ---------- */
html.ink-on.night-glass:not(.dark) {
  background: #20241c;
  color: #ece8db;
}
html.ink-on.night-glass:not(.dark) body::before {
  content: '';
  position: fixed;
  inset: -12%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(640px 480px at 10% -8%,  rgba(122, 158, 90, .55), rgba(122, 158, 90, 0) 70%),
    radial-gradient(560px 440px at 94% 4%,   rgba(212, 160, 70, .48), rgba(212, 160, 70, 0) 70%),
    radial-gradient(700px 520px at 80% 100%, rgba(96, 110, 152, .50), rgba(96, 110, 152, 0) 70%),
    radial-gradient(560px 440px at 0% 92%,   rgba(140, 100, 150, .42), rgba(140, 100, 150, 0) 70%),
    radial-gradient(480px 380px at 45% 55%,  rgba(90, 120, 100, .30), rgba(90, 120, 100, 0) 70%);
}

/* 根容器与页底一律透明（.nc-app 不透明会盖掉光斑，r2 的教训） */
html.ink-on.night-glass:not(.dark) body,
html.ink-on.night-glass:not(.dark) .nc-app,
html.ink-on.night-glass:not(.dark) .app-bg-pattern,
html.ink-on.night-glass:not(.dark) .nc-app-content,
html.ink-on.night-glass:not(.dark) .nc-app-content-inner,
html.ink-on.night-glass:not(.dark) .ink-overview,
html.ink-on.night-glass:not(.dark) .pub-landing,
html.ink-on.night-glass:not(.dark) .pub-auth-bg {
  background: transparent !important;
}

/* ---------- 二、变量整体翻暗（特异性高于墨线基底的 !important 变量） ---------- */
html.ink-on.night-glass:not(.dark),
html.ink-on.night-glass:not(.dark) .ink-overview {
  --theme-bg: #20241c !important;
  --theme-text: #ece8db !important;
  --farm-bg: #20241c !important;
  --farm-bg-subtle: #262a20 !important;
  --farm-surface: rgba(44, 48, 42, .55) !important;
  --farm-surface-elevated: rgba(58, 62, 54, .66) !important;
  --farm-card-bg: rgba(44, 48, 42, .55) !important;
  --farm-border: rgba(232, 228, 216, .20) !important;
  --farm-border-subtle: rgba(232, 228, 216, .13) !important;
  --farm-text: #ece8db !important;
  --farm-muted: #a39e8e !important;
  --farm-accent: #a8b07f !important;
  --farm-accent-hover: #bcc492 !important;
  --farm-accent-soft: rgba(168, 176, 127, .16) !important;
  --farm-input-bg: rgba(40, 44, 38, .72) !important;
  --farm-elevated-bg: rgba(56, 60, 52, .70) !important;
  --farm-glass: rgba(44, 48, 42, .6) !important;
  --farm-glass-border: rgba(232, 228, 216, .18) !important;
  --color-canvas: #20241c !important;
  --color-bg-muted: #262a20 !important;
  --color-surface: rgba(44, 48, 42, .55) !important;
  --color-border: rgba(232, 228, 216, .20) !important;
  --color-border-subtle: rgba(232, 228, 216, .13) !important;
  --color-accent: #a8b07f !important;
  --color-accent-hover: #bcc492 !important;
  --color-accent-muted: rgba(168, 176, 127, .18) !important;
  --color-text: #ece8db !important;
  --color-text-muted: #a39e8e !important;
  --color-muted-foreground: #a39e8e !important;
  --color-caption: #a39e8e !important;
  --color-list-text: #e2ded0 !important;
  --ink-page-bg: #20241c !important;
  --ink-page-surface: rgba(44, 48, 42, .55) !important;
  --ink-page-surface-soft: rgba(58, 62, 54, .66) !important;
  --ink-page-border: rgba(232, 228, 216, .30) !important;
  --ink-page-border-soft: rgba(232, 228, 216, .18) !important;
  --ink-page-text: #ece8db !important;
  --ink-page-muted: #a39e8e !important;
  --ink-page-accent: #a8b07f !important;
  --ink-page-accent-hover: #bcc492 !important;
  --ink-page-accent-soft: rgba(168, 176, 127, .16) !important;
  --ink-page-shadow: 0 10px 30px rgba(0, 0, 0, .32) !important;
  --farm-shadow: 0 10px 30px rgba(0, 0, 0, .32) !important;
  --farm-shadow-lg: 0 14px 38px rgba(0, 0, 0, .38) !important;
  --shadow-card: 0 10px 30px rgba(0, 0, 0, .32) !important;
  --shadow-float: 0 14px 38px rgba(0, 0, 0, .42) !important;
  --personal-stat-blue: #a8b07f;
}

/* ---------- 三、玻璃面（半透深灰 + 大半径 blur） ---------- */
@supports (backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px)) {

  html.ink-on.night-glass:not(.dark) .bg-white,
  html.ink-on.night-glass:not(.dark) .bg-white\/95,
  html.ink-on.night-glass:not(.dark) .bg-white\/90,
  html.ink-on.night-glass:not(.dark) .bg-white\/80,
  html.ink-on.night-glass:not(.dark) .bg-white\/70,
  html.ink-on.night-glass:not(.dark) .bg-white\/60,
  html.ink-on.night-glass:not(.dark) .nav-panel,
  html.ink-on.night-glass:not(.dark) .nav-scroll,
  html.ink-on.night-glass:not(.dark) .nav-footer,
  html.ink-on.night-glass:not(.dark) .nav-tile,
  html.ink-on.night-glass:not(.dark) .ink-card,
  html.ink-on.night-glass:not(.dark) .ink-farm-panel,
  html.ink-on.night-glass:not(.dark) .ink-farm-option,
  html.ink-on.night-glass:not(.dark) .ink-farm-search,
  html.ink-on.night-glass:not(.dark) .nc-glass-panel,
  html.ink-on.night-glass:not(.dark) .nc-overview-panel,
  html.ink-on.night-glass:not(.dark) .nc-overview-account-card,
  html.ink-on.night-glass:not(.dark) .nc-dash-announcement,
  html.ink-on.night-glass:not(.dark) .settings-content-card,
  html.ink-on.night-glass:not(.dark) .status-tile,
  html.ink-on.night-glass:not(.dark) .announcement-panel,
  html.ink-on.night-glass:not(.dark) .qixi-progress-card,
  html.ink-on.night-glass:not(.dark) .confirm-modal,
  html.ink-on.night-glass:not(.dark) .purchase-modal,
  html.ink-on.night-glass:not(.dark) .account-auto-relogin-dialog,
  html.ink-on.night-glass:not(.dark) .user-menu-links,
  html.ink-on.night-glass:not(.dark) .nc-menu-panel,
  html.ink-on.night-glass:not(.dark) .aqs-panel,
  html.ink-on.night-glass:not(.dark) .nc-appearance-panel,
  html.ink-on.night-glass:not(.dark) .nc-log-panel,
  html.ink-on.night-glass:not(.dark) .ac-hub .ac-extras > :not(p),
  html.ink-on.night-glass:not(.dark) .app-container .content-area {
    background: rgba(44, 48, 42, .52) !important;
    -webkit-backdrop-filter: blur(28px) saturate(1.6);
    backdrop-filter: blur(28px) saturate(1.6);
  }
  /* 悬浮层稍不透一点，保证浮层文字对比度 */
  html.ink-on.night-glass:not(.dark) .bg-white\/95,
  html.ink-on.night-glass:not(.dark) .bg-white\/90,
  html.ink-on.night-glass:not(.dark) .nc-menu-panel,
  html.ink-on.night-glass:not(.dark) .aqs-panel,
  html.ink-on.night-glass:not(.dark) .nc-appearance-panel,
  html.ink-on.night-glass:not(.dark) .confirm-modal,
  html.ink-on.night-glass:not(.dark) .purchase-modal,
  html.ink-on.night-glass:not(.dark) .account-auto-relogin-dialog,
  html.ink-on.night-glass:not(.dark) .user-menu-links {
    background: rgba(52, 56, 50, .68) !important;
  }

  /* 大卡：顶部冷白高光内衬 + 深投影 */
  html.ink-on.night-glass:not(.dark) .ink-card,
  html.ink-on.night-glass:not(.dark) .nav-panel,
  html.ink-on.night-glass:not(.dark) .ink-farm-panel,
  html.ink-on.night-glass:not(.dark) .nc-glass-panel,
  html.ink-on.night-glass:not(.dark) .nc-overview-panel,
  html.ink-on.night-glass:not(.dark) .nc-overview-account-card,
  html.ink-on.night-glass:not(.dark) .nc-dash-announcement,
  html.ink-on.night-glass:not(.dark) .settings-content-card,
  html.ink-on.night-glass:not(.dark) .status-tile,
  html.ink-on.night-glass:not(.dark) .announcement-panel,
  html.ink-on.night-glass:not(.dark) .qixi-progress-card,
  html.ink-on.night-glass:not(.dark) .nc-log-panel,
  html.ink-on.night-glass:not(.dark) .nc-menu-panel,
  html.ink-on.night-glass:not(.dark) .aqs-panel,
  html.ink-on.night-glass:not(.dark) .nc-appearance-panel,
  html.ink-on.night-glass:not(.dark) .confirm-modal,
  html.ink-on.night-glass:not(.dark) .purchase-modal,
  html.ink-on.night-glass:not(.dark) .account-auto-relogin-dialog,
  html.ink-on.night-glass:not(.dark) .user-menu-links {
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .14),
      0 10px 30px rgba(0, 0, 0, .32) !important;
  }

  html.ink-on.night-glass:not(.dark) .shadow,
  html.ink-on.night-glass:not(.dark) .shadow-md,
  html.ink-on.night-glass:not(.dark) .shadow-lg {
    box-shadow: 0 10px 30px rgba(0, 0, 0, .32) !important;
  }
}

/* ---------- 四、Tailwind 冷灰/蓝系 → 暗夜橄榄系 ---------- */
html.ink-on.night-glass:not(.dark) .bg-gray-50  { background: rgba(58, 62, 54, .5) !important; }
html.ink-on.night-glass:not(.dark) .bg-gray-100 { background: rgba(50, 54, 47, .55) !important; }
html.ink-on.night-glass:not(.dark) .bg-gray-200 { background: rgba(66, 70, 62, .6) !important; }
html.ink-on.night-glass:not(.dark) .hover\:bg-gray-50:hover  { background: rgba(70, 74, 66, .55) !important; }
html.ink-on.night-glass:not(.dark) .hover\:bg-gray-100:hover { background: rgba(66, 70, 62, .6) !important; }
html.ink-on.night-glass:not(.dark) .hover\:bg-gray-200:hover { background: rgba(78, 82, 74, .6) !important; }
html.ink-on.night-glass:not(.dark) .hover\:bg-gray-100\/60:hover { background: rgba(70, 74, 66, .4) !important; }
html.ink-on.night-glass:not(.dark) .hover\:bg-gray-50\/80:hover  { background: rgba(66, 70, 62, .5) !important; }
html.ink-on.night-glass:not(.dark) .bg-blue-50,
html.ink-on.night-glass:not(.dark) .bg-indigo-50 { background: rgba(111, 118, 81, .16) !important; }
html.ink-on.night-glass:not(.dark) .bg-blue-100  { background: rgba(111, 118, 81, .22) !important; }
html.ink-on.night-glass:not(.dark) .bg-blue-200  { background: rgba(111, 118, 81, .3) !important; }
html.ink-on.night-glass:not(.dark) .border-gray-200\/80 { border-color: rgba(232, 228, 216, .22) !important; }
html.ink-on.night-glass:not(.dark) .border-gray-200\/60 { border-color: rgba(232, 228, 216, .16) !important; }
html.ink-on.night-glass:not(.dark) .border-gray-200 { border-color: rgba(232, 228, 216, .22) !important; }
html.ink-on.night-glass:not(.dark) .border-gray-300 { border-color: rgba(232, 228, 216, .28) !important; }
html.ink-on.night-glass:not(.dark) .divide-gray-100 > :not([hidden]) ~ :not([hidden]) { border-color: rgba(232, 228, 216, .12) !important; }
html.ink-on.night-glass:not(.dark) .text-blue-400,
html.ink-on.night-glass:not(.dark) .text-blue-500,
html.ink-on.night-glass:not(.dark) .text-blue-600,
html.ink-on.night-glass:not(.dark) .text-blue-700,
html.ink-on.night-glass:not(.dark) .text-blue-800,
html.ink-on.night-glass:not(.dark) .text-indigo-500,
html.ink-on.night-glass:not(.dark) .text-indigo-600 { color: #bcc492 !important; }

/* ---------- 五、墨线 CSS 里的暖纸文字/描边 → 暗夜 ---------- */
html.ink-on.night-glass:not(.dark) .nc-log-panel {
  background: rgba(44, 48, 42, .52);
  border-color: rgba(232, 228, 216, .18);
}
html.ink-on.night-glass:not(.dark) .nc-log-panel-head {
  background: rgba(58, 62, 54, .5);
  border-bottom-color: rgba(232, 228, 216, .12);
}
html.ink-on.night-glass:not(.dark) .nc-log-panel-title,
html.ink-on.night-glass:not(.dark) .nc-log-panel-title h3 { color: #ece8db; }
html.ink-on.night-glass:not(.dark) .nc-log-panel-title p,
html.ink-on.night-glass:not(.dark) .nc-log-time,
html.ink-on.night-glass:not(.dark) .nc-log-empty { color: #a39e8e; }
html.ink-on.night-glass:not(.dark) .nc-log-table { color: #e2ded0; }
html.ink-on.night-glass:not(.dark) .nc-log-table thead th,
html.ink-on.night-glass:not(.dark) .nc-log-table tbody td { border-color: rgba(232, 228, 216, .12); }
html.ink-on.night-glass:not(.dark) .nc-log-msg-text,
html.ink-on.night-glass:not(.dark) .nc-log-event,
html.ink-on.night-glass:not(.dark) .nc-log-col-content { color: #e2ded0; }
html.ink-on.night-glass:not(.dark) .nc-log-tools button,
html.ink-on.night-glass:not(.dark) .nc-log-filter-toggle {
  background: rgba(58, 62, 54, .6);
  border-color: rgba(232, 228, 216, .2);
  color: #c9c4b4;
}
html.ink-on.night-glass:not(.dark) .nc-log-tools button:hover,
html.ink-on.night-glass:not(.dark) .nc-log-filter-toggle:hover {
  background: rgba(78, 82, 74, .65);
  border-color: rgba(232, 228, 216, .3);
}

/* 概览页 ink-card（奶油渐变卡面）→ 暗玻璃 */
html.ink-on.night-glass:not(.dark) .ink-card {
  background: rgba(44, 48, 42, .52) !important;
  border-color: rgba(232, 228, 216, .3);
  color: #ece8db;
}
html.ink-on.night-glass:not(.dark) .ink-card small { color: #a39e8e !important; }

/* 农场切换卡（fs.css 硬编码暖纸）→ 暗玻璃 */
html.ink-on.night-glass:not(.dark) .ink-farm-picker .ink-account {
  background: rgba(44, 48, 42, .55) !important;
  border-color: rgba(232, 228, 216, .28) !important;
}
html.ink-on.night-glass:not(.dark) .ink-farm-panel {
  background: rgba(44, 48, 42, .55) !important;
  border-color: rgba(232, 228, 216, .3) !important;
}
html.ink-on.night-glass:not(.dark) .ink-farm-manage {
  background: rgba(58, 62, 54, .6) !important;
  border-color: rgba(232, 228, 216, .25) !important;
  color: #c9c4b4 !important;
}
html.ink-on.night-glass:not(.dark) .ink-farm-search {
  background: rgba(40, 44, 38, .72) !important;
  border-color: rgba(232, 228, 216, .22) !important;
  color: #ece8db !important;
}
html.ink-on.night-glass:not(.dark) .ink-farm-option {
  background: rgba(52, 56, 50, .6) !important;
  border-color: rgba(232, 228, 216, .2) !important;
  color: #ece8db;
}
html.ink-on.night-glass:not(.dark) .ink-farm-option.is-current {
  background: rgba(111, 118, 81, .3) !important;
  border-color: #bcc492 !important;
}
html.ink-on.night-glass:not(.dark) .ink-farm-hint,
html.ink-on.night-glass:not(.dark) .ink-farm-empty { color: #a39e8e !important; }

/* 「QQ区/未选择分区」胶囊 → 暗玻璃 */
html.ink-on.night-glass:not(.dark) .ink-platform {
  background: rgba(58, 62, 54, .55) !important;
  border-color: rgba(232, 228, 216, .3) !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .3) !important;
  color: #c9c4b4 !important;
}
html.ink-on.night-glass:not(.dark) .ink-platform i { background: #8f9a8a !important; }
html.ink-on.night-glass:not(.dark) .ink-platform.ink-platform-empty {
  background: rgba(58, 62, 54, .55) !important;
  border-color: rgba(232, 228, 216, .35) !important;
}
html.ink-on.night-glass:not(.dark) .ink-platform.ink-platform-empty i { background: #7d8578 !important; }
html.ink-on.night-glass:not(.dark) .ink-level {
  border-color: rgba(232, 228, 216, .3);
  background: rgba(66, 52, 50, .55);
}

/* 自动化卡（r30 硬编码暖纸按钮与小底）→ 暗玻璃 */
html.ink-on.night-glass:not(.dark) .ac-hub button:not(.ac-tab) {
  background: rgba(58, 62, 54, .6) !important;
  border-color: rgba(232, 228, 216, .28) !important;
  color: #ece8db !important;
  box-shadow: none !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub button:not(.ac-tab):hover {
  background: rgba(78, 82, 74, .65) !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub .ac-extras > :not(p) {
  border-color: rgba(232, 228, 216, .18) !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub .ac-extras > .bg-sky-50 { background: rgba(111, 118, 81, .14) !important; }
html.ink-on.night-glass:not(.dark) .ac-hub .ac-extras > .bg-green-50 { background: rgba(111, 118, 81, .16) !important; }
html.ink-on.night-glass:not(.dark) .ac-hub .ac-extras > .bg-purple-50 { background: rgba(140, 100, 150, .14) !important; }
html.ink-on.night-glass:not(.dark) .ac-hub .ac-extras > .bg-amber-50 { background: rgba(212, 160, 70, .14) !important; }
html.ink-on.night-glass:not(.dark) .ac-hub .ac-extras > section[aria-label="自动出售延迟"] { background: rgba(58, 62, 54, .5) !important; }
html.ink-on.night-glass:not(.dark) .ac-tab {
  border-color: rgba(232, 228, 216, .3) !important;
  color: #c9c4b4 !important;
  background: rgba(58, 62, 54, .45) !important;
}
html.ink-on.night-glass:not(.dark) .ac-tab.is-active {
  /* 金豆豆选中态保留：金底深字在暗底上对比充分 */
  border-color: rgba(232, 228, 216, .35) !important;
}

/* 硬编码白底的杂项面板/按钮 */
html.ink-on.night-glass:not(.dark) .account-auto-relogin-field input,
html.ink-on.night-glass:not(.dark) .qty-input,
html.ink-on.night-glass:not(.dark) .dashboard-section-nav-item,
html.ink-on.night-glass:not(.dark) .nc-overview-account-card .nc-dash-progress span,
html.ink-on.night-glass:not(.dark) .announcement-panel .farm-btn,
html.ink-on.night-glass:not(.dark) .nc-console-tab-active .nc-console-tab-badge,
html.ink-on.night-glass:not(.dark) .auth-card-badge,
html.ink-on.night-glass:not(.dark) .auth-card-meta-item {
  background: rgba(52, 56, 50, .6) !important;
}
html.ink-on.night-glass:not(.dark) .auth-panel .base-input {
  background: rgba(40, 44, 38, .72) !important;
  border-color: rgba(232, 228, 216, .25) !important;
  color: #ece8db !important;
}
html.ink-on.night-glass:not(.dark) .account-auto-relogin-close,
html.ink-on.night-glass:not(.dark) .account-auto-relogin-header h2,
html.ink-on.night-glass:not(.dark) .account-auto-relogin-retry,
html.ink-on.night-glass:not(.dark) .account-auto-relogin-status,
html.ink-on.night-glass:not(.dark) .claim-modal-icon,
html.ink-on.night-glass:not(.dark) .user-menu-links { color: #bcc492 !important; }
html.ink-on.night-glass:not(.dark) .account-auto-relogin-cancel {
  background: rgba(58, 62, 54, .6) !important;
  color: #ece8db !important;
  border-color: rgba(232, 228, 216, .25) !important;
}

/* 主按钮（墨绿渐变 + 白字）在暗底上原样成立，无需改动；
   焦点描边提亮一档 */
html.ink-on.night-glass:not(.dark) .focus\:ring-blue-500:focus,
html.ink-on.night-glass:not(.dark) .focus\:ring-blue-400:focus { --tw-ring-color: rgba(168, 176, 127, .45) !important; }
html.ink-on.night-glass:not(.dark) .account-auto-relogin-dialog :focus-visible,
html.ink-on.night-glass:not(.dark) .account-auto-relogin-trigger:focus-visible { outline-color: #bcc492 !important; }

/* ---------- 六、文字对比度强化（v2 · 2026-11-09） ----------
 * 教训：卡片作用域变量（.nc-overview-account-card[data-v] 把 --color-text
 * 改回深蓝）+ Tailwind text-gray-* 工具类 + 懒加载路由 css 注入在后，
 * 三者都会让暗底上残留深色文字。故本段全部带 !important。 */

/* 6.1 语义状态色提亮（在线/警告/错误在暗底上的可读版本） */
html.ink-on.night-glass:not(.dark),
html.ink-on.night-glass:not(.dark) .ink-overview {
  --color-success: #8fce7f !important;
  --color-success-muted: rgba(143, 206, 127, .16) !important;
  --color-warn: #e5b566 !important;
  --color-danger: #e08a80 !important;
  --color-danger-muted: rgba(224, 138, 128, .16) !important;
}

/* 6.2 账号大卡：data-v 作用域变量翻白（原本写死深蓝 #172b4d） */
html.ink-on.night-glass:not(.dark) .nc-overview-account-card {
  --color-text: #ece8db !important;
  --color-text-muted: #a39e8e !important;
  --color-muted-foreground: #a39e8e !important;
  --color-surface: rgba(44, 48, 42, .55) !important;
  --color-bg-muted: rgba(58, 62, 54, .5) !important;
  border-color: rgba(232, 228, 216, .2) !important;
}
html.ink-on.night-glass:not(.dark) .nc-overview-account-card .account-quick-switcher,
html.ink-on.night-glass:not(.dark) .account-quick-switcher {
  --color-surface: rgba(52, 56, 50, .7) !important;
  --color-bg-muted: rgba(66, 70, 62, .5) !important;
  --color-text: #ece8db !important;
  --color-text-muted: #c9c4b4 !important;
  --color-muted-foreground: #a39e8e !important;
  --color-accent: #bcc492 !important;
  --color-accent-muted: rgba(168, 176, 127, .18) !important;
  --color-border: rgba(232, 228, 216, .25) !important;
  --color-border-subtle: rgba(232, 228, 216, .16) !important;
}

/* 6.3 Tailwind 文字工具类全系扫覆盖（黑系 → 暖白阶梯） */
html.ink-on.night-glass:not(.dark) .text-black,
html.ink-on.night-glass:not(.dark) .text-gray-900,
html.ink-on.night-glass:not(.dark) .text-gray-800 { color: #f2eee2 !important; }
html.ink-on.night-glass:not(.dark) .text-gray-700 { color: #e2ded0 !important; }
html.ink-on.night-glass:not(.dark) .text-gray-600 { color: #c9c4b4 !important; }
html.ink-on.night-glass:not(.dark) .text-gray-500 { color: #a39e8e !important; }
html.ink-on.night-glass:not(.dark) .text-gray-400 { color: #8f8a7c !important; }
html.ink-on.night-glass:not(.dark) .text-gray-300 { color: #7d7868 !important; }
html.ink-on.night-glass:not(.dark) .text-slate-900,
html.ink-on.night-glass:not(.dark) .text-slate-800,
html.ink-on.night-glass:not(.dark) .text-slate-700 { color: #e2ded0 !important; }
html.ink-on.night-glass:not(.dark) .text-slate-600,
html.ink-on.night-glass:not(.dark) .text-slate-500 { color: #a39e8e !important; }

/* 6.4 Dashboard 组件专项 */
html.ink-on.night-glass:not(.dark) .dashboard-brand strong { color: #ece8db !important; }
html.ink-on.night-glass:not(.dark) .dashboard-page { color: #ece8db !important; }
html.ink-on.night-glass:not(.dark) .dashboard-section-nav-item {
  background: rgba(58, 62, 54, .55) !important;
  border-color: rgba(232, 228, 216, .25) !important;
  color: #c9c4b4 !important;
}
html.ink-on.night-glass:not(.dark) .dashboard-section-nav-item:hover {
  border-color: #bcc492 !important;
  background: rgba(168, 176, 127, .18) !important;
  color: #e6ead4 !important;
}
html.ink-on.night-glass:not(.dark) .dashboard-section-nav-item.is-active {
  background: linear-gradient(125deg, #8b9467, #6f7651) !important;
  border-color: rgba(232, 228, 216, .35) !important;
  color: #fffdf8 !important;
}
html.ink-on.night-glass:not(.dark) .nc-dash-badge,
html.ink-on.night-glass:not(.dark) .nc-dash-progress { background: rgba(66, 70, 62, .55) !important; }
html.ink-on.night-glass:not(.dark) .nc-dash-progress span { background: #a8b07f !important; }
html.ink-on.night-glass:not(.dark) .nc-overview-op-row span:not(.nc-op-icon) { color: #e2ded0 !important; }

/* 6.5 运行日志标题等：加 !important 防懒加载 css 后注入反杀 */
html.ink-on.night-glass:not(.dark) .nc-log-panel-title,
html.ink-on.night-glass:not(.dark) .nc-log-panel-title h3 { color: #ece8db !important; }
html.ink-on.night-glass:not(.dark) .nc-log-panel-title p,
html.ink-on.night-glass:not(.dark) .nc-log-time,
html.ink-on.night-glass:not(.dark) .nc-log-empty { color: #a39e8e !important; }
html.ink-on.night-glass:not(.dark) .nc-log-msg-text,
html.ink-on.night-glass:not(.dark) .nc-log-event,
html.ink-on.night-glass:not(.dark) .nc-log-col-content,
html.ink-on.night-glass:not(.dark) .nc-log-table { color: #e2ded0 !important; }
html.ink-on.night-glass:not(.dark) .nc-log-panel { border-color: rgba(232, 228, 216, .18) !important; }
html.ink-on.night-glass:not(.dark) .nc-log-panel-head { border-bottom-color: rgba(232, 228, 216, .12) !important; }

/* ---------- 七、浅色粉彩面上的文字回深（v3 · 2026-11-09） ----------
 * 问题：night 版把 .ink-card 文字统一翻暖白，但资产四行、用品四宫格、
 * 累计两栏保留了奶油粉彩底（linear-gradient 背景图）。自动引擎把
 * "有背景图的面"视为设计意图而跳过 → 白字压浅底，几乎看不见。
 * 做法：这些面带背景图的小块本身不动（彩色小块在暗底上好看），
 * 只把其内部文字按奶油主题的深色阶梯压回去。 */

/* 7.1 资产四行：金豆 / 点券 / 豆子 / 钻石 */
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-asset,
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-asset>strong,
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-asset-name {
  color: #383c30 !important;
}
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-asset small { color: #6b6555 !important; }
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-asset .ink-gain { color: #6b7a3f !important; }
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-asset .ink-icon-unavailable { color: #8b8677 !important; }

/* 7.2 用品四宫格：有机化肥 / 种子 / 道具 / 续费 */
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-tile,
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-tile>span,
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-tile>strong { color: #383c30 !important; }
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-tile>small { color: #6b6555 !important; }

/* 7.3 累计两栏：历史累计收获 / 卡密倒计时 */
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-lifetime>div,
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-lifetime strong { color: #383c30 !important; }
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-lifetime small { color: #6b6555 !important; }
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-license:has([data-state="expired"]) strong,
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-license:has([data-state="disabled"]) strong {
  color: #a3493e !important;
}

/* 7.4 今日统计行（半透奶油小底，同样压深字） */
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-statistics-row,
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-statistics-row>span,
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-statistics-row strong { color: #383c30 !important; }

/* 7.5 等级圆牌在 night 版已翻暗（rgba(66,52,50,.55)）→ 字反过来提亮 */
html.ink-on.night-glass:not(.dark) .ink-dashboard .ink-level { color: #e8a49a !important; }

/* ---------- 八、自动化页（.ac-hub）暗玻璃化（v4 · 2026-11-09） ----------
 * 问题：.ac-hub 是页面自带的奶油渐变卡（background-image），夜间的
 * 卡片/文字规则都没覆盖它 → 卡面仍是奶油底，而夜间把按钮、输入框、
 * 说明文字全翻成了浅色 → 白字压奶油，几乎看不清，也没有玻璃质感。
 * 做法：把这张卡按暗玻璃重做（半透深灰 + blur + 浅描边），内部
 * 文字/输入框/开关/标签一并翻暗夜版；tab 选中态保留金豆豆奶油金。 */

/* 8.1 控制台外壳透明，让暗色光斑透上来
 * 实测：该路由页面底仍是 #F6EDDF（奶油），说明外壳某层把底色压住了。
 * 三道保险：① html/body 加 !important（原规则没有，会被内联或别处赢掉）
 *          ② div 级祖先（:has(.ac-hub)）一律透明——不依赖具体类名
 *          ③ 已知外壳类一并透明 */
html.ink-on.night-glass:not(.dark) {
  background: #20241c !important;
}
html.ink-on.night-glass:not(.dark) body {
  background: #20241c !important;
}
html.ink-on.night-glass:not(.dark) div:has(.ac-hub),
html.ink-on.night-glass:not(.dark) .app-root,
html.ink-on.night-glass:not(.dark) .nc-console,
html.ink-on.night-glass:not(.dark) .nc-console-panel,
html.ink-on.night-glass:not(.dark) .nc-console-body,
html.ink-on.night-glass:not(.dark) .nc-console-content,
html.ink-on.night-glass:not(.dark) .nc-console-main,
html.ink-on.night-glass:not(.dark) .automation-cat-root {
  background: transparent !important;
}

/* 8.2 自动化大卡 → 暗玻璃 */
html.ink-on.night-glass:not(.dark) .ac-hub {
  background: rgba(44, 48, 42, .52) !important;
  border-color: rgba(232, 228, 216, .22) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .14),
    0 10px 30px rgba(0, 0, 0, .32) !important;
  -webkit-backdrop-filter: blur(28px) saturate(1.6);
  backdrop-filter: blur(28px) saturate(1.6);
  color: #e2ded0 !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub-title { color: #ece8db !important; }
html.ink-on.night-glass:not(.dark) .ac-hub-hint { color: #a39e8e !important; }

/* 8.3 卡内分段标签 */
html.ink-on.night-glass:not(.dark) .ac-hub .ac-tabs {
  background: rgba(52, 56, 50, .55) !important;
  border-color: rgba(232, 228, 216, .18) !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub .ac-tab {
  background: rgba(58, 62, 54, .4) !important;
  border-color: rgba(232, 228, 216, .22) !important;
  color: #c9c4b4 !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub .ac-tab:hover:not(.is-active) {
  background: rgba(70, 74, 66, .55) !important;
  border-color: rgba(232, 228, 216, .3) !important;
  color: #e6ead4 !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub .ac-tab.is-active {
  background: linear-gradient(110deg, #fce4bc, #fae9cc) !important;
  border-color: rgba(232, 228, 216, .38) !important;
  color: #4a4030 !important;
  font-weight: 650;
  box-shadow: inset 0 0 0 1px rgba(54, 59, 46, .5) !important;
}

/* 8.4 开关轨道：关态深玻璃，开态保留奶油金 + 橙块 */
html.ink-on.night-glass:not(.dark) .ac-hub .base-switch {
  background: rgba(58, 62, 54, .75) !important;
  border: 1.5px solid rgba(232, 228, 216, .28) !important;
  box-shadow: inset 0 0 0 2px rgba(0, 0, 0, .18) !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub input:checked ~ .base-switch,
html.ink-on.night-glass:not(.dark) .ac-hub input:checked + .base-switch {
  background: linear-gradient(110deg, #fce4bc, #fae9cc) !important;
  border: 1.5px solid rgba(232, 228, 216, .35) !important;
}

/* 8.5 输入框 / 数字框 / 下拉：暗玻璃底 + 暖白字 */
html.ink-on.night-glass:not(.dark) .ac-hub input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
html.ink-on.night-glass:not(.dark) .ac-hub textarea,
html.ink-on.night-glass:not(.dark) .ac-hub select {
  background: rgba(40, 44, 38, .72) !important;
  border-color: rgba(232, 228, 216, .22) !important;
  color: #ece8db !important;
}
html.ink-on.night-glass:not(.dark) .ac-hub input::placeholder { color: #8f8a7c !important; }

/* 8.6 说明段落与开关旁边的文字 */
html.ink-on.night-glass:not(.dark) .ac-hub p,
html.ink-on.night-glass:not(.dark) .ac-hub label,
html.ink-on.night-glass:not(.dark) .ac-hub .automation-feature-proxy-control { color: #c9c4b4 !important; }

/* 8.7 底部导航 → 暗玻璃 */
html.ink-on.night-glass:not(.dark) .nc-mobile-tabbar {
  background: rgba(44, 48, 42, .62) !important;
  border-color: rgba(232, 228, 216, .2) !important;
  -webkit-backdrop-filter: blur(24px) saturate(1.6);
  backdrop-filter: blur(24px) saturate(1.6);
}

/* ---------- 九、打印降级 ---------- */
@media print {
  html.ink-on.night-glass:not(.dark) body::before { display: none; }
}
