/* Global Variables */
:root {
    --primary-blue: #3185C6;
    --primary-blue-hover: #24689E;
    --primary-text: #232429;
    --secondary-text: #414141; /* Dark-ish grey from screenshot for links */
    --footer-bg: #FFFFFF;
    --border-color: #E5E7EB;
    --font-main: Verdana, Geneva, Tahoma, sans-serif; /* Matched from country-ambition.cgs.umd.edu */
}

/* Reset and Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-main);
    color: var(--primary-text);
    background-color: #DCEDF8; /* Slightly darker blue background */
    line-height: 1.5;
    overflow-x: hidden; /* Prevent horizontal scroll on mobile */
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* ========================================= */
/* HEADER STYLES                             */
/* ========================================= */
#header-placeholder {
    z-index: 1000;
    display: flow-root; /* Prevents margin collapse of child elements */
}

body.home-page #header-placeholder {
    position: sticky;
    top: 0;
}

.site-header {
    background-color: #FFFFFF;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.08); /* Soft shadow for floating effect */
    padding: 12px 24px;
    margin: 16px 24px; /* Floating margin */
    transition: background-color 0.3s ease;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.branding .cgs-logo {
    height: 80px; /* Reverted to 80px to fix blurriness */
    display: block;
}

.main-nav {
    flex-grow: 1;
    display: flex;
    justify-content: flex-end; /* Push to the right */
    padding-right: 32px;
}

.main-nav ul {
    display: flex;
    gap: 32px;
}

.main-nav a {
    font-size: 16px; /* Reduced from 17px */
    font-weight: 500;
    color: #000;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s ease;
}

.main-nav a:hover {
    color: var(--primary-blue);
}

.nav-icon {
    font-size: 10px;
    color: #666;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-container {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input {
    background-color: #FFFFFF;
    border: 1px solid #CCC;
    border-radius: 4px; /* Slight rounding according to screenshot */
    padding: 8px 30px 8px 12px;
    font-size: 14px;
    width: 180px;
}

.search-btn {
    position: absolute;
    right: 8px;
    background: none;
    border: none;
    color: #888;
    cursor: pointer;
    font-size: 14px;
}

/* Search Results Dropdown */
.search-results-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #FFFFFF;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    margin-top: 8px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    max-height: 400px;
    overflow-y: auto;
    z-index: 2000;
    display: none; /* Hidden by default */
}

.search-results-dropdown.active {
    display: block;
}

.search-result-item {
    padding: 12px 16px;
    border-bottom: 1px solid #F3F4F6;
    display: block;
    text-decoration: none;
    transition: background 0.2s ease;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: #F9FAFB;
}

.result-title {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 2px;
}

.result-category {
    font-size: 10px;
    text-transform: uppercase;
    color: #9CA3AF;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
    display: block;
}

