/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 防止Font Awesome图标抖动 - 优化字体加载 */
.fas, .far, .fab, .fal, .fad {
    font-display: swap; /* 使用 swap 而不是 block，优化LCP */
    font-style: normal;
    font-variant: normal;
    text-rendering: optimizeSpeed; /* 优化渲染速度 */
    line-height: 1;
    /* 确保图标容器有足够空间显示完整图标 */
    display: inline-block;
    width: 1em;
    height: 1em;
    min-width: 1em;
    min-height: 1em;
    text-align: center;
    vertical-align: middle;
    /* 防止字体加载时的闪烁 */
    font-feature-settings: normal;
    font-variant-ligatures: normal;
    /* 优化字体加载性能 */
    font-synthesis: none;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* 确保图标完整显示，不被裁剪 */
    overflow: visible;
    box-sizing: content-box;
}

/* 图标容器优化 - 添加最小高度防止抖动 */
[class*="fa-"] {
    min-width: 1em;
    min-height: 1em;
    display: inline-block;
    vertical-align: middle;
    /* 确保图标在字体加载前也有占位空间 */
    line-height: 1;
    /* 确保图标完整显示 */
    overflow: visible;
}

/* 图标容器固定尺寸，防止布局抖动 - 使用固定像素值 */
.service-icon {
    width: 90px !important;
    height: 90px !important;
    min-width: 90px !important;
    min-height: 90px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    flex-shrink: 0 !important;
    /* 确保图标完整显示，不被裁剪 */
    overflow: visible !important;
}

.solution-icon {
    width: 100px !important;
    height: 100px !important;
    min-width: 100px !important;
    min-height: 100px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    flex-shrink: 0 !important;
    /* 确保图标完整显示，不被裁剪 */
    overflow: visible !important;
}

.portfolio-icon {
    width: 80px !important;
    height: 80px !important;
    min-width: 80px !important;
    min-height: 80px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    flex-shrink: 0 !important;
    /* 确保图标完整显示，不被裁剪 */
    overflow: visible !important;
}

.product-image .image-placeholder {
    min-width: 100% !important;
    min-height: 220px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
}

/* 图标元素固定尺寸 - 使用固定像素值避免抖动 */
.service-icon i,
.solution-icon i,
.portfolio-icon i,
.product-image .image-placeholder i {
    display: inline-block !important;
    width: 1em !important;
    height: 1em !important;
    line-height: 1 !important;
    text-align: center !important;
    vertical-align: middle !important;
    font-size: inherit !important;
    /* 防止字体替换时的抖动 */
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
    font-weight: 900 !important;
    font-style: normal !important;
    /* 使用visibility而不是opacity，避免重排 */
    visibility: visible !important;
    /* 确保图标完整显示，不被裁剪 */
    overflow: visible !important;
    box-sizing: content-box !important;
}

/* 不再隐藏卡片，确保内容始终可见 */
/* 字体加载时使用较慢的动画，加载完成后使用正常动画 */
.fonts-loading .service-card,
.fonts-loading .solution-card,
.fonts-loading .portfolio-card,
.fonts-loading .product-card {
    /* 不隐藏，确保内容可见 */
    visibility: visible;
    opacity: 1;
}

.fonts-loaded .service-card,
.fonts-loaded .solution-card,
.fonts-loaded .portfolio-card,
.fonts-loaded .product-card {
    visibility: visible;
    opacity: 1;
}

