* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Georgia', 'Times New Roman', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #FFF8F0;
    color: #6B4226;
    line-height: 1.6;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* ===== 晨曦·日光棱镜 - 暖白香槟金流动渐变背景 ===== */
.parchment-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    background: linear-gradient(160deg, #FFF8F0, #FFF0E0, #FFF5EC, #FFE8D6, #FFF8F0);
    background-size: 300% 300%;
    animation: warmGoldFlow 15s ease-in-out infinite;
    overflow: hidden;
}

@keyframes warmGoldFlow {
    0%   { background-position: 0% 50%; }
    25%  { background-position: 50% 100%; }
    50%  { background-position: 100% 50%; }
    75%  { background-position: 50% 0%; }
    100% { background-position: 0% 50%; }
}

/* 淡金色几何光点 - 不同周期轻微闪烁 */
.parchment-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 10% 15%, rgba(200, 150, 110, 0.18) 4px, transparent 4px),
        radial-gradient(circle at 25% 78%, rgba(212, 165, 116, 0.16) 5px, transparent 5px),
        radial-gradient(circle at 42% 34%, rgba(184, 134, 90, 0.14) 4px, transparent 4px),
        radial-gradient(circle at 58% 66%, rgba(200, 150, 110, 0.20) 7px, transparent 7px),
        radial-gradient(circle at 73% 22%, rgba(212, 165, 116, 0.15) 4px, transparent 4px),
        radial-gradient(circle at 88% 84%, rgba(184, 134, 90, 0.17) 6px, transparent 6px),
        radial-gradient(circle at 15% 52%, rgba(200, 150, 110, 0.13) 3px, transparent 3px),
        radial-gradient(circle at 33% 85%, rgba(184, 134, 90, 0.16) 4px, transparent 4px),
        radial-gradient(circle at 50% 46%, rgba(212, 165, 116, 0.18) 5px, transparent 5px),
        radial-gradient(circle at 67% 18%, rgba(200, 150, 110, 0.14) 3px, transparent 3px),
        radial-gradient(circle at 82% 54%, rgba(212, 165, 116, 0.16) 4px, transparent 4px);
    animation: warmSparkles 12s ease-in-out infinite alternate;
}

@keyframes warmSparkles {
    0%   { opacity: 0.4; }
    25%  { opacity: 0.7; }
    50%  { opacity: 0.5; }
    75%  { opacity: 0.85; }
    100% { opacity: 0.55; }
}

/* 大范围暖色光晕 */
.parchment-bg::after {
    content: '';
    position: absolute;
    inset: -30%;
    background:
        radial-gradient(ellipse at 20% 20%, rgba(255,240,220,0.12) 0%, transparent 45%),
        radial-gradient(ellipse at 75% 70%, rgba(245,215,180,0.10) 0%, transparent 42%),
        radial-gradient(ellipse at 85% 25%, rgba(235,205,170,0.08) 0%, transparent 38%),
        radial-gradient(ellipse at 15% 75%, rgba(250,225,195,0.09) 0%, transparent 40%);
    animation: warmGlowShift 40s ease-in-out infinite;
}

@keyframes warmGlowShift {
    from { transform: translateX(-1%) translateY(-0.5%); }
    to   { transform: translateX(1%) translateY(0.5%); }
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    padding: 10px;
}

@media (min-width: 768px) {
    .games-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

@media (min-width: 1024px) {
    .games-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 20px;
    }
}

/* ===== 缓慢悬浮动画（translateY ±4px，周期 7s） ===== */
@keyframes cardFloat {
    0%, 100% { transform: translateY(0px); }
    33% { transform: translateY(-4px); }
    66% { transform: translateY(2px); }
}

.game-card {
    transition: all 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border-radius: 16px;
    animation: cardFloat var(--float-dur, 7s) ease-in-out var(--float-delay, 0s) infinite;
    cursor: pointer;
}

.game-card[data-float-dur] {
    --float-dur: calc(attr(data-float-dur) * 1s);
    --float-delay: calc(attr(data-float-delay) * 1s);
}

.game-card:hover {
    transform: translateY(-6px) scale(1.02) !important;
    box-shadow: 0 12px 32px rgba(200, 150, 100, 0.28), 0 0 24px rgba(212, 165, 116, 0.15), inset 0 0 10px rgba(255,255,255,0.05);
    animation-play-state: paused !important;
}

.game-card:hover img {
    transform: scale(1.03);
}

/* ===== 对角扫光动画 (8秒周期) ===== */
.card-sweep-light {
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(
        105deg,
        transparent 20%,
        rgba(212, 165, 116, 0.12) 45%,
        rgba(212, 165, 116, 0.22) 50%,
        rgba(212, 165, 116, 0.12) 55%,
        transparent 80%
    );
    z-index: 8;
    pointer-events: none;
    animation: cardSweepGleam 8s ease-in-out infinite;
}

@keyframes cardSweepGleam {
    0%, 65% { left: -100%; opacity: 0; }
    72% { opacity: 1; }
    85% { left: 200%; opacity: 0; }
    100% { left: 200%; opacity: 0; }
}

/* ===== 触摸反馈 - 轻微缩入效果（scale 0.98）===== */
.game-card:active {
    transform: scale(0.98) translateY(2px) !important;
    box-shadow:
        inset 4px 4px 18px rgba(0, 0, 0, 0.08),
        0 4px 24px rgba(200, 150, 100, 0.25),
        0 0 36px rgba(200, 150, 100, 0.1);
}

/* ===== 触摸反馈 - 涟漪光晕扩散 ===== */
.card-touch-ring {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 10;
    border-radius: 16px;
}
.game-card:active .card-touch-ring::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid #D4A574;
    transform: translate(-50%, -50%);
    animation: goldRingExpand 0.6s ease-out forwards;
    pointer-events: none;
}
@keyframes goldRingExpand {
    0% { width: 10px; height: 10px; opacity: 1; border-width: 3px; }
    100% { width: 250px; height: 250px; opacity: 0; border-width: 0.5px; }
}

/* ===== 标题金色滚动闪烁光效 ===== */
@keyframes titleShine {
    0% { background-position: 200% center; }
    100% { background-position: -200% center; }
}

/* ===== 去除分割线，用交替金色渐变阴影区分层次 ===== */
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;
    }
}

.related-game {
    transition: all 0.35s ease;
    border-radius: 16px;
}

.related-game:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(200, 150, 100, 0.25), 0 0 22px rgba(212, 165, 116, 0.15);
}

button {
    transition: all 0.3s ease;
}

button:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 30px rgba(200, 150, 100, 0.3);
}

img {
    max-width: 100%;
    height: auto;
}

a {
    transition: all 0.3s ease;
}

::selection {
    background: rgba(200, 150, 110, 0.3);
    color: #6B4226;
}

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #FFF5EC;
}

::-webkit-scrollbar-thumb {
    background: rgba(200, 150, 110, 0.35);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(200, 150, 110, 0.55);
}