/* style/promotions.css */

:root {
    --primary-color: #017439;
    --secondary-color: #FFFFFF;
    --register-button-bg: #C30808;
    --login-button-bg: #C30808;
    --register-login-font-color: #FFFF00;
    --text-color-dark: #333333;
    --text-color-light: #FFFFFF;
    --card-bg: #FFFFFF;
    --border-color: #e0e0e0;
}

.page-promotions {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color-dark);
    background-color: var(--background-color, var(--secondary-color)); /* Default to white if not set by shared */
}

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

/* HERO Section */
.page-promotions__hero-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: var(--primary-color);
    color: var(--text-color-light);
    padding: 0; /* Assuming shared.css handles body padding-top */
    position: relative;
    overflow: hidden;
    min-height: 500px;
}

.page-promotions__hero-content {
    flex: 1;
    padding: 60px 40px;
    z-index: 1;
    max-width: 50%;
}

.page-promotions__hero-title {
    font-size: 3.2em;
    margin-bottom: 20px;
    line-height: 1.2;
    color: var(--text-color-light);
}

.page-promotions__hero-description {
    font-size: 1.1em;
    margin-bottom: 30px;
}

.page-promotions__hero-cta {
    display: flex;
    gap: 15px;
}

.page-promotions__hero-image {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 50%;
}

.page-promotions__hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* General Buttons */
.page-promotions__btn-primary,
.page-promotions__btn-secondary,
.page-promotions__card-button {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    text-align: center;
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
}

.page-promotions__btn-primary {
    background-color: var(--register-button-bg);
    color: var(--register-login-font-color);
    border: 2px solid var(--register-button-bg);
}

.page-promotions__btn-primary:hover {
    background-color: darken(var(--register-button-bg), 10%);
    border-color: darken(var(--register-button-bg), 10%);
}

.page-promotions__btn-secondary {
    background-color: transparent;
    color: var(--text-color-light);
    border: 2px solid var(--text-color-light);
}

.page-promotions__btn-secondary:hover {
    background-color: var(--text-color-light);
    color: var(--primary-color);
}

.page-promotions__card-button {
    background-color: var(--primary-color);
    color: var(--text-color-light);
    border: 2px solid var(--primary-color);
    margin-top: 15px;
}

.page-promotions__card-button:hover {
    background-color: darken(var(--primary-color), 10%);
    border-color: darken(var(--primary-color), 10%);
}

/* Section Titles & Descriptions */
.page-promotions__section-title {
    font-size: 2.5em;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 20px;
    margin-top: 60px;
}