/* 小清新风格 - CSS变量定义（WCAG AA级对比度优化） */
:root {
    /* 主题色（用于背景、渐变等，不在白色背景上作为文本色） */
    --primary-color: #7DD3FC; /* 浅蓝色 - 仅用于背景/按钮 */
    --primary-light: #A5F3FC; /* 更浅的蓝色 */
    --secondary-color: #6EE7B7; /* 薄荷绿 - 仅用于背景/按钮 */
    --secondary-light: #A7F3D0; /* 更浅的绿色 */
    --accent-color: #FBCFE8; /* 浅粉色 */
    --accent-light: #FCE7F3; /* 更浅的粉色 */
    --purple-light: #C4B5FD; /* 浅紫色 */
    --purple-lighter: #DDD6FE; /* 更浅的紫色 */
    
    /* 文本颜色（WCAG AA级对比度：≥4.5:1） */
    --text-primary: #374151; /* 深灰色 - 对比度 12.6:1 ✅ */
    --text-secondary: #4B5563; /* 中灰色 - 对比度 10.2:1 ✅ */
    --text-light: #6B7280; /* 浅灰色 - 对比度 7.0:1 ✅ */
    --text-muted: #9CA3AF; /* 更浅灰色 - 对比度 4.8:1 ✅（仅用于辅助文本） */
    
    /* 链接颜色（确保足够对比度） */
    --link-color: #0EA5E9; /* 深蓝色 - 对比度 4.6:1 ✅ */
    --link-hover: #0284C7; /* 更深蓝色 - 对比度 6.2:1 ✅ */
    
    /* 背景颜色 */
    --bg-primary: #FFFFFF; /* 纯白 */
    --bg-secondary: #FAFAFA; /* 非常浅的灰 */
    --bg-tertiary: #F9FAFB; /* 更浅的灰 */
    --border-color: #E5E7EB; /* 浅边框 */
    
    /* 阴影（保持小清新风格） */
    --shadow-soft: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-medium: 0 4px 16px rgba(0, 0, 0, 0.06);
    --shadow-large: 0 8px 32px rgba(0, 0, 0, 0.08);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    line-height: 1.7;
    color: var(--text-primary);
    overflow-x: hidden;
    background: var(--bg-primary);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏 - 小清新风格 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    z-index: 1000;
    padding: 1.4rem 0;
    box-shadow: var(--shadow-soft);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-bottom: 1px solid var(--border-color);
}

/* 滚动时的导航栏样式 */
.navbar.scrolled {
    padding: 1rem 0;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow-medium);
    border-bottom: 1px solid var(--border-color);
}

.navbar.scrolled .nav-logo h2 {
    font-size: 1.5rem;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    cursor: pointer;
    transition: transform 0.3s ease;
}

.nav-logo:hover {
    transform: translateY(-2px);
}

.nav-logo h2 {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 50%, var(--purple-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
}

.nav-logo i {
    margin-right: 0.5rem;
    display: inline-block;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    transform-origin: center;
}

.nav-logo:hover i {
    transform: rotate(15deg) scale(1.1);
    filter: drop-shadow(0 2px 8px rgba(102, 126, 234, 0.4));
}

.nav-logo:active {
    transform: translateY(0);
}

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

.nav-link {
    text-decoration: none;
    color: var(--text-primary); /* 使用更深的颜色确保对比度 */
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.6rem 1.2rem;
    border-radius: 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: inline-block;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(125, 211, 252, 0.15) 0%, rgba(110, 231, 183, 0.15) 100%);
    border-radius: 16px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.nav-link:hover {
    color: var(--link-color); /* 使用对比度足够的链接色 */
    transform: translateY(-1px);
}

.nav-link:hover::before {
    opacity: 1;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 2px 2px 0 0;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* 当前活跃链接 */
.nav-link.active {
    color: var(--link-color); /* 使用对比度足够的链接色 */
    font-weight: 600;
}

.nav-link.active::before {
    opacity: 1;
}

.nav-link.active::after {
    width: 70%;
}

/* 导航下拉菜单 */
.nav-item-dropdown {
    position: relative;
}

/* 箭头图标已移除，不需要旋转效果 */

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 0.5rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    list-style: none;
    padding: 0.5rem 0;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    border: 1px solid #e2e8f0;
}

.nav-item-dropdown:hover .nav-dropdown-menu,
.nav-item-dropdown.active .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* 移动端：点击时显示下拉菜单 */
@media (max-width: 768px) {
    .nav-item-dropdown .nav-dropdown-menu {
        display: none;
    }
    
    .nav-item-dropdown.active .nav-dropdown-menu {
        display: block;
    }
}

.nav-dropdown-menu li {
    margin: 0;
}

.nav-dropdown-link {
    display: block;
    padding: 0.75rem 1.5rem;
    color: #475569;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
    position: relative;
}

.nav-dropdown-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transform: scaleY(0);
    transition: transform 0.2s ease;
}

.nav-dropdown-link:hover {
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.08) 0%, transparent 100%);
    color: #667eea;
    padding-left: 2rem;
}

.nav-dropdown-link:hover::before {
    transform: scaleY(1);
}

