/* 布局样式 - 深色模式 */

/* 健康小知识模块样式 */
.health-tips-list {
  display: grid;
  gap: 1.2rem;
  margin: 2rem 0;
}

.health-tips-list[data-columns="1"] {
  grid-template-columns: 1fr;
}

.health-tips-list[data-columns="2"] {
  grid-template-columns: repeat(2, 1fr);
}

.health-tips-list[data-columns="3"] {
  grid-template-columns: repeat(3, 1fr);
}

.health-tips-list[data-columns="4"] {
  grid-template-columns: repeat(4, 1fr);
}

.health-tip-card {
  background: var(--surface-color);
  border-radius: 6px;
  padding: 1.2rem;
  transition: all 0.3s ease;
  display: flex;
  gap: 1rem;
  border: 1px solid var(--border-color);
}

.health-tip-card:hover {
  border-color: var(--primary-color);
  box-shadow: 0 2px 8px rgba(var(--primary-color-rgb), 0.2);
}

.health-tip-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(var(--primary-color-rgb), 0.15);
  color: var(--primary-color);
  border-radius: 4px;
  font-size: 1.1rem;
  transition: all 0.3s ease;
}

.health-tip-card:hover .health-tip-icon {
  background: rgba(var(--primary-color-rgb), 0.25);
}

.health-tip-content {
  flex: 1;
}

.health-tip-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 0.4rem 0;
  color: var(--text-color);
  transition: color 0.3s ease;
}

.health-tip-card:hover .health-tip-title {
  color: var(--primary-color);
}

.health-tip-text {
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0 0 0.6rem 0;
}

.health-tip-category {
  display: inline-block;
  font-size: 0.7rem;
  padding: 0.2rem 0.6rem;
  background: rgba(var(--primary-color-rgb), 0.15);
  color: var(--primary-color);
  border-radius: 4px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.health-tip-card:hover .health-tip-category {
  background: rgba(var(--primary-color-rgb), 0.25);
}

/* 响应式设计 */
@media (max-width: 768px) {
  .health-tips-list[data-columns="2"],
  .health-tips-list[data-columns="3"],
  .health-tips-list[data-columns="4"] {
    grid-template-columns: 1fr;
  }
  
  .health-tip-card {
    flex-direction: column;
    text-align: center;
  }
  
  .health-tip-icon {
    align-self: center;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .health-tips-list[data-columns="3"],
  .health-tips-list[data-columns="4"] {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* 健康小知识小工具样式 */
.widget_health_tips .health-tips-list {
  margin: 0;
  gap: 0.8rem;
}

.widget_health_tips .health-tip-card {
  padding: 0.8rem;
  flex-direction: column;
  text-align: center;
}

.widget_health_tips .health-tip-icon {
  align-self: center;
  width: 36px;
  height: 36px;
  font-size: 0.9rem;
}

.widget_health_tips .health-tip-title {
  font-size: 0.9rem;
  margin: 0.4rem 0 0.2rem;
}

.widget_health_tips .health-tip-text {
  font-size: 0.75rem;
  margin: 0 0 0.4rem;
}

.widget_health_tips .health-tip-category {
  font-size: 0.65rem;
  padding: 0.15rem 0.5rem;
}


/* 头部样式 */
:root.dark-mode .header {
  background-color: var(--surface-color);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  min-height: 60px;
  display: flex;
  align-items: center;
  transition: background-color var(--transition-normal), box-shadow var(--transition-normal);
}

:root.dark-mode .header.scrolled {
  background-color: rgba(17, 24, 39, 0.95);
}

/* 当管理栏显示时，调整 header 位置 */
:root.dark-mode body.admin-bar .header {
  top: 32px;
}

:root.dark-mode .header .container {
  display: flex;
  align-items: center;
  width: 100%;
  height: 100%;
}

:root.dark-mode .header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0;
  flex-wrap: nowrap;
  height: 100%;
  width: 100%;
}

/* 确保所有header子元素垂直居中 */
:root.dark-mode .header-container > * {
  display: flex;
  align-items: center;
  height: 100%;
}

/* 确保nav内部元素垂直居中 */
:root.dark-mode .nav > * {
  display: flex;
  align-items: center;
  height: 100%;
}

/* 导航区域 */
:root.dark-mode .nav {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  flex: 1;
  justify-content: flex-end;
  height: 100%;
}

/* 按钮区域 */
:root.dark-mode .nav-buttons {
  display: flex;
  align-items: center;
  height: 100%;
  gap: 0;
  padding: 0;
  margin: 0;
}

:root.dark-mode .nav-buttons > * {
  flex-shrink: 0;
}

:root.dark-mode .site-logo {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  height: 100%;
  padding: 0 var(--spacing-md);
  flex-shrink: 0;
  z-index: 1;
}

/* 站点标志 */
:root.dark-mode .site-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-color);
  transition: color var(--transition-fast);
}

:root.dark-mode .site-title:hover {
  color: var(--primary-color);
}

/* 导航菜单 */
:root.dark-mode .nav-menu {
  display: flex;
  gap: var(--spacing-sm);
  list-style: none;
  height: 100%;
  align-items: center;
  margin: 0 0 0 6px;
  padding-right: 6px;
  border-right: 1px solid var(--border-color);
}

:root.dark-mode .nav-menu li {
  display: flex;
  align-items: center;
}

:root.dark-mode .nav-menu li a {
  color: var(--text-color);
  font-weight: 500;
  font-size: 0.875rem;
  transition: color var(--transition-fast);
  position: relative;
  display: inline-block;
  padding: 12px 8px;
  height: 100%;
  box-sizing: border-box;
}

:root.dark-mode .nav-menu li a:hover {
  color: var(--primary-color);
}

/* 边框容器 */
:root.dark-mode .nav-menu li a::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid transparent;
  transition: all var(--transition-normal);
  pointer-events: none;
}

