/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --secondary-color: #1e293b;
    --accent-color: #f43f5e;
    --text-color: #334155;
    --text-light: #64748b;
    --bg-color: #f8fafc;
    --bg-dark: #0f172a;
    --border-color: #e2e8f0;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 按钮 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--secondary-color);
    color: white;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: white;
}

.btn-danger {
    background: var(--danger-color);
    color: white;
}

.btn-warning {
    background: var(--warning-color);
    color: white;
}

.btn-success {
    background: var(--success-color);
    color: white;
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 15px 0;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: white;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-menu a {
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary-color);
}

/* 下拉菜单 */
.nav-item {
    position: relative;
}

.nav-item.has-dropdown > a {
    display: flex;
    align-items: center;
    gap: 5px;
}

.dropdown-arrow {
    font-size: 10px;
    transition: transform 0.3s;
}

.nav-item.has-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 150px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 1000;
    padding: 8px 0;
    list-style: none;
}

.nav-item.has-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    margin: 0;
}

.dropdown-menu a {
    display: block;
    padding: 10px 20px;
    color: #333;
    font-size: 14px;
    transition: all 0.3s;
}

.dropdown-menu a:hover {
    background: #f5f5f5;
    color: var(--primary-color);
}

.nav-auth {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nav-auth span {
    color: rgba(255, 255, 255, 0.8);
}

/* 轮播图 */
.hero-slider {
    position: relative;
    height: 70vh;
    min-height: 500px;
    margin-top: 60px;
}

.slides {
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.slide::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.5), rgba(15, 23, 42, 0.9));
}

.slide.active {
    opacity: 1;
}

.slide-content {
    position: relative;
    z-index: 1;
    color: white;
    padding-top: 120px;
    max-width: 600px;
}

.slide-content h1 {
    font-size: 48px;
    font-weight: 700;
    margin: 20px 0;
}

.slide-content p {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 30px;
}

.slider-nav {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.nav-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: none;
    cursor: pointer;
    transition: all 0.3s;
}

.nav-dot.active {
    background: var(--primary-color);
    transform: scale(1.2);
}

/* 标签 */
.badge {
    display: inline-block;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 20px;
    text-transform: uppercase;
}

.badge-news { background: var(--primary-color); color: white; }
.badge-update { background: var(--warning-color); color: white; }
.badge-event { background: var(--success-color); color: white; }
.badge-success { background: var(--success-color); color: white; }
.badge-danger { background: var(--danger-color); color: white; }
.badge-primary { background: var(--primary-color); color: white; }
.badge-top { background: var(--accent-color); color: white; }

/* 区块标题 */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 30px;
}

.section-header h2 {
    font-size: 32px;
    font-weight: 700;
    color: var(--secondary-color);
}

/* 产品网格 */
.products-section,
.videos-section,
.announcements-section {
    padding: 80px 0;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.products-grid.large {
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
}

.product-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.product-cover {
    position: relative;
    display: block;
    height: 200px;
    overflow: hidden;
}

.product-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-cover img {
    transform: scale(1.1);
}

.product-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.product-cover:hover .product-overlay {
    opacity: 1;
}
}

.product-cover:hover .product-overlay {
    opacity: 1;
}

.product-info {
    padding: 20px;
}

.product-info h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}

.product-info h3 a:hover {
    color: var(--primary-color);
}

.product-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 10px;
    font-size: 14px;
    color: var(--text-light);
}

.product-desc {
    color: var(--text-light);
    font-size: 14px;
}

/* 视频网格 */
.videos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.videos-grid.large {
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
}

.videos-grid.small {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.video-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
    cursor: pointer;
    transition: all 0.3s ease;
}

.video-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.video-cover {
    position: relative;
    height: 180px;
    overflow: hidden;
}

.video-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(99, 102, 241, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    transition: all 0.3s;
}

.video-card:hover .play-btn {
    transform: translate(-50%, -50%) scale(1.1);
    background: var(--primary-color);
}

.video-info {
    padding: 15px 20px;
}

.video-info h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 5px;
}

.video-info p {
    color: var(--text-light);
    font-size: 14px;
}

.video-info .views {
    font-size: 12px;
    color: var(--text-light);
}

