/* style/resources.css */
:root {
    --primary-color: #017439;
    --secondary-color: #FFFFFF;
    --register-color: #C30808;
    --login-color: #C30808;
    --background-color: #FFFFFF;
    --register-login-font-color: #FFFF00;
    --dark-text-color: #333333;
    --light-text-color: #ffffff;
    --border-color: #e0e0e0;
}

.page-resources {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--dark-text-color); /* Default text color for light backgrounds */
    background-color: var(--background-color); /* Default body background is light */
}

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

.page-resources__light-bg {
    background-color: var(--secondary-color);
    color: var(--dark-text-color);
}

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

.page-resources__hero-section {
    position: relative;
    padding-top: var(--header-offset, 120px); /* Ensures content is below fixed header */
    padding-bottom: 80px;
    text-align: center;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

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

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

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

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

.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: normal;
    word-wrap: break-word;
    text-align: center;
    box-sizing: border-box;
}

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

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

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

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

.page-resources__section-title {
    font-size: 2.5em;
    text-align: center;
    margin-bottom: 40px;
    color: inherit; /* Inherits color from parent section */
}

.page-resources__intro-section,
.page-resources__guides-section,
.page-resources__news-section,
.page-resources__cta-section {
    padding: 60px 0;
}

.page-resources__categories-section,
.page-resources__strategies-section,
.page-resources__faq-section {
    padding: 60px 0;
}

.page-resources__text-block {
    margin-bottom: 20px;
    font-size: 1.1em;
    color: inherit;
}

.page-resources__text-block a {
    color: var(--primary-color);
    text-decoration: underline;
}

.page-resources__text-block a:hover {
    color: var(--register-color);
}

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

.page-resources__card {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    text-decoration: none;
    color: var(--light-text-color);
    transition: transform 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-resources__card:hover {
    transform: translateY(-10px);
    background-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

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

.page-resources__card-title {
    font-size: 1.5em;
    margin-bottom: 15px;
    color: inherit;
}

.page-resources__card-description {
    font-size: 1em;
    color: inherit;
    flex-grow: 1;
}

.page-resources__content-wrapper {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.page-resources__text-content {
    flex: 2;
}

.page-resources__image-aside {
    flex: 1;
    text-align: center;
}

.page-resources__image-responsive {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-resources__image-caption {
    font-style: italic;
    margin-top: 10px;
    color: var(--dark-text-color);
}

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

.page-resources__card--strategy {
    background-color: var(--secondary-color);
    color: var(--dark-text-color);
    border: 1px solid var(--border-color);
}

.page-resources__card--strategy:hover {
    background-color: #f0f0f0;
    transform: translateY(-5px);
}

.page-resources__btn-ghost {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 20px;
    border: 2px solid var(--primary-color);
    border-radius: 5px;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s ease, color 0.3s ease;
}

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

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

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

.page-resources__article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.page-resources__article-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.page-resources__article-content {
    padding: 20px;
    flex-grow: 1;
}

.page-resources__article-title {
    font-size: 1.4em;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.page-resources__article-excerpt {
    font-size: 0.95em;
    color: var(--dark-text-color);
}

.page-resources__cta-bottom {
    text-align: center;
    margin-top: 40px;
}

.page-resources__faq-list {
    margin-top: 40px;
}

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

.page-resources__faq-item summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    cursor: pointer;
    font-size: 1.2em;
    font-weight: bold;
    list-style: none;
    color: var(--light-text-color);
}

.page-resources__faq-item summary::-webkit-details-marker {
    display: none;
}

.page-resources__faq-qtext {
    flex-grow: 1;
}

.page-resources__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    margin-left: 15px;
}

.page-resources__faq-answer {
    padding: 0 20px 20px 20px;
    font-size: 1.1em;
    color: var(--light-text-color);
}

.page-resources__faq-answer p {
    margin-top: 0;
    margin-bottom: 0;
}

.page-resources__cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 40px;
}

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

@media (max-width: 768px) {
    .page-resources__hero-section {
        padding-top: var(--header-offset, 120px) !important; /* Mobile fixed header offset */
        padding-bottom: 60px;
    }
    .page-resources__hero-title {
        font-size: 2em;
    }
    .page-resources__hero-description {
        font-size: 1em;
        padding: 0 10px;
    }
    .page-resources__hero-cta,
    .page-resources__cta-buttons {
        flex-direction: column;
        gap: 15px;
        padding: 0 15px;
    }
    .page-resources__btn-primary,
    .page-resources__btn-secondary {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding: 12px 20px;
    }
    .page-resources__section-title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }
    .page-resources__intro-section,
    .page-resources__guides-section,
    .page-resources__news-section,
    .page-resources__cta-section,
    .page-resources__categories-section,
    .page-resources__strategies-section,
    .page-resources__faq-section {
        padding: 40px 0;
    }
    .page-resources__container {
        padding: 0 15px;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
    .page-resources__content-wrapper {
        flex-direction: column;
        gap: 30px;
    }
    .page-resources__image-aside {
        order: -1; /* Image appears before text on mobile */
    }
    /* Mobile image responsiveness */
    .page-resources img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-resources__card-image,
    .page-resources__article-image {
        height: 180px;
    }
    .page-resources__card,
    .page-resources__article-card {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        padding: 20px;
    }
    .page-resources__faq-item summary {
        font-size: 1.1em;
        padding: 15px;
    }
    .page-resources__faq-answer {
        padding: 0 15px 15px 15px;
        font-size: 1em;
    }
    .page-resources__text-block,
    .page-resources__card-description,
    .page-resources__article-excerpt {
      font-size: 0.95em;
    }
}

@media (max-width: 480px) {
    .page-resources__hero-title {
        font-size: 1.8em;
    }
    .page-resources__section-title {
        font-size: 1.5em;
    }
    .page-resources__sub-title {
        font-size: 1.5em;
    }
    .page-resources__card-title {
        font-size: 1.3em;
    }
    .page-resources__article-title {
        font-size: 1.2em;
    }
}