/* 合并优化的样式表 */
/* 整合所有页面共用的样式，减少HTTP请求 */

/* 基础变量定义 */
:root {
    /* 主色调 */
    --primary: #00b42a;
    --secondary: #79f29d;
    --primary-blue: #0a2463;
    --accent-teal: #00d4ff;
    
    /* 暗黑主题 */
    --dark-bg: #0f1419;
    --light-text: #e8eaed;
    --dark: #0a192f;
    --sidebar: #0f172a;
    --panel: #1e293b;
    
    /* 霓虹色彩 */
    --neon-purple: #9B59B6;
    --neon-green: #2ECC71;
    --neon-blue: #3498DB;
    --neon-yellow: #F1C40F;
    --neon-cyan: #1ABC9C;
    --neon-pink: #E91E63;
    --neon-orange: #FF5722;
    --neon-blue-alt: #00ffff;
    --neon-green-alt: #00ff00;
    --neon-purple-alt: #bf00ff;
}

/* 全局样式重置和基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--dark);
    color: var(--light-text);
    font-family: 'Segoe UI', system-ui, sans-serif;
    overflow-x: hidden;
    min-height: 100vh;
    font-size: clamp(14px, 2vw, 16px);
    line-height: 1.6;
}

/* 响应式文字样式 */
h1, h2, h3, h4, h5, h6 {
    font-size: clamp(1.5rem, 5vw, 3rem);
    line-height: 1.2;
    margin-bottom: 1rem;
}

h2 {
    font-size: clamp(1.25rem, 4vw, 2.5rem);
}

h3 {
    font-size: clamp(1.125rem, 3vw, 2rem);
}

p {
    font-size: clamp(1rem, 2vw, 1.125rem);
}

/* 响应式间距 */
.py-10 {
    padding-top: clamp(2rem, 5vw, 6rem);
    padding-bottom: clamp(2rem, 5vw, 6rem);
}

.py-20 {
    padding-top: clamp(3rem, 8vw, 8rem);
    padding-bottom: clamp(3rem, 8vw, 8rem);
}

.mb-4 {
    margin-bottom: clamp(0.5rem, 2vw, 1rem);
}

.mb-6 {
    margin-bottom: clamp(1rem, 3vw, 1.5rem);
}

.mb-8 {
    margin-bottom: clamp(1.5rem, 4vw, 2rem);
}

.mb-10 {
    margin-bottom: clamp(2rem, 5vw, 3rem);
}

.mb-16 {
    margin-bottom: clamp(3rem, 7vw, 4rem);
}

/* 响应式图片 */
img {
    max-width: 100%;
    height: auto;
}

/* 响应式容器宽度 */
.container {
    width: 100%;
    padding-right: 1rem;
    padding-left: 1rem;
    margin-right: auto;
    margin-left: auto;
}

/* 容器断点 */
@media (min-width: 576px) { .container { max-width: 540px; } }
@media (min-width: 768px) { .container { max-width: 720px; } }
@media (min-width: 992px) { .container { max-width: 960px; } }
@media (min-width: 1200px) { .container { max-width: 1140px; } }
@media (min-width: 1400px) { .container { max-width: 1320px; } }

/* 控制面板样式 */
.sidebar {
    background-color: var(--sidebar);
    border-right: 1px solid #334155;
}

.content-panel {
    background-color: var(--panel);
    border-radius: 8px;
}

.stat-card {
    background-color: var(--panel);
    border-radius: 8px;
    border: 1px solid #334155;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px -5px rgba(0, 180, 42, 0.1);
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 响应式导航 */
.nav-icon {
    font-size: clamp(18px, 6vw, 24px);
    width: clamp(28px, 8vw, 32px);
    height: clamp(28px, 8vw, 32px);
    line-height: clamp(28px, 8vw, 32px);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 4px;
    transition: all 0.3s ease;
}

/* 移动端底部导航栏样式 */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 50;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.5);
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.8);
    padding: 8px 0;
    text-decoration: none;
    transition: all 0.3s ease;
    min-width: 60px;
}

.mobile-nav-item.active .nav-icon {
    color: #ffffff;
}

.mobile-nav-item.active span {
    color: #ffffff;
}

/* 不同图标颜色 */
.nav-icon-brain { color: var(--neon-purple); }
.nav-icon-phone { color: var(--neon-green); }
.nav-icon-globe { color: var(--neon-blue); }
.nav-icon-trophy { color: var(--neon-yellow); }
.nav-icon-cloud { color: var(--neon-cyan); }
.nav-icon-more { color: var(--neon-pink); }
.nav-icon-building { color: var(--neon-orange); }
.nav-icon-users { color: var(--neon-green); }
.nav-icon-store { color: var(--neon-yellow); }
.nav-icon-heart { color: var(--neon-pink); }
.nav-icon-video { color: var(--neon-purple); }
.nav-icon-shopping-cart { color: var(--neon-blue); }

/* 移动端和桌面端导航适配 */
@media (min-width: 768px) {
    .mobile-nav-container {
        display: flex;
        width: 80%;
        max-width: 1200px;
        margin: 0 auto;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        justify-content: space-between;
    }
    
    .mobile-nav-container::-webkit-scrollbar { display: none; }
    
    .mobile-nav-item:not(.nav-item-more) {
        display: flex;
        flex: 1;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 8.333%;
        padding: 10px 0;
    }
    
    .nav-item-more { display: none !important; }
}