/* 悬停时的边框动画效果 */
:root.dark-mode .nav-menu li a:hover::before {
  animation: border-animation 0.8s ease-in-out forwards;
}

/* 汉堡菜单 */
:root.dark-mode .mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.25rem;
  cursor: pointer;
  color: var(--text-color);
  padding: var(--spacing-md);
  height: 100%;
  transition: color var(--transition-fast), background-color var(--transition-fast);
  z-index: 1001;
  position: relative;
}

:root.dark-mode .mobile-menu-toggle:hover {
  color: var(--primary-color);
  background-color: rgba(255, 255, 255, 0.1);
}

/* 导航按钮通用样式（包括主题切换、搜索等按钮） */
:root.dark-mode .nav-buttons button {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-color);
  font-weight: 500;
  font-size: 0.875rem;
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  transition: color var(--transition-fast), background-color var(--transition-fast);
  box-sizing: border-box;
}

:root.dark-mode .nav-buttons button:hover {
  color: var(--primary-color);
}

/* 搜索按钮特殊处理 - 鼠标经过时不改变背景 */
:root.dark-mode .nav-buttons .search-toggle:hover {
  background-color: transparent;
}

/* 按钮图标样式 */
:root.dark-mode .nav-buttons button i {
  font-size: 1rem; /* 调整图标大小以匹配菜单项字体 */
  display: block;
}

/* 主题切换滑块 */
:root.dark-mode .theme-toggle-slider {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 12px;
}

:root.dark-mode .theme-toggle-checkbox {
  display: none;
}

:root.dark-mode .theme-toggle-label {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 20px;
  background-color: #ccc;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color var(--transition-fast);
}

:root.dark-mode .theme-toggle-handle {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background-color: white;
  border-radius: 2px;
  transition: transform var(--transition-fast);
}

/* 主题切换动画 */
:root.dark-mode .theme-toggle-label {
  transition: background-color 0.3s ease;
}

:root.dark-mode .theme-toggle-handle {
  transition: transform 0.3s ease;
}

/* 当复选框被选中时，移动滑块 */
:root.dark-mode .theme-toggle-checkbox:checked + .theme-toggle-label {
  background-color: var(--primary-color);
}

:root.dark-mode .theme-toggle-checkbox:checked + .theme-toggle-label .theme-toggle-handle {
  transform: translateX(20px);
}

/* 主内容区 */
:root.dark-mode .main-content {
  background-color: var(--background-color);
  position: relative;
  z-index: 1;
}

/* 侧边栏 */
:root.dark-mode .sidebar {
  width: 100%;
  position: sticky;
  top: 85px;
}

:root.dark-mode .widget-area {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-lg);
}

