:root {
    --primary-color: #11A84E;
    --secondary-color: #22C768;
    --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
    --card-b-g: #11271B;
    --background: #08160F;
    --text-main: #F2FFF6;
    --text-secondary: #A7D9B8;
    --border: #2E7A4E;
    --glow: #57E38D;
    --gold: #F2C14E;
    --divider: #1E3A2A;
    --deep-green: #0A4B2C;
}

/* --- General Styles --- */
.page-blog {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: var(--text-secondary); /* Default text color based on body background */
    background-color: var(--background); /* Use the custom background color */
}

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

.page-blog__section-title {
    font-size: 2.5em;
    color: var(--text-main);
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.page-blog__sub-title {
    font-size: 1.8em;
    color: var(--text-main);
    margin-top: 30px;
    margin-bottom: 15px;
    font-weight: 600;
}

.page-blog__section-intro {
    font-size: 1.1em;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.page-blog p {
    color: var(--text-secondary);
    margin-bottom: 15px;
}

/* --- Buttons --- */
.page-blog__cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
}

.page-blog__btn-primary,
.page-blog__btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1.1em;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    white-space: nowrap;
    word-wrap: break-word; /* Allow text wrapping */
    box-sizing: border-box;
    max-width: 100%; /* Ensure buttons don't overflow */
}

