/* ========================================
   BatVoice 公共侧边栏样式
   ======================================== */

/* CSS 变量 - 主题色 */
:root {
    --primary: #ff6b35;
    --primary-light: #ff8c5a;
    --primary-dark: #e85a2a;
    --gradient: linear-gradient(135deg, #ff6b35 0%, #f7931e 50%, #ffb347 100%);
    --gradient-hover: linear-gradient(135deg, #e85a2a 0%, #e8820a 50%, #f0a030 100%);
    --bg-primary: #0f0f12;
    --bg-secondary: #18181c;
    --bg-card: #1e1e24;
    --bg-elevated: #26262e;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a8;
    --text-muted: #6b6b75;
    --border: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    --glow: rgba(255, 107, 53, 0.25);
}

/* 基础重置 */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
}

/* 背景装饰 */
body::before {
    content: '';
    position: fixed;
    top: -50%;
    right: -30%;
    width: 80%;
    height: 100%;
    background: radial-gradient(ellipse, rgba(255, 107, 53, 0.08) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
}
body::after {
    content: '';
    position: fixed;
    bottom: -30%;
    left: -20%;
    width: 60%;
    height: 80%;
    background: radial-gradient(ellipse, rgba(247, 147, 30, 0.05) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
}

/* 整体布局 */
.layout { 
    display: flex; 
    min-height: 100vh; 
    position: relative; 
    z-index: 1; 
}

/* 左侧边栏 */
.sidebar {
    width: 240px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    padding: 28px 0;
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    overflow-y: auto;
    z-index: 100;
    backdrop-filter: blur(20px);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 24px 28px;
    text-decoration: none;
    border-bottom: 1px solid var(--border);
    margin-bottom: 24px;
}

.sidebar-logo-icon {
    width: 44px;
    height: 44px;
    background: var(--gradient);
    border-radius: 12px;
    box-shadow: 0 8px 24px var(--glow);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-logo-icon::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.2) 0%, transparent 50%);
    pointer-events: none;
}

.sidebar-logo-icon svg {
    width: 24px;
    height: 24px;
    stroke: #fff;
    fill: none;
    position: relative;
    z-index: 1;
}

.sidebar-logo-text {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.sidebar-logo-text span { 
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-section { 
    margin-bottom: 28px; 
}

.sidebar-section-title {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    padding: 0 24px;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.sidebar-nav { 
    list-style: none; 
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 24px;
    min-height: 52px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-left: 3px solid transparent;
    position: relative;
}

.sidebar-nav a:hover {
    background: rgba(255, 107, 53, 0.08);
    color: var(--primary);
}

.sidebar-nav a.active {
    background: linear-gradient(90deg, rgba(255, 107, 53, 0.15), transparent);
    color: var(--primary);
    border-left-color: var(--primary);
}

.sidebar-nav a.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 24px;
    background: var(--gradient);
    border-radius: 0 2px 2px 0;
    box-shadow: 0 0 12px var(--glow);
}

.sidebar-nav a svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
}

.sidebar-footer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 24px;
    border-top: 1px solid var(--border);
    background: var(--bg-secondary);
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-user-avatar {
    width: 42px;
    height: 42px;
    background: var(--gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 4px 16px var(--glow);
}

.sidebar-user-info { 
    flex: 1; 
}

.sidebar-user-name { 
    font-size: 14px; 
    font-weight: 600; 
    color: var(--text-primary); 
}

.sidebar-user-credits { 
    font-size: 12px; 
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
}

/* 主内容区 */
.main-content {
    flex: 1;
    margin-left: 240px;
    padding: 48px 60px;
    display: flex;
    gap: 48px;
}

/* 响应式 - 侧边栏 */
@media (max-width: 768px) {
    .sidebar { 
        transform: translateX(-100%); 
    }
    .main-content { 
        margin-left: 0; 
        padding: 24px; 
    }
}

