/* style/promotions.css */

/* Custom properties for colors */
:root {
    --primary-color: #11A84E;
    --secondary-color: #22C768;
    --button-gradient-start: #2AD16F;
    --button-gradient-end: #13994A;
    --card-bg: #11271B;
    --background-color: #08160F; /* This is the body background */
    --text-main: #F2FFF6;
    --text-secondary: #A7D9B8;
    --border-color: #2E7A4E;
    --glow-color: #57E38D;
    --gold-color: #F2C14E;
    --divider-color: #1E3A2A;
    --deep-green: #0A4B2C;
}

/* Base styles for the page content, ensuring contrast with body background */
.page-promotions {
    background-color: var(--background-color); /* Matches the provided background */
    color: var(--text-main); /* Light text for dark background */
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    padding-bottom: 40px; /* Add some padding at the bottom */
}

/* Section styling */
.page-promotions__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding-top: 10px; /* Small top padding */
    padding-bottom: 60px;
    background-color: var(--deep-green); /* A darker green for the hero section background */
}

.page-promotions__hero-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
    max-width: 100%; /* Ensure image responsiveness */
}

.page-promotions__hero-content {
    position: relative; /* Changed from absolute to relative for "上图下文" */
    text-align: center;
    padding: 20px;
    max-width: 900px;
    margin-top: 30px; /* Space between image and content */
    z-index: 1; /* Ensure content is above image if any overlap */
}

.page-promotions__main-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem); /* Responsive font size for H1 */
    color: var(--gold-color); /* Gold color for main title */
    margin-bottom: 20px;
    font-weight: bold;
    line-height: 1.2;
    text-shadow: 0 0 10px rgba(87, 227, 141, 0.5); /* Soft glow */
}

.page-promotions__intro-text {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

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

.page-promotions__btn-primary,
.page-promotions__btn-secondary,
.page-promotions__card-button,
.page-promotions__inline-button {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    box-sizing: border-box;
    max-width: 100%; /* Ensure button responsiveness */
    white-space: normal; /* Allow text to wrap */
    word-wrap: break-word; /* Allow text to break words */
    text-align: center;
}

.page-promotions__btn-primary {
    background: linear-gradient(180deg, var(--button-gradient-start) 0%, var(--button-gradient-end) 100%);
    color: var(--text-main); /* White-ish text on green gradient */
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.page-promotions__btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    opacity: 0.9;
}

.page-promotions__btn-secondary {
    background: var(--card-bg); /* Darker background */
    color: var(--primary-color); /* Primary green text */
    border: 2px solid var(--primary-color);
}

.page-promotions__btn-secondary:hover {
    background: var(--primary-color);
    color: var(--text-main);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.page-promotions__btn-large {
    padding: 18px 40px;
    font-size: 1.2rem;
}

.page-promotions__section-title {
    font-size: 2.2rem;
    color: var(--gold-color);
    text-align: center;
    margin-bottom: 40px;
    margin-top: 60px;
    font-weight: bold;
    text-shadow: 0 0 8px rgba(87, 227, 141, 0.3);
}

.page-promotions__text-block {
    font-size: 1rem;
    color: var(--text-secondary);
    text-align: justify;
    margin-bottom: 20px;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.page-promotions__overview-section,
.page-promotions__categories-section,
.page-promotions__how-to-claim-section,
.page-promotions__terms-section,
.page-promotions__faq-section,
.page-promotions__cta-bottom-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}

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

.page-promotions__promotion-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    text-align: center;
    padding-bottom: 20px;
    box-shadow: 0 8px 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-promotions__promotion-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.5);
}

.page-promotions__card-image {
    width: 100%;
    height: 200px; /* Fixed height for consistency */
    object-fit: cover;
    display: block;
    margin-bottom: 20px;
}

.page-promotions__card-title {
    font-size: 1.4rem;
    color: var(--text-main);
    margin: 0 15px 15px;
    font-weight: bold;
}

.page-promotions__card-text {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin: 0 15px 20px;
    flex-grow: 1; /* Allow text to take available space */
}

