/**
 * OiClaw Toolbox - 高端奢华设计系统
 * 设计理念：玻璃态、有机形状、丝滑动画、精湛工艺
 */

/* ==========================================
   主题变量（Light / Dark / System）
   ========================================== */

:root {
    /* 浅色主题 */
    --color-bg: #f0f2f5;
    --color-surface: rgba(255, 255, 255, 0.8);
    --color-surface-solid: #ffffff;
    --color-text: #1a1a2e;
    --color-text-secondary: #555770;
    --color-primary: #6366f1;
    --color-primary-light: #818cf8;
    --color-primary-dark: #4f46e5;
    --color-secondary: #ec4899;
    --color-accent: #06b6d4;
    --color-success: #10b981;
    --color-warning: #f59e0b;
    --color-error: #ef4444;
    --color-border: rgba(0, 0, 0, 0.1);
    --color-shadow: rgba(0, 0, 0, 0.08);
    --color-shadow-lg: rgba(0, 0, 0, 0.15);
    --color-glass: rgba(255, 255, 255, 0.6);
    --color-glass-border: rgba(255, 255, 255, 0.8);
    --color-navbar: rgba(255, 255, 255, 0.85);
    --color-footer: rgba(26, 26, 46, 0.95);
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #ec4899 100%);
    --gradient-hero: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-dark: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    --blur-amount: 20px;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 32px;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    --color-bg: #0f0f1a;
    --color-surface: rgba(30, 30, 50, 0.8);
    --color-surface-solid: #1e1e32;
    --color-text: #e2e8f0;
    --color-text-secondary: #a0aec0;
    --color-primary: #818cf8;
    --color-primary-light: #a5b4fc;
    --color-primary-dark: #6366f1;
    --color-secondary: #f472b6;
    --color-accent: #22d3ee;
    --color-success: #34d399;
    --color-warning: #fbbf24;
    --color-error: #f87171;
    --color-border: rgba(255, 255, 255, 0.1);
    --color-shadow: rgba(0, 0, 0, 0.3);
    --color-shadow-lg: rgba(0, 0, 0, 0.5);
    --color-glass: rgba(30, 30, 50, 0.6);
    --color-glass-border: rgba(255, 255, 255, 0.1);
    --color-navbar: rgba(15, 15, 26, 0.9);
    --color-footer: rgba(10, 10, 20, 0.98);
    --gradient-primary: linear-gradient(135deg, #818cf8 0%, #f472b6 100%);
    --gradient-hero: linear-gradient(135deg, #1a1a2e 0%, #2d1b69 100%);
    --gradient-dark: linear-gradient(135deg, #0f0f1a 0%, #1a1a2e 100%);
}

/* 系统主题检测 */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]):not([data-theme="dark"]) {
        --color-bg: #0f0f1a;
        --color-surface: rgba(30, 30, 50, 0.8);
        --color-surface-solid: #1e1e32;
        --color-text: #e2e8f0;
        --color-text-secondary: #a0aec0;
        --color-primary: #818cf8;
        --color-primary-light: #a5b4fc;
        --color-primary-dark: #6366f1;
        --color-secondary: #f472b6;
        --color-accent: #22d3ee;
        --color-success: #34d399;
        --color-warning: #fbbf24;
        --color-error: #f87171;
        --color-border: rgba(255, 255, 255, 0.1);
        --color-shadow: rgba(0, 0, 0, 0.3);
        --color-shadow-lg: rgba(0, 0, 0, 0.5);
        --color-glass: rgba(30, 30, 50, 0.6);
        --color-glass-border: rgba(255, 255, 255, 0.1);
        --color-navbar: rgba(15, 15, 26, 0.9);
        --color-footer: rgba(10, 10, 20, 0.98);
        --gradient-primary: linear-gradient(135deg, #818cf8 0%, #f472b6 100%);
        --gradient-hero: linear-gradient(135deg, #1a1a2e 0%, #2d1b69 100%);
        --gradient-dark: linear-gradient(135deg, #0f0f1a 0%, #1a1a2e 100%);
    }
}

/* ==========================================
   基础重置与全局样式
   ========================================== */

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-family);
    background: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
    min-height: 100vh;
    transition: background var(--transition-normal), color var(--transition-normal);
    overflow-x: hidden;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--color-primary-light);
}

