/* ============================================================
   Candy Theme — CSS 变量回退默认值
   ============================================================
   本文件仅定义 theme_generate_css() 不输出的附加变量。
   后台已生成的变量（--gold / --ink / --bg-soft / --line 等）
   在 theme-vars.css 中定义，遵循 "后台优先" 原则。
   ============================================================ */
:root {
  /* ---- 附加品牌色（theme_generate_css 未覆盖） ---- */
  --ink-soft:     #33332f;
  --gold-deep:    #92400e;
  --gold-tint:    #fde68a;
  --gold-bg:      #fffbeb;
  --wechat-green: #07c160;   /* 微信品牌绿（登录页微信扫码/快捷登录） */

  /* ---- 附加边框色 ---- */
  --line-2:       #c4b6a6;
  --line-3:       #d4c8ba;

  /* ---- 语义色 ---- */
  --success:      #16a34a;
  --warning:      #d97706;
  --danger:       #dc2626;
  --info:         #2563eb;

  /* ---- 强调色上的反白文字（accent 页脚/按钮，守禁六不写死白） ---- */
  --on-accent:       rgba(255,255,255,.92);
  --on-accent-soft:  rgba(255,255,255,.72);
  --on-accent-line:  rgba(255,255,255,.25);

  /* ---- RGB 变量（用于 rgba） ---- */
  --ink-rgb:      28,27,25;
  --gold-rgb:     169,133,74;

  /* ---- 过渡 ---- */
  --transition:   .25s cubic-bezier(.2,.8,.2,1);
  --transition-fast: .15s;
  --transition-slow: .4s;
}

/* ===== 外来 token 桥接（2026-07-11 内容页视觉对齐前置）
   内容页 CSS（article/album/dynasty/encyclopedia/library/social/timeline/index/design-system/
   filter_topbar/nav/page_layout）引用了 20 个另一套设计系统的词汇（Bootstrap/Tailwind 风），
   candy 从未定义过，导致 27+ 处无兜底引用回退默认色（已坏）。此处桥接为 candy 语义别名，
   零视觉风险、守禁六不写死，使内容页被 candy 设计系统驱动。属"补 token 定义"，非新函数/接口。
   注：--accent 已在 design-system.css:9 定义为 var(--hx-a9854a)（=暖金），此处不重复定义（守禁四）。 ===== */
:root {
  /* 文字 */
  --color-text-muted:    var(--muted);          /* 次要/元信息文字 → candy 暖灰 */
  --c-text-1:            var(--ink);            /* 主文字 */
  --c-text-2:            var(--muted);          /* 次文字 */
  --ink-700:             var(--ink-soft);       /* 中深墨 */
  --line-height:         1.7;                   /* 正文行高 */

  /* 表面 / 卡片 */
  --surface:             var(--bg);             /* 纯白表面 */
  --surface-2:           var(--bg-soft);        /* 次表面（米白） */
  --card-bg:             var(--bg-soft);        /* 卡片底 */
  --color-bg-tertiary:   var(--bg-soft);        /* 三级底 */

  /* 边框 */
  --border-color:        var(--line);           /* 主边框（墨黑 9%） */
  --color-border-light:  var(--line-3);         /* 浅边框 */

  /* 文字（补缺：album.css/social.css/nav.css 用但未定义 */
  --color-text:          var(--ink);            /* 主文字（别名为 candy --ink） */
  --gray-200:            var(--bg-soft);        /* nav.css 弱背景 #E8E8E8 → candy 米白 */
  --gray-400:            var(--faint);          /* nav.css 浅文字 #BFBFBF → candy 最浅灰 */
  --accent-bg:           var(--gold-soft);      /* nav.css 强调背景 #F5F0E8 → candy 暖金柔 */

  /* 强调（暖金体系） */
  --cc:                  var(--gold);
  --bh-color:            var(--gold);
  --dot-color:           var(--gold);
  --accent-soft:         color-mix(in srgb, var(--gold) 14%, transparent);
  --accent-weak:         color-mix(in srgb, var(--gold) 9%, transparent);
  --color-primary-light: color-mix(in srgb, var(--gold) 16%, var(--hx-ffffff));
  --c-primary-light:     color-mix(in srgb, var(--gold) 16%, var(--hx-ffffff));

  /* 尺寸 */
  --spacing-xxl:         44px;
  --button-radius:       var(--radius);
}

