/* style/game-bai.css */

/* Base styles for the page-game-bai scope */
.page-game-bai {
    font-family: 'Arial', sans-serif;
    color: #FFF5E1; /* Text Main on dark body background */
    line-height: 1.6;
    background-color: #B71C1C; /* Background color from custom palette */
}

.page-game-bai__content-area {
    max-width: 1170px;
    margin: 0 auto;
    padding: 40px 16px;
    box-sizing: border-box;
}

.page-game-bai__content-area--center {
    text-align: center;
}

.page-game-bai__section-title {
    font-size: 2.5em;
    font-weight: bold;
    color: #FFF5E1; /* Text Main on dark background */
    text-align: center;
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 15px;
}

.page-game-bai__section-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #FFD86A, #E6B800); /* Gold gradient */
    border-radius: 2px;
}

.page-game-bai__section-description {
    font-size: 1.1em;
    color: #FFF5E1; /* Text Main */
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
}

/* Hero Section */
.page-game-bai__hero-section {
    padding-top: 10px; /* Small top padding, body handles header offset */
    padding-bottom: 60px;
    background-color: #B71C1C; /* Ensure consistency with body background */
}

.page-game-bai__hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 40px;
    padding: 20px 16px;
}

.page-game-bai__hero-content {
    flex: 1 1 45%;
    min-width: 300px;
    color: #FFF5E1; /* Text Main */
    text-align: left;
}

.page-game-bai__main-title {
    font-size: clamp(2em, 4vw, 3.5em); /* Responsive font size for H1 */
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
    color: #FFF5E1; /* Text Main */
}

.page-game-bai__hero-description {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: #FFF5E1; /* Text Main */
}

.page-game-bai__cta-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.page-game-bai__cta-buttons--center {
    justify-content: center;
    margin-top: 30px;
}

.page-game-bai__btn-primary,
.page-game-bai__btn-secondary {
    display: inline-block;
    padding: 14px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1em;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
    box-sizing: border-box; /* Crucial for responsive buttons */
    white-space: normal; /* Allow text wrapping */
    word-wrap: break-word; /* Allow text breaking */
    max-width: 100%; /* For responsive buttons */
}

.page-game-bai__btn-primary {
    background: linear-gradient(180deg, #FFD86A 0%, #E6B800 100%); /* Custom button color */
    color: #333333; /* Dark text for contrast on light gold button */
    border: 2px solid transparent;
}

.page-game-bai__btn-primary:hover {
    background: linear-gradient(180deg, #E6B800 0%, #FFD86A 100%);
    box-shadow: 0 0 15px rgba(255, 216, 106, 0.6);
}

.page-game-bai__btn-secondary {
    background: transparent;
    color: #FFF5E1; /* Text Main */
    border: 2px solid #F2B544; /* Border color from custom palette */
}

.page-game-bai__btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: #FFD86A;
    color: #FFD86A;
}

.page-game-bai__hero-image {
    flex: 1 1 45%;
    min-width: 300px;
    text-align: center;
}

.page-game-bai__hero-side-image {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* Intro Section (3-column icon boxes) */
.page-game-bai__intro-section {
    padding-top: 60px;
    padding-bottom: 60px;
    background-color: #D32F2F; /* Card BG color */
}

.page-game-bai__intro-text {
    text-align: center;
    font-size: 1.1em;
    margin-bottom: 50px;
    color: #FFF5E1; /* Text Main */
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-game-bai__icon-boxes {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}

.page-game-bai__icon-box {
    flex: 1 1 300px;
    max-width: 350px;
    background-color: #7A0E0E; /* Deep Red for card background */
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
    box-sizing: border-box;
}

.page-game-bai__icon-box:hover {
    transform: translateY(-10px);
}

.page-game-bai__icon-box-media {
    width: 180px; /* Reduced from 400x400 for better layout in 3-col */
    height: 180px;
    margin: 0 auto 20px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid #F2B544; /* Border color */
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 15px rgba(255, 216, 106, 0.4);
}

.page-game-bai__icon-box-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.page-game-bai__icon-box-title {
    font-size: 1.5em;
    font-weight: 700;
    color: #FFD86A; /* Gold color */
    margin-bottom: 15px;
}

.page-game-bai__icon-box-description {
    font-size: 1em;
    color: #FFF5E1; /* Text Main */
}

/* Game Tabs Section */
.page-game-bai__game-tabs-section {
    padding-top: 60px;
    padding-bottom: 60px;
    background-color: #B71C1C; /* Background color */
}

.page-game-bai__tab-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 40px;
    gap: 10px;
    border-bottom: 2px solid #7A0E0E; /* Deep Red */
    padding-bottom: 10px;
}

.page-game-bai__tab-button {
    background-color: transparent;
    border: none;
    padding: 12px 25px;
    font-size: 1.1em;
    font-weight: 600;
    color: #FFF5E1; /* Text Main */
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 8px 8px 0 0;
    position: relative;
    outline: none;
}

.page-game-bai__tab-button:hover {
    color: #FFD86A; /* Gold color */
}

.page-game-bai__tab-button.is-active {
    color: #333333; /* Dark text for active tab */
    background: linear-gradient(180deg, #FFD86A 0%, #E6B800 100%); /* Gold gradient */
    box-shadow: 0 -5px 15px rgba(255, 216, 106, 0.3);
    border-top: 2px solid #FFD86A;
    border-left: 2px solid #FFD86A;
    border-right: 2px solid #FFD86A;
    border-bottom: none;
}

.page-game-bai__game-panels {
    background-color: #7A0E0E; /* Deep Red for panel background */
    border-radius: 0 0 15px 15px;
    padding: 40px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    min-height: 400px; /* Ensure content area is visible */
}

.page-game-bai__game-panel {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

.page-game-bai__game-panel.is-active {
    display: block;
}

.page-game-bai__game-panel-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.page-game-bai__game-panel-image {
    max-width: 800px;
    width: 100%;
    height: auto;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-game-bai__game-panel-title {
    font-size: 2em;
    font-weight: 700;
    color: #FFD86A; /* Gold color */
    margin-bottom: 20px;
}

.page-game-bai__game-panel-description {
    font-size: 1.1em;
    color: #FFF5E1; /* Text Main */
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Guide Section */
.page-game-bai__guide-section {
    padding-top: 60px;
    padding-bottom: 60px;
    background-color: #B71C1C; /* Background color */
}

.page-game-bai__guide-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}