design-system.css 3.43 KB
/* ========================================
   BettaFish 设计系统
   Digital Archive 美学 - 档案馆绿 + 黄铜色
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;600&family=Playfair+Display:wght@400;500;600;700&family=Noto+Sans+SC:wght@400;500;700&family=Noto+Serif+SC:wght@600;700&display=swap');

:root {
  /* ===== 色彩系统 ===== */

  /* 主色调:深邃档案馆绿 */
  --primary: #0D211C;
  --primary-light: #1A3D32;
  --primary-soft: #2D5A47;

  /* 强调色:温暖黄铜色 */
  --accent: #C4956A;
  --accent-light: #D4AA7D;

  /* 功能色 */
  --success: #3D8B6E;
  --warning: #B8863B;
  --danger: #A34A3A;
  --info: #4A7B9B;

  /* 背景层次 */
  --bg-base: #F5F0E8;
  --bg-elevated: #FAF7F2;
  --bg-deep: #EDE8E0;

  /* 文字层次 */
  --text-primary: #0D211C;
  --text-secondary: #4A6B5D;
  --text-muted: #8A9E94;
  --text-inverse: #F5F0E8;

  /* 边框 */
  --border-subtle: rgba(13, 33, 28, 0.08);
  --border-medium: rgba(13, 33, 28, 0.15);
  --border-strong: rgba(13, 33, 28, 0.25);

  /* 阴影 */
  --shadow-sm: 0 2px 8px rgba(13, 33, 28, 0.06);
  --shadow-md: 0 8px 24px rgba(13, 33, 28, 0.1);
  --shadow-lg: 0 16px 48px rgba(13, 33, 28, 0.14);

  /* ===== 字体系统 ===== */
  --font-display: 'Playfair Display', 'Noto Serif SC', serif;
  --font-body: 'DM Sans', 'Noto Sans SC', sans-serif;
  --font-mono: 'JetBrains Mono', 'IBM Plex Mono', monospace;

  /* ===== 间距系统 ===== */
  --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-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-2xl: 32px;
  --radius-full: 9999px;

  /* ===== 布局尺寸 ===== */
  --cmd-bar-height: 64px;
  --sidebar-width: 280px;
  --feed-width: 320px;
}

/* ===== 全局重置 ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
}

#app {
  min-height: 100vh;
  position: relative;
}

/* ===== Selection ===== */
::selection {
  background: rgba(196, 149, 106, 0.3);
  color: var(--text-primary);
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-thumb {
  background: rgba(13, 33, 28, 0.2);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-track {
  background: rgba(13, 33, 28, 0.05);
}

/* ===== Focus ===== */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ===== Typography ===== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  color: var(--text-primary);
}

p {
  line-height: 1.7;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ===== Buttons ===== */
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* ===== Images ===== */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ===== Inputs ===== */
input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
}