:root.dark-mode .widget {
  width: 100%;
  box-sizing: border-box;
  border-radius: 2px;
  /* padding: var(--spacing-lg); */
  border: 1px solid var(--border-color);
}

:root.dark-mode .widget-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
  padding-bottom: var(--spacing-sm);
  border-bottom: 2px solid var(--primary-color);
  color: var(--text-color);
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

:root.dark-mode .widget-title::before {
  content: '';
  width: 4px;
  height: 20px;
  background-color: var(--primary-color);
  border-radius: 2px;
}

:root.dark-mode .widget-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--secondary-color);
  transition: width var(--transition-normal);
}

:root.dark-mode .widget:hover .widget-title::after {
  width: 100%;
}

/* 小工具列表样式 - 深色模式 */
:root.dark-mode .widget ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

:root.dark-mode .widget li {
  padding: var(--spacing-xs) 0;
  border-bottom: 1px solid var(--border-color);
  transition: all var(--transition-fast);
}

:root.dark-mode .widget li:last-child {
  border-bottom: none;
}

:root.dark-mode .widget li:hover {
  padding-left: var(--spacing-sm);
}

:root.dark-mode .widget li a {
  color: var(--text-color);
  text-decoration: none;
  transition: color var(--transition-fast);
  display: block;
}

:root.dark-mode .widget li a:hover {
  color: var(--primary-color);
}

/* 搜索小工具 - 深色模式 */
:root.dark-mode .widget_search form {
  display: flex;
  gap: var(--spacing-sm);
}

:root.dark-mode .widget_search input[type="search"] {
  flex: 1;
  padding: var(--spacing-sm) var(--spacing-md);
  border: 1px solid var(--border-color);
  border-radius: 2px;
  background-color: var(--background-color);
  color: var(--text-color);
  transition: all var(--transition-fast);
}

:root.dark-mode .widget_search input[type="search"]:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(var(--primary-color-rgb), 0.2);
}

