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

.page-game-guides-baccarat-rules {
    font-family: Arial, sans-serif;
    color: var(--text-main); /* Default text color for the page */
    background-color: var(--body-bg); /* Ensure content contrast with body background */
}

.page-game-guides-baccarat-rules__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 0 60px 0; /* Small top padding, more bottom padding for content */
    background-color: var(--card-bg);
    overflow: hidden;
}

.page-game-guides-baccarat-rules__hero-image-wrapper {
    width: 100%;
    max-height: 675px; /* Max height for hero image */
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.page-game-guides-baccarat-rules__hero-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    filter: brightness(0.6); /* Slightly dim the image for text readability */
}

.page-game-guides-baccarat-rules__hero-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 10;
    max-width: 90%;
    padding: 20px;
    box-sizing: border-box;
}

.page-game-guides-baccarat-rules__main-title {
    font-size: clamp(2.2rem, 4vw, 3.5rem);
    font-weight: bold;
    color: var(--text-main);
    line-height: 1.2;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.page-game-guides-baccarat-rules__description {
    font-size: clamp(1rem, 2vw, 1.3rem);
    color: var(--text-secondary);
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.page-game-guides-baccarat-rules__cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.page-game-guides-baccarat-rules__btn-primary,
.page-game-guides-baccarat-rules__btn-secondary {
    display: inline-block;
    padding: 14px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
    max-width: 100%;
    white-space: normal;
    word-wrap: break-word;
    text-align: center;
}

.page-game-guides-baccarat-rules__btn-primary {
    background: var(--button-gradient);
    color: var(--text-main);
    border: 2px solid transparent;
}

.page-game-guides-baccarat-rules__btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(var(--glow-color), 0.4);
}

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

.page-game-guides-baccarat-rules__btn-secondary:hover {
    background: var(--gold-color);
    color: var(--body-bg);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(var(--gold-color), 0.4);
}

.page-game-guides-baccarat-rules__content-area {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
    background-color: var(--body-bg);
    color: var(--text-secondary);
}

.page-game-guides-baccarat-rules__section-container {
    margin-bottom: 50px;
    padding: 30px;
    border-radius: 12px;
    background-color: var(--card-bg);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
}

.page-game-guides-baccarat-rules__section-title {
    font-size: 2.2rem;
    color: var(--text-main);
    margin-bottom: 25px;
    text-align: center;
    font-weight: bold;
    position: relative;
    padding-bottom: 15px;
}

.page-game-guides-baccarat-rules__section-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--gold-color);
    border-radius: 2px;
}

.page-game-guides-baccarat-rules__sub-title {
    font-size: 1.6rem;
    color: var(--text-main);
    margin-top: 35px;
    margin-bottom: 20px;
    font-weight: bold;
}

.page-game-guides-baccarat-rules__text-block {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 20px;
    color: var(--text-secondary);
}

.page-game-guides-baccarat-rules__text-block a {
    color: var(--gold-color);
    text-decoration: none;
}

.page-game-guides-baccarat-rules__text-block a:hover {
    text-decoration: underline;
}

.page-game-guides-baccarat-rules__list,
.page-game-guides-baccarat-rules__ordered-list {
    list-style-type: disc;
    margin-left: 25px;
    margin-bottom: 20px;
    color: var(--text-secondary);
}

.page-game-guides-baccarat-rules__ordered-list {
    list-style-type: decimal;
}

.page-game-guides-baccarat-rules__list-item {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 10px;
}

.page-game-guides-baccarat-rules__sub-list {
    list-style-type: circle;
    margin-left: 20px;
    margin-top: 10px;
}

.page-game-guides-baccarat-rules__image-inline {
    width: 100%;
    height: auto;
    display: block;
    margin: 30px auto;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color);
}

.page-game-guides-baccarat-rules__dark-bg {
    background-color: var(--deep-green);
    color: var(--text-main);
}

.page-game-guides-baccarat-rules__dark-bg .page-game-guides-baccarat-rules__section-title {
    color: var(--text-main);
}

.page-game-guides-baccarat-rules__dark-bg .page-game-guides-baccarat-rules__text-secondary {
    color: var(--text-secondary);
}

.page-game-guides-baccarat-rules__cta-section {
    text-align: center;
    padding: 50px 20px;
    margin-top: 40px;
    margin-bottom: 40px;
}

.page-game-guides-baccarat-rules__faq-list {
    margin-top: 40px;
}

.page-game-guides-baccarat-rules__faq-item {
    background-color: var(--body-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.page-game-guides-baccarat-rules__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    cursor: pointer;
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--text-main);
    background-color: var(--card-bg);
    border-bottom: 1px solid var(--divider-color);
}

.page-game-guides-baccarat-rules__faq-question:hover {
    background-color: var(--deep-green);
}

.page-game-guides-baccarat-rules__faq-toggle {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--gold-color);
    transition: transform 0.3s ease;
}

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

.page-game-guides-baccarat-rules__faq-answer {
    padding: 20px 25px;
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-secondary);
    background-color: var(--body-bg);
}

.page-game-guides-baccarat-rules__faq-answer p {
    margin-bottom: 10px;
}

