/* style/promotions.css */

/* Base Styles */
.page-promotions {
    color: #f0f0f0; /* Light text for dark body background */
    background-color: #000; /* Ensure consistency with body background */
    font-family: Arial, sans-serif;
    line-height: 1.6;
}

.page-promotions__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

.page-promotions__section-title {
    font-size: 36px;
    color: #FFD700; /* Gold for titles */
    text-align: center;
    margin-bottom: 30px;
    font-weight: 700;
    line-height: 1.2;
}

.page-promotions__section-description {
    font-size: 18px;
    text-align: center;
    margin-bottom: 40px;
    color: #cccccc;
}

/* Buttons */
.page-promotions__btn-primary,
.page-promotions__btn-secondary {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
    max-width: 100%;
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
}

.page-promotions__btn-primary {
    background-color: #FFD700;
    color: #000000; /* Black text for gold button */
    border: 2px solid #FFD700;
}

.page-promotions__btn-primary:hover {
    background-color: #e6c200;
    border-color: #e6c200;
}

.page-promotions__btn-secondary {
    background-color: transparent;
    color: #FFD700;
    border: 2px solid #FFD700;
}

.page-promotions__btn-secondary:hover {
    background-color: #FFD700;
    color: #000000;
}

/* Hero Section */
.page-promotions__hero-section {
    position: relative;
    padding-top: var(--header-offset, 120px); /* Adjust based on shared.css body padding */
    padding-bottom: 60px;
    background: linear-gradient(to right, #8B0000, #4a0000); /* Dark red gradient */
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
    gap: 40px;
    text-align: center;
}

/* If shared.css already sets body padding-top, set hero-section padding-top to 0 */
body.has-header-offset .page-promotions__hero-section {
    padding-top: 0;
}

.page-promotions__hero-content {
    flex: 1;
    min-width: 300px;
    max-width: 600px;
    padding: 20px;
    box-sizing: border-box;
}

.page-promotions__hero-title {
    font-size: 48px;
    color: #FFD700;
    margin-bottom: 20px;
    line-height: 1.2;
    font-weight: 800;
}

.page-promotions__hero-description {
    font-size: 20px;
    color: #f0f0f0;
    margin-bottom: 30px;
    line-height: 1.5;
}

.page-promotions__hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.page-promotions__hero-image-wrapper {
    flex: 1;
    min-width: 400px;
    max-width: 800px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}

.page-promotions__hero-image {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    display: block;
}

/* Overview Section */
.page-promotions__overview-section {
    padding: 80px 0;
    background-color: #0d0d0d; /* Slightly lighter dark background */
}

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

.page-promotions__promo-card {
    background-color: #1a1a1a;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.page-promotions__promo-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
}

.page-promotions__promo-card-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    min-height: 200px; /* Ensure minimum height */
}

.page-promotions__promo-card-title {
    font-size: 24px;
    color: #FFD700;
    margin: 20px 20px 10px;
    font-weight: 600;
}

.page-promotions__promo-card-text {
    font-size: 16px;
    color: #cccccc;
    padding: 0 20px 20px;
    flex-grow: 1;
}

.page-promotions__promo-card-link {
    display: block;
    text-align: center;
    padding: 12px 20px;
    background-color: #8B0000; /* Dark red for CTA */
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s ease;
    border-radius: 0 0 10px 10px;
}

.page-promotions__promo-card-link:hover {
    background-color: #a00000;
}

/* Details Section */
.page-promotions__details-section {
    padding: 80px 0;
    background-color: #8B0000; /* Main dark red background */
    color: #ffffff;
}

.page-promotions__details-section .page-promotions__section-title {
    color: #FFD700; /* Gold title on dark red background */
}

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

.page-promotions__feature-item {
    background-color: rgba(0, 0, 0, 0.3); /* Semi-transparent dark background */
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    transition: background-color 0.3s ease;
}

.page-promotions__feature-item:hover {
    background-color: rgba(0, 0, 0, 0.5);
}

