/* GLOBAL BOXES & LAYOUT OVERRIDES [bs-merge - version=2], uses --legacy-rem
   This file is only loaded on v2 — html.me-sv-2 prefix is not needed anywhere here. */


/*  SECTION HEADER  */

.pagewidth {
    width: 960px;
    margin-left: auto;
    margin-right: auto;
    position: relative;
}

#m_section_header {
    background: #fff;
    border-bottom: 1px solid #e5e5e5;
}

#m_section_header > .pagewidth {
    display: flex;
    align-items: center;
    height: 52px;
}

/* v2: tighter section header */
#m_section_header > .pagewidth { height: 42px; }

/* v0: section title */
#m_section_title {
    display: flex;
    align-items: center;
    font-size: calc(var(--legacy-rem) * 1.25px);
    font-weight: 700;
    color: #212529;
    white-space: nowrap;
    line-height: 1;
    padding-right: 20px;
}

#m_section_title #m_section_show { display: none; }
#m_section_title  { display: none; }

/* v0: section nav */
#m_section_nav { flex: 1; }
#m_section_nav  { display: none; }

#m_section_nav .section_menu {
    display: flex;
    align-items: stretch;
    list-style: none;
    margin: 0;
    padding: 0;
    height: 52px;
}

#m_section_nav .section_menu li {
    display: flex;
    align-items: stretch;
    margin: 0;
    padding: 0;
}

#m_section_nav .section_menu li.title { display: none; }

#m_section_nav .section_menu li a {
    display: flex;
    align-items: center;
    color: #212529;
    text-decoration: none;
    font-size: calc(var(--legacy-rem) * 1.167px);
    padding: 0 1em;
    border-bottom: 3px solid transparent;
    white-space: nowrap;
}

#m_section_nav .section_menu li.selected a,
#m_section_nav .section_menu li.selected a:hover,
#m_section_nav .section_menu li a:hover {
    border-bottom-color: #ad974f;
    outline: none;
}

/* Buttons — hidden */
#m_section_buttons { display: none; }


/*  Browse button (sidenav toggle, tablet only) ─ */
.bc-browse-btn {
    display: none;
}

/*  bc-bar overrides ─ */
.navbar-brand { padding-top: 0; padding-bottom: 0; }


/*  MAIN LAYOUT  */

#m_main_fade {
    position: absolute;
    top: 0;
    display: none;
}

#m_main {
    padding-top: 20px;
    padding-bottom: 100px;
    height: auto;
    min-height: calc(100vh - 700px);
}

#m_main *,
#m_main *::before,
#m_main *::after {
    box-sizing: content-box;
}

#m_main .me-ui *,
#m_main .me-ui *::before,
#m_main .me-ui *::after {
    box-sizing: border-box;
}

#m_content_wrapper {
    float: left;
    width: 100%;
    min-height: 1px;
    max-width: 970px;
}

#m_content {
    padding: 0;
    text-align: left;
    min-height: 1px;
}

#m_sub_section_title { display: none; }

#m_sub_section_nav {
    float: left;
    text-align: left;
    width: 190px;
    min-height: 1px;
    margin-left: -100%;
}


/*  SIDENAV  */

/* Section label above menu items */
.me-sv2-sidenav-heading {
    font-size: calc(var(--legacy-rem) * 1px);
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #b0b0b0;
    padding: 0 calc(var(--legacy-rem) * 0.833px) calc(var(--legacy-rem) * 0.833px);
    margin-right: calc(var(--legacy-rem) * 0.667px);
    line-height: 1;
    border: none;
    border-bottom: 1px solid #e8e8e8;
    margin-bottom: 8px;
}

/* Layout row: flow-root BFC contains floated children; bounds sticky sidenav height */
.me-sv2-layout-row {
    display: flow-root;
}

/* Sidenav container */
#m_sub_section_nav {
    display: flex;
    flex-direction: column;
    z-index: 2;
    margin-left: calc(-100% - 10px);
    margin-top: -20px;
    padding-top: 20px;
    position: sticky;
    top: 10px;
    border-right: 1px solid #e8e8e8;
    overflow-x: hidden;
    background: #fff;
}