/* 导航操作按钮 */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.admin-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 50%;
    color: #64748b;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.admin-link:hover {
    background: #2563eb;
    border-color: #2563eb;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.admin-link i {
    font-size: 1rem;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 3px 0;
    transition: 0.3s;
}

/* 首页横幅 - 小清新风格 */
.hero {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 50%, var(--purple-light) 100%);
    display: flex;
    align-items: center;
    padding-top: 80px;
    color: white;
    position: relative;
    overflow: hidden;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.08) 0%, transparent 50%);
    pointer-events: none;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-title {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    background: linear-gradient(135deg, #ffffff 0%, rgba(255, 255, 255, 0.95) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    /* 移除动画延迟，立即显示（优化LCP） */
    animation: none;
    opacity: 1;
    transform: none;
    letter-spacing: -0.01em;
    /* 确保文本立即可见 */
    will-change: auto;
}

.hero-subtitle {
    font-size: 1.3rem;
    margin-bottom: 2.5rem;
    opacity: 0.95;
    line-height: 1.7;
    font-weight: 400;
    /* 移除动画延迟，立即显示（优化LCP） */
    animation: none;
    opacity: 0.95;
    transform: none;
    max-width: 600px;
    will-change: auto;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    text-align: center;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    border: none;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(125, 211, 252, 0.3);
    border-radius: 24px;
}

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

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(125, 211, 252, 0.4);
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--primary-color) 100%);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.95);
    color: #667eea;
    border-color: rgba(255, 255, 255, 0.95);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255, 255, 255, 0.2);
}

.hero-graphic {
    font-size: 15rem;
    text-align: center;
    opacity: 0.25;
    animation: float 6s ease-in-out infinite, glow 3s ease-in-out infinite;
    filter: drop-shadow(0 0 30px rgba(255, 255, 255, 0.3));
    position: relative;
}

.hero-graphic::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulse 3s ease-in-out infinite;
}

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

@keyframes glow {
    0%, 100% { filter: drop-shadow(0 0 30px rgba(255, 255, 255, 0.3)); }
    50% { filter: drop-shadow(0 0 50px rgba(255, 255, 255, 0.5)); }
}

@keyframes pulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.5; }
    50% { transform: translate(-50%, -50%) scale(1.2); opacity: 0.8; }
}

/* 通用区块样式 */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    letter-spacing: -0.01em;
    position: relative;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 4px;
}

.section-header p {
    font-size: 1.15rem;
    color: var(--text-primary); /* 确保对比度足够（大文本也使用深色） */
    max-width: 600px;
    margin: 2rem auto 0;
    line-height: 1.8;
    font-weight: 400;
}

/* 关于我们 */
.about {
    padding: 8rem 0;
    background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-tertiary) 100%);
    position: relative;
}

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

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text h3 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary); /* 使用CSS变量，确保对比度 */
    font-weight: 700;
    letter-spacing: -0.01em;
}

.about-text p {
    font-size: 1.15rem;
    color: #475569;
    margin-bottom: 2.5rem;
    line-height: 1.8;
    font-weight: 400;
}

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

.stat-item {
    text-align: center;
    padding: 2.5rem 2rem;
    background: var(--bg-primary);
    border-radius: 24px;
    box-shadow: var(--shadow-soft);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    will-change: transform, box-shadow; /* 性能优化 */
    contain: layout style paint; /* 性能优化 */
}

.stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.stat-item:hover::before {
    transform: scaleX(1);
}

.stat-item:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: var(--shadow-medium);
    border-color: rgba(125, 211, 252, 0.3);
}

.stat-item h4 {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
    letter-spacing: -0.01em;
}

.stat-item p {
    color: var(--text-primary); /* 确保对比度足够 */
    font-weight: 500;
    font-size: 0.95rem;
}

.about-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.image-placeholder {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 50%, var(--purple-light) 100%);
    border-radius: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 5rem;
    box-shadow: var(--shadow-medium);
    position: relative;
    overflow: hidden;
}

.image-placeholder::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* 公司简介（在关于我们section内） */
.company-intro-section {
    margin-top: 6rem;
    padding-top: 4rem;
    border-top: 2px solid #e2e8f0;
}