.page-blog__btn-primary {
    background: var(--button-gradient);
    color: #F2FFF6;
    border: 2px solid transparent;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-blog__btn-primary:hover {
    background: linear-gradient(180deg, #13994A 0%, #2AD16F 100%);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-blog__btn-secondary {
    background: transparent;
    color: #F2FFF6; /* text-main for secondary buttons */
    border: 2px solid var(--border);
}

.page-blog__btn-secondary:hover {
    background: var(--deep-green); /* A subtle background on hover */
    color: #F2FFF6;
    border-color: var(--glow);
}

/* --- Hero Section --- */
.page-blog__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 10px; /* Small top padding, body handles header offset */
    padding-bottom: 60px;
    overflow: hidden;
    box-sizing: border-box;
}

.page-blog__hero-image-wrapper {
    width: 100%;
    max-height: 500px; /* Limit height for hero image */
    overflow: hidden;
    margin-bottom: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.page-blog__hero-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    border-radius: 10px;
}

.page-blog__hero-content {
    max-width: 900px;
    text-align: center;
    padding: 0 20px;
    box-sizing: border-box;
}

.page-blog__main-title {
    color: var(--text-main);
    font-size: clamp(2em, 4vw, 3.2em); /* Responsive font size for H1 */
    margin-bottom: 20px;
    font-weight: bold;
    line-height: 1.2;
    letter-spacing: -0.03em;
}

.page-blog__description {
    font-size: 1.2em;
    color: var(--text-secondary);
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* --- Card Grid Layout --- */
.page-blog__card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.page-blog__blog-card,
.page-blog__guide-card {
    background-color: var(--card-b-g);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.page-blog__blog-card:hover,
.page-blog__guide-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
}

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

.page-blog__blog-card-content,
.page-blog__guide-card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.page-blog__blog-card-title,
.page-blog__guide-card-title {
    font-size: 1.5em;
    font-weight: bold;
    margin-bottom: 10px;
    line-height: 1.3;
}

.page-blog__blog-card-title a,
.page-blog__guide-card-title a {
    color: var(--text-main);
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-blog__blog-card-title a:hover,
.page-blog__guide-card-title a:hover {
    color: var(--glow);
}

.page-blog__blog-card-meta {
    font-size: 0.9em;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.page-blog__blog-card-excerpt,
.page-blog__guide-card-excerpt {
    font-size: 1em;
    color: var(--text-secondary);
    margin-bottom: 20px;
    flex-grow: 1; /* Allow excerpt to take available space */
}

.page-blog__read-more-link {
    color: var(--glow);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
    align-self: flex-start; /* Align to the start of the flex container */
}

.page-blog__read-more-link:hover {
    color: #F2C14E; /* Gold on hover */
}

.page-blog__view-all-button-container {
    text-align: center;
    margin-top: 50px;
}

/* --- Market Analysis Section --- */
.page-blog__market-analysis .page-blog__content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    align-items: start;
    margin-top: 40px;
}

.page-blog__image-block {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.page-blog__image-responsive {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    min-width: 200px;
    min-height: 200px;
}

.page-blog__cta-box {
    background-color: var(--deep-green);
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.page-blog__cta-title {
    font-size: 1.8em;
    color: var(--gold);
    margin-bottom: 15px;
    font-weight: bold;
}

.page-blog__cta-text {
    color: #F2FFF6;
    font-size: 1.1em;
    margin-bottom: 25px;
}

/* --- FAQ Section --- */
.page-blog__faq-list {
    margin-top: 40px;
}

.page-blog__faq-item {
    background-color: var(--card-b-g);
    border-radius: 12px;
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.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 */
}

.page-blog__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    font-size: 1.2em;
    font-weight: bold;
    color: var(--text-main);
    cursor: pointer;
    background-color: var(--deep-green); /* Darker background for question */
    border-bottom: 1px solid var(--divider);
    transition: background-color 0.3s ease;
}

.page-blog__faq-question:hover {
    background-color: var(--primary-color);
}

.page-blog__faq-qtext {
    flex-grow: 1;
}

.page-blog__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    margin-left: 15px;
    color: var(--glow);
}

.page-blog__faq-item[open] .page-blog__faq-question {
    border-bottom: 1px solid var(--glow);
}

.page-blog__faq-answer {
    padding: 20px 25px;
    font-size: 1em;
    color: var(--text-secondary);
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .page-blog__market-analysis .page-blog__content-grid {
        grid-template-columns: 1fr;
    }
}

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

    .page-blog__section {
        padding: 40px 15px;
    }

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

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

    .page-blog__hero-section {
        padding-bottom: 40px;
    }

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

    .page-blog__description {
        font-size: 1em;
    }

    .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: 1em;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    .page-blog__blog-card-image,
    .page-blog__guide-card-image {
        height: 180px; /* Adjust card image height for mobile */
    }

    .page-blog__blog-card-title,
    .page-blog__guide-card-title {
        font-size: 1.3em;
    }

    .page-blog__market-analysis .page-blog__content-grid {
        gap: 30px;
    }

    .page-blog__image-responsive {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }

    /* Mobile image and video responsiveness */
    .page-blog img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    
    .page-blog video,
    .page-blog__video { /* If video elements are used */
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }

    .page-blog__section,
    .page-blog__card,
    .page-blog__container,
    .page-blog__hero-section,
    .page-blog__cta-buttons,
    .page-blog__button-group,
    .page-blog__btn-container,
    .page-blog__video-section,
    .page-blog__video-container,
    .page-blog__video-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow: hidden !important; /* Prevent horizontal scroll */
    }

    .page-blog__video-section {
        padding-top: 10px !important; /* body already handles --header-offset */
    }

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

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

/* Ensure text contrast for main content */
.page-blog p,
.page-blog li,
.page-blog__blog-card-excerpt,
.page-blog__guide-card-excerpt,
.page-blog__cta-text,
.page-blog__faq-answer {
    color: var(--text-secondary); /* Use secondary text color for paragraphs and excerpts */
}

.page-blog h1, .page-blog h2, .page-blog h3, .page-blog h4, .page-blog h5, .page-blog h6,
.page-blog__blog-card-title a,
.page-blog__guide-card-title a,
.page-blog__faq-question {
    color: var(--text-main); /* Use main text color for headings and titles */
}

.page-blog__btn-primary {
    color: #F2FFF6; /* Ensure white text on primary button */
}
.page-blog__btn-secondary {
    color: #F2FFF6; /* Ensure white text on secondary button */
}