/* 现代化主题增强样式（覆盖 main.css 的视觉风格） */

/* 基础布局与头部 */
.header {
  background: var(--surface);
  box-shadow: var(--shadow);
  border-radius: var(--radius);
}

.header-content { gap: 12px; }

.logo {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--text);
}

.user-info { gap: 10px; }

.logout-btn {
  background: var(--danger);
  border-radius: 10px;
}

/* 主题切换按钮 */
.theme-toggle {
  padding: 8px 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 10px;
  cursor: pointer;
}
.theme-toggle:hover { border-color: var(--primary); }

/* 内容容器 */
.content {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* 内容头部排版修复与美化 */
.content-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.breadcrumb-item {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
}
.breadcrumb-item:hover { background: rgba(99,102,241,0.08); border-color: var(--primary); }
.breadcrumb-separator { color: var(--text-muted); }

.view-controls { gap: 8px; }
.view-btn {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 10px;
}
.view-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.refresh-btn {
  padding: 8px 12px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 10px;
}
.refresh-btn:hover { background: var(--primary-hover); }

/* 统计信息卡片 */
.stats-card {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  padding: 14px;
  margin: 8px 0 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.stat { padding: 10px 12px; border-radius: 10px; background: rgba(99,102,241,0.06); }
[data-theme="dark"] .stat { background: rgba(129,140,248,0.12); }
.stat-label { font-size: 12px; color: var(--text-muted); }
.stat-value { font-size: 20px; font-weight: 700; color: var(--text); }

/* 网格卡片与列表项的现代视觉 */
.grid-item {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.grid-item:hover { transform: translateY(-2px); box-shadow: 0 14px 28px rgba(0,0,0,0.12); }

.grid-item-content { padding: 14px; display: grid; grid-template-columns: 40px 1fr; gap: 10px; align-items: center; }
.grid-item-icon { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; border-radius: 10px; background: rgba(99,102,241,0.08); color: var(--text); font-size: 20px; }
[data-theme="dark"] .grid-item-icon { background: rgba(129,140,248,0.15); }
.grid-item-name { font-weight: 600; color: var(--text); word-break: break-word; }
.grid-item-info { font-size: 12px; color: var(--text-muted); }

.list-view { gap: 10px; }
.list-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 8px;
}
.list-item:hover { background: rgba(99,102,241,0.05); }
.list-item-icon { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; margin-right: 12px; border-radius: 10px; background: rgba(99,102,241,0.08); color: var(--text); font-size: 20px; }
[data-theme="dark"] .list-item-icon { background: rgba(129,140,248,0.15); }
.list-item-content { display: flex; flex-direction: column; gap: 4px; }
.list-item-name { font-weight: 600; color: var(--text); }
.list-item-info { font-size: 12px; color: var(--text-muted); }

/* 模态框导航别名与美化 */
.modal-navigation { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(0,0,0,0.5); color: #fff; border: none; border-radius: 50%; width: 50px; height: 50px; cursor: pointer; font-size: 24px; }
.modal-navigation.prev { left: 20px; }
.modal-navigation.next { right: 20px; }
.modal-close { background: rgba(0,0,0,0.6); }

/* 深色模式下的卡片投影优化 */
[data-theme="dark"] .grid-item,
[data-theme="dark"] .list-item,
[data-theme="dark"] .content,
[data-theme="dark"] .header {
  box-shadow: 0 8px 20px rgba(0,0,0,0.35);
}

/* 触摸设备覆盖：减少过度动画 */
@media (hover: none) and (pointer: coarse) {
  .grid-item:hover { transform: none; }
}