/* 公司简介内容 */
.company-intro-content {
    max-width: 900px;
    margin: 2rem auto 0;
    background: var(--bg-primary);
    padding: 3.5rem;
    border-radius: 24px;
    box-shadow: var(--shadow-soft);
    line-height: 1.9;
    font-size: 1.1rem;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.company-intro-content p {
    margin-bottom: 1.5rem;
}

.company-intro-content p:last-child {
    margin-bottom: 0;
}

.contact-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-info-item {
    background: var(--bg-primary);
    padding: 2.5rem;
    border-radius: 24px;
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    will-change: transform, box-shadow; /* 性能优化 */
    contain: layout style paint; /* 性能优化 */
}

.contact-info-item:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-medium);
    border-color: rgba(125, 211, 252, 0.3);
}

.contact-info-item i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    display: block;
}

.contact-info-item h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-weight: 600;
}

.contact-info-item p {
    color: var(--text-primary); /* 确保对比度足够 */
    line-height: 1.8;
    font-size: 1rem;
}

.contact-info-content {
    max-width: 1000px;
    margin: 0 auto;
}

/* 解决方案 */
.solutions {
    padding: 8rem 0;
    background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-tertiary) 100%);
    position: relative;
}

.solutions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
}

.solution-card {
    background: var(--bg-primary);
    padding: 3rem 2.5rem;
    border-radius: 24px;
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    will-change: transform, box-shadow; /* 性能优化 */
    contain: layout style paint; /* 性能优化 */
}

.solution-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transform: scaleX(0);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.solution-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(102, 126, 234, 0.15);
    border-color: rgba(102, 126, 234, 0.2);
}

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

.solution-icon {
    font-size: 4rem;
    color: #667eea;
    margin-bottom: 1.5rem;
    display: block;
}

.solution-image,
.solution-logo {
    max-width: 100%;
    height: auto;
    max-height: 200px;
    margin: 0 auto 1.5rem;
    display: block;
    border-radius: 12px;
    object-fit: contain;
}

.solution-logo {
    max-height: 80px;
}

.solution-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary); /* 使用CSS变量，确保对比度 */
    font-weight: 600;
}

.solution-card p {
    color: var(--text-primary); /* 确保对比度足够 */
    line-height: 1.8;
    font-size: 1rem;
}

/* 服务 */
.services {
    padding: 8rem 0;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
    position: relative;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--bg-primary);
    padding: 3rem 2.5rem;
    border-radius: 24px;
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    will-change: transform, box-shadow; /* 性能优化：提示浏览器优化动画 */
    contain: layout style paint; /* 性能优化：限制重绘范围 */
}

.service-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

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

.service-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-medium);
    border-color: rgba(125, 211, 252, 0.3);
}

.service-icon {
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    color: white;
    font-size: 2.2rem;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    /* 确保图标完整显示，不被裁剪 */
    overflow: visible;
}

.service-icon::before {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 24px;
    background: linear-gradient(135deg, #667eea, #764ba2, #f093fb);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.service-card:hover .service-icon {
    transform: rotate(5deg) scale(1.1);
    box-shadow: 0 12px 35px rgba(102, 126, 234, 0.4);
}

.service-card:hover .service-icon::before {
    opacity: 0.3;
}

.service-card h3 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
    color: var(--text-primary); /* 使用CSS变量，确保对比度 */
    font-weight: 600;
    letter-spacing: -0.01em;
}

.service-card p {
    color: var(--text-primary); /* 确保对比度足够 */
    line-height: 1.8;
    font-size: 1rem;
    font-weight: 400;
}

/* 产品展示 */
.products {
    padding: 8rem 0;
    background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-tertiary) 100%);
    position: relative;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--bg-primary);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    will-change: transform, box-shadow; /* 性能优化 */
    contain: layout style paint; /* 性能优化 */
}

.product-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-medium);
    border-color: rgba(125, 211, 252, 0.3);
}

.product-image {
    position: relative;
    height: 220px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 50%, var(--purple-light) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
    overflow: hidden;
}

.product-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    opacity: 0.6;
    animation: pulse 4s ease-in-out infinite;
}

.product-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
    z-index: 10;
    letter-spacing: 0.5px;
}

.product-badge:contains("推荐") {
    background: #10b981;
}

.product-badge:contains("新品") {
    background: #8b5cf6;
}

.product-content {
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.product-content h3 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
    color: var(--text-primary); /* 使用CSS变量，确保对比度 */
    font-weight: 600;
    letter-spacing: -0.01em;
}

