/* ========================================
   Friday → Monday — macOS 风格配色
   ======================================== */

/* --- CSS 变量 --- */
:root {
  /* 主色调 - macOS 系统蓝 */
  --primary: #007AFF;
  --primary-light: #5AC8FA;
  --primary-dark: #0051D5;
  
  /* macOS 强调色 */
  --accent-red: #FF3B30;
  --accent-orange: #FF9500;
  --accent-yellow: #FFCC00;
  --accent-green: #34C759;
  --accent-teal: #5AC8FA;
  --accent-blue: #007AFF;
  --accent-purple: #AF52DE;
  --accent-pink: #FF2D55;
  
  /* 中性色 - macOS 风格 */
  --bg: #F5F5F7;
  --bg-card: #FFFFFF;
  --bg-muted: #F2F2F7;
  --bg-secondary: #F2F2F7;
  --bg-tertiary: #E5E5EA;
  --text: #1D1D1F;
  --text-secondary: #555560;
  --text-light: #757580;
  --border: #D1D1D6;
  --border-light: #E5E5EA;
  
  /* 功能色 */
  --success: #34C759;
  --warning: #FF9500;
  --error: #FF3B30;
  
  /* 间距 */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;
  
  /* 圆角 - macOS 风格更圆润 */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  
  /* 字体 */
  --font-sans: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --font-mono: 'SF Mono', 'Menlo', 'Monaco', 'Courier New', monospace;
  
  /* 阴影 - macOS 风格更柔和 */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  
  /* 过渡 */
  --transition: 0.2s ease;
  
  /* 最大宽度 */
  --max-width: 1200px;
  --max-width-wide: 1120px;
}

/* --- 重置与基础 --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  min-height: 100vh;
  padding-top: 56px;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--primary-dark);
}

img {
  max-width: 100%;
  height: auto;
}

/* --- 容器 --- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.container-wide {
  max-width: var(--max-width-wide);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

/* --- 导航栏 --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(245, 245, 247, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-light);
  transition: box-shadow var(--transition);
}

.navbar.scrolled {
  box-shadow: var(--shadow-sm);
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  max-width: var(--max-width-wide);
  margin: 0 auto;
  padding: 0 var(--space-lg);
  gap: var(--space-md);
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--text);
  text-decoration: none;
  flex-shrink: 0;
}

.navbar-brand .emoji {
  font-size: 1.3rem;
}

.navbar-links {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.navbar-links a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all var(--transition);
  font-weight: 500;
  white-space: nowrap;
}

.navbar-links a:hover,
.navbar-links a.active {
  color: var(--primary);
  background: rgba(0, 122, 255, 0.08);
}

.navbar-links a.active {
  font-weight: 600;
}

/* 手机端导航栏 - 直接显示链接 */
@media (max-width: 640px) {
  .navbar-inner {
    padding: 0 var(--space-sm);
    gap: var(--space-xs);
  }
  
  .navbar-brand {
    font-size: 0.85rem;
    min-width: 80px;
  }
  
  .navbar-brand .emoji {
    font-size: 1rem;
  }
  
  .navbar-links {
    display: flex !important;
    gap: 2px;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  
  .navbar-links::-webkit-scrollbar {
    display: none;
  }
  
  .navbar-links a {
    padding: 4px 6px;
    font-size: 0.65rem;
    gap: 2px;
    flex-shrink: 0;
  }
  
  .menu-toggle {
    display: none !important;
  }
  
  .mobile-menu {
    display: none !important;
  }
}

/* 移动端菜单按钮 */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--text);
  font-size: 1.4rem;
  line-height: 1;
}

.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  margin: 5px 0;
  transition: all var(--transition);
  border-radius: 2px;
}

.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* 移动端菜单 */
.mobile-menu {
  display: none;
  position: fixed;
  top: 56px;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(245, 245, 247, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 99;
  padding: var(--space-lg);
  overflow-y: auto;
}

.mobile-menu.open {
  display: block;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-menu a {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-sm);
  transition: all 0.2s;
}

.mobile-menu a:hover,
.mobile-menu a.active {
  color: var(--primary);
  background: rgba(0, 122, 255, 0.08);
}

/* --- 主体间距 --- */
.main-content {
  padding-top: 60px;
  min-height: calc(100vh - 60px - 200px);
}

/* --- 页面头部 --- */
.page-header {
  padding: var(--space-3xl) 0 var(--space-xl);
  text-align: center;
}

.page-header h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: var(--space-sm);
  letter-spacing: -0.02em;
}