/* 公告列表 */
.announcements-list {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: var(--shadow);
}

.announcement-item {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    transition: background 0.3s;
}

.announcement-item:last-child {
    border-bottom: none;
}

.announcement-item:hover {
    background: var(--bg-color);
}

.announcement-item .badge {
    flex-shrink: 0;
    margin-right: 15px;
}

.announcement-item .title {
    flex: 1;
    font-weight: 500;
}

.announcement-item .date {
    color: var(--text-light);
    font-size: 14px;
}

/* 页面Banner */
.page-banner {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 120px 0 60px;
    margin-top: 60px;
    text-align: center;
}

.page-banner h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 10px;
}

.page-banner p {
    font-size: 18px;
    opacity: 0.8;
}

/* 公告网格 */
.announcements-grid {
    display: grid;
    gap: 30px;
}

.announcement-card {
    display: flex;
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.announcement-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.announcement-card .card-image {
    width: 300px;
    flex-shrink: 0;
}

.announcement-card .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.announcement-card .card-content {
    padding: 25px;
    flex: 1;
}

.announcement-card .card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.announcement-card .date {
    color: var(--text-light);
    font-size: 14px;
}

.announcement-card h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 10px;
}

.announcement-card p {
    color: var(--text-light);
    margin-bottom: 15px;
}

.announcement-card .read-more {
    color: var(--primary-color);
    font-weight: 500;
}

/* 筛选栏 */
.filter-bar {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    background: white;
    padding: 15px;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.filter-bar a {
    padding: 8px 20px;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s;
}

.filter-bar a:hover,
.filter-bar a.active {
    background: var(--primary-color);
    color: white;
}

/* 文章页 */
.article-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 100px 20px 60px;
}

.article-header {
    text-align: center;
    margin-bottom: 40px;
}

.article-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
    color: var(--text-light);
}

.article-header h1 {
    font-size: 36px;
    font-weight: 700;
}

.article-cover {
    margin-bottom: 40px;
    border-radius: 16px;
    overflow: hidden;
}

.article-content {
    background: white;
    padding: 40px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    line-height: 1.8;
}

.article-content h2,
.article-content h3 {
    margin: 30px 0 15px;
}

.article-content p {
    margin-bottom: 20px;
}

.article-content ul,
.article-content ol {
    margin: 20px 0;
    padding-left: 30px;
}

.article-content li {
    margin-bottom: 10px;
}

.article-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 40px;
    gap: 20px;
}

.article-nav a {
    padding: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow);
    flex: 1;
    transition: all 0.3s;
}

.article-nav a:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.article-nav span {
    color: var(--text-light);
    font-size: 14px;
}

.article-nav p {
    font-weight: 600;
    margin-top: 5px;
}

/* 产品详情页 */
.product-detail {
    padding: 60px 0;
    margin-top: 60px;
}

.detail-grid {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
}

.detail-section {
    background: white;
    padding: 30px;
    border-radius: 16px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
}

.detail-section h2 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--border-color);
}

.description {
    line-height: 1.8;
}

.features-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.features-list li {
    padding: 15px 20px;
    background: var(--bg-color);
    border-radius: 10px;
    position: relative;
    padding-left: 40px;
}

.features-list li::before {
    content: '✓';
    position: absolute;
    left: 15px;
    color: var(--success-color);
    font-weight: bold;
}

.video-player {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 12px;
}

.video-player iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.sidebar-card {
    background: white;
    padding: 25px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    position: sticky;
    top: 80px;
}

.sidebar-card .cover-image {
    width: 100%;
    border-radius: 12px;
    margin-bottom: 20px;
}

.game-info {
    margin-bottom: 20px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.info-item:last-child {
    border-bottom: none;
}

.info-item .label {
    color: var(--text-light);
}

.info-item .value {
    font-weight: 600;
}

.related-products {
    margin-top: 60px;
}

.related-products h2 {
    font-size: 28px;
    margin-bottom: 30px;
}

/* 认证页面 */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--bg-dark), var(--secondary-color));
    padding: 20px;
}

.auth-container {
    width: 100%;
    max-width: 450px;
}

.auth-box {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
}