.result-snippet {
    display: block;
    font-size: 12px;
    color: #6B7280;
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.no-results {
    padding: 20px;
    text-align: center;
    color: #9CA3AF;
    font-size: 14px;
}

.contact-btn {
    background-color: var(--primary-blue);
    color: #FFFFFF;
    font-size: 14px;
    font-weight: 500;
    padding: 10px 20px;
    border-radius: 4px; /* Rectangular with slight rounded corners */
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.menu-toggle {
    display: none; /* Hidden on desktop */
    background: none;
    border: none;
    font-size: 24px;
    color: var(--primary-blue);
    cursor: pointer;
    padding: 8px;
}

/* ========================================= */
/* FOOTER STYLES                             */
/* ========================================= */

/* 1. Sign-up Block (Top Footer) */
.footer-top {
    background-color: var(--primary-blue); 
    color: #FFFFFF;
    padding: 60px 20px;
    text-align: center;
}

.footer-top h2 {
    font-size: 24px;
    font-weight: 500;
    margin-bottom: 12px;
}

.footer-top p {
    font-size: 14px;
    margin-bottom: 24px;
    font-weight: 400;
}

.signup-form {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 480px;
    margin: 0 auto;
    position: relative;
}

.signup-form input {
    width: 100%;
    padding: 14px 44px 14px 20px;
    border-radius: 24px; /* nice pill shape */
    border: none;
    font-size: 14px;
    color: var(--primary-text);
}

.signup-form input::placeholder {
    color: #999;
}

.signup-form button {
    position: absolute;
    right: 6px;
    top: 6px;
    bottom: 6px;
    width: 32px;
    height: 32px;
    border-radius: 50%; /* Circular */
    background-color: #FFFFFF;
    color: var(--primary-blue);
    border: 2px solid #EEEEEE;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
}

/* 2. Main Informational Footer (Bottom Footer) */
.footer-bottom {
    background-color: #FFFFFF;
    padding: 60px 40px;
}

.footer-bottom-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: center; /* Center everything as requested */
    gap: 120px; /* <leave some space> between left panel and columns */
}

.footer-left-section {
    flex-shrink: 0;
}

.footer-address {
    font-size: 14px; /* Reduced from 15px */
    color: var(--primary-text);
    line-height: 1.6;
}

.footer-address strong {
    font-weight: 700;
}

.footer-grid {
    display: flex;
    gap: 60px;
    justify-content: center;
}

.cgs-footer-logo {
    height: 70px; /* Increased CGS logo size for footer */
    margin-bottom: 24px;
    display: block;
}

.social-links {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.social-links a {
    display: flex;
    align-items: center;
    font-size: 15px; /* Increased */
    color: var(--secondary-text);
    font-weight: 400;
}

.social-links a img {
    width: 24px;
    height: 24px;
    margin-right: 12px;
    border-radius: 4px; /* Very slight rounding for JPEGs */
    object-fit: cover;
}

.footer-col h3 {
    font-size: 16px; /* Increased */
    font-weight: 700;
    color: var(--primary-blue); /* Changed to blue matching theme */ 
    margin-bottom: 20px;
    text-transform: capitalize;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 16px; /* Increased gap */
}

.footer-col ul a, .contact-link {
    font-size: 14px; /* Reduced from 15px */
    color: var(--primary-text);
    font-weight: 400; /* Removed bold */
}

.contact-link {
    display: inline-block;
}

/* ========================================= */
/* HERO SECTION                              */
/* ========================================= */
.hero-section {
    padding: 80px 0;
    background-color: transparent; /* Seamless with body background */
}

.hero-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 60px;
}

.hero-text {
    flex: 1;
}

.hero-text h1 {
    font-size: 44px; /* Reduced from 48px */
    font-weight: 800;
    color: #000;
    margin-bottom: 30px;
    line-height: 1.2;
}

.hero-text p {
    font-size: 17px; /* Reduced from 18px */
    margin-bottom: 24px;
    line-height: 1.6;
    color: #333;
}

.hero-image-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 50px; /* Slightly lowered space between image and button */
}

.hero-cover-img {
    width: 100%;
    max-width: 360px;
    border: 8px solid #FFFFFF; /* Thick white physical frame */
    border-radius: 4px; /* Crisp edges */
    box-shadow: -16px 16px 0px var(--primary-blue), 0 24px 40px rgba(0,0,0,0.12); /* Layered thematic block shadow and soft depth */
    display: block;
}

.btn-primary {
    background-color: #6C8E68; /* Green button matching screenshot */
    color: white;
    padding: 14px 28px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 30px; /* Pillow shape matching screenshot */
    border: none;
    cursor: pointer;
    display: inline-block;
    transition: background-color 0.2s ease;
}

.btn-primary:hover {
    background-color: #557252;
}

/* ========================================= */
/* EXPLORE SECTION                           */
/* ========================================= */
.explore-section {
    background-color: #F5F8FA; /* Thematic light grey-blue */
    padding: 80px 0;
}

.explore-container {
    max-width: 1400px;
    margin: 0 auto;
}

