/* Base styles for the blog page */
.page-blog {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333333; /* Text Main */
    background: #F5F7FA; /* Background */
}

/* Hero Section */
.page-blog__hero-section {
    position: relative;
    padding-top: 10px; /* Small top padding, relying on body for header offset */
    margin-bottom: 40px;
    background: #E53935; /* Main color as background for hero section */
    color: #ffffff; /* White text for contrast */
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    overflow: hidden; /* Ensure content doesn't spill */
}

.page-blog__hero-image {
    width: 100%;
    max-height: 500px; /* Limit height for desktop */
    overflow: hidden;
    margin-bottom: 20px; /* Space between image and content */
}

.page-blog__hero-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover; /* Cover for desktop to fill space */
    object-position: center;
    min-width: 200px;
    min-height: 200px;
}

.page-blog__hero-content {
    max-width: 900px;
    padding: 20px;
    box-sizing: border-box;
    margin-bottom: 40px;
}

.page-blog__main-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem); /* Responsive font size */
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 15px;
    color: #ffffff;
}

.page-blog__hero-description {
    font-size: 1.2rem;
    margin-bottom: 30px;
    color: #ffffff;
}

.page-blog__hero-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

/* General Section Styling */
.page-blog__section {
    padding: 40px 0;
    margin-bottom: 30px;
    background: #FFFFFF; /* Card BG */
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.page-blog__section:last-of-type {
    margin-bottom: 0;
}

.page-blog__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

.page-blog__section-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: #E53935; /* Main color for titles */
    text-align: center;
    margin-bottom: 30px;
    line-height: 1.3;
}

.page-blog__sub-title {
    font-size: 1.6rem;
    font-weight: 600;
    color: #E53935; /* Main color for sub-titles */
    margin-top: 30px;
    margin-bottom: 15px;
    line-height: 1.4;
}

.page-blog__content-area {
    font-size: 1.1rem;
    line-height: 1.7;
    color: #333333;
    max-width: 900px; /* Constrain content width for readability */
    margin: 0 auto;
}

.page-blog__content-area p {
    margin-bottom: 15px;
}

.page-blog__list {
    list-style: disc;
    margin-left: 25px;
    margin-bottom: 15px;
}

.page-blog__list li {
    margin-bottom: 8px;
}

.page-blog__list-ordered {
    list-style: decimal;
    margin-left: 25px;
    margin-bottom: 15px;
}

.page-blog__list-ordered li {
    margin-bottom: 8px;
}

.page-blog__article-image {
    width: 100%;
    height: auto;
    display: block;
    margin: 25px auto;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    min-width: 200px; /* Minimum size requirement */
    min-height: 200px; /* Minimum size requirement */
}

/* Ensure all images are responsive by default */
.page-blog img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Buttons */
.page-blog__btn-primary,
.page-blog__btn-secondary,
.page-blog__btn-tertiary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
    box-sizing: border-box;
    white-space: normal; /* Allow text wrapping */
    word-wrap: break-word; /* Allow text wrapping */
    max-width: 100%; /* Ensure buttons don't overflow */
}