:root.dark-mode .widget_search input[type="submit"] {
  padding: var(--spacing-sm) var(--spacing-md);
  background-color: var(--primary-color);
  color: white;
  border: none;
  border-radius: 2px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

:root.dark-mode .widget_search input[type="submit"]:hover {
  background-color: var(--secondary-color);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

/* 分类小工具 - 深色模式 */
:root.dark-mode .widget_categories li {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

:root.dark-mode .widget_categories .count {
  background-color: var(--background-color);
  padding: 2px 8px;
  border-radius: 2px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* 最新文章小工具 - 深色模式 */
:root.dark-mode .widget_recent_entries li {
  position: relative;
}

:root.dark-mode .widget_recent_entries li::before {
  content: "→";
  position: absolute;
  left: -10px;
  opacity: 0;
  transition: opacity var(--transition-fast), transform var(--transition-fast);
  color: var(--primary-color);
}

:root.dark-mode .widget_recent_entries li:hover::before {
  opacity: 1;
  transform: translateX(5px);
}

/* 面包屑导航 */
:root.dark-mode .breadcrumb {
  padding: 0 !important;
  font-size: 0.875rem !important;
  color: var(--text-secondary) !important;
  margin: 0 0 var(--spacing-md) !important;
  background: none !important;
  border-radius: 0 !important;
  display:grid !important
}

:root.dark-mode .breadcrumb-text {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 4px;
  justify-content: flex-start;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
}

:root.dark-mode .breadcrumb-separator {
  margin: 0 4px;
  color: var(--text-secondary);
  font-size: 12px;
}

:root.dark-mode .breadcrumb-link {
  color: var(--text-color);
  text-decoration: none;
  transition: color var(--transition-fast);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 150px;
  display: inline-block;
  vertical-align: bottom;
}

:root.dark-mode .breadcrumb-link:hover {
  color: var(--primary-color);
  text-decoration: none;
}

:root.dark-mode .breadcrumb-current {
  color: var(--text-secondary);
  font-weight: normal;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
  display: inline-block;
  vertical-align: bottom;
}

/* 页脚 */
:root.dark-mode .footer {
  background-color: var(--background-color);
  border-top: 1px solid var(--border-color);
  position: relative;
  z-index: 1;
}

:root.dark-mode .footer-bottom {
  width: 100%;
  text-align: center;
  padding: var(--spacing-lg) 0;
  color: var(--text-secondary);
  font-size: 0.875rem;
}

/* 备案信息样式 - 深色模式 */
:root.dark-mode .footer-beian {
  margin-top: var(--spacing-md);
  display: flex;
  justify-content: center;
  gap: var(--spacing-md);
  flex-wrap: wrap;
}

:root.dark-mode .beian-link {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color var(--transition-fast);
  font-size: 0.75rem;
}

:root.dark-mode .beian-link:hover {
  color: var(--primary-color);
  text-decoration: none;
}

/* 统计代码样式 - 深色模式 */
:root.dark-mode .footer-analytics {
  margin-top: var(--spacing-md);
  font-size: 0;
  line-height: 0;
}

/* 文章详情页 */
:root.dark-mode .single-posts {
  background-color: var(--surface-color);
  box-shadow: var(--shadow-sm);
}

:root.dark-mode .post-title {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.4;
  text-align: left;
  margin: 15px 0 25px;
  padding-bottom: 8px;
  color: var(--text-color);
  border-bottom: 3px solid var(--primary-color);
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
  transition: all 0.3s ease;
}

:root.dark-mode .post-title:hover {
  color: var(--primary-color);
  border-bottom-color: var(--secondary-color);
}

:root.dark-mode .post-meta {
  color: var(--text-secondary);
}

:root.dark-mode .post-content {
  margin-bottom: var(--spacing-xl);
  text-indent: 2rem;
  color: var(--text-color);
  line-height: 1.6;
}

:root.dark-mode .post-content p {
  margin-bottom: var(--spacing-md);
  line-height: 1.6;
}

:root.dark-mode .post-content img {
  display: block;
  margin: var(--spacing-lg) auto;
  border-radius: 2px;
  box-shadow: var(--shadow-sm);
  max-width: 75%;
  height: auto;
  cursor: pointer;
  transition: transform 0.3s ease;
}

:root.dark-mode .post-content img:hover {
  transform: scale(1.02);
}

/* 文章页标题样式 - 深色模式 */
:root.dark-mode .post-content h1,
:root.dark-mode .post-content h2,
:root.dark-mode .post-content h3,
:root.dark-mode .post-content h4,
:root.dark-mode .post-content h5,
:root.dark-mode .post-content h6 {
  position: relative;
  margin: 1.5rem 0 1rem;
  padding-left: 12px;
  border-left: 4px solid var(--primary-color);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 8px;
  font-weight: 600;
  color: var(--text-color);
}

:root.dark-mode .post-content h1 {
  font-size: 1.25rem;
}

:root.dark-mode .post-content h2 {
  font-size: 1.125rem;
}

:root.dark-mode .post-content h3 {
  font-size: 1rem;
}

:root.dark-mode .post-content h4 {
  font-size: 0.9375rem;
}

:root.dark-mode .post-content h5 {
  font-size: 0.875rem;
}

:root.dark-mode .post-content h6 {
  font-size: 0.8125rem;
}

:root.dark-mode .post-content ul {
  padding-left: 3rem;
}

/* 文章导航 */
:root.dark-mode .post-navigation {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  padding-top: var(--spacing-lg);
  border-top: 1px solid var(--border-color);
}

:root.dark-mode .post-navigation a {
  color: var(--text-color);
  transition: color var(--transition-fast);
  font-size: 0.875rem;
}

:root.dark-mode .post-navigation a:hover {
  color: var(--primary-color);
}

/* 分页 */
:root.dark-mode .pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--spacing-md);
  margin: var(--spacing-2xl) 0;
}

:root.dark-mode .pagination a, .pagination span {
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: 2px;
  transition: all var(--transition-fast);
}

:root.dark-mode .pagination a {
  background-color: var(--surface-color);
  color: var(--text-color);
}

:root.dark-mode .pagination a:hover {
  background-color: var(--primary-color);
  color: white;
}

:root.dark-mode .pagination .current {
  background-color: var(--primary-color);
  color: white;
}

/* 侧边按钮 */
:root.dark-mode .side-button {
  background-color: var(--primary-color);
  color: white;
  box-shadow: var(--shadow-md);
}

:root.dark-mode .side-button:hover {
  background-color: var(--secondary-color);
  box-shadow: var(--shadow-lg);
}





/* 搜索弹窗 */
:root.dark-mode #search-modal-overlay {
  background-color: rgba(0, 0, 0, 0.7);
}

:root.dark-mode .search-popup-container {
  background-color: var(--surface-color);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

:root.dark-mode .search-popup-close {
  color: var(--text-color);
}

:root.dark-mode .search-popup-close:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--primary-color);
}

