* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #EDF0F8;
    color: #2C2F38;
    line-height: 1.6;
    min-height: 100vh;
}

/* ===== 花火·绚烂星幕 - 动态花火星空背景 ===== */
.firework-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    background-color: #EDF0F8;
    overflow: hidden;
}

/* 柔焦暖橙辉光 */
.firework-bg::before {
    content: '';
    position: absolute;
    top: -10%;
    right: -5%;
    width: 240px;
    height: 240px;
    background: radial-gradient(circle, rgba(255, 150, 100, 0.45) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(85px);
    animation: warmGlow 22s ease-in-out infinite;
}

@keyframes warmGlow {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-15px, 25px) scale(1.2); }
}

/* 柔焦淡紫辉光 */
.firework-bg::after {
    content: '';
    position: absolute;
    bottom: -8%;
    left: -5%;
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(180, 140, 220, 0.45) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(90px);
    animation: coolGlow 26s ease-in-out infinite;
}

@keyframes coolGlow {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(20px, -15px) scale(1.15); }
}

/* 流星轨迹1 */
.firework-bg .shooting-star1 {
    position: absolute;
    top: 20%;
    left: -30%;
    width: 80%;
    height: 3px;
    background: linear-gradient(90deg, transparent, rgba(255, 200, 100, 0.6), rgba(255, 255, 255, 0.9), transparent);
    filter: blur(2px);
    transform: rotate(-25deg);
    animation: shoot1 12s linear infinite;
}

@keyframes shoot1 {
    0% { left: -30%; opacity: 0; }
    10% { opacity: 1; }
    30% { opacity: 1; }
    40% { left: 110%; opacity: 0; }
    100% { left: 110%; opacity: 0; }
}

/* 流星轨迹2 */
.firework-bg .shooting-star2 {
    position: absolute;
    top: 50%;
    right: -30%;
    width: 70%;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(180, 220, 255, 0.5), rgba(255, 255, 255, 0.8), transparent);
    filter: blur(3px);
    transform: rotate(20deg);
    animation: shoot2 16s linear infinite;
    animation-delay: 6s;
}

@keyframes shoot2 {
    0% { right: -30%; opacity: 0; }
    10% { opacity: 1; }
    30% { opacity: 1; }
    40% { right: 110%; opacity: 0; }
    100% { right: 110%; opacity: 0; }
}

/* 花火光点层1 - 暖色 */
.firework-bg .sparks-warm {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    box-shadow:
        30px 60px 0 rgba(255, 100, 80, 0.7),
        120px 200px 0 rgba(255, 210, 60, 0.8),
        250px 80px 0 rgba(255, 150, 100, 0.6),
        340px 250px 0 rgba(255, 180, 120, 0.7),
        80px 300px 0 rgba(255, 220, 80, 0.8),
        200px 350px 0 rgba(255, 120, 90, 0.7),
        310px 150px 0 rgba(255, 190, 130, 0.6);
    animation: sparksFloat 8s ease-in-out infinite;
}

/* 花火光点层2 - 冷色 */
.firework-bg .sparks-cool {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    box-shadow:
        60px 120px 0 rgba(120, 230, 160, 0.7),
        180px 40px 0 rgba(100, 200, 220, 0.8),
        300px 200px 0 rgba(200, 140, 230, 0.7),
        50px 250px 0 rgba(130, 220, 180, 0.8),
        220px 300px 0 rgba(160, 180, 240, 0.7),
        330px 80px 0 rgba(110, 210, 200, 0.6);
    animation: sparksFloat 10s ease-in-out infinite reverse;
}

/* 花火光点层3 - 高光白 */
.firework-bg .sparks-white {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    box-shadow:
        15px 80px 0 rgba(255, 255, 255, 0.9),
        140px 30px 0 rgba(255, 255, 255, 0.8),
        260px 160px 0 rgba(255, 255, 255, 0.7),
        350px 300px 0 rgba(255, 255, 255, 0.9),
        70px 350px 0 rgba(255, 255, 255, 0.8),
        190px 110px 0 rgba(255, 255, 255, 0.7);
    animation: sparksFloat 6s ease-in-out infinite;
}

@keyframes sparksFloat {
    0%, 100% { transform: translateY(0); opacity: 0.6; }
    50% { transform: translateY(-10px); opacity: 1; }
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
    padding: 10px;
}

@media (min-width: 768px) {
    .games-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 30px;
    }
}

@media (min-width: 1024px) {
    .games-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 30px;
    }
}

/* ===== 花火·绚烂星幕 - 纯透明装饰卡片 ===== */
.game-card,
.related-game {
    background: rgba(255,255,255,0.7);
    backdrop-filter: blur(6px);
    border-radius: 22px;
    box-shadow:
        4px 6px 20px rgba(180, 140, 190, 0.15),
        30px 60px 0 rgba(255, 100, 80, 0.3),
        -25px -40px 0 rgba(120, 230, 160, 0.25),
        35px -20px 0 rgba(255, 210, 60, 0.28),
        -30px 35px 0 rgba(200, 140, 230, 0.26),
        15px 50px 0 rgba(130, 220, 180, 0.24);
    overflow: hidden;
    transition: all 0.4s ease;
    position: relative;
    animation: fireworkCardBreathe 7s ease-in-out infinite;
}

