/*!
 * tokens-bridge.css — 自动生成，禁止手改。
 * 源文件：src/tokens.css（终末地 endfield 浅/深两块）
 * 生成器：tools/gen_flarum_tokens.py
 * 作用：把 cathi-ui 的 --cathi-* token 编译为 Flarum 原生变量覆盖，
 *       根治 --primary-color 柠檬黄 (#fffa00) 与 cathi-ui chartreuse 的漂移。
 * 应用：由 extend.php 在 endfield.css 之后注入本文件（独立 <link>），不改动 forum.css。
 */

:root {
/* 浅色（覆盖 forum.css :root） */
  --primary-color: hsl(68 95% 36%) !important;
  --secondary-color: hsl(68 85% 22%) !important;
  --accent-color: hsl(68 95% 36%) !important;
  --danger-color: hsl(0 72% 50%) !important;
  --body-bg: hsl(220 14% 94%) !important;
  --body-bg-light: hsl(0 0% 100%) !important;
  --body-bg-shaded: hsl(220 16% 91%) !important;
  --body-bg-faded: hsl(220 14% 94% / .94) !important;
  --body-bg-fade-70: hsl(220 14% 94% / .70) !important;
  --text-color: hsl(220 22% 12%) !important;
  --text-color-fade-70: hsl(220 22% 12% / .70) !important;
  --heading-color: hsl(220 22% 12%) !important;
  --muted-color: hsl(220 12% 42%) !important;
  --muted-color-light: hsl(220 12% 42%) !important;
  --muted-color-dark: hsl(220 22% 12%) !important;
  --link-color: hsl(68 95% 36%) !important;
  --discussion-title-color: hsl(220 22% 12%) !important;
  --control-bg: hsl(0 0% 100%) !important;
  --control-bg-light: hsl(0 0% 100%) !important;
  --control-bg-shaded: hsl(220 16% 91%) !important;
  --control-bg-darken-5: hsl(220 16% 91%) !important;
  --control-bg-darken-10: hsl(220 16% 89%) !important;
  --control-color: hsl(220 22% 12%) !important;
  --control-muted-color: hsl(220 12% 42%) !important;
  --form-control-bg: hsl(220 16% 96%) !important;
  --form-control-color: hsl(220 22% 12%) !important;
  --button-bg: hsl(0 0% 100%) !important;
  --button-color: hsl(220 22% 12%) !important;
  --button-primary-bg: hsl(68 95% 36%) !important;
  --button-primary-color: hsl(0 0% 100%) !important;
  --on-primary-color: hsl(0 0% 100%) !important;
  --header-bg: hsl(220 8% 11%) !important;
  --header-color: #ffffff !important;
  --header-control-bg: hsl(220 8% 14%) !important;
  --header-control-color: #ffffff !important;
  --hero-bg: hsl(220 8% 11%) !important;
  --hero-color: #ffffff !important;
  --usercard-bg: hsl(0 0% 100%) !important;
  --code-bg: hsl(220 10% 12%) !important;
  --code-color: hsl(68 95% 36%) !important;
  --tag-bg: hsl(68 95% 36%) !important;
  --tag-color: hsl(0 0% 100%) !important;
  --pill-bg: hsl(220 16% 91%) !important;
  --overlay-bg: rgba(12,12,12,.55) !important;
  --tooltip-bg: hsl(68 95% 36%) !important;
  --tooltip-color: hsl(0 0% 100%) !important;
  --alert-bg: hsl(220 16% 91%) !important;
  --alert-color: hsl(220 22% 12%) !important;
  --alert-success-bg: hsl(145 45% 38% / .16) !important;
  --alert-success-color: hsl(0 0% 100%) !important;
  --alert-error-bg: hsl(0 72% 50% / .14) !important;
  --alert-error-color: hsl(0 0% 100%) !important;
  --discussion-list-item-bg-hover: hsl(220 16% 89%) !important;
  --shadow-color: hsl(220 20% 20% / .18) !important;
  --shadow-color-darken-5: hsl(220 20% 20% / .25) !important;
  --border-radius: 3px !important;
  --border-radius-rounded: 6px !important;
  --border-radius-circle: 999px !important;
  --highlight-color: hsl(68 95% 36% / .45) !important;
  --loading-indicator-color: hsl(68 95% 36%) !important;
  --online-user-circle-color: hsl(68 95% 36%) !important;
  --switch-on-color: hsl(68 95% 36%) !important;
  --switch-off-color: hsl(220 16% 91%) !important;
  /* cathi tokens export for components-bridge */
  --cathi-card: 0 0% 100% !important;
  --cathi-muted: 220 16% 91% !important;
  --cathi-field: 220 16% 96% !important;
  --cathi-field-2: 220 16% 85% !important;
  --cathi-background: 220 14% 94% !important;
  --cathi-foreground: 220 22% 12% !important;
  --cathi-primary: 68 95% 36% !important;
  --cathi-primary-active: 68 95% 28% !important;
  --cathi-primary-foreground: 0 0% 100% !important;
  --cathi-secondary: 220 16% 89% !important;
  --cathi-line: 220 16% 78% !important;
  --cathi-accent-line: 68 90% 36% !important;
  --cathi-border: 220 14% 76% !important;
  --cathi-input: 220 16% 80% !important;
  --cathi-ring: 68 95% 40% !important;
  --cathi-radius: .25rem !important;
  --cathi-r-sm: .25rem !important;
  --cathi-r-md: .35rem !important;
}

