/* BB Mega Menu – Frontend Styles
   ================================================ */

/* ── Container ──────────────────────────────────── */

.sdbmm-has-mega {
    position: static !important; /* override relative so panel can be full-width */
}

/* ── Panel ──────────────────────────────────────── */

.sdbmm-panel {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 9999;

    /* Hidden by default */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(8px);
    transition:
        opacity   .3s ease,
        transform .3s ease,
        visibility 0s   .3s;
}

/* Open state */
.sdbmm-has-mega.sdbmm-open > .sdbmm-panel,
.sdbmm-has-mega:focus-within > .sdbmm-panel {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
    transition:
        opacity   .3s ease,
        transform .3s ease;
}

/* ── Width variants ─────────────────────────────── */

.sdbmm-panel.sdbmm-panel-width-full {
    left: 0;
    right: 0;
    width: 100vw;
    /* Push back to left edge of viewport when menu isn't flush */
    margin-left: calc( (100vw - 100%) / -2 );
}

.sdbmm-panel.sdbmm-panel-width-container {
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    width: min(1200px, 96vw);
}

.sdbmm-has-mega.sdbmm-open > .sdbmm-panel.sdbmm-panel-width-container,
.sdbmm-has-mega:focus-within > .sdbmm-panel.sdbmm-panel-width-container {
    transform: translateX(-50%) translateY(0);
}

.sdbmm-panel.sdbmm-panel-width-auto {
    left: 0;
    min-width: 320px;
    width: max-content;
    max-width: 96vw;
}

/* ── Toggle button & chevron icon ───────────────── */

/* Standalone toggle button injected after the <a> */
.sdbmm-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    padding: 0 6px;
    margin: 0;
    cursor: pointer;
    color: inherit;
    font-size: inherit;
    line-height: inherit;
    vertical-align: middle;
    /* Match the link height so it doesn't push the row taller */
    height: 100%;
}

.sdbmm-toggle:focus {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

/* ── Chevron arrow on parent item (FontAwesome) ─── */

.sdbmm-has-mega{
    padding-right: 20px !important;
} 

.sdbmm-has-mega:hover .sdbmm-toggle{
	transform: scaleY(-1);
	-webkit-transform: scaleY(-1);
	-moz-transform: scaleY(-1);
	margin-top: -18px;
	opacity: 1;
	color: #DE7356 !important;
}

/* The <i> chevron icon injected by JS */
.sdbmm-toggle{
    padding: 0;
    background: unset !important;
    border: unset !important;
    color: #101E23;
    appearance: unset;
    line-height: 1;
    border-radius: unset;
    height: auto;
    display: block;
	margin-top: -20px;
    margin-right: -24px;
    float: right;
}
.sdbmm-chevron {
    font-size: .75em;
    line-height: 1;
}

/* Rotate chevron when open */
.sdbmm-has-mega.sdbmm-open > a .sdbmm-chevron,
.sdbmm-has-mega:focus-within > a .sdbmm-chevron {
    transform: scaleY(-1);
    -webkit-transform: scaleY(-1);
    -moz-transform: scaleY(-1);
    opacity: 1;
}

/* ── Inner wrapper ──────────────────────────────── */

.sdbmm-panel-inner {
    padding: 0;
}

/* Remove BB's default margin-bottom on last row */
.sdbmm-panel-inner .fl-row:last-child {
    margin-bottom: 0;
}

/* ── Accessibility: skip invisible panels ───────── */
.sdbmm-panel[aria-hidden="true"] * {
    visibility: hidden;
}



/* ── Mobile: stack panels below nav item ────────── */
@media (max-width: 1024px) {
    .sdbmm-has-mega.sdbmm-open > .sdbmm-panel {
        display: block;
    }

    .sdbmm-panel-inner {
        padding: 0;
    }
    .sdbmm-toggle{
        position: unset;
        margin-top: 0;
        margin-right: 0;
        float: unset;
    }
}
