/* /public_html/assets/css/ui-mobile-topbar.css */

@media (max-width: 719px) {
    body.is-dashboard-shell-visible .app-header {
        position: sticky;
        top: 0;
        display: block;
        min-height: calc(env(safe-area-inset-top, 0px) + 3.25rem);
        height: calc(env(safe-area-inset-top, 0px) + 3.25rem);
        padding: 0;
        background: transparent;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        border-bottom: 0 !important;
        box-shadow: none !important;
        overflow: visible;
    }

    body.is-dashboard-shell-visible .app-header > :not(.mobile-shell-navbar) {
        display: none !important;
    }

    body.is-dashboard-shell-visible #app-root {
        padding-top: 0 !important;
    }

    body.is-dashboard-shell-visible #dashboard-app-shell,
    body.is-dashboard-shell-visible .dashboard-app-main,
    body.is-dashboard-shell-visible #dashboard-view {
        margin-top: 0 !important;
        padding-top: 0 !important;
    }

    body.is-dashboard-shell-visible .app-header::before {
        content: "";
        position: absolute;
        inset: 0;
        pointer-events: none;
        z-index: 0;
        background: color-mix(in srgb, var(--color-bg, #020617) 14%, transparent);
        backdrop-filter: blur(20px) saturate(1.12);
        -webkit-backdrop-filter: blur(20px) saturate(1.12);

        -webkit-mask-image: linear-gradient(
            to bottom,
            rgba(0, 0, 0, 1) 0%,
            rgba(0, 0, 0, 1) 60%,
            rgba(0, 0, 0, 0.82) 76%,
            rgba(0, 0, 0, 0.46) 88%,
            rgba(0, 0, 0, 0.12) 96%,
            rgba(0, 0, 0, 0) 100%
        );
        mask-image: linear-gradient(
            to bottom,
            rgba(0, 0, 0, 1) 0%,
            rgba(0, 0, 0, 1) 60%,
            rgba(0, 0, 0, 0.82) 76%,
            rgba(0, 0, 0, 0.46) 88%,
            rgba(0, 0, 0, 0.12) 96%,
            rgba(0, 0, 0, 0) 100%
        );
    }

    .mobile-shell-navbar {
        position: relative;
        z-index: 1;
        display: block;
        width: 100%;
        height: 100%;
        min-height: calc(env(safe-area-inset-top, 0px) + 3.25rem);
        padding-top: env(safe-area-inset-top, 0px);
        padding-inline: 0.75rem;
    }

    .mobile-shell-navbar.is-hidden {
        display: none !important;
    }

    .mobile-shell-navbar__left,
    .mobile-shell-navbar__center,
    .mobile-shell-navbar__right {
        position: absolute;
        top: calc(env(safe-area-inset-top, 0px) + 1.625rem);
        transform: translateY(-50%);
        min-height: 2.5rem;
        z-index: 2;
    }

    .mobile-shell-navbar__left {
        left: 0.75rem;
        display: inline-flex;
        align-items: center;
        justify-content: flex-start;
    }

    .mobile-shell-navbar__right {
        right: 0.75rem;
        display: inline-flex;
        align-items: center;
        justify-content: flex-end;
        gap: 0.45rem;
    }

    .mobile-shell-navbar__center {
        left: 50%;
        transform: translate(-50%, -50%);
        display: flex;
        align-items: center;
        justify-content: center;
        width: calc(100% - 8.75rem);
        max-width: 14rem;
        min-width: 0;
        font-size: 1rem;
        font-weight: 800;
        line-height: 1.1;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        pointer-events: none;
        z-index: 1;
    }

    .mobile-shell-navbar.is-dashboard .mobile-shell-navbar__center {
        width: calc(100% - 6.5rem);
    }

    .mobile-shell-navbar__logo {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: auto;
        max-width: 9rem;
        max-height: 3rem;
    }

    .mobile-shell-navbar__logo .app-logo,
    .mobile-shell-navbar__logo .app-brand-btn,
    .mobile-shell-navbar__logo .app-brand-label {
        display: none !important;
    }

    .mobile-shell-navbar__logo svg,
    .mobile-shell-navbar__logo img {
        display: block;
        width: auto;
        max-width: 100%;
        max-height: 3rem;
    }

    .mobile-shell-navbar__btn {
        width: 2.5rem;
        min-width: 2.5rem;
        height: 2.5rem;
        min-height: 2.5rem;
        padding: 0;
        border-radius: 999px;
        border: 1px solid color-mix(in srgb, var(--color-border-subtle, rgba(255,255,255,0.18)) 78%, transparent);
        background: color-mix(in srgb, var(--color-surface, rgba(255,255,255,0.08)) 34%, transparent);
        backdrop-filter: blur(18px) saturate(1.1);
        -webkit-backdrop-filter: blur(18px) saturate(1.1);
        color: inherit;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        box-shadow: none;
    }

    .mobile-shell-navbar__btn--primary {
        border-color: color-mix(in srgb, var(--color-primary, #fb7185) 48%, rgba(255,255,255,0.12));
        background: color-mix(in srgb, var(--color-primary, #fb7185) 12%, transparent);
    }


    .mobile-shell-navbar__btn[data-mobile-shell-menu-trigger="1"].is-menu-open {
        border-color: transparent;
        background: transparent;
        box-shadow: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        transform: none;
    }

    .mobile-shell-navbar__btn[data-mobile-shell-menu-trigger="1"].is-menu-open i {
        transform: scale(0.86);
        opacity: 0;
        transition: transform 160ms ease, opacity 160ms ease;
    }

    .mobile-shell-navbar__btn i {
        font-size: 1rem;
        line-height: 1;
    }

    .mobile-shell-navbar__btn.has-badge {
        position: relative;
    }

    .mobile-shell-navbar__btn.has-badge::after {
        content: attr(data-badge-count);
        position: absolute;
        top: -0.18rem;
        right: -0.18rem;
        min-width: 1.08rem;
        height: 1.08rem;
        padding: 0 0.26rem;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: rgba(255, 255, 255, 0.9);
        color: rgba(2, 6, 23, 0.92);
        font-size: 0.64rem;
        font-weight: 900;
        line-height: 1;
        letter-spacing: -0.01em;
        box-shadow: 0 4px 14px rgba(2, 6, 23, 0.22);
    }

    .mobile-shell-navbar__btn.has-badge.has-badge-priority::after {
        background: rgba(251, 113, 133, 0.98);
        color: #fff;
    }

    .mobile-shell-navbar__btn[data-mobile-shell-menu-trigger="1"].is-menu-open.has-badge::after {
        opacity: 0;
        transform: scale(0.6);
    }

    body.is-dashboard-shell-visible[data-dashboard-shell-topbar-mode="icon"] .panel-mobile-title,
    body.is-dashboard-shell-visible[data-dashboard-shell-topbar-mode="icon"] .students-panel-mobile-title,
    body.is-dashboard-shell-visible[data-dashboard-shell-topbar-mode="icon"] .teachers-panel-mobile-title,
    body.is-dashboard-shell-visible[data-dashboard-shell-topbar-mode="icon"] .edq-panel-shell__mobile-title {
        display: none !important;
    }
}
