/* -----------------------------------------
   1. Hover Progress Bar Effect
----------------------------------------- */
.ano-advanced-nav > li {
    position: relative;
}

.ano-advanced-nav > li > a {
    position: relative;
    display: inline-flex;
    align-items: center;
    padding-bottom: 8px; /* space between text and progress bar */
    text-decoration: none;
}

.ano-advanced-nav > li > a .ano-link-text {
    position: relative;
}

/* The animated line */
.ano-advanced-nav > li > a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff007f, #7f00ff); /* Premium gradient */
    transition: width 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    border-radius: 2px;
}

/* Hover state triggers the bar */
.ano-advanced-nav > li:hover > a::after {
    width: 100%;
}


/* -----------------------------------------
   2. Mega Menu Container setup
----------------------------------------- */
/* When mega menu is enabled, drop the native positioning constraints if possible */
.ano-advanced-nav > li.ano-has-mega-menu {
    position: static !important; /* Forces the dropdown to align with header width instead of <li> */
}

/* Mega Menu Box */
.ano-advanced-nav > li.ano-has-mega-menu > ul.ano-mega-menu-wrapper {
    position: absolute;
    left: 5%;
    width: 90%;
    display: none; 
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    padding: 30px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px); /* Glassmorphism background */
    box-shadow: 0 15px 35px rgba(0,0,0,0.08); /* Soft Premium Shadow */
    border-radius: 12px;
    z-index: 99999;
    border: 1px solid rgba(0,0,0,0.04);
    
    /* Animation initial state */
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    margin-top: 15px; /* Spacing below header */
}

/* Reveal logic */
.ano-advanced-nav > li.ano-has-mega-menu:hover > ul.ano-mega-menu-wrapper {
    display: grid !important; 
    opacity: 1;
    transform: translateY(0);
}


/* -----------------------------------------
   3. Mega Menu Card Item Design
----------------------------------------- */
.ano-mega-menu-wrapper > li.ano-card-item {
    list-style: none;
    display: block;
}

.ano-mega-menu-wrapper > li.ano-card-item > a {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 10px;
    background: #fff;
    border: 1px solid transparent;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    overflow: hidden; /* important for image border radius */
    height: 100%;
}

.ano-mega-menu-wrapper > li.ano-card-item > a:hover {
    background: #ffffff;
    box-shadow: 0 8px 24px rgba(0,0,0,0.06);
    border: 1px solid rgba(0,0,0,0.03);
    transform: translateY(-4px); /* Float effect */
}

.ano-card-content {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Card Image */
.ano-card-image {
    width: 100%;
    height: 150px;
    background-size: cover;
    background-position: center;
    transition: transform 0.4s ease;
}

.ano-mega-menu-wrapper > li.ano-card-item > a:hover .ano-card-image {
    transform: scale(1.05); /* Slight zoom on image */
}

/* Text Container */
.ano-card-text {
    display: flex;
    flex-direction: column;
    padding: 16px;
    gap: 6px;
    background: #fff; /* Ensure text covers zoomed image edge seamlessly */
    flex-grow: 1;
    z-index: 2;
    position: relative;
}

/* Typography styles */
.ano-menu-title {
    font-weight: 600;
    font-size: 16px;
    color: #111;
    line-height: 1.2;
    font-family: 'Inter', 'Roboto', 'Helvetica Neue', sans-serif; 
}

.ano-menu-title::after {
    content: "→";
    opacity: 0;
    margin-left: -5px;
    transition: all 0.3s ease;
    display: inline-block;
    color: #ff007f; /* Theme accent */
}

.ano-mega-menu-wrapper > li.ano-card-item > a:hover .ano-menu-title::after {
    opacity: 1;
    margin-left: 8px;
}

.ano-menu-subtitle {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
    font-family: 'Inter', 'Roboto', 'Helvetica Neue', sans-serif;
}
