:root {
    --primary-color: #1A2E44; /* Midnight Blue */
    --secondary-color: #FFD700; /* Gold */
    --text-dark: #333333;
    --text-light: #ffffff;
    --background-light: #f8f8f8;
    --border-color: #e0e0e0;
    --shadow-light: rgba(0, 0, 0, 0.1);
    --shadow-dark: rgba(0, 0, 0, 0.2);
}

.page-lottery {
    font-family: 'Arial', sans-serif;
    color: var(--text-dark); /* Default text color for light body background */
    line-height: 1.6;
    background-color: var(--background-light); /* Light background for overall page */
}

.page-lottery__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* --- Hero Section --- */
.page-lottery__hero-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    padding-top: var(--header-offset, 120px); /* Ensures content is not hidden by fixed header */
    background: linear-gradient(135deg, var(--primary-color), #0D1B2A); /* Darker gradient for hero background */
    color: var(--text-light);
}

.page-lottery__hero-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 30px;
}

.page-lottery__hero-image {
    width: 100%;
    max-width: 900px; /* Adjust max-width for the image */
    margin-bottom: 20px;
}

.page-lottery__hero-image img {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 10px 30px var(--shadow-dark);
}

.page-lottery__hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
    max-width: 800px;
}

.page-lottery__main-title {
    font-size: 3.2em;
    margin-bottom: 20px;
    color: var(--secondary-color); /* Gold title for prominence */
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    line-height: 1.2;
}

.page-lottery__hero-description {
    font-size: 1.2em;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    color: #E0E0E0; /* Slightly lighter white for readability */
}

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

.page-lottery__cta-button {
    display: inline-block;
    padding: 15px 40px;
    text-decoration: none;
    border-radius: 8px;
    font-size: 1.1em;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px var(--shadow-dark);
    white-space: normal; /* Allow text to wrap */
    word-wrap: break-word; /* Allow text to break words */
    max-width: 100%; /* Ensure button doesn't overflow */
    box-sizing: border-box; /* Include padding and border in the element's total width and height */
}

.page-lottery__btn-primary {
    background: var(--secondary-color); /* Gold background */
    color: var(--primary-color); /* Midnight Blue text for contrast */
    border: 2px solid var(--secondary-color);
}

.page-lottery__btn-primary:hover {
    background: #FFEB80; /* Lighter gold on hover */
    color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px var(--shadow-dark);
}

.page-lottery__btn-secondary {
    background: transparent;
    color: var(--secondary-color); /* Gold text */
    border: 2px solid var(--secondary-color);
}

.page-lottery__btn-secondary:hover {
    background: var(--secondary-color);
    color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px var(--shadow-dark);
}

/* --- General Section Styling --- */
.page-lottery__section {
    padding: 80px 0;
    text-align: center;
}

.page-lottery__section:nth-of-type(even) {
    background-color: var(--background-light); /* Alternating background for visual separation */
}

.page-lottery__section-title {
    font-size: 2.5em;
    margin-bottom: 40px;
    color: var(--primary-color);
    position: relative;
    padding-bottom: 15px;
}

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

.page-lottery__section-title--light {
    color: var(--text-light);
}

.page-lottery__section-title--light::after {
    background-color: var(--secondary-color);
}

.page-lottery__text-block {
    max-width: 900px;
    margin: 0 auto 20px auto;
    font-size: 1.1em;
    color: var(--text-dark);
}

.page-lottery__text-block--light {
    color: #E0E0E0;
}

.page-lottery__image-wrapper {
    margin: 40px auto;
    max-width: 900px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 25px var(--shadow-dark);
}

.page-lottery__image-wrapper img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    filter: none; /* Ensure no CSS filter changes image color */
}

.page-lottery__cta-wrapper {
    margin-top: 50px;
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* --- Introduction Section --- */
.page-lottery__introduction {
    background-color: #ffffff;
}
.page-lottery__introduction .page-lottery__text-block strong {
    color: var(--primary-color);
}

/* --- Lottery Types Section --- */
.page-lottery__types {
    background-color: var(--primary-color); /* Dark background */
    color: var(--text-light);
}

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

.page-lottery__card {
    background: #ffffff;
    color: var(--text-dark);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 20px var(--shadow-light);
    text-align: left;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--border-color);
}

.page-lottery__card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px var(--shadow-dark);
}