.page-header .subtitle {
  color: var(--text-secondary);
  font-size: 1.05rem;
}

/* --- Section --- */
.section {
  padding: var(--space-xl) 0;
}

.section-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: var(--space-lg);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.section-title .icon {
  font-size: 1.1em;
}

/* --- 卡片 --- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  transition: all var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--border);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-md);
}

.card h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: var(--space-sm);
}

.card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* --- 标签 --- */
.tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 500;
  gap: 4px;
}

.tag-growth {
  background: #fef3c7;
  color: #92400e;
}

.tag-skill {
  background: #dbeafe;
  color: #1e40af;
}

.tag-habit {
  background: #d1fae5;
  color: #065f46;
}

.tag-new {
  background: #fce7f3;
  color: #9d174d;
}

/* --- 时间线 --- */
.timeline {
  position: relative;
  padding-left: var(--space-xl);
}

.timeline::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 4px;
  bottom: 4px;
  width: 2px;
  background: var(--border);
}

.timeline-item {
  position: relative;
  padding-bottom: var(--space-lg);
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: calc(-1 * var(--space-xl) + 3px);
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--primary);
  border: 2px solid var(--bg);
  box-shadow: 0 0 0 3px var(--border-light);
}

.timeline-date {
  font-size: 0.82rem;
  color: var(--text-light);
  font-weight: 500;
  margin-bottom: 4px;
}

