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

body {
    font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
    color: #333;
    background-color: #e8f5f8;
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

a {
    text-decoration: none;
    color: inherit;
}

ul, ol {
    list-style-position: inside;
    padding-left: 20px;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 10px;
}

.main-container {
    padding-top: 10px;
}

h2 {
    font-size: 20px;
    margin-bottom: 10px;
    color: #333;
    font-weight: bold;
}

h3 {
    font-size: 16px;
    margin-bottom: 10px;
    margin-top: 15px;
}

/* 头部样式 */
header {
    background-color: #e8f5f8;
    position: sticky;
    top: 0;
    z-index: 100;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
}

.logo-search {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 5px 0;
}

.logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-right: 20px;
}

.logo h1 {
    margin: 0;
    padding: 0;
    font-size: 28px;
    font-weight: 800;
    line-height: 1;
}

/* 创建现代化的logo样式 */
.logo-text {
    color: #2962FF;
    letter-spacing: -1px;
    font-family: 'Nunito', sans-serif;
}

.logo-number {
    color: #FF3D00;
    font-size: 32px;
    position: relative;
    top: 2px;
}

.domain-name {
    font-size: 12px;
    color: #666;
    margin-top: 2px;
    letter-spacing: 0.5px;
}

.game-tip {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-grow: 1;
}

.tip-text {
    font-size: 28px;
    font-weight: 800;
    color: #ff6b6b;
    text-align: center;
    padding: 5px 0;
    background: linear-gradient(90deg, transparent, rgba(255,107,107,0.1) 15%, rgba(255,107,107,0.1) 85%, transparent);
    position: relative;
    font-family: 'Impact', 'Arial Black', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: 2px 2px 0 rgba(0,0,0,0.2);
    width: 100%;
}

.tip-text:after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 100px;
    height: 3px;
    background: linear-gradient(90deg, transparent, #ff6b6b, transparent);
    transform: translateX(-50%);
}

.home-icon {
    color: #aaa;
    font-size: 18px;
    cursor: pointer;
    margin-left: 15px;
    transition: color 0.3s;
}

.home-icon:hover {
    color: #007bff;
}

nav ul {
    display: flex;
    padding: 0;
    list-style: none;
    justify-content: flex-end;
}

nav ul li {
    margin-left: 10px;
}

.nav-button {
    display: flex;
    align-items: center;
    background-color: #007bff;
    color: #fff;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 500;
    transition: background-color 0.3s, transform 0.2s;
    font-size: 14px;
    white-space: nowrap;
}

.nav-button img.nav-icon,
.nav-button i.icon-spacing {
    width: 20px;
    height: 20px;
    margin-right: 8px;
    object-fit: contain;
}

.nav-button:hover {
    background-color: #0069d9;
    transform: translateY(-2px);
}

.nav-button.active {
    background-color: #007bff;
    color: #fff;
}

/* 调整游戏网格为两行五列，展示所有10个图片 */
.game-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr); /* 每行5个卡片 */
    gap: 8px; /* 减小间距以适应更多卡片 */
    margin: 15px auto;
    width: 100%;
    max-width: 1400px;
}

/* 游戏卡片基本样式 */
.game-card {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease;
    position: relative;
    cursor: pointer;
}

/* 添加大型卡片样式 */
.game-card.large {
    grid-column: span 2;
    grid-row: span 2;
    min-height: 320px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    border: 1px solid rgba(0, 123, 255, 0.1);
}

/* 大型卡片特殊悬停效果 */
.game-card.large:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 24px rgba(0, 123, 255, 0.2);
    border-color: rgba(0, 123, 255, 0.3);
}

/* 大型卡片标题样式 */
.game-card.large .game-title {
    font-size: 18px;
    padding: 12px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0));
}

/* 添加推荐标记 */
.game-card.large::before {
    content: "热门";
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: #ff6b6b;
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    z-index: 2;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.game-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
}

.game-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* 图片和视频容器样式 */
.game-img {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.game-img img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    transition: opacity 0.3s ease;
}