/* !important required — overrides inline SubSectionNavStyle attribute */
#m_content.me-sv2-has-sidenav { margin-left: 200px !important; }

/* Menu list grows to push CTA to bottom */
#m_sub_section_nav .side_menu {
    flex: 1;
    border: none;
    width: auto;
    background: transparent;
    box-shadow: none;
    border-radius: 0;
    margin: 5px;
}

#m_sub_section_nav .side_menu .mainlink {
    background: none;
    margin-bottom: 1px;
}

/* Nav items */
#m_main #m_sub_section_nav .side_menu .mainlink > a,
#m_main #m_sub_section_nav .side_menu .mainlink > a:visited {
    display: block;
    font-size: calc(var(--legacy-rem) * 1.083px);
    font-family: inherit;
    font-weight: 400;
    color: #4a4a4a;
    background: none;
    background-image: none;
    padding: 5px 10px;
    margin: 0;
    text-decoration: none;
    text-transform: none;
    letter-spacing: normal;
    line-height: 1.4;
    border: none;
    border-radius: 6px;
    text-shadow: none;
    cursor: pointer;
    pointer-events: auto;
    position: static;
    transition: background 90ms, color 90ms;
    white-space: normal;
}
#m_main #m_sub_section_nav .side_menu .mainlink > a:hover {
    color: #111;
    background: rgba(0,0,0,.06);
    background-image: none;
}

/* Active item */
#m_main #m_sub_section_nav .side_menu .mainlink > a.selected,
#m_main #m_sub_section_nav .side_menu .mainlink > a.selected:visited {
    color: #fff;
    font-weight: 400;
    background: #4a4a4a;
    background-image: none;
    border: none;
}
#m_main #m_sub_section_nav .side_menu .mainlink > a.selected:hover {
    background: #555;
    color: #fff;
}

/* Hide legacy arrow icon */
#m_sub_section_nav .side_menu .expandable_icon { display: none; }

/* Dividers */
#m_sub_section_nav .side_menu .maindivider {
    height: 1px;
    background: #e8e8e8;
    border: none;
    box-shadow: none;
}

/* Sub-items (AddSubMenuItem) */
#m_sub_section_nav .side_menu ul {
    list-style: none;
    margin: 2px 0 6px;
    padding: 0;
    box-shadow: none;
    border: none;
}
#m_sub_section_nav .side_menu ul li { margin: 0; }

#m_main #m_sub_section_nav .side_menu ul li a,
#m_main #m_sub_section_nav .side_menu ul li a:visited {
    display: block;
    font-size: calc(var(--legacy-rem) * 1px);
    font-family: inherit;
    color: #888;
    background: none;
    background-image: none;
    padding: 5px 10px 5px 18px;
    text-decoration: none;
    text-transform: none;
    letter-spacing: normal;
    border: none;
    border-left: 2px solid #e0e0e0;
    border-radius: 0 4px 4px 0;
    line-height: 1.4;
    transition: background 90ms, color 90ms, border-color 90ms;
}
#m_main #m_sub_section_nav .side_menu ul li a:hover {
    color: #111;
    background: rgba(0,0,0,.05);
    background-image: none;
    border-left-color: #aaa;
}
#m_main #m_sub_section_nav .side_menu ul li a.selected,
#m_main #m_sub_section_nav .side_menu ul li a.selected:visited {
    color: #111;
    font-weight: 600;
    background: none;
    background-image: none;
    border-left-color: #1a1a1a;
}

