#mmenu > div.scrollable {
    height: 100%;
}

#mmenu .inside #mmenu_bottom {
    position: static;
    display: block;
    padding: 0 20px calc(20px + env(safe-area-inset-bottom));
}

#mmenu .bh-mobile-contact {
    border-top: 1px solid #ddd;
    padding-top: 16px;
}

#mmenu .bh-mobile-contact address {
    font-style: normal;
}

#mmenu .bh-mobile-contact p {
    margin: 0 0 10px;
}

#mmenu .bh-mobile-contact .mod_socials {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

#mmenu .bh-mobile-contact .mod_socials a {
    display: inline-grid;
    place-items: center;
    min-width: 44px;
    min-height: 44px;
}

#mmenu nav.mobile_horizontal .bh-jagd-menu summary {
    cursor: pointer;
    padding: 10px;
    background: transparent;
    color: inherit;
    font-weight: 700;
}

#mmenu nav.mobile_horizontal .bh-jagd-menu details[open] > ul > li {
    display: block;
}

#mmenu .bh-mobile-secondary ul {
    display: flex;
    flex-wrap: wrap;
    gap: 0 12px;
    list-style: none;
    margin: 0 0 8px;
    padding: 0;
}

#mmenu .bh-mobile-secondary a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 0.875rem;
}

#mmenu .bh-mobile-secondary a[aria-current="page"] {
    text-decoration: underline;
}

#mmenu .bh-mobile-order {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    margin: 0 0 12px;
    border-top: 1px solid #ddd;
    padding-top: 16px;
}

#mmenu .bh-mobile-order-button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 46px;
    flex: 1 1 140px;
    padding: 8px 14px;
    border-radius: 3px;
    background: #CA1C20;
    color: #fff;
    font-weight: 700;
    text-align: center;
}

#mmenu .bh-mobile-order-phone {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 46px;
    flex: 1 1 140px;
    color: #035139;
    white-space: nowrap;
    font-weight: 700;
    border: 1px solid #035139;
    border-radius: 3px;
    padding: 8px 12px;
}

#mmenu .bh-mobile-order a:focus-visible {
    outline: 2px solid #035139;
    outline-offset: 3px;
}

#mmenu .bh-mobile-contact {
    font-size: 0.9rem;
    line-height: 1.6;
}

#mmenu .bh-mobile-contact .mod_socials {
    margin-right: 0;
}

#mmenu .bh-mobile-secondary ul {
    justify-content: space-between;
    gap: 0 8px;
}

@media (max-width: 360px) {
    #mmenu .inside #mmenu_bottom {
        padding-left: 14px;
        padding-right: 14px;
    }
    #mmenu .bh-mobile-secondary a {
        font-size: 0.8rem;
    }
}

/* Tablet: keep one menu trigger alongside the order button. */
@media (min-width: 768px) and (max-width: 1024px) {
    #header .logo {
        width: clamp(220px, 32vw, 300px);
    }

    #top .top_divider #holzbestellen {
        right: 96px;
        margin-left: 0;
        white-space: nowrap;
    }

    #header .inside > .smartmenu {
        position: absolute;
        top: 11px;
        right: 40px;
        float: none;
        width: 44px;
        height: 54px;
        margin: 0;
    }

    #header .inside > .smartmenu .smartmenu-trigger {
        width: 44px;
        height: 54px;
    }

    #header .inside > .smartmenu ~ .smartmenu {
        display: none;
    }
}

/* The sticky header also contains duplicate tablet menu modules. */
@media (min-width: 768px) and (max-width: 1024px) {
    .stickyheader .smartmenu ~ .smartmenu {
        display: none;
    }
}

/* Tablet contact bar: keep each contact item together and icons on one row. */
@media (min-width: 768px) and (max-width: 1024px) {
    #top > .inside {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: nowrap;
        gap: 12px;
        min-height: 40px;
        padding-left: 24px;
        padding-right: 24px;
    }

    #top .mod_top_mail,
    #top .top_divider,
    #top .mod_socials {
        float: none;
        margin: 0;
        width: auto;
        line-height: 1.35;
    }

    #top .mod_top_mail {
        flex: 0 0 auto;
        white-space: nowrap;
        font-size: 11px;
    }

    #top .mod_top_mail a {
        display: inline-flex;
        align-items: center;
        gap: 5px;
    }

    #top .mod_top_mail i {
        margin: 0;
    }

    #top .top_divider {
        flex: 1 1 auto;
        min-width: 0;
        text-align: center;
        font-size: 11px;
        padding-top: 5px;
        padding-bottom: 5px;
    }

    #top .mod_socials {
        display: flex;
        flex: 0 0 auto;
        align-items: center;
        gap: 10px;
        white-space: nowrap;
    }

    #top .mod_socials a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        float: none;
        margin: 0;
        width: 18px;
        min-height: 32px;
    }

    #top .clear {
        display: none;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    #top .top_divider #holzbestellen {
        top: 40px;
        line-height: 40px;
    }
}