.page-promotions__card-button {
    background: linear-gradient(180deg, var(--button-gradient-start) 0%, var(--button-gradient-end) 100%);
    color: var(--text-main);
    border: none;
    padding: 12px 25px;
    border-radius: 6px;
    margin: 0 15px;
    font-size: 0.9rem;
    font-weight: bold;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

.page-promotions__card-button:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.page-promotions__steps-list {
    list-style: none;
    padding: 0;
    margin-top: 40px;
}

.page-promotions__step-item {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.page-promotions__step-title {
    font-size: 1.3rem;
    color: var(--primary-color);
    margin-bottom: 10px;
    font-weight: bold;
}

.page-promotions__step-description {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.page-promotions__inline-button {
    background: var(--primary-color);
    color: var(--text-main);
    padding: 8px 15px;
    border-radius: 5px;
    font-size: 0.9rem;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

.page-promotions__inline-button:hover {
    background-color: var(--secondary-color);
}

.page-promotions__terms-list {
    list-style: none;
    padding: 0;
    margin-top: 30px;
}

.page-promotions__terms-item {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 15px;
    color: var(--text-secondary);
    font-size: 0.95rem;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

/* FAQ Section */
.page-promotions__faq-list {
    margin-top: 40px;
}

.page-promotions__faq-item {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    margin-bottom: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.page-promotions__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--text-main);
    transition: background-color 0.3s ease;
    user-select: none;
}

.page-promotions__faq-question:hover {
    background-color: var(--deep-green);
}

.page-promotions__faq-qtext {
    flex-grow: 1;
    color: var(--primary-color); /* Question text in primary color */
}

.page-promotions__faq-toggle {
    font-size: 1.5rem;
    line-height: 1;
    margin-left: 15px;
    color: var(--gold-color);
}

.page-promotions__faq-answer {
    padding: 0 25px 20px;
    font-size: 0.95rem;
    color: var(--text-secondary);
    max-height: 0; /* Hidden by default for JS toggle */
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
}

.page-promotions__faq-item[open] .page-promotions__faq-answer {
    max-height: 500px; /* Max height for expansion */
    padding-top: 10px;
}

/* For JS toggle, if not using details/summary */
.page-promotions__faq-item.active .page-promotions__faq-answer {
    max-height: 2000px !important; /* Ensure it expands, important for JS */
    padding-top: 10px;
}

.page-promotions__faq-item.active .page-promotions__faq-question .page-promotions__faq-toggle {
    content: '−'; /* Change to minus when active */
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .page-promotions__main-title {
        font-size: clamp(2rem, 6vw, 3rem);
    }
    .page-promotions__section-title {
        font-size: 1.8rem;
    }
    .page-promotions__promotion-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    .page-promotions {
        font-size: 16px;
        line-height: 1.6;
    }
    .page-promotions__hero-content {
        padding: 15px;
        margin-top: 20px;
    }
    .page-promotions__main-title {
        font-size: clamp(1.8rem, 7vw, 2.5rem);
        margin-bottom: 15px;
    }
    .page-promotions__intro-text {
        font-size: 1rem;
        margin-bottom: 25px;
    }
    .page-promotions__cta-buttons {
        flex-direction: column; /* Stack buttons vertically */
        gap: 15px;
        width: 100%;
        max-width: 300px; /* Limit width for stacked buttons */
        margin: 0 auto;
    }
    .page-promotions__btn-primary,
    .page-promotions__btn-secondary,
    .page-promotions__card-button,
    .page-promotions__inline-button {
        max-width: 100% !important;
        width: 100% !important;
        padding-left: 15px;
        padding-right: 15px;
        white-space: normal !important;
        word-wrap: break-word !important;
    }
    .page-promotions__section-title {
        font-size: 1.6rem;
        margin-top: 40px;
        margin-bottom: 30px;
    }
    .page-promotions__text-block {
        font-size: 0.95rem;
        padding: 0 10px; /* Add horizontal padding */
    }
    .page-promotions__overview-section,
    .page-promotions__categories-section,
    .page-promotions__how-to-claim-section,
    .page-promotions__terms-section,
    .page-promotions__faq-section,
    .page-promotions__cta-bottom-section {
        padding: 15px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    .page-promotions__promotion-grid {
        grid-template-columns: 1fr; /* Single column on mobile */
        gap: 20px;
    }
    .page-promotions__card-image {
        height: 180px; /* Slightly smaller card images */
    }
    .page-promotions__card-title {
        font-size: 1.2rem;
    }
    .page-promotions__card-text {
        font-size: 0.9rem;
    }
    .page-promotions__step-item {
        padding: 20px;
    }
    .page-promotions__step-title {
        font-size: 1.15rem;
    }
    .page-promotions__step-description {
        font-size: 0.9rem;
    }
    .page-promotions__faq-question {
        font-size: 1rem;
        padding: 15px 20px;
    }
    .page-promotions__faq-answer {
        font-size: 0.9rem;
        padding: 0 20px 15px;
    }

    /* Mobile image responsiveness */
    .page-promotions img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-promotions__section,
    .page-promotions__card,
    .page-promotions__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-promotions__video-section { /* Although no video here, maintain structure */
        padding-top: 10px !important;
    }
}