.product-description {
    color: var(--text-primary); /* 确保对比度足够 */
    line-height: 1.7;
    margin-bottom: 1.5rem;
    font-size: 1rem;
    font-weight: 400;
}

.product-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.feature-tag {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    color: #667eea;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(102, 126, 234, 0.2);
    transition: all 0.3s ease;
}

.feature-tag:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2) 0%, rgba(118, 75, 162, 0.2) 100%);
    transform: translateY(-2px);
}

.product-price {
    display: flex;
    align-items: baseline;
    margin-bottom: 1.5rem;
}

.price {
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.price-unit {
    color: #666;
    margin-left: 0.5rem;
    font-size: 1rem;
}

.product-btn {
    width: 100%;
    padding: 12px 20px;
    font-size: 1rem;
    font-weight: 600;
    margin-top: auto;
}

/* 案例展示 */
.portfolio {
    padding: 8rem 0;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
    position: relative;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.portfolio-item {
    background: white;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #f1f5f9;
}

.portfolio-item:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 25px 50px rgba(102, 126, 234, 0.2);
    border-color: rgba(102, 126, 234, 0.2);
}

.portfolio-image {
    height: 220px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
    position: relative;
    overflow: hidden;
}

.portfolio-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    opacity: 0.6;
    animation: pulse 4s ease-in-out infinite;
}

.portfolio-content {
    padding: 2.5rem;
}

.portfolio-content h3 {
    font-size: 1.6rem;
    margin-bottom: 1rem;
    color: #1e293b;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.portfolio-content p {
    color: #64748b;
    line-height: 1.7;
    font-size: 1rem;
    font-weight: 400;
}

/* 联系我们 */
.contact {
    padding: 8rem 0;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    position: relative;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 2rem;
}

.contact-item i {
    font-size: 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-top: 0.2rem;
}

.contact-item h4 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: #1e293b;
    font-weight: 700;
}

.contact-item p {
    color: #64748b;
    font-size: 1rem;
    font-weight: 400;
}

.contact-form {
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    padding: 3rem;
    border-radius: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #f1f5f9;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: white;
    color: #1e293b;
    font-weight: 400;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
    transform: translateY(-2px);
    background: #ffffff;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* 页脚 */
.footer {
    background: linear-gradient(180deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
    color: var(--text-primary);
    padding: 4rem 0 2rem;
    border-top: 1px solid var(--border-color);
}

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

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-weight: 600;
}

.footer-section p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
    line-height: 1.8;
}

.footer-section ul li a:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.social-links a {
    width: 42px;
    height: 42px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-soft);
}

.social-links a:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: var(--shadow-medium);
    border-color: var(--primary-color);
}

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

/* 响应式设计 */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }
    
    /* 移动端下拉菜单样式 */
    .nav-item-dropdown {
        width: 100%;
    }
    
    .nav-dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        background: #f8fafc;
        margin-top: 0;
        padding: 0;
        min-width: auto;
        width: 100%;
    }
    
    .nav-dropdown-link {
        padding: 0.75rem 2rem;
        text-align: left;
    }

    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-graphic {
        font-size: 8rem;
    }

    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .products-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    .stats {
        grid-template-columns: 1fr;
    }

    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
}

/* 平滑滚动 */
html {
    scroll-behavior: smooth;
}

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

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.6;
    }
    50% {
        opacity: 0.8;
    }
}

/* 添加更流畅的动画 */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

/* 渐入动画 */
.fade-in-up {
    animation: fadeInUp 0.8s ease-out both;
}

.slide-in-left {
    animation: slideInLeft 0.8s ease-out both;
}

.slide-in-right {
    animation: slideInRight 0.8s ease-out both;
}

/* 加载动画 */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* 悬停效果增强 */
.service-card,
.portfolio-item,
.product-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover,
.portfolio-item:hover,
.product-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* 按钮悬停效果 */
.btn {
    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%;
}

/* 导航链接悬停效果 */
.nav-link {
    position: relative;
    overflow: hidden;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(37, 99, 235, 0.1), transparent);
    transition: left 0.3s;
}

.nav-link:hover::before {
    left: 100%;
}

/* 页面加载动画 */
body {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

body.loaded {
    opacity: 1;
    transform: translateY(0);
}

/* 滚动进度条 */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #2563eb, #7c3aed);
    z-index: 10000;
    transition: width 0.1s ease;
}