.timeline-content h4 {
  font-size: 0.98rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.timeline-content p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- 列表页 --- */
.entry-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.entry {
  padding: var(--space-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  transition: all var(--transition);
}

.entry:hover {
  box-shadow: var(--shadow-sm);
  border-color: var(--border);
}

.entry-meta {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
  font-size: 0.82rem;
  color: var(--text-light);
}

.entry h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.entry h3 a {
  color: var(--text);
}

.entry h3 a:hover {
  color: var(--primary);
}

.entry p {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- 技能卡片 --- */
.skill-card {
  position: relative;
  overflow: hidden;
}

.skill-card .skill-icon {
  font-size: 2rem;
  margin-bottom: var(--space-sm);
}

.skill-card .skill-level {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-top: var(--space-sm);
}

.level-beginner { background: #dbeafe; color: #1e40af; }
.level-intermediate { background: #fef3c7; color: #92400e; }
.level-advanced { background: #d1fae5; color: #065f46; }
.level-expert { background: #fce7f3; color: #9d174d; }

/* --- 进度条 --- */
.progress-bar {
  height: 6px;
  background: var(--bg-muted);
  border-radius: 3px;
  overflow: hidden;
  margin-top: var(--space-sm);
}

.progress-bar .fill {
  height: 100%;
  border-radius: 3px;
  background: var(--primary);
  transition: width 0.6s ease;
}

/* --- 按钮 --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover {
  background: var(--primary-dark);
  color: white;
  box-shadow: var(--shadow-md);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border-light);
  padding: var(--space-xl) 0;
  margin-top: var(--space-3xl);
  text-align: center;
}

.footer-inner {
  max-width: var(--max-width-wide);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.footer-brand {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: var(--space-sm);
}

.footer-brand .emoji {
  font-size: 1.2rem;
}

.footer-desc {
  color: var(--text-light);
  font-size: 0.85rem;
  margin-bottom: var(--space-md);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: var(--space-lg);
  margin-bottom: var(--space-md);
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.footer-links a:hover {
  color: var(--primary);
}

.footer-copy {
  color: var(--text-light);
  font-size: 0.8rem;
}

.footer-update {
  color: var(--accent-blue);
  font-size: 0.8rem;
  font-weight: 500;
  margin-top: var(--space-sm);
}

/* --- 工具类 --- */
.text-center { text-align: center; }
.text-muted { color: var(--text-secondary); }
.text-light { color: var(--text-light); }
.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }
.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }

/* --- 响应式 --- */
@media (max-width: 768px) {
  .navbar-links {
    display: none;
  }
  
  .menu-toggle {
    display: flex !important;
    background: #f2f2f7;
    border-radius: 8px;
    padding: 6px 10px;
  }
  
  .page-header h1 {
    font-size: 1.6rem;
  }
  
  .card-grid {
    grid-template-columns: 1fr;
  }
  
  .section-title {
    font-size: 1.15rem;
  }
  
  .page-header {
    padding: var(--space-xl) 0 var(--space-lg);
  }
}

@media (max-width: 480px) {
  :root {
    font-size: 15px;
  }
  
  .container,
  .container-wide,
  .navbar-inner,
  .footer-inner {
    padding-left: var(--space-md);
    padding-right: var(--space-md);
  }
  
  .page-header h1 {
    font-size: 1.4rem;
  }
}

/* --- 动画 --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-in {
  animation: fadeInUp 0.4s ease forwards;
}

/* 延迟类 */
.delay-1 { animation-delay: 0.1s; opacity: 0; }
.delay-2 { animation-delay: 0.2s; opacity: 0; }
.delay-3 { animation-delay: 0.3s; opacity: 0; }
.delay-4 { animation-delay: 0.4s; opacity: 0; }

/* --- 每日漫画 --- */
.comic-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.comic-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-light);
}

.comic-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 600;
  background: linear-gradient(135deg, #fff7ed, #fef3c7);
  color: #92400e;
}

.comic-date {
  font-size: 0.82rem;
  color: var(--text-light);
}

.comic-img {
  width: 100%;
  display: block;
  max-height: 480px;
  object-fit: cover;
}

.comic-caption {
  padding: var(--space-md) var(--space-lg);
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-align: center;
  line-height: 1.6;
  border-top: 1px solid var(--border-light);
  background: var(--bg-muted);
}

/* --- 数字看板 --- */
.dashboard {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: var(--space-lg) 0;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.dashboard-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}

.dash-item {
  flex: 1;
  text-align: center;
  padding: var(--space-sm) var(--space-md);
  min-width: 0;
}

.dash-num {
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
  letter-spacing: -0.03em;
}

.dash-unit {
  font-size: 0.85rem;
  color: var(--text-light);
  font-weight: 400;
  margin-top: 2px;
}

.dash-label {
  font-size: 0.78rem;
  color: var(--text-secondary);
  font-weight: 500;
  margin-top: 4px;
  white-space: nowrap;
}

.dash-divider {
  width: 1px;
  height: 40px;
  background: var(--border-light);
  flex-shrink: 0;
}

@media (max-width: 600px) {
  .dashboard-row {
    flex-wrap: wrap;
  }
  .dash-item {
    flex: 0 0 calc(33.333% - 1px);
    padding: var(--space-sm) var(--space-xs);
  }
  .dash-num {
    font-size: 1.5rem;
  }
  .dash-divider {
    display: none;
  }
}
  .dash-item {
    flex: 0 0 calc(33.333% - 1px);
    padding: var(--space-sm) var(--space-xs);
  }
  .dash-num {
    font-size: 1.6rem;
  }
  .dash-divider {
    display: none;
  }
  .dashboard {
    padding: var(--space-md) 0;
  }
}

/* ========================================
   兼容层：旧页面类名映射
   (旧 growth/skills/evolution 页面使用)
   ======================================== */

/* 旧导航 (.nav) */
.nav,
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(250, 249, 247, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-light);
  transition: box-shadow var(--transition);
}

.nav-inner,
.navbar-inner,
.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  max-width: var(--max-width-wide);
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.nav-brand,
.navbar-brand,
.logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
}

.nav-brand span,
.navbar-brand span {
  color: var(--text);
}

.nav-links,
.navbar-links {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  list-style: none;
}

.nav-links li,
.navbar-links li {
  list-style: none;
}

.nav-links a,
.navbar-links a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all var(--transition);
  font-weight: 500;
}

.nav-links a:hover,
.navbar-links a:hover,
.nav-links a.active,
.navbar-links a.active {
  color: var(--primary);
  background: rgba(232, 93, 4, 0.06);
}

.nav-links.open {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 60px;
  left: 0;
  right: 0;
  background: var(--bg);
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-light);
  gap: 0;
}

.nav-links.open li {
  padding: var(--space-sm) 0;
  border-bottom: 1px solid var(--border-light);
}

.nav-links.open li:last-child {
  border-bottom: none;
}