:root.dark-mode .search-popup-content {
  background-color: var(--surface-color);
}

:root.dark-mode .search-type-switch {
  background-color: var(--background-color);
}

:root.dark-mode .search-type-item {
  color: var(--text-secondary);
}

:root.dark-mode .search-type-item.active {
  color: var(--text-color);
}

:root.dark-mode .search-type-slider {
  background-color: var(--surface-color);
  box-shadow: var(--shadow-sm);
}

:root.dark-mode #fox-search-input {
  background-color: var(--background-color);
  color: var(--text-color);
  border-color: var(--border-color);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

:root.dark-mode #fox-search-input:focus {
  border-color: var(--primary-color);
  box-shadow: 0 4px 8px rgba(var(--primary-color-rgb), 0.2);
}

:root.dark-mode #fox-search-input::placeholder {
  color: var(--text-secondary);
}

:root.dark-mode .search-btn-submit {
  background-color: var(--primary-color);
  color: white;
}

:root.dark-mode .search-btn-submit:hover {
  background-color: var(--secondary-color);
}

:root.dark-mode .section-title {
  color: var(--text-color);
}

:root.dark-mode .section-action {
  color: var(--text-secondary);
}

:root.dark-mode .section-action:hover {
  color: var(--primary-color);
}

:root.dark-mode .search-tag-item {
  background-color: var(--background-color);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
}

:root.dark-mode .search-tag-item:hover {
  background-color: rgba(var(--primary-color-rgb), 0.1);
  border-color: var(--primary-color);
  color: var(--primary-color);
}

/* 加载动画 */
:root.dark-mode .loading-spinner {
  border-color: var(--border-color);
  border-top-color: var(--primary-color);
}

/* 404页面 */
:root.dark-mode .error-404 {
  text-align: center;
  padding: var(--spacing-2xl) 0;
}

:root.dark-mode .error-404 h1 {
  font-size: 4rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: var(--spacing-lg);
}

:root.dark-mode .error-404 p {
  font-size: 1.125rem;
  margin-bottom: var(--spacing-xl);
}

/* 归档页面 */
:root.dark-mode .archive-header {
  margin-bottom: var(--spacing-2xl);
  padding-bottom: var(--spacing-lg);
  border-bottom: 1px solid var(--border-color);
}

:root.dark-mode .archive-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: var(--spacing-md);
}

/* 分类页面 */
:root.dark-mode .category-header {
  margin-bottom: var(--spacing-2xl);
  padding-bottom: var(--spacing-lg);
  border-bottom: 1px solid var(--border-color);
}

:root.dark-mode .category-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: var(--spacing-md);
}

:root.dark-mode .category-description {
  color: var(--text-secondary);
  font-size: 1rem;
}

/* 标签页面 */
:root.dark-mode .tag-header {
  margin-bottom: var(--spacing-2xl);
  padding-bottom: var(--spacing-lg);
  border-bottom: 1px solid var(--border-color);
}

:root.dark-mode .tag-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: var(--spacing-md);
}

/* 作者页面 */
:root.dark-mode .author-header {
  margin-bottom: var(--spacing-2xl);
  padding-bottom: var(--spacing-lg);
  border-bottom: 1px solid var(--border-color);
}

:root.dark-mode .author-avatar {
  width: 100px;
  height: 100px;
  border-radius: 2px;
  margin-bottom: var(--spacing-md);
  object-fit: cover;
}

:root.dark-mode .author-name {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: var(--spacing-sm);
}

:root.dark-mode .author-description {
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: var(--spacing-md);
}



/* 阅读时间 */
:root.dark-mode .reading-time {
  color: var(--text-secondary);
}

/* 文章列表 */
:root.dark-mode .posts-grid {
  gap: var(--spacing-lg);
}

/* 文章卡片 */
:root.dark-mode .post-card {
  background-color: var(--surface-color);
  box-shadow: var(--shadow-sm);
}