/* ==========================================
   主题切换器
   ========================================== */

.theme-switcher {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1001;
    display: flex;
    gap: 8px;
    padding: 8px;
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: 50px;
    box-shadow: 0 8px 32px var(--color-shadow);
    animation: slideInRight 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.theme-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    font-size: 1.2rem;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-normal);
    position: relative;
}

.theme-btn:hover {
    background: var(--color-primary);
    transform: scale(1.1);
}

.theme-btn.active {
    background: var(--gradient-primary);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

/* ==========================================
   导航栏（玻璃态）
   ========================================== */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--color-navbar);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border-bottom: 1px solid var(--color-border);
    padding: 1rem 0;
    transition: all var(--transition-normal);
}

.navbar.scrolled {
    padding: 0.7rem 0;
    box-shadow: 0 4px 20px var(--color-shadow-lg);
}

.navbar .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--color-text);
    font-size: 1.5rem;
    font-weight: 700;
    text-decoration: none;
}

.brand-icon {
    font-size: 2rem;
    filter: drop-shadow(0 2px 4px var(--color-shadow));
}

.brand-text {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.brand-tag {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    padding: 2px 8px;
    background: var(--color-glass);
    border-radius: 20px;
    border: 1px solid var(--color-border);
}

.nav-menu {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.nav-link {
    color: var(--color-text-secondary);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-weight: 500;
    font-size: 0.95rem;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 6px;
    position: relative;
}

.nav-link:hover {
    color: var(--color-primary);
    background: var(--color-glass);
}

.nav-link.active {
    color: var(--color-primary);
    background: var(--color-glass);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.nav-icon {
    font-size: 1.1rem;
}

.nav-upload {
    background: var(--gradient-primary);
    color: white !important;
    padding: 8px 20px;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.nav-upload:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--color-glass);
    border-radius: 50px;
    border: 1px solid var(--color-border);
}

.user-avatar {
    font-size: 1.3rem;
}

.user-name {
    font-weight: 600;
    color: var(--color-primary);
}

.nav-logout {
    color: var(--color-error) !important;
}

.nav-logout:hover {
    background: rgba(239, 68, 68, 0.1) !important;
}

/* 移动端菜单按钮 */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background: var(--color-text);
    border-radius: 3px;
    transition: all var(--transition-fast);
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* ==========================================
   Hero 区域（首页）
   ========================================== */

.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 120px 2rem 80px;
    background: var(--gradient-hero);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 900px;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    color: white;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-title .gradient-text {
    background: linear-gradient(135deg, #fbbf24 0%, #f472b6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2.5rem;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
}

/* ==========================================
   玻璃态卡片
   ========================================== */

.glass-card {
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: 0 8px 32px var(--color-shadow);
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
}

.glass-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px var(--color-shadow-lg);
}

/* ==========================================
   统计卡片
   ========================================== */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.stat-card {
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-lg);
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: 0 8px 32px var(--color-shadow);
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.stat-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: transform var(--transition-normal);
}

.stat-card:hover::after {
    transform: scaleX(1);
}

.stat-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px var(--color-shadow-lg);
}

.stat-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
    filter: drop-shadow(0 4px 8px var(--color-shadow));
}

.stat-number {
    font-size: 3.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--color-text-secondary);
    font-size: 1.1rem;
    font-weight: 500;
}

/* ==========================================
   按钮系统
   ========================================== */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    font-family: var(--font-family);
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all var(--transition-normal);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
    color: white;
}