/* ===== 裸 hex 迁移 token（2026-07-11 全量迁移 pages/ 14 文件，精确保色，零视觉偏差） ===== */
:root {
  --hx-667eea: #667eea;
  --hx-764ba2: #764ba2;
  --hx-ffffff: #ffffff;
  --hx-f0f0f0: #f0f0f0;
  --hx-1a1a2e: #1a1a2e;
  --hx-888888: #888888;
  --hx-999999: #999999;
  --hx-666666: #666666;
  --hx-333333: #333333;
  --hx-f5f5f5: #f5f5f5;
  --hx-555555: #555555;
  --hx-e0e0e0: #e0e0e0;
  --hx-dddddd: #dddddd;
  --hx-f8f9ff: #f8f9ff;
  --hx-1a1a1a: #1a1a1a;
  --hx-ff2442: #ff2442;
  --hx-e5e0d6: #e5e0d6;
  --hx-222222: #222222;
  --hx-111111: #111111;
  --hx-faf8f5: #faf8f5;
  --hx-e53935: #e53935;
  --hx-ff9800: #ff9800;
  --hx-e0d8cc: #e0d8cc;
  --hx-f0ece6: #f0ece6;
  --hx-fafaf6: #fafaf6;
  --hx-aaaaaa: #aaaaaa;
  --hx-7a2c00: #7a2c00;
  --hx-e8e8e8: #e8e8e8;
  --hx-eeeeee: #eeeeee;
  --hx-fef9f5: #fef9f5;
  --hx-f0ddd0: #f0ddd0;
  --hx-f5f2ed: #f5f2ed;
  --hx-f5f0eb: #f5f0eb;
  --hx-e8ddd0: #e8ddd0;
  --hx-444444: #444444;
  --hx-fafafa: #fafafa;
  --hx-e8e0d4: #e8e0d4;
  --hx-c0b8a8: #c0b8a8;
  --hx-c45537: #c45537;
  --hx-cccccc: #cccccc;
  --hx-fff5f0: #fff5f0;
  --hx-a8482e: #a8482e;
  --hx-f0f0ea: #f0f0ea;
  --hx-e8e8e0: #e8e8e0;
  --hx-bbbbbb: #bbbbbb;
  --hx-1677ff: #1677ff;
  --hx-f0f7ff: #f0f7ff;
  --hx-f5a623: #f5a623;
  --hx-fef9f0: #fef9f0;
  --hx-f5f5f0: #f5f5f0;
  --hx-a8452e: #a8452e;
  --hx-4a90d9: #4a90d9;
  --hx-3a7bc0: #3a7bc0;
  --hx-6ec6ff: #6ec6ff;
  --hx-ffd666: #ffd666;
  --hx-a9854a: #a9854a;
  --hx-4d4d4d: #4d4d4d;
  --hx-000000: #000000;
  --hx-f5f0e8: #f5f0e8;
  --hx-10b981: #10b981;
  --hx-34d399: #34d399;
  --hx-059669: #059669;
  --hx-d9d9d9: #d9d9d9;
  --hx-bfbfbf: #bfbfbf;
  --hx-f59e0b: #f59e0b;
  --hx-ef4444: #ef4444;
  --hx-3b82f6: #3b82f6;
  --hx-cd7f32: #cd7f32;
  --hx-c0c0c0: #c0c0c0;
  --hx-ffd700: #ffd700;
  --hx-b9f2ff: #b9f2ff;
  --hx-d4a574: #d4a574;
  --hx-2a1a0e: #2a1a0e;
  --hx-2d2d2d: #2d2d2d;
  --hx-404040: #404040;
  --hx-6b6b6b: #6b6b6b;
  --hx-dc2626: #dc2626;
  --hx-d1fae5: #d1fae5;
  --hx-fef3c7: #fef3c7;
  --hx-fee2e2: #fee2e2;
  --hx-f3f4f6: #f3f4f6;
  --hx-ecfeff: #ecfeff;
  --hx-06b6d4: #06b6d4;
  --hx-c97638: #c97638;
  --hx-f8f8f8: #f8f8f8;
  --hx-e5e5e5: #e5e5e5;
  --hx-e8e2d8: #e8e2d8;
  --hx-f0ece4: #f0ece4;
  --hx-3d3428: #3d3428;
  --hx-7a7066: #7a7066;
  --hx-4a1a08: #4a1a08;
  --hx-6b2c10: #6b2c10;
  --hx-8b3d18: #8b3d18;
  --hx-9e4a22: #9e4a22;
  --hx-a85a30: #a85a30;
  --hx-b86a3a: #b86a3a;
  --hx-c4762e: #c4762e;
  --hx-fdfbf7: #fdfbf7;
  --hx-f8f4ec: #f8f4ec;
  --hx-efe9e0: #efe9e0;
  --hx-fef3e8: #fef3e8;
  --hx-fdfcf9: #fdfcf9;
  --hx-2e7d6b: #2e7d6b;
  --hx-f0f6f3: #f0f6f3;
  --hx-eef6f1: #eef6f1;
  --hx-eef3f8: #eef3f8;
  --hx-e0e9f2: #e0e9f2;
  --hx-c8b99a: #c8b99a;
  --hx-a02818: #a02818;
  --hx-f8f6f3: #f8f6f3;
  --hx-1b6b4a: #1b6b4a;
  --hx-f0f8f4: #f0f8f4;
  --hx-faf6ee: #faf6ee;
  --hx-e5dfd0: #e5dfd0;
  --hx-2c2418: #2c2418;
  --hx-a89b87: #a89b87;
  --hx-6b6254: #6b6254;
  --hx-f0ebe0: #f0ebe0;
  --hx-fff3cd: #fff3cd;
  --hx-856404: #856404;
  --hx-e53e3e: #e53e3e;
  --hx-e8dcc8: #e8dcc8;
  --hx-c9b896: #c9b896;
  --hx-6b5d4a: #6b5d4a;
  --hx-fefce8: #fefce8;
  --hx-e8e3c5: #e8e3c5;
  --hx-b8a88a: #b8a88a;
  --hx-3d2e1e: #3d2e1e;
  --hx-e8e0d8: #e8e0d8;
  --hx-1565c0: #1565c0;
  --hx-f39c12: #f39c12;
  --hx-f7ba2a: #f7ba2a;
  --hx-ff6b6b: #ff6b6b;
  --hx-ee5a24: #ee5a24;
  --hx-ff4d4f: #ff4d4f;
  --hx-fff1f0: #fff1f0;
  --hx-fafbfc: #fafbfc;
  --hx-1890ff: #1890ff;
  --hx-e6f7ff: #e6f7ff;
  --hx-fa8c16: #fa8c16;
  --hx-fff7e6: #fff7e6;
  --hx-3a2e22: #3a2e22;
  --hx-c9a87a: #c9a87a;
  --hx-f9f7f3: #f9f7f3;
  --hx-ebe5dc: #ebe5dc;
  --hx-f3ede4: #f3ede4;
  --hx-d8cfc0: #d8cfc0;
  --hx-5a4636: #5a4636;
  --hx-efe9e1: #efe9e1;
  --hx-fdf6ec: #fdf6ec;
  --hx-f0dcc8: #f0dcc8;
  --hx-777777: #777777;
  --hx-b8945e: #b8945e;
  --hx-f8f5f0: #f8f5f0;
  --hx-ddd5c8: #ddd5c8;
  --hx-f8f5ef: #f8f5ef;
  --hx-c4a882: #c4a882;
  --hx-e8ecf4: #e8ecf4;
  --hx-eef2ff: #eef2ff;
  --hx-913300: #913300;
  --hx-c4956a: #c4956a;
  --hx-eee5d9: #eee5d9;
  --hx-f0ebe4: #f0ebe4;
  --hx-fffcf7: #fffcf7;
  --hx-e8e0d0: #e8e0d0;
  --hx-fcfbfa: #fcfbfa;
  --hx-d8d4c8: #d8d4c8;
  --hx-f5f0ea: #f5f0ea;
  --hx-faf8f3: #faf8f3;
  --hx-c47a3d: #c47a3d;
  --hx-ffc069: #ffc069;
  --hx-ad6800: #ad6800;
  --hx-91d5ff: #91d5ff;
  --hx-096dd9: #096dd9;
  --hx-7a2900: #7a2900;
  --hx-7a2a00: #7a2a00;
  --hx-cc3333: #cc3333;
  --hx-cc9999: #cc9999;
  --hx-fff8f0: #fff8f0;
  --hx-f7f4ef: #f7f4ef;
  --hx-d9d2c8: #d9d2c8;
  --hx-7a2b00: #7a2b00;
  --hx-f0ece5: #f0ece5;
  --hx-fff7f0: #fff7f0;
  --hx-f0d9c0: #f0d9c0;
  --hx-ffe8d6: #ffe8d6;
  --hx-fffbf7: #fffbf7;
  --hx-52c41a: #52c41a;
  --hx-f6ffed: #f6ffed;

  /* navbar.css 裸 hex 迁移 token（2026-07-11） */
  --hx-639922: #639922;
  --hx-D4537E: #d4537e;
  --hx-A32D6F: #a32d6f;
  --hx-FFF9E6: #fff9e6;
  --hx-FEF3CD: #fef3cd;
  --hx-FDE8B0: #fde8b0;
  --hx-8A6D20: #8a6d20;
  --hx-FDD56B: #fdd56b;
  --hx-E6A23C: #e6a23c;
  --hx-C44900: #c44900;
  --hx-A33D00: #a33d00;
  --hx-F8F9FA: #f8f9fa;
  --hx-E9ECEF: #e9ecef;
  --hx-DEE2E6: #dee2e6;
  --hx-5A6268: #5a6268;
  --hx-CED4DA: #ced4da;

  --hx-333: #333;
  --hx-666: #666;
  --hx-999: #999;
  --hx-a0a0a0: #a0a0a0;
  --hx-e0d4c4: #e0d4c4;
  --hx-e74c3c: #e74c3c;
  --hx-eee: #eee;
  --hx-f0e8dc: #f0e8dc;
  --hx-f8f9fa: #f8f9fa;
  --hx-fff: #fff;
}