:root.dark-mode .post-card:hover {
  box-shadow: var(--shadow-md);
}

/* 文章卡片标题 */
:root.dark-mode .post-card-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: var(--spacing-md);
  line-height: 1.3;
}

:root.dark-mode .post-card-title a {
  color: var(--text-color);
  transition: color var(--transition-fast);
}

:root.dark-mode .post-card-title a:hover {
  color: var(--primary-color);
}

/* 文章卡片摘要 */
:root.dark-mode .post-card-excerpt {
  color: var(--text-secondary);
  font-size: 0.875rem;
  line-height: 1.5;
  margin-bottom: var(--spacing-md);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

/* 文章卡片元信息 */
:root.dark-mode .post-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-md);
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: auto;
}

:root.dark-mode .post-category a {
  color: var(--text-secondary);
}

:root.dark-mode .post-category a:hover {
  color: var(--primary-color);
}

/* 文章详情页标签 - 深色模式 */
:root.dark-mode .post-tags {
  margin: var(--spacing-lg) 0 0;
  padding: var(--spacing-md);
  font-size: 0.875rem;
}

:root.dark-mode .tags-label {
  font-weight: 600;
  color: var(--text-color);
  margin-right: var(--spacing-sm);
}

:root.dark-mode .post-tags a {
  color: var(--primary-color);
  transition: color var(--transition-fast);
}

:root.dark-mode .post-tags a:hover {
  color: var(--secondary-color);
  text-decoration: none;
}

/* 评论区域 */
:root.dark-mode .post-comments {
  border-top: 1px solid var(--border-color);
}

:root.dark-mode .xinzhiji-comments-section {
  background-color: var(--surface-color);
  box-shadow: var(--shadow-sm);
}

:root.dark-mode .xinzhiji-comments-title {
  color: var(--text-color);
  border-bottom: 2px solid var(--primary-color);
}

:root.dark-mode .xinzhiji-comment-item {
  border-bottom: 1px solid var(--border-color);
}

:root.dark-mode .xinzhiji-comment-author {
  color: var(--text-color);
}

:root.dark-mode .xinzhiji-comment-meta-row {
  color: var(--text-secondary);
}

:root.dark-mode .xinzhiji-comment-date a {
  color: var(--text-secondary);
}

:root.dark-mode .xinzhiji-comment-date a:hover {
  color: var(--primary-color);
}

:root.dark-mode .xinzhiji-comment-edit a {
  color: var(--text-secondary);
}

:root.dark-mode .xinzhiji-comment-edit a:hover {
  color: var(--primary-color);
}

:root.dark-mode .xinzhiji-comment-reply a {
  color: var(--primary-color);
}

:root.dark-mode .xinzhiji-comment-reply a:hover {
  color: var(--secondary-color);
}

:root.dark-mode .xinzhiji-comment-location {
  background: var(--surface-color);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
}

:root.dark-mode .xinzhiji-comment-awaiting-moderation {
  color: var(--warning-color);
}

:root.dark-mode .xinzhiji-comment-text {
  color: var(--text-color);
}

/* 评论表单 */
:root.dark-mode .xinzhiji-comment-form {
  background-color: var(--surface-color);
}

:root.dark-mode .xinzhiji-comment-form h3 {
  color: var(--text-color);
}

