/* style/blog.css */
/* body 已 padding-top: var(--header-offset)；页面禁止再写该变量 */
.page-blog {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #F2FFF6; /* Text Main */
    background-color: #08160F; /* Background */
}

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

.page-blog__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-bottom: 60px; /* Space below content */
    padding-top: 10px; /* Small top padding, body handles header offset */
    overflow: hidden; /* Ensure content doesn't overflow */
}

.page-blog__hero-image-wrapper {
    width: 100%;
    max-height: 700px; /* Limit hero image height */
    overflow: hidden;
    margin-bottom: 40px; /* Space between image and content */
}

.page-blog__hero-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    filter: brightness(0.7); /* Slightly darken image for text readability */
}

.page-blog__hero-content {
    max-width: 900px;
    padding: 0 20px;
    z-index: 1; /* Ensure content is above image if any overlap */
    position: relative; /* For z-index to work */
}

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

.page-blog__hero-description {
    font-size: 1.25rem;
    color: #A7D9B8; /* Text Secondary */
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.page-blog__cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
}

.page-blog__btn-primary,
.page-blog__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s ease;
    box-sizing: border-box;
    max-width: 100%; /* Ensure button doesn't overflow */
    white-space: normal; /* Allow text to wrap */
    word-wrap: break-word; /* Allow text to break words */
    text-align: center;
}

.page-blog__btn-primary {
    background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%); /* Button */
    color: #F2FFF6; /* Text Main */
    border: 2px solid transparent;
}

.page-blog__btn-primary:hover {
    background: linear-gradient(180deg, #13994A 0%, #2AD16F 100%);
    box-shadow: 0 0 15px rgba(87, 227, 141, 0.6); /* Glow */
}

.page-blog__btn-secondary {
    background: transparent;
    color: #2AD16F; /* Green from button gradient */
    border: 2px solid #2AD16F; /* Border */
}

.page-blog__btn-secondary:hover {
    background: #2AD16F;
    color: #F2FFF6;
    box-shadow: 0 0 15px rgba(87, 227, 141, 0.6); /* Glow */
}

.page-blog__section-title {
    font-size: 2.5rem;
    color: #F2FFF6; /* Text Main */
    text-align: center;
    margin-bottom: 20px;
    font-weight: 700;
}

.page-blog__section-description {
    font-size: 1.1rem;
    color: #A7D9B8; /* Text Secondary */
    text-align: center;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Latest Blog Posts Section */
.page-blog__latest-posts-section {
    padding: 80px 0;
    background-color: #0A4B2C; /* Deep Green */
}

.page-blog__blog-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.page-blog__blog-card {
    background-color: #11271B; /* Card BG */
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #2E7A4E; /* Border */
}

.page-blog__blog-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.page-blog__blog-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.page-blog__blog-card-image {
    width: 100%;
    height: 225px; /* Fixed height for consistency */
    object-fit: cover;
    display: block;
}

.page-blog__blog-card-content {
    padding: 25px;
}

.page-blog__blog-card-title {
    font-size: 1.4rem;
    color: #F2FFF6; /* Text Main */
    margin-bottom: 10px;
    line-height: 1.3;
}

.page-blog__blog-card-excerpt {
    font-size: 0.95rem;
    color: #A7D9B8; /* Text Secondary */
    margin-bottom: 15px;
}

.page-blog__blog-card-date {
    font-size: 0.85rem;
    color: #2AD16F; /* Green from button gradient */
    display: block;
}

.page-blog__view-all-button-wrapper {
    text-align: center;
}

/* Categories Section */
.page-blog__categories-section {
    padding: 80px 0;
    background-color: #08160F; /* Background */
}

.page-blog__categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
}

.page-blog__category-card {
    background-color: #11271B; /* Card BG */
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    text-decoration: none;
    color: #F2FFF6; /* Text Main */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #2E7A4E; /* Border */
}

.page-blog__category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.25);
}

.page-blog__category-title {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #F2FFF6;
}