.explore-container h2 {
    font-size: 36px;
    font-weight: 800;
    color: #1A365D; /* Dark blue */
    margin-bottom: 40px;
    text-align: center;
}

.carousel-wrapper {
    position: relative;
    width: 100%;
    padding: 0 80px; /* Space for the arrows */
    display: flex;
    align-items: center;
}

.carousel-arrow {
    background-color: white;
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #000;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    z-index: 10;
    position: absolute;
}

.prev-arrow {
    left: 10px;
}

.next-arrow {
    right: 10px;
}

.carousel-track-container {
    overflow: hidden;
    width: 100%;
}

.carousel-track {
    display: flex;
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.carousel-slide {
    min-width: 100%;
    display: flex;
    gap: 50px;
    align-items: center;
    padding: 40px; 
    background-color: #E1F0FA; /* Pale light blue matching the theme */
    border-radius: 24px;
    opacity: 0.2;
    transform: scale(0.95);
    transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    pointer-events: none;
}

.carousel-slide.current-slide {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

.slide-image {
    flex: 0 0 350px;
}

.slide-image img {
    width: 100%;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    display: block;
}

.slide-content {
    flex: 1;
}

.slide-content h3 {
    font-size: 28px;
    font-weight: 700;
    color: #000; /* Revert back to black for readability on light blue */
    margin-bottom: 20px;
}

.slide-content p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 30px;
    color: #333; /* Revert back to slate grey for readability */
}

/* ========================================= */
/* PAGE HERO BANNER (Reusable for subpages)  */
/* ========================================= */
.page-hero {
    position: relative;
    width: 100%;
    height: 380px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
}

.page-hero-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.page-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.45) 0%,
        rgba(0, 0, 0, 0.1) 50%,
        transparent 100%
    );
}

.page-hero-title {
    position: relative;
    z-index: 2;
    font-size: 56px;
    font-weight: 800;
    color: #FFFFFF;
    padding: 40px 60px;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

/* On subpages (about, etc.) dark blue background behind header card */
body.about-page {
    background-color: #FFFFFF;
}

body.about-page #header-placeholder {
    background-color: #1A365D;
}

/* ========================================= */
/* ABOUT THE PROJECT SECTION                 */
/* ========================================= */
.about-project-section {
    background-color: #F5F8FA;
    padding: 80px 0;
}

.about-project-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

.about-project-container h2 {
    font-size: 40px;
    font-weight: 800;
    color: #1A365D;
    margin-bottom: 32px;
}

.about-project-container > p {
    font-size: 15px; /* Reduced from 16px */
    line-height: 1.85;
    color: #444;
}

/* ========================================= */
/* ABOUT CGS SECTION                         */
/* ========================================= */
.about-cgs-section {
    background-color: #FFFFFF;
    padding: 80px 0;
}

.about-cgs-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    align-items: flex-start;
    gap: 60px;
}

.about-cgs-image {
    flex: 0 0 440px;
}

.about-cgs-image img {
    width: 100%;
    border-radius: 16px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    display: block;
}

.about-cgs-text {
    flex: 1;
}

.about-cgs-text h2 {
    font-size: 34px;
    font-weight: 800;
    color: #1A365D;
    margin-bottom: 28px;
    line-height: 1.25;
}

.about-cgs-text p {
    font-size: 15px;
    line-height: 1.8;
    color: #444;
    margin-bottom: 20px;
}

.about-cgs-text .btn-primary {
    margin-top: 12px;
}

/* ========================================= */
/* FAQ PAGE                                  */
/* ========================================= */
.faq-section {
    background-color: #FFFFFF;
    padding: 60px 0;
}

.faq-section-alt {
    background-color: #F5F8FA;
}

.faq-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 40px;
}

.faq-container h2 {
    font-size: 34px;
    font-weight: 800;
    color: #1A365D;
    margin-bottom: 32px;
}

