/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    background-color: #000;
    color: #fff;
}

/* 退出动画 */
.fade-out {
    animation: fadeOut 0.5s ease forwards;
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

/* 磨砂质感效果 */
.icon-bg {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
}

.nav-item:active .icon-bg {
    transform: scale(0.9);
    background: rgba(255, 215, 0, 0.2);
}

.tab-icon-bg {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(145deg, #ffd700, #ff8c00);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 2px 8px rgba(255, 215, 0, 0.3);
}

.tab-icon-bg.inactive {
    background: rgba(50, 50, 50, 0.5);
    box-shadow: none;
}

.game-tab {
    transition: all 0.3s ease;
    position: relative;
}

.game-tab:active {
    transform: scale(0.95);
}

/* 游戏内容切换动画 */
.game-content-container {
    position: relative;
    min-height: 300px;
}

.game-content {
    position: relative;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease, transform 0.5s ease;
    transform: translateY(20px);
    display: none;
}

.game-content.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    display: block;
}

/* 游戏标签切换效果 */
.game-tab.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: #ffd700;
    border-radius: 2px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        opacity: 0.6;
        width: 15px;
    }
    50% {
        opacity: 1;
        width: 25px;
    }
    100% {
        opacity: 0.6;
        width: 15px;
    }
}

/* 公告栏动画 */
.announcement-container {
    width: 100%;
    overflow: hidden;
}

.announcement-content {
    display: inline-block;
    animation: scroll-left 20s linear infinite;
}

@keyframes scroll-left {
    0% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(-100%);
    }
}

/* 游戏卡片悬停效果 */
.game-provider {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.game-provider:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

.game-provider:active {
    transform: translateY(0) scale(0.98);
}

.game-provider.clicked {
    animation: click-pulse 0.3s ease;
}

@keyframes click-pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(0.95);
    }
    100% {
        transform: scale(1);
    }
}

/* 轮播图样式 */
.swiper-container {
    width: 100%;
    height: 160px;
    overflow: hidden;
    position: relative;
}

.swiper-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    transition-property: transform;
}

.swiper-slide {
    width: 100%;
    height: 100%;
    flex-shrink: 0;
    position: relative;
}

.swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.swiper-pagination {
    position: absolute;
    bottom: 10px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    z-index: 10;
}

.swiper-pagination-bullet {
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 1;
    margin: 0 3px;
    border-radius: 50%;
    cursor: pointer;
}

.swiper-pagination-bullet-active {
    background: #ffd700;
    width: 18px;
    border-radius: 3px;
}

/* 按钮动画效果 */
button {
    transition: all 0.2s ease;
}

button:active {
    transform: scale(0.95);
}

.refresh-btn {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
}

.refresh-btn:active {
    transform: rotate(180deg) scale(0.9);
}

.refresh-btn.rotating {
    animation: rotate-360 1s linear;
}

@keyframes rotate-360 {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* 评分星星动画 */
.rating i {
    transition: all 0.3s ease;
}

.game-provider:hover .rating i {
    transform: scale(1.2);
    color: #ffd700;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .max-w-md {
        max-width: 100%;
    }
}

/* 磨砂玻璃效果 */
.glassmorphism {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* 页面过渡动画 */
.page-transition {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 页面加载动画 */
.page-loaded {
    animation: page-load 0.5s ease-out;
}

@keyframes page-load {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* 维护中状态样式 */
.maintenance {
    position: relative;
    overflow: hidden;
}

.maintenance-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
}

.maintenance-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 0.5rem;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* 临时隐藏特定游戏 */
.game-provider[data-game-id="wg_electronic"],
.game-provider[data-game-id="cq9_electronic"],
.game-provider[data-game-id="mg_electronic"],
.game-provider[data-game-id="bg_live"],
.game-provider[data-game-id="allbet_live"],
.game-provider[data-game-id^="ig_lottery"],
.game-provider[data-game-id^="lk_lottery"],
.game-provider[data-game-id^="fc_lottery"],
.game-provider[data-game-id^="jnd_lottery"],
.game-provider[data-game-id^="lottery"] {
    display: none;
}

/* 隐藏整个彩票区域 */
#lottery-games {
    display: none !important;
}

/* 隐藏余额和刷新按钮 */
#balance, 
.refresh-btn {
    display: none !important;
} 