:root {
    --primary-color: #2563eb;
    --secondary-color: #3b82f6;
    --text-color: #1f2937;
    --bg-color: #ffffff;
}

/* 深色模式变量 */
.dark-mode {
    --text-color: #ffffff;
    --bg-color: #1a1a1a;
}

/* 通用样式 */
body {
    color: var(--text-color);
    background-color: var(--bg-color);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* 移动端默认字体 */
body {
    font-family: -apple-system, system-ui, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Helvetica Neue', sans-serif;
}

/* 桌面端默认字体 */
@media screen and (min-width: 768px) {
    body {
        font-family: 'Helvetica Neue', Helvetica, 'Hiragino Sans GB', 'STHeitiSC-Light', 'Microsoft YaHei', '微软雅黑', 'WenQuanYi Micro Hei', Arial, sans-serif;
    }
}

a {
    text-decoration: none;
}

/* 深色模式样式覆盖 */
.dark-mode .navbar-scrolled {
    background-color: #2d2d2d;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* 深色模式导航栏样式 */
.dark-mode .navbar {
    background-color: #1a1a1a;
}

.dark-mode .navbar-light .navbar-nav .nav-link,
.dark-mode .navbar-light .navbar-brand {
    color: #ffffff;
}

.dark-mode .navbar-light .navbar-nav .nav-link:hover,
.dark-mode .navbar-light .navbar-nav .nav-link:focus {
    color: rgba(255, 255, 255, 0.8);
}

.dark-mode .navbar-light .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.1);
}

.dark-mode .navbar-light .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255, 255, 255, 0.8)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.dark-mode .hero {
    background: linear-gradient(to right, #1a1a1a, #2d2d2d);
}

/* 优势卡片的深色模式样式 */
.dark-mode .advantages {
    background-color: #1a1a1a !important;
}

.dark-mode .advantage-card {
    background-color: #2d2d2d !important;
    color: var(--text-color);
}

/* 深色模式切换按钮样式 */
#darkModeToggle {
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    padding: 8px;
}

#darkModeToggle i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

#darkModeToggle:hover i {
    transform: rotate(15deg);
}

/* 导航栏 */
.navbar {
    transition: all 0.3s ease;
    background-color: transparent;
}

.navbar-scrolled {
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.backdrop-blur {
    backdrop-filter: blur(10px);
}

/* Hero 区域 */
.hero {
    padding-top: 80px;
    background: linear-gradient(to right, #f8fafc, #eff6ff);
}

/* 卡片样式 */
.card {
    transition: transform 0.2s ease;
}

.card:hover {
    transform: translateY(-5px);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .hero {
        text-align: center;
    }

    .hero .features-list {
        text-align: left;
    }
    
    .hero .btn-group {
        justify-content: center;
    }

    .contact {
        text-align: center;
    }

    .contact .qrcode {
        margin: 0 auto;
    }
}

/* 动画效果 */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

/* 卡片悬停效果 */
.product-card {
    transition: all 0.3s ease;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1) !important;
}

/* 图标动画 */
.icon-wrapper {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.icon-wrapper i {
    font-size: 24px;
    color: white;
}

.product-card:hover .icon-wrapper {
    transform: scale(1.1) rotate(10deg);
}

/* 按钮动画 */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

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

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

/* 页面切换动画 */
.page-transition {
    animation: pageTransition 0.5s ease;
}

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

/* Footer Styles */
.footer {
    border-top: 1px solid rgba(0,0,0,0.1);
}

.footer a {
    transition: color 0.3s ease;
}

.footer a:hover {
    color: var(--primary-color) !important;
}

.footer .bi {
    font-size: 1.2rem;
}

/* 暗色模式适配 */
[data-bs-theme="dark"] .footer {
    background-color: #1a1a1a !important;
    border-top: 1px solid rgba(255,255,255,0.1);
}

[data-bs-theme="dark"] .footer .text-muted {
    color: #a0a0a0 !important;
}

/* 动画效果 */
.footer [data-aos] {
    transition-duration: 800ms;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .footer {
        text-align: center;
    }
    
    .footer .d-flex {
        justify-content: center;
    }
    
    .footer h5 {
        margin-top: 1.5rem;
    }
}

/* Language Switcher Styles */
.dropdown-menu {
    min-width: 100px;
}

.dropdown-item {
    cursor: pointer;
    padding: 0.5rem 1rem;
    transition: background-color 0.2s ease;
}

.dropdown-item:hover {
    background-color: var(--bs-primary-bg-subtle);
}

#langToggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--bs-body-color);
    text-decoration: none;
}

#langToggle:hover {
    color: var(--bs-primary);
}

#langToggle .bi-globe2 {
    font-size: 1.2rem;
}

/* 暗色模式适配 */
[data-bs-theme="dark"] .dropdown-item:hover {
    background-color: var(--bs-primary-bg-subtle);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--bs-primary);
    color: white;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    padding: 0;
    border: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.back-to-top:hover {
    background-color: var(--bs-primary-dark, #0056b3);
    transform: translateY(-3px);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

/* 适配移动端 */
@media (max-width: 768px) {
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 35px;
        height: 35px;
    }
}


/* 品牌标语样式 */
.brand-separator {
    margin: 0 10px;
    color: #666;
    font-weight: 300;
}

.brand-slogan {
    font-size: 0.9rem;
    color: #666;
    font-weight: 300;
}

/* 深色模式下的样式 */
.dark-mode .brand-separator,
.dark-mode .brand-slogan {
    color: #fff;
}
