Files
personal/app/globals.css
T
virtheart d666cedfc6 feat: Next.js 后端 + SQLite + 暗门后台 /virtheart + 服务咨询页
后端(node:sqlite 零原生依赖,data/site.db,WAL + busy_timeout 抗并发):
- works / service_items / site_config / inquiries / admin_users / admin_sessions / captcha_challenges
- API:admin 登录登出/密码、作品与服务 CRUD、图片上传、留言箱、
  验证码 challenge/verify、咨询提交(一次性滑块令牌防重放)

后台 /virtheart(仅手动访问,未登录一律 307 → /virtheart/login):
- 服务端布局鉴权 + DB 会话(httpOnly cookie 7 天)+ CSRF 头校验
- 概览 / 作品(上传、网格预设、发布开关)/ 服务 / 留言箱 / 配置(全站文案)
- 设计与主站同语言:暗底点阵、mono、lime 选中,非传统后台模板

公开站:
- 路由组 (site) 隔离站点壳层;首页/服务页文案全部 DB 驱动即时生效
- /services 服务菜单 + 留言表单 + 全屏居中滑块拼图验证码(对齐缺口)
- 提交入 inquiries 并 SMTP(飞书 notify@)邮件通知 chenchun@virtheart.com
- Header 新增「服务」菜单;旧作品清理,空状态自动接管
- 根布局仅承载字体/全局样式,后台无站点壳层

验证:登录/CSRF/发布隔离/滑块容错/令牌单次消费/SMTP 真发全部通过;
lint 与基线一致(119 errors 均为存量)。
2026-09-02 18:34:18 +08:00

191 lines
4.5 KiB
CSS

@import "tailwindcss";
/* Theme color indirection: utilities (text-l1, bg-b1, …) reference these
tokens, and the .dark block (below) flips their values — the same
light/dark token pairs the original stylesheet emits. */
@theme {
/* MiSans(中文,cn-font-split 分片 + unicode-range,经 <link> 引入)
接在各栈尾:英文/数字由 TikTok Sans 与等宽字体先行命中,中文回落
到 MiSans 分片。 */
--font-sans: var(--font-tiktok), "MiSans", sans-serif;
--font-mono: var(--font-geist-mono), "MiSans", monospace;
--font-mono-2: var(--font-departure-mono), "MiSans", monospace;
--color-l1: var(--label-1);
--color-l2: var(--label-2);
--color-l3: var(--label-3);
--color-line: var(--line);
--color-b1: rgb(var(--background-deep));
--color-be: var(--background-elevated);
--color-selection: #c0fe04;
}
:root {
--bg-color: rgb(var(--background-deep));
--text-color: var(--label-1);
--grid-dot: var(--line);
--selection-bg: #c0fe04;
/* Light theme tokens (chunk 635eb04122aa774f.css :root). */
--label: 0, 0, 0;
--label-d: 54, 54, 48;
--background-deep: 251, 250, 244;
--background-elevated: #efede7;
--label-1: rgba(var(--label), 1);
--label-2: rgba(var(--label-d), 0.6);
--label-3: rgba(var(--label-d), 0.32);
--label-4: rgba(var(--label-d), 0.18);
--line: rgba(var(--label-d), 0.1);
/* Original code token colors (light theme). */
--code-comment: rgba(var(--label-d), 0.45);
--code-string: lab(43.8263% -47.6118 18.596);
--code-number: lab(46.7992% 8.99872 72.9973);
--code-keyword: lab(43.3789% 36.2819 -73.3524);
--code-function: lab(47.3165% -8.24019 -45.3882);
--code-tag: lab(47.2741% 51.266 23.7532);
--code-operator: rgba(var(--label-d), 0.75);
}
/* Dark theme (original .dark block: ThemeModeProvider adds the class to
<html>; localStorage "theme" ∈ light|dark|system, system follows
prefers-color-scheme). */
.dark {
color-scheme: dark;
--label: 255, 255, 255;
--label-d: 230, 232, 232;
--background-deep: 15, 17, 17;
--background-elevated: #191b1b;
--label-1: rgba(var(--label), 1);
--label-2: rgba(var(--label-d), 0.6);
--label-3: rgba(var(--label-d), 0.32);
--label-4: rgba(var(--label-d), 0.16);
--line: rgba(var(--label-d), 0.08);
--code-comment: rgba(var(--label-d), 0.5);
--code-string: lab(80.5863% -36.0539 14.2351);
--code-number: lab(81.7507% 5.58251 51.1676);
--code-keyword: lab(74.3615% 26.3244 -70.4223);
--code-function: lab(78.8788% -11.9607 -42.8116);
--code-tag: lab(76.4079% 47.9123 21.2271);
--code-operator: rgba(var(--label-d), 0.85);
}
/* Background lives on the ROOT only — per CSS painting it propagates to the
canvas backdrop, so it stays BEHIND the original's -z-1 fixed WebGL host.
A body-level background would paint as normal-flow content and cover the
scene (the text-over-canvas regression this fixes). */
html {
background-color: var(--bg-color);
}
body {
color: var(--text-color);
font-family: var(--font-sans);
margin: 0;
padding: 0;
min-height: 100vh;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
::selection {
background-color: var(--selection-bg);
color: #000;
}
.no-scrollbar {
scrollbar-width: none;
-ms-overflow-style: none;
}
.no-scrollbar::-webkit-scrollbar {
display: none;
}
html, body {
scrollbar-width: none; /* Firefox */
-ms-overflow-style: none; /* IE and Edge */
}
html::-webkit-scrollbar, body::-webkit-scrollbar {
display: none; /* Chrome, Safari and Opera */
}
@keyframes vh-fade-in {
from {
opacity: 0;
}
to {
opacity: 1;
}
}
/* Hyper-space stagger text (original hsst-char / hsstFadeIn / hsstFadeOut). */
.hsst-char {
display: inline-block;
}
/* Passcode unlock screen (original ease-66 token + caret-blink). */
.ease-66 {
transition-timing-function: cubic-bezier(0.66, 0, 0.01, 1);
}
@keyframes caret-blink {
0%,
100% {
opacity: 1;
}
50% {
opacity: 0;
}
}
.caret-blink {
animation: caret-blink 1s step-end infinite;
}
/* 滑块验证码 — 校验失败抖动。 */
@keyframes vh-shake {
0%,
100% {
transform: translateX(0);
}
20% {
transform: translateX(-6px);
}
40% {
transform: translateX(6px);
}
60% {
transform: translateX(-4px);
}
80% {
transform: translateX(4px);
}
}
@keyframes hsstFadeIn {
0% {
opacity: 0;
}
32% {
opacity: 0.22;
}
62% {
opacity: 0.55;
}
to {
opacity: 1;
}
}
@keyframes hsstFadeOut {
0% {
opacity: 1;
}
38% {
opacity: 0.62;
}
72% {
opacity: 0.28;
}
to {
opacity: 0;
}
}