/* VisionFlow 品牌样式（fork 自有文件，随 web 镜像发布，由 index.html 引入）。
   颜色、圆角、控件尺寸不在这里：它们是站点皮肤（后台 → 外观设置 → 皮肤主题），
   源文件是 /brand/skin-visionflow.json，按环境用 infra/scripts/apply-brand-skin.sh 应用或回收。
   这里只放皮肤系统覆盖不到的部分：字体与字号基准。设计师改字体只需改本文件。 */

/* 正文字体栈（Inter Variable + 系统中文字体）和等宽字体由上游 globals.css 定义，Inter / JetBrains Mono
   通过 @fontsource-variable 随构建自托管，这里不再重复声明。
   application.tsx 用 inline style 把 body 字体写死成 SF Pro/苹方栈，只有 !important 能盖过 inline style；
   AntD 组件已通过主题 token 使用 --font-sans，这条只影响 AntD 之外的元素。 */
html:root body {
    font-family: var(--font-sans) !important;
}

/* 登录场景的展示字体（只在 web/src/pages/auth/auth-scene.css 里使用）：
   Press Start 2P 是电脑主题的英文标语；两个 CTA 字体是按登录页现有文案裁切的中文子集，
   改了登录页文案要按 fonts/AUTH-CTA-FONTS.md 重新生成，缺字会回退到系统字体。 */
@font-face {
    font-family: "Press Start 2P";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("/brand/fonts/PressStart2P-Regular.ttf") format("truetype");
}
@font-face {
    font-family: "VisionFlow CTA Rounded";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("/brand/fonts/auth-cta-rounded-bold.otf") format("opentype");
}
@font-face {
    font-family: "VisionFlow CTA Pixel";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("/brand/fonts/auth-cta-pixel.woff") format("woff");
}

/* ---- 对比度修正（fork 自有；上游派生值在皮肤系统里改不到）----
   链接色不在这里覆盖：AntD 把 a { color } 应用到所有锚点（包括工作台侧栏导航），任何着色都会染到导航上；
   保持上游默认（链接跟随主操作色，黑白皮肤下即中性文字色）。
   占位符 / 三级文字 AntD 默认 25% / 45% 透明度，在深色卡片上不足 3:1，这里提到 50% / 62%。
   AntD 的变量挂在 .infinite-canvas-<皮肤>-<模式> 容器上，按前缀匹配。 */
html:root [class*="infinite-canvas-"][class*="-dark"] {
    --ant-color-text-placeholder: rgba(255, 255, 255, 0.5);
    --ant-color-text-quaternary: rgba(255, 255, 255, 0.5);
    --ant-color-text-tertiary: rgba(255, 255, 255, 0.62);
    --ant-color-text-description: rgba(255, 255, 255, 0.62);
}
html:root [class*="infinite-canvas-"][class*="-light"] {
    --ant-color-text-placeholder: rgba(0, 0, 0, 0.5);
    --ant-color-text-quaternary: rgba(0, 0, 0, 0.5);
    --ant-color-text-tertiary: rgba(0, 0, 0, 0.62);
    --ant-color-text-description: rgba(0, 0, 0, 0.62);
}

/* 创作首页把次要文字写死为 #7c838b / #565d67 一类固定灰，浅色下 11px 说明只有 3.5:1；改为跟随皮肤的次要文字色。 */
html:root body .creation-home {
    --creation-muted: var(--muted-foreground);
    --creation-faint: color-mix(in srgb, var(--muted-foreground) 72%, transparent);
}
