
/* Keep dropdown menus within the visible viewport */
.metismenu.mod-menu .mm-collapse {
    max-height: calc(100vh - 180px);
    overflow-y: auto;
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: auto;
}

/* Allow the dropdown to use the available width */
.metismenu.mod-menu .mm-collapse {
    box-sizing: border-box;
}


/* Allow scrolling throughout the dropdown menu */
.metismenu.mod-menu .mm-collapse {
    overflow-y: auto;
    overscroll-behavior-y: contain;
    pointer-events: auto;
}

/* Ensure submenu items do not create separate scroll areas */
.metismenu.mod-menu .mm-collapse > li,
.metismenu.mod-menu .mm-collapse > li > a,
.metismenu.mod-menu .mm-collapse > li > span {
    pointer-events: auto;
}


/* Refined submenu indicator for Cassiopeia Extended */
.metismenu.mod-menu .parent-indicator {
    border: none;
    background: transparent;
    box-shadow: none;
}

/* Style the indicator icon */
.metismenu.mod-menu .parent-indicator .icon-chevron-down,
.metismenu.mod-menu .parent-indicator svg {
    width: 0.7rem;
    height: 0.7rem;
    stroke-width: 1.5;
    opacity: 0.7;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

/* Subtle hover feedback */
.metismenu.mod-menu .parent-indicator:hover svg {
    opacity: 1;
}


/* Slightly indent dropdown submenus */
.metismenu.mod-menu .mm-collapse {
    margin-left: 60px;
}





/* =========================================
   Professional submenu indicators
   Joomla 6 - Cassiopeia Extended
   ========================================= */

/* Remove the default triangle from the indicator button */
.metismenu.mod-menu .parent-indicator {
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    font-size: 0;
}

/* Draw a fine chevron using CSS */
.metismenu.mod-menu .parent-indicator::after {
    content: "";
    display: inline-block;
    width: 7px;
    height: 7px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg);
    margin-top: -4px;
    opacity: 0.65;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

/* Subtle hover effect */
.metismenu.mod-menu .parent-indicator:hover::after {
    opacity: 1;
}
