/* ==========================================================================
   REALISEMOTION RURAL - MASTER SYSTEM LAYOUT RESETS (CONCISE MODEL)
   ========================================================================== */

/* 1. MASTER ENVIRONMENTAL SCREEN ENGINE VIEWPORT LOCKS */
html,
body,
body#PageBody,
body.unselectable {
    margin: 0 !important;
    padding: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    max-height: 100vh !important;
    overflow: hidden !important; /* HARD BLOCK: Freezes the raw browser window boundary */
    display: flex !important;
    flex-direction: column !important;
    box-sizing: border-box !important;
}

/* 2. FIXED COMMAND BAR NAVIGATION HEADER */
body .app-top-header {
    height: 56px !important;
    min-height: 56px !important;
    max-height: 56px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    z-index: 10000 !important;
    width: 100% !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
}

/* 3. DYNAMIC ASYNC ENVIRONMENT VIEWS CANVAS HOUSING SINK */
body .app-view-canvas,
body .mainDivImage {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    padding: 0 16px !important;
    box-sizing: border-box !important;
    overflow: hidden !important; /* HARD OVERFLOW BLOCK: Strips the first outer scrollbar track! */
    position: relative !important;
    width: 100% !important;
    height: calc(100vh - 116px) !important; /* Clear height footprint layout calculation */
    min-height: auto !important; /* FIXED: Overrides template relative height leakage bugs */
}
    /* ==========================================================================
   4. FIXED SINGULAR SCROLLWAY CONTAINER TRAYS
   ========================================================================== */

    /* 
   THE PARENT CLAMP ENGINE:
   Forcefully freezes all parent wrapper blocks, stripping out the duplicate 
   inner container scrollbar and fixing your layout boundaries concise!
*/
    body .app-view-canvas > div,
    body .workspace-center-panel,
    body .settings-workspace-wrapper,
    div[id^="divContentHolder_"] {
        width: 100% !important;
        max-width: 640px !important; /* Tight width clamp keeps console panels layout centered */
        height: 100% !important;
        max-height: calc(100vh - 120px) !important;
        display: flex !important;
        flex-direction: column !important;
        box-sizing: border-box !important;
        overflow: hidden !important; /* HARD OVERFLOW BLOCK: Kills the second, duplicate inner container scrollbar! */
        background-color: transparent !important;
        border: none !important;
        padding: 0 !important;
        margin: 0 auto !important;
    }

    /* ==========================================================================
   5. FIXED SYSTEM NAV NAVBAR FOOTER TRAY STICKY PERSISTENCE
   ========================================================================== */
    footer#globalAppBottomNavbar.app-bottom-navbar,
    html body#PageBody footer#globalAppBottomNavbar,
    body footer {
        height: 60px !important;
        min-height: 60px !important;
        max-height: 60px !important;
        display: flex !important; /* FIXED: Locks your horizontal bar visible on screen even after script postbacks! */
        align-items: center !important;
        justify-content: center !important; /* FORCES SYSTEM CONTAINER TO STAY PERFECTLY CENTERED HORIZONTALLY */
        padding: 0 24px !important;
        z-index: 99999 !important;
        width: 100% !important;
        position: fixed !important; /* FIXED: Forces footer to stick flat against the absolute screen base bounds */
        bottom: 0 !important;
        left: 0 !important;
        flex-shrink: 0 !important; /* ROADBLOCK: Defeats footer compression anomalies */
        box-sizing: border-box !important;
    }

.nav-toolbar-hub {
    display: flex !important;
    flex-direction: row !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 500px !important;
    justify-content: center !important; /* CENTRES THE FOOTER NAV PILLS ROW FLAT INSIDE VISUAL FIELDS */
    align-items: center !important;
    margin: 0 auto !important; /* CRITICAL: Hard-centers the hub element on screen glass */
    box-sizing: border-box !important;
    height: 100% !important;
}

.custom-nav-pill,
body footer button {
    font-size: 0.75rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    padding: 0 18px !important;
    height: 40px !important;
    max-height: 40px !important;
    border-radius: 4px !important;
    cursor: pointer !important;
    flex: 1 !important;
    display: inline-flex !important;
    align-items: center !important; /* FIXED: Forcefully centers the text vertically inside nav pills! */
    justify-content: center !important; /* FIXED: Centers horizontal text tracks layout */
    text-align: center !important;
    margin: 0 !important; /* FIXED: Eradicates Bootstrap default left alignment margins! */
    line-height: 1 !important;
    box-shadow: none !important;
}