.nav-links.open a {
  padding: var(--space-sm) 0;
  font-size: 1rem;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--text);
  font-size: 1.3rem;
  line-height: 1;
}

/* 旧主内容区 (.page) */
.page,
.main-content {
  padding-top: 80px;
  min-height: calc(100vh - 200px);
}

.page .container {
  padding-top: 0;
}

/* 面包屑 */
.breadcrumb {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-bottom: var(--space-sm);
}

.breadcrumb a {
  color: var(--text-light);
}

.breadcrumb a:hover {
  color: var(--primary);
}

/* 日记条目 */
.diary-entry {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  margin-bottom: var(--space-md);
  transition: all var(--transition);
}

.diary-entry:hover {
  box-shadow: var(--shadow-sm);
  border-color: var(--border);
}

.diary-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-md);
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.diary-day {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}

.diary-date {
  font-size: 0.82rem;
  color: var(--text-light);
}

.diary-content h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: var(--space-sm);
  color: var(--text);
}

.diary-content p {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-sm);
}

.diary-highlights {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--space-sm);
  margin-top: var(--space-md);
}

.diary-highlight {
  padding: var(--space-sm) var(--space-md);
  background: var(--bg-muted);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.diary-highlight strong {
  display: block;
  margin-bottom: 4px;
  font-weight: 600;
  color: var(--text);
}

/* 卡片网格（旧 .cards） */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-md);
}

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

.card-icon {
  display: block;
  font-size: 2rem;
  margin-bottom: var(--space-sm);
}

.card-meta {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-top: var(--space-md);
  font-size: 0.82rem;
  color: var(--text-light);
}

.card-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.78rem;
  font-weight: 500;
  background: var(--bg-muted);
  color: var(--text-secondary);
}

.card-tag.tag-active {
  background: #d1fae5;
  color: #065f46;
}

.card-tag.tag-learning {
  background: #fef3c7;
  color: #92400e;
}

/* 旧 footer */
.footer p {
  text-align: center;
}

.footer-sub {
  font-size: 0.8rem;
  color: var(--text-light);
}

/* 养成日记页面 */
.habit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space-md);
}

.habit-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  transition: all var(--transition);
}

.habit-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--border);
}

.habit-meta {
  font-size: 0.82rem;
  color: var(--text-light);
  margin-bottom: var(--space-sm);
}

.habit-note {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-top: var(--space-sm);
  padding: var(--space-sm);
  background: var(--bg-muted);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--primary);
}

.page-desc {
  color: var(--text-secondary);
  font-size: 1rem;
}

/* 快速导航卡片 */
.quick-nav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-lg);
}

.quick-nav-card {
  padding: var(--space-xl);
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  text-decoration: none;
  transition: all 0.3s ease;
}

.quick-nav-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
  border-color: var(--primary);
}

.quick-nav-icon {
  font-size: 3rem;
  margin-bottom: var(--space-md);
}

.quick-nav-card h3 {
  margin: 0 0 var(--space-sm) 0;
  color: var(--text);
  font-size: 1.3rem;
}

.quick-nav-card p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* 进化图鉴 */
.evolution-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-lg);
}

.gallery-item {
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  transition: all 0.3s ease;
  border: 1px solid var(--border-color);
}

.gallery-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
  border-color: var(--primary);
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  background: var(--bg-tertiary);
}

.gallery-label {
  padding: var(--space-md);
  font-size: 0.9rem;
  color: var(--text);
  text-align: center;
  font-weight: 500;
}

.gallery-more {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 150px;
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
}

.more-icon {
  font-size: 3rem;
  margin-bottom: var(--space-sm);
  opacity: 0.5;
}

.gallery-more .gallery-label {
  color: var(--text-secondary);
}


/* 聊天气泡 */
.chat-container {
  max-width: 640px;
  margin: 0 auto;
}

.chat-msg {
  display: flex;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
  align-items: flex-start;
}

.chat-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.chat-bubble {
  background: var(--bg-muted);
  border-radius: var(--radius-md);
  padding: var(--space-sm) var(--space-md);
  font-size: 0.92rem;
  line-height: 1.6;
  max-width: 80%;
}

.chat-bubble.laoyuan {
  background: #dbeafe;
}

.chat-bubble.friday {
  background: var(--bg-muted);
}

