/* 详情页特定样式 */

/* 游戏详情头部 */
.game-header {
    padding: 80px 0 60px;
    position: relative;
}

.game-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.game-hero-image {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.placeholder-img.large {
    aspect-ratio: 16/9;
    background-size: cover;
    background-position: center;
    position: relative;
}

.placeholder-img.large::before {
    content: '🎮 游戏封面';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2rem;
    font-weight: bold;
    color: white;
    text-shadow: 0 0 20px rgba(0, 0, 0, 0.8);
}

.game-hero-info {
    padding: 20px 0;
}

.game-title {
    font-size: 3.5rem;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #9B59B6, #3498DB, #2ECC71, #F1C40F, #FF6B6B);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: detailTitleGlow 4s ease-in-out infinite;
}

@keyframes detailTitleGlow {
    0%, 100% {
        filter: brightness(1) drop-shadow(0 0 20px rgba(155, 89, 182, 0.5));
    }
    25% {
        filter: brightness(1.1) drop-shadow(0 0 25px rgba(52, 152, 219, 0.6));
    }
    50% {
        filter: brightness(1.2) drop-shadow(0 0 30px rgba(46, 204, 113, 0.7));
    }
    75% {
        filter: brightness(1.1) drop-shadow(0 0 25px rgba(241, 196, 15, 0.6));
    }
}

.game-meta {
    margin-bottom: 30px;
}

.game-meta > * {
    display: block;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.game-genre {
    background: linear-gradient(45deg, #F1C40F, #FF6B6B);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
    font-size: 1.2rem;
    text-shadow: 0 0 10px rgba(241, 196, 15, 0.3);
}

.game-rating {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.2rem;
}

.stars {
    color: #F1C40F;
    font-size: 1.3rem;
    text-shadow: 0 0 8px rgba(241, 196, 15, 0.5);
    animation: starsTwinkle 2s ease-in-out infinite;
}

@keyframes starsTwinkle {
    0%, 100% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.3);
    }
}

.rating {
    color: #ffffff;
    font-weight: 600;
}

.game-release,
.game-developer {
    color: #cccccc;
}

.game-actions {
    display: flex;
    gap: 20px;
    margin-top: 30px;
}

.game-actions .btn {
    flex: 1;
    max-width: 200px;
}

/* 游戏描述 */
.game-description {
    padding: 60px 0;
    border-top: 2px solid rgba(155, 89, 182, 0.3);
    border-bottom: 2px solid rgba(155, 89, 182, 0.3);
    position: relative;
}

.game-description::before {
    content: '';
    position: absolute;
    top: -2px;
    left: 0;
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, #9B59B6, #3498DB, #2ECC71, #F1C40F, #FF6B6B);
    animation: descriptionLine 4s ease-in-out infinite;
}

@keyframes descriptionLine {
    0%, 100% {
        width: 100px;
        opacity: 1;
    }
    50% {
        width: 200px;
        opacity: 0.8;
    }
}

.game-description h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    background: linear-gradient(45deg, #9B59B6, #3498DB);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-align: center;
}

.game-description p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 20px;
    color: #e0e0e0;
    text-align: justify;
}

/* 游戏截图 */
.game-screenshots {
    padding: 60px 0;
    position: relative;
}

.game-screenshots h2 {
    font-size: 2.5rem;
    margin-bottom: 40px;
    background: linear-gradient(45deg, #3498DB, #2ECC71);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-align: center;
}

.screenshots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.screenshot-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.screenshot-item:hover {
    transform: scale(1.05);
    box-shadow: 0 15px 30px rgba(155, 89, 182, 0.4);
}

.screenshot-item .placeholder-img {
    aspect-ratio: 16/9;
}

.screenshot-item .placeholder-img::before {
    content: '📸';
    font-size: 2rem;
}

/* 相关推荐 */
.related-games {
    padding: 60px 0 80px;
    position: relative;
}

.related-games h2 {
    font-size: 2.5rem;
    margin-bottom: 40px;
    background: linear-gradient(45deg, #2ECC71, #F1C40F);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-align: center;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .game-hero {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .game-title {
        font-size: 2.5rem;
    }

    .game-actions {
        justify-content: center;
        flex-wrap: wrap;
    }

    .game-actions .btn {
        max-width: none;
        min-width: 150px;
    }

    .game-description,
    .game-screenshots,
    .related-games {
        padding: 40px 0;
    }

    .game-description h2,
    .game-screenshots h2,
    .related-games h2 {
        font-size: 2rem;
    }

    .screenshots-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .game-header {
        padding: 60px 0 40px;
    }

    .game-title {
        font-size: 2rem;
    }

    .game-meta > * {
        font-size: 1rem;
    }

    .game-actions {
        flex-direction: column;
        align-items: center;
    }

    .game-actions .btn {
        width: 100%;
        max-width: 250px;
    }

    .game-description,
    .game-screenshots,
    .related-games {
        padding: 30px 0;
    }

    .game-description h2,
    .game-screenshots h2,
    .related-games h2 {
        font-size: 1.8rem;
    }
}

/* 特殊动画效果 */
.game-hero-image {
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

.game-hero-info {
    animation: slideInRight 1s ease-out;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.game-description {
    animation: fadeInUp 1s ease-out 0.3s both;
}

.game-screenshots {
    animation: fadeInUp 1s ease-out 0.6s both;
}

.related-games {
    animation: fadeInUp 1s ease-out 0.9s both;
}

/* 截图悬停效果 */
.screenshot-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(155, 89, 182, 0.8), rgba(52, 152, 219, 0.8), rgba(46, 204, 113, 0.8));
    opacity: 0;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
}

.screenshot-item::after {
    content: '点击查看大图';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 1.2rem;
    font-weight: bold;
    opacity: 0;
    transition: all 0.3s ease;
}

.screenshot-item:hover::before,
.screenshot-item:hover::after {
    opacity: 1;
}

/* 背景效果 */
.game-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 80%, rgba(155, 89, 182, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(52, 152, 219, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(46, 204, 113, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(241, 196, 15, 0.1) 0%, transparent 50%);
    pointer-events: none;
    animation: detailHeaderBgShift 12s ease-in-out infinite;
}

@keyframes detailHeaderBgShift {
    0%, 100% {
        opacity: 0.8;
    }
    50% {
        opacity: 1;
    }
}

/* 购买按钮特殊效果 */
.btn-primary {
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '🎮';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.2rem;
    opacity: 0;
    transition: all 0.3s ease;
    filter: hue-rotate(0deg);
}

.btn-primary:hover::before {
    opacity: 1;
    animation: gameIconBounce 0.8s ease-in-out;
}

@keyframes gameIconBounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translate(-50%, -50%) translateY(0) scale(1);
        filter: hue-rotate(0deg);
    }
    40% {
        transform: translate(-50%, -50%) translateY(-12px) scale(1.1);
        filter: hue-rotate(45deg);
    }
    60% {
        transform: translate(-50%, -50%) translateY(-6px) scale(1.05);
        filter: hue-rotate(90deg);
    }
}
