/* ===== 游戏详情页面样式 ===== */

/* 页面背景 */
.game-detail-page {
    background: linear-gradient(180deg, #1b2838 0%, #171a21 100%);
    min-height: 100vh;
    color: #c7d5e0;
}

/* 导航栏 */
.game-navbar {
    background: rgba(30, 58, 138, 0.95);
    backdrop-filter: blur(10px);
}

/* 游戏头部 */
.game-header {
    background: linear-gradient(180deg, rgba(27, 40, 56, 0.7) 0%, rgba(23, 26, 33, 0.9) 100%),
                url('images/game/header-bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 100px 2rem 1rem;
}

.game-header-container {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.game-header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.game-header-img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.game-title {
    font-size: 1.75rem;
    font-weight: 400;
    color: #fff;
}

.community-link {
    color: #67c1f5;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.community-link:hover {
    color: #fff;
}

/* 主内容区域 */
.game-main {
    background: linear-gradient(180deg, #1b2838 0%, #171a21 100%);
    padding: 1rem 2rem 2rem;
}

.game-content-wrapper {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 324px;
    gap: 1.5rem;
}

/* 媒体展示区域 */
.game-media-section {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.main-display {
    position: relative;
    background: #000;
    border-radius: 4px;
    overflow: hidden;
    aspect-ratio: 16/9;
}

.media-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.media-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.media-item.active {
    opacity: 1;
}

.media-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 视频iframe */
.video-item iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
}

/* 视频占位图 */
.video-placeholder {
    width: 100%;
    height: 100%;
    position: relative;
    cursor: pointer;
    z-index: 5;
}

.video-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: rgba(0, 0, 0, 0.6);
    border: 3px solid rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.play-btn:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: translate(-50%, -50%) scale(1.1);
}

.play-btn svg {
    margin-left: 5px;
}

.video-label {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    background: rgba(0, 0, 0, 0.7);
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 1px;
}

/* 缩略图导航 */
.thumbnail-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0, 0, 0, 0.3);
    padding: 0.5rem;
    border-radius: 4px;
}

.nav-arrow {
    width: 32px;
    height: 32px;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    border-radius: 4px;
    color: #67c1f5;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    flex-shrink: 0;
}

.nav-arrow:hover {
    background: rgba(103, 193, 245, 0.2);
}

.thumbnail-track {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    flex: 1;
    padding: 0.25rem 0;
}

.thumbnail-track::-webkit-scrollbar {
    height: 4px;
}

.thumbnail-track::-webkit-scrollbar-track {
    background: transparent;
}

.thumbnail-track::-webkit-scrollbar-thumb {
    background: rgba(103, 193, 245, 0.3);
    border-radius: 2px;
}

.thumbnail {
    width: 116px;
    height: 65px;
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    flex-shrink: 0;
    position: relative;
    border: 2px solid transparent;
    transition: all 0.2s;
}

.thumbnail:hover {
    border-color: rgba(103, 193, 245, 0.5);
}

.thumbnail.active {
    border-color: #67c1f5;
}

.thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.thumbnail .play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 30px;
    height: 30px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 游戏信息区域 */
.game-info-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.game-cover {
    position: relative;
    border-radius: 4px;
    overflow: hidden;
}

.game-cover img {
    width: 100%;
    display: block;
}

.patch-badge {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background: linear-gradient(135deg, #06b6d4, #3b82f6);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
    text-align: center;
    line-height: 1.3;
    color: #fff;
}

.game-description {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #acb2b8;
}

/* 游戏元数据 */
.game-meta {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-size: 0.85rem;
}

.meta-row {
    display: flex;
    gap: 0.5rem;
}

.meta-label {
    color: #556772;
    min-width: 80px;
}

.meta-value {
    color: #8f98a0;
}

.meta-value.positive {
    color: #a8cfff;
}

.meta-value.very-positive {
    color: #66c0f4;
}

.meta-value.link {
    color: #67c1f5;
    cursor: pointer;
}

.meta-value.link:hover {
    color: #fff;
}

/* 标签 */
.game-tags {
    margin-top: 0.5rem;
}

.tag-label {
    font-size: 0.75rem;
    color: #556772;
    display: block;
    margin-bottom: 0.5rem;
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    padding: 0.25rem 0.75rem;
    background: rgba(103, 193, 245, 0.15);
    border-radius: 3px;
    font-size: 0.8rem;
    color: #67c1f5;
    cursor: pointer;
    transition: all 0.2s;
}

.tag:hover {
    background: rgba(103, 193, 245, 0.25);
}

.tag.more {
    background: rgba(103, 193, 245, 0.3);
}

/* ===== 关于游戏区域 ===== */
.game-about {
    background: linear-gradient(180deg, #171a21 0%, #1b2838 100%);
    padding: 2rem;
    clear: both;
    width: 100%;
}

.about-container {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.section-title {
    font-size: 0.9rem;
    font-weight: 400;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 1.5rem;
}

.about-logo {
    text-align: center;
    margin-bottom: 1rem;
    margin-top: -1rem;
}

.about-logo img {
    max-width: 400px;
    height: auto;
}

.about-content {
    max-height: 400px;
    overflow: hidden;
    transition: max-height 0.5s ease;
    position: relative;
}

.about-content.expanded {
    max-height: none;
}

.about-content::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100px;
    background: linear-gradient(transparent, #171a21);
    pointer-events: none;
    transition: opacity 0.3s;
}

.about-content.expanded::after {
    opacity: 0;
}

.intro-text {
    font-size: 1rem;
    line-height: 1.8;
    color: #67c1f5;
    margin-bottom: 1.5rem;
}

.intro-text em {
    font-style: italic;
}

.feature-section {
    margin-bottom: 1.5rem;
}

.feature-section h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 0.5rem;
}

.feature-section p {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #acb2b8;
}

.about-image {
    margin: 1.5rem 0;
    border-radius: 4px;
    overflow: hidden;
}

.about-image img {
    width: 100%;
    display: block;
}

/* 视频区域 */
.about-video {
    margin: 1.5rem 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    aspect-ratio: 16 / 9;
    background: #1a1a2e;
}

.about-video video {
    width: 100%;
    height: 100%;
    display: block;
    border-radius: 8px;
    object-fit: cover;
}

.about-video video:focus {
    outline: none;
}

.expand-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    max-width: 800px;
    padding: 1rem;
    background: rgba(103, 193, 245, 0.1);
    border: none;
    border-radius: 4px;
    color: #67c1f5;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s;
    margin: 1rem auto 0;
}

.expand-btn:hover {
    background: rgba(103, 193, 245, 0.2);
}

.expand-btn.expanded svg {
    transform: rotate(180deg);
}

/* ===== 系统需求 ===== */
.system-requirements {
    background: #171a21;
    padding: 2rem;
    clear: both;
}

.requirements-container {
    max-width: 800px;
    margin: 0 auto;
}

.requirements-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.requirement-column h3 {
    font-size: 0.85rem;
    font-weight: 400;
    color: #fff;
    margin-bottom: 1rem;
}

.requirement-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.requirement-list li {
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
    line-height: 1.5;
}

.req-label {
    color: #556772;
}

.req-value {
    color: #acb2b8;
}

/* ===== 页脚 ===== */
.game-footer {
    background: #171a21;
    padding: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-container {
    max-width: 1100px;
    margin: 0 auto;
    text-align: left;
}

.game-footer p {
    font-size: 0.75rem;
    color: #556772;
    margin-bottom: 0.25rem;
    line-height: 1.5;
}

/* ===== 响应式设计 ===== */
@media (max-width: 1024px) {
    .game-content-wrapper {
        grid-template-columns: 1fr;
    }

    .game-info-section {
        order: -1;
    }

    .game-cover {
        max-width: 400px;
    }
}

@media (max-width: 768px) {
    .game-header {
        padding: 90px 1rem 1rem;
    }

    .game-header-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .game-main {
        padding: 1rem;
    }

    .requirements-grid {
        grid-template-columns: 1fr;
    }

    .game-about,
    .system-requirements,
    .game-footer {
        padding: 1.5rem 1rem;
    }

    .thumbnail {
        width: 100px;
        height: 56px;
    }
}

@media (max-width: 480px) {
    .game-title {
        font-size: 1.4rem;
    }

    .meta-row {
        flex-direction: column;
        gap: 0.1rem;
    }

    .meta-label {
        min-width: auto;
    }
}

/* ===== 视频加载状态 ===== */
#videoLoading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    background: rgba(0, 0, 0, 0.8);
    padding: 30px;
    border-radius: 12px;
    z-index: 10;
}

#videoLoading .loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-top-color: #06b6d4;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

#localVideo {
    background: #000;
}

/* 视频切换按钮（可选，用于手动切换） */
.video-source-toggle {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    border: none;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    z-index: 20;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.media-item:hover .video-source-toggle {
    opacity: 1;
}

.video-source-toggle:hover {
    background: rgba(6, 182, 212, 0.8);
}