[data-theme^="dark"] {
/* 深色（覆盖 forum.css [data-theme^="dark"]) */
  --primary-color: hsl(68 100% 48%) !important;
  --secondary-color: hsl(0 0% 90%) !important;
  --accent-color: hsl(68 100% 48%) !important;
  --danger-color: hsl(0 72% 56%) !important;
  --body-bg: hsl(220 5% 8%) !important;
  --body-bg-light: hsl(220 6% 12%) !important;
  --body-bg-shaded: hsl(220 6% 15%) !important;
  --body-bg-faded: hsl(220 5% 8% / .94) !important;
  --body-bg-fade-70: hsl(220 5% 8% / .70) !important;
  --text-color: hsl(0 0% 95%) !important;
  --text-color-fade-70: hsl(0 0% 95% / .70) !important;
  --heading-color: hsl(0 0% 95%) !important;
  --muted-color: hsl(214 8% 66%) !important;
  --muted-color-light: hsl(214 8% 66%) !important;
  --muted-color-dark: hsl(0 0% 95%) !important;
  --link-color: hsl(68 100% 48%) !important;
  --discussion-title-color: hsl(0 0% 95%) !important;
  --control-bg: hsl(220 6% 12%) !important;
  --control-bg-light: hsl(220 6% 12%) !important;
  --control-bg-shaded: hsl(220 6% 15%) !important;
  --control-bg-darken-5: hsl(220 6% 15%) !important;
  --control-bg-darken-10: hsl(220 6% 16%) !important;
  --control-color: hsl(0 0% 95%) !important;
  --control-muted-color: hsl(214 8% 66%) !important;
  --form-control-bg: hsl(220 12% 11%) !important;
  --form-control-color: hsl(0 0% 92%) !important;
  --button-bg: hsl(220 6% 12%) !important;
  --button-color: hsl(0 0% 95%) !important;
  --button-primary-bg: hsl(68 100% 48%) !important;
  --button-primary-color: hsl(26 35% 8%) !important;
  --on-primary-color: hsl(26 35% 8%) !important;
  --header-bg: hsl(0 0% 0%) !important;
  --header-color: #ffffff !important;
  --header-control-bg: hsl(0 0% 0%) !important;
  --header-control-color: #ffffff !important;
  --hero-bg: hsl(0 0% 0%) !important;
  --hero-color: #ffffff !important;
  --usercard-bg: hsl(220 6% 12%) !important;
  --code-bg: hsl(0 0% 0%) !important;
  --code-color: hsl(68 100% 48%) !important;
  --tag-bg: hsl(68 100% 48%) !important;
  --tag-color: hsl(26 35% 8%) !important;
  --pill-bg: hsl(220 6% 15%) !important;
  --overlay-bg: rgba(0,0,0,.7) !important;
  --tooltip-bg: hsl(68 100% 48%) !important;
  --tooltip-color: hsl(26 35% 8%) !important;
  --alert-bg: hsl(220 6% 15%) !important;
  --alert-color: hsl(0 0% 95%) !important;
  --alert-success-bg: hsl(145 45% 50% / .16) !important;
  --alert-success-color: hsl(145 60% 10%) !important;
  --alert-error-bg: hsl(0 72% 56% / .14) !important;
  --alert-error-color: hsl(0 0% 98%) !important;
  --discussion-list-item-bg-hover: hsl(220 6% 16%) !important;
  --shadow-color: hsl(0 0% 0% / .18) !important;
  --shadow-color-darken-5: hsl(0 0% 0% / .25) !important;
  --border-radius: 3px !important;
  --border-radius-rounded: 6px !important;
  --border-radius-circle: 999px !important;
  --highlight-color: hsl(68 100% 48% / .45) !important;
  --loading-indicator-color: hsl(68 100% 48%) !important;
  --online-user-circle-color: hsl(68 100% 48%) !important;
  --switch-on-color: hsl(68 100% 48%) !important;
  --switch-off-color: hsl(220 6% 15%) !important;
  /* cathi tokens export for components-bridge */
  --cathi-card: 220 6% 12% !important;
  --cathi-muted: 220 6% 15% !important;
  --cathi-field: 220 12% 11% !important;
  --cathi-field-2: 220 12% 20% !important;
  --cathi-background: 220 5% 8% !important;
  --cathi-foreground: 0 0% 95% !important;
  --cathi-primary: 68 100% 48% !important;
  --cathi-primary-active: 68 100% 38% !important;
  --cathi-primary-foreground: 26 35% 8% !important;
  --cathi-secondary: 220 6% 16% !important;
  --cathi-line: 214 12% 30% !important;
  --cathi-accent-line: 68 100% 55% !important;
  --cathi-border: 214 12% 28% !important;
  --cathi-input: 214 12% 30% !important;
  --cathi-ring: 68 100% 48% !important;
}

