/* /Components/Layout/MainLayout.razor.rz.scp.css */
.page[b-3scb89lcyt] { position: relative; display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }

main[b-3scb89lcyt] { flex: 1; min-width: 0; display: flex; flex-direction: column; background: var(--paper); }

/* ---- Sidebar: petrol ink ---- */
.sidebar[b-3scb89lcyt] {
    background: linear-gradient(185deg, var(--ink) 0%, var(--ink-deep) 100%);
    border-right: 1px solid rgba(0, 0, 0, .2);
}

/* ---- Top bar ---- */
.top-row[b-3scb89lcyt] {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    height: 3.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}
.top-bar__left[b-3scb89lcyt] { display: flex; align-items: center; gap: .65rem; min-width: 0; }
.top-bar__right[b-3scb89lcyt] { display: flex; align-items: center; gap: .8rem; min-width: 0; }

/* hamburger — mobile only */
.nav-toggle[b-3scb89lcyt] {
    display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; flex: none;
    border: 1px solid var(--border); border-radius: 9px;
    background: var(--surface); color: var(--ink); cursor: pointer; transition: background .15s;
}
.nav-toggle:hover[b-3scb89lcyt] { background: var(--surface-2); }
.brand-mini[b-3scb89lcyt] { display: inline-flex; align-items: center; }
.brand-mini img[b-3scb89lcyt] { height: 24px; display: block; }