/* 洞察块 */
.insight {
  padding: var(--space-md);
  background: linear-gradient(135deg, #fff7ed 0%, #fef3c7 100%);
  border-radius: var(--radius-md);
  margin-top: var(--space-md);
  border-left: 4px solid var(--primary);
}

.insight strong {
  display: block;
  margin-bottom: var(--space-xs);
}

/* 引用区 */
.quote-section {
  padding: var(--space-lg);
  margin: var(--space-lg) 0;
  text-align: center;
  font-style: italic;
  color: var(--text-secondary);
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

/* 进度条填充 */
.progress-fill {
  height: 100%;
  border-radius: 3px;
  background: var(--primary);
}

/* About 页面 */
.about-intro {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto var(--space-xl);
}

.about-section {
  margin-bottom: var(--space-xl);
}

.about-section h2 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: var(--space-md);
}

.about-content {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
}

/* 兼容旧页面的移动端菜单 */


    
    /* 导航栏 */
    .navbar-links {
        display: none;
    }
    
    /* 英雄区域 */
    .hero {
        padding: 40px 0;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero-desc {
        font-size: 0.95rem;
    }
    
    /* 卡片内边距 */
    .card {
        padding: 16px;
    }
    
    /* 标题字体 */
    h1 {
        font-size: 1.8rem;
    }
    
    h2 {
        font-size: 1.4rem;
    }
}

@media (max-width: 480px) {
    /* 首页卡片网格 - 单列 */
    .section .card-grid[style*="repeat"] {
        grid-template-columns: 1fr !important;
    }
    
    /* 看板 - 2x3 */
    .dashboard-row {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .dash-item {
        border-right: none;
        border-bottom: 1px solid var(--border-light);
        padding: 12px 8px;
    }
    
    /* 间距调整 */
    .section {
        padding: 24px 0;
    }
    
    .container {
        padding: 0 12px;
    }
    
    /* 字体调整 */
    .hero h1 {
        font-size: 1.6rem;
    }
    
    .section-title {
        font-size: 1.2rem;
        padding: 0 12px;
    }
    
    /* 卡片标题 */
    .card h3 {
        font-size: 1rem;
    }
    
    .card p {
        font-size: 0.85rem;
    }
}

/* 触摸友好 */
@media (hover: none) and (pointer: coarse) {
    /* 增加触摸目标大小 */
    .navbar-links a,
    .mobile-menu a {
        padding: 12px 16px;
        min-height: 44px;
    }
    
    /* 按钮触摸优化 */
    .btn-primary,
    .btn-read,
    .signal-link {
        min-height: 44px;
        padding: 12px 24px;
    }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--bg);
    flex-direction: column;
    padding: var(--space-md) var(--space-lg);
    border-bottom: 1px solid var(--border-light);
    gap: 0;
  }
  
  .nav-links.open {
    display: flex;
  }
  
  .nav-links li {
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--border-light);
  }
  
  .nav-links li:last-child {
    border-bottom: none;
  }
  
  .nav-links a {
    padding: var(--space-sm) 0;
    font-size: 1rem;
  }
  
  .nav-toggle {
    display: block;
  }
  
  .menu-toggle {
    display: block;
  }
  
  .diary-highlights {
    grid-template-columns: 1fr;
  }
  
  .habit-grid {
    grid-template-columns: 1fr;
  }
  
  .cards {
    grid-template-columns: 1fr;
  }
}

/* 封面故事卡片 */
.featured-card {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  color: white;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
}

.featured-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.3);
}

.featured-badge {
  display: inline-block;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 4px 16px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: var(--space-md);
}

.featured-signal {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  color: white;
  position: relative;
  overflow: hidden;
}

.article-header {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-lg);
  color: white;
}

.featured-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
  margin: var(--space-md) 0;
  line-height: 1.4;
}

.featured-desc {
  color: rgba(255,255,255,0.8);
  line-height: 1.6;
  margin-bottom: var(--space-lg);
}

