/* General Styles */
body {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    background-color: #f7f7f7;
    color: #333333;
}

/* Top Navigation Bar */
.nav-logo {
    width: 40px;
    height: auto;
    margin-right: 20px;
}

header {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #ffffff;
    padding: 18px 20px;
    border-bottom: 2px solid #2a3b5f;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
    overflow: visible;
}

header nav {
    display: flex;
    justify-content: center;
    /* Centers the menu options */
    align-items: center;
    width: 100%;
    overflow: visible;
    white-space: normal;
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 20px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    /* Allows items to wrap if needed */
    width: 100%;
    overflow: visible;
}

nav ul li {
    position: relative;
    flex-shrink: 0;
    overflow: visible;
}

nav ul li a {
    text-decoration: none;
    color: #2a3b5f;
    font-weight: bold;
    font-size: 18px;
    padding: 8px 14px;
    transition: color 0.3s ease, background-color 0.3s ease;
    white-space: nowrap;
}

nav ul li a:hover,
nav ul li a.active {
    color: #ffffff;
    background-color: #2a3b5f;
    border-radius: 5px;
}

/* Default for desktop */
.dropdown .dropdown-content {
    position: absolute;
    top: 100%;
    left: 0;
    display: none;
    background-color: #fff;
    border: 1px solid #2a3b5f;
    border-radius: 5px;
    min-width: 160px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.1);
    z-index: 9999;
}

/* Mobile override */
@media (max-width: 768px) {
  .mobile-nav .dropdown .dropdown-content {
      position: fixed;
      top: 60px;
      left: 5%;
      right: 5%;
      display: none;
      background-color: #fff;
      border: 1px solid #2a3b5f;
      border-radius: 5px;
      box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
      z-index: 9999;
  }

  .mobile-nav .dropdown:hover .dropdown-content {
      display: block;
  }
}

.dropdown:hover .dropdown-content {
    display: block;
}

.dropdown-content a {
    display: block;
    padding: 10px;
    text-decoration: none;
    color: #2a3b5f;
    font-size: 16px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.dropdown-content a:hover {
    background-color: #2a3b5f;
    color: #ffffff;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 50px 20px;
    background: #2a3b5f;
    color: #ffffff;
}

/* Gallery Section */
.gallery {
    padding: 20px;
    text-align: center;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.gallery-grid img {
    width: 100%;
    border-radius: 10px;
    transition: transform 0.3s ease;
}

.gallery-grid img:hover {
    transform: scale(1.05);
}

/* Scheduling Section */
.schedule {
    padding: 20px;
    background-color: #ffffff;
    text-align: center;
}

.calendar-container,
.contact-details {
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

input,
select,
button {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #ccc;
}

button {
    background-color: #2a3b5f;
    color: #ffffff;
    cursor: pointer;
}

button:hover {
    background-color: #1f2a4d;
}

/* Footer */
footer {
    background-color: #ffffff;
    text-align: center;
    padding: 20px;
}

/* Scroll Button Styles */
.scroll-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background-color: #2a3b5f;
    color: #ffffff;
    border: none;
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
    z-index: 1000;
}

.scroll-button:hover {
    background-color: #1f2a4d;
    transform: translateY(-2px);
}

.scroll-button svg {
    width: 24px;
    height: 24px;
}

/* Mobile Styles */
@media (max-width: 768px) {
    /* Mobile and Tablet Styles */

    .desktop-nav {
        display: none;
    }

    .mobile-nav {
        display: block;
    }

    .contact-section {
        display: none;
    }

    /* Nav Wrapper */
    .nav-scroll-wrapper {
        display: block;
        overflow-x: auto;
        overflow-y: visible;
        position: relative;
        z-index: 1000;
        background-color: #fff;
        isolation: isolate;
    }

    .nav-scroll-wrapper::-webkit-scrollbar {
        display: none;
    }

    header nav {
        display: flex;
        align-items: center;
        white-space: nowrap;
        width: max-content;
        overflow: visible;
    }

    nav ul {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 20px;
        padding: 0 16px;
        margin: 0;
        list-style: none;
        overflow: visible;
        position: relative;
        z-index: 1001;
        white-space: nowrap;
    }

    nav ul li {
        flex-shrink: 0;
        scroll-snap-align: start;
        position: relative;
        overflow: visible;
    }

    nav ul li a {
        font-size: 14px;
        padding: 8px 12px;
        white-space: nowrap;
        text-decoration: none;
        font-weight: bold;
        color: #2a3b5f;
        display: inline-block;
    }

    nav ul li.dropdown {
        position: relative;
    }

    /* Mobile Dropdowns */
    .mobile-nav .dropdown .dropdown-content {
        position: fixed;
        top: 60px;
        /* adjust to match header height */
        left: 5%;
        right: 5%;
        display: none;
        background-color: #fff;
        border: 1px solid #2a3b5f;
        border-radius: 5px;
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
        z-index: 9999;
    }

    .mobile-nav .dropdown:hover .dropdown-content {
        display: block;
    }


    .hero {
        padding: 40px 20px;
        /* Adjust padding for mobile */
        padding-top: 120px;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        /* Adjust grid for smaller screens */
    }

    .schedule {
        padding: 20px;
        text-align: center;
    }

    /* Contact Section */
    .contact-section {
        position: absolute;
        top: 90px;
        /* Adjust for fixed header */
        padding: 20px;
        width: 100%;
        text-align: center;
        background-color: rgba(255, 255, 255, 0.8);
        /* Adjust background for contrast */
        border-radius: 10px;
        /* Rounded corners */
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    }

    .contact-section h2 {
        font-size: 22px;
    }

    .contact-section p {
        font-size: 14px;
    }

    .contact-section .btn-blue {
        font-size: 14px;
        padding: 10px 15px;
        /* Adjust button padding for mobile */
    }

    .scroll-button {
        width: 45px;
        height: 45px;
    }
}