.page-blog__btn-primary {
    background: linear-gradient(180deg, #FF5A4F 0%, #E53935 100%);
    color: #ffffff;
    border: none;
}

.page-blog__btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.page-blog__btn-secondary {
    background: #ffffff;
    color: #E53935;
    border: 2px solid #E53935;
}

.page-blog__btn-secondary:hover {
    background: #E53935;
    color: #ffffff;
}

.page-blog__btn-tertiary {
    background: transparent;
    color: #E53935;
    border: 1px solid #FF5A4F;
    padding: 10px 20px;
    font-weight: 600;
    border-radius: 5px;
    margin-top: 15px;
}

.page-blog__btn-tertiary:hover {
    background: #FF5A4F;
    color: #ffffff;
}

.page-blog__games-links {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 20px;
    margin-bottom: 20px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

/* Dark Section Specifics */
.page-blog__dark-section {
    background: #E53935; /* Main color as background */
    color: #ffffff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.page-blog__dark-section .page-blog__section-title,
.page-blog__dark-section .page-blog__sub-title {
    color: #ffffff;
}

.page-blog__dark-section .page-blog__content-area {
    color: #f0f0f0;
}

.page-blog__dark-section .page-blog__btn-tertiary {
    color: #ffffff;
    border-color: #FF5A4F;
}

.page-blog__dark-section .page-blog__btn-tertiary:hover {
    background: #FF5A4F;
    color: #ffffff;
}

/* FAQ Section */
details.page-blog__faq-item {
  margin-bottom: 15px;
  border-radius: 8px; /* Slightly larger radius */
  border: 1px solid #E0E0E0; /* Border color */
  overflow: hidden;
  background: #ffffff; /* Card BG */
}
details.page-blog__faq-item summary.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease;
  color: #333333; /* Text Main */
  font-weight: 600;
}
details.page-blog__faq-item summary.page-blog__faq-question::-webkit-details-marker {
  display: none;
}
details.page-blog__faq-item summary.page-blog__faq-question:hover {
  background: #f5f5f5;
}
.page-blog__faq-qtext {
  flex: 1;
  font-size: 1.1rem; /* Slightly larger font */
  line-height: 1.5;
  text-align: left;
}
.page-blog__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: #E53935; /* Main color for toggle */
  flex-shrink: 0;
  margin-left: 15px;
  width: 28px;
  text-align: center;
}
details.page-blog__faq-item .page-blog__faq-answer {
  padding: 0 20px 20px;
  background: #f9f9f9; /* Lighter background for answer */
  border-radius: 0 0 8px 8px;
  color: #333333;
}
.page-blog__faq-answer p {
    margin-bottom: 0; /* Remove extra margin from last p in answer */
}


/* CTA Section */
.page-blog__cta-section {
    padding: 60px 0;
    text-align: center;
}

.page-blog__cta-section .page-blog__section-title {
    margin-bottom: 20px;
}

.page-blog__cta-section .page-blog__content-area {
    margin-bottom: 40px;
}

.page-blog__cta-section .page-blog__cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%; /* Ensure container fills width */
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

/* Responsive Styles */

/* General for tablets and smaller desktops */
@media (max-width: 1024px) {
    .page-blog__container {
        padding: 0 15px;
    }

    .page-blog__hero-content {
        padding: 15px;
    }

    .page-blog__main-title {
        font-size: clamp(2rem, 4.5vw, 3rem);
    }

    .page-blog__hero-description {
        font-size: 1.1rem;
    }

    .page-blog__section-title {
        font-size: 2rem;
    }

    .page-blog__sub-title {
        font-size: 1.5rem;
    }

    .page-blog__content-area {
        font-size: 1rem;
    }

    .page-blog__btn-primary,
    .page-blog__btn-secondary,
    .page-blog__btn-tertiary {
        padding: 12px 24px;
        font-size: 0.95rem;
    }
}

/* Specific breakpoint for hero image object-fit */
@media (max-width: 849px) {
    .page-blog__hero-image img {
        object-fit: contain !important; /* Force contain to prevent cropping */
        aspect-ratio: unset !important; /* Remove fixed aspect ratio */
        height: auto !important; /* Adjust height automatically */
    }
}

@media (max-width: 768px) {
    /* HERO 主图区域 */
    .page-blog__hero-section {
        padding-top: 10px; /* Small top padding, relying on body for header offset */
        margin-bottom: 30px;
    }

    .page-blog__hero-image {
        max-height: 300px; /* Adjust max height for mobile */
        margin-bottom: 15px;
    }

    .page-blog__hero-content {
        padding: 15px;
        margin-bottom: 30px;
    }

    .page-blog__main-title {
        font-size: clamp(1.8rem, 8vw, 2.5rem); /* More aggressive clamp for mobile */
        margin-bottom: 10px;
    }

    .page-blog__hero-description {
        font-size: 1rem;
        margin-bottom: 20px;
    }

    .page-blog__hero-actions {
        flex-direction: column; /* Stack buttons vertically */
        gap: 10px;
        width: 100%;
        max-width: 300px; /* Limit button group width */
        margin: 0 auto;
    }

    /* 按钮与按钮容器 */
    .page-blog__btn-primary,
    .page-blog__btn-secondary,
    .page-blog__btn-tertiary,
    .page-blog a[class*="button"],
    .page-blog a[class*="btn"] {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding-left: 15px;
        padding-right: 15px;
        font-size: 1rem;
    }

    .page-blog__hero-actions,
    .page-blog__games-links,
    .page-blog__cta-section .page-blog__cta-buttons {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        flex-wrap: wrap !important;
        gap: 10px;
    }

    .page-blog__section {
        padding: 30px 0;
        margin-bottom: 20px;
        border-radius: 0; /* Remove border-radius on full-width sections */
        box-shadow: none; /* Remove box-shadow for cleaner look */
    }

    /* 通用图片与容器 */
    .page-blog__container,
    .page-blog__section,
    .page-blog__card,
    .page-blog__content-area {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .page-blog img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block;
    }

    .page-blog__section-title {
        font-size: 1.8rem;
        margin-bottom: 20px;
    }

    .page-blog__sub-title {
        font-size: 1.3rem;
        margin-top: 25px;
        margin-bottom: 10px;
    }

    .page-blog__content-area {
        font-size: 1rem;
        padding: 0; /* Remove any content area padding that might cause overflow */
    }

    .page-blog__content-area p {
        margin-bottom: 10px;
    }

    .page-blog__list,
    .page-blog__list-ordered {
        margin-left: 20px;
        margin-bottom: 10px;
    }

    .page-blog__article-image {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        margin: 20px auto;
        border-radius: 5px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    
    .page-blog__games-links {
        flex-direction: column; /* Stack game links vertically */
        gap: 10px;
        margin: 20px auto;
    }

    details.page-blog__faq-item {
        margin-bottom: 10px;
        border-radius: 5px;
    }
    details.page-blog__faq-item summary.page-blog__faq-question {
        padding: 15px;
        font-size: 1rem;
    }
    .page-blog__faq-qtext {
        font-size: 1rem;
    }
    .page-blog__faq-toggle {
        font-size: 20px;
        width: 24px;
    }
    details.page-blog__faq-item .page-blog__faq-answer {
        padding: 0 15px 15px;
    }

    .page-blog__cta-section {
        padding: 40px 0;
    }

    .page-blog__cta-section .page-blog__cta-buttons {
        flex-direction: column;
        gap: 10px;
        margin: 0 auto;
    }
}