/* Sub-child items (ul.subchild): deeper nesting */
#m_sub_section_nav .side_menu ul.subchild {
    list-style: square inside;
    padding-left: 36px;
    margin: 2px;
}
#m_sub_section_nav .side_menu ul.subchild li { border-left: none; }
#m_sub_section_nav .side_menu ul.subchild li::marker { color: #ccc; }
#m_main #m_sub_section_nav .side_menu ul.subchild li a,
#m_main #m_sub_section_nav .side_menu ul.subchild li a:visited {
    padding: 3px 10px 3px 0;
    border-left: none;
    border-radius: 4px;
}
#m_main #m_sub_section_nav .side_menu ul.subchild li a:hover      { border-left: none; }
#m_sub_section_nav .side_menu ul.subchild li:hover::marker { color: #888; }
#m_main #m_sub_section_nav .side_menu ul.subchild li a.selected,
#m_main #m_sub_section_nav .side_menu ul.subchild li a.selected:visited { border-left: none; }
#m_sub_section_nav .side_menu ul.subchild li:has(a.selected)::marker { color: #1a1a1a; }

/* CTA block */
#m_sub_section_nav .me-sv2-sidenav-cta {
    margin-top: 24px;
    padding: 20px 8px;
    border-top: 1px solid #e8e8e8;
}
#m_sub_section_nav .me-sv2-sidenav-cta-btn {
    display: block;
    box-sizing: content-box;
    width: auto;
    padding: 11px 10px;
    background: #1a1a1a;
    color: #fff !important;
    font-size: calc(var(--legacy-rem) * 1.083px);
    font-weight: 600;
    text-align: center;
    text-decoration: none !important;
    border-radius: 6px;
    line-height: 1.3;
    letter-spacing: .01em;
    transition: background 100ms;
}
#m_sub_section_nav .me-sv2-sidenav-cta-btn:hover {
    background: #333;
    color: #fff !important;
}

/* Collapsed state — JS toggles .me-nav-collapsed on <html> */
.me-nav-collapsed #m_sub_section_title,
.me-nav-collapsed #m_sub_section_nav { display: none; }
/* !important required — overrides inline SubSectionNavStyle attribute */
.me-nav-collapsed #m_content.me-sv2-has-sidenav { margin-left: 0 !important;}


#m_nav_panel_data,
#m_nav_key_data { display: none; }

#m_actions_wrapper {
    margin-top: 1em;
    float: left;
    width: 100%;
    min-height: 1px;
}

header,
footer,
.footer {
    font-size: calc(var(--legacy-rem) * .9px);
}

.me-single-page #m_main {
    background: none;
    padding-top: 0;
}

.me-micro #m_content_wrapper,
.me-theme-r #m_content_wrapper {
    min-height: calc(90vh);
}

/* ExternalPage / modal */
.me-ep .pagewidth,
.me-modal .pagewidth {
    width: auto;
    max-width: 1280px;
}

.me-app .pagewidth,
.me-modal .pagewidth {
    width: auto;
    max-width: 100%;
}

.me-ep #m_main,
.me-modal #m_main {
    background: none !important;
    background-image: none;
    padding: 0;
    height: auto;
}

.me-ep #m_content,
.me-ep body,
.me-modal #m_content,
.me-modal body {
    background: none !important;
}

/*  ≥961px (desktop footer)  */
@media screen and (min-width: 961px) {
    .me-theme-r div.m_footer {
        padding: calc(var(--legacy-rem) * 0.5px) calc(var(--legacy-rem) * 2px) calc(var(--legacy-rem) * 1px) 2em;
        position: relative;
    }
    .me-theme-r div.footer {
        margin: 0 auto;
    }
}


/*  ≤991px (tablet + mobile)  */
@media (max-width: 991px) {

    /* Section header: responsive width */
    #m_section_header > .pagewidth {
        width: auto;
    }

    #m_content { margin-top: 0 !important; }

    #m_main > .pagewidth {
        width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    #m_content_wrapper {
        float: none;
        width: 100%;
        max-width: 100%;
        margin-left: 0;
        box-sizing: border-box;
    }

    #m_main img {
        max-width: 100%;
        height: auto;
    }
}


