/* style/tai-xiu.css */

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

.page-tai-xiu {
    font-family: 'Arial', sans-serif;
    color: var(--tdtc-text-main); /* Default text color for the page */
    background-color: var(--tdtc-background); /* Page background */
    line-height: 1.6;
}

/* 1. Top Section (Hero-like) */
.page-tai-xiu__hero-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding-bottom: 40px;
    padding-top: 10px; /* Specific: ~10px top padding for first section */
    position: relative;
    overflow: hidden;
}

.page-tai-xiu__hero-image-wrapper {
    width: 100%;
    max-height: 675px; /* Adjust based on typical hero image height for content */
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.page-tai-xiu__hero-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    object-position: center;
}

.page-tai-xiu__hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin-top: -150px; /* Overlap slightly for visual effect, but content itself is below */
    padding: 0 20px;
    background: linear-gradient(to top, var(--tdtc-background) 70%, transparent 100%);
    padding-top: 150px; /* Compensate for negative margin */
    width: 100%;
    box-sizing: border-box;
}

.page-tai-xiu__main-title {
    font-size: clamp(2.2em, 4vw, 3.5em); /* H1 title clamp */
    color: var(--tdtc-gold);
    margin-bottom: 15px;
    font-weight: 700;
    line-height: 1.2;
    text-shadow: 0 0 10px rgba(242, 193, 78, 0.5);
}

.page-tai-xiu__description {
    font-size: 1.1em;
    color: var(--tdtc-text-secondary);
    margin-bottom: 30px;
}

.page-tai-xiu__cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap; /* Allow wrapping for multiple buttons */
    width: 100%; /* Ensure container takes full width */
    max-width: 600px; /* Limit button group width */
    margin: 0 auto;
    box-sizing: border-box;
}

.page-tai-xiu__btn {
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1.1em;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
    flex-grow: 1;
    min-width: 180px;
    max-width: 100%; /* Ensure button adapts to container */
    box-sizing: border-box;
    white-space: normal; /* Allow text to wrap */
    word-wrap: break-word; /* Break long words */
}

.page-tai-xiu__btn--primary {
    background: var(--tdtc-button-gradient);
    color: var(--tdtc-text-main);
    border: 2px solid transparent;
    box-shadow: 0 4px 15px rgba(42, 209, 111, 0.4);
}

.page-tai-xiu__btn--primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(42, 209, 111, 0.6);
}

.page-tai-xiu__btn--secondary {
    background: var(--tdtc-background);
    color: var(--tdtc-green-main);
    border: 2px solid var(--tdtc-green-main);
    box-shadow: 0 4px 15px rgba(17, 168, 78, 0.2);
}

.page-tai-xiu__btn--secondary:hover {
    transform: translateY(-3px);
    background: var(--tdtc-green-main);
    color: var(--tdtc-text-main);
    box-shadow: 0 6px 20px rgba(17, 168, 78, 0.4);
}

/* 2. Single column long-form content containers */
.page-tai-xiu__section {
    padding: 60px 0;
    border-bottom: 1px solid var(--tdtc-divider);
}

.page-tai-xiu__section:last-of-type {
    border-bottom: none;
}