/* 视频样式，默认隐藏 */
.game-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* 确保视频和图片一样的尺寸比例 */
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}

/* 鼠标悬停时显示视频，隐藏图片 */
.game-card:hover .game-video {
    opacity: 1;
}

.game-card:hover img {
    opacity: 0;
}

/* 游戏标题 */
.game-title {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.7), rgba(0,0,0,0));
    color: white;
    padding: 10px;
    font-weight: 600;
    font-size: 14px;
}

/* 游戏卡片加载动画 */
@keyframes cardAppear {
    from {
        opacity: 0;
        transform: translateY(15px); /* 减小移动距离 */
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.game-card:nth-child(1) { animation-delay: 0.1s; }
.game-card:nth-child(2) { animation-delay: 0.2s; }
.game-card:nth-child(3) { animation-delay: 0.3s; }
.game-card:nth-child(4) { animation-delay: 0.4s; }
.game-card:nth-child(5) { animation-delay: 0.5s; }
.game-card:nth-child(6) { animation-delay: 0.6s; }
.game-card:nth-child(7) { animation-delay: 0.7s; }
.game-card:nth-child(8) { animation-delay: 0.8s; }
.game-card:nth-child(9) { animation-delay: 0.9s; }
.game-card:nth-child(10) { animation-delay: 1.0s; }

/* 卡片点击动画效果 */
@keyframes cardClick {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(0.95);
    }
    100% {
        transform: scale(1);
    }
}

.card-clicked {
    animation: cardClick 0.3s ease;
}

/* 删除不需要的样式 */
.game-card.wide, .game-card.tall {
    /* 重置宽/高卡片，不再使用这些类 */
    grid-column: auto;
    grid-row: auto;
}

.game-item {
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s;
}

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

.game-item img {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.game-item p {
    font-size: 14px;
    color: #666;
}

/* 关于区域 */
.about {
    padding: 20px 0;
    background-color: #f8f9fa;
    margin-top: 15px;
}

.about p {
    margin-bottom: 12px;
    color: #555;
    line-height: 1.6;
    font-size: 14px;
}

/* FAQ区域 */
.faq {
    padding: 20px 0;
    background-color: #e8f5f8;
    margin-top: 0;
}

.faq-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.faq-content {
    flex: 1;
}

.faq-image {
    flex: 0 0 280px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.game-characters {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

.faq h3 {
    margin-bottom: 10px;
    margin-top: 20px;
    color: #333;
    font-weight: 600;
    font-size: 16px;
    padding-left: 5px;
    border-left: 3px solid #ff6b6b;
}

.faq ol {
    margin-bottom: 20px;
    list-style-position: inside;
    padding-left: 5px;
}

.faq li {
    margin-bottom: 6px;
    color: #666;
}

.faq li a {
    color: #0066cc;
    text-decoration: none;
    transition: color 0.2s;
}

.faq li a:hover {
    color: #004499;
    text-decoration: underline;
}

/* 底部区域 */
footer {
    background-color: #343a40;
    color: #f8f9fa;
    padding: 40px 0 15px;
    margin-top: 30px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 25px;
}

.footer-logo h2 {
    color: #fff;
    margin-bottom: 8px;
    font-size: 24px;
}

.footer-logo .logo-text {
    color: #64B5F6;
}

.footer-logo .logo-number {
    color: #FF7043;
}

.footer-logo p {
    color: #adb5bd;
    font-size: 14px;
}

.footer-links ul {
    display: flex;
    flex-wrap: wrap;
    padding: 0;
    list-style: none;
    gap: 15px;
}

.footer-links li {
    margin: 0;
}

.footer-links a {
    color: #dee2e6;
    font-size: 14px;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: #fff;
}

.copyright {
    border-top: 1px solid #495057;
    padding-top: 15px;
    text-align: center;
    color: #6c757d;
    font-size: 12px;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .game-grid {
        grid-template-columns: repeat(4, 1fr); /* 大屏幕4列 */
    }
    nav ul li {
        margin-left: 5px;
    }
    .nav-button {
        padding: 6px 10px;
        font-size: 13px;
    }
    .nav-button img.nav-icon,
    .nav-button i.icon-spacing {
        width: 18px;
        height: 18px;
        margin-right: 5px;
    }
}

@media (max-width: 992px) {
    .game-grid {
        grid-template-columns: repeat(3, 1fr); /* 中等屏幕3列 */
        gap: 8px;
    }
    
    .game-card.large {
        grid-column: span 6;
        min-height: 300px;
    }
    
    .game-card.medium {
        grid-column: span 3;
    }
    header .container {
        flex-direction: column;
        align-items: stretch;
    }
    .logo-search {
        margin-bottom: 10px;
    }
    nav ul {
        justify-content: center;
        flex-wrap: wrap;
        gap: 5px;
    }
    nav ul li {
        margin-left: 0;
    }
}

@media (max-width: 768px) {
    .game-grid {
        grid-template-columns: repeat(3, 1fr); /* 中等屏幕3列 */
        gap: 8px;
    }
    
    .game-card.large {
        grid-column: span 6;
        min-height: 300px;
    }
    
    .game-card.medium {
        grid-column: span 3;
    }
    
    header .container {
        flex-direction: column;
        align-items: stretch;
    }
    
    .logo-search {
        margin-bottom: 10px;
    }
    
    nav ul {
        justify-content: center;
        flex-wrap: wrap;
        gap: 5px;
    }
    
    nav ul li {
        margin-left: 0;
    }
    
    .faq-container {
        flex-direction: column;
    }
    
    .faq-image {
        order: -1;
        margin-bottom: 15px;
        width: 100%;
        flex: 0 0 auto;
    }
    
    .game-characters {
        width: 250px;
    }
    
    .tip-text {
        font-size: 24px;
    }
}

@media (max-width: 576px) {
    .game-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }
    
    .game-card.large, 
    .game-card.medium {
        grid-column: span 2;
        grid-row: span 1;
        min-height: 160px;
    }
    
    .logo-search {
        flex-wrap: wrap;
    }
    
    .game-tip {
        order: 3;
        width: 100%;
        margin: 10px 0 0;
    }
    
    .tip-text {
        width: 100%;
        padding: 8px 0;
        font-size: 18px;
    }
    
    .logo h1 {
        font-size: 20px;
    }
    .nav-button {
        font-size: 12px;
        padding: 5px 8px;
    }
    .nav-button img.nav-icon,
    .nav-button i.icon-spacing {
        width: 16px;
        height: 16px;
        margin-right: 4px;
    }
    
    .footer-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .footer-links ul {
        justify-content: center;
    }
    .game-title {
        font-size: 12px;
        padding: 8px;
    }
}

@media (max-width: 480px) {
    .game-grid {
        grid-template-columns: repeat(2, 1fr); /* 移动设备保持2列 */
        gap: 6px;
    }
}

/* 所有游戏列表 */
.all-games {
    padding: 40px 0;
    background-color: #fff;
}

.game-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 15px;
}

/* 卡片悬停动画效果 */
@keyframes cardHover {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(-5px);
    }
}

.card-hover {
    animation: cardHover 0.3s ease forwards;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12);
}

/* 添加自动播放卡片的样式 */
.card-active {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
    position: relative;
    z-index: 5;
}

.card-active::after {
    content: "";
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    border: 2px solid #007bff;
    border-radius: 10px;
    animation: pulse 1.5s infinite;
    z-index: -1;
}

@keyframes pulse {
    0% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.05);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.game-title-link {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s;
}

.game-title-link:hover {
    color: #007bff;
}

/* 添加大型卡片点击动画效果 */
@keyframes largeCardClick {
    0% {
        transform: scale(1);
    }
    40% {
        transform: scale(0.97);
    }
    70% {
        transform: scale(0.99);
    }
    100% {
        transform: scale(1);
    }
}

/* 大型卡片点击效果 */
.game-card.large.card-clicked {
    animation: largeCardClick 0.4s ease;
    box-shadow: 0 0 20px rgba(0, 123, 255, 0.4);
} 