/* ==========================================
   智影旅拍本体数据库 - 深色科技感主题样式
   ========================================== */

/* CSS 变量定义 */
:root {
    /* 主色调 */
    --primary-color: #00d4ff;
    --primary-glow: rgba(0, 212, 255, 0.5);
    --secondary-color: #7b2fff;
    --secondary-glow: rgba(123, 47, 255, 0.5);
    --accent-color: #00ff88;
    --accent-glow: rgba(0, 255, 136, 0.5);

    /* 背景色 */
    --bg-dark: #0a0e17;
    --bg-darker: #050810;
    --bg-card: rgba(15, 23, 42, 0.8);
    --bg-card-hover: rgba(20, 30, 50, 0.9);

    /* 边框色 */
    --border-color: rgba(0, 212, 255, 0.2);
    --border-glow: rgba(0, 212, 255, 0.4);

    /* 文字色 */
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-muted: rgba(255, 255, 255, 0.4);

    /* 字体 */
    --font-display: 'Orbitron', sans-serif;
    --font-body: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;

    /* 尺寸 */
    --sidebar-width: 280px;
    --header-height: 70px;
    --border-radius: 12px;
    --border-radius-sm: 8px;

    /* 动画 */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* 重置样式 */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-darker);
    color: var(--text-primary);
    line-height: 1.6;
}

/* ==========================================
   背景动画
   ========================================== */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

.bg-grid {
    position: absolute;
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    background-image:
        linear-gradient(rgba(0, 212, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 212, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(50px, 50px);
    }
}

.bg-glow {
    position: absolute;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(ellipse 80% 50% at 20% 40%, rgba(0, 212, 255, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse 60% 40% at 80% 60%, rgba(123, 47, 255, 0.08) 0%, transparent 50%);
    animation: glowPulse 8s ease-in-out infinite alternate;
}

@keyframes glowPulse {
    0% {
        opacity: 0.5;
    }

    100% {
        opacity: 1;
    }
}

/* ==========================================
   主容器布局
   ========================================== */
.app-container {
    display: flex;
    height: 100vh;
    position: relative;
}

/* ==========================================
   左侧边栏
   ========================================== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 10;
}

.sidebar::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 1px;
    height: 100%;
    background: linear-gradient(to bottom,
            transparent,
            var(--primary-color),
            transparent);
    opacity: 0.5;
}

/* Logo 区域 */
.logo-container {
    padding: 30px 20px;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.logo-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 15px;
    position: relative;
}

.logo-svg {
    width: 100%;
    height: 100%;
    animation: logoRotate 20s linear infinite;
}

@keyframes logoRotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.logo-circle {
    fill: none;
    stroke: var(--primary-color);
    stroke-width: 1;
    opacity: 0.3;
}

.logo-circle-inner {
    fill: none;
    stroke: var(--secondary-color);
    stroke-width: 1;
    opacity: 0.5;
}

.logo-node {
    fill: var(--primary-color);
    filter: drop-shadow(0 0 4px var(--primary-glow));
}

.logo-line {
    stroke: var(--primary-color);
    stroke-width: 1.5;
    opacity: 0.8;
}

.logo-text {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px var(--primary-glow);
    margin-bottom: 5px;
}

.logo-subtitle {
    font-family: var(--font-display);
    font-size: 0.65rem;
    color: var(--text-muted);
    letter-spacing: 3px;
    text-transform: uppercase;
}

/* 菜单样式 */
.menu {
    flex: 1;
    padding: 20px 0;
    overflow-y: auto;
}

.menu-list {
    list-style: none;
}

.menu-item {
    display: flex;
    align-items: center;
    padding: 16px 24px;
    margin: 8px 16px;
    cursor: pointer;
    border-radius: var(--border-radius-sm);
    position: relative;
    transition: all var(--transition-normal);
    background: transparent;
    border: 1px solid transparent;
}

.menu-item:hover {
    background: rgba(0, 212, 255, 0.05);
    border-color: var(--border-color);
}

.menu-item.active {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.1), rgba(123, 47, 255, 0.1));
    border-color: var(--border-glow);
    box-shadow:
        0 0 20px rgba(0, 212, 255, 0.1),
        inset 0 0 20px rgba(0, 212, 255, 0.05);
}