[data-colored-header="true"][data-theme^="light"],
[data-colored-header="true"]:not([data-theme^="dark"]) {
/* 浅色 + 彩色顶栏 */
  --primary-color: hsl(68 95% 36%) !important;
  --secondary-color: hsl(68 85% 22%) !important;
  --accent-color: hsl(68 95% 36%) !important;
  --danger-color: hsl(0 72% 50%) !important;
  --body-bg: hsl(220 14% 94%) !important;
  --body-bg-light: hsl(0 0% 100%) !important;
  --body-bg-shaded: hsl(220 16% 91%) !important;
  --body-bg-faded: hsl(220 14% 94% / .94) !important;
  --body-bg-fade-70: hsl(220 14% 94% / .70) !important;
  --text-color: hsl(220 22% 12%) !important;
  --text-color-fade-70: hsl(220 22% 12% / .70) !important;
  --heading-color: hsl(220 22% 12%) !important;
  --muted-color: hsl(220 12% 42%) !important;
  --muted-color-light: hsl(220 12% 42%) !important;
  --muted-color-dark: hsl(220 22% 12%) !important;
  --link-color: hsl(68 95% 36%) !important;
  --discussion-title-color: hsl(220 22% 12%) !important;
  --control-bg: hsl(0 0% 100%) !important;
  --control-bg-light: hsl(0 0% 100%) !important;
  --control-bg-shaded: hsl(220 16% 91%) !important;
  --control-bg-darken-5: hsl(220 16% 91%) !important;
  --control-bg-darken-10: hsl(220 16% 89%) !important;
  --control-color: hsl(220 22% 12%) !important;
  --control-muted-color: hsl(220 12% 42%) !important;
  --form-control-bg: hsl(220 16% 96%) !important;
  --form-control-color: hsl(220 22% 12%) !important;
  --button-bg: hsl(0 0% 100%) !important;
  --button-color: hsl(220 22% 12%) !important;
  --button-primary-bg: hsl(68 95% 36%) !important;
  --button-primary-color: hsl(0 0% 100%) !important;
  --on-primary-color: hsl(0 0% 100%) !important;
  --header-bg: hsl(220 8% 11%) !important;
  --header-color: #ffffff !important;
  --header-control-bg: hsl(220 8% 14%) !important;
  --header-control-color: #ffffff !important;
  --hero-bg: hsl(220 8% 11%) !important;
  --hero-color: #ffffff !important;
  --usercard-bg: hsl(0 0% 100%) !important;
  --code-bg: hsl(220 10% 12%) !important;
  --code-color: hsl(68 95% 36%) !important;
  --tag-bg: hsl(68 95% 36%) !important;
  --tag-color: hsl(0 0% 100%) !important;
  --pill-bg: hsl(220 16% 91%) !important;
  --overlay-bg: rgba(12,12,12,.55) !important;
  --tooltip-bg: hsl(68 95% 36%) !important;
  --tooltip-color: hsl(0 0% 100%) !important;
  --alert-bg: hsl(220 16% 91%) !important;
  --alert-color: hsl(220 22% 12%) !important;
  --alert-success-bg: hsl(145 45% 38% / .16) !important;
  --alert-success-color: hsl(0 0% 100%) !important;
  --alert-error-bg: hsl(0 72% 50% / .14) !important;
  --alert-error-color: hsl(0 0% 100%) !important;
  --discussion-list-item-bg-hover: hsl(220 16% 89%) !important;
  --shadow-color: hsl(220 20% 20% / .18) !important;
  --shadow-color-darken-5: hsl(220 20% 20% / .25) !important;
  --border-radius: 3px !important;
  --border-radius-rounded: 6px !important;
  --border-radius-circle: 999px !important;
  --highlight-color: hsl(68 95% 36% / .45) !important;
  --loading-indicator-color: hsl(68 95% 36%) !important;
  --online-user-circle-color: hsl(68 95% 36%) !important;
  --switch-on-color: hsl(68 95% 36%) !important;
  --switch-off-color: hsl(220 16% 91%) !important;
  /* cathi tokens export for components-bridge */
  --cathi-card: 0 0% 100% !important;
  --cathi-muted: 220 16% 91% !important;
  --cathi-field: 220 16% 96% !important;
  --cathi-field-2: 220 16% 85% !important;
  --cathi-background: 220 14% 94% !important;
  --cathi-foreground: 220 22% 12% !important;
  --cathi-primary: 68 95% 36% !important;
  --cathi-primary-active: 68 95% 28% !important;
  --cathi-primary-foreground: 0 0% 100% !important;
  --cathi-secondary: 220 16% 89% !important;
  --cathi-line: 220 16% 78% !important;
  --cathi-accent-line: 68 90% 36% !important;
  --cathi-border: 220 14% 76% !important;
  --cathi-input: 220 16% 80% !important;
  --cathi-ring: 68 95% 40% !important;
  --cathi-radius: .25rem !important;
  --cathi-r-sm: .25rem !important;
  --cathi-r-md: .35rem !important;
}

