fix(app): 全链路验证修复 — 编译错误/CORS/迁移/启动脚本
Some checks failed
Main Merge / backend (push) Has been cancelled
Main Merge / frontend (push) Has been cancelled

前端修复:
- calendar_page: 移除不存在的 JournalEntry.content getter
- responsive_scaffold: 移除不存在的 notchThickness 参数
- splash_page: SingleTickerProvider → TickerProvider (多 AnimationController)
- profile_page: UserRoleType.name → .code (修复运行时崩溃)
- 导入缺失的 user.dart

后端修复:
- class_service: generate_class_code 取 UUID 后6位(随机部分)避免碰撞
- diary_role_seed: 移除不存在的 id 列,使用复合主键 ON CONFLICT

基础设施:
- config/default.toml: CORS 改为通配符(开发模式)
- scripts/dev.sh: 统一启动脚本(自动清理端口)
- docs/opendesign/: Open Design 设计规格 HTML 原型稿

验证结果: flutter analyze 0 error, cargo test 77/77 通过, 17个页面全部渲染正常
This commit is contained in:
iven
2026-06-02 01:03:58 +08:00
parent 749ef55b89
commit b320641d9c
56 changed files with 20696 additions and 239 deletions

View File

@@ -0,0 +1,296 @@
/* ─────────────────────────────────────────────────────────
* 暖记 — 共享组件样式
* ───────────────────────────────────────────────────────── */
/* Reset & base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body {
font-family: var(--font-body);
font-size: var(--text-base);
line-height: var(--leading-body);
color: var(--fg);
background: var(--bg);
overflow-x: hidden;
}
/* Phone frame wrapper */
.phone-frame {
width: 390px;
height: 844px;
position: relative;
overflow: hidden;
background: var(--bg);
border-radius: 44px;
box-shadow: var(--elev-float);
}
/* Status bar */
.status-bar {
display: flex;
justify-content: space-between;
align-items: center;
padding: 14px 28px 0;
height: var(--safe-top);
font-size: var(--text-sm);
font-weight: 600;
color: var(--fg);
position: relative;
z-index: 100;
}
.status-bar .time { font-variant-numeric: tabular-nums; }
.status-bar .icons { display: flex; gap: 6px; align-items: center; }
.status-bar .icons svg { width: 18px; height: 18px; }
/* Dynamic Island */
.dynamic-island {
position: absolute;
top: 12px;
left: 50%;
transform: translateX(-50%);
width: 126px;
height: 36px;
background: #000;
border-radius: 20px;
z-index: 200;
}
/* Top nav bar */
.top-nav {
display: flex;
align-items: center;
justify-content: space-between;
padding: var(--space-4) var(--space-5);
position: relative;
z-index: 10;
}
.top-nav .title {
font-family: var(--font-display);
font-size: var(--text-xl);
font-weight: 700;
color: var(--fg);
}
.top-nav .action {
width: var(--touch-min);
height: var(--touch-min);
display: flex;
align-items: center;
justify-content: center;
border-radius: var(--radius-pill);
background: var(--surface);
border: none;
cursor: pointer;
transition: background var(--motion-fast) var(--ease-standard);
}
.top-nav .action:hover { background: var(--border-soft); }
.top-nav .action:focus-visible { box-shadow: var(--focus-ring); outline: none; }
.top-nav .action svg { width: 22px; height: 22px; color: var(--fg); }
/* Bottom tab bar */
.tab-bar {
position: absolute;
bottom: 0;
left: 0;
right: 0;
height: calc(var(--tab-height) + var(--safe-bottom));
padding-bottom: var(--safe-bottom);
display: flex;
align-items: flex-start;
justify-content: space-around;
background: var(--surface);
border-top: 1px solid var(--border-soft);
z-index: 100;
}
.tab-item {
display: flex;
flex-direction: column;
align-items: center;
gap: 2px;
padding-top: 10px;
background: none;
border: none;
cursor: pointer;
color: var(--muted);
font-size: var(--text-xs);
font-weight: 500;
transition: color var(--motion-fast) var(--ease-standard);
}
.tab-item.active { color: var(--accent); }
.tab-item svg { width: 24px; height: 24px; }
.tab-item span { margin-top: 2px; }
/* Buttons */
.btn {
display: inline-flex;
align-items: center;
justify-content: center;
gap: var(--space-2);
padding: 14px 28px;
border-radius: var(--radius-pill);
border: none;
font-family: var(--font-display);
font-size: var(--text-md);
font-weight: 600;
cursor: pointer;
transition: all var(--motion-fast) var(--ease-standard);
}
.btn:active { transform: scale(0.97); }
.btn-primary {
background: var(--accent);
color: var(--accent-on);
}
.btn-primary:hover { background: var(--accent-hover); }
.btn-primary:focus-visible { box-shadow: var(--focus-ring); outline: none; }
.btn-secondary {
background: var(--surface);
color: var(--fg);
border: 1.5px solid var(--border);
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }
.btn-secondary:focus-visible { box-shadow: var(--focus-ring); outline: none; }
.btn-ghost {
background: transparent;
color: var(--muted);
}
.btn-ghost:hover { color: var(--accent); }
/* Cards */
.card {
background: var(--surface);
border-radius: var(--radius-md);
padding: var(--space-5);
box-shadow: var(--elev-soft);
border: 1px solid var(--border-soft);
}
/* Tags / chips */
.chip {
display: inline-flex;
align-items: center;
gap: var(--space-1);
padding: 6px 14px;
border-radius: var(--radius-pill);
font-size: var(--text-sm);
font-weight: 500;
background: var(--surface);
color: var(--fg-2);
border: 1px solid var(--border);
transition: all var(--motion-fast) var(--ease-standard);
}
.chip:focus-visible { box-shadow: var(--focus-ring); outline: none; }
.chip.active {
background: var(--accent);
color: var(--accent-on);
border-color: var(--accent);
}
/* Section heading */
.section-heading {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: var(--space-4);
}
.section-heading h3 {
font-family: var(--font-display);
font-size: var(--text-lg);
font-weight: 700;
}
.section-heading .more {
font-size: var(--text-sm);
color: var(--accent);
cursor: pointer;
background: none;
border: none;
font-weight: 500;
min-height: var(--touch-min);
display: inline-flex;
align-items: center;
}
.section-heading .more:focus-visible { box-shadow: var(--focus-ring); outline: none; border-radius: 4px; }
/* Mood emoji faces */
.mood-row {
display: flex;
gap: var(--space-3);
justify-content: center;
}
.mood-btn {
width: 48px;
height: 48px;
border-radius: 50%;
border: 2px solid var(--border);
display: flex;
align-items: center;
justify-content: center;
font-size: 24px;
background: var(--surface);
cursor: pointer;
transition: all var(--motion-fast) var(--ease-bounce);
}
.mood-btn:hover { transform: scale(1.1); }
.mood-btn:focus-visible { box-shadow: var(--focus-ring); outline: none; }
.mood-btn.selected {
border-color: var(--accent);
background: var(--surface-warm);
transform: scale(1.08);
}
/* Scroll content area */
.scroll-content {
overflow-y: auto;
overflow-x: hidden;
-webkit-overflow-scrolling: touch;
scrollbar-width: none;
}
.scroll-content::-webkit-scrollbar { display: none; }
/* Utility */
.text-center { text-align: center; }
.text-muted { color: var(--muted); }
.text-accent { color: var(--accent); }
.text-secondary { color: var(--secondary); }
.font-display { font-family: var(--font-display); }
.font-hand { font-family: var(--font-handwritten); }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-5 { gap: var(--space-5); }
.gap-6 { gap: var(--space-6); }
.w-full { width: 100%; }
.rounded-full { border-radius: var(--radius-pill); }
/* Decorative doodles */
.doodle { opacity: 0.15; pointer-events: none; }
/* Home indicator */
.home-indicator {
width: 134px;
height: 5px;
background: var(--fg);
opacity: 0.2;
border-radius: 3px;
margin: 8px auto;
}
/* Page transitions */
@keyframes fadeIn {
from { opacity: 0; transform: translateY(12px); }
to { opacity: 1; transform: translateY(0); }
}
@keyframes slideUp {
from { opacity: 0; transform: translateY(40px); }
to { opacity: 1; transform: translateY(0); }
}
@keyframes scaleIn {
from { opacity: 0; transform: scale(0.9); }
to { opacity: 1; transform: scale(1); }
}
.anim-fade { animation: fadeIn 0.5s var(--ease-standard) both; }
.anim-slide { animation: slideUp 0.6s var(--ease-bounce) both; }
.anim-scale { animation: scaleIn 0.4s var(--ease-bounce) both; }