.page-game-guides-baccarat-rules__faq-answer a {
    color: var(--gold-color);
    text-decoration: none;
}

.page-game-guides-baccarat-rules__faq-answer a:hover {
    text-decoration: underline;
}

/* Ensure color contrast for main text */
.page-game-guides-baccarat-rules__content-area p,
.page-game-guides-baccarat-rules__content-area li {
    color: var(--text-secondary);
}

/* Hide default details marker */
.page-game-guides-baccarat-rules__faq-item summary::-webkit-details-marker {
    display: none;
}
.page-game-guides-baccarat-rules__faq-item summary::marker {
    display: none;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .page-game-guides-baccarat-rules__hero-content {
        max-width: 95%;
    }
    .page-game-guides-baccarat-rules__main-title {
        font-size: clamp(2rem, 5vw, 3rem);
    }
    .page-game-guides-baccarat-rules__description {
        font-size: clamp(0.95rem, 2.5vw, 1.2rem);
    }
    .page-game-guides-baccarat-rules__section-title {
        font-size: 1.8rem;
    }
    .page-game-guides-baccarat-rules__sub-title {
        font-size: 1.4rem;
    }
    .page-game-guides-baccarat-rules__text-block,
    .page-game-guides-baccarat-rules__list-item,
    .page-game-guides-baccarat-rules__faq-question,
    .page-game-guides-baccarat-rules__faq-answer {
        font-size: 1rem;
    }
}

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

    .page-game-guides-baccarat-rules__hero-section {
        padding: 10px 0 40px 0;
    }

    .page-game-guides-baccarat-rules__hero-content {
        padding: 15px;
        position: static; /* Allow content to flow naturally on small screens */
        transform: none;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    .page-game-guides-baccarat-rules__hero-image-wrapper {
        max-height: 400px;
    }

    .page-game-guides-baccarat-rules__main-title {
        font-size: 2rem !important;
        margin-bottom: 15px;
    }

    .page-game-guides-baccarat-rules__description {
        font-size: 1rem !important;
        margin-bottom: 20px;
        padding: 0 15px;
    }

    .page-game-guides-baccarat-rules__cta-buttons {
        flex-direction: column;
        gap: 15px;
        padding: 0 15px;
    }

    .page-game-guides-baccarat-rules__btn-primary,
    .page-game-guides-baccarat-rules__btn-secondary {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 20px !important;
        font-size: 1rem !important;
    }

    .page-game-guides-baccarat-rules__content-area {
        padding: 30px 15px;
    }

    .page-game-guides-baccarat-rules__section-container {
        padding: 20px;
        margin-bottom: 30px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .page-game-guides-baccarat-rules__section-title {
        font-size: 1.6rem !important;
        margin-bottom: 20px;
    }

    .page-game-guides-baccarat-rules__sub-title {
        font-size: 1.3rem !important;
        margin-top: 25px;
        margin-bottom: 15px;
    }

    .page-game-guides-baccarat-rules__text-block,
    .page-game-guides-baccarat-rules__list-item,
    .page-game-guides-baccarat-rules__faq-question,
    .page-game-guides-baccarat-rules__faq-answer {
        font-size: 0.95rem !important;
    }

    .page-game-guides-baccarat-rules__image-inline {
        max-width: 100% !important;
        height: auto !important;
        margin: 20px auto !important;
    }

    .page-game-guides-baccarat-rules__faq-question {
        padding: 15px 20px;
    }

    .page-game-guides-baccarat-rules__faq-answer {
        padding: 15px 20px;
    }
}

/* General image responsiveness for content area */
.page-game-guides-baccarat-rules img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Content area images CSS dimensions lower bound */
.page-game-guides-baccarat-rules__section-container img,
.page-game-guides-baccarat-rules__text-block img {
    min-width: 200px; /* Ensure content images are not too small */
    min-height: 200px;
}

/* Mobile specific overrides for images and containers */
@media (max-width: 768px) {
    .page-game-guides-baccarat-rules img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-game-guides-baccarat-rules__section,
    .page-game-guides-baccarat-rules__card,
    .page-game-guides-baccarat-rules__container,
    .page-game-guides-baccarat-rules__section-container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow: hidden !important;
    }
    .page-game-guides-baccarat-rules__hero-image {
        filter: brightness(0.5) !important; /* Make hero image darker for better text contrast on mobile */
    }
}

/* Hero image specific styling to ensure text is above the image */
.page-game-guides-baccarat-rules__hero-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.page-game-guides-baccarat-rules__hero-image-wrapper {
    order: 1; /* Image first */
}

.page-game-guides-baccarat-rules__hero-content {
    order: 2; /* Content second */
    position: relative; /* Reset position for mobile, it will be static */
    transform: none; /* Reset transform for mobile */
    top: auto; 
    left: auto;
    margin-top: 20px; /* Add some space between image and content */
    padding: 0 20px; /* Add horizontal padding */
}

@media (min-width: 769px) {
    .page-game-guides-baccarat-rules__hero-content {
        position: absolute; /* Revert to absolute for desktop to overlay */
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        margin-top: 0;
        padding: 20px;
    }
}