/* 基础样式和CSS变量 */
:root {
    /* 冰晶色彩系统 */
    --ice-blue: #4A9EFF;
    --mint-green: #00D4AA;
    --ice-crystal: #E8F4FD;
    --deep-ice-blue: #2D7DD2;
    --glass-white: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(147, 197, 253, 0.3);
    --text-primary: #334155;
    --text-secondary: #64748B;
    --success-color: #00D4AA;
    --warning-color: #F59E0B;
    --error-color: #EF4444;
    
    /* 字体系统 */
    --font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
    
    /* 间距系统 */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    
    /* 圆角系统 */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    
    /* 阴影系统 */
    --shadow-light: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 4px 16px rgba(0, 0, 0, 0.15);
    --shadow-heavy: 0 8px 24px rgba(0, 0, 0, 0.2);
    
    /* 动画时间 */
    --transition-fast: 150ms;
    --transition-medium: 300ms;
    --transition-slow: 500ms;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background: linear-gradient(135deg, 
        var(--ice-crystal) 0%, 
        #F0F9FF 25%, 
        var(--ice-crystal) 50%, 
        #E0F2FE 75%, 
        var(--ice-crystal) 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* 冰晶条纹背景纹理 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        repeating-linear-gradient(
            45deg,
            transparent,
            transparent 10px,
            rgba(74, 158, 255, 0.03) 10px,
            rgba(74, 158, 255, 0.03) 20px
        ),
        repeating-linear-gradient(
            -45deg,
            transparent,
            transparent 15px,
            rgba(0, 212, 170, 0.02) 15px,
            rgba(0, 212, 170, 0.02) 30px
        );
    pointer-events: none;
    z-index: -1;
}

/* 毛玻璃效果基类 */
.glass-effect {
    background: var(--glass-white);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-medium);
}

/* 页面容器 */
#app {
    position: relative;
    min-height: 100vh;
    padding-bottom: 80px; /* 底部导航高度 */
}

/* 页面基础样式 */
.page {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 80px;
    opacity: 0;
    transform: translateX(100%);
    transition: all var(--transition-medium) ease-in-out;
    overflow-y: auto;
    padding: var(--spacing-lg);
    display: none;
}

.page.active {
    opacity: 1;
    transform: translateX(0);
    display: block;
}

.page.slide-left {
    transform: translateX(-100%);
}

.page.slide-right {
    transform: translateX(100%);
}

/* 页面标题 */
.page-header {
    margin-bottom: var(--spacing-lg);
    text-align: center;
}

.page-header h2 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-sm);
}

.page-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
}

/* 隐藏类 */
.hidden {
    display: none !important;
}

/* 响应式断点 */
@media (min-width: 768px) {
    .page {
        max-width: 800px;
        margin: 0 auto;
        padding: var(--spacing-xl);
    }
}

@media (min-width: 1024px) {
    .page {
        max-width: 1200px;
    }
}

/* 可访问性 */
@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
        animation: none !important;
    }
}

/* 深色模式适配 */
@media (prefers-color-scheme: dark) {
    :root {
        --glass-white: rgba(30, 41, 59, 0.8);
        --glass-border: rgba(100, 116, 139, 0.3);
        --text-primary: #F8FAFC;
        --text-secondary: #CBD5E1;
        --ice-crystal: #1E293B;
    }
    
    body {
        background: linear-gradient(135deg, 
            #0F172A 0%, 
            #1E293B 25%, 
            #0F172A 50%, 
            #334155 75%, 
            #1E293B 100%);
    }
}