.btn-secondary {
    background: var(--color-glass);
    color: var(--color-text);
    border: 1px solid var(--color-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: var(--color-surface);
    transform: translateY(-2px);
    color: var(--color-primary);
}

.btn-ghost {
    background: transparent;
    color: var(--color-text-secondary);
    padding: 8px 16px;
}

.btn-ghost:hover {
    background: var(--color-glass);
    color: var(--color-primary);
}

.btn-lg {
    padding: 16px 36px;
    font-size: 1.1rem;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.9rem;
}

/* ==========================================
   文件列表（玻璃态卡片视图）
   ========================================== */

.files-section {
    padding: 2rem 0 4rem;
}

.files-toolbar {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.files-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.file-card {
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: 0 8px 32px var(--color-shadow);
    transition: all var(--transition-normal);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.file-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
}

.file-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px var(--color-shadow-lg);
}

.file-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.file-card-icon {
    flex-shrink: 0;
}

.file-card-actions {
    display: flex;
    gap: 0.5rem;
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.file-card:hover .file-card-actions {
    opacity: 1;
}

.btn-danger {
    background: var(--color-error);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-danger:hover {
    background: #dc2626;
    transform: scale(1.05);
}

.file-card-body {
    /* Content area */
}

/* ==========================================
   快速操作区域
   ========================================== */

.quick-actions {
    padding: 4rem 0;
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.action-card {
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-lg);
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: 0 8px 32px var(--color-shadow);
    transition: all var(--transition-normal);
    cursor: pointer;
    text-decoration: none;
    color: var(--color-text);
    display: block;
    position: relative;
    overflow: hidden;
}

.action-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity var(--transition-normal);
    z-index: 0;
}

.action-card:hover::before {
    opacity: 0.05;
}

.action-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px var(--color-shadow-lg);
}

.action-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    display: block;
    position: relative;
    z-index: 1;
}

.action-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.8rem;
    position: relative;
    z-index: 1;
}

.action-desc {
    color: var(--color-text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

/* ==========================================
   Footer（玻璃态）
   ========================================== */

.footer {
    background: var(--color-footer);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    color: white;
    padding: 4rem 0 2rem;
    margin-top: 6rem;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.footer .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
}

.footer-links h4,
.footer-contact h4 {
    font-size: 1.1rem;
    margin-bottom: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
}

.footer-links a {
    display: block;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    padding: 0.4rem 0;
    transition: all var(--transition-fast);
}

.footer-links a:hover {
    color: white;
    transform: translateX(5px);
}

.footer-contact p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.5rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    text-align: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 0.5rem;
}

.beian-link {
    color: rgba(255, 255, 255, 0.5) !important;
    font-size: 0.9rem;
    transition: color var(--transition-fast);
}

.beian-link:hover {
    color: rgba(255, 255, 255, 0.8) !important;
}

/* ==========================================
   提示消息（Glassmorphism）
   ========================================== */

.flash-messages {
    position: fixed;
    top: 100px;
    right: 20px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
}

.alert {
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-md);
    padding: 1rem 1.5rem;
    box-shadow: 0 8px 32px var(--color-shadow-lg);
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideInRight 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.alert-success { border-left: 4px solid var(--color-success); }
.alert-error { border-left: 4px solid var(--color-error); }
.alert-warning { border-left: 4px solid var(--color-warning); }
.alert-info { border-left: 4px solid var(--color-accent); }

.alert-icon {
    font-size: 1.3rem;
}

.alert-close {
    background: none;
    border: none;
    color: var(--color-text-secondary);
    cursor: pointer;
    font-size: 1.5rem;
    margin-left: auto;
    padding: 0 5px;
    transition: color var(--transition-fast);
}

.alert-close:hover {
    color: var(--color-text);
}

/* ==========================================
   动画系统
   ========================================== */

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

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

.animate-in {
    animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* 卡片延迟动画 */
.stat-card:nth-child(1) { animation-delay: 0s; }
.stat-card:nth-child(2) { animation-delay: 0.1s; }
.stat-card:nth-child(3) { animation-delay: 0.2s; }

/* ==========================================
   主内容区域
   ========================================== */

.main-content {
    margin-top: 80px;
    min-height: calc(100vh - 80px);
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ==========================================
   响应式设计（优化版）
   ========================================== */

/* 大屏幕（>1400px）*/
@media (min-width: 1401px) {
    .container {
        max-width: 1400px;
    }
}

/* 笔记本电脑（1024px - 1400px）*/
@media (max-width: 1400px) and (min-width: 1025px) {
    .hero-title {
        font-size: 3.5rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }
}

/* 平板电脑（768px - 1024px）*/
@media (max-width: 1024px) and (min-width: 769px) {
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1.5rem;
    }
    
    .files-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
    
    .tools-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
    
    .actions-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
}

/* 大型手机（481px - 768px）*/
@media (max-width: 768px) and (min-width: 481px) {
    .theme-switcher {
        top: 15px;
        right: 15px;
        padding: 6px;
    }
    
    .theme-btn {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
    
    .navbar .container {
        padding: 0 1.5rem;
    }
    
    .nav-menu {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--color-navbar);
        backdrop-filter: blur(var(--blur-amount));
        -webkit-backdrop-filter: blur(var(--blur-amount));
        flex-direction: column;
        padding: 1.5rem;
        gap: 0.5rem;
        border-bottom: 1px solid var(--color-border);
        transform: translateY(-100%);
        opacity: 0;
        transition: all var(--transition-normal);
        pointer-events: none;
        z-index: 999;
    }
    
    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .hero-section {
        padding: 100px 1.5rem 60px;
    }
    
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-actions {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
        gap: 1.5rem;
    }
    
    .stat-card {
        padding: 2rem 1.5rem;
    }
    
    .stat-icon {
        font-size: 2.5rem;
    }
    
    .stat-number {
        font-size: 3rem;
    }
    
    .files-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 1rem;
    }
    
    .tools-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    }
    
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
    
    .actions-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }
    
    .auth-container {
        padding: 2.5rem 2rem;
    }
    
    .upload-container {
        padding: 0 1rem;
    }
}