.page-lottery__card--dark {
    background: #2A4058; /* Slightly lighter dark for cards on dark background */
    color: var(--text-light);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.page-lottery__card--dark .page-lottery__card-title {
    color: var(--secondary-color);
}
.page-lottery__card--dark .page-lottery__card-text {
    color: #E0E0E0;
}
.page-lottery__card--dark .page-lottery__list {
    color: #E0E0E0;
}

.page-lottery__card-title {
    font-size: 1.6em;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.page-lottery__card-text {
    font-size: 1em;
    margin-bottom: 15px;
}

.page-lottery__list {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.95em;
    color: var(--text-dark);
}

.page-lottery__list li {
    margin-bottom: 8px;
    position: relative;
    padding-left: 20px;
}

.page-lottery__list li::before {
    content: '✅'; /* Checkmark icon */
    position: absolute;
    left: 0;
    top: 0;
    color: var(--secondary-color);
}

/* --- How to Play Section --- */
.page-lottery__how-to-play {
    background-color: #ffffff;
}

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

.page-lottery__step-card {
    background: var(--background-light);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 15px var(--shadow-light);
    text-align: left;
    border-top: 5px solid var(--secondary-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-lottery__step-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px var(--shadow-dark);
}

.page-lottery__step-title {
    font-size: 1.5em;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.page-lottery__step-text {
    font-size: 1em;
    color: var(--text-dark);
}

.page-lottery__step-text a {
    color: var(--primary-color);
    text-decoration: underline;
    font-weight: bold;
}

.page-lottery__step-text a:hover {
    color: var(--secondary-color);
}

/* --- Promotions Section --- */
.page-lottery__promotions {
    background-color: var(--primary-color);
}

/* --- Tips & Strategy Section --- */
.page-lottery__tips-strategy {
    background-color: #ffffff;
}

.page-lottery__content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
    text-align: left;
}

.page-lottery__sub-title {
    font-size: 1.8em;
    color: var(--primary-color);
    margin-bottom: 15px;
    position: relative;
    padding-bottom: 10px;
}

.page-lottery__sub-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 60px;
    height: 3px;
    background-color: var(--secondary-color);
    border-radius: 2px;
}

.page-lottery__tips-strategy .page-lottery__text-block p {
    margin-bottom: 1em;
    color: var(--text-dark);
}

.page-lottery__tips-strategy .page-lottery__text-block strong {
    color: var(--primary-color);
}

/* --- FAQ Section --- */
.page-lottery__faq {
    background-color: var(--background-light);
}

.page-lottery__faq-list {
    max-width: 900px;
    margin: 50px auto 0 auto;
    text-align: left;
}

.page-lottery__faq-item {
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px var(--shadow-light);
}

.page-lottery__faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
    padding: 0 20px;
    opacity: 0;
}

.page-lottery__faq-item.active .page-lottery__faq-answer {
    max-height: 2000px !important; /* 🚨 Using !important */
    padding: 20px !important; /* 🚨 Using !important */
    opacity: 1;
    background: #ffffff;
    border-radius: 0 0 8px 8px;
    border-top: 1px solid var(--border-color);
}

.page-lottery__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 20px;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    user-select: none;
    transition: background-color 0.3s ease, border-color 0.3s ease;
    position: relative;
    color: var(--primary-color);
}

.page-lottery__faq-item.active .page-lottery__faq-question {
    border-radius: 8px 8px 0 0;
    border-bottom: none;
}

.page-lottery__faq-question:hover {
    background: var(--background-light);
    border-color: #d0d0d0;
}

.page-lottery__faq-question:active {
    background: #eeeeee;
}

.page-lottery__faq-question h3 {
    margin: 0;
    padding: 0;
    flex: 1;
    font-size: 1.15em;
    font-weight: 600;
    line-height: 1.5;
    pointer-events: none; /* Prevent h3 from blocking click event */
    color: var(--primary-color);
}

.page-lottery__faq-toggle {
    font-size: 24px;
    font-weight: bold;
    line-height: 1;
    color: var(--secondary-color); /* Gold toggle icon */
    transition: transform 0.3s ease, color 0.3s ease;
    flex-shrink: 0;
    margin-left: 15px;
    pointer-events: none; /* Prevent icon from blocking click event */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
}

.page-lottery__faq-item.active .page-lottery__faq-toggle {
    color: var(--primary-color); /* Darker when active */
    transform: rotate(45deg); /* Plus to X effect */
}

.page-lottery__faq-answer p {
    margin: 0;
    color: var(--text-dark);
}

.page-lottery__faq-answer a {
    color: var(--primary-color);
    text-decoration: underline;
}

.page-lottery__faq-answer a:hover {
    color: var(--secondary-color);
}

.page-lottery__faq-buttons {
    margin-top: 20px;
    display: flex;
    justify-content: flex-start;
    gap: 15px;
}

/* --- Conclusion Section --- */
.page-lottery__conclusion {
    background-color: var(--primary-color);
}

.page-lottery__conclusion .page-lottery__cta-button {
    color: var(--primary-color);
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

.page-lottery__conclusion .page-lottery__cta-button:hover {
    background-color: #FFEB80;
    color: var(--primary-color);
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .page-lottery__main-title {
        font-size: 2.8em;
    }
    .page-lottery__section-title {
        font-size: 2.2em;
    }
}

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

    /* Hero Section */
    .page-lottery__hero-section {
        padding-top: var(--header-offset, 120px) !important; /* Mobile specific header offset */
        padding-bottom: 40px;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-lottery__main-title {
        font-size: 2em;
        margin-bottom: 15px;
    }
    .page-lottery__hero-description {
        font-size: 1em;
        margin-bottom: 20px;
    }
    .page-lottery__hero-image img {
        border-radius: 8px;
    }
    .page-lottery__hero-buttons {
        flex-direction: column;
        gap: 15px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 0 15px;
    }
    .page-lottery__cta-button {
        padding: 12px 25px;
        font-size: 1em;
        width: 100% !important; /* Force full width on mobile */
        max-width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    /* General Section */
    .page-lottery__section {
        padding: 40px 0;
    }
    .page-lottery__section-title {
        font-size: 1.8em;
        margin-bottom: 30px;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-lottery__section-title::after {
        width: 60px;
    }
    .page-lottery__container {
        padding: 0 15px;
    }
    .page-lottery__text-block {
        font-size: 1em;
        padding: 0 15px; /* Add padding to text blocks */
    }
    .page-lottery__image-wrapper {
        margin: 20px auto;
        border-radius: 8px;
        padding: 0 15px; /* Ensure wrapper stays within bounds */
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
    }
    .page-lottery__image-wrapper img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        object-fit: cover;
    }

    /* Grid Layouts */
    .page-lottery__grid,
    .page-lottery__steps-grid,
    .page-lottery__content-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-top: 30px;
    }
    .page-lottery__card,
    .page-lottery__step-card {
        padding: 20px;
        border-radius: 8px;
    }
}
}