.menu-icon {
    width: 24px;
    height: 24px;
    margin-right: 14px;
    color: var(--text-secondary);
    transition: all var(--transition-normal);
}

.menu-item:hover .menu-icon,
.menu-item.active .menu-icon {
    color: var(--primary-color);
    filter: drop-shadow(0 0 8px var(--primary-glow));
}

.menu-text {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all var(--transition-normal);
}

.menu-item:hover .menu-text,
.menu-item.active .menu-text {
    color: var(--text-primary);
}

.menu-indicator {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 0;
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
    border-radius: 0 3px 3px 0;
    transition: all var(--transition-normal);
}

.menu-item.active .menu-indicator {
    height: 60%;
    box-shadow: 0 0 10px var(--primary-glow);
}

/* 侧边栏底部 */
.sidebar-footer {
    padding: 20px;
    border-top: 1px solid var(--border-color);
}

.status-indicator {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-color);
    margin-right: 10px;
    animation: statusPulse 2s ease-in-out infinite;
    box-shadow: 0 0 10px var(--accent-glow);
}

@keyframes statusPulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.5;
        transform: scale(0.8);
    }
}

.status-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.version {
    font-size: 0.7rem;
    color: var(--text-muted);
    font-family: var(--font-display);
}

/* ==========================================
   主内容区
   ========================================== */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--bg-dark);
}

/* 内容头部 */
.content-header {
    height: var(--header-height);
    padding: 0 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-card);
    backdrop-filter: blur(10px);
}

.page-title {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 500;
    color: var(--text-primary);
    position: relative;
    padding-left: 20px;
}

.page-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 24px;
    background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
    box-shadow: 0 0 10px var(--primary-glow);
}

.header-actions {
    display: flex;
    gap: 12px;
}

.action-btn {
    width: 42px;
    height: 42px;
    border-radius: var(--border-radius-sm);
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-normal);
}

.action-btn svg {
    width: 20px;
    height: 20px;
}

.action-btn:hover {
    background: rgba(0, 212, 255, 0.1);
    border-color: var(--primary-color);
    color: var(--primary-color);
    box-shadow: 0 0 15px rgba(0, 212, 255, 0.2);
}

.action-btn:active {
    transform: scale(0.95);
}

/* 图表容器 */
.chart-container {
    flex: 1;
    position: relative;
    padding: 20px;
    overflow: hidden;
}

.chart {
    width: 100%;
    height: 100%;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.3),
        inset 0 0 60px rgba(0, 212, 255, 0.02);
}

/* 加载动画 */
.loading-overlay {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    bottom: 20px;
    background: rgba(10, 14, 23, 0.95);
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.loader-ring {
    position: absolute;
    width: 60px;
    height: 60px;
    border: 2px solid transparent;
    border-radius: 50%;
}

.loader-ring:nth-child(1) {
    border-top-color: var(--primary-color);
    animation: spin 1.5s linear infinite;
}

.loader-ring:nth-child(2) {
    width: 48px;
    height: 48px;
    border-right-color: var(--secondary-color);
    animation: spin 1.2s linear infinite reverse;
}

.loader-ring:nth-child(3) {
    width: 36px;
    height: 36px;
    border-bottom-color: var(--accent-color);
    animation: spin 0.9s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.loader-text {
    margin-top: 80px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    letter-spacing: 2px;
    animation: textPulse 1.5s ease-in-out infinite;
}

@keyframes textPulse {

    0%,
    100% {
        opacity: 0.5;
    }

    50% {
        opacity: 1;
    }
}

/* ==========================================
   响应式设计
   ========================================== */
@media (max-width: 1024px) {
    .sidebar {
        width: 240px;
    }

    .logo-text {
        font-size: 1.2rem;
    }
}

@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        left: -280px;
        height: 100%;
        z-index: 1000;
        transition: left var(--transition-normal);
    }

    .sidebar.open {
        left: 0;
    }

    .chart-container {
        padding: 10px;
    }
}

/* ==========================================
   滚动条样式
   ========================================== */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}