/* style/blog.css */

/* Root variables for colors */
:root {
    --k9bet-green-dark: #11A84E;
    --k9bet-green-light: #22C768;
    --k9bet-button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
    --k9bet-card-bg: #11271B;
    --k9bet-background: #08160F;
    --k9bet-text-main: #F2FFF6;
    --k9bet-text-secondary: #A7D9B8;
    --k9bet-border: #2E7A4E;
    --k9bet-glow: #57E38D;
    --k9bet-gold: #F2C14E;
    --k9bet-divider: #1E3A2A;
    --k9bet-deep-green: #0A4B2C;
}

/* Base styles for the blog page, respecting shared.css body padding */
.page-blog {
    font-family: 'Arial', sans-serif;
    color: var(--k9bet-text-main); /* Ensure light text on dark background from body */
    background-color: var(--k9bet-background);
}

/* General container for content sections */
.page-blog__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}

/* Section titles */
.page-blog__section-title {
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 700;
    color: var(--k9bet-gold);
    text-align: center;
    margin-bottom: 40px;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

/* Hero Section */
.page-blog__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 0 60px 0; /* Small top padding, body handles header offset */
    background-color: var(--k9bet-deep-green);
    overflow: hidden;
}

.page-blog__hero-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    max-height: 500px;
    filter: brightness(0.7); /* Slightly dim the image for text contrast */
    margin-bottom: 30px;
}

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

.page-blog__hero-title {
    font-size: clamp(36px, 5vw, 56px);
    font-weight: 800;
    color: var(--k9bet-gold);
    margin-bottom: 20px;
    line-height: 1.2;
    letter-spacing: -1px;
}

.page-blog__hero-description {
    font-size: 18px;
    line-height: 1.6;
    color: var(--k9bet-text-secondary);
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Buttons */
.page-blog__btn-primary,
.page-blog__btn-secondary {
    display: inline-block;
    padding: 14px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 18px;
    transition: all 0.3s ease;
    text-align: center;
    cursor: pointer;
    border: none;
    box-sizing: border-box;
}

.page-blog__btn-primary {
    background: var(--k9bet-button-gradient);
    color: #ffffff; /* White text for primary button */
    box-shadow: 0 4px 15px rgba(0, 200, 100, 0.3);
}

.page-blog__btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 200, 100, 0.4);
}

.page-blog__btn-secondary {
    background-color: transparent;
    color: var(--k9bet-gold);
    border: 2px solid var(--k9bet-gold);
    box-shadow: 0 2px 8px rgba(242, 193, 78, 0.2);
}

.page-blog__btn-secondary:hover {
    background-color: rgba(242, 193, 78, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(242, 193, 78, 0.3);
}

/* Articles Section */
.page-blog__articles-section {
    padding: 60px 0;
    background-color: var(--k9bet-background);
}

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

.page-blog__article-card {
    background-color: var(--k9bet-card-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--k9bet-border);
}

.page-blog__article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
}

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

.page-blog__card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.page-blog__card-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 10px;
    line-height: 1.4;
}