/* Accordion */
.faq-accordion {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.faq-item {
    border-radius: 8px;
    overflow: hidden;
    background-color: #F6F8FA;
    transition: background-color 0.3s ease;
}

.faq-item.open {
    background-color: #EBF3FA;
}

.faq-question {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 28px;
    border: none;
    background: none;
    cursor: pointer;
    text-align: left;
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 700;
    color: #1A365D;
    gap: 20px;
}

.faq-question:hover {
    opacity: 0.85;
}

.faq-icon {
    font-size: 26px;
    font-weight: 400;
    flex-shrink: 0;
    color: #1A365D;
    line-height: 1;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
    padding: 0 28px;
}

.faq-item.open .faq-answer {
    max-height: 800px;
    padding: 0 28px 24px;
}

.faq-answer p {
    font-size: 14px;
    line-height: 1.75;
    color: #333;
    margin-bottom: 12px;
}

.faq-answer ul {
    list-style: disc;
    margin-left: 24px;
    margin-bottom: 12px;
}

.faq-answer ul li {
    font-size: 14px;
    line-height: 1.75;
    color: #333;
    margin-bottom: 4px;
}

.faq-answer a {
    color: var(--primary-blue);
    text-decoration: underline;
}

/* FAQ Table */
.faq-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    border: 1px solid #CCC;
}

.faq-table td {
    padding: 16px 20px;
    border: 1px solid #CCC;
    font-size: 14px;
    line-height: 1.7;
    color: #333;
    vertical-align: top;
}

.faq-table td:first-child {
    width: 45%;
    font-weight: 600;
}

.faq-table ul {
    margin-left: 20px;
    margin-bottom: 0;
}

/* Contact Section */
.faq-contact-section {
    background-color: #1A365D;
    padding: 60px 0;
    text-align: center;
}

.faq-contact-section h2 {
    font-size: 30px;
    font-weight: 800;
    color: #FFFFFF;
    margin-bottom: 20px;
}

.faq-contact-section p {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 10px;
}

.faq-contact-section a {
    color: #A0C4E8;
    text-decoration: underline;
}

/* ========================================= */
/* DATA PAGE                                 */
/* ========================================= */
.data-section {
    background-color: #FFFFFF;
    padding: 70px 0 80px;
}

.data-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 40px;
}

.data-description {
    font-size: 15px; /* Reduced from 16px */
    line-height: 1.85;
    color: #444;
    margin-bottom: 24px;
}

.data-description em {
    font-style: italic;
}

/* Data Table */
.data-table-wrapper {
    margin-top: 40px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.07);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table thead {
    background-color: #1A365D;
}

.data-table thead th {
    padding: 18px 28px;
    font-size: 15px;
    font-weight: 700;
    color: #FFFFFF;
    text-align: left;
}

.data-table tbody tr {
    border-bottom: 1px solid #E5E7EB;
    transition: background-color 0.2s ease;
}

.data-table tbody tr:last-child {
    border-bottom: none;
}

.data-table tbody tr:nth-child(even) {
    background-color: #F7FAFC;
}

.data-table tbody tr:hover {
    background-color: #EAF4FC;
}

.data-table tbody td {
    padding: 18px 28px;
    font-size: 14px; /* Reduced from 15px */
    color: #333;
    vertical-align: middle;
}

.data-table tbody td em {
    font-style: italic;
    color: #555;
}

.download-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-blue);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: color 0.2s ease;
}

.download-link:hover {
    color: var(--primary-blue-hover);
    text-decoration: underline;
}

.download-link i {
    font-size: 16px;
}

/* Zip All Button */
.data-zip-all {
    margin-top: 40px;
    text-align: center;
}

.data-zip-all .btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* ========================================= */
/* PRIVACY POLICY PAGE                       */
/* ========================================= */
.policy-section {
    background-color: #FFFFFF;
    padding: 70px 0 80px;
}

.policy-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 40px;
}

