#header {
    width: 100%;
    height: 50px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(245, 245, 245, 0.95) 100%);
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    padding: 0px 40px;
    box-shadow: 0px 3px 15px rgba(0, 0, 0, 0.1);
    margin: 0;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 2000;
    animation: slideDownFadeIn 0.8s ease-out;
    transition: transform 0.3s ease;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

@keyframes slideDownFadeIn {
  0% {
    opacity: 0;
    transform: translateY(-20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

#header.transparent-blur {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.8) 0%, rgba(245, 245, 245, 0.8) 100%);
    backdrop-filter: saturate(180%) blur(10px);
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
}

.site-header {
    margin-bottom: 30px;
}

#header .h-logo {
    display: flex;
    align-items: center;
    height: 100%;
    color: black;
    font-weight: bold;
    padding-top: 3px;
    z-index: 2000;
    margin-right: auto;
}

#header .logo-img {
    width: 22px;
    height: auto;
    transition: 0.3s ease;
}

#header .logo-img:hover {
    opacity: 0.8;
}

.nav-container {
    display: flex;
    align-items: center;
}

.menu-toggle {
    display: none;
    font-size: 26px;
    color: #555;
    cursor: pointer;
    position: absolute;
    top: 10px;
    right: 20px;
    background-color: #e0e0e0;
}

.menu-toggle span,
.menu-toggle span::before,
.menu-toggle span::after {
    display: block;
    background: #333;
    width: 16px;
    height: 1px;
    position: absolute;
    transition: all 0.3s ease;
}

.menu-toggle span {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.menu-toggle span::before {
    content: '';
    top: -6px;
}

.menu-toggle span::after {
    content: '';
    bottom: -6px;
}

.menu-toggle.active span {
    background: transparent;
}

.menu-toggle.active span::before {
    transform: rotate(45deg);
    top: 0;
}

.menu-toggle.active span::after {
    transform: rotate(-45deg);
    bottom: 0;
}

#header .nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
    justify-content: center;
    align-items: center;
    height: 100%;
}

#header .nav-links .list,
#header .nav-links .list a {
    display: flex;
    height: 100%;
    align-items: center;
    text-align: center;
    color: #333333;
    text-decoration: none;
    padding: 10px 8px;
    font-size: 12px;
    transition: 0.2s;
}

.sendMail-btn {
    max-height: 40px;
    background: linear-gradient(135deg, #4F9CF9 0%, #6C63FF 100%);
    color: #ffffff;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.sendMail-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(79, 156, 249, 0.3);
}

.copy-email-btn {
    border: none;
    color: #ffffff;
    font-size: 14px;
    padding: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
    background: transparent;
}

.copy-email-btn:hover {
    color: #ffffff;
    background-color: transparent;
    opacity: 0.8;
}

#header .nav-links li a:hover {
    opacity: 0.8;
}

.mobile-only {
    display: none;
}