/* 小型手机（<481px）*/
@media (max-width: 480px) {
    .theme-switcher {
        top: 10px;
        right: 10px;
        padding: 5px;
        gap: 5px;
    }
    
    .theme-btn {
        width: 32px;
        height: 32px;
        font-size: 0.9rem;
    }
    
    .navbar {
        padding: 0.8rem 0;
    }
    
    .navbar .container {
        padding: 0 1rem;
    }
    
    .nav-brand a {
        font-size: 1.2rem;
    }
    
    .brand-icon {
        font-size: 1.5rem;
    }
    
    .brand-tag {
        display: none;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .hero-section {
        padding: 90px 1rem 50px;
        min-height: 100vh;
    }
    
    .hero-title {
        font-size: 2.2rem;
        line-height: 1.2;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 2rem;
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 0.8rem;
    }
    
    .hero-actions .btn {
        width: 100%;
        justify-content: center;
        padding: 14px 24px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .stat-card {
        padding: 1.5rem;
    }
    
    .stat-icon {
        font-size: 2.2rem;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .files-toolbar {
        flex-direction: column;
        gap: 0.8rem;
    }
    
    .files-toolbar .search-box {
        width: 100%;
    }
    
    .files-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .file-card {
        padding: 1.2rem;
    }
    
    .file-card-header {
        flex-direction: column;
        gap: 0.8rem;
    }
    
    .file-card-actions {
        opacity: 1;
        width: 100%;
        justify-content: flex-start;
    }
    
    .tools-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .tool-card {
        padding: 1.5rem;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .footer {
        padding: 3rem 0 1.5rem;
    }
    
    .actions-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .action-card {
        padding: 2rem 1.5rem;
    }
    
    .auth-section {
        padding: 100px 1rem 60px;
    }
    
    .auth-container {
        padding: 2rem 1.5rem;
    }
    
    .auth-header h1 {
        font-size: 1.8rem;
    }
    
    .auth-icon {
        font-size: 3rem;
    }
    
    .upload-section {
        padding: 1.5rem 0 3rem;
    }
    
    .upload-container {
        padding: 0 1rem;
    }
    
    .file-drop-zone {
        padding: 3rem 1.5rem;
    }
    
    .drop-icon {
        font-size: 4rem;
    }
    
    .drop-title {
        font-size: 1.2rem;
    }
    
    .page-title {
        font-size: 2rem;
    }
    
    .page-subtitle {
        font-size: 1rem;
    }
    
    .tool-page-title {
        font-size: 2rem;
    }
    
    .tool-container {
        padding: 1.5rem;
    }
    
    .flash-messages {
        top: 80px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    .alert {
        padding: 0.8rem 1rem;
        font-size: 0.9rem;
    }
}

/* ==========================================
   工具页面样式
   ========================================== */

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.tool-card {
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    text-decoration: none;
    color: var(--color-text);
    box-shadow: 0 8px 32px var(--color-shadow);
    transition: all var(--transition-normal);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.tool-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.tool-card:hover::after {
    opacity: 0.05;
}

.tool-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px var(--color-shadow-lg);
}

.tool-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    display: block;
    position: relative;
    z-index: 1;
}

.tool-name {
    font-weight: 700;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    position: relative;
    z-index: 1;
}

.tool-desc {
    font-size: 0.95rem;
    color: var(--color-text-secondary);
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

/* 工具内容区域 */
.tool-container {
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    margin: 2rem 0;
    box-shadow: 0 8px 32px var(--color-shadow);
}

.tool-input,
.tool-output {
    margin-bottom: 2rem;
}

.tool-input label,
.tool-output label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.8rem;
    color: var(--color-text);
    font-size: 1.1rem;
}

.tool-input textarea,
.tool-output textarea,
.tool-input input,
.tool-output pre {
    width: 100%;
    padding: 1rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    font-family: 'Courier New', monospace;
    font-size: 0.95rem;
    background: var(--color-surface-solid);
    color: var(--color-text);
    transition: border-color var(--transition-fast);
}

.tool-input textarea:focus,
.tool-input input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.tool-output pre {
    background: var(--color-surface-solid);
    min-height: 150px;
    overflow-y: auto;
    white-space: pre-wrap;
    line-height: 1.8;
}

.tool-buttons {
    margin-top: 1.5rem;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ==========================================
   表单样式（玻璃态）
   ========================================== */

.auth-section {
    min-height: calc(100vh - 80px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 2rem 80px;
    background: linear-gradient(135deg, var(--color-bg) 0%, rgba(99, 102, 241, 0.05) 100%);
}

.auth-container {
    width: 100%;
    max-width: 480px;
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-xl);
    padding: 3rem;
    box-shadow: 0 20px 60px var(--color-shadow-lg);
    animation: scaleIn 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.auth-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.auth-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    display: block;
    animation: float 3s ease-in-out infinite;
}

.auth-header h1 {
    font-size: 2.2rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: var(--color-text-secondary);
    font-size: 1.05rem;
}

.auth-form .form-group {
    margin-bottom: 1.8rem;
}

.auth-form label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 0.6rem;
    font-weight: 600;
    color: var(--color-text);
    font-size: 0.95rem;
}

.form-icon {
    font-size: 1.2rem;
}

.auth-form input {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--color-border);
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-family: var(--font-family);
    background: var(--color-surface-solid);
    color: var(--color-text);
    transition: all var(--transition-fast);
}

.auth-form input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.auth-form input.error {
    border-color: var(--color-error);
    background: rgba(239, 68, 68, 0.05);
}

.auth-form input.success {
    border-color: var(--color-success);
    background: rgba(16, 185, 129, 0.05);
}

.error-message {
    color: var(--color-error);
    font-size: 0.85rem;
    margin-top: 0.4rem;
    display: flex;
    align-items: center;
    gap: 5px;
    animation: fadeInUp 0.3s ease;
}

.success-message {
    color: var(--color-success);
    font-size: 0.85rem;
    margin-top: 0.4rem;
    display: flex;
    align-items: center;
    gap: 5px;
    animation: fadeInUp 0.3s ease;
}

/* 密码强度指示器 */
#passwordStrength {
    margin-top: 0.5rem;
}

#strengthBar1, #strengthBar2, #strengthBar3, #strengthBar4 {
    transition: background 0.3s ease;
}

#strengthText {
    transition: color 0.3s ease;
}

