/* style/resources.css */

:root {
    --primary-color: #017439;
    --secondary-color: #FFFFFF;
    --text-dark: #333333;
    --text-light: #ffffff;
    --button-register: #C30808;
    --button-login: #C30808;
    --font-login-register: #FFFF00;
    --background-default: #FFFFFF;
}

.page-resources {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--background-default);
}

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

/* Hero Section */
.page-resources__hero-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 600px;
    padding: 100px 20px 40px;
    padding-top: var(--header-offset, 120px);
    background-color: var(--primary-color);
    color: var(--text-light);
    overflow: hidden;
}

.page-resources__hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.3;
    z-index: 0;
}

.page-resources__hero-section .page-resources__container {
    position: relative;
    z-index: 1;
}

.page-resources__hero-title {
    font-size: 3.5em;
    margin-bottom: 20px;
    line-height: 1.2;
    color: var(--font-login-register); /* Specific font color for title */
}

.page-resources__hero-description {
    font-size: 1.3em;
    margin-bottom: 40px;
    max-width: 800px;
    color: var(--text-light);
}

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

/* Buttons */
.page-resources__btn-primary,
.page-resources__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    white-space: nowrap;
    cursor: pointer;
    box-sizing: border-box;
}

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

.page-resources__btn-primary:hover {
    background-color: #a00606;
    border-color: #a00606;
}

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

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

.page-resources__btn-text {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-resources__btn-text:hover {
    color: var(--button-register);
}

.page-resources__btn-large {
    padding: 18px 35px;
    font-size: 1.1em;
}

.page-resources__btn-margin-top {
    margin-top: 30px;
}

/* Section General */
.page-resources__content-section {
    padding: 80px 0;
}

.page-resources__section-title {
    font-size: 2.5em;
    margin-bottom: 40px;
    text-align: center;
    color: var(--primary-color);
}

.page-resources__section-sub-title {
    font-size: 1.8em;
    margin-top: 40px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

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

.page-resources__paragraph {
    font-size: 1.1em;
    margin-bottom: 20px;
}

/* Background Colors */
.page-resources__light-bg {
    background-color: var(--background-default);
    color: var(--text-dark);
}

.page-resources__dark-bg {
    background-color: var(--primary-color);
    color: var(--text-light);
}

.page-resources__dark-bg .page-resources__section-title,
.page-resources__dark-bg .page-resources__sub-title,
.page-resources__dark-bg .page-resources__btn-text {
    color: var(--font-login-register);
}

.page-resources__dark-bg .page-resources__btn-secondary {
    color: var(--text-light);
    border-color: var(--text-light);
}

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

/* Images */
.page-resources__image-full-width {
    width: 100%;
    height: auto;
    display: block;
    margin: 40px 0;
    border-radius: 10px;
    object-fit: cover;
}

.page-resources__image-left {
    width: 100%;
    max-width: 500px;
    height: auto;
    display: block;
    float: left;
    margin-right: 30px;
    margin-bottom: 20px;
    border-radius: 10px;
    object-fit: cover;
}

.page-resources__image-right {
    width: 100%;
    max-width: 500px;
    height: auto;
    display: block;
    float: right;
    margin-left: 30px;
    margin-bottom: 20px;
    border-radius: 10px;
    object-fit: cover;
}

.page-resources__text-block {
    overflow: hidden; /* Clear floats */
    margin-bottom: 40px;
}

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

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

/* Cards */
.page-resources__card {
    background-color: var(--secondary-color);
    color: var(--text-dark);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3s ease;
}

.page-resources__dark-bg .page-resources__card {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
}

.page-resources__dark-bg .page-resources__card .page-resources__card-title,
.page-resources__dark-bg .page-resources__card p,
.page-resources__dark-bg .page-resources__card li {
    color: var(--text-light);
}

.page-resources__dark-bg .page-resources__card .page-resources__btn-text {
    color: var(--font-login-register);
}

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

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

.page-resources__dark-bg .page-resources__card-title {
    color: var(--font-login-register);
}

.page-resources__list {
    list-style: disc inside;
    margin-bottom: 20px;
    padding-left: 20px;
}

.page-resources__list li {
    margin-bottom: 10px;
}

/* CTA Section */
.page-resources__cta-section {
    background-color: var(--primary-color);
    color: var(--text-light);
    text-align: center;
    padding: 80px 20px;
}

.page-resources__cta-title {
    font-size: 2.8em;
    margin-bottom: 20px;
    color: var(--font-login-register);
}

.page-resources__cta-description {
    font-size: 1.2em;
    max-width: 900px;
    margin: 0 auto 40px;
    color: var(--text-light);
}

/* FAQ Section */
.page-resources__faq-section {
    margin-top: 60px;
    border-top: 1px solid #e0e0e0;
    padding-top: 40px;
}

.page-resources__faq-item {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    background-color: var(--secondary-color);
    color: var(--text-dark);
}

.page-resources__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    background-color: #f9f9f9;
    transition: background-color 0.3s ease;
    color: var(--primary-color);
}

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

.page-resources__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    transition: transform 0.3s ease;
    color: var(--primary-color);
}

