body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    margin: 0;
    padding-top: 6vh;
    color: #333;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* --- BASE NAVBAR STYLES (MODIFIED) --- */
#NavBar {
    background-color: #f0f0f0;
    /* Use Grid for better control on small screens */
    display: grid;
    /* Defines 3 columns: Logo 1, Logo 2, Hamburger */
    grid-template-columns: auto auto 1fr;
    align-items: center;
    padding: 10px 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    /* Let the height be determined by content on mobile */
    height: auto;
    box-sizing: border-box;
    z-index: 1000;
}

#NavBar a img {
    height: 40px;
}

/* Ensure image hover is transparent and doesn't affect the grid layout */
#NavBar a:nth-child(1),
#NavBar a:nth-child(2) {
    /* No margin-right: auto here anymore, let the grid handle spacing */
    margin-left: 0;
    margin-right: 0;
}

.nav-links-container {
    display: flex;
    align-items: center;
    /* Pushes the container to the right, opposite the logos */
    margin-left: auto;
    grid-column: 3 / 4; /* Place this in the third column on large screens */
    justify-content: flex-end; /* Align links to the right */
}

#NavBar a {
    color: #111111;
    text-decoration: none;
    padding: 8px 15px;
    font-size: 14px;
    font-weight: bold;
    transition: background-color 0.3s;
    border-radius: 4px;
}

#nav-links-id a:hover {
    background-color: #E5002B;
    color: white;
}


/* --- HAMBURGER MENU STYLES (HIDDEN BY DEFAULT) --- */
#menu-toggle {
    display: none; /* Hide the actual checkbox */
}

.menu-icon {
    display: none; /* Hidden by default on large screens */
    font-size: 28px;
    cursor: pointer;
    padding: 5px 10px;
    /* Place icon on the far right of the third column */
    justify-self: end;
}


/* --- MEDIA QUERY: COLLAPSE THE MENU ON SMALL SCREENS --- */
/* Adjust '900px' to the max width before elements start hiding */
@media (max-width: 900px) {

    /* 1. Show the hamburger icon */
    .menu-icon {
        display: block;
    }

    /* 2. Hide the links container by default */
    .nav-links-container {
        display: none;
        /* Make it span across all columns below the header items */
        grid-column: 1 / -1;
        flex-direction: column;
        width: 100%;
        text-align: center;
        padding-bottom: 10px;
    }

    /* Ensure links stack vertically and take up the full width */
    .nav-links-container a {
        display: block;
        margin: 5px 0;
    }

    /* 3. Display the links container when the checkbox is checked */
    #menu-toggle:checked ~ .nav-links-container {
        display: flex;
    }
}

.auth-container {
    background: white;
    padding: 30px 40px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    width: 350px;
    margin: 50px auto;
    align-self: center;
}

h2 {
    text-align: center;
    margin-top: 0;
}

input[type="email"],
input[type="password"],
input[type="text"] {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    display: inline-block;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
    font-size: 16px;
}

button[type="submit"],
#logoutButton {
    background-color: #E5002B;
    color: white;
    border: none;
    cursor: pointer;
    font-size: 16px;
    width: 100%;
    padding: 12px;
    margin-top: 15px;
    border-radius: 4px;
}

button[type="submit"]:hover,
#logoutButton:hover {
    background-color: #CC0026;
}

.separator {
    margin: 20px 0;
    border-bottom: 1px solid #eee;
}

.link-button {
    display: block;
    text-align: center;
    margin-top: 10px;
    color: #051446;
    text-decoration: none;
}

.link-button:hover {
    text-decoration: underline;
}

.error-message:empty {
    display: none;
    color: #d9534f;
    text-align: center;
    margin-top: 10px;
    padding: 10px;
    border: 1px solid #d9534f;
    border-radius: 4px;
    background-color: #f2dede;
}

.info-message:empty {
    display: none;
    color: #337ab7;
    text-align: center;
    margin-top: 10px;
    padding: 10px;
    border: 1px solid #337ab7;
    border-radius: 4px;
    background-color: #d9edf7;
}

.hero-section {
    background: linear-gradient(rgba(5, 20, 70, 0.7), rgba(5, 20, 70, 0.7)), url('Ressources/airplane-hero.png') no-repeat center center/cover;
    color: white;
    text-align: center;
    padding: 100px 20px;
    height: 80vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin-bottom: 40px;
}

.button-primary {
    color: #111111;
}

.hero-section h1 {
    font-size: 3em;
    margin-bottom: 10px;
}

.hero-section p {
    font-size: 1.5em;
    margin-bottom: 30px;
}

.main-content {
    max-width: 1200px;
    margin: 0 auto 50px auto;
    padding: 0 20px;
}

.section-title {
    color: #051446;
    text-align: center;
    margin-bottom: 30px;
    font-size: 2em;
    border-bottom: 2px solid #E5002B;
    padding-bottom: 10px;
}

.news-section {
    padding: 40px 0;
    margin-bottom: 20px;
    background-color: #ffffff;
}

.carousel-container {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    padding: 20px 0;
}

.carousel-track {
    display: flex;
    align-items: center;
    gap: 30px;
    transition: transform 0.4s ease-in-out;
}

.news-card {
    background-color: #ffffff;
    border: 1px solid #ddd;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    width: 300px;
    padding: 15px;
    text-align: center;
    transition: all 0.4s ease;
    cursor: pointer;
    position: relative;
    z-index: 10;
    opacity: 0.6;
    transform: scale(0.95);
    filter: brightness(0.8);
}

.news-card.active {
    z-index: 20;
    opacity: 1;
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
    filter: brightness(1);
    border: 2px solid #E5002B;
}