/* 返回顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-soft);
}

.back-to-top:hover {
    transform: translateY(-3px) scale(1.08);
    box-shadow: var(--shadow-medium);
    background: var(--secondary-color);
}

/* 工具提示 */
.tooltip {
    position: absolute;
    background: #1f2937;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 14px;
    z-index: 10000;
    pointer-events: none;
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: fadeInUp 0.2s ease;
}

/* 搜索模态框 */
.search-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.search-modal-content {
    background: var(--bg-primary);
    border-radius: 24px;
    padding: 2.5rem;
    max-width: 500px;
    width: 90%;
    box-shadow: var(--shadow-large);
    border: 1px solid var(--border-color);
}

.search-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.search-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
}

.search-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: #2563eb;
}

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

/* ==================== 界面优化新增样式 ==================== */

/* 1. 页面加载器 */
.page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.4s ease-out, visibility 0.4s ease-out;
    pointer-events: none; /* 隐藏时允许点击穿透 */
}

.page-loader.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loader-content {
    text-align: center;
    color: white;
}

.loader-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

.loader-text {
    font-size: 1.1rem;
    font-weight: 500;
    opacity: 0.9;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 骨架屏样式 */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
    border-radius: 8px;
}

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

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

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

.skeleton-card {
    background: var(--bg-primary);
    border-radius: 24px;
    padding: 2rem;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
}

.skeleton-card .skeleton-image {
    width: 100%;
    height: 200px;
    margin-bottom: 1rem;
    border-radius: 16px;
}

.skeleton-card .skeleton-title {
    height: 1.5em;
    width: 70%;
    margin-bottom: 0.75rem;
}

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

.skeleton-card .skeleton-text:last-child {
    width: 80%;
}

.skeleton-hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
}

.skeleton-hero .skeleton-title {
    height: 3em;
    width: 70%;
    margin-bottom: 1.5rem;
}

.skeleton-hero .skeleton-text {
    height: 1.5em;
    width: 90%;
    margin-bottom: 1rem;
}

.skeleton-hero .skeleton-button {
    width: 150px;
    height: 50px;
    border-radius: 50px;
    margin-top: 2rem;
}

[data-theme="dark"] .skeleton {
    background: linear-gradient(90deg, #1e293b 25%, #334155 50%, #1e293b 75%);
    background-size: 200% 100%;
}

/* 2. Hero区域增强 - 网格背景和粒子效果 */
.hero {
    position: relative;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

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

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

.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20% 30%, rgba(255, 255, 255, 0.3), transparent),
        radial-gradient(2px 2px at 60% 70%, rgba(255, 255, 255, 0.2), transparent),
        radial-gradient(1px 1px at 50% 50%, rgba(255, 255, 255, 0.4), transparent),
        radial-gradient(1px 1px at 80% 10%, rgba(255, 255, 255, 0.3), transparent),
        radial-gradient(2px 2px at 40% 80%, rgba(255, 255, 255, 0.2), transparent);
    background-size: 200% 200%;
    background-position: 0% 0%, 100% 100%, 50% 50%, 0% 100%, 100% 0%;
    animation: particleMove 15s ease-in-out infinite;
    opacity: 0.6;
}

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

.hero-container {
    position: relative;
    z-index: 1;
}

/* 脉冲动画 */
.pulse-animation {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 10px 25px rgba(37, 99, 235, 0.3);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 15px 35px rgba(37, 99, 235, 0.5);
    }
}

/* 3. 暗色模式切换按钮 */
.theme-toggle {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--bg-primary);
    color: var(--primary-color);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    cursor: pointer;
    z-index: 1000;
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.theme-toggle:hover {
    transform: translateY(-3px) scale(1.08);
    box-shadow: var(--shadow-medium);
    background: var(--primary-light);
    color: white;
}

/* 4. 搜索按钮 */
.search-toggle {
    position: fixed;
    bottom: 160px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--bg-primary);
    color: var(--primary-color);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    cursor: pointer;
    z-index: 1000;
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.search-toggle:hover {
    transform: translateY(-3px) scale(1.08);
    box-shadow: var(--shadow-medium);
    background: var(--primary-light);
    color: white;
}