.page-blog__category-description {
    font-size: 0.95rem;
    color: #A7D9B8; /* Text Secondary */
}

/* FAQ Section */
.page-blog__faq-section {
    padding: 80px 0;
    background-color: #0A4B2C; /* Deep Green */
}

.page-blog__faq-list {
    max-width: 900px;
    margin: 0 auto;
}

.page-blog__faq-item {
    background-color: #11271B; /* Card BG */
    border: 1px solid #2E7A4E; /* Border */
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    color: #F2FFF6;
}

.page-blog__faq-item summary {
    list-style: none; /* Hide default marker */
}
.page-blog__faq-item summary::-webkit-details-marker {
    display: none; /* Hide default marker for webkit browsers */
}

.page-blog__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    color: #F2FFF6; /* Text Main */
    transition: background-color 0.3s ease;
}

.page-blog__faq-question:hover {
    background-color: rgba(46, 122, 78, 0.3); /* Border with opacity */
}

.page-blog__faq-toggle {
    font-size: 1.5rem;
    line-height: 1;
    margin-left: 15px;
    color: #2AD16F; /* Green from button gradient */
}

.page-blog__faq-answer {
    padding: 0 25px 20px;
    font-size: 1rem;
    color: #A7D9B8; /* Text Secondary */
}

/* CTA Bottom Section */
.page-blog__cta-bottom-section {
    padding: 80px 0;
    background-color: #08160F; /* Background */
    text-align: center;
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .page-blog__main-title {
        font-size: clamp(2rem, 4.5vw, 3rem);
    }
    .page-blog__section-title {
        font-size: 2rem;
    }
    .page-blog__blog-card-title {
        font-size: 1.2rem;
    }
    .page-blog__category-title {
        font-size: 1.3rem;
    }
}

@media (max-width: 768px) {
    .page-blog {
        font-size: 16px;
        line-height: 1.6;
    }

    .page-blog__container {
        padding: 0 15px;
    }

    .page-blog__hero-section {
        padding-bottom: 40px;
        padding-top: 10px !important; /* Ensure small top padding */
    }

    .page-blog__hero-image-wrapper {
        margin-bottom: 20px;
    }

    .page-blog__main-title {
        font-size: clamp(1.8rem, 7vw, 2.5rem);
    }

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

    .page-blog__cta-buttons {
        flex-direction: column;
        gap: 15px;
    }

    .page-blog__btn-primary,
    .page-blog__btn-secondary {
        max-width: 100% !important;
        width: 100% !important;
        padding: 12px 20px;
        font-size: 1rem;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

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

    .page-blog__section-description {
        font-size: 1rem;
        margin-bottom: 30px;
    }

    .page-blog__latest-posts-section,
    .page-blog__categories-section,
    .page-blog__faq-section,
    .page-blog__cta-bottom-section {
        padding: 60px 0;
    }

    .page-blog__blog-list {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-blog__blog-card-image {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
        min-height: 200px; /* Ensure minimum size */
    }
    
    .page-blog__blog-card {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .page-blog__categories-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-blog__category-card {
        padding: 25px;
    }

    .page-blog__faq-question {
        font-size: 1rem;
        padding: 15px 20px;
    }

    .page-blog__faq-answer {
        padding: 0 20px 15px;
    }

    /* General image responsiveness */
    .page-blog img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
        min-width: 200px; /* Ensure minimum width */
        min-height: 200px; /* Ensure minimum height */
    }

    /* All containers that might hold images/buttons/videos */
    .page-blog__hero-section,
    .page-blog__latest-posts-section,
    .page-blog__categories-section,
    .page-blog__faq-section,
    .page-blog__cta-bottom-section,
    .page-blog__container,
    .page-blog__blog-list,
    .page-blog__categories-grid,
    .page-blog__faq-list,
    .page-blog__cta-buttons,
    .page-blog__hero-image-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow: hidden !important; /* Prevent horizontal scroll */
    }
}