.policy-intro {
    font-size: 16px;
    line-height: 1.85;
    color: #444;
    margin-bottom: 24px;
}

.policy-container h2 {
    font-size: 28px;
    font-weight: 800;
    color: #1A365D;
    margin-top: 48px;
    margin-bottom: 16px;
}

.policy-container h3 {
    font-size: 18px;
    font-weight: 700;
    color: #1A365D;
    margin-top: 28px;
    margin-bottom: 12px;
}

.policy-container p {
    font-size: 15px;
    line-height: 1.85;
    color: #444;
    margin-bottom: 16px;
}

.policy-container a {
    color: var(--primary-blue);
    text-decoration: underline;
}

.policy-list {
    list-style: disc;
    margin-left: 28px;
    margin-bottom: 24px;
}

.policy-list li {
    font-size: 15px;
    line-height: 1.85;
    color: #444;
    margin-bottom: 8px;
}

/* ========================================= */
/* REPORTS PAGE                              */
/* ========================================= */

/* Executive Summary */
.report-summary-section {
    background-color: #FFFFFF;
    padding: 70px 0 40px;
}

.report-summary-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    align-items: flex-start;
    gap: 50px;
}

.report-summary-text {
    flex: 1;
}

.report-summary-text h2 {
    font-size: 32px; /* Reduced from 36px */
    font-weight: 800;
    color: #1A365D;
    margin-bottom: 24px;
}

.report-summary-text p {
    font-size: 15px;
    line-height: 1.85;
    color: #444;
    margin-bottom: 20px;
}

.report-summary-text .btn-primary {
    margin-top: 12px;
}

.report-summary-image {
    flex: 0 0 300px;
}

.report-summary-image img {
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    display: block;
}

/* Note Callout */
.report-note {
    max-width: 1200px;
    margin: 40px auto 0;
    padding: 20px 28px;
    background-color: #E1F0FA; /* Light Blue background */
    border-left: 5px solid var(--primary-blue); /* Thematic blue border */
    border-radius: 6px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.report-note i {
    color: var(--primary-blue);
    font-size: 20px;
    margin-top: 2px;
    flex-shrink: 0;
}

.report-note p {
    font-size: 14px;
    line-height: 1.7;
    color: #1A365D;
    margin: 0;
}

/* About the Chapters */
.report-chapters-section {
    background-color: #F5F8FA;
    padding: 70px 0 80px;
}

.report-chapters-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

.report-chapters-container > h2 {
    font-size: 36px;
    font-weight: 800;
    color: #1A365D;
    margin-bottom: 8px;
    text-align: center;
}

.chapters-subtitle {
    font-size: 15px;
    color: #666;
    text-align: center;
    margin-bottom: 40px;
}

/* Chapter Grid */
.chapter-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 20px;
}

.chapter-card {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.chapter-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14);
}

.chapter-card.active {
    outline: 3px solid var(--primary-blue);
    outline-offset: 2px;
}

.chapter-card img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    display: block;
}

.chapter-card-label {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 14px 16px;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    color: #FFFFFF;
    font-size: 14px;
    font-weight: 700;
}

.card-download-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.9);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1A365D;
    font-size: 16px;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transform: translateY(-5px);
    transition: all 0.3s ease;
    z-index: 10;
}

.chapter-card:hover .card-download-btn {
    opacity: 1;
    transform: translateY(0);
}

.card-download-btn:hover {
    background: #1A365D;
    color: #FFFFFF;
    transform: scale(1.1);
}

/* Chapter Detail Panel */
.chapter-detail {
    grid-column: 1 / -1;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease, margin 0.4s ease, opacity 0.4s ease;
    opacity: 0;
    margin: 0;
}

.chapter-detail.open {
    max-height: 600px;
    opacity: 1;
    margin: 10px 0 20px;
}

