/* style/resources.css */

/* --- Base Styles --- */
.page-resources {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #ffffff; /* Body background #1a1a1a (dark), so text must be light */
    background-color: #1a1a1a; /* Ensure consistency with shared.css body bg */
}

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

.page-resources__section {
    padding: 80px 0;
    position: relative;
    z-index: 1;
}

.page-resources__section-title {
    font-size: 2.5em;
    color: #ffffff; /* Light text for dark background */
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
}

.page-resources__section-description {
    font-size: 1.1em;
    color: #f0f0f0; /* Slightly lighter white for description */
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
}

/* --- Hero Section --- */
.page-resources__hero-section {
    position: relative;
    height: 70vh; /* Adjust as needed */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    padding-top: var(--header-offset, 120px); /* Ensure space for fixed header */
}

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

.page-resources__hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7); /* Dark overlay for text readability */
    z-index: -1;
}

.page-resources__hero-content {
    position: relative;
    z-index: 1;
    max-width: 900px;
    padding: 20px;
    color: #ffffff;
}

.page-resources__hero-title {
    font-size: 3.5em;
    margin-bottom: 20px;
    line-height: 1.2;
    color: #ffffff;
    font-weight: bold;
}

.page-resources__hero-description {
    font-size: 1.3em;
    margin-bottom: 40px;
    color: #f0f0f0;
}

/* --- Buttons --- */
.page-resources__cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
}

.page-resources__btn-primary,
.page-resources__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1em;
    transition: all 0.3s ease;
    box-sizing: border-box; /* Crucial for responsive buttons */
    max-width: 100%; /* Ensure button doesn't overflow */
    white-space: normal; /* Allow text to wrap */
    word-wrap: break-word; /* Allow text to break words */
}

.page-resources__btn-primary {
    background-color: #017439; /* Primary color */
    color: #ffffff;
    border: 2px solid #017439;
}

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

.page-resources__btn-secondary {
    background-color: transparent;
    color: #ffffff;
    border: 2px solid #ffffff;
}

.page-resources__btn-secondary:hover {
    background-color: #ffffff;
    color: #017439;
}

/* Custom colors for Login/Register buttons */
.page-resources__btn-login {
    background-color: #C30808; /* Red for Login */
    border-color: #C30808;
    color: #FFFF00; /* Yellow text for Login */
}
.page-resources__btn-login:hover {
    background-color: #e00b0b;
    border-color: #e00b0b;
}

.page-resources__btn-register {
    background-color: #C30808; /* Red for Register */
    border-color: #C30808;
    color: #FFFF00; /* Yellow text for Register */
}
.page-resources__btn-register:hover {
    background-color: #e00b0b;
    border-color: #e00b0b;
}

.page-resources__btn-download {
    background-color: #017439; /* Green for Download */
    border-color: #017439;
    color: #ffffff;
}
.page-resources__btn-download:hover {
    background-color: #02944b;
    border-color: #02944b;
}

/* --- Video Section --- */
.page-resources__video-section {
    background-color: #1a1a1a; /* Dark background */
    padding-top: var(--header-offset, 120px); /* Ensure space for fixed header */
}

.page-resources__video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    margin: 40px auto;
    background-color: #000;
    border-radius: 10px;
}

.page-resources__video-link {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    cursor: pointer;
}

.page-resources__video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
    display: block;
}

/* --- Guide Cards Section --- */
.page-resources__guides-section {
    background-color: #2a2a2a; /* Slightly lighter dark background */
}

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

.page-resources__card {
    background-color: rgba(255, 255, 255, 0.08); /* Semi-transparent white for dark background */
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    color: #ffffff; /* Light text for card content */
}

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

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

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

.page-resources__card-title {
    font-size: 1.4em;
    margin-bottom: 15px;
    line-height: 1.3;
    color: #ffffff;
}

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

.page-resources__card-title a:hover {
    color: #017439; /* Primary color on hover */
}

.page-resources__card-text {
    font-size: 0.95em;
    color: #e0e0e0;
    margin-bottom: 20px;
    flex-grow: 1;
}

.page-resources__card-link {
    display: inline-block;
    color: #017439; /* Primary color for link */
    text-decoration: none;
    font-weight: bold;
    margin-top: auto; /* Push to bottom */
    transition: color 0.3s ease;
}