@keyframes fireworkCardBreathe {
    0%, 100% {
        transform: translateY(0) scale(1);
        box-shadow:
            4px 6px 20px rgba(180, 140, 190, 0.15),
            30px 60px 0 rgba(255, 100, 80, 0.3),
            -25px -40px 0 rgba(120, 230, 160, 0.25),
            35px -20px 0 rgba(255, 210, 60, 0.28),
            -30px 35px 0 rgba(200, 140, 230, 0.26),
            15px 50px 0 rgba(130, 220, 180, 0.24);
    }
    50% {
        transform: translateY(-5px) scale(1.02);
        box-shadow:
            6px 10px 28px rgba(180, 140, 190, 0.22),
            32px 62px 0 rgba(255, 100, 80, 0.38),
            -27px -42px 0 rgba(120, 230, 160, 0.33),
            37px -18px 0 rgba(255, 210, 60, 0.36),
            -32px 37px 0 rgba(200, 140, 230, 0.34),
            17px 52px 0 rgba(130, 220, 180, 0.32);
    }
}

/* 触摸反馈 - 迷你烟花光点爆发 */
.game-card:active,
.related-game:active {
    transform: scale(0.98);
    animation: none !important;
    transition: all 0.2s ease;
    box-shadow:
        4px 4px 20px rgba(180, 140, 190, 0.28),
        inset 0 0 30px rgba(240, 140, 80, 0.18),
        0 0 0 3px solid rgba(200, 140, 230, 0.35);
}

/* 触摸时四周爆开迷你烟花光点 */
.game-card:active::before,
.related-game:active::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 8px;
    height: 8px;
    background: #fff;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow:
        45px -45px 0 3px rgba(255, 100, 80, 0.95),
        -42px -48px 0 2.5px rgba(255, 210, 60, 0.93),
        52px -55px 0 2px rgba(120, 230, 160, 0.91),
        -48px -58px 0 2.5px rgba(200, 140, 230, 0.94),
        32px 42px 0 2px rgba(255, 180, 120, 0.9),
        -45px 46px 0 2.5px rgba(130, 220, 180, 0.92),
        58px 12px 0 2px rgba(255, 200, 100, 0.89),
        -52px -15px 0 2.5px rgba(160, 180, 240, 0.93),
        18px 56px 0 2px rgba(255, 120, 90, 0.88),
        -38px 52px 0 1.5px rgba(240, 195, 145, 0.9);
    animation: miniFireworkExplode 0.5s ease-out forwards;
    pointer-events: none;
    z-index: 10;
}

@keyframes miniFireworkExplode {
    0% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(5); opacity: 0; }
}

/* 卡片内部闪过彩色光带 */
.game-card:active::after,
.related-game:active::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 100, 80, 0.85),
        rgba(255, 210, 60, 0.85),
        rgba(120, 230, 160, 0.85),
        rgba(200, 140, 230, 0.85),
        transparent
    );
    z-index: 10;
    pointer-events: none;
    opacity: 1;
    animation: rainbowSweep 0.5s ease-out forwards;
}

@keyframes rainbowSweep {
    0% { left: -100%; opacity: 1; }
    100% { left: 100%; opacity: 0; }
}

.game-card:hover,
.related-game:hover {
    transform: translateY(-8px) rotate(-0.5deg);
    box-shadow:
        8px 14px 35px rgba(180, 140, 190, 0.28),
        32px 62px 0 rgba(255, 100, 80, 0.4),
        -27px -42px 0 rgba(120, 230, 160, 0.36),
        37px -18px 0 rgba(255, 210, 60, 0.39),
        0 0 0 3px solid rgba(200, 140, 230, 0.3);
}

.game-card:hover img,
.related-game:hover img {
    transform: scale(1.08);
}

/* 标题文字 - 深灰色+小星形前缀 */
.desert-card-title {
    position: relative;
    display: inline-block;
    font-weight: 600;
    color: #2C2F38;
    letter-spacing: 0.3px;
}

.desert-card-title::before {
    content: '★';
    margin-right: 5px;
    font-size: 0.85em;
    color: #FF6450;
}

hr, .divider {
    display: none;
}

hr.dashed, .divider-dashed {
    display: none;
}

.related-games-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

@media (min-width: 768px) {
    .related-games-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 20px;
    }
}

button {
    transition: all 0.4s ease;
    background: linear-gradient(135deg, rgba(255, 100, 80, 0.2), rgba(200, 140, 230, 0.2));
    border: 2px solid rgba(200, 140, 230, 0.5);
    color: #2C2F38;
    position: relative;
    overflow: hidden;
    font-weight: 500;
    cursor: pointer;
    border-radius: 50px;
    box-shadow: 3px 3px 10px rgba(180, 140, 190, 0.25);
}

button:hover {
    transform: translateY(-2px);
    box-shadow:
        5px 5px 15px rgba(180, 140, 190, 0.35),
        0 0 15px rgba(255, 100, 80, 0.3);
    border-color: #FF6450;
}

img {
    max-width: 100%;
    height: auto;
    transition: transform 0.4s ease;
}

a {
    transition: all 0.4s ease;
    color: #3A3D4A;
}

a:hover {
    color: #FF6450;
}

::selection {
    background: rgba(255, 100, 80, 0.35);
    color: #fff;
}

::-webkit-scrollbar {
    width: 14px;
}

::-webkit-scrollbar-track {
    background: #EDF0F8;
    border-left: 2px solid rgba(200, 140, 230, 0.15);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(255, 100, 80, 0.7), rgba(200, 140, 230, 0.7));
    border-radius: 7px;
    border: 2px solid rgba(180, 140, 190, 0.35);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(255, 100, 80, 0.9), rgba(200, 140, 230, 0.9));
}