/* style/resources.css */

:root {
    --primary-color: #1A202C;
    --secondary-color: #FFD700;
    --text-on-dark: #ffffff;
    --text-on-light: #333333;
    --light-background: #f8f9fa;
    --card-background-dark: rgba(255, 255, 255, 0.08);
    --card-background-light: #ffffff;
    --border-color: #e0e0e0;
}

.page-resources {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: var(--text-on-dark); /* Default text color for dark body background */
    background-color: var(--primary-color);
    padding-top: var(--header-offset, 120px); /* Ensure content is below fixed header */
}

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

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

.page-resources__light-bg {
    background-color: var(--light-background);
    color: var(--text-on-light);
}

/* Hero Section */
.page-resources__hero-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 80px 0;
    gap: 40px;
    flex-wrap: wrap;
}

.page-resources__hero-content {
    flex: 1;
    min-width: 300px;
    max-width: 600px;
    text-align: left;
    padding-left: 20px;
}

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

.page-resources__hero-description {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: var(--text-on-dark);
}

.page-resources__cta-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.page-resources__btn-primary,
.page-resources__btn-secondary,
.page-resources__btn-link {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    text-align: center;
    white-space: normal;
    word-wrap: break-word;
    box-sizing: border-box;
}

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

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

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

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

.page-resources__btn-link {
    background-color: transparent;
    color: var(--secondary-color);
    border: 1px solid var(--secondary-color);
    padding: 8px 15px;
    font-size: 0.9em;
}

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

.page-resources__hero-image-wrapper {
    flex: 1;
    min-width: 400px;
    max-width: 700px;
    text-align: right;
}

.page-resources__hero-image {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

/* General Section Styles */
.page-resources__introduction-section,
.page-resources__guides-section,
.page-resources__strategies-section,
.page-resources__policies-section,
.page-resources__faq-section,
.page-resources__contact-cta-section {
    padding: 60px 0;
}

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

.page-resources__introduction-section .page-resources__section-title {
    color: var(--text-on-dark);
}

.page-resources__text-block {
    font-size: 1.1em;
    text-align: center;
    max-width: 900px;
    margin: 0 auto 30px auto;
    line-height: 1.8;
}

.page-resources__introduction-section .page-resources__text-block {
    color: var(--text-on-dark);
}

.page-resources__guides-section .page-resources__section-title,
.page-resources__policies-section .page-resources__section-title,
.page-resources__faq-section .page-resources__section-title {
    color: var(--primary-color);
}

.page-resources__guides-section .page-resources__text-block,
.page-resources__policies-section .page-resources__text-block,
.page-resources__faq-section .page-resources__text-block {
    color: var(--text-on-light);
}

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

.page-resources__guide-card,
.page-resources__policy-card {
    background-color: var(--card-background-light);
    color: var(--text-on-light);
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 30px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-height: 450px; /* Ensure cards have similar height */
}

.page-resources__guide-card:hover,
.page-resources__policy-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.page-resources__card-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 20px;
    object-fit: cover;
    width: 100%;
    min-height: 200px;
}

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

.page-resources__card-title a {
    color: var(--primary-color);
    text-decoration: none;
}

.page-resources__card-title a:hover {
    color: var(--secondary-color);
}

.page-resources__card-description {
    font-size: 1em;
    line-height: 1.7;
    margin-bottom: 20px;
    flex-grow: 1;
}

