/* style/resources.css */

/* --- General Styles --- */
.page-resources {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333333; /* Default text color for light background */
    background-color: var(--secondary-color, #FFFFFF); /* Body background is light */
}

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

.page-resources__section-title {
    font-size: 36px;
    font-weight: bold;
    color: var(--primary-color, #26A9E0);
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    padding-bottom: 15px;
}

.page-resources__section-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--primary-color, #26A9E0);
    border-radius: 2px;
}

.page-resources__section-title--white {
    color: #ffffff;
}

.page-resources__section-title--white::after {
    background-color: #ffffff;
}

.page-resources__text-block {
    font-size: 18px;
    text-align: center;
    margin-bottom: 40px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-resources__cta-button {
    display: inline-block;
    padding: 15px 40px;
    background: var(--primary-color, #26A9E0);
    color: #ffffff;
    text-decoration: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    margin-top: 30px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.page-resources__cta-button:hover {
    background: #1e87c0; /* Slightly darker primary color */
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-resources__btn-secondary {
    display: inline-block;
    padding: 10px 25px;
    background: #ffffff;
    color: var(--primary-color, #26A9E0);
    text-decoration: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: bold;
    border: 2px solid var(--primary-color, #26A9E0);
    transition: all 0.3s ease;
}

.page-resources__btn-secondary:hover {
    background: var(--primary-color, #26A9E0);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* --- 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); /* Ensure space below fixed header */
    background: linear-gradient(135deg, var(--primary-color, #26A9E0), #FFFFFF);
    color: #ffffff;
    overflow: hidden; /* Prevent content overflow */
}

.page-resources__hero-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1; /* Ensure content is above background effects */
}

.page-resources__hero-image {
    width: 100%;
    margin-bottom: 30px;
}

.page-resources__hero-image img {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.page-resources__hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
    color: #ffffff; /* Text color for hero content */
}

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

.page-resources__description {
    font-size: 22px;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    color: #f0f8ff;
}

/* --- Intro Section --- */
.page-resources__intro-section {
    padding: 80px 0;
    background-color: var(--secondary-color, #FFFFFF);
    color: #333333;
}

/* --- Guides Section --- */
.page-resources__guides-section {
    padding: 80px 0;
    background-color: var(--primary-color, #26A9E0);
    color: #ffffff;
}

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

.page-resources__guide-card {
    background-color: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.page-resources__guide-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

.page-resources__guide-card img {
    width: 100%;
    height: 250px; /* Fixed height for consistency */
    object-fit: cover;
    display: block;
}

.page-resources__card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.page-resources__card-title {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 15px;
    line-height: 1.3;
}

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

.page-resources__card-title a:hover {
    color: #1e87c0; /* Darker blue on hover */
}

.page-resources__card-description {
    font-size: 16px;
    color: #666666;
    margin-bottom: 20px;
}

/* --- Tips Section --- */
.page-resources__tips-section {
    padding: 80px 0;
    background-color: #f8f9fa; /* Light gray background */
    color: #333333;
}

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

.page-resources__tip-item {
    background-color: #ffffff;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-resources__tip-title {
    font-size: 24px;
    font-weight: bold;
    color: var(--primary-color, #26A9E0);
    margin-bottom: 15px;
}

.page-resources__tip-item p {
    font-size: 16px;
    color: #555555;
}

/* --- FAQ Section --- */
.page-resources__faq-section {
    padding: 80px 0;
    background-color: var(--primary-color, #26A9E0);
    color: #ffffff;
}

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

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

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

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

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

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

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

.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;
    border-radius: 0 0 8px 8px;
}

.page-resources__faq-item.active .page-resources__faq-answer {
    max-height: 2000px !important; /* Ensure content can fully expand */
    padding: 20px 25px !important;
    opacity: 1;
}

.page-resources__faq-answer p {
    margin: 0;
    font-size: 16px;
    line-height: 1.7;
}

.page-resources__faq-answer a {
    color: var(--primary-color, #26A9E0);
    text-decoration: underline;
}

.page-resources__cta-section {
    text-align: center;
    margin-top: 50px;
}

.page-resources__cta-text {
    font-size: 20px;
    color: #ffffff;
    margin-bottom: 20px;
}

.page-resources__cta-button--contact {
    background-color: #EA7C07; /* Login button color */
}

.page-resources__cta-button--contact:hover {
    background-color: #c76505; /* Darker orange on hover */
}


/* --- News Section --- */
.page-resources__news-section {
    padding: 80px 0;
    background-color: var(--secondary-color, #FFFFFF);
    color: #333333;
}

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

.page-resources__news-card {
    background-color: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.page-resources__news-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
}

.page-resources__news-card img {
    width: 100%;
    height: 220px; /* Fixed height for consistency */
    object-fit: cover;
    display: block;
}

.page-resources__news-card .page-resources__card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.page-resources__news-card .page-resources__card-title a {
    color: #333333;
}

.page-resources__news-card .page-resources__card-title a:hover {
    color: var(--primary-color, #26A9E0);
}

.page-resources__news-card .page-resources__card-description {
    color: #666666;
}

.page-resources__view-all-news {
    text-align: center;
    margin-top: 50px;
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .page-resources__main-title {
        font-size: 44px;
    }
    .page-resources__description {
        font-size: 20px;
    }
    .page-resources__section-title {
        font-size: 30px;
    }
    .page-resources__text-block {
        font-size: 17px;
    }
    .page-resources__guide-card img,
    .page-resources__news-card img {
        height: 200px;
    }
}

@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__hero-image img {
        border-radius: 8px;
    }

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

    .page-resources__description {
        font-size: 18px;
        margin-bottom: 30px;
    }

    .page-resources__cta-button {
        padding: 12px 30px;
        font-size: 16px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

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

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

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

    .page-resources__intro-section,
    .page-resources__guides-section,
    .page-resources__tips-section,
    .page-resources__faq-section,
    .page-resources__news-section {
        padding: 50px 0;
    }

    .page-resources__guide-list,
    .page-resources__tips-list,
    .page-resources__news-list {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .page-resources__guide-card img,
    .page-resources__news-card img {
        
    }

    .page-resources__card-title {
        font-size: 20px;
    }

    .page-resources__card-description {
        font-size: 15px;
    }

    .page-resources__btn-secondary {
        padding: 8px 20px;
        font-size: 14px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    .page-resources__faq-question {
        padding: 15px;
        flex-wrap: wrap;
        border-radius: 6px;
    }

    .page-resources__faq-question h3 {
        font-size: 16px;
        margin-bottom: 0;
        width: calc(100% - 40px);
    }

    .page-resources__faq-toggle {
        margin-left: 10px;
        width: 28px;
        height: 28px;
        font-size: 24px;
    }

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

    .page-resources__faq-item.active .page-resources__faq-answer {
        padding: 15px !important;
    }

    .page-resources__faq-answer p {
        font-size: 15px;
    }

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

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

    .page-resources__hero-container,
    .page-resources__intro-section .page-resources__container,
    .page-resources__guides-section .page-resources__container,
    .page-resources__tips-section .page-resources__container,
    .page-resources__faq-section .page-resources__container,
    .page-resources__news-section .page-resources__container,
    .page-resources__card,
    .page-resources__tip-item,
    .page-resources__faq-item {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
}