@media screen and (max-width: 1400px) {
    .mobile-only {
        display: none;
    }

    #header {
        height: 65px;
        padding: 0px 40px;
    }

    #header .h-logo {
        position: absolute;
        top: 2px;
        left: 50%;
        transform: translateX(-50%);
        margin: 0;
    }

    #header .logo-img {
        width: 30px;
    }

    .menu-toggle {
        font-size: 24px;
        font-weight: 300;
        text-align: center;
        display: flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        top: 16px;
        left: 16px;
        width: 35px;
        height: 35px;
        border: 1px solid rgba(0, 0, 0, 0.1);
        border-radius: 5px;
        padding: 0;
        background-color: #eaeaea;
        color: #000000;
        transition: 0.2s;
    }

    .menu-toggle span,
    .menu-toggle span::before,
    .menu-toggle span::after {
        width: 20px;
    }

    .menu-toggle.active {
        color: #000000;
        background-color: #e5e5e5;
    }

    .menu-toggle:hover {
        color: #000000;
        background-color: rgba(0, 0, 0, 0.1);
    }

    .nav-container {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 65px;
        left: 0;
        z-index: 980;
        align-items: center;
        opacity: 0;
        transform: translateY(-10px);
        transition: all 0.3s ease;
        max-height: 90vh;
        overflow-y: auto;
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(245, 245, 245, 0.95) 100%);
        backdrop-filter: blur(10px);
        box-shadow: 0px 3px 15px rgba(0, 0, 0, 0.1);
        border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    }

    .nav-container.active {
        display: flex !important;
        padding: 15px 0px;
        opacity: 1;
        transform: translateY(0);
    }

    .nav-container.transparent-blur-mobile {
        will-change: backdrop-filter;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    #header .nav-links {
        flex-direction: column;
        gap: 10px;
        width: 100%;
        align-items: center;
        color: #ffffff;
    }

    #header .nav-links .list {
        display: block;
        width: 100%;
        text-align: center;
        padding: 0px 0px;
        cursor: pointer;
    }

    #header .nav-links .list a {
        display: grid;
        align-items: center;
        width: 100%;
        padding: 16px 0px; /* increased for touch */
        font-size: 16px; /* slightly larger text */
        cursor: pointer;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        touch-action: manipulation;
    }


    #header .nav-links li a {
        font-size: 14px;
    }

    .sendMail-btn {
        display: none;
        border-radius: 0px;
        padding: 0px 15px;
        cursor: pointer;
        background-color: #435d7c;
    }

    .nav-container.smooth {
        transition: max-height 0.4s ease, opacity 0.4s ease, transform 0.4s ease;
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        transform: translateY(-15px);
    }

    .nav-container.active.smooth {
        max-height: 650px;
        opacity: 1;
        transform: translateY(0);
    }

    #header .menu-toggle {
        left: 16px !important;
        right: auto !important;
    }

    .nav-container.transparent-blur {
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(245, 245, 245, 0.95) 100%);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }

    #header.menu-open {
        padding-top: 50px;
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(245, 245, 245, 0.95) 100%);
    }

    @keyframes slideFadeIn {
        0% {
            opacity: 0;
            transform: translateY(-10px);
        }
        100% {
            opacity: 1;
            transform: translateY(0);
        }
    }

    @keyframes slideFadeOut {
        0% {
            opacity: 1;
            transform: translateY(0);
        }
        100% {
            opacity: 0;
            transform: translateY(-10px);
        }
    }

    .nav-container.animate-in {
        animation: slideFadeIn 0.3s ease forwards;
    }

    .nav-container.animate-out {
        animation: slideFadeOut 0.3s ease forwards;
    }


    .nav-links .dropdown-menu-mobile {
        display: none;
        flex-direction: column;
        width: 100%;
    }

    .nav-links .dropdown-menu-mobile.show {
        display: flex;
    }

    .nav-links .dropdown-menu-mobile li a {
        padding-left: 24px;
        font-size: 13px;
    }

    .nav-links .dropdown {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .nav-links .dropdown a {
        padding: 12px 0;
        border-bottom: 1px solid rgba(0, 0, 0, 0.1);
        width: 100%;
        text-align: center;
    }

    .nav-links .dropdown-mobile-toggle {
        background: none;
        border: none;
        color: #333333;
        font-size: 13px;
        margin-top: -8px;
        margin-bottom: 6px;
        cursor: pointer;
    }

    .nav-links .dropdown-menu {
        position: static;
        background-color: transparent;
        display: flex;
        opacity: 1;
        transform: none;
        pointer-events: auto;
        padding: 0;
        border-radius: 0;
    }

    .nav-links .dropdown-menu li,
    .nav-links .dropdown-menu li a {
        padding: 14px 0; /* increased for touch */
        font-size: 15px; /* slightly larger text */
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        touch-action: manipulation; /* added for touch */
    }
}

/* Dropdown base */
.nav-links .dropdown {
    position: relative;
}

.nav-links .dropdown-menu {
    position: absolute;
    top: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(245, 245, 245, 0.95) 100%);
    display: none;
    flex-direction: column;
    text-align: center;
    min-width: 150px;
    min-height: 100%;
    opacity: 0;
    transform: translateY(-10px) translateX(-50%);
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 2000;
    left: 50%;
    padding: 5px 5px;
    pointer-events: none;
    transform: translateX(-50%);
    border-radius: 0px 0px 10px 10px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.nav-links .dropdown-menu li,
.nav-links .dropdown-menu li a {
    width: 100%;
    max-height: 60px;
    align-items: center;
    text-align: center;
    /* border-bottom: 1px solid rgba(255, 255, 255, 0.15); */
    padding: 20px 15px;
    display: block;
    font-size: 14px;
    color: #ffffff;
    transition: 0.2s;
}

.nav-links .dropdown:hover .dropdown-menu {
    display: flex;
    pointer-events: auto;
    animation: dropdownFadeIn 0.3s ease forwards;
}


/* Mobile adjustments */
@media screen and (max-width: 768px) {
    .nav-links .dropdown-menu {
        position: relative;
        top: 0;
        background-color: rgba(0, 0, 0, 0);
    }
}

@keyframes dropdownFadeIn {
    0% {
        opacity: 0;
        transform: translateY(-10px) translateX(-50%);
    }
    100% {
        opacity: 1;
        transform: translateY(0) translateX(-50%);
    }
}
/* ===== Church Section Nav Custom Styles ===== */
#church-section-nav {
    display: flex;
    align-items: center;
    height: 100%;
}

#church-section-nav .dropdown {
    display: flex;
    align-items: center;
    height: 100%;
}

#church-section-nav .dropdown a {
    color: #333;
    padding: 10px 12px;
    text-decoration: none;
    font-size: 12px;
    transition: background-color 0.3s ease;
}