.news-card .card-image-container {
    width: 100%;
    height: 150px;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 10px;
}

.news-card .card-image {
    width: 300px;
    height: 175px;
    object-fit: cover;
    border-radius: 8px;
}

.news-card h3 {
    color: #051446;
    margin-top: 5px;
}

.news-card p {
    font-size: 0.9em;
    color: #555;
    min-height: 40px;
}

.carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: #E5002B;
    color: white;
    border: none;
    padding: 10px 15px;
    font-size: 24px;
    cursor: pointer;
    z-index: 30;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    line-height: 25px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s;
}

.carousel-nav:hover {
    background-color: #CC0026;
}

.prev-btn {
    left: 0;
}

.next-btn {
    right: 0;
}

.card-container {
    display: flex;
    justify-content: space-around;
    gap: 30px;
    padding: 20px 0;
    flex-wrap: wrap;
}

.discovery-card {
    background-color: #ffffff;
    border: 1px solid #ddd;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 300px;
    padding: 20px;
    text-align: center;
}

.discovery-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2), 0 0 0 2px #000;
    background-color: #f8f8f8;
}

.discovery-card h3 {
    color: #051446;
    margin-top: 15px;
}

.card-image-container {
    width: 100%;
    height: 180px;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 10px;
}

.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.card-button {
    display: inline-block;
    background-color: #E5002B;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 4px;
    margin-top: 15px;
    font-weight: bold;
    transition: background-color 0.3s;
}

.card-button:hover {
    background-color: #CC0026;
}

.destination-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    padding: 20px 0;
    flex-wrap: wrap;
    margin-bottom: 50px;
}

.destination-card {
    background-color: #ffffff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    width: 250px;
    overflow: hidden;
    text-align: center;
    position: relative;
}

.destination-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15), 0 0 0 2px #000;
    background-color: #f5f5f5;
}

.card-image-container {
    width: 100%;
    height: 150px;
    overflow: hidden;
    position: relative;
}

.destination-city {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(5, 20, 70, 0.75);
    color: white;
    padding: 8px 0;
    margin: 0;
    font-size: 1.2em;
    font-weight: bold;
    z-index: 10;
    text-align: center;
}

.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card-details {
    padding: 15px 15px 10px;
    text-align: left;
    background-color: #f9f9f9;
}

.card-details p {
    margin: 5px 0;
    font-size: 0.9em;
    color: #444;
}

.card-details strong {
    color: #051446;
}

.card-button {
    display: block;
    background-color: #E5002B;
    color: white;
    padding: 10px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s;
    border-top: 1px solid #CC0026;
}

.card-button:hover {
    background-color: #CC0026;
}

.member-card {
    background-color: #ffffff;
    border: 1px solid #ddd;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 300px;
    padding: 20px;
    text-align: center;
}

.member-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2), 0 0 0 2px #000;
    background-color: #f8f8f8;
}

.member-card h3 {
    color: #051446;
    margin-top: 15px;
}

.member-card-image-container {
    width: 300px;
    height: 250px;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 10px;
}

.member-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.member-group {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

/* WRAPPER */
.learning-wrapper {
    display: flex;
    gap: 20px;
    margin-top: 20px;
}

/* SIDEBAR */
.sidebar {
    width: 260px;
    background-color: #ffffff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    padding: 15px;
    height: fit-content;
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f4f4f4;
    padding: 10px;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
    border: 1px solid #ddd;
    margin-bottom: 5px;
}

.category-header:hover {
    background-color: #e9e9e9;
}

.arrow {
    display: inline-block;
    transition: transform 0.3s ease;
}

.arrow.open {
    transform: rotate(90deg);
}

.subcategory-list {
    list-style: none;
    margin: 0 0 10px 10px;
    padding: 0;
    display: none;
    animation: slideDown 0.3s ease;
}

.subcategory-list li {
    padding: 8px 10px;
    border-radius: 4px;
    cursor: pointer;
    margin: 3px 0;
    transition: background-color 0.2s;
}

.subcategory-list li:hover {
    background-color: #E5002B;
    color: white;
}

.learning-page-area {
    flex: 1;
}

.page-card {
    background-color: #ffffff;
    border: 1px solid #ddd;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}

.privacy-content {
    max-width: 900px;
    margin: 100px auto 50px auto;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}
.privacy-content h1 {
    color: #051446;
    text-align: center;
    margin-bottom: 30px;
    border-bottom: 2px solid #E5002B;
    padding-bottom: 10px;
}
.privacy-content h2 {
    color: #E5002B;
    margin-top: 30px;
    margin-bottom: 15px;
}
.privacy-content p, .privacy-content ul {
    line-height: 1.7;
    color: #333;
    margin-bottom: 20px;
}
.privacy-content ul {
    list-style-type: disc;
    padding-left: 40px;
}
.privacy-content li {
    margin-bottom: 10px;
}

#Footer {
    margin-top: auto;
    background-color: #333;
    color: white;
    padding: 20px 50px;
    font-size: 0.9em;
    border-top: 5px solid #E5002B;
}

#Footer .footer-content {
    display: flex;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
}

#Footer h4 {
    color: #f0ead6;
    margin-bottom: 10px;
}

#Footer ul {
    list-style: none;
    padding: 0;
}

#Footer ul li a {
    color: #ccc;
    text-decoration: none;
    line-height: 1.6;
}

#Footer ul li a:hover {
    color: #f0ead6;
    text-decoration: underline;
}

#Footer .copyright {
    text-align: center;
    margin-top: 20px;
    padding-top: 10px;
    border-top: 1px solid #444;
}