/* Navbar styles */
.navbar.custom-navbar {
    background-color: rgba(0, 0, 0, 0.1) !important;
    padding: 0.5rem 1rem;
    transition: top 0.3s ease-in-out, background-color 0.3s ease, color 0.3s ease;
}

.navbar.custom-navbar:hover {
    background-color: rgb(235, 230, 230) !important;
}

.navbar-brand img {
    height: 50px;
    max-width: 100%;
}

.navbar-nav {
    margin: 0;
    display: flex;
    justify-content: space-between; /* Distribute nav items evenly */
    align-items: center;
    width: 100%;
    flex-wrap: nowrap;
}

.navbar-nav .nav-item {
    flex-shrink: 0; /* Prevent shrinking */
    margin: 0 0.5rem; /* Adjust spacing between items */
}

.navbar-nav .nav-link {
    padding: 0.5rem 0.25rem;
    font-size: 20px;
    font-family: "metropolis", sans-serif;
    font-weight: bold;
    color: white !important;
    transition: color 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    white-space: nowrap; /* Prevent text from wrapping */
}

.navbar.custom-navbar:hover .nav-link,
.navbar.custom-navbar.menu-open .nav-link {
    color: black !important;
}

.navbar-nav .nav-link:hover::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background-color: red;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(0, 0, 0, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
    /* Set the color of the hamburger menu lines to black */
}

.navbar-toggler:hover .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(0, 0, 0, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
    /* Ensure the hamburger menu stays black on hover */
}

.navbar-toggler:hover {
    border: 2px solid black; /* Optional: Add a border around the hamburger menu on hover */
}

@media (max-width: 1199.98px) {
    .navbar-nav .nav-link {
        font-size: 0.9rem;
        padding: 0.5rem 0.2rem;
    }

    .navbar-nav .nav-item {
        margin: 0 0.2rem; /* Adjust spacing for smaller screens */
    }
}

@media (max-width: 991.98px) {
    .navbar.custom-navbar {
        background-color: transparent !important;
    }

    .navbar.custom-navbar.menu-open {
        background-color: rgb(235, 230, 230) !important;
    }

    .navbar.custom-navbar.menu-open .nav-link {
        color: black !important;
    }
    
    .navbar-nav {
        flex-direction: column;
        align-items: flex-start;
    }

    .navbar-nav .nav-item {
        margin: 0.25rem 0;
    }

    .navbar-brand img {
        height: 40px;
    }

    .navbar-nav .nav-link {
        font-size: 0.9rem;
    }
}

@media (max-width: 575.98px) {
    .navbar-brand img {
        height: 30px;
    }

    .navbar-nav .nav-link {
        font-size: 0.8rem;
    }
}

.login-icon {
    width: 20px;
    margin-right: 5px;
}

.dropdown-menu-custom {
    display: none;
    flex-direction: column;
    padding: 15px;
    width: auto;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
    position: absolute; /* Ensures correct positioning */
    z-index: 1000; /* Ensures it appears above other content */
}

.dropdown-item-custom {
    display: flex;
    flex-direction: row; /* Keep image and text stacked vertically */
    align-items: center;
    margin-top: 5px 0; /* Increase margin between items */
}

.dropdown-image {
    width: 200px; /* Increase the image size */
    height: 100px; /* Increase the image size */
    margin-right: 10px; /* Space between image and text */
}

.dropdown-item {
    text-align: left;
    color: black;
    font-size: 1rem; /* Increase the text size */
}

.dropdown-item:hover {
    background-color: #f8f9fa !important;
    color: red;
    border-radius: 5px; /* Optional: add rounding on hover */
    transition: background-color 0.3s ease;
}

.container {
    width: 80%;
    margin: auto;
}

table {
    border-collapse: collapse;
    width: 100%;
}

th, td {
    text-align: left;
    padding: 8px;
}

tr:nth-child(even) {
    background-color: #f2f2f2;
}

/* Slideshow styles */
.slideshow-container {
    position: relative;
    max-width: 100%;
    margin: auto;
    height: 450px; /* Adjusted height for smaller scale */
}

.mySlides {
    display: none;
    height: 100%;
    opacity: 0;
    transform: translateY(20px); /* Start slightly below */
    transition: opacity 1s ease-in-out, transform 1s ease-in-out; /* Smooth fade-in and slide-up */
}

.mySlides.active {
    opacity: 1;
    transform: translateY(0); /* Move into position */
}

.mySlides img {
    width: 100%;
    height: 100%; /* Make image fill the container */
    object-fit: cover; /* Ensure image covers the container without distortion */
}

.prev, .next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    width: auto;
    padding: 16px;
    margin-top: -22px;
    color: white;
    font-weight: bold;
    font-size: 18px;
    transition: 0.6s ease;
    border-radius: 0 3px 3px 0;
    user-select: none;
}

.next {
    right: 0;
    border-radius: 3px 0 0 3px;
}

.prev {
    left: 0;
    border-radius: 3px 0 0 3px;
}

.text {
    color: #2bfc5c77;
    font-size: 24px;
    font-weight: bold;
    font-style: italic;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    background: rgba(0, 0, 0, 0.5);
    padding: 5px 10px;
    border-radius: 5px;
}

/* Trip container styles */
.trip-container {
    display: flex;
    justify-content: space-between;
    margin: 20px;
    opacity: 0; /* Initially hidden */
    transform: translateY(20px); /* Start slightly below */
    transition: opacity 1s ease-in-out, transform 1s ease-in-out;
}

/* Form Section */
.trip-form {
    width: 20%;
    padding-right: 20px;
    opacity: 0; /* Initially hidden */
    transform: translateY(20px); /* Start slightly below */
    transition: opacity 1s ease-in-out, transform 1s ease-in-out;
}

.trip-form.fade-in, .trip-container.fade-in {
    opacity: 1;
    transform: translateY(0); /* Move into position */
}

.trip-form h2 {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 10px;
}

.trip-form select,
.trip-form label {
    display: block;
    margin-bottom: 15px;
    font-size: 16px;
}

.trip-form select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.duration-options label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.duration-options input[type="radio"] {
    margin-right: 8px;
}

/* Trip card styles */
.trip-cards {
    width: 75%;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.trip-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    text-align: center;
    flex: 1;
    flex-basis: calc(33.33% - 20px); /* Adjust for gap */
    box-sizing: border-box;
    opacity: 0; /* Initially hidden */
    transform: translateY(20px); /* Start slightly below */
    transition: opacity 1s ease-in-out, transform 1s ease-in-out, transform 0.3s ease, box-shadow 0.3s ease;
}

.trip-card.fade-in {
    opacity: 1;
    transform: translateY(0); /* Move into position */
}
.trip-card:hover {
    transform: scale(1.05); /* Scale up slightly */
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2); /* Increase shadow on hover */
}

.trip-card:nth-child(5n + 1) { /* Target every 5th card starting from the 1st */
    order: 5; /* Place it after the first 4 cards */
}

.trip-card img {
    width: 100%;
    height: 60%;
}

.trip-info {
    padding: 15px;
}

.trip-info h3 {
    font-size: 16px;
    font-weight: bold;
    background-color: black;
    color: white;
    padding: 5px;
    margin: 0;
}

.trip-info p {
    font-size: 14px;
    color: #555;
    margin-top: 10px;
}

@media (max-width: 768px) {
    .trip-cards {
        flex-wrap: wrap;
    }

    .trip-card {
        flex-basis: calc(50% - 20px); /* Adjust for two columns on smaller screens */
    }

    .trip-card:nth-child(5n + 1) {
        order: 3; /* Adjust order for smaller screens if needed */
    }
}
