/* style/resources.css */

/* --- Base Styles --- */
.page-resources {
    color: #ffffff; /* Light text for dark body background */
    background-color: #121212; /* Matching body background */
    padding-top: var(--header-offset, 120px); /* Ensure content starts below fixed header */
}

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

.page-resources__section {
    padding: 80px 0;
    position: relative;
    overflow: hidden; /* Prevent content overflow */
}

.page-resources__section-title {
    font-size: 36px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 40px;
    color: #FFC107; /* Accent color for titles */
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.page-resources__sub-title {
    font-size: 24px;
    font-weight: 600;
    margin-top: 30px;
    margin-bottom: 15px;
    color: #FFC107; /* Accent color for sub-titles */
}

.page-resources p {
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 15px;
    color: #f0f0f0; /* Slightly off-white for paragraphs */
}

.page-resources ol, .page-resources ul {
    list-style-position: inside;
    margin-bottom: 15px;
    padding-left: 20px;
    color: #f0f0f0;
}

.page-resources ol li, .page-resources ul li {
    margin-bottom: 8px;
    line-height: 1.6;
}

.page-resources a {
    color: #FFC107; /* Accent color for links */
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-resources a:hover {
    color: #ffe082; /* Lighter accent on hover */
    text-decoration: underline;
}

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

.page-resources__cta-button {
    background: #FFC107; /* Accent color */
    color: #0A2E4A; /* Dark text for accent background */
    border-color: #FFC107;
}

.page-resources__cta-button:hover {
    background: #ffe082;
    border-color: #ffe082;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(255, 193, 7, 0.3);
}

.page-resources__btn-primary {
    background: #0A2E4A; /* Primary brand color */
    color: #ffffff; /* White text for primary background */
    border-color: #0A2E4A;
}

.page-resources__btn-primary:hover {
    background: #1a4a70;
    border-color: #1a4a70;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(10, 46, 74, 0.3);
}

.page-resources__btn-secondary {
    background: transparent;
    color: #FFC107; /* Accent text for transparent background */
    border-color: #FFC107;
}

.page-resources__btn-secondary:hover {
    background: #FFC107;
    color: #0A2E4A;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(255, 193, 7, 0.3);
}

/* Image base styles */
.page-resources img {
    max-width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    border-radius: 8px;
}

/* --- Hero Section --- */
.page-resources__hero-section {
    background: linear-gradient(135deg, #0A2E4A, #121212); /* Blend brand color with body bg */
    padding: 100px 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

.page-resources__hero-content {
    max-width: 800px;
    margin: 0 auto 40px auto;
    padding: 0 20px;
    z-index: 1;
}

.page-resources__main-title {
    font-size: 48px;
    font-weight: 800;
    color: #FFC107; /* Accent for main title */
    margin-bottom: 25px;
    line-height: 1.2;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.page-resources__description {
    font-size: 20px;
    line-height: 1.6;
    margin-bottom: 40px;
    color: #f0f0f0;
}

.page-resources__hero-image-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Content Sections (Newbie Guide, Security, Strategies, News) --- */
.page-resources__light-bg {
    background-color: #1a1a1a; /* Slightly lighter dark background for contrast */
    color: #ffffff;
}

.page-resources__dark-bg {
    background-color: #0A2E4A; /* Primary brand color background */
    color: #ffffff;
}

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

.page-resources__content-wrapper--reverse {
    flex-direction: row-reverse;
}

.page-resources__text-block {
    flex: 1;
    min-width: 0; /* Allow flex item to shrink */
}

.page-resources__image-block {
    flex: 1;
    min-width: 0; /* Allow flex item to shrink */
}

.page-resources__image-block img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

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

.page-resources__card {
    background: #1f1f1f; /* Dark card background */
    border: 1px solid rgba(255, 193, 7, 0.2); /* Subtle accent border */
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
}

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

.page-resources__card img {
    width: 100%;
    height: 200px; /* Fixed height for consistency */
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
}

.page-resources__card-title {
    font-size: 22px;
    font-weight: 600;
    color: #FFC107;
    margin-bottom: 10px;
}

.page-resources__card p {
    font-size: 15px;
    color: #cccccc;
    margin-bottom: 20px;
    flex-grow: 1; /* Allow paragraph to take available space */
}

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

.page-resources__news-item {
    background: #1f1f1f; /* Dark news item background */
    border: 1px solid rgba(255, 193, 7, 0.2);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

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

.page-resources__news-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-bottom: 1px solid rgba(255, 193, 7, 0.1);
}

.page-resources__news-item .page-resources__news-title {
    font-size: 20px;
    font-weight: 600;
    margin: 20px 20px 10px 20px;
    color: #FFC107;
}

.page-resources__news-item .page-resources__news-title a {
    color: inherit;
    text-decoration: none;
}

.page-resources__news-item .page-resources__news-title a:hover {
    text-decoration: underline;
}

.page-resources__news-item .page-resources__news-excerpt {
    font-size: 15px;
    color: #cccccc;
    margin: 0 20px 15px 20px;
    flex-grow: 1;
}

.page-resources__news-item .page-resources__news-date {
    font-size: 13px;
    color: #999999;
    margin: 0 20px 20px 20px;
    display: block;
}

.page-resources__button-group {
    text-align: center;
    margin-top: 50px;
}

/* --- FAQ Section --- */
.page-resources__faq-section {
    padding-bottom: 80px;
}

.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.2);
    background-color: #1f1f1f; /* Dark background for FAQ item */
}

.page-resources__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    background: #0A2E4A; /* Primary brand color for question header */
    color: #ffffff;
    border: 1px solid #1a4a70;
    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: #1a4a70; /* Slightly lighter primary on hover */
    border-color: #2c6a9e;
}

.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 event */
    color: #ffffff; /* White text for contrast */
}

.page-resources__faq-toggle {
    font-size: 28px;
    font-weight: bold;
    line-height: 1;
    color: #FFC107; /* Accent color for toggle */
    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: 30px;
    height: 30px;
}

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

.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: #1f1f1f; /* Darker background for answer */
    color: #cccccc; /* Lighter text for answer */
    border-top: 1px solid rgba(255, 193, 7, 0.1);
}

