/*
 * DD Vertical Menu Widget — base structural styles.
 * Color/typography are added inline by Elementor's Style tab controls;
 * this file only handles reset + layout structure.
 */

.dd-vmenu,
.dd-vmenu-level {
    list-style: none;
    margin: 0;
    padding: 0;
}

.dd-vmenu {
    display: block;
    width: 100%;
}

.dd-vmenu-level {
    display: block;
}

.dd-vmenu li {
    display: block;
}

.dd-vmenu a {
    display: block;
    width: fit-content;
    text-decoration: none;
    box-sizing: border-box;
    border-style: solid;
    border-width: 0;
    border-color: transparent;
    transition: border-color var(--dd-vmenu-transition, 200ms) ease, color var(--dd-vmenu-transition, 200ms) ease;
}

/* Fixed "space before text" padding — nested items get it by default,
   top-level items don't unless the indent-top-level modifier is present. */
.dd-vmenu-level .dd-vmenu-level {
    padding-left: var(--dd-vmenu-indent, 0px);
}

.dd-vmenu--indent-top > .dd-vmenu-level > li {
    padding-left: var(--dd-vmenu-indent, 0px);
}

/* Nested submenu wrappers push their own items right of their parent —
   this is a plain descendant selector so it naturally cascades: each
   additional nesting level stacks another margin-left on top of the one
   already applied to its ancestor .dd-vmenu-level. The root list is
   excluded since it's not itself nested inside another .dd-vmenu-level. */
.dd-vmenu-level .dd-vmenu-level {
    margin-left: var(--dd-vmenu-indent, 0px);
}

/* When top-level items are flush left (indent-top-level off), the submenu
   directly under a top-level item shouldn't also get this cascading margin
   — its anchors' own fixed padding already gives it exactly one indent
   step relative to its flush parent. Only deeper nesting (grandchild
   submenus and beyond) should keep stacking margin on top of that. This
   is more specific than the rule above, so it wins for this one level. */
.dd-vmenu:not(.dd-vmenu--indent-top) > .dd-vmenu-level > li > .dd-vmenu-level {
    margin-left: 0;
}

/* Nested levels are never hidden — always expanded, no toggle/JS involved */
.dd-vmenu .dd-vmenu-level {
    display: block !important;
}