/* 密码匹配提示 */
#passwordMatch {
    font-size: 0.85rem;
    margin-top: 0.4rem;
    animation: fadeInUp 0.3s ease;
}

/* 切换密码按钮 */
.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 5px;
    transition: opacity 0.2s;
}

.toggle-password:hover {
    opacity: 0.7;
}

.form-hint {
    display: block;
    margin-top: 0.4rem;
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    font-weight: 400;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

.auth-switch {
    text-align: center;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--color-border);
    color: var(--color-text-secondary);
}

.auth-switch a {
    font-weight: 600;
    margin-left: 5px;
}

.auth-features {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--color-border);
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--color-surface);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    color: var(--color-text-secondary);
    transition: all var(--transition-fast);
}

.feature-item:hover {
    background: var(--color-glass);
    transform: translateX(5px);
}

.feature-icon {
    font-size: 1.3rem;
}

/* ==========================================
   上传表单（玻璃态）
   ========================================== */

.upload-section {
    padding: 2rem 0 4rem;
}

.upload-container {
    max-width: 800px;
    margin: 0 auto;
}

/* 拖拽上传区域 */
.file-drop-zone {
    border: 3px dashed var(--color-border);
    border-radius: var(--radius-lg);
    padding: 4rem 2rem;
    text-align: center;
    transition: all var(--transition-normal);
    cursor: pointer;
    background: var(--color-surface);
    position: relative;
    overflow: hidden;
}