.page-tai-xiu__article-wrap {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

.page-tai-xiu__article-wrap--center {
    text-align: center;
}

.page-tai-xiu__section-title {
    font-size: 2.5em;
    color: var(--tdtc-gold);
    margin-bottom: 30px;
    text-align: center;
    font-weight: 700;
    line-height: 1.3;
}

.page-tai-xiu__sub-title {
    font-size: 1.8em;
    color: var(--tdtc-green-secondary);
    margin-top: 40px;
    margin-bottom: 15px;
    font-weight: 600;
}

.page-tai-xiu p {
    margin-bottom: 1em;
    color: var(--tdtc-text-main);
}

.page-tai-xiu strong {
    color: var(--tdtc-gold);
}

.page-tai-xiu a {
    color: var(--tdtc-green-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-tai-xiu a:hover {
    color: var(--tdtc-gold);
    text-decoration: underline;
}

.page-tai-xiu__list {
    list-style-type: disc;
    margin-left: 25px;
    margin-bottom: 1em;
    color: var(--tdtc-text-main);
}

.page-tai-xiu__list li {
    margin-bottom: 0.5em;
}

.page-tai-xiu__sub-list {
    list-style-type: circle;
    margin-left: 20px;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
    color: var(--tdtc-text-secondary);
}

/* 3. General images and figures */
.page-tai-xiu__figure {
    margin: 30px 0;
    text-align: center;
    background-color: var(--tdtc-card-bg);
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.page-tai-xiu__image {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 5px;
    margin: 0 auto;
    object-fit: cover;
    object-position: center;
}

.page-tai-xiu__figcaption {
    font-size: 0.9em;
    color: var(--tdtc-text-secondary);
    margin-top: 10px;
}

/* Promotions Grid */
.page-tai-xiu__promo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.page-tai-xiu__promo-card {
    background-color: var(--tdtc-card-bg);
    border: 1px solid var(--tdtc-border);
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.page-tai-xiu__promo-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
}

.page-tai-xiu__promo-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 15px;
}

.page-tai-xiu__promo-title {
    font-size: 1.5em;
    color: var(--tdtc-gold);
    margin-bottom: 10px;
    font-weight: 600;
}

.page-tai-xiu__promo-description {
    color: var(--tdtc-text-secondary);
    font-size: 0.95em;
    flex-grow: 1;
    margin-bottom: 20px;
}

.page-tai-xiu__btn--link {
    display: inline-block;
    background: var(--tdtc-deep-green);
    color: var(--tdtc-text-main);
    padding: 10px 20px;
    border-radius: 5px;
    font-size: 0.9em;
    font-weight: 500;
    margin-top: auto; /* Push to bottom */
}

.page-tai-xiu__btn--link:hover {
    background: var(--tdtc-green-main);
    text-decoration: none;
}

/* FAQ Section */
.page-tai-xiu__faq-list {
    margin-top: 30px;
}

.page-tai-xiu__faq-item {
    background-color: var(--tdtc-card-bg);
    border: 1px solid var(--tdtc-border);
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.page-tai-xiu__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    font-size: 1.15em;
    font-weight: 600;
    color: var(--tdtc-text-main);
    cursor: pointer;
    background-color: var(--tdtc-deep-green);
    border-bottom: 1px solid var(--tdtc-divider);
    list-style: none; /* For details/summary */
}

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

.page-tai-xiu__faq-question::marker {
    display: none;
}

.page-tai-xiu__faq-qtext {
    flex-grow: 1;
}

.page-tai-xiu__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    margin-left: 15px;
    color: var(--tdtc-gold);
    transition: transform 0.3s ease;
}

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

.page-tai-xiu__faq-answer {
    padding: 20px 25px;
    font-size: 1em;
    color: var(--tdtc-text-secondary);
    background-color: var(--tdtc-card-bg);
    border-top: 1px solid var(--tdtc-divider);
}

.page-tai-xiu__faq-answer p:last-child {
    margin-bottom: 0;
}

/* Final CTA Section */
.page-tai-xiu__section--final-cta {
    padding-top: 80px;
    padding-bottom: 80px;
    background: linear-gradient(135deg, var(--tdtc-deep-green) 0%, var(--tdtc-background) 100%);
    text-align: center;
}

/* Buttons group with center alignment */
.page-tai-xiu__button-group {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 30px;
    flex-wrap: wrap;
    width: 100%;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box;
}

.page-tai-xiu__button-group--center {
    justify-content: center;
}


/* ------------------------------------------- */
/* Responsive Styles for Mobile (max-width: 768px) */
/* ------------------------------------------- */
@media (max-width: 768px) {
    .page-tai-xiu__hero-section {
        padding-top: 10px !important; /* Fixed header spacing */
        padding-bottom: 20px;
    }

    .page-tai-xiu__hero-content {
        margin-top: -80px; /* Adjust overlap for mobile */
        padding-top: 80px;
    }

    .page-tai-xiu__main-title {
        font-size: clamp(1.8em, 8vw, 2.5em); /* Adjust H1 size for mobile */
        margin-bottom: 10px;
    }

    .page-tai-xiu__description {
        font-size: 1em;
        margin-bottom: 20px;
    }

    /* 1. Top section title + CTA */
    .page-tai-xiu__cta-buttons {
        flex-direction: column; /* Stack buttons vertically */
        gap: 15px;
        padding: 0 15px; /* Add padding to container */
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .page-tai-xiu__btn {
        width: 100% !important; /* Full width for buttons */
        min-width: unset;
        max-width: 100% !important;
        padding: 12px 20px;
        font-size: 1em;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    /* 2. Single column long-form content containers */
    .page-tai-xiu__section {
        padding: 40px 0;
    }

    .page-tai-xiu__article-wrap {
        padding: 0 15px; /* Adjust padding for mobile */
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .page-tai-xiu__section-title {
        font-size: 2em;
        margin-bottom: 20px;
    }

    .page-tai-xiu__sub-title {
        font-size: 1.5em;
        margin-top: 30px;
        margin-bottom: 10px;
    }

    .page-tai-xiu p,
    .page-tai-xiu li {
        font-size: 0.95em;
    }

    /* 3. General images and figures */
    .page-tai-xiu__image {
        max-width: 100% !important;
        height: auto !important;
        width: 100% !important; /* Ensure images take full container width */
        box-sizing: border-box !important;
    }

    .page-tai-xiu__figure {
        padding: 10px;
        margin: 20px 0;
    }

    .page-tai-xiu__promo-grid {
        grid-template-columns: 1fr; /* Single column for promo cards */
        gap: 20px;
    }

    .page-tai-xiu__promo-image {
        height: 180px; /* Adjust height for mobile cards */
    }

    .page-tai-xiu__promo-title {
        font-size: 1.3em;
    }

    .page-tai-xiu__promo-description {
        font-size: 0.9em;
    }

    /* 4. Buttons and button containers (already covered in top section, but ensure general application) */
    .page-tai-xiu__button-group {
        flex-direction: column; /* Stack buttons vertically */
        gap: 15px;
        padding: 0 15px; /* Add padding to container */
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .page-tai-xiu__button-group .page-tai-xiu__btn {
        width: 100% !important;
        min-width: unset;
        max-width: 100% !important;
        padding: 12px 20px;
        font-size: 1em;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    /* 5. Registration tutorial and FAQ blocks */
    .page-tai-xiu__faq-question {
        padding: 15px 20px;
        font-size: 1.05em;
    }

    .page-tai-xiu__faq-answer {
        padding: 15px 20px;
        font-size: 0.9em;
    }
}

/* Additional media query for tablets/smaller desktops */
@media (max-width: 1024px) {
    .page-tai-xiu__hero-content {
        margin-top: -100px;
        padding-top: 100px;
    }
    .page-tai-xiu__main-title {
        font-size: clamp(2em, 3.5vw, 3em);
    }
    .page-tai-xiu__section-title {
        font-size: 2.2em;
    }
    .page-tai-xiu__article-wrap {
        max-width: 800px;
        padding: 0 30px;
    }
    .page-tai-xiu__promo-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 20px;
    }
}