.page-resources__faq-item.active .page-resources__faq-answer {
    max-height: 2000px !important; /* Sufficiently large for content */
    padding: 20px 25px !important;
    opacity: 1;
    border-radius: 0 0 8px 8px;
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .page-resources__hero-section {
        padding: 80px 0;
    }

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

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

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

    .page-resources__section-title {
        font-size: 32px;
    }

    .page-resources__content-wrapper {
        flex-direction: column;
    }

    .page-resources__content-wrapper--reverse {
        flex-direction: column;
    }

    .page-resources__image-block img {
        height: auto;
        max-height: 400px;
    }

    .page-resources__strategy-cards {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }

    .page-resources__news-list {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    /* General mobile adaptations */
    .page-resources {
        font-size: 16px;
        line-height: 1.6;
        padding-top: var(--header-offset, 120px);
    }

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

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

    .page-resources__hero-content {
        margin-bottom: 30px;
    }

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

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

    .page-resources__cta-button {
        padding: 10px 20px;
        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 {
        padding: 40px 0;
    }

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

    .page-resources__sub-title {
        font-size: 20px;
        margin-top: 25px;
        margin-bottom: 10px;
    }

    .page-resources p {
        font-size: 15px;
        line-height: 1.7;
    }

    .page-resources__image-block img {
        max-height: 300px;
        width: 100% !important;
        height: auto !important;
    }

    /* All images, ensure full width and auto height */
    .page-resources img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }
    
    /* All image containers, ensure full width and proper box-sizing */
    .page-resources__hero-image-wrapper,
    .page-resources__image-block,
    .page-resources__card,
    .page-resources__news-item {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    /* Strategy Cards */
    .page-resources__strategy-cards {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-resources__card {
        padding: 20px;
    }

    .page-resources__card img {
        
        margin-bottom: 15px;
    }

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

    .page-resources__card p {
        font-size: 14px;
    }

    /* News List */
    .page-resources__news-list {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-resources__news-item img {
        
    }

    .page-resources__news-item .page-resources__news-title {
        font-size: 18px;
        margin: 15px 15px 8px 15px;
    }

    .page-resources__news-item .page-resources__news-excerpt {
        font-size: 14px;
        margin: 0 15px 10px 15px;
    }

    .page-resources__news-item .page-resources__news-date {
        font-size: 12px;
        margin: 0 15px 15px 15px;
    }

    .page-resources__button-group {
        margin-top: 40px;
    }

    /* FAQ */
    .page-resources__faq-question {
        padding: 15px 20px;
        flex-wrap: wrap;
    }
    
    .page-resources__faq-question h3 {
        font-size: 16px;
        margin-bottom: 0;
        width: calc(100% - 40px);
    }
    
    .page-resources__faq-toggle {
        margin-left: 10px;
        width: 26px;
        height: 26px;
        font-size: 22px;
    }
    
    .page-resources__faq-answer {
        padding: 0 20px;
    }
    
    .page-resources__faq-item.active .page-resources__faq-answer {
        padding: 15px 20px !important;
    }
}