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

.page-game-rules {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: var(--text-main); /* Light text for dark background */
    background-color: var(--background); /* Overall page background */
}

/* Hero Section */
.page-game-rules__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    padding-top: 10px; /* Small top padding, body handles header offset */
    background-color: var(--deep-green); /* Use a darker brand color for hero background */
    overflow: hidden; /* Ensure image doesn't overflow */
}

.page-game-rules__hero-image-wrapper {
    width: 100%;
    max-width: 100%;
    margin-bottom: 30px;
    overflow: hidden;
}

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

.page-game-rules__hero-content {
    max-width: 900px;
    z-index: 1;
    color: var(--text-main);
}

.page-game-rules__main-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem); /* Using clamp for H1 font size */
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--gold-color);
    line-height: 1.2;
}

.page-game-rules__description {
    font-size: 1.2rem;
    margin-bottom: 30px;
    color: var(--text-secondary);
}

/* Section Common Styles */
.page-game-rules__section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 40px;
    color: var(--gold-color);
}

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

.page-game-rules__text-block {
    font-size: 1.1rem;
    margin-bottom: 20px;
    color: var(--text-main);
}

/* Light Background Sections */
.page-game-rules__light-bg {
    background-color: var(--background); /* Use overall background, text will be light */
    color: var(--text-main);
    padding: 60px 0;
}

/* Dark Background Sections */
.page-game-rules__dark-bg {
    background-color: var(--card-bg); /* Use card background, text will be light */
    color: var(--text-main);
    padding: 60px 0;
}

/* Buttons */
.page-game-rules__cta-button {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
    box-sizing: border-box; /* Ensure padding is included in width */
}

.page-game-rules__btn-primary {
    background: var(--button-gradient);
    color: var(--text-main); /* White text on dark gradient */
    border: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-game-rules__btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-game-rules__btn-secondary {
    background: transparent;
    color: var(--gold-color);
    border: 2px solid var(--gold-color);
    margin-left: 20px;
}

.page-game-rules__btn-secondary:hover {
    background: var(--gold-color);
    color: var(--background); /* Dark text on gold hover */
    transform: translateY(-2px);
}

/* Content Images */
.page-game-rules__content-image {
    width: 100%;
    height: auto;
    display: block;
    margin: 30px auto;
    max-width: 800px; /* Limit content image width */
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
}

/* Rule Categories and Lists */
.page-game-rules__rule-category {
    margin-bottom: 40px;
    padding: 30px;
    background-color: var(--deep-green); /* Slightly different dark background */
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-game-rules__rule-subtitle {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.page-game-rules__list {
    list-style: none;
    padding: 0;
    margin-bottom: 20px;
}

.page-game-rules__list li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 10px;
    color: var(--text-secondary);
}

.page-game-rules__list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--gold-color);
    font-weight: 700;
}

/* Game Cards */
.page-game-rules__game-card {
    background-color: var(--card-bg);
    padding: 30px;
    border-radius: 10px;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 200px; /* Ensure cards have some height */
}

.page-game-rules__game-title {
    font-size: 1.6rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--gold-color); /* Title color for contrast */
}

.page-game-rules__game-title a {
    color: inherit; /* Inherit color from parent */
    text-decoration: none;
}

.page-game-rules__game-title a:hover {
    text-decoration: underline;
}

.page-game-rules__game-description {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

/* CTA Group */
.page-game-rules__cta-group {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
    flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
}

/* FAQ Section */
.page-game-rules__faq-section {
    padding: 60px 0;
    background-color: var(--background); /* Light background for FAQ */
    color: var(--text-main);
}

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

.page-game-rules__faq-item {
    background-color: var(--card-bg);
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-game-rules__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    cursor: pointer;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--gold-color);
    background-color: var(--deep-green);
    border-bottom: 1px solid var(--divider-color);
}

.page-game-rules__faq-question:hover {
    background-color: var(--primary-color);
    color: var(--text-main);
}

.page-game-rules__faq-toggle {
    font-size: 1.5rem;
    line-height: 1;
    transition: transform 0.3s ease;
}

.page-game-rules__faq-item[open] .page-game-rules__faq-toggle {
    transform: rotate(45deg);
}

.page-game-rules__faq-answer {
    padding: 20px 25px;
    font-size: 1rem;
    color: var(--text-secondary);
    background-color: var(--card-bg);
}

.page-game-rules__faq-answer p {
    margin-bottom: 0;
    color: var(--text-secondary);
}

/* Conclusion Section */
.page-game-rules__conclusion-section {
    padding: 60px 0;
    text-align: center;
    background-color: var(--deep-green);
    color: var(--text-main);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-game-rules__section-title {
        font-size: 2rem;
    }
    .page-game-rules__rule-subtitle {
        font-size: 1.6rem;
    }
    .page-game-rules__cta-button {
        padding: 12px 25px;
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .page-game-rules__hero-section {
        padding: 40px 15px;
        padding-top: 10px !important; /* body handles header offset */
    }
    .page-game-rules__main-title {
        font-size: clamp(2rem, 8vw, 2.8rem);
    }
    .page-game-rules__description {
        font-size: 1rem;
    }
    .page-game-rules__section-title {
        font-size: 1.8rem;
        margin-bottom: 30px;
    }
    .page-game-rules__rule-subtitle {
        font-size: 1.4rem;
    }
    .page-game-rules__text-block,
    .page-game-rules__list li,
    .page-game-rules__game-description,
    .page-game-rules__faq-answer p {
        font-size: 0.95rem;
    }

    /* Mobile image responsiveness */
    .page-game-rules img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-game-rules__hero-image-wrapper,
    .page-game-rules__container,
    .page-game-rules__rule-category,
    .page-game-rules__game-card,
    .page-game-rules__faq-item,
    .page-game-rules__cta-group {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow: hidden !important;
    }

    /* Mobile button responsiveness */
    .page-game-rules__cta-button,
    .page-game-rules__btn-primary,
    .page-game-rules__btn-secondary,
    .page-game-rules a[class*="button"],
    .page-game-rules a[class*="btn"] {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        margin-left: 0 !important; /* Remove margin for stacked buttons */
        margin-bottom: 10px; /* Add vertical spacing */
    }
    .page-game-rules__cta-group {
        flex-direction: column; /* Stack buttons vertically */
        gap: 10px;
    }
    .page-game-rules__btn-secondary {
        margin-top: 10px; /* Add spacing between primary and secondary if stacked */
    }
}

@media (max-width: 480px) {
    .page-game-rules__main-title {
        font-size: clamp(1.8rem, 10vw, 2.5rem);
    }
    .page-game-rules__section-title {
        font-size: 1.5rem;
    }
    .page-game-rules__faq-question {
        font-size: 1rem;
        padding: 15px 20px;
    }
    .page-game-rules__faq-answer {
        padding: 15px 20px;
    }
}