/* style/resources.css */

/* General Page Styles */
.page-resources {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333333; /* Dark text for light body background */
    background-color: #ffffff; /* Explicitly set for content area */
}

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

.page-resources__container--center {
    text-align: center;
}

.page-resources__section {
    padding: 60px 0;
    margin-bottom: 20px;
}

.page-resources__section-title {
    font-size: 36px;
    color: #26A9E0;
    text-align: center;
    margin-bottom: 40px;
    font-weight: bold;
}

.page-resources__text-block {
    font-size: 17px;
    margin-bottom: 25px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-resources__text-block--center {
    text-align: center;
}

/* Color Scheme Application */
.page-resources__light-bg {
    background-color: #ffffff;
    color: #333333;
}

.page-resources__dark-bg {
    background-color: #26A9E0;
    color: #ffffff;
}

.page-resources__dark-bg .page-resources__section-title,
.page-resources__dark-bg .page-resources__card-title,
.page-resources__dark-bg .page-resources__feature-title,
.page-resources__dark-bg .page-resources__mobile-title {
    color: #ffffff; /* Ensure titles are white on dark background */
}

/* Hero Section */
.page-resources__hero-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    padding-top: var(--header-offset, 120px); /* Account for fixed header */
    background: linear-gradient(135deg, #26A9E0, #a9e0f5); /* Soft gradient background */
    overflow: hidden; /* Ensure image doesn't overflow */
}

.page-resources__hero-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.page-resources__hero-image {
    width: 100%;
    margin-bottom: 30px;
    max-width: 100%;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

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

.page-resources__hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
    padding: 0 20px;
}

.page-resources__main-title {
    font-size: 48px;
    color: #ffffff;
    margin-bottom: 20px;
    font-weight: 800;
    line-height: 1.2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.page-resources__intro-text {
    font-size: 20px;
    color: #f0f0f0;
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.page-resources__cta-button {
    display: inline-block;
    padding: 15px 40px;
    background: #EA7C07; /* Login color for CTA */
    color: #ffffff;
    text-decoration: none;
    border-radius: 8px;
    font-size: 20px;
    font-weight: bold;
    margin-top: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: none;
    cursor: pointer;
    max-width: 100%; /* Ensure responsiveness */
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
}

.page-resources__cta-button:hover {
    background: #d46b00;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.page-resources__cta-button--small {
    padding: 10px 25px;
    font-size: 16px;
    margin-top: 15px;
}

.page-resources__cta-button--large {
    padding: 20px 50px;
    font-size: 22px;
    margin-top: 40px;
}

.page-resources__image-full {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    margin-top: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Grid Layouts */
.page-resources__grid {
    display: grid;
    gap: 30px;
    margin-top: 40px;
}

.page-resources__grid--3-cols {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.page-resources__grid--2-cols {
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
}

/* Card Styles */
.page-resources__card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    color: #333333; /* Ensure text is dark on light card */
}

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

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

.page-resources__card-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.page-resources__card-title {
    font-size: 22px;
    font-weight: bold;
    margin: 0 0 10px 0;
    line-height: 1.3;
    color: #26A9E0; /* Brand color for titles */
}

.page-resources__card-title a {
    color: #26A9E0;
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-resources__card-title a:hover {
    color: #1a7bb5;
}

.page-resources__card-text {
    font-size: 16px;
    margin: 0 0 20px 0;
    flex-grow: 1; /* Make text block fill available space */
}

.page-resources__card-link {
    display: inline-block;
    padding: 10px 20px;
    background: #26A9E0;
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    align-self: flex-start; /* Align link to bottom-left */
    max-width: 100%; /* Ensure responsiveness */
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
}

.page-resources__card-link:hover {
    background: #1a7bb5;
}

/* Feature Row */
.page-resources__feature-row {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    margin-top: 40px;
}

.page-resources__feature-item {
    flex: 1 1 calc(33% - 30px); /* Three items per row, adjust for gap */
    max-width: calc(33% - 30px);
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    padding: 30px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box;
}

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

.page-resources__feature-image {
    width: 100%;
    height: auto;
    max-width: 250px; /* Constrain image size */
    display: block;
    margin: 0 auto 20px auto;
    border-radius: 8px;
    object-fit: cover;
}

.page-resources__feature-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #26A9E0;
}

.page-resources__feature-text {
    font-size: 16px;
    color: #555555;
}

/* Mobile Features */
.page-resources__mobile-features {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    margin-top: 40px;
}

.page-resources__mobile-item {
    flex: 1 1 calc(50% - 30px); /* Two items per row */
    max-width: calc(50% - 30px);
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    padding: 30px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box;
}

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

.page-resources__mobile-image {
    width: 100%;
    height: auto;
    max-width: 300px; /* Constrain image size */
    display: block;
    margin: 0 auto 20px auto;
    border-radius: 8px;
    object-fit: cover;
}

.page-resources__mobile-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #26A9E0;
}

.page-resources__mobile-text {
    font-size: 16px;
    color: #555555;
    margin-bottom: 20px;
}

/* News Cards */
.page-resources__news-card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    display: flex;
    flex-direction: row; /* Horizontal layout for news */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    color: #333333;
}

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

.page-resources__news-image {
    width: 40%; /* Image takes 40% of card width */
    height: auto;
    object-fit: cover;
    display: block;
    min-width: 200px; /* Minimum width for image */
}

.page-resources__news-content {
    width: 60%; /* Content takes 60% of card width */
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.page-resources__news-title {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 10px;
    line-height: 1.3;
}

.page-resources__news-title a {
    color: #26A9E0;
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-resources__news-title a:hover {
    color: #1a7bb5;
}

.page-resources__news-date {
    font-size: 14px;
    color: #888888;
    margin-bottom: 10px;
}

.page-resources__news-summary {
    font-size: 16px;
    margin-bottom: 15px;
}

/* Button Group */
.page-resources__button-group {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
    flex-wrap: wrap; /* Allow wrapping on small screens */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
    padding: 0 20px;
}

.page-resources__btn-primary,
.page-resources__btn-secondary {
    display: inline-block;
    padding: 12px 30px;
    font-size: 18px;
    font-weight: bold;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 2px solid;
    cursor: pointer;
    max-width: 100%; /* Ensure responsiveness */
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
}

.page-resources__btn-primary {
    background: #26A9E0;
    color: #ffffff;
    border-color: #26A9E0;
    box-shadow: 0 4px 10px rgba(38, 169, 224, 0.3);
}

.page-resources__btn-primary:hover {
    background: #1a7bb5;
    border-color: #1a7bb5;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(38, 169, 224, 0.4);
}

.page-resources__btn-secondary {
    background: #ffffff;
    color: #26A9E0;
    border-color: #26A9E0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.page-resources__btn-secondary:hover {
    background: #f0f8ff;
    color: #1a7bb5;
    border-color: #1a7bb5;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
}

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

.page-resources__faq-item {
    margin-bottom: 15px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.page-resources__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    cursor: pointer;
    user-select: none;
    transition: background-color 0.3s ease, border-color 0.3s ease;
    position: relative;
    color: #333333;
}

.page-resources__faq-question:hover {
    background: #f5f5f5;
    border-color: #d0d0d0;
}

.page-resources__faq-item.active .page-resources__faq-question {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    background-color: #f0f0f0;
}

.page-resources__faq-question h3 {
    margin: 0;
    padding: 0;
    flex: 1;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.5;
    pointer-events: none; /* Prevent h3 from blocking click */
    color: #26A9E0; /* Brand color for question titles */
}

.page-resources__faq-toggle {
    font-size: 28px;
    font-weight: bold;
    line-height: 1;
    color: #666;
    transition: transform 0.3s ease, color 0.3s ease;
    flex-shrink: 0;
    margin-left: 15px;
    pointer-events: none; /* Prevent icon from blocking click */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.page-resources__faq-item.active .page-resources__faq-toggle {
    color: #333;
    transform: rotate(45deg); /* Rotate for 'x' effect if using '+' initially */
}

.page-resources__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 25px;
    opacity: 0;
    background: #f9f9f9;
    color: #555555;
    font-size: 16px;
    line-height: 1.7;
}

.page-resources__faq-item.active .page-resources__faq-answer {
    max-height: 2000px !important; /* Sufficiently large value */
    padding: 20px 25px !important;
    opacity: 1;
    border: 1px solid #e0e0e0;
    border-top: none;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-resources__hero-image img {
        width: 100%;
        height: auto;
    }

    .page-resources__grid--2-cols {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    }

    .page-resources__feature-item,
    .page-resources__mobile-item {
        flex: 1 1 calc(50% - 30px);
        max-width: calc(50% - 30px);
    }

    .page-resources__news-card {
        flex-direction: column; /* Stack news card elements on smaller screens */
    }

    .page-resources__news-image,
    .page-resources__news-content {
        width: 100%;
        min-width: unset;
    }
    .page-resources__news-image {
        height: 250px; /* Adjust height for stacked images */
    }
}

@media (max-width: 768px) {
    .page-resources__hero-section {
        padding-top: var(--header-offset, 120px) !important;
        padding-bottom: 40px;
        padding-left: 15px;
        padding-right: 15px;
    }

    .page-resources__main-title {
        font-size: 36px;
    }

    .page-resources__intro-text {
        font-size: 18px;
    }

    .page-resources__section {
        padding: 40px 0;
    }

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

    .page-resources__text-block {
        font-size: 16px;
        margin-bottom: 20px;
    }

    .page-resources__container {
        padding: 0 15px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* Image responsiveness */
    .page-resources img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }

    .page-resources__section,
    .page-resources__card,
    .page-resources__container,
    .page-resources__news-card,
    .page-resources__feature-item,
    .page-resources__mobile-item {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-resources__card, .page-resources__news-card, .page-resources__feature-item, .page-resources__mobile-item {
        padding: 20px; /* Adjust internal padding */
    }

    .page-resources__grid {
        grid-template-columns: 1fr; /* Single column on mobile */
        gap: 20px;
    }
}