.page-resources__faq-item.active .page-resources__faq-toggle {
    transform: rotate(45deg);
}

.page-resources__faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 20px;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.page-resources__faq-item.active .page-resources__faq-answer {
    max-height: 1000px !important; /* Ensure it expands sufficiently */
    padding: 20px;
    padding-top: 0;
}

.page-resources__faq-answer p {
    margin-bottom: 0;
    font-size: 1.1em;
    color: var(--text-dark);
}

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

    .page-resources__hero-description {
        font-size: 1.1em;
    }

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

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

    .page-resources__image-left,
    .page-resources__image-right {
        float: none;
        margin: 20px auto;
        max-width: 80%;
    }

    .page-resources__text-block {
        overflow: visible;
    }
}

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

    .page-resources__hero-section {
        min-height: 500px;
        padding: 80px 15px 30px;
        padding-top: var(--header-offset, 120px) !important; /* Ensure header offset on mobile */
    }

    .page-resources__hero-title {
        font-size: 2.2em;
    }

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

    .page-resources__hero-buttons {
        flex-direction: column;
        gap: 15px;
    }

    .page-resources__btn-primary,
    .page-resources__btn-secondary {
        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-resources__content-section {
        padding: 40px 0;
    }

    .page-resources__section-title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }

    .page-resources__sub-title {
        font-size: 1.2em;
    }

    .page-resources__paragraph {
        font-size: 1em;
    }

    .page-resources__card {
        padding: 20px;
    }

    .page-resources__card-title {
        font-size: 1.4em;
    }

    .page-resources__grid-3-columns,
    .page-resources__grid-2-columns {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-resources__image-full-width,
    .page-resources__image-left,
    .page-resources__image-right {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        margin: 20px auto !important;
        float: none !important;
    }

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

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

    /* Ensure all content containers are constrained */
    .page-resources__section,
    .page-resources__card,
    .page-resources__container,
    .page-resources__hero-section,
    .page-resources__content-section,
    .page-resources__cta-section,
    .page-resources__faq-section,
    .page-resources__hero-buttons,
    .page-resources__grid-3-columns,
    .page-resources__grid-2-columns {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow-x: hidden !important;
    }
    
    .page-resources__hero-section {
        padding-left: 0;
        padding-right: 0;
    }
    .page-resources__hero-section .page-resources__container {
        padding-left: 15px;
        padding-right: 15px;
    }

    /* FAQ specific for mobile */
    .page-resources__faq-question {
        font-size: 1em;
        padding: 15px;
    }

    .page-resources__faq-answer {
        padding: 0 15px;
    }

    .page-resources__faq-item.active .page-resources__faq-answer {
        padding: 15px;
        padding-top: 0;
    }
}