@media (max-width: 767px) {
    .mobile-bottom-nav {
        background-color: #1C1C1C;
        border-top: 1px solid #333;
        padding-bottom: 0;
        z-index: 999;
    }
    
    .mobile-nav-container {
        display: flex;
        flex-wrap: wrap;
        justify-content: flex-start;
    }
    
    .mobile-nav-item:not(.all-nav-item) {
        display: flex !important;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 16.666%;
        padding: 10px 0;
        color: #999;
    }
    
    .mobile-nav-item.all-nav-item { display: none; }
    
    .mobile-bottom-nav.expanded {
        background-color: #1C1C1C;
        padding-bottom: 10px;
    }
    
    .mobile-bottom-nav.expanded .mobile-nav-item.all-nav-item {
        display: flex !important;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 16.666%;
        padding: 10px 0;
        color: #999;
    }
    
    .mobile-nav-item.active .nav-icon {
        background-color: #2C80FF;
        border-radius: 50%;
        width: 36px;
        height: 36px;
        line-height: 36px;
        text-align: center;
        font-size: 24px;
    }
    
    .nav-icon {
        font-size: 24px;
        width: 36px;
        height: 36px;
        line-height: 36px;
        text-align: center;
    }
    
    .mobile-nav-item span { font-size: 12px; line-height: 1; }
    
    .nav-item-more { cursor: pointer; }
}

/* 小屏幕适配 */
@media (max-width: 360px) {
    .nav-icon {
        font-size: 20px;
        width: 28px;
        height: 28px;
        line-height: 28px;
    }
    
    .mobile-nav-item span { font-size: 11px; }
}

/* 响应式网格优化 */
@media (max-width: 640px) {
    .sm\:grid-cols-2 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
}

@media (max-width: 768px) {
    .md\:grid-cols-2, .md\:grid-cols-3 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
    .md\:flex-row { flex-direction: column; }
}

/* 特性卡片样式 */
.feature-card {
    background-color: rgba(30, 41, 59, 0.7);
    border-radius: 8px;
    padding: 2rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px -5px rgba(0, 180, 42, 0.1);
}

/* 渐变文本 */
.gradient-text {
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.btn-neon {
    background: linear-gradient(90deg, var(--neon-blue), var(--neon-purple));
    color: white;
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

.btn-neon:hover {
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.8);
    transform: translateY(-2px);
}

/* 加载动画 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.8s ease forwards;
}

/* 粒子背景动画 */
.bg-particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
}

.particle {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, var(--neon-blue-alt) 0%, transparent 70%);
    animation: float 15s infinite linear;
    opacity: 0.3;
}

@keyframes float {
    0% { transform: translate(0, 0) rotate(0deg); }
    100% { transform: translate(100vw, 100vh) rotate(360deg); }
}

/* 优化滚动性能 */
html {
    scroll-behavior: smooth;
}

/* 减少重绘重排 */
* {
    will-change: auto;
}

/* 字体优化 */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 导航栏相关样式 */
.navbar {
    background: rgba(15, 20, 25, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 212, 255, 0.2);
    z-index: 1000;
}

.navbar-nav .nav-item {
    position: relative;
    margin: 0 5px;
}

.navbar-nav .nav-link {
    color: var(--light-text);
    padding: 8px 16px;
    transition: all 0.3s ease;
    position: relative;
}

.navbar-nav .nav-link:hover {
    color: var(--accent-teal);
}

/* 下拉菜单样式 */
.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: rgba(15, 24, 42, 0.95);
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-radius: 8px;
    padding: 0.5rem 0;
    margin: 0;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    z-index: 1000;
    min-width: 160px;
    animation: dropdownFadeIn 0.3s ease-out;
}

@keyframes dropdownFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dropdown-menu .dropdown-item {
    display: block;
    width: 100%;
    padding: 0.5rem 1rem;
    clear: both;
    font-weight: 400;
    color: var(--light-text);
    text-align: inherit;
    text-decoration: none;
    white-space: nowrap;
    background-color: transparent;
    border: 0;
    transition: all 0.3s ease;
}

.dropdown-menu .dropdown-item:hover {
    color: var(--accent-teal);
    background-color: rgba(0, 212, 255, 0.1);
}

/* 导航链接悬停效果 */
.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent-teal);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 80%;
}

/* Hero Section 样式 */
.hero-section {
    padding-top: 160px;
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
}

/* 45度渐变文本 */
.gradient-text-45 {
    background: linear-gradient(45deg, var(--neon-blue-alt), var(--neon-purple-alt));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    background-size: 200% 200%;
    animation: gradientMove 5s ease infinite;
}

@keyframes gradientMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 神经网络背景动画 */
.neural-network {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.neural-path {
    position: absolute;
    background: linear-gradient(to right, var(--neon-pink), var(--neon-blue));
    height: 2px;
    opacity: 0.1;
    animation: pulsePath 3s infinite alternate;
}

@keyframes pulsePath {
    0% { opacity: 0.05; }
    100% { opacity: 0.2; }
}

/* 页面加载指示器 */
#pageLoadingIndicator {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--dark);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* 分类按钮样式 */
.category-btn-module {
    transition: all 0.3s ease;
    cursor: pointer;
}

.category-btn-module:hover {
    transform: translateY(-2px);
}

/* 页脚样式 */
.footer {
    background-gradient-to-b from-gray-900 to-black;
    position: relative;
    overflow: hidden;
}

.footer .absolute {
    position: absolute;
    opacity: 10%;
}

/* 确保汉堡菜单在小屏幕上正常显示 */
@media (max-width: 767px) {
    #mobileMenuBtn {
        font-size: clamp(20px, 8vw, 24px);
    }
}