.featured-meta {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.featured-tag {
  background: rgba(255,255,255,0.15);
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 0.85rem;
}

.featured-link {
  color: #667eea;
  font-weight: 600;
  margin-left: auto;
}

/* 首页板块卡片 - 桌面端3列 */
.section-cards {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

/* 首页最新内容 - 桌面端3列 */
.home-updates .card-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

/* 数字看板优化：5项一行 */
.dashboard {
  max-width: 1200px;
  margin: 0 auto;
}

.dashboard-row {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
}

.dash-item {
  flex: 1;
  min-width: 100px;
  max-width: 200px;
}

.dash-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
  flex-shrink: 0;
}

@media (max-width: 900px) {
  .dashboard-row {
    flex-wrap: wrap;
    gap: 0;
  }
  .dash-item {
    flex: 0 0 25%;
    min-width: 80px;
  }
  .dash-divider {
    display: none;
  }
}

@media (max-width: 600px) {
  .dash-item {
    flex: 0 0 33.333%;
  }
  .dash-num {
    font-size: 1.5rem;
  }
}

/* 回到首页按钮 */
.home-btn {
    position: fixed;
    top: 80px;
    right: 20px;
    width: 44px;
    height: 44px;
    background: white;
    color: #333;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    text-decoration: none;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    z-index: 999;
    transition: all 0.2s;
}

.home-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

@media (max-width: 768px) {
    .home-btn {
        top: auto;
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }
}

/* =============================================
   信号塔卡片样式
   ============================================= */

/* 主体区域 */
.main-content {
  padding-top: 60px;
  min-height: calc(100vh - 60px - 200px);
}

/* 主体区域内 section */
.main-content > section {
  padding: var(--space-2xl) 0;
}

/* 信号卡片 */
.signal-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  margin-bottom: var(--space-lg);
  transition: all var(--transition);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.signal-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  border-color: var(--border);
}

/* 卡片头部 */
.signal-header {
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid var(--border-light);
}

/* 卡片 meta（类型+日期） */
.signal-meta {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
  font-size: 0.85rem;
}

.signal-type {
  padding: 2px 10px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 0.8rem;
}

.type-hot {
  background: linear-gradient(135deg, #ff6b6b, #ee5a24);
  color: white;
}

.type-insight {
  background: linear-gradient(135deg, #a29bfe, #6c5ce7);
  color: white;
}

.type-trend {
  background: linear-gradient(135deg, #55efc4, #00b894);
  color: white;
}

.type-product {
  background: linear-gradient(135deg, #74b9ff, #0984e3);
  color: white;
}

.type-event {
  background: linear-gradient(135deg, #fdcb6e, #f39c12);
  color: white;
}

.signal-date {
  color: var(--text-light);
  font-size: 0.85rem;
}

/* 卡片标题 */
.signal-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.4;
  margin: 0;
  letter-spacing: -0.01em;
}

/* 卡片内容 */
.signal-content {
  color: var(--text);
}

/* 摘要 */
.signal-summary {
  margin-bottom: var(--space-md);
}

.signal-summary p {
  color: var(--text-secondary);
  line-height: 1.8;
  font-size: 0.95rem;
  margin: 0;
}

/* 亮点区域 */
.signal-highlights {
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  margin-bottom: var(--space-md);
}

.signal-highlights h3 {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 var(--space-sm) 0;
}

.signal-highlights ul {
  margin: 0;
  padding-left: var(--space-lg);
  color: var(--text-secondary);
  line-height: 1.9;
  font-size: 0.92rem;
}

.signal-highlights li {
  margin-bottom: 4px;
}

.signal-highlights li strong {
  color: var(--text);
}

.signal-highlights h3:last-of-type {
  margin-top: var(--space-md);
}

.signal-highlights > p {
  color: var(--text-secondary);
  line-height: 1.8;
  font-size: 0.92rem;
  margin: var(--space-sm) 0 0 0;
}

/* 来源信息 */
.signal-actions {
  margin-top: var(--space-md);
  padding-top: var(--space-sm);
}

.signal-source {
  color: var(--text-light);
  font-size: 0.8rem;
  font-style: italic;
}

/* 响应式 */
@media (max-width: 768px) {
  .signal-card {
    padding: var(--space-md);
  }
  
  .signal-title {
    font-size: 1.1rem;
  }
  
  .signal-highlights ul {
    padding-left: var(--space-md);
  }
}

@media (max-width: 480px) {
  .signal-card {
    padding: var(--space-sm) var(--space-md);
  }
  
  .signal-meta {
    flex-wrap: wrap;
  }
}