.file-drop-zone:hover,
.file-drop-zone.drag-over {
    border-color: var(--color-primary);
    background: rgba(99, 102, 241, 0.05);
    transform: scale(1.01);
}

.file-drop-zone .drop-zone-content {
    position: relative;
    z-index: 1;
}

.file-drop-zone .drop-icon {
    font-size: 5rem;
    margin-bottom: 1.5rem;
    display: block;
    animation: float 3s ease-in-out infinite;
}

.file-drop-zone .drop-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--color-text);
}

.file-drop-zone .drop-text {
    color: var(--color-text-secondary);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.drop-zone-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(99, 102, 241, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.drop-zone-overlay.active {
    display: flex;
}

.overlay-content {
    text-align: center;
}

.overlay-icon {
    font-size: 4rem;
    display: block;
    margin-bottom: 1rem;
    animation: bounce 1s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* 文件预览 */
.file-preview {
    margin-bottom: 2rem;
    animation: fadeInUp 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.preview-content {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.preview-info p {
    margin-bottom: 0.5rem;
    color: var(--color-text-secondary);
}

.preview-info strong {
    color: var(--color-text);
}

/* 上传进度条 */
.upload-progress {
    animation: fadeInUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 上传提示 */
.upload-tips ul li {
    padding: 0.5rem 0;
}

/* ==========================================
   页面标题
   ========================================== */

.page-header {
    padding: 3rem 0 2rem;
    text-align: center;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.page-subtitle {
    color: var(--color-text-secondary);
    font-size: 1.1rem;
}

/* ==========================================
   加载状态与骨架屏
   ========================================== */

/* 全局加载遮罩 */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* 加载 spinner */
.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--color-glass);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* 加载文本 */
.loading-text {
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 1rem;
}

/* 按钮加载状态 */
.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.8;
}

.btn-loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

.btn-loading span {
    opacity: 0;
}

/* 骨架屏 */
.skeleton {
    background: linear-gradient(
        90deg,
        var(--color-surface) 25%,
        var(--color-glass) 50%,
        var(--color-surface) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius-sm);
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-text {
    height: 1em;
    margin-bottom: 0.5rem;
}

.skeleton-title {
    height: 2em;
    width: 60%;
    margin-bottom: 1rem;
}

.skeleton-card {
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    padding: 2rem;
    margin-bottom: 1rem;
}

.skeleton-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin-bottom: 1rem;
}

.skeleton-button {
    height: 40px;
    width: 120px;
    border-radius: 50px;
}

/* Toast 通知系统 */
.toast-container {
    position: fixed;
    top: 100px;
    right: 20px;
    z-index: 9998;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
}

.toast {
    background: var(--color-glass);
    backdrop-filter: blur(var(--blur-amount));
    -webkit-backdrop-filter: blur(var(--blur-amount));
    border: 1px solid var(--color-glass-border);
    border-radius: var(--radius-md);
    padding: 1rem 1.5rem;
    box-shadow: 0 8px 32px var(--color-shadow-lg);
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideInRight 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    transition: all 0.3s ease;
}

.toast.success {
    border-left: 4px solid var(--color-success);
}

.toast.error {
    border-left: 4px solid var(--color-error);
}

.toast.warning {
    border-left: 4px solid var(--color-warning);
}

.toast.info {
    border-left: 4px solid var(--color-accent);
}

.toast-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
}

.toast-message {
    flex: 1;
    font-size: 0.95rem;
    color: var(--color-text);
}

.toast-close {
    background: none;
    border: none;
    color: var(--color-text-secondary);
    cursor: pointer;
    font-size: 1.3rem;
    padding: 0 5px;
    transition: color 0.2s;
    flex-shrink: 0;
}

.toast-close:hover {
    color: var(--color-text);
}

.toast-exit {
    animation: slideOutRight 0.3s ease forwards;
}

@keyframes slideOutRight {
    to {
        opacity: 0;
        transform: translateX(100px);
    }
}

/* 进度条 */
.progress-bar {
    width: 100%;
    height: 4px;
    background: var(--color-surface);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 1rem;
}

.progress-bar-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 2px;
    transition: width 0.3s ease;
    width: 0%;
}

/* 文件上传进度 */
.upload-progress-container {
    margin-top: 1.5rem;
    animation: fadeInUp 0.3s ease;
}

.upload-progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--color-text-secondary);
}

.upload-progress-percentage {
    font-weight: 600;
    color: var(--color-primary);
}

/* ==========================================
   空状态
   ========================================== */

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--color-text-secondary);
}