.page-promotions__feature-icon {
    width: 100px;
    height: auto;
    margin: 0 auto 20px;
    display: block;
    border-radius: 5px;
    object-fit: cover;
    min-height: 100px; /* Ensure minimum height */
}

.page-promotions__feature-title {
    font-size: 22px;
    color: #FFD700;
    margin-bottom: 10px;
    font-weight: 600;
}

.page-promotions__feature-text {
    font-size: 16px;
    color: #f0f0f0;
}

.page-promotions__cta-buttons-center {
    text-align: center;
}

/* How to Claim Section */
.page-promotions__how-to-claim {
    padding: 80px 0;
    background-color: #000; /* Dark background */
}

.page-promotions__steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.page-promotions__step-item {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.page-promotions__step-icon {
    width: 60px;
    height: 60px;
    line-height: 60px;
    margin: 0 auto 20px;
    background-color: #FFD700;
    color: #000;
    border-radius: 50%;
    font-size: 30px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.page-promotions__step-title {
    font-size: 22px;
    color: #FFD700;
    margin-bottom: 10px;
    font-weight: 600;
}

.page-promotions__step-text {
    font-size: 16px;
    color: #cccccc;
}

/* Terms Section */
.page-promotions__terms-section {
    padding: 80px 0;
    background-color: #8B0000; /* Dark red background */
    color: #ffffff;
}

.page-promotions__terms-section .page-promotions__section-title {
    color: #FFD700;
}

.page-promotions__terms-content {
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    padding: 40px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    text-align: left;
}

.page-promotions__terms-content p {
    font-size: 18px;
    margin-bottom: 20px;
    color: #f0f0f0;
}

.page-promotions__terms-list {
    list-style: disc;
    padding-left: 25px;
    margin-bottom: 30px;
    color: #f0f0f0;
}

.page-promotions__terms-list li {
    margin-bottom: 10px;
    font-size: 16px;
}

/* FAQ Section */
.page-promotions__faq-section {
    padding: 80px 0;
    background-color: #0d0d0d; /* Slightly lighter dark background */
    color: #f0f0f0;
}

.page-promotions__faq-list {
    max-width: 900px;
    margin: 0 auto;
}

/* FAQ容器样式 */
.page-promotions__faq-item {
    margin-bottom: 15px;
    border-radius: 5px;
    overflow: hidden;
    background-color: #1a1a1a; /* Darker background for FAQ item */
}

/* FAQ默认状态 - 答案隐藏 */
.page-promotions__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; /* Adjusted padding for better visual */
    opacity: 0;
    color: #cccccc;
}

/* FAQ展开状态 - 🚨 使用!important和足够大的max-height确保一定能展开 */
.page-promotions__faq-item.active .page-promotions__faq-answer {
    max-height: 2000px !important; /* 🚨 使用!important确保优先级，值足够大以容纳任何内容 */
    padding: 20px !important; /* Adjusted padding for better visual */
    opacity: 1;
    background: #2a2a2a; /* Slightly lighter background for active answer */
    border-radius: 0 0 5px 5px;
}

/* 问题样式 */
.page-promotions__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 20px;
    background: #1a1a1a; /* Dark background for question */
    border: 1px solid #333333; /* Darker border */
    border-radius: 5px;
    cursor: pointer;
    user-select: none;
    transition: background-color 0.3s ease, border-color 0.3s ease;
    position: relative;
}

.page-promotions__faq-question:hover {
    background: #2a2a2a;
    border-color: #444444;
}

.page-promotions__faq-question:active {
    background: #3a3a3a;
}

/* 问题标题样式 */
.page-promotions__faq-question h3 {
    margin: 0;
    padding: 0;
    flex: 1;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.5;
    pointer-events: none; /* 防止h3标签阻止点击事件 */
    color: #FFD700; /* Gold color for FAQ question title */
}