.page-resources__card-link:hover {
    text-decoration: underline;
    color: #02944b;
}

/* --- News Section --- */
.page-resources__news-section {
    background-color: #017439; /* Primary color for news section background */
    color: #ffffff;
}

.page-resources__news-section .page-resources__section-title,
.page-resources__news-section .page-resources__section-description {
    color: #ffffff;
}

/* --- FAQ Section --- */
.page-resources__faq-section {
    background-color: #1a1a1a; /* Dark background */
}

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

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

.page-resources__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    cursor: pointer;
    font-size: 1.15em;
    font-weight: bold;
    color: #ffffff;
    transition: background-color 0.3s ease;
}

.page-resources__faq-question:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

.page-resources__faq-question h3 {
    margin: 0;
    color: inherit;
}

.page-resources__faq-toggle {
    font-size: 1.5em;
    font-weight: bold;
    color: #017439; /* Primary color for toggle */
    transition: transform 0.3s ease;
}

.page-resources__faq-item.active .page-resources__faq-toggle {
    transform: rotate(45deg); /* Rotate for minus sign effect */
}

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

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

.page-resources__faq-answer p {
    margin: 0;
    color: inherit;
}

/* --- Support Info Section --- */
.page-resources__support-info-section {
    background-color: #017439; /* Primary color background */
    color: #ffffff;
}

.page-resources__support-info-section .page-resources__section-title,
.page-resources__support-info-section .page-resources__section-description {
    color: #ffffff;
}

.page-resources__link-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.page-resources__link-item {
    display: block;
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    text-decoration: none;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    font-weight: bold;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.page-resources__link-item:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
}

/* --- Final CTA Section --- */
.page-resources__cta-final-section {
    background-color: #1a1a1a; /* Dark background */
}

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

@media (max-width: 768px) {
    .page-resources__hero-section {
        height: 60vh;
        padding-top: var(--header-offset, 120px) !important; /* Ensure space for fixed header on mobile */
    }
    .page-resources__hero-title {
        font-size: 2.5em;
    }
    .page-resources__hero-description {
        font-size: 1.1em;
    }
    .page-resources__cta-buttons {
        flex-direction: column;
        gap: 15px;
    }
    .page-resources__btn-primary,
    .page-resources__btn-secondary,
    .page-resources__btn-login,
    .page-resources__btn-register,
    .page-resources__btn-download,
    .page-resources a[class*="button"],
    .page-resources a[class*="btn"] {
        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__cta-buttons,
    .page-resources__button-group,
    .page-resources__btn-container {
      max-width: 100% !important;
      width: 100% !important;
      box-sizing: border-box !important;
      padding-left: 15px;
      padding-right: 15px;
      flex-wrap: wrap !important;
      gap: 10px;
    }

    .page-resources__section {
        padding: 60px 0;
    }
    .page-resources__container {
        padding: 0 15px;
    }
    .page-resources__section-title {
        font-size: 1.8em;
    }
    .page-resources__section-description {
        font-size: 1em;
    }

    /* Mobile image responsive rules */
    .page-resources img {
        max-width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-resources__section,
    .page-resources__card,
    .page-resources__container,
    .page-resources__video-section,
    .page-resources__video-container,
    .page-resources__video-wrapper,
    .page-resources__faq-item {
      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 */
    }
    .page-resources__video-section {
        padding-top: var(--header-offset, 120px) !important;
    }
    .page-resources__video-wrapper {
        padding-bottom: 56.25% !important; /* Maintain aspect ratio */
        height: 0 !important;
        overflow: hidden !important;
    }
    .page-resources__video {
        max-width: 100% !important;
        width: 100% !important;
        height: 100% !important; /* Fill parent */
        object-fit: cover !important;
    }

    .page-resources__card-image {
        height: auto; /* Allow height to adjust */
    }
    .page-resources__faq-question {
        font-size: 1em;
        padding: 15px 20px;
    }
    .page-resources__faq-answer {
        padding: 0 20px;
    }
    .page-resources__faq-item.active .page-resources__faq-answer {
        padding: 10px 20px 20px;
    }
    .page-resources__link-grid {
        grid-template-columns: 1fr;
    }
}

/* Ensure content area images are not too small */
.page-resources__hero-image {
    min-width: 200px;
    min-height: 200px;
}
.page-resources__video {
    min-width: 200px;
    min-height: 200px;
}