.page-promotions__section-description {
    font-size: 1.1em;
    text-align: center;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Featured Promos Section */
.page-promotions__featured-promos-section {
    padding: 60px 0;
    background-color: var(--background-color, var(--secondary-color));
}

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

.page-promotions__promo-card {
    background-color: var(--card-bg);
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    text-align: left;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.page-promotions__promo-card:hover {
    transform: translateY(-5px);
}

.page-promotions__promo-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.page-promotions__promo-card .page-promotions__card-title {
    font-size: 1.5em;
    margin: 20px 20px 10px 20px;
    color: var(--primary-color);
}

.page-promotions__promo-card .page-promotions__card-title a {
    text-decoration: none;
    color: inherit;
}

.page-promotions__promo-card .page-promotions__card-title a:hover {
    text-decoration: underline;
}

.page-promotions__promo-card .page-promotions__card-description {
    font-size: 0.95em;
    color: #666;
    padding: 0 20px;
    flex-grow: 1;
}

.page-promotions__promo-card .page-promotions__card-button {
    margin: 20px;
}

/* Benefits Section */
.page-promotions__benefits-section {
    padding: 80px 0;
    background-color: var(--primary-color);
    color: var(--text-color-light);
}

.page-promotions__benefits-section .page-promotions__section-title {
    color: var(--text-color-light);
}

.page-promotions__benefits-section .page-promotions__section-description {
    color: var(--text-color-light);
}

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

.page-promotions__benefit-item {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 10px;
    text-align: center;
}

.page-promotions__benefit-title {
    font-size: 1.8em;
    margin-bottom: 15px;
    color: var(--text-color-light);
}

.page-promotions__benefit-description {
    font-size: 1em;
    color: var(--text-color-light);
}

/* Terms Section */
.page-promotions__terms-section {
    padding: 60px 0;
    background-color: var(--background-color, var(--secondary-color));
}

.page-promotions__terms-list {
    list-style-type: disc;
    padding-left: 40px;
    margin-top: 30px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-promotions__term-item {
    margin-bottom: 15px;
    font-size: 1em;
    color: #555;
}

.page-promotions__terms-cta {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 50px;
}

/* FAQ Section */
.page-promotions__faq-section {
    padding: 60px 0;
    background-color: #f9f9f9;
}

.page-promotions__faq-list {
    margin-top: 40px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-promotions__faq-item {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
}

.page-promotions__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    font-size: 1.1em;
    font-weight: bold;
    color: var(--primary-color);
    cursor: pointer;
    background-color: var(--card-bg);
    transition: background-color 0.3s ease;
}

.page-promotions__faq-question:hover {
    background-color: #f0f0f0;
}

.page-promotions__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    transition: transform 0.3s ease;
}

.page-promotions__faq-item.active .page-promotions__faq-toggle {
    transform: rotate(45deg); /* Plus sign rotates to form an X or minus */
}

.page-promotions__faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 25px;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
    color: #555;
}

.page-promotions__faq-item.active .page-promotions__faq-answer {
    max-height: 1000px !important; /* Sufficiently large to show content */
    padding: 15px 25px 25px 25px;
}

/* Call to Action Section */
.page-promotions__cta-section {
    padding: 80px 0;
    background-color: var(--primary-color);
    color: var(--text-color-light);
    text-align: center;
}

.page-promotions__cta-section .page-promotions__section-title {
    color: var(--text-color-light);
}

.page-promotions__cta-section .page-promotions__section-description {
    color: var(--text-color-light);
    margin-bottom: 40px;
}

.page-promotions__cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.page-promotions__btn-register {
    background-color: var(--register-button-bg);
    color: var(--register-login-font-color);
    border-color: var(--register-button-bg);
}

.page-promotions__btn-register:hover {
    background-color: darken(var(--register-button-bg), 10%);
    border-color: darken(var(--register-button-bg), 10%);
}

.page-promotions__btn-login {
    background-color: var(--login-button-bg);
    color: var(--register-login-font-color);
    border-color: var(--login-button-bg);
}

.page-promotions__btn-login:hover {
    background-color: darken(var(--login-button-bg), 10%);
    border-color: darken(var(--login-button-bg), 10%);
}

/* --- Responsive Styles --- */

/* Tablet & Smaller Desktops */
@media (max-width: 1024px) {
    .page-promotions__hero-section {
        flex-direction: column;
        text-align: center;
        min-height: auto;
        padding-bottom: 40px;
    }

    .page-promotions__hero-content {
        max-width: 90%;
        padding: 40px 20px;
        order: 2;
    }

    .page-promotions__hero-title {
        font-size: 2.5em;
    }

    .page-promotions__hero-image {
        position: relative;
        width: 100%;
        height: 350px;
        margin-top: 20px;
        order: 1;
    }

    .page-promotions__hero-cta {
        justify-content: center;
    }

    .page-promotions__section-title {
        font-size: 2em;
    }

    .page-promotions__section-description {
        font-size: 1em;
    }

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

    .page-promotions__benefits-list {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }

    .page-promotions__terms-list {
        padding-left: 20px;
    }
}

/* Mobile Styles */
@media (max-width: 768px) {
    .page-promotions__hero-section {
        padding-top: 0; /* Assuming shared.css handles body padding-top */
    }

    .page-promotions__hero-content {
        max-width: 100%;
        padding: 30px 15px;
    }

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

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

    .page-promotions__hero-cta {
        flex-direction: column;
        gap: 10px;
        padding: 0 15px;
        width: 100%;
        box-sizing: border-box;
    }

    .page-promotions__hero-image {
        height: 250px;
        margin-top: 15px;
    }

    /* General Images & Containers */
    .page-promotions img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block;
    }

    .page-promotions__section,
    .page-promotions__card,
    .page-promotions__container,
    .page-promotions__promo-card {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow-x: hidden;
    }

    .page-promotions__section-title {
        font-size: 1.8em;
        margin-top: 40px;
        margin-bottom: 15px;
        padding: 0 15px;
    }

    .page-promotions__section-description {
        font-size: 0.9em;
        margin-bottom: 30px;
        padding: 0 15px;
    }

    /* Product/Promotions Grid for mobile */
    .page-promotions__promos-grid {
        grid-template-columns: 1fr; /* Stack cards vertically */
        gap: 20px;
        padding: 0 15px;
    }

    .page-promotions__promo-card {
        margin: 0 auto;
        padding: 0;
    }

    .page-promotions__promo-card img {
        height: 200px;
    }

    .page-promotions__promo-card .page-promotions__card-title {
        font-size: 1.3em;
        margin: 15px 15px 8px 15px;
    }

    .page-promotions__promo-card .page-promotions__card-description {
        font-size: 0.9em;
        padding: 0 15px;
    }

    .page-promotions__promo-card .page-promotions__card-button {
        margin: 15px;
        width: calc(100% - 30px);
    }

    /* Benefits Section */
    .page-promotions__benefits-section {
        padding: 40px 0;
    }

    .page-promotions__benefits-list {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 0 15px;
    }

    .page-promotions__benefit-item {
        padding: 20px;
    }

    .page-promotions__benefit-title {
        font-size: 1.5em;
    }

    /* Terms Section */
    .page-promotions__terms-section {
        padding: 40px 0;
    }

    .page-promotions__terms-list {
        padding-left: 20px;
        padding-right: 15px;
        margin-top: 20px;
    }

    .page-promotions__term-item {
        font-size: 0.9em;
    }

    .page-promotions__terms-cta {
        flex-direction: column;
        gap: 10px;
        margin-top: 30px;
        padding: 0 15px;
    }

    /* FAQ Section */
    .page-promotions__faq-section {
        padding: 40px 0;
    }

    .page-promotions__faq-list {
        margin-top: 30px;
        padding: 0 15px;
    }

    .page-promotions__faq-question {
        padding: 15px 20px;
        font-size: 1em;
    }

    .page-promotions__faq-answer {
        padding: 0 20px;
    }

    .page-promotions__faq-item.active .page-promotions__faq-answer {
        padding: 10px 20px 20px 20px;
    }

    /* CTA Section */
    .page-promotions__cta-section {
        padding: 40px 0;
    }

    .page-promotions__cta-buttons {
        flex-direction: column;
        gap: 10px;
        padding: 0 15px;
    }

    /* Buttons mobile */
    .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__cta-buttons,
    .page-promotions__button-group,
    .page-promotions__btn-container {
        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__cta-buttons {
        display: flex;
        flex-direction: column !important; /* Force vertical stacking for CTA buttons */
    }
}