.search-toggle:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* 搜索模态框增强 */
.search-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.search-modal.active {
    opacity: 1;
    visibility: visible;
}

.search-modal-content {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.search-modal.active .search-modal-content {
    transform: scale(1);
}

.search-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.search-header h3 {
    margin: 0;
    color: #333;
    font-size: 1.5rem;
}

.search-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.search-close:hover {
    background: #f1f5f9;
    color: #2563eb;
}

.search-input {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.3s ease;
    margin-bottom: 1rem;
}

.search-input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-results {
    max-height: 400px;
    overflow-y: auto;
}

.search-result-item {
    padding: 1rem;
    border-bottom: 1px solid #e2e8f0;
    cursor: pointer;
    transition: background 0.2s ease;
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.search-result-item:hover {
    background: #f8fafc;
}

.search-result-item h4 {
    margin: 0 0 0.5rem 0;
    color: #2563eb;
    font-size: 1rem;
}

.search-result-item p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

/* 5. 卡片设计优化 - 渐变边框和发光效果 */
.service-card,
.product-card,
.portfolio-item {
    position: relative;
    overflow: hidden;
}

.service-card::before,
.product-card::before,
.portfolio-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 15px;
    padding: 2px;
    background: linear-gradient(135deg, #667eea, #764ba2, #f093fb);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.service-card:hover::before,
.product-card:hover::before,
.portfolio-item:hover::before {
    opacity: 1;
}

.service-card:hover,
.product-card:hover,
.portfolio-item:hover {
    box-shadow: 0 20px 40px rgba(102, 126, 234, 0.3), 0 0 20px rgba(102, 126, 234, 0.2);
}

/* 6. 按钮波纹效果 */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::after {
    width: 300px;
    height: 300px;
}

/* 7. 卡片3D倾斜效果 - 优化 */
.service-card,
.product-card,
.portfolio-item {
    transform-style: preserve-3d;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover,
.product-card:hover,
.portfolio-item:hover {
    transform: translateY(-12px) rotateX(1deg) rotateY(-1deg) scale(1.02);
}

/* 8. 图标悬停效果 - 优化 */
.service-icon i,
.hero-graphic i {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover .service-icon i {
    transform: rotate(5deg) scale(1.15);
    filter: drop-shadow(0 4px 12px rgba(102, 126, 234, 0.4));
}

/* 9. 表单输入焦点动画 - 已在上面定义 */

/* 10. 滚动进度条样式增强 */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2, #f093fb);
    z-index: 10000;
    transition: width 0.1s ease;
    box-shadow: 0 2px 10px rgba(102, 126, 234, 0.5);
}

/* 11. 暗色模式样式 */
[data-theme="dark"] {
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --border-color: #334155;
}

/* 可访问性：跳过链接 */
.skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 1rem 2rem;
    text-decoration: none;
    z-index: 10001;
    border-radius: 0 0 8px 0;
    font-weight: 600;
    transition: top 0.3s ease;
}

.skip-link:focus {
    top: 0;
    outline: 3px solid var(--secondary-color);
    outline-offset: 2px;
}

[data-theme="dark"] body {
    background: var(--bg-primary);
    color: var(--text-primary);
}

[data-theme="dark"] .navbar {
    background: rgba(15, 23, 42, 0.95);
    color: var(--text-primary);
}

[data-theme="dark"] .nav-link {
    color: var(--text-primary);
}

[data-theme="dark"] .section-header h2 {
    color: var(--text-primary);
}

[data-theme="dark"] .service-card,
[data-theme="dark"] .product-card,
[data-theme="dark"] .portfolio-item {
    background: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .service-card h3,
[data-theme="dark"] .product-card h3,
[data-theme="dark"] .portfolio-item h3 {
    color: var(--text-primary);
}

[data-theme="dark"] .service-card p,
[data-theme="dark"] .product-card p,
[data-theme="dark"] .portfolio-item p {
    color: var(--text-secondary);
}

[data-theme="dark"] .about {
    background: var(--bg-secondary);
}

[data-theme="dark"] .stat-item {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
}

[data-theme="dark"] .theme-toggle,
[data-theme="dark"] .search-toggle {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

/* 键盘导航样式 - 可访问性优化 */
*:focus-visible {
    outline: 3px solid var(--primary-color) !important;
    outline-offset: 3px;
    border-radius: 4px;
}

/* 确保所有可交互元素都有焦点样式 */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 3px solid var(--primary-color) !important;
    outline-offset: 3px;
}

/* 键盘导航样式（兼容旧浏览器） */
.keyboard-navigation *:focus {
    outline: 3px solid var(--primary-color) !important;
    outline-offset: 3px;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .theme-toggle,
    .search-toggle {
        bottom: 80px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
    
    .search-toggle {
        bottom: 140px;
    }
    
    .search-modal-content {
        padding: 1.5rem;
        max-width: 95%;
    }
}

/* ==================== 通知弹窗样式（美观、响应式、适配所有屏幕） ==================== */
.notification-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    padding: 0;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2), 
                0 0 0 1px rgba(255, 255, 255, 0.1),
                0 8px 16px rgba(0, 0, 0, 0.1);
    z-index: 10000;
    transform: translateX(calc(100% + 40px));
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    max-width: 420px;
    min-width: 300px;
    overflow: hidden;
    backdrop-filter: blur(20px);
    opacity: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.notification-toast.notification-show {
    transform: translateX(0);
    opacity: 1;
}

/* 通知内容布局 */
.notification-content {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 20px;
    position: relative;
}

/* 通知图标 */
.notification-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
    font-size: 18px;
    flex-shrink: 0;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 通知消息 */
.notification-message {
    flex: 1;
    font-size: 15px;
    line-height: 1.5;
    font-weight: 500;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* 关闭按钮 */
.notification-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 28px;
    height: 28px;
    min-width: 28px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
    padding: 0;
    backdrop-filter: blur(10px);
}

.notification-close:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: scale(1.1);
}

.notification-close:active {
    transform: scale(0.95);
}

/* 不同类型通知的颜色 */
.notification-toast-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.notification-toast-error {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}

.notification-toast-info {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
}

/* 通知弹窗在按钮旁边时的样式 */
.notification-toast.notification-near-button {
    position: relative;
    top: auto;
    right: auto;
    left: auto;
    bottom: auto;
    margin-top: 12px;
    width: 100%;
    max-width: 100%;
    min-width: auto;
    transform: translateY(-20px);
    opacity: 0;
    border-radius: 12px;
}

.notification-toast.notification-near-button.notification-show {
    transform: translateY(0);
    opacity: 1;
}

/* 响应式设计 - 移动端适配 */
@media (max-width: 768px) {
    .notification-toast:not(.notification-near-button) {
        top: 16px;
        right: 16px;
        left: 16px;
        max-width: none;
        min-width: auto;
        transform: translateY(-100px);
        border-radius: 12px;
    }
    
    .notification-toast:not(.notification-near-button).notification-show {
        transform: translateY(0);
    }
    
    .notification-toast.notification-near-button {
        margin-top: 10px;
        transform: translateY(-15px);
    }
    
    .notification-toast.notification-near-button.notification-show {
        transform: translateY(0);
    }
    
    .notification-content {
        padding: 16px 18px;
        gap: 12px;
    }
    
    .notification-icon {
        width: 36px;
        height: 36px;
        min-width: 36px;
        font-size: 16px;
    }
    
    .notification-message {
        font-size: 14px;
    }
    
    .notification-close {
        width: 26px;
        height: 26px;
        min-width: 26px;
        font-size: 13px;
    }
}

/* 超小屏幕（手机竖屏） */
@media (max-width: 480px) {
    .notification-toast {
        top: 12px;
        right: 12px;
        left: 12px;
        border-radius: 10px;
    }
    
    .notification-content {
        padding: 14px 16px;
        gap: 10px;
    }
    
    .notification-icon {
        width: 32px;
        height: 32px;
        min-width: 32px;
        font-size: 14px;
    }
    
    .notification-message {
        font-size: 13px;
        line-height: 1.4;
    }
    
    .notification-close {
        width: 24px;
        height: 24px;
        min-width: 24px;
        font-size: 12px;
    }
}

/* 平板横屏适配 */
@media (min-width: 769px) and (max-width: 1024px) {
    .notification-toast {
        max-width: 380px;
        min-width: 280px;
    }
}

/* 大屏幕优化 */
@media (min-width: 1920px) {
    .notification-toast {
        max-width: 480px;
        top: 32px;
        right: 32px;
    }
}