:root.dark-mode .xinzhiji-comment-form-field input,
:root.dark-mode .xinzhiji-comment-form-field textarea {
  background-color: var(--background-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

:root.dark-mode .xinzhiji-comment-form-field input:focus,
:root.dark-mode .xinzhiji-comment-form-field textarea:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(var(--primary-color-rgb), 0.1);
}

:root.dark-mode .xinzhiji-comment-submit-btn {
  background-color: var(--primary-color);
}

:root.dark-mode .xinzhiji-comment-submit-btn:hover {
  background-color: var(--secondary-color);
  box-shadow: var(--shadow-sm);
}

/* 评论导航 */
:root.dark-mode .comment-navigation {
  border-top: 1px solid var(--border-color);
}

:root.dark-mode .comment-navigation a {
  color: var(--primary-color);
}

:root.dark-mode .comment-navigation a:hover {
  color: var(--secondary-color);
}

:root.dark-mode .xinzhiji-comments-closed {
  color: var(--text-secondary);
  background-color: var(--background-color);
}

/* 无文章提示 */
:root.dark-mode .no-posts {
  color: var(--text-secondary);
}

:root.dark-mode .no-posts h2 {
  color: var(--text-color);
}

/* 健康小知识小工具 */
:root.dark-mode .widget_xinzhiji_health_tips_widget {
  width: 100%;
  box-sizing: border-box;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tips-list {
  margin: 0;
  gap: 1.2rem;
  display: flex;
  flex-direction: column;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-card {
  padding: 1.5rem;
  flex-direction: column;
  text-align: left;
  background: var(--surface-color);
  border: none;
  border-radius: 0;
  transition: none;
  box-shadow: none;
  gap: 0.8rem;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-card:hover {
  border-color: transparent;
  box-shadow: none;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-icon {
  display: none;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-content {
  flex: 1;
  width: 100%;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.6rem;
  color: var(--text-color);
  line-height: 1.4;
  transition: none;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-card:hover .health-tip-title {
  color: var(--text-color);
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-text {
  font-size: 0.9rem;
  margin: 0 0 0.8rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-category {
  font-size: 0.7rem;
  padding: 0.2rem 0.8rem;
  background: rgba(var(--primary-color-rgb), 0.1);
  color: var(--primary-color);
  border-radius: 12px;
  font-weight: 500;
  align-self: flex-start;
  transition: none;
}

:root.dark-mode .widget_xinzhiji_health_tips_widget .health-tip-card:hover .health-tip-category {
  background: rgba(var(--primary-color-rgb), 0.1);
}

/* 我的名片小工具 */
:root.dark-mode .my-card {
  text-align: center;
  padding: var(--spacing-lg);
}

:root.dark-mode .my-card-avatar {
  margin-bottom: var(--spacing-md);
  display: flex;
  justify-content: center;
  align-items: center;
}

:root.dark-mode .my-card-avatar img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--primary-color);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

:root.dark-mode .my-card-avatar img:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-md);
}

:root.dark-mode .my-card-name {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: var(--spacing-xs);
  color: var(--text-color);
}

:root.dark-mode .my-card-screen-name {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
}

:root.dark-mode .my-card-description {
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--text-color);
  margin-bottom: var(--spacing-md);
}

:root.dark-mode .my-card-social {
  display: flex;
  justify-content: center;
  gap: var(--spacing-md);
  margin-top: var(--spacing-md);
  padding-top: var(--spacing-md);
  border-top: 1px solid var(--border-color);
}

:root.dark-mode .my-card-social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-color: var(--background-color);
  color: var(--text-color);
  border-radius: 2px;
  font-size: 1.25rem;
  transition: all 0.3s ease;
  text-decoration: none;
  border: 1px solid var(--border-color);
}

:root.dark-mode .my-card-social-link:hover {
  background-color: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
  transform: translateY(-2px);
}

/* 微信二维码样式 - 深色模式 */
:root.dark-mode .wechat-qr-code {
  background-color: var(--background-color);
  border-color: var(--border-color);
}

:root.dark-mode .wechat-qr-code::after {
  border-color: transparent transparent var(--background-color) transparent;
  border-bottom-color: var(--border-color);
}

:root.dark-mode .wechat-qr-code::before {
  border-color: transparent transparent var(--background-color) transparent;
}

/* 彩色标签小工具 */
:root.dark-mode .colorful-tags-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm);
  background-color: var(--background-color);
  border-radius: 2px;
}

:root.dark-mode .colorful-tag {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 2px;
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: 500;
  font-size: 14px;
}

/* 彩色标签 - 与 zhiji 主题一致的颜色方案 */
:root.dark-mode .colorful-tag:nth-child(4n+1) {
  background-color: #ff6b6b;
  color: white;
}

:root.dark-mode .colorful-tag:nth-child(4n+2) {
  background-color: #4ecdc4;
  color: white;
}

:root.dark-mode .colorful-tag:nth-child(4n+3) {
  background-color: #45b7d1;
  color: white;
}

:root.dark-mode .colorful-tag:nth-child(4n+4) {
  background-color: #96ceb4;
  color: #333;
}

:root.dark-mode .colorful-tag:hover {
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
  opacity: 0.8;
  transform: translateY(-2px);
}

:root.dark-mode .colorful-tag:active {
  transform: translateY(0);
}