.page-blog__card-title a {
    color: var(--k9bet-text-main);
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-blog__card-title a:hover {
    color: var(--k9bet-gold);
}

.page-blog__card-meta {
    font-size: 14px;
    color: var(--k9bet-text-secondary);
    margin-bottom: 15px;
}

.page-blog__card-description {
    font-size: 16px;
    line-height: 1.6;
    color: var(--k9bet-text-secondary);
    margin-bottom: 20px;
    flex-grow: 1;
}

.page-blog__card-link {
    display: inline-block;
    color: var(--k9bet-green-light);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: color 0.3s ease;
}

.page-blog__card-link:hover {
    color: var(--k9bet-gold);
    text-decoration: underline;
}

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

/* Categories Section */
.page-blog__categories-section {
    padding: 60px 0;
    background-color: var(--k9bet-deep-green);
}

.page-blog__category-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.page-blog__category-item a {
    display: block;
    padding: 10px 25px;
    background-color: var(--k9bet-card-bg);
    color: var(--k9bet-text-main);
    text-decoration: none;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 500;
    transition: background-color 0.3s ease, color 0.3s ease;
    border: 1px solid var(--k9bet-border);
}

.page-blog__category-item a:hover {
    background-color: var(--k9bet-green-light);
    color: var(--k9bet-background);
}

/* CTA Section */
.page-blog__cta-section {
    padding: 80px 0;
    background-color: var(--k9bet-background);
    text-align: center;
}

.page-blog__cta-section .page-blog__container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.page-blog__cta-image {
    width: 100%;
    max-width: 800px;
    height: auto;
    display: block;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    margin-bottom: 20px;
}

.page-blog__cta-content {
    max-width: 800px;
}

.page-blog__cta-description {
    font-size: 18px;
    line-height: 1.7;
    color: var(--k9bet-text-secondary);
    margin-bottom: 30px;
}

/* FAQ Section */
.page-blog__faq-section {
    padding: 60px 0 80px 0;
    background-color: var(--k9bet-deep-green);
}

.page-blog__faq-list {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.page-blog__faq-item {
    background-color: var(--k9bet-card-bg);
    border-radius: 10px;
    border: 1px solid var(--k9bet-border);
    overflow: hidden;
    transition: background-color 0.3s ease;
}

.page-blog__faq-item[open] {
    background-color: var(--k9bet-deep-green);
}

.page-blog__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    font-size: 18px;
    font-weight: 600;
    color: var(--k9bet-text-main);
    cursor: pointer;
    user-select: none;
    transition: color 0.3s ease;
    list-style: none; /* Hide default marker for details/summary */
}

.page-blog__faq-question::-webkit-details-marker {
    display: none;
}

.page-blog__faq-item[open] .page-blog__faq-question {
    color: var(--k9bet-gold);
}

.page-blog__faq-toggle {
    font-size: 24px;
    line-height: 1;
    transition: transform 0.3s ease;
}

.page-blog__faq-item[open] .page-blog__faq-toggle {
    transform: rotate(45deg); /* Change + to X or similar */
}

.page-blog__faq-answer {
    padding: 0 25px 20px 25px;
    font-size: 16px;
    line-height: 1.7;
    color: var(--k9bet-text-secondary);
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .page-blog__hero-title {
        font-size: clamp(32px, 4.5vw, 50px);
    }
    .page-blog__hero-description {
        font-size: 17px;
    }
    .page-blog__article-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
    .page-blog__category-item a {
        padding: 8px 20px;
        font-size: 15px;
    }
    .page-blog__cta-image {
        max-width: 600px;
    }
}

@media (max-width: 768px) {
    .page-blog {
        font-size: 16px;
        line-height: 1.6;
    }
    .page-blog__container {
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-blog__section-title {
        font-size: clamp(24px, 6vw, 36px);
        margin-bottom: 30px;
    }
    .page-blog__hero-section {
        padding-bottom: 40px;
    }
    .page-blog__hero-image {
        max-height: 300px;
        margin-bottom: 20px;
    }
    .page-blog__hero-title {
        font-size: clamp(28px, 7vw, 42px);
        margin-bottom: 15px;
    }
    .page-blog__hero-description {
        font-size: 16px;
        margin-bottom: 25px;
    }
    .page-blog__btn-primary,
    .page-blog__btn-secondary {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding: 12px 20px;
        font-size: 16px;
    }
    .page-blog__articles-section,
    .page-blog__categories-section,
    .page-blog__cta-section,
    .page-blog__faq-section {
        padding: 40px 0;
    }
    .page-blog__article-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .page-blog__article-image {
        height: 180px;
    }
    .page-blog__card-title {
        font-size: 20px;
    }
    .page-blog__card-description {
        font-size: 15px;
    }
    .page-blog__category-list {
        gap: 10px;
    }
    .page-blog__category-item a {
        padding: 8px 15px;
        font-size: 14px;
    }
    .page-blog__cta-image {
        max-width: 100%;
        width: 100%;
        height: auto;
        margin-bottom: 15px;
    }
    .page-blog__cta-description {
        font-size: 16px;
    }
    .page-blog__faq-question {
        padding: 15px 20px;
        font-size: 16px;
    }
    .page-blog__faq-answer {
        padding: 0 20px 15px 20px;
        font-size: 15px;
    }
    /* Mobile image and video responsiveness */
    .page-blog img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-blog__section,
    .page-blog__card,
    .page-blog__container,
    .page-blog__cta-section .page-blog__container,
    .page-blog__articles-section .page-blog__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-blog video,
    .page-blog__video {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .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;
    }
    .page-blog__video-section {
        padding-top: 10px !important;
    }
    .page-blog__video-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    .page-blog__cta-buttons,
    .page-blog__button-group,
    .page-blog__btn-container {
        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__cta-buttons {
        display: flex;
        flex-direction: column; 
    }
}

@media (max-width: 480px) {
    .page-blog__hero-title {
        font-size: clamp(24px, 8vw, 38px);
    }
    .page-blog__hero-description {
        font-size: 15px;
    }
    .page-blog__section-title {
        font-size: clamp(20px, 7vw, 32px);
    }
    .page-blog__card-title {
        font-size: 18px;
    }
    .page-blog__card-description {
        font-size: 14px;
    }
    .page-blog__faq-question {
        font-size: 15px;
    }
    .page-blog__faq-answer {
        font-size: 14px;
    }
}