.auth-box h1 {
    font-size: 28px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 10px;
}

.auth-subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 30px;
}

.auth-form .form-group {
    margin-bottom: 20px;
}

.auth-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-color);
}

.auth-form input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-size: 15px;
    transition: border-color 0.3s;
}

.auth-form input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.input-with-btn {
    display: flex;
    gap: 10px;
}

.input-with-btn input {
    flex: 1;
}

.input-with-btn .btn {
    white-space: nowrap;
}

.auth-link {
    text-align: center;
    margin-top: 20px;
    color: var(--text-light);
}

.auth-link a {
    color: var(--primary-color);
    font-weight: 500;
}

/* 弹窗 */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 900px;
    position: relative;
}

.modal-content #videoContainer {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
}

.modal-content iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 16px;
}

.close-btn {
    position: absolute;
    top: -40px;
    right: 0;
    font-size: 30px;
    color: white;
    cursor: pointer;
    z-index: 10;
}

/* 提示框 */
.alert {
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-weight: 500;
    animation: fadeOut 0.5s ease 2s forwards;
}

@keyframes fadeOut {
    from { opacity: 1; transform: translateY(0); }
    to { opacity: 0; transform: translateY(-10px); height: 0; padding: 0; margin: 0; }
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
}

.alert-error {
    background: #fee2e2;
    color: #991b1b;
}

/* 空状态 */
.empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-light);
}

/* 页脚 */
.footer {
    background: var(--bg-dark);
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand h3 {
    font-size: 24px;
    margin-bottom: 10px;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.6);
}

.footer-links h4 {
    font-size: 16px;
    margin-bottom: 15px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.6);
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
}

.footer-beian {
    margin-top: 10px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
}

.footer-beian a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-beian a:hover {
    color: var(--primary-color);
}

/* 响应式 */
@media (max-width: 1024px) {
    .detail-grid {
        grid-template-columns: 1fr;
    }
    
    .sidebar-card {
        position: static;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .hero-slider {
        height: 50vh;
    }
    
    .slide-content h1 {
        font-size: 32px;
    }
    
    .products-grid,
    .products-grid.large,
    .videos-grid,
    .videos-grid.large {
        grid-template-columns: 1fr;
    }
    
    .videos-grid.small {
        grid-template-columns: 1fr;
    }
    
    .features-list {
        grid-template-columns: 1fr;
    }
    
    .announcement-card {
        flex-direction: column;
    }
    
    .announcement-card .card-image {
        width: 100%;
        height: 200px;
    }
    
    .article-nav {
        flex-direction: column;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* 游戏截图展示 */
.screenshots-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.screenshot-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.screenshot-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.screenshot-item img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.screenshot-item:hover img {
    transform: scale(1.05);
}

.screenshot-item::after {
    content: '🔍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 40px;
    opacity: 0;
    transition: opacity 0.3s;
}

.screenshot-item:hover::after {
    opacity: 1;
}

/* 图片灯箱 */
.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 3000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.lightbox.active {
    display: flex;
}

.lightbox img {
    max-width: 90%;
    max-height: 90vh;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.lightbox-close {
    position: fixed;
    top: 30px;
    right: 30px;
    font-size: 40px;
    color: white;
    cursor: pointer;
    z-index: 3010;
    transition: transform 0.3s;
}

.lightbox-close:hover {
    transform: rotate(90deg);
}

/* 公告弹窗 */
.popup-announcement {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.popup-content {
    background: white;
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow: hidden;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 28px;
    color: #666;
    cursor: pointer;
    z-index: 10;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.popup-close:hover {
    background: rgba(0, 0, 0, 0.1);
    color: #333;
}

.popup-image img {
    width: 100%;
    max-height: 300px;
    object-fit: cover;
}

.popup-body {
    padding: 25px;
}

.popup-body h3 {
    font-size: 20px;
    color: #333;
    margin-bottom: 15px;
    line-height: 1.4;
}

.popup-body p {
    font-size: 14px;
    color: #666;
    line-height: 1.8;
}

.popup-content a {
    display: block;
    text-decoration: none;
}

.popup-content a:hover .popup-body h3 {
    color: var(--primary-color);
}