[data-colored-header="true"][data-theme^="dark"] {
/* 深色 + 彩色顶栏 */
  --primary-color: hsl(68 100% 48%) !important;
  --secondary-color: hsl(0 0% 90%) !important;
  --accent-color: hsl(68 100% 48%) !important;
  --danger-color: hsl(0 72% 56%) !important;
  --body-bg: hsl(220 5% 8%) !important;
  --body-bg-light: hsl(220 6% 12%) !important;
  --body-bg-shaded: hsl(220 6% 15%) !important;
  --body-bg-faded: hsl(220 5% 8% / .94) !important;
  --body-bg-fade-70: hsl(220 5% 8% / .70) !important;
  --text-color: hsl(0 0% 95%) !important;
  --text-color-fade-70: hsl(0 0% 95% / .70) !important;
  --heading-color: hsl(0 0% 95%) !important;
  --muted-color: hsl(214 8% 66%) !important;
  --muted-color-light: hsl(214 8% 66%) !important;
  --muted-color-dark: hsl(0 0% 95%) !important;
  --link-color: hsl(68 100% 48%) !important;
  --discussion-title-color: hsl(0 0% 95%) !important;
  --control-bg: hsl(220 6% 12%) !important;
  --control-bg-light: hsl(220 6% 12%) !important;
  --control-bg-shaded: hsl(220 6% 15%) !important;
  --control-bg-darken-5: hsl(220 6% 15%) !important;
  --control-bg-darken-10: hsl(220 6% 16%) !important;
  --control-color: hsl(0 0% 95%) !important;
  --control-muted-color: hsl(214 8% 66%) !important;
  --form-control-bg: hsl(220 12% 11%) !important;
  --form-control-color: hsl(0 0% 92%) !important;
  --button-bg: hsl(220 6% 12%) !important;
  --button-color: hsl(0 0% 95%) !important;
  --button-primary-bg: hsl(68 100% 48%) !important;
  --button-primary-color: hsl(26 35% 8%) !important;
  --on-primary-color: hsl(26 35% 8%) !important;
  --header-bg: hsl(0 0% 0%) !important;
  --header-color: #ffffff !important;
  --header-control-bg: hsl(0 0% 0%) !important;
  --header-control-color: #ffffff !important;
  --hero-bg: hsl(0 0% 0%) !important;
  --hero-color: #ffffff !important;
  --usercard-bg: hsl(220 6% 12%) !important;
  --code-bg: hsl(0 0% 0%) !important;
  --code-color: hsl(68 100% 48%) !important;
  --tag-bg: hsl(68 100% 48%) !important;
  --tag-color: hsl(26 35% 8%) !important;
  --pill-bg: hsl(220 6% 15%) !important;
  --overlay-bg: rgba(0,0,0,.7) !important;
  --tooltip-bg: hsl(68 100% 48%) !important;
  --tooltip-color: hsl(26 35% 8%) !important;
  --alert-bg: hsl(220 6% 15%) !important;
  --alert-color: hsl(0 0% 95%) !important;
  --alert-success-bg: hsl(145 45% 50% / .16) !important;
  --alert-success-color: hsl(145 60% 10%) !important;
  --alert-error-bg: hsl(0 72% 56% / .14) !important;
  --alert-error-color: hsl(0 0% 98%) !important;
  --discussion-list-item-bg-hover: hsl(220 6% 16%) !important;
  --shadow-color: hsl(0 0% 0% / .18) !important;
  --shadow-color-darken-5: hsl(0 0% 0% / .25) !important;
  --border-radius: 3px !important;
  --border-radius-rounded: 6px !important;
  --border-radius-circle: 999px !important;
  --highlight-color: hsl(68 100% 48% / .45) !important;
  --loading-indicator-color: hsl(68 100% 48%) !important;
  --online-user-circle-color: hsl(68 100% 48%) !important;
  --switch-on-color: hsl(68 100% 48%) !important;
  --switch-off-color: hsl(220 6% 15%) !important;
  /* cathi tokens export for components-bridge */
  --cathi-card: 220 6% 12% !important;
  --cathi-muted: 220 6% 15% !important;
  --cathi-field: 220 12% 11% !important;
  --cathi-field-2: 220 12% 20% !important;
  --cathi-background: 220 5% 8% !important;
  --cathi-foreground: 0 0% 95% !important;
  --cathi-primary: 68 100% 48% !important;
  --cathi-primary-active: 68 100% 38% !important;
  --cathi-primary-foreground: 26 35% 8% !important;
  --cathi-secondary: 220 6% 16% !important;
  --cathi-line: 214 12% 30% !important;
  --cathi-accent-line: 68 100% 55% !important;
  --cathi-border: 214 12% 28% !important;
  --cathi-input: 214 12% 30% !important;
  --cathi-ring: 68 100% 48% !important;
}
