/* Hamburger Menu */
.hamburger div {
    transition: all 0.3s ease;
}

.hamburger.active div:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

.hamburger.active div:nth-child(2) {
    opacity: 0;
}

.hamburger.active div:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
}

/* Property Badge */
.property-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #d97706; /* mh-amber */
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

/* Shadows */
.header-shadow {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.mobile-menu {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    transition:
        transform 0.3s ease,
        opacity 0.3s ease;
    transform: translateY(-100%);
    opacity: 0;
    display: none; /* Explicitly hidden by default */
}

.mobile-menu:not(.hidden) {
    transform: translateY(0);
    opacity: 1;
    display: block; /* Explicitly shown when not hidden */
}

/* Button Styles */
.contact-btn,
.phone-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    backdrop-filter: blur(12px);
    border-width: 1px;
    transition: all 0.3s ease;
    overflow: hidden;
}

.contact-btn:hover,
.phone-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(26, 75, 95, 0.3);
}

.app-button-line {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-size: 200% 100%;
    animation: gradientMove 3s linear infinite;
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.4s ease;
}

.contact-btn:hover .app-button-line,
.phone-btn:hover .app-button-line {
    transform: scaleX(1);
}

/* Navbar Link Styles */
.nav-link {
    transition: all 0.3s ease;
}

.nav-link:hover {
    transform: scale(1.03);
}

.active {
    color: #f59e0b; /* mh-gold */
    transform: scale(1.05);
    text-shadow: 0 0 5px rgba(245, 158, 11, 0.5);
    position: relative;
}

.nav-underline {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(
        90deg,
        #2a7d7b,
        #f59e0b,
        #2a7d7b
    ); /* mh-teal, mh-gold, mh-teal */
    background-size: 200% 100%;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.active .nav-underline {
    transform: scaleX(1);
    animation: gradientMove 3s ease infinite;
}

/* Mobile Menu Styles */
.mobile-nav-link {
    transition: all 0.3s ease;
    transform: translateX(-20px);
    opacity: 0;
    animation: slideInMobile 0.3s ease-out forwards;
}

.mobile-menu:not(.hidden) .mobile-nav-link:nth-child(1) {
    animation-delay: 0.1s;
}
.mobile-menu:not(.hidden) .mobile-nav-link:nth-child(2) {
    animation-delay: 0.2s;
}
.mobile-menu:not(.hidden) .mobile-nav-link:nth-child(3) {
    animation-delay: 0.3s;
}
.mobile-menu:not(.hidden) .mobile-nav-link:nth-child(4) {
    animation-delay: 0.4s;
}
.mobile-menu:not(.hidden) .mobile-nav-link:nth-child(5) {
    animation-delay: 0.5s;
}
.mobile-menu:not(.hidden) .mobile-nav-link:nth-child(6) {
    animation-delay: 0.6s;
}
.mobile-menu:not(.hidden) .mobile-nav-link:nth-child(7) {
    animation-delay: 0.7s;
}

.mobile-menu .active {
    background: #1a4b5f; /* mh-deep-teal */
    color: #f59e0b; /* mh-gold */
    transform: translateX(0);
    opacity: 1;
}

/* Animations */
@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@keyframes slideInMobile {
    from {
        transform: translateX(-20px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Responsive Adjustments */
@media (max-width: 900px) {
    .property-badge {
        top: -6px;
        right: -6px;
        width: 16px;
        height: 16px;
        font-size: 10px;
    }
}

@media (min-width: 1280px) {
    .contact-btn,
    .phone-btn {
        padding: 0.5rem 1.25rem; /* xl:py-2 xl:px-5 */
    }
}