.chapter-detail-inner {
    display: flex;
    align-items: flex-start;
    gap: 40px;
    background-color: #FFFFFF;
    border-radius: 16px;
    padding: 36px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.chapter-detail-image {
    flex: 0 0 220px;
}

.chapter-detail-image img {
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
    display: block;
}

.chapter-detail-text {
    flex: 1;
}

.chapter-detail-text h3 {
    font-size: 24px;
    font-weight: 800;
    color: #1A365D;
    margin-bottom: 16px;
}

.chapter-detail-text p {
    font-size: 15px;
    line-height: 1.85;
    color: #444;
    margin-bottom: 24px;
}

/* ========================================= */
/* DOWNLOAD GATE MODAL                       */
/* ========================================= */
.download-gate-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: none; /* Hidden by default */
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.download-gate-modal.active {
    display: flex;
    opacity: 1;
}

.modal-content-container {
    position: relative;
    background: #FFFFFF;
    width: 90%;
    max-width: 800px;
    height: 90vh;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    display: flex;
    flex-direction: column;
}

.download-gate-modal.active .modal-content-container {
    transform: scale(1);
}

.modal-skip-btn {
    position: absolute;
    top: 20px;
    right: 25px;
    padding: 10px 20px;
    background: #1A365D;
    color: #FFFFFF;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    z-index: 10001;
    transition: all 0.2s ease;
}

.modal-skip-btn:hover {
    background: #2D4A77;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

.modal-skip-btn:active {
    transform: translateY(0);
}

.iframe-scroll-wrapper {
    flex: 1;
    width: 100%;
    overflow: hidden; /* No custom scroll — let the form handle it */
    padding-top: 60px; /* Space for the skip button */
}

.google-form-iframe {
    width: 100%;
    height: 100%; /* Fill the wrapper fully */
    border: none;
    display: block;
}

/* ========================================= */
/* COOKIE CONSENT BANNER                      */
/* ========================================= */
.cookie-banner {
    position: fixed;
    bottom: 30px;
    right: 30px;
    max-width: 400px;
    background: #FFFFFF;
    color: #333333;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    z-index: 9998;
    display: none; /* Hidden by default */
    border: 1px solid rgba(0, 0, 0, 0.05);
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.cookie-banner.active {
    display: block;
    transform: translateY(0);
    opacity: 1;
}

.cookie-content p {
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 16px 0;
    color: #444;
}

.cookie-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.cookie-accept-btn {
    background-color: #1A365D;
    color: #FFFFFF;
    border: none;
    padding: 8px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.cookie-accept-btn:hover {
    background-color: #2D4A77;
}

.cookie-decline-btn {
    background-color: transparent;
    color: #1A365D;
    border: 1px solid #1A365D;
    padding: 8px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cookie-decline-btn:hover {
    background-color: #F8F9FA;
    border-color: #2D4A77;
    color: #2D4A77;
}

@media (max-width: 1440px) {
    .header-container, 
    .hero-container, 
    .explore-container, 
    .about-project-container, 
    .about-cgs-container, 
    .footer-bottom-container,
    .data-container,
    .report-chapters-container,
    .report-summary-container {
        max-width: 1140px;
    }

    .hero-text h1 {
        font-size: 36px;
    }

    .page-hero-title {
        font-size: 46px;
    }

    .branding .cgs-logo {
        height: 64px;
    }

    .footer-bottom-container {
        gap: 60px;
    }
}

@media (max-width: 1200px) {
    .header-container, 
    .hero-container, 
    .explore-container, 
    .about-project-container, 
    .about-cgs-container, 
    .footer-bottom-container {
        padding: 0 24px;
        max-width: 100%;
    }
}

@media (max-width: 1024px) {
    .footer-bottom-container {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }
    
    .footer-grid {
        justify-content: center;
        flex-wrap: wrap;
    }

    .chapter-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .main-nav {
        display: none; /* Hidden by default on mobile */
        position: absolute;
        top: 100%;
        left: 24px;
        right: 24px;
        background: #FFFFFF;
        box-shadow: 0 10px 20px rgba(0,0,0,0.1);
        border-radius: 12px;
        padding: 24px;
        z-index: 1001;
        flex-grow: 0;
    }

    .main-nav.active {
        display: block;
    }

    .main-nav ul a {
        padding: 12px 0;
        width: 100%;
        border-bottom: 1px solid #F0F0F0;
        font-size: 18px; /* Easier to tap */
    }

    .main-nav ul li:last-child a {
        border-bottom: none;
    }

    .hero-container {
        flex-direction: column;
        text-align: center;
        padding-top: 40px;
    }

    .hero-text h1 {
        font-size: 30px; /* Reduced from 32px */
        line-height: 1.1;
        margin-bottom: 20px;
    }

    .hero-text p {
        font-size: 15px; /* Reduced from 16px */
    }

    .hero-image-block {
        margin-top: 40px;
        width: 100%;
    }

    .hero-cover-img {
        max-width: 280px;
        margin: 0 auto;
    }

    .about-cgs-container {
        flex-direction: column;
        align-items: center;
    }

    .about-project-container h2 {
        font-size: 30px; /* Reduced from 32px */
    }

    .about-cgs-text h2 {
        font-size: 26px; /* Reduced from 28px */
    }

    .about-cgs-text p {
        font-size: 13px; /* Reduced from 14px */
    }

    .carousel-slide {
        flex-direction: column;
        padding: 24px;
        text-align: center;
        gap: 30px;
    }

    .slide-image {
        flex: 0 0 auto;
        width: 100%;
        max-width: 260px;
    }

    .slide-content h3 {
        font-size: 20px; /* Reduced from 22px */
    }

    .slide-content p {
        font-size: 14px; /* Reduced from 15px */
    }

    .page-hero-title {
        font-size: 36px;
        padding: 24px;
    }

    .report-summary-text h2 {
        font-size: 30px;
    }

    .report-summary-text p {
        font-size: 14px;
    }

    .report-summary-image {
        flex: 0 0 auto;
        order: -1; 
        margin-bottom: 24px;
        max-width: 220px;
    }

    .report-chapters-container > h2 {
        font-size: 28px;
    }

    .report-actions {
        flex-direction: column;
        width: 100%;
        gap: 12px !important;
    }

    .report-actions .btn-primary {
        width: 100%;
        text-align: center;
    }

    .chapter-grid {
        grid-template-columns: 1fr;
    }

    .chapter-detail-inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .data-table-wrapper {
        overflow-x: auto;
    }

    .data-description {
        font-size: 13px; /* Reduced from 14px */
        line-height: 1.7;
    }

    .data-table thead th, 
    .data-table tbody td {
        padding: 12px 16px;
        font-size: 12px; /* Reduced from 13px */
    }

    .footer-top h2 {
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .site-header {
        margin: 8px;
        padding: 8px 12px;
        position: relative;
    }

    .header-container {
        gap: 10px;
    }

    .branding .cgs-logo {
        height: 36px; /* Even smaller for more space */
    }

    .search-container {
        flex: 1; /* Allow search to take remaining space */
        min-width: 80px;
    }

    .search-input {
        width: 100%;
        font-size: 12px;
        padding: 6px 28px 6px 10px;
    }

    .hero-text h1 {
        font-size: 22px; /* Reduced from 24px */
        padding: 0 10px;
    }

    .hero-text p {
        font-size: 14px; /* Reduced from 15px */
        padding: 0 10px;
    }

    .page-hero-title {
        font-size: 24px; /* Reduced from 26px */
        padding: 20px;
    }

    .carousel-arrow {
        width: 44px;
        height: 44px;
        font-size: 20px;
    }

    .prev-arrow { left: 5px; }
    .next-arrow { right: 5px; }
}

@media (max-width: 360px) {
    .branding .cgs-logo {
        height: 30px;
    }
    
    .search-container {
        display: none; /* Hide search bar on extremely narrow screens to keep logo/menu visible */
    }
}