View File

@@ -0,0 +1,502 @@
/* ─────────────────────────────────────────────────────────
* 暖记 — 编辑器共享样式
* 三端通用 (mobile / tablet / desktop)
* ───────────────────────────────────────────────────────── */
/* Top toolbar */
.editor-topbar {
display: flex;
align-items: center;
justify-content: space-between;
background: var(--surface);
border-bottom: 1px solid var(--border-soft);
}
.topbar-left, .topbar-right {
display: flex;
align-items: center;
gap: var(--space-3);
}
.topbar-btn {
border-radius: var(--radius-pill);
border: none;
background: none;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
color: var(--fg);
transition: background var(--motion-fast);
}
.topbar-btn:hover { background: var(--surface-warm); }
.topbar-center {
font-family: var(--font-display);
font-size: var(--text-base);
font-weight: 600;
color: var(--fg-2);
}
/* Save button */
.save-btn {
background: var(--accent);
color: var(--accent-on);
border: none;
border-radius: var(--radius-pill);
font-family: var(--font-display);
font-size: var(--text-sm);
font-weight: 600;
cursor: pointer;
transition: all var(--motion-fast);
}
.save-btn:hover { background: var(--accent-hover); }
/* Canvas area common */
.canvas-grid {
position: absolute;
inset: 0;
background-image: radial-gradient(circle, var(--border) 1px, transparent 1px);
background-size: 28px 28px;
opacity: 0.4;
pointer-events: none;
border-radius: var(--radius-md);
}
.washi-tape {
position: absolute;
background: repeating-linear-gradient(
45deg,
rgba(242, 204, 143, 0.7),
rgba(242, 204, 143, 0.7) 4px,
rgba(255, 243, 230, 0.7) 4px,
rgba(255, 243, 230, 0.7) 8px
);
transform: rotate(-8deg);
border-radius: 2px;
opacity: 0.8;
}
.placed-sticker {
position: absolute;
cursor: move;
filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}
.journal-content { position: relative; z-index: 1; }
.journal-title {
font-family: var(--font-display);
font-size: var(--text-2xl);
font-weight: 700;
color: var(--fg);
margin-bottom: var(--space-4);
border: none;
outline: none;
width: 100%;
background: transparent;
}
.journal-body {
font-size: var(--text-base);
line-height: 1.9;
color: var(--fg-2);
border: none;
outline: none;
width: 100%;
background: transparent;
resize: none;
min-height: 240px;
}
/* Format bar */
.format-bar {
display: flex;
align-items: center;
gap: var(--space-2);
padding: var(--space-2) 0;
margin-bottom: var(--space-4);
border-bottom: 1px solid var(--border-soft);
}
.format-btn {
border-radius: 6px;
border: none;
background: none;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
color: var(--muted);
font-size: var(--text-sm);
font-weight: 600;
transition: all var(--motion-fast);
}
.format-btn:hover { background: var(--surface-warm); color: var(--fg); }
.format-btn.active { background: var(--accent); color: #FFF8F0; }
.format-divider {
width: 1px;
height: 22px;
background: var(--border);
}
/* Color dots */
.color-dot {
border-radius: 50%;
border: 2px solid transparent;
cursor: pointer;
transition: all var(--motion-fast);
}
.color-dot:hover { transform: scale(1.15); }
.color-dot.active { border-color: var(--fg); }
/* Placed photo in journal */
.placed-photo {
width: 100%;
border-radius: var(--radius-sm);
background: linear-gradient(135deg, #D4E8DC, #E8F4ED);
display: flex;
align-items: center;
justify-content: center;
}
/* Panel tabs */
.panel-tab {
padding: 8px 16px;
border-radius: var(--radius-pill);
font-size: var(--text-sm);
font-weight: 500;
background: var(--surface-warm);
color: var(--fg-2);
border: none;
cursor: pointer;
white-space: nowrap;
transition: all var(--motion-fast);
}
.panel-tab.active { background: var(--accent); color: #FFF8F0; }
.panel-content {
padding: var(--space-5);
}
/* Sticker grid */
.sticker-grid {
display: grid;
grid-template-columns: repeat(5, 1fr);
gap: var(--space-3);
}
.sticker-item {
aspect-ratio: 1;
border-radius: var(--radius-sm);
background: var(--surface-warm);
display: flex;
align-items: center;
justify-content: center;
font-size: 28px;
cursor: pointer;
transition: all var(--motion-fast) var(--ease-bounce);
border: 1px solid transparent;
}
.sticker-item:hover { transform: scale(1.1); border-color: var(--accent); }
/* Date strip */
.date-strip {
display: flex;
align-items: center;
justify-content: space-between;
background: var(--surface);
}
.date-info {
display: flex;
align-items: center;
gap: var(--space-2);
font-size: var(--text-sm);
color: var(--muted);
}
.date-info strong { color: var(--fg); font-weight: 600; }
.mood-quick { display: flex; gap: 6px; }
.mood-mini {
border-radius: 50%;
border: 1.5px solid var(--border);
display: flex;
align-items: center;
justify-content: center;
background: var(--surface);
cursor: pointer;
transition: all var(--motion-fast);
}
.mood-mini.selected { border-color: var(--accent); background: var(--surface-warm); }
/* Undo/Redo */
.topbar-undo-redo {
display: flex;
align-items: center;
gap: 2px;
}
.undo-btn, .redo-btn {
border-radius: var(--radius-pill);
border: none;
background: none;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
color: var(--muted);
transition: all var(--motion-fast);
}
.undo-btn:hover:not(:disabled), .redo-btn:hover:not(:disabled) { background: var(--surface-warm); color: var(--fg); }
.undo-btn:disabled, .redo-btn:disabled { opacity: 0.35; cursor: default; }
.undo-btn svg, .redo-btn svg { width: 18px; height: 18px; }
/* Auto-save indicator */
.autosave-status {
display: flex;
align-items: center;
gap: 5px;
font-size: 11px;
color: var(--success);
font-weight: 500;
}
.autosave-dot {
width: 6px;
height: 6px;
border-radius: 50%;
background: var(--success);
}
/* Brush slider (size + opacity) */
.brush-slider {
flex: 1;
-webkit-appearance: none;
appearance: none;
height: 4px;
border-radius: 2px;
background: var(--border);
outline: none;
}
.brush-slider::-webkit-slider-thumb {
-webkit-appearance: none;
width: 18px;
height: 18px;
border-radius: 50%;
background: var(--accent);
cursor: pointer;
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}
.brush-size-row {
display: flex;
align-items: center;
gap: var(--space-3);
}
.brush-size-value {
font-size: var(--text-sm);
font-weight: 600;
color: var(--fg);
min-width: 36px;
text-align: right;
}
/* Brush color dots */
.brush-color-dot {
border-radius: 50%;
border: 3px solid transparent;
cursor: pointer;
transition: all var(--motion-fast);
}
.brush-color-dot:hover { transform: scale(1.1); }
.brush-color-dot.active { border-color: var(--fg); box-shadow: 0 0 0 2px var(--surface); }
/* Brush opacity */
.brush-opacity-row {
display: flex;
align-items: center;
gap: var(--space-3);
transition: opacity var(--motion-fast);
}
.brush-opacity-row.disabled { opacity: 0.35; pointer-events: none; }
.brush-opacity-label {
font-size: var(--text-xs);
color: var(--muted);
font-weight: 500;
min-width: 40px;
}
.brush-opacity-value {
font-size: var(--text-sm);
font-weight: 600;
color: var(--fg);
min-width: 36px;
text-align: right;
}
/* Tag pill */
.tag-selected-area {
display: flex;
flex-wrap: wrap;
gap: var(--space-2);
min-height: 36px;
}
.tag-pill {
display: inline-flex;
align-items: center;
gap: 4px;
padding: 4px 12px;
border-radius: 9999px;
background: var(--surface-warm);
color: var(--accent);
font-size: 13px;
font-weight: 500;
transition: all var(--motion-fast);
}
.tag-pill .remove {
width: 16px;
height: 16px;
border-radius: 50%;
background: var(--accent);
color: var(--surface);
display: flex;
align-items: center;
justify-content: center;
font-size: 10px;
cursor: pointer;
border: none;
line-height: 1;
transition: background var(--motion-fast);
}
.tag-pill .remove:hover { background: var(--accent-hover); }
/* Tag input */
.tag-input-row {
display: flex;
}
.tag-input {
flex: 1;
height: 44px;
border: 1.5px solid var(--border);
border-radius: var(--radius-pill);
padding: 0 var(--space-4);
font-size: var(--text-sm);
color: var(--fg);
background: var(--bg);
outline: none;
transition: border-color var(--motion-fast);
font-family: var(--font-body);
}
.tag-input::placeholder { color: var(--meta); }
.tag-input:focus { border-color: var(--accent); box-shadow: var(--shadow-input-focus); }
/* Tag suggest items */
.tag-suggest-item {
display: inline-flex;
align-items: center;
padding: 6px 14px;
border-radius: 9999px;
background: var(--surface-warm);
color: var(--fg-2);
font-size: var(--text-sm);
font-weight: 500;
border: 1px solid transparent;
cursor: pointer;
white-space: nowrap;
min-height: 44px;
transition: all var(--motion-fast);
}
.tag-suggest-item:hover { border-color: var(--accent); color: var(--accent); }
/* Brush section title (tablet/desktop) */
.brush-section-title {
font-size: var(--text-xs);
font-weight: 600;
color: var(--muted);
text-transform: uppercase;
letter-spacing: 0.5px;
margin-bottom: var(--space-3);
}
/* Brush color grid (tablet/desktop) */
.brush-colors-grid {
display: grid;
grid-template-columns: repeat(4, 1fr);
gap: var(--space-3);
}
/* Tags section */
.tags-section {
margin-bottom: var(--space-5);
}
/* Tool panel side (tablet/desktop) */
.tool-panel-side {
background: var(--surface);
border-left: 1px solid var(--border-soft);
overflow-y: auto;
scrollbar-width: thin;
flex-shrink: 0;
}
.tool-panel-side::-webkit-scrollbar { width: 4px; }
.tool-panel-side::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
.panel-header {
padding: var(--space-5);
border-bottom: 1px solid var(--border-soft);
display: flex;
align-items: center;
gap: var(--space-3);
}
/* Canvas wrapper scrollbar (tablet/desktop) */
.canvas-wrapper {
flex: 1;
padding: var(--space-6);
overflow-y: auto;
scrollbar-width: thin;
scrollbar-color: var(--border) transparent;
}
.canvas-wrapper::-webkit-scrollbar { width: 4px; }
.canvas-wrapper::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
/* Canvas paper (tablet/desktop) */
.canvas-paper {
background: var(--surface);
border-radius: var(--radius-md);
box-shadow: var(--elev-medium);
border: 1px solid var(--border-soft);
position: relative;
}
/* Editor body flex layout (tablet/desktop) */
.editor-body {
flex: 1;
display: flex;
overflow: hidden;
}

View File

@@ -0,0 +1,235 @@
/* ─────────────────────────────────────────────────────────
* 暖记 (Warm Notes) — 手账日记App 视觉系统
* Theme 1: 暖阳 (Warm Sun) — 温暖治愈 · 手绘插画风 · 默认
* Theme 2: 松风 (Pine Wind) — 静谧森林 · 自然调性 · 男学生向
* ───────────────────────────────────────────────────────── */
:root {
/* Surface */
--bg: #FFF8F0;
--surface: #FFFFFF;
--surface-warm: #FFF3E6;
/* Foreground ramp (contrast-safe on #FFF8F0) */
--fg: #2D2420;
--fg-2: #5C4F47;
--muted: #7A6D63;
--meta: #8B7E74;
/* Border */
--border: #E8DDD4;
--border-soft: #F0E8DF;
/* Accent — soft coral / terracotta */
--accent: #E07A5F;
--accent-on: #FFF8F0;
--accent-hover: #D06A4F;
--accent-active: #C05A3F;
--accent-glow: rgba(224, 122, 95, 0.25);
/* Secondary — sage green */
--secondary: #81B29A;
--secondary-soft: #D4E8DC;
/* Tertiary — warm gold */
--tertiary: #F2CC8F;
--tertiary-soft: #FBE8C8;
/* Rose */
--rose: #D4A5A5;
--rose-soft: #F0DADA;
/* Semantic */
--success: #5A9E7E;
--warn: #D4A843;
--danger: #C93D3D;
/* Typography */
--font-display: "Quicksand", "Nunito", "SF Pro Rounded", -apple-system, system-ui, sans-serif;
--font-body: "Nunito", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
--font-mono: ui-monospace, "JetBrains Mono", monospace;
--font-handwritten: "Caveat", "Kalam", cursive;
/* Type scale */
--text-xs: 11px;
--text-sm: 13px;
--text-base: 15px;
--text-md: 17px;
--text-lg: 20px;
--text-xl: 24px;
--text-2xl: 30px;
--text-3xl: 38px;
--text-4xl: 48px;
--leading-body: 1.6;
--leading-tight: 1.25;
/* Spacing */
--space-1: 4px;
--space-2: 8px;
--space-3: 12px;
--space-4: 16px;
--space-5: 20px;
--space-6: 24px;
--space-8: 32px;
--space-10: 40px;
--space-12: 48px;
/* Radius */
--radius-sm: 10px;
--radius-md: 16px;
--radius-lg: 22px;
--radius-xl: 28px;
--radius-pill: 9999px;
/* Elevation */
--elev-soft: 0 2px 12px rgba(45, 36, 32, 0.06);
--elev-medium: 0 4px 20px rgba(45, 36, 32, 0.08);
--elev-float: 0 8px 32px rgba(45, 36, 32, 0.12);
/* Focus */
--focus-ring: 0 0 0 3px rgba(224, 122, 95, 0.45);
--shadow-accent: 0 4px 14px rgba(224, 122, 95, 0.25);
--shadow-accent-hover: 0 6px 20px rgba(224, 122, 95, 0.35);
--shadow-input-focus: 0 0 0 3px rgba(224, 122, 95, 0.2);
--bg-frosted: rgba(255, 248, 240, 0.85);
/* Touch target minimum (WCAG 2.5.8) */
--touch-min: 44px;
/* Motion */
--motion-fast: 150ms;
--motion-base: 250ms;
--ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
--ease-standard: cubic-bezier(0.2, 0, 0, 1);
/* Layout */
--container-max: 390px;
--safe-top: 54px;
--safe-bottom: 34px;
--tab-height: 56px;
/* Theme meta */
--theme-name: "暖阳";
}
/* ─────────────────────────────────────────────────────────
* Theme: 松风 (Pine Wind) — 森林书房 · 男学生向
* Steel blue accent + forest green + warm amber
* ───────────────────────────────────────────────────────── */
[data-theme="pine"] {
--bg: #F2F3F0;
--surface: #FFFFFF;
--surface-warm: #E9EAE6;
--fg: #23272F;
--fg-2: #484E58;
--muted: #6E7380;
--meta: #8A8F9A;
--border: #D5D2CD;
--border-soft: #E3E1DC;
--accent: #4A7B9D;
--accent-on: #FFFFFF;
--accent-hover: #3F6A8A;
--accent-active: #345A78;
--accent-glow: rgba(74, 123, 157, 0.25);
--secondary: #5B9E7A;
--secondary-soft: #D6E8DE;
--tertiary: #C49A3C;
--tertiary-soft: #F0E4C8;
--rose: #7A8B6A;
--rose-soft: #E0E8D8;
--success: #4A9E6E;
--warn: #B89430;
--danger: #C93D3D;
--elev-soft: 0 2px 12px rgba(35, 39, 47, 0.06);
--elev-medium: 0 4px 20px rgba(35, 39, 47, 0.08);
--elev-float: 0 8px 32px rgba(35, 39, 47, 0.12);
--focus-ring: 0 0 0 3px rgba(74, 123, 157, 0.45);
--shadow-accent: 0 4px 14px rgba(74, 123, 157, 0.25);
--shadow-accent-hover: 0 6px 20px rgba(74, 123, 157, 0.35);
--shadow-input-focus: 0 0 0 3px rgba(74, 123, 157, 0.2);
--bg-frosted: rgba(242, 243, 240, 0.85);
--theme-name: "松风";
}
/* ─────────────────────────────────────────────────────────
* Dark Mode — 暖阳 (Warm Sun) dark
* ───────────────────────────────────────────────────────── */
@media (prefers-color-scheme: dark) {
:root:not([data-theme]),
:root[data-theme="warm"] {
--bg: #1A1614;
--surface: #2A2520;
--surface-warm: #332D28;
--fg: #F0E8DF;
--fg-2: #C4B8AA;
--muted: #9B8E82;
--meta: #7A6D63;
--border: #3A3530;
--border-soft: #302B26;
--accent: #E8907A;
--accent-on: #1A1614;
--accent-hover: #D07A64;
--accent-active: #C06A54;
--accent-glow: rgba(232, 144, 122, 0.25);
--secondary: #8FBF9E;
--secondary-soft: #2A3A2E;
--tertiary: #D4B878;
--tertiary-soft: #302A1E;
--rose: #C4A0A0;
--rose-soft: #3A2A2A;
--success: #6AAF8E;
--warn: #C4A843;
--danger: #D94A4A;
--elev-soft: 0 2px 12px rgba(0, 0, 0, 0.2);
--elev-medium: 0 4px 20px rgba(0, 0, 0, 0.25);
--elev-float: 0 8px 32px rgba(0, 0, 0, 0.3);
--focus-ring: 0 0 0 3px rgba(232, 144, 122, 0.5);
--shadow-accent: 0 4px 14px rgba(232, 144, 122, 0.25);
--shadow-accent-hover: 0 6px 20px rgba(232, 144, 122, 0.35);
--shadow-input-focus: 0 0 0 3px rgba(232, 144, 122, 0.2);
--bg-frosted: rgba(26, 22, 20, 0.85);
* */
@media (prefers-color-scheme: dark) {
[data-theme="pine"] {
--bg: #14161C;
--surface: #1C1E26;
--surface-warm: #22242C;
--fg: #E4E6EC;
--fg-2: #B4B8C4;
--muted: #7E8494;
--meta: #5E6474;
--border: #282C38;
--border-soft: #1E222C;
--accent: #5A8FAD;
--accent-on: #14161C;
--accent-hover: #4A7F9D;
--accent-active: #3A6F8D;
--accent-glow: rgba(90, 143, 173, 0.25);
--secondary: #6AAE85;
--secondary-soft: #1C2E24;
--tertiary: #D4AA4C;
--tertiary-soft: #2A2618;
--rose: #8A9B7A;
--rose-soft: #242E20;
--success: #5AAE7E;
--warn: #C4A440;
--danger: #D94A4A;
--elev-soft: 0 2px 12px rgba(0, 0, 0, 0.2);
--elev-medium: 0 4px 20px rgba(0, 0, 0, 0.25);
--elev-float: 0 8px 32px rgba(0, 0, 0, 0.3);
--focus-ring: 0 0 0 3px rgba(90, 143, 173, 0.5);
--shadow-accent: 0 4px 14px rgba(90, 143, 173, 0.25);
--shadow-accent-hover: 0 6px 20px rgba(90, 143, 173, 0.35);
--shadow-input-focus: 0 0 0 3px rgba(90, 143, 173, 0.2);
--bg-frosted: rgba(20, 22, 28, 0.85);