/* CSS Variables for theme colors and fonts */
:root {
  --primary-color: #FF4C29;  /* Fire-like orange/red */
  --secondary-color: #2C7DA0;  /* Water-like blue */
  --background-color: #2A2438;  /* Dark purple for retro feel */
  --text-color: #FFE6D6;  /* Warm light color for text */
  --header-height: 80px;
  --retro-font: 'Press Start 2P', cursive;  /* Retro gaming font */
}

/* Base styles */
body {
  margin: 0;
  padding: 0;
  background-color: var(--background-color);
  color: var(--text-color);
}

/* Header styles */
.site-header {
  background: linear-gradient(to right, #1a1625, #2A2438, #1a1625);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  padding: 1rem;
  border-bottom: 3px solid #FF4C29;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.logo-link {
  display: block;
}

.site-logo {
  width: 60px;
  height: 60px;
  object-fit: contain;
}

.site-title {
  font-family: var(--retro-font), system-ui;
  font-size: 1.8rem;
  margin: 0;
  background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
  letter-spacing: 1px;
}

/* Responsive design */
@media (max-width: 768px) {
  .site-title {
    font-size: 1.4rem;
  }
  
  .site-logo {
    width: 50px;
    height: 50px;
  }
}

@media (max-width: 480px) {
  .site-title {
    font-size: 1.2rem;
  }
  
  .site-logo {
    width: 40px;
    height: 40px;
  }
}

/* Game Section Layout */
.game-section {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.game-layout {
    display: grid;
    grid-template-columns: 1fr 250px;
    grid-template-areas: 
        "main sidebar"
        "bottom sidebar";
    gap: 1rem;
}

/* Main Game Area */
.game-main {
    grid-area: main;
    background: #1a1625;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    aspect-ratio: 16/9;
    width: 100%;
    position: relative;
}

.game-iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* 全屏按钮样式 */
.fullscreen-btn {
    position: absolute;
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    border: 2px solid rgba(255, 255, 255, 0.2);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
    padding: 0;
}

.fullscreen-btn:hover {
    background: rgba(0, 0, 0, 0.8);
    border-color: rgba(255, 255, 255, 0.4);
    transform: scale(1.1);
}

.fullscreen-icon {
    fill: white;
    width: 24px;
    height: 24px;
    transition: transform 0.3s ease;
}

.fullscreen-btn:hover .fullscreen-icon {
    transform: scale(0.9);
}

/* 全屏样式 */
.game-iframe:fullscreen,
.game-iframe:-webkit-full-screen,
.game-iframe:-moz-full-screen,
.game-iframe:-ms-fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    border: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    object-fit: contain;
    background: black;
}

/* Right Sidebar Navigation */
.game-sidebar {
    grid-area: sidebar;
}

.nav-game-card {
    display: block;
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    transition: transform 0.3s ease;
    margin-bottom: 1rem;
}

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

.nav-game-img {
    width: 100%;
    height: 200px; /* 固定高度 */
    object-fit: cover; /* 确保图片填充但不变形 */
    display: block;
}

.nav-game-title {
    color: var(--text-color);
    padding: 1rem;
    font-size: 1rem;
    display: block;
    text-align: center;
}

/* Bottom Navigation */
.game-bottom-nav {
    grid-area: bottom;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.bottom-game-card {
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    transition: transform 0.3s ease;
}

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

.bottom-game-img {
    width: 100%;
    height: 150px; /* 固定高度 */
    object-fit: cover; /* 确保图片填充但不变形 */
    display: block;
}

.bottom-game-title {
    color: var(--text-color);
    padding: 1rem;
    font-size: 1rem;
    display: block;
    text-align: center;
}

/* 响应式设计更新 */
@media (max-width: 1440px) {
    .game-section {
        max-width: 1200px;
    }
}

@media (max-width: 1024px) {
    .game-layout {
        grid-template-columns: 1fr 200px;
    }
    
    .game-section {
        max-width: 1000px;
    }
}

@media (max-width: 768px) {
    .game-layout {
        grid-template-columns: 1fr;
        grid-template-areas: 
            "main"
            "sidebar"
            "bottom";
    }
    
    .game-section {
        padding: 0 0.5rem;
    }
    
    .nav-game-img {
        height: 160px;
    }
    
    .bottom-game-img {
        height: 130px;
    }
    
    .game-bottom-nav {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
}

@media (max-width: 480px) {
    .nav-game-img {
        height: 140px;
    }
    
    .bottom-game-img {
        height: 120px;
    }
    
    .game-bottom-nav {
        grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    }
}

/* Hero Section */
.hero-section {
    padding: 4rem 1rem;
    background: linear-gradient(45deg, rgba(26, 22, 37, 0.9), rgba(42, 36, 56, 0.9));
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.hero-content {
    color: var(--text-color);
}

.hero-title {
    font-family: var(--retro-font);
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-description {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.hero-features {
    list-style: none;
    padding: 0;
    margin-bottom: 2rem;
}

.hero-features li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.8rem;
}

.hero-features li::before {
    content: "▶";
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

.hero-controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    padding: 1.5rem;
    background: rgba(26, 22, 37, 0.6);
    border-radius: 8px;
    margin-top: 2rem;
}

.control-group h3 {
    font-family: var(--retro-font);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.hero-image {
    position: relative;
}

.hero-img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 0 20px rgba(255, 76, 41, 0.3);
}

/* Responsive Design */
@media (max-width: 968px) {
    .hero-container {
        grid-template-columns: 1fr;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-image {
        order: -1;
    }
}

@media (max-width: 480px) {
    .hero-controls {
        grid-template-columns: 1fr;
    }
}

/* Feature Section Styles */
.feature-section {
    padding: 4rem 1rem;
    background: linear-gradient(to bottom, rgba(26, 22, 37, 0.9), rgba(42, 36, 56, 0.9));
}

.feature-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

.feature-card {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 2rem;
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.feature-image {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
}

.feature-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.feature-content h3 {
    font-family: var(--retro-font);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.feature-content p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--text-color);
}

/* Responsive Design */
@media (max-width: 968px) {
    .feature-card {
        grid-template-columns: 1fr;
    }
    
    .feature-image {
        height: 200px;
    }
}

@media (max-width: 480px) {
    .feature-content h3 {
        font-size: 1.2rem;
    }
    
    .feature-content p {
        font-size: 1rem;
    }
}

/* Common Section Styles */
.what-is-section,
.how-to-section,
.why-section {
    padding: 4rem 1rem;
    background: linear-gradient(to bottom, rgba(26, 22, 37, 0.9), rgba(42, 36, 56, 0.9));
}

.what-is-content,
.how-to-content,
.why-content {
    max-width: 1200px;
    margin: 0 auto;
    color: var(--text-color);
}

.section-title {
    font-family: var(--retro-font);
    font-size: 2.5rem;
    margin-bottom: 2rem;
    text-align: center;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* What Is Section Styles */
.what-is-content p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.game-mechanics {
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.game-mechanics h3 {
    font-family: var(--retro-font);
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.game-mechanics ul {
    list-style: none;
    padding: 0;
}

.game-mechanics li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 1rem;
}

.game-mechanics li::before {
    content: "▶";
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

/* How To Section Styles */
.how-to-content {
    display: grid;
    gap: 2rem;
}

.controls-guide,
.gameplay-mechanics,
.advanced-strategies,
.progression-tips {
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.how-to-content h3 {
    font-family: var(--retro-font);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.how-to-content p {
    font-size: 1.1rem;
    line-height: 1.8;
}

/* Why Section Styles */
.why-content {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.unique-features,
.educational-value,
.social-aspects,
.accessibility {
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.why-content h3 {
    font-family: var(--retro-font);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.why-content p {
    font-size: 1.1rem;
    line-height: 1.8;
}

/* Responsive Design */
@media (max-width: 968px) {
    .section-title {
        font-size: 2rem;
    }

    .why-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .section-title {
        font-size: 1.8rem;
    }

    .game-mechanics,
    .controls-guide,
    .gameplay-mechanics,
    .advanced-strategies,
    .progression-tips,
    .unique-features,
    .educational-value,
    .social-aspects,
    .accessibility {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .section-title {
        font-size: 1.5rem;
    }

    .what-is-content p,
    .how-to-content p,
    .why-content p {
        font-size: 1rem;
        line-height: 1.6;
    }
}

/* FAQ Section Styles */
.faq-section {
    padding: 4rem 1rem;
    background: linear-gradient(to bottom, rgba(26, 22, 37, 0.9), rgba(42, 36, 56, 0.9));
}

.faq-list {
    max-width: 1200px;
    margin: 0 auto;
}

.faq-item {
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.faq-item h3 {
    font-family: var(--retro-font);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.faq-answer {
    color: var(--text-color);
}

.faq-answer p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1rem;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .faq-item {
        padding: 1.5rem;
    }

    .faq-item h3 {
        font-size: 1.1rem;
    }

    .faq-answer p {
        font-size: 1rem;
        line-height: 1.6;
    }
}

/* Game Info Section Styles */
.game-info {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 0 1rem;
}

.game-info h2 {
    font-family: var(--retro-font);
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    text-align: center;
}

.game-description {
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.game-description p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.how-to-play {
    background: rgba(26, 22, 37, 0.6);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.how-to-play h3 {
    font-family: var(--retro-font);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .game-info h2 {
        font-size: 1.8rem;
    }

    .game-description,
    .how-to-play {
        padding: 1.5rem;
    }

    .game-description p {
        font-size: 1rem;
        line-height: 1.6;
    }

    .how-to-play h3 {
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .game-info h2 {
        font-size: 1.5rem;
    }

    .game-description,
    .how-to-play {
        padding: 1rem;
    }
}

/* Footer Styles */
.site-footer {
    background: linear-gradient(to bottom, #1a1625, #0f0d16);
    padding: 3rem 1rem;
    border-top: 3px solid var(--primary-color);
    margin-top: 4rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    color: var(--text-color);
}

.footer-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-section h3 {
    font-family: var(--retro-font);
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.footer-social a {
    color: var(--text-color);
    font-size: 1.5rem;
    transition: color 0.3s ease;
}

.footer-social a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    grid-column: 1 / -1;
}

.footer-bottom p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Responsive Design */
@media (max-width: 968px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .site-footer {
        padding: 2rem 1rem;
    }

    .footer-bottom {
        margin-top: 1.5rem;
        padding-top: 1.5rem;
    }
}

/* 响应式调整 */
@media (max-width: 968px) {
    .game-main {
        width: 100%;
    }
    
    .fullscreen-btn {
        bottom: 10px;
        right: 10px;
        width: 36px;
        height: 36px;
    }
}

@media (max-width: 1200px) {
    .game-bottom-nav {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
}
