/* style/g.css */
.page-g {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #ffffff; /* Default text color for dark body background */
    background-color: #1a1a2e; /* Inherited from shared, but explicit for context */
}

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

/* Hero Section */
.page-g__hero-section {
    position: relative;
    text-align: center;
    overflow: hidden;
    padding-top: 10px; /* Small top padding, body handles header offset */
    padding-bottom: 40px;
    background-color: #017439; /* Brand color as hero background */
}

.page-g__hero-image-wrapper {
    width: 100%;
    max-height: 600px; /* Limit hero image height */
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.page-g__hero-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

.page-g__hero-content {
    padding: 20px;
    max-width: 900px;
    margin: 20px auto 0;
}

.page-g__main-title {
    font-size: 2.8em;
    font-weight: 700;
    line-height: 1.2;
    color: #ffffff;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-g__description {
    font-size: 1.2em;
    color: #f0f0f0;
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

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

.page-g__cta-buttons--centered {
    margin-top: 30px;
}

.page-g__btn-primary,
.page-g__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1em;
    transition: all 0.3s ease;
    text-align: center;
    box-sizing: border-box;
    max-width: 300px; /* Limit button width */
}

.page-g__btn-primary {
    background-color: #C30808; /* Custom Register color */
    color: #ffffff; /* ENSURING CONTRAST - overriding #FFFF00 */
    border: 2px solid #C30808;
}

.page-g__btn-primary:hover {
    background-color: #e00b0b;
    border-color: #e00b0b;
    transform: translateY(-2px);
}

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

.page-g__btn-secondary:hover {
    background-color: #ffffff;
    color: #017439;
    transform: translateY(-2px);
}

/* General Section Styling */
.page-g__section-title {
    font-size: 2.2em;
    font-weight: 700;
    color: #ffffff;
    text-align: center;
    margin-bottom: 30px;
    padding-top: 40px;
}

.page-g__text-block {
    font-size: 1.1em;
    color: #f0f0f0;
    margin-bottom: 20px;
    text-align: justify;
}

.page-g__dark-section {
    background-color: #017439; /* Brand primary color for dark sections */
    padding: 60px 0;
}

.page-g__introduction-section,
.page-g__how-to-play-section,
.page-g__game-types-section,
.page-g__benefits-section,
.page-g__login-guide-section,
.page-g__faq-section,
.page-g__conclusion-section {
    padding: 60px 0;
}

/* Images within content */
.page-g__image-content {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 30px auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* Lists */
.page-g__ordered-list,
.page-g__unordered-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.page-g__list-item {
    font-size: 1.1em;
    color: #f0f0f0;
    margin-bottom: 15px;
    padding-left: 25px;
    position: relative;
}

.page-g__ordered-list .page-g__list-item::before {
    content: counter(list-item) ".";
    counter-increment: list-item;
    position: absolute;
    left: 0;
    color: #FFFF00; /* Custom register/login font color for list numbers */
    font-weight: bold;
}

.page-g__unordered-list .page-g__list-item::before {
    content: "•";
    position: absolute;
    left: 0;
    color: #FFFF00; /* Custom register/login font color for bullets */
    font-weight: bold;
}

/* Cards */
.page-g__card {
    background-color: rgba(255, 255, 255, 0.1); /* Semi-transparent white on dark background */
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%; /* Ensure cards in a grid have equal height */
}

.page-g__card-title {
    font-size: 1.4em;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 15px;
}

.page-g__card-text {
    font-size: 1em;
    color: #e0e0e0;
}

.page-g__grid-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

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

.page-g__login-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.page-g__login-step-card {
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    text-align: center;
    height: 100%;
}
.page-g__login-step-card .page-g__card-title {
    color: #FFFF00; /* Custom color for step titles */
}
.page-g__login-step-card .page-g__card-text {
    color: #f0f0f0;
}

/* FAQ Section */
.page-g__faq-list {
    margin-top: 30px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-g__faq-item {
    background-color: rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    overflow: hidden;
}

.page-g__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    font-size: 1.15em;
    font-weight: 600;
    color: #ffffff;
    cursor: pointer;
    background-color: rgba(255, 255, 255, 0.05);
    transition: background-color 0.3s ease;
    list-style: none; /* For details/summary */
}

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

.page-g__faq-item[open] .page-g__faq-question {
    background-color: rgba(255, 255, 255, 0.12);
}

.page-g__faq-question:hover {
    background-color: rgba(255, 255, 255, 0.12);
}

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

.page-g__faq-toggle {
    font-size: 1.5em;
    font-weight: bold;
    color: #FFFF00; /* Custom color for FAQ toggle */
    margin-left: 15px;
    transition: transform 0.3s ease;
}

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

.page-g__faq-answer {
    padding: 0 25px 20px;
    font-size: 1em;
    color: #e0e0e0;
}

.page-g__faq-answer .page-g__image-content {
    margin-top: 15px;
    margin-bottom: 10px;
    border-radius: 5px;
}

/* Conclusion Section */
.page-g__conclusion-section {
    text-align: center;
}
.page-g__conclusion-section .page-g__text-block {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 30px;
}


/* Responsive Design */
@media (max-width: 1024px) {
    .page-g__main-title {
        font-size: 2.5em;
    }

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

    .page-g__cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    .page-g__btn-primary,
    .page-g__btn-secondary {
        max-width: 80%;
        width: 100%;
    }
}

@media (max-width: 768px) {
    /* HERO Section */
    .page-g__hero-section {
        padding-top: 10px !important; /* Small top padding, body handles header offset */
        padding-bottom: 20px !important;
    }
    .page-g__hero-image-wrapper {
        max-height: 400px;
    }
    .page-g__main-title {
        font-size: 2em !important;
        margin-bottom: 10px !important;
    }
    .page-g__description {
        font-size: 1em !important;
        margin-bottom: 20px !important;
    }

    /* General Sections and Containers */
    .page-g__introduction-section,
    .page-g__how-to-play-section,
    .page-g__game-types-section,
    .page-g__benefits-section,
    .page-g__login-guide-section,
    .page-g__faq-section,
    .page-g__conclusion-section {
        padding: 40px 0 !important;
    }
    .page-g__container {
        padding-left: 15px !important;
        padding-right: 15px !important;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    .page-g__section-title {
        font-size: 1.8em !important;
        margin-bottom: 20px !important;
        padding-top: 20px !important;
    }
    .page-g__text-block {
        font-size: 0.95em !important;
    }

    /* Universal Images and Containers */
    .page-g img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        box-sizing: border-box !important;
    }
    .page-g__image-content {
        margin: 20px auto !important;
    }
    .page-g__section,
    .page-g__card,
    .page-g__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Buttons and Button Containers */
    .page-g__cta-buttons {
        flex-direction: column !important;
        gap: 10px !important;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-g__btn-primary,
    .page-g__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 !important;
        font-size: 1em !important;
    }
    
    /* Product/Game/Card Grids - Mobile layout */
    .page-g__grid-list,
    .page-g__benefits-list,
    .page-g__login-steps {
        grid-template-columns: 1fr !important; /* Single column layout */
        gap: 20px !important;
        margin-top: 20px !important;
    }
    .page-g__card,
    .page-g__login-step-card {
        padding: 20px !important;
        margin-bottom: 0 !important; /* Remove bottom margin if gap is used */
    }

    /* FAQ Section */
    .page-g__faq-question {
        font-size: 1em !important;
        padding: 15px 20px !important;
    }
    .page-g__faq-answer {
        padding: 0 20px 15px !important;
        font-size: 0.95em !important;
    }
    .page-g__faq-toggle {
        font-size: 1.3em !important;
    }
}