* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #f5f5f5;
    font-family: "Microsoft YaHei", sans-serif;
    background-image: url("/assets/img/index/mainbg.jpg" );
    background-repeat: no-repeat;
    background-size: 100% 100%;
}

.header {
    background: #3c2f2f;
    padding: 10px 0;
    text-align: center;
    background-image: url("/assets/img/index/32px.jpg" );
    background-repeat: no-repeat;
    height: 90px;
}

.banner-container {
    width: 60%;
    margin: 0 auto;
    display: flex;
    justify-content: space-around;
    justify-items: center;
    align-items: center;
}

.header img {
    height: 60px;
}

.center {
    margin-top: -25px;
    height: 90px !important;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
}

.game-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.game-item {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.3s;

    position: relative;
    overflow: hidden;
}


/* 游戏项目相对定位，以便内部元素可以绝对定位 */
.game-item {
    position: relative;
    overflow: hidden;
}

/* 按钮容器样式 */
.game-buttons {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.7);
    opacity: 0;
    transition: opacity 0.3s ease;
    gap: 15px;
}

/* 鼠标悬停时显示按钮 */
.game-item:hover .game-buttons {
    opacity: 1;
}

/* 按钮基本样式 */
.btn {
    display: inline-block;
    padding: 10px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
    transition: transform 0.2s ease;
}

/* 活动详情按钮样式 */
.btn-detail {
    background: linear-gradient(to bottom, #f8e7b3, #d4b45c);
    color: #6b5824;
}

/* 优惠申请按钮样式 */
.btn-apply {
    background: linear-gradient(to bottom, #ff9933, #ff6600);
    color: white;
}

/* 按钮悬停效果 */
.btn:hover {
    transform: scale(1.05);
}


.game-item:hover {
    transform: translateY(-5px);
}

.game-item img {
    width: 100%;
    height: auto;
}

.game-title {
    padding: 10px;
    text-align: center;
    color: #333;
    font-size: 14px;
}

.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1c1d1e;
    color: #fff;
    display: none;
    padding: 10px 0;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
}

.bottom-nav ul {
    display: flex;
    justify-content: space-evenly;
    list-style: none;
}

.bottom-nav li {
    text-align: center;
}

.bottom-nav a {
    color: #fff;
    text-decoration: none;
    font-size: 12px;
}

.bottom-nav i {
    display: block;
    font-size: 20px;
    margin-bottom: 5px;
}



/* 响应式设计 */
/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
}

.modal-content {
    position: relative;
    background-color: #3c2f2f;
    margin: 10% auto;
    padding: 30px;
    width: 80%;
    max-width: 500px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    color: #fff;
    border: 1px solid #d4b45c;
}

.close-btn {
    position: absolute;
    right: 20px;
    top: 10px;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-btn:hover {
    color: #fff;
}

.modal-title {
    text-align: center;
    color: #d4b45c;
    font-size: 24px;
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-size: 16px;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px;
    border-radius: 5px;
    border: none;
    font-size: 16px;
}

.submit-btn {
    display: block;
    width: 100%;
    padding: 12px;
    background-color: #ff6600;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 18px;
    cursor: pointer;
    margin-top: 20px;
    font-weight: bold;
}

.submit-btn:hover {
    background-color: #ff8533;
}

.iconfont  {
    display: none;
}

@media (max-width: 768px) {
    .game-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .bottom-nav {
        display: block;
    }

    .container {
        padding-bottom: 70px;
    }
    
    .center {
        display: none;
    }
    .right {
        display: none;
    }

    .iconfont  {
        position: absolute;
        top: 25px;
        right: 20px;
        font-size: 25px;
        display: block;
        color: #cdb76f;
    }

    .modal-content {
        margin-top: 38%;
    }
}

@media (max-width: 480px) {
    .game-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    /* 鼠标悬停时显示按钮 */
    .game-item:hover .game-buttons {
        display: none;
        opacity: 0;
    }

    .side-nav{
        display: none;
    }
}