/* Strategy List */
.page-resources__strategy-list {
    list-style: none;
    padding: 0;
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.page-resources__strategy-item {
    display: flex;
    align-items: center;
    background-color: var(--card-background-dark);
    color: var(--text-on-dark);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    gap: 30px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-resources__strategy-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.page-resources__list-image {
    width: 300px;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

.page-resources__list-content {
    flex-grow: 1;
}

.page-resources__list-title {
    font-size: 1.8em;
    margin-bottom: 10px;
    color: var(--secondary-color);
}

.page-resources__list-title a {
    color: var(--secondary-color);
    text-decoration: none;
}

.page-resources__list-title a:hover {
    color: var(--text-on-dark);
}

.page-resources__list-description {
    font-size: 1.1em;
    line-height: 1.7;
}

/* FAQ Section */
.page-resources__faq-list {
    margin-top: 40px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-resources__faq-item {
    background-color: var(--card-background-light);
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.page-resources__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    font-size: 1.2em;
    font-weight: bold;
    color: var(--primary-color);
    cursor: pointer;
    background-color: #ffffff;
    border-bottom: 1px solid var(--border-color);
}

.page-resources__faq-question:hover {
    background-color: var(--light-background);
}

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

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

.page-resources__faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 25px;
    transition: max-height 0.3s ease, padding 0.3s ease;
    color: var(--text-on-light);
    background-color: #ffffff;
}

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

/* Contact CTA Section */
.page-resources__contact-cta-section {
    text-align: center;
    padding: 80px 0;
}

.page-resources__contact-cta-section .page-resources__section-title {
    color: var(--secondary-color);
}

.page-resources__contact-cta-section .page-resources__text-block {
    color: var(--text-on-dark);
    margin-bottom: 40px;
}


/* Responsive Design */
@media (max-width: 1024px) {
    .page-resources__hero-section {
        flex-direction: column;
        text-align: center;
        padding: 60px 0;
    }

    .page-resources__hero-content {
        padding-left: 0;
        max-width: 100%;
    }

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

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

    .page-resources__hero-image-wrapper {
        text-align: center;
        margin-top: 40px;
        min-width: unset;
        max-width: 100%;
    }

    .page-resources__strategy-item {
        flex-direction: column;
        text-align: center;
    }

    .page-resources__list-image {
        margin-bottom: 20px;
        width: 100%;
        height: auto;
        max-height: 250px;
    }
}

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

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

    .page-resources__hero-section {
        padding: 40px 0;
    }

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

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

    .page-resources__cta-buttons {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }

    .page-resources__btn-primary,
    .page-resources__btn-secondary,
    .page-resources__btn-link {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 15px;
        font-size: 1em;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

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

    .page-resources__text-block {
        font-size: 1em;
    }

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

    .page-resources__guide-card, .page-resources__policy-card {
        padding: 20px;
        min-height: unset;
    }

    .page-resources__card-image {
        min-height: 180px;
    }

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

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

    .page-resources__list-image {
        width: 100%;
        height: auto;
        min-height: 180px;
    }

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

    .page-resources__faq-question {
        font-size: 1.1em;
        padding: 15px 20px;
    }

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

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

    /* Images responsive */
    .page-resources img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    
    .page-resources__hero-image-wrapper,
    .page-resources__grid-container,
    .page-resources__guide-card,
    .page-resources__policy-card,
    .page-resources__strategy-item,
    .page-resources__list-content,
    .page-resources__faq-list,
    .page-resources__faq-item,
    .page-resources__contact-cta-section .page-resources__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow-x: hidden !important; /* Prevent horizontal scroll */
    }

    /* Specific padding for sections if needed to avoid double padding */
    .page-resources__introduction-section .page-resources__container,
    .page-resources__guides-section .page-resources__container,
    .page-resources__strategies-section .page-resources__container,
    .page-resources__policies-section .page-resources__container,
    .page-resources__faq-section .page-resources__container {
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Ensure content area images are not too small */
    .page-resources__guide-card .page-resources__card-image,
    .page-resources__strategy-item .page-resources__list-image {
        min-width: 200px;
        min-height: 200px;
    }

    /* Fixed header offset for mobile, if not handled by shared */
    .page-resources__hero-section {
        padding-top: var(--header-offset, 120px) !important; /* Ensure hero is below header */
    }
}

/* Ensure all links have proper color contrast */
.page-resources a {
    color: var(--secondary-color);
    text-decoration: underline;
}

.page-resources a:hover {
    color: darken(var(--secondary-color), 15%);
}

.page-resources__card-title a {
    color: var(--primary-color);
}

.page-resources__card-title a:hover {
    color: var(--secondary-color);
}

.page-resources__list-title a {
    color: var(--secondary-color);
}

.page-resources__list-title a:hover {
    color: var(--text-on-dark);
}

/* Contrast fixes */
.page-resources__contrast-fix {
  background: #ffffff !important;
  color: #333333 !important;
  border: 1px solid #e0e0e0 !important;
}

.page-resources__text-contrast-fix {
  color: #333333 !important;
  text-shadow: none !important;
}