.empty-state .empty-icon {
    font-size: 5rem;
    margin-bottom: 1.5rem;
    display: block;
    opacity: 0.5;
}

.empty-state .empty-text {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
}

/* ==========================================
   用户个人中心
   ========================================== */

.profile-section {
    padding: 2rem 0 4rem;
}

.profile-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

/* 用户信息卡片 */
.profile-info-card {
    padding: 2.5rem 2rem;
    text-align: center;
}

.profile-avatar {
    margin-bottom: 2rem;
}

.avatar-circle {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: white;
    font-size: 3rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    box-shadow: 0 8px 32px rgba(99, 102, 241, 0.3);
}

.profile-username {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 0.5rem;
}

.profile-role {
    display: inline-block;
    padding: 0.3rem 1rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
}

.role-admin {
    background: rgba(239, 68, 68, 0.1);
    color: var(--color-error);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.role-user {
    background: rgba(99, 102, 241, 0.1);
    color: var(--color-primary);
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.profile-details {
    margin-top: 2rem;
    text-align: left;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0.8rem 0;
    border-bottom: 1px solid var(--color-border);
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

.detail-label {
    color: var(--color-text-secondary);
    font-size: 0.9rem;
    min-width: 80px;
}

.detail-value {
    color: var(--color-text);
    font-weight: 500;
    flex: 1;
}

.text-muted {
    color: var(--color-text-secondary);
    font-style: italic;
}

.profile-action {
    margin-top: 2rem;
}

.profile-form {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--color-border);
    text-align: left;
    animation: fadeInUp 0.3s ease;
}

/* 统计卡片（小型） */
.profile-stats-col {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.stat-mini-card {
    padding: 1.5rem;
    text-align: center;
    transition: all var(--transition-normal);
}

.stat-mini-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px var(--color-shadow-lg);
}

.stat-mini-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    display: block;
}

.stat-mini-value {
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
    margin-bottom: 0.3rem;
}

.stat-mini-label {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    font-weight: 500;
}

/* 修改密码卡片 */
.password-card {
    padding: 2rem;
}

.password-card .card-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--color-text);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.password-card .card-title span {
    font-size: 1.5rem;
}

/* 我的上传区域 */
.my-files-section {
    animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
}

/* ==========================================
   工具页面标题
   ========================================== */

.tool-page-header {
    text-align: center;
    padding: 3rem 0 2rem;
}

.tool-page-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    display: block;
}

.tool-page-title {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.tool-page-desc {
    color: var(--color-text-secondary);
    font-size: 1.1rem;
}

/* ==========================================
   卡片延迟动画
   ========================================== */

.stat-card:nth-child(1) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0s both; }
.stat-card:nth-child(2) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both; }
.stat-card:nth-child(3) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both; }

.tool-card:nth-child(1) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0s both; }
.tool-card:nth-child(2) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both; }
.tool-card:nth-child(3) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both; }
.tool-card:nth-child(4) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.3s both; }
.tool-card:nth-child(5) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.4s both; }
.tool-card:nth-child(6) { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.5s both; }

/* ==========================================
   滚动条美化
   ========================================== */

::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--color-bg);
}

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

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

/* ==========================================
   选择文本颜色
   ========================================== */

::selection {
    background: var(--color-primary);
    color: white;
}