/*  ≤960px (.mob footer)  */
@media screen and (max-width: 960px) {

    .me-theme-r div.m_footer {
        padding: calc(var(--legacy-rem) * 0.5px) 0 calc(var(--legacy-rem) * 1px) 0;
        height: auto;
        min-width: inherit;
        min-height: 80px;
        position: relative;
    }
    .me-theme-r div.m_mitsubishi {
        min-height: 1px;
        float: none;
    }
    .me-theme-r div.m_facebook {
        position: absolute;
        right: 55px;
        top: 1.3em;
    }
    .me-theme-r div.m_youtube {
        position: absolute;
        right: 10px;
        top: 1.3em;
    }
    .me-theme-r div.m_footer_nav {
        text-align: left;
        min-width: inherit;
        min-height: 1px;
        float: none;
        margin: 0;
        padding: calc(var(--legacy-rem) * 1px) 0;
    }
    .me-theme-r div.m_copyright {
        text-align: left;
        float: inherit;
        margin: 0;
        clear: right;
    }
}


@media(min-width: 769px){
    .me-nav-collapsed #m_section_header .bc-browse-btn ~ .sub-nav {
        display: flex;
    }
}

/*  768–991px (tablet)  */
@media (min-width: 768px) and (max-width: 991px) {

    /* Browse button: sidenav toggle */
    .bc-browse-btn {
        width: 30px;
        height: 30px;
        border: none;
        background: rgba(0,0,0,.06); /* active: sidenav is showing */
        border-radius: 6px;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        margin-right: 10px;
        color: #212529;
        padding: 0;
        transition: color 150ms, background 150ms;
    }
    .bc-browse-btn:hover                  { background: rgba(0,0,0,.10); color: #212529; }
    .me-nav-collapsed .bc-browse-btn      { background: none; color: #888; }
    .me-nav-collapsed .bc-browse-btn:hover { background: rgba(0,0,0,.06); color: #555; }

    .me-nav-collapsed #m_content.me-sv2-has-sidenav {
        padding: 15px;
    }


    /* Section nav links: hide when sidenav is visible, restore when sidenav is collapsed */
    #m_section_header .bc-browse-btn ~ .sub-nav       { display: none; }

    /* Re-apply float layout so sidenav and content sit side by side */
    #m_content_wrapper { float: left; width: 100%; }
    #m_content.me-sv2-has-sidenav { margin-left: 185px !important; }

    /* Sidenav: slightly tighter width */
    #m_sub_section_nav {
        width: 175px;
        margin-left: -100%;
    }

    #top_content, #tabbed_content, .tab-content {
        border: none !important;
        margin-top: -8px;
    }
    #m_content_wrapper #catteaser_wrapper_compact {
        width: 700px;
        margin-left: auto;
        margin-right: auto;
    }
    #m_content_wrapper .slidesjs-container {
        margin-bottom: 32px;
    }
    #m_content_wrapper .gallery-wrapper{
        max-width: 550px;
        margin-bottom: 10px;
    }
    #m_section_header{
        padding: 0 0.5rem;
    }
}


/*  BACK TO TOP  */

#me-back-to-top {
    display: none;
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 40px;
    height: 40px;
    background: #1a1a1a;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    z-index: 9990;
    box-sizing: border-box;
    transition: background 100ms;
}

#me-back-to-top.me-btt-visible {
    display: flex;
}

#me-back-to-top:hover {
    background: #333;
}

#me-back-to-top:focus-visible {
    outline: 2px solid #ad974f;
    outline-offset: 2px;
}


/*  ≤767px (mobile)  */
@media (max-width: 767px) {

    /* Remove sidenav-induced content margin */
    #m_content.me-sv2-has-sidenav,
    .me-nav-collapsed #m_content.me-sv2-has-sidenav { margin-left: 0 !important; }

    /* Sidenav hidden — section links injected into global sidebar */
    #m_sub_section_nav { display: none; }

    /* Backdrop: injected by section-header-v2.js */
    #me-nav-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,.6);
        z-index: 9998;
        opacity: 0;
        pointer-events: none;
        transition: opacity 260ms ease-out;
    }
}
