:root {
  /* 调音师助理 官方 Windows 11 Fluent Acrylic / Mica 视觉体系 */
  color-scheme: dark;
  --bg-titlebar: #1c1c1c;
  --bg-sidebar: #1c1c1c;
  --bg-content: #202020;
  --bg-card: #2b2b2b;
  --bg-card-header: #242424;
  --bg-card-hover: #323232;
  --bg-card-nested: #1e1e1e;
  
  --bg-hover: rgba(255, 255, 255, 0.07);
  --bg-active: rgba(96, 205, 255, 0.14);
  
  --color-text-primary: #f0f0f0;
  --color-text-secondary: #aaaaaa;
  --color-text-muted: #787878;
  --color-accent: #60cdff;
  --color-accent-hover: #7adbff;
  --color-accent-glow: rgba(96, 205, 255, 0.25);
  --color-accent-gradient: linear-gradient(135deg, #0078d4 0%, #60cdff 100%);
  --color-purple-gradient: linear-gradient(135deg, #722ed1 0%, #b37feb 100%);
  --color-green-gradient: linear-gradient(135deg, #237804 0%, #52c41a 100%);
  
  --border-color: rgba(255, 255, 255, 0.08);
  --border-subtle: rgba(255, 255, 255, 0.04);
  --border-highlight: rgba(255, 255, 255, 0.14);
  
  --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  --card-shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  
  --btn-secondary-bg: #333333;
  --btn-secondary-hover: #3a3a3a;
  --btn-secondary-border: rgba(255, 255, 255, 0.1);
  --btn-secondary-border-bottom: rgba(255, 255, 255, 0.2);
  
  --input-bg: #222222;
  --input-bg-focus: #1c1c1c;
  --input-border: rgba(255, 255, 255, 0.12);
  --input-focus-border: #60cdff;
  --input-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
  
  --success: #52c41a;
  --warning: #faad14;
  --danger: #ff4d4f;
  --info: #60cdff;
  
  --radius-xs: 4px;
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  
  --sidebar-width: 220px;
  --header-height: 48px;
  --font-family: "Segoe UI Variable Display", "Segoe UI", "HarmonyOS Sans SC", "Inter", -apple-system, BlinkMacSystemFont, Roboto, Helvetica, Arial, sans-serif;
}

[data-theme="light"] {
  color-scheme: light;
  --bg-titlebar: #f3f3f3;
  --bg-sidebar: #f3f3f3;
  --bg-content: #ffffff;
  --bg-card: #ffffff;
  --bg-card-header: #f8f8f8;
  --bg-card-hover: #fcfcfc;
  --bg-card-nested: #f5f5f5;
  
  --bg-hover: rgba(0, 0, 0, 0.04);
  --bg-active: rgba(0, 120, 212, 0.08);
  
  --color-text-primary: #1a1a1a;
  --color-text-secondary: #606060;
  --color-text-muted: #8c8c8c;
  --color-accent: #0078d4;
  --color-accent-hover: #106ebe;
  --color-accent-glow: rgba(0, 120, 212, 0.15);
  --color-accent-gradient: linear-gradient(135deg, #0078d4 0%, #2b88d8 100%);
  
  --border-color: rgba(0, 0, 0, 0.06);
  --border-subtle: rgba(0, 0, 0, 0.03);
  --border-highlight: rgba(0, 0, 0, 0.1);
  
  --card-shadow: 0 2px 8px rgba(0, 0, 0, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.8);
  --card-shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.8);
  
  --btn-secondary-bg: #f4f4f4;
  --btn-secondary-hover: #eaeaea;
  --btn-secondary-border: rgba(0, 0, 0, 0.08);
  --btn-secondary-border-bottom: rgba(0, 0, 0, 0.14);
  
  --input-bg: #ffffff;
  --input-bg-focus: #ffffff;
  --input-border: rgba(0, 0, 0, 0.14);
  --input-focus-border: #0078d4;
  --input-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.04);
}

/* 极致精致的极细滚动条 */
::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.22);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-content);
  color: var(--color-text-primary);
  min-height: 100vh;
  display: flex;
  overflow-x: hidden;
  font-size: 13px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Sidebar Navigation */
.sidebar {
  width: var(--sidebar-width);
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border-color);
  height: 100vh;
  position: fixed;
  left: 0;
  top: 0;
  display: flex;
  flex-direction: column;
  z-index: 100;
}

.sidebar-profile {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar-avatar {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: var(--color-accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 2px 8px var(--color-accent-glow);
}

.sidebar-user-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.sidebar-username {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--color-text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.2px;
}

.sidebar-status-tag {
  font-size: 10.5px;
  color: var(--color-accent);
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 1px;
  font-weight: 500;
}

.sidebar-status-tag::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 6px rgba(82, 196, 26, 0.5);
  display: inline-block;
}

.sidebar-nav {
  flex: 1;
  padding: 8px 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow-y: auto;
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 11px;
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.12s ease;
  border: 1px solid transparent;
}

.nav-item:hover {
  color: var(--color-text-primary);
  background-color: var(--bg-hover);
}

.nav-item.active {
  color: var(--color-accent);
  background-color: var(--bg-active);
  font-weight: 600;
}

.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 5px;
  bottom: 5px;
  width: 3px;
  background: var(--color-accent);
  border-radius: 0 3px 3px 0;
}

.nav-item svg {
  width: 15px;
  height: 15px;
  stroke-width: 2;
  flex-shrink: 0;
}

.sidebar-footer {
  padding: 10px 14px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Main Content Area */
.main-wrapper {
  margin-left: var(--sidebar-width);
  flex: 1;
  min-width: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg-content);
}

/* Header & Titlebar */
.header {
  height: var(--header-height);
  background: var(--bg-titlebar);
  border-bottom: 1px solid var(--border-color);
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 90;
}

.header-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--color-text-primary);
  letter-spacing: 0.2px;
}

.header-subtitle {
  font-size: 11.5px;
  color: var(--color-text-muted);
  padding-left: 9px;
  border-left: 1px solid var(--border-color);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.content-container {
  padding: 20px 24px;
  flex: 1;
  max-width: 1360px;
  width: 100%;
}

@media (max-width: 760px) {
  :root { --sidebar-width: 180px; }
  .sidebar { width: var(--sidebar-width); }
  .main-wrapper { margin-left: var(--sidebar-width); min-width: 0; }
  .header { padding: 0 12px; }
  .header-subtitle { display: none; }
  .content-container { padding: 12px; min-width: 0; overflow-x: hidden; }
  .section-toolbar { flex-wrap: wrap; gap: 8px; }
  .toolbar-left, .toolbar-right { min-width: 0; }
  .toolbar-right { flex-wrap: wrap; }
  .table-container { max-width: 100%; overflow-x: auto; }
}

.tab-pane {
  display: none;
  animation: fadeIn 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}

.tab-pane.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}