/* 切换图标 */
.page-promotions__faq-toggle {
    font-size: 24px;
    font-weight: bold;
    line-height: 1;
    color: #FFD700; /* Gold color for toggle icon */
    transition: transform 0.3s ease, color 0.3s ease;
    flex-shrink: 0;
    margin-left: 15px;
    pointer-events: none; /* 防止图标阻止点击事件 */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
}

.page-promotions__faq-item.active .page-promotions__faq-toggle {
    color: #ffffff; /* White color when active */
    transform: rotate(45deg); /* Rotate for minus sign */
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .page-promotions__hero-title {
        font-size: 40px;
    }

    .page-promotions__hero-description {
        font-size: 18px;
    }

    .page-promotions__section-title {
        font-size: 32px;
    }
}

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

    .page-promotions__container {
        padding: 0 15px;
    }

    .page-promotions__hero-section {
        flex-direction: column;
        padding-top: var(--header-offset, 120px) !important; /* Ensure padding-top is applied if shared doesn't do it */
        padding-bottom: 40px;
        gap: 20px;
    }
    /* If shared.css already sets body padding-top, set hero-section padding-top to 0 */
    body.has-header-offset .page-promotions__hero-section {
        padding-top: 0 !important;
    }

    .page-promotions__hero-content,
    .page-promotions__hero-image-wrapper {
        min-width: unset;
        max-width: 100%;
        padding: 0;
    }

    .page-promotions__hero-title {
        font-size: 32px;
        margin-bottom: 15px;
    }

    .page-promotions__hero-description {
        font-size: 16px;
        margin-bottom: 20px;
    }

    .page-promotions__hero-buttons {
        flex-direction: column;
        gap: 10px;
    }

    /* Mobile button responsiveness */
    .page-promotions__btn-primary,
    .page-promotions__btn-secondary,
    .page-promotions a[class*="button"],
    .page-promotions a[class*="btn"] {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    .page-promotions__hero-buttons,
    .page-promotions__cta-buttons-center {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        flex-wrap: wrap !important;
        gap: 10px;
    }

    .page-promotions__section-title {
        font-size: 28px;
        margin-bottom: 20px;
    }

    .page-promotions__section-description {
        font-size: 16px;
        margin-bottom: 30px;
    }

    .page-promotions__overview-section,
    .page-promotions__details-section,
    .page-promotions__how-to-claim,
    .page-promotions__terms-section,
    .page-promotions__faq-section {
        padding: 40px 0;
    }

    .page-promotions__promo-grid,
    .page-promotions__feature-grid,
    .page-promotions__steps-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-promotions__promo-card-image,
    .page-promotions__feature-icon {
        min-height: 150px;
    }

    .page-promotions__promo-card-title,
    .page-promotions__feature-title,
    .page-promotions__step-title {
        font-size: 20px;
    }

    .page-promotions__promo-card-text,
    .page-promotions__feature-text,
    .page-promotions__step-text,
    .page-promotions__terms-content p,
    .page-promotions__terms-list li {
        font-size: 15px;
    }

    .page-promotions__terms-content {
        padding: 25px;
    }

    /* FAQ Mobile */
    .page-promotions__faq-question {
        padding: 15px;
        flex-wrap: wrap;
    }
    
    .page-promotions__faq-question h3 {
        font-size: 16px;
        margin-bottom: 0;
        width: calc(100% - 40px);
        color: #FFD700;
    }
    
    .page-promotions__faq-toggle {
        margin-left: 10px;
        width: 24px;
        height: 24px;
        font-size: 20px;
        color: #FFD700;
    }
    
    .page-promotions__faq-answer {
        padding: 0 15px;
    }
    
    .page-promotions__faq-item.active .page-promotions__faq-answer {
        padding: 15px !important;
    }

    /* Image responsiveness */
    .page-promotions img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        box-sizing: border-box !important;
    }
    
    .page-promotions__hero-image-wrapper,
    .page-promotions__promo-card,
    .page-promotions__feature-item,
    .page-promotions__step-item,
    .page-promotions__terms-content,
    .page-promotions__faq-list {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
}