/* tenant pill */
.tenant[b-3scb89lcyt] {
    display: inline-flex; align-items: center; gap: .5rem;
    border: 1px solid var(--border); background: var(--surface-2);
    border-radius: 999px; padding: .3rem .55rem .3rem .7rem; font-size: .78rem;
}
.tenant__dot[b-3scb89lcyt] { width: 7px; height: 7px; border-radius: 50%; flex: none;
    background: #3f9a4f; box-shadow: 0 0 0 3px #e7f3ec; }
.tenant__name[b-3scb89lcyt] { color: var(--text); font-weight: 600;
    max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tenant__code[b-3scb89lcyt] { font: 700 .64rem/1 var(--font-mono); letter-spacing: .06em;
    background: var(--brass); color: #fff; padding: .22rem .42rem; border-radius: 5px; }

/* user chip + logout */
.userchip[b-3scb89lcyt] { display: inline-flex; align-items: center; gap: .5rem; min-width: 0; }
.userchip__av[b-3scb89lcyt] { width: 30px; height: 30px; border-radius: 50%; flex: none;
    background: var(--ink); color: #fff; font: 700 .72rem/1 var(--font-sans);
    display: inline-flex; align-items: center; justify-content: center; }
.userchip__name[b-3scb89lcyt] { font-size: .82rem; font-weight: 600; color: var(--text);
    max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-logout-form[b-3scb89lcyt] { margin: 0; display: inline-flex; }
.topbar-logout[b-3scb89lcyt] {
    display: inline-flex; align-items: center; justify-content: center;
    width: 34px; height: 34px; flex: none;
    border: 1px solid var(--border); border-radius: 9px;
    background: var(--surface); color: var(--muted); cursor: pointer; transition: all .15s;
}
.topbar-logout:hover[b-3scb89lcyt] { color: #c0392b; border-color: #e3b4ac; background: #fdf4f2; }

.nav-backdrop[b-3scb89lcyt] { display: none; }

article.content[b-3scb89lcyt] { padding-top: 1.6rem; padding-bottom: 3rem; }

/* ===== mobile (<641): off-canvas sidebar drawer, single top bar ===== */
@media (max-width: 640.98px) {
    .sidebar[b-3scb89lcyt] {
        position: fixed; top: 0; left: 0; bottom: 0; width: 270px; max-width: 84vw; z-index: 60;
        transform: translateX(-100%); transition: transform .25s ease; overflow-y: auto;
    }
    .page.nav-open .sidebar[b-3scb89lcyt] { transform: translateX(0); box-shadow: 0 0 44px rgba(0, 0, 0, .4); }
    .page.nav-open .nav-backdrop[b-3scb89lcyt] { display: block; position: fixed; inset: 0; z-index: 55; background: rgba(8, 20, 24, .45); }
    .tenant__name[b-3scb89lcyt], .userchip__name[b-3scb89lcyt] { display: none; }   /* keep the bar compact */
}

/* ===== desktop (>=641): fixed left sidebar ===== */
@media (min-width: 641px) {
    .page[b-3scb89lcyt] { flex-direction: row; }
    .sidebar[b-3scb89lcyt] { width: 256px; height: 100vh; position: sticky; top: 0; }
    .top-row[b-3scb89lcyt] { position: sticky; top: 0; z-index: 3; }
    .top-row[b-3scb89lcyt], article[b-3scb89lcyt] { padding-left: 2rem !important; padding-right: 2rem !important; }
    .nav-toggle[b-3scb89lcyt], .brand-mini[b-3scb89lcyt] { display: none; }
}

#blazor-error-ui[b-3scb89lcyt] {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0; left: 0; width: 100%;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, .2);
    box-sizing: border-box;
    display: none;
    padding: .6rem 1.25rem .7rem 1.25rem;
    position: fixed;
    z-index: 1000;
}
#blazor-error-ui .dismiss[b-3scb89lcyt] { cursor: pointer; position: absolute; right: .75rem; top: .5rem; }
/* /Components/Layout/NavMenu.razor.rz.scp.css */
/* ---- Brand: AKM logo in a white tile (the logo is a white-bg wordmark; the tile makes it
   read cleanly on the dark sidebar) + a small ERP tag for app identity. ---- */
.brand[b-zcwveu6uv9] {
    display: flex; align-items: center; gap: .6rem;
    height: 3.25rem; padding: 0 1.1rem;
    border-bottom: 1px solid rgba(255,255,255,.08);
}
.brand__logo[b-zcwveu6uv9] { height: 24px; width: auto; display: block; }   /* white AKM mark, sits directly on the dark sidebar */
.brand__erp[b-zcwveu6uv9] { color: var(--brass-bright); font: 700 .72rem/1 var(--font-sans); letter-spacing: .16em; }

/* ---- Scroll area ---- */
.nav-scroll[b-zcwveu6uv9] { overflow-y: auto; height: calc(100vh - 3.25rem); padding: .6rem .6rem 2rem; }
.nav-scroll[b-zcwveu6uv9]::-webkit-scrollbar { width: 8px; }
.nav-scroll[b-zcwveu6uv9]::-webkit-scrollbar-thumb { background: rgba(255,255,255,.12); border-radius: 8px; }

/* ---- Module accordion head ---- */
.nav-mod[b-zcwveu6uv9] { margin-bottom: .1rem; }
.nav-modhead[b-zcwveu6uv9] {
    width: 100%; display: flex; align-items: center; gap: .65rem;
    background: none; border: 0; cursor: pointer;
    padding: .55rem .7rem; border-radius: 8px;
    color: rgba(255,255,255,.74);
    font: 600 .82rem/1 var(--font-sans); text-align: left;
}
.nav-modhead:hover[b-zcwveu6uv9] { background: rgba(255,255,255,.06); color: #fff; }
.nav-modhead .ic[b-zcwveu6uv9] { width: 18px; height: 18px; flex: none; opacity: .85; }
.nav-modhead > span:first-of-type[b-zcwveu6uv9] { flex: 1; }
.nav-modhead .count[b-zcwveu6uv9] {
    font: 600 .6rem/1 var(--font-mono); color: rgba(255,255,255,.4);
    background: rgba(255,255,255,.06); padding: .2rem .35rem; border-radius: 4px;
}
.nav-modhead .chev[b-zcwveu6uv9] { width: 15px; height: 15px; opacity: .5; transition: transform .18s ease; }
.nav-mod.open > .nav-modhead .chev[b-zcwveu6uv9] { transform: rotate(90deg); }
.nav-mod.open > .nav-modhead[b-zcwveu6uv9] { color: #fff; }

/* svg defaults */
.ic[b-zcwveu6uv9], .chev[b-zcwveu6uv9] { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ---- Submenu ---- */
.nav-sub[b-zcwveu6uv9] { margin: .15rem 0 .5rem; padding-left: .85rem;
    border-left: 1px solid rgba(255,255,255,.08); margin-left: 1.1rem; }

/* ---- Items (NavLink renders <a>, hence ::deep) ---- */
.nav-scroll[b-zcwveu6uv9]  .nav-link {
    display: flex; align-items: center; gap: .5rem;
    padding: .42rem .65rem; margin: 1px 0; border-radius: 7px;
    color: rgba(255,255,255,.62); font: 500 .82rem/1.2 var(--font-sans);
    text-decoration: none; cursor: pointer;
}
.nav-scroll[b-zcwveu6uv9]  .nav-link:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav-scroll[b-zcwveu6uv9]  .nav-link.active {
    background: var(--brass-soft); color: var(--brass-bright); font-weight: 600;
    box-shadow: inset 2px 0 0 var(--brass);
}
.nav-scroll[b-zcwveu6uv9]  .nav-link.nav-top { padding: .55rem .7rem; color: rgba(255,255,255,.78); }
.nav-scroll[b-zcwveu6uv9]  .nav-link.nav-top .ic { width: 18px; height: 18px; }

/* soon = disabled stub */
.nav-scroll[b-zcwveu6uv9]  .nav-link.is-soon { color: rgba(255,255,255,.34); cursor: default; }
.nav-scroll[b-zcwveu6uv9]  .nav-link.is-soon:hover { background: none; color: rgba(255,255,255,.45); }
.nav-scroll[b-zcwveu6uv9]  .nav-link.is-soon em {
    margin-left: auto; font: 600 .56rem/1 var(--font-sans); font-style: normal;
    letter-spacing: .08em; text-transform: uppercase;
    color: rgba(255,255,255,.3); border: 1px solid rgba(255,255,255,.14);
    padding: .12rem .3rem; border-radius: 4px;
}

/* Mobile open/close is owned by the layout's off-canvas drawer (MainLayout) — the menu itself
   always renders; the sidebar slides in/out. */
/* /Components/Layout/ReconnectModal.razor.rz.scp.css */
.components-reconnect-first-attempt-visible[b-l9nvybdvh5],
.components-reconnect-repeated-attempt-visible[b-l9nvybdvh5],
.components-reconnect-failed-visible[b-l9nvybdvh5],
.components-pause-visible[b-l9nvybdvh5],
.components-resume-failed-visible[b-l9nvybdvh5],
.components-rejoining-animation[b-l9nvybdvh5] {
    display: none;
}

#components-reconnect-modal.components-reconnect-show .components-reconnect-first-attempt-visible[b-l9nvybdvh5],
#components-reconnect-modal.components-reconnect-show .components-rejoining-animation[b-l9nvybdvh5],
#components-reconnect-modal.components-reconnect-paused .components-pause-visible[b-l9nvybdvh5],
#components-reconnect-modal.components-reconnect-resume-failed .components-resume-failed-visible[b-l9nvybdvh5],
#components-reconnect-modal.components-reconnect-retrying[b-l9nvybdvh5],
#components-reconnect-modal.components-reconnect-retrying .components-reconnect-repeated-attempt-visible[b-l9nvybdvh5],
#components-reconnect-modal.components-reconnect-retrying .components-rejoining-animation[b-l9nvybdvh5],
#components-reconnect-modal.components-reconnect-failed[b-l9nvybdvh5],
#components-reconnect-modal.components-reconnect-failed .components-reconnect-failed-visible[b-l9nvybdvh5] {
    display: block;
}


#components-reconnect-modal[b-l9nvybdvh5] {
    background-color: white;
    width: 20rem;
    margin: 20vh auto;
    padding: 2rem;
    border: 0;
    border-radius: 0.5rem;
    box-shadow: 0 3px 6px 2px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transition: display 0.5s allow-discrete, overlay 0.5s allow-discrete;
    animation: components-reconnect-modal-fadeOutOpacity-b-l9nvybdvh5 0.5s both;
    &[open]

{
    animation: components-reconnect-modal-slideUp-b-l9nvybdvh5 1.5s cubic-bezier(.05, .89, .25, 1.02) 0.3s, components-reconnect-modal-fadeInOpacity-b-l9nvybdvh5 0.5s ease-in-out 0.3s;
    animation-fill-mode: both;
}

}

#components-reconnect-modal[b-l9nvybdvh5]::backdrop {
    background-color: rgba(0, 0, 0, 0.4);
    animation: components-reconnect-modal-fadeInOpacity-b-l9nvybdvh5 0.5s ease-in-out;
    opacity: 1;
}

@keyframes components-reconnect-modal-slideUp-b-l9nvybdvh5 {
    0% {
        transform: translateY(30px) scale(0.95);
    }

    100% {
        transform: translateY(0);
    }
}

@keyframes components-reconnect-modal-fadeInOpacity-b-l9nvybdvh5 {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

@keyframes components-reconnect-modal-fadeOutOpacity-b-l9nvybdvh5 {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

.components-reconnect-container[b-l9nvybdvh5] {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

#components-reconnect-modal p[b-l9nvybdvh5] {
    margin: 0;
    text-align: center;
}

#components-reconnect-modal button[b-l9nvybdvh5] {
    border: 0;
    background-color: #6b9ed2;
    color: white;
    padding: 4px 24px;
    border-radius: 4px;
}

    #components-reconnect-modal button:hover[b-l9nvybdvh5] {
        background-color: #3b6ea2;
    }

    #components-reconnect-modal button:active[b-l9nvybdvh5] {
        background-color: #6b9ed2;
    }

.components-rejoining-animation[b-l9nvybdvh5] {
    position: relative;
    width: 80px;
    height: 80px;
}

    .components-rejoining-animation div[b-l9nvybdvh5] {
        position: absolute;
        border: 3px solid #0087ff;
        opacity: 1;
        border-radius: 50%;
        animation: components-rejoining-animation-b-l9nvybdvh5 1.5s cubic-bezier(0, 0.2, 0.8, 1) infinite;
    }

        .components-rejoining-animation div:nth-child(2)[b-l9nvybdvh5] {
            animation-delay: -0.5s;
        }

@keyframes components-rejoining-animation-b-l9nvybdvh5 {
    0% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 0;
    }

    4.9% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 0;
    }

    5% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 1;
    }

    100% {
        top: 0px;
        left: 0px;
        width: 80px;
        height: 80px;
        opacity: 0;
    }
}
