﻿/* =========================================================
   STATERA ERP – APPLICATION SHELL
   Outlook / Enterprise Layout
   ========================================================= */

/* =========================
   BASE
   ========================= */

:root {
    --statera-font: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

html, body {
    height: 100%;
    margin: 0;
    font-family: "Segoe UI", Arial, sans-serif;
    background: #f5f7fb;
    overflow: hidden; /* ✅ add this */
}

/* =========================
   SHELL
   ========================= */

.statera-shell {
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden; /* 🔑 prevents footer scroll */
}

/* =========================
   TOP BAR
   ========================= */

.statera-topbar {
    height: 54px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 18px;
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.company-icon {
    width: 100px;
    height: auto;
}

.product-name {
    font-size: 15px;
    color: #3b6fa3; /* Steel blue */
    font-weight: 600; /* optional – looks good in headers */
}

.topbar-search {
    flex: 1;
    display: flex;
    justify-content: center;
}

    .topbar-search input {
        width: 420px;
        max-width: 100%;
        height: 38px;
        padding: 0 16px;
        border-radius: 19px;
        border: 1px solid #d1d5db;
        font-size: 14px;
        background: #ffffff;
    }

        .topbar-search input:focus {
            border-color: #2F5FA7;
            outline: none;
        }

.topbar-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.settings {
    width: 40px;
    height: 40px;
}

.avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
}

/* =========================
   WORKSPACE
   ========================= */

.statera-workspace {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* =========================
   WORKSPACE BODY
   ========================= */

.statera-workspace-body {
    display: flex;
    flex: 1;
    min-height: 0;
}

/* =========================
   SUB NAV
   ========================= */


/* =========================
   MAIN CONTENT
   ========================= */

.statera-content {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden; /* ✅ FIX */
}


/* =========================
   AVATAR PANEL
   ========================= */

.avatar-panel-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.15);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    z-index: 1000;
}

.avatar-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: 320px;
    height: 100vh;
    background: #ffffff;
    box-shadow: -4px 0 16px rgba(0,0,0,0.08);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    z-index: 1001;
}

.statera-shell.avatar-open .avatar-panel {
    transform: translateX(0);
}

.statera-shell.avatar-open .avatar-panel-overlay {
    opacity: 1;
    pointer-events: auto;
}

.topbar-right .k-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.topbar-left .k-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.topbar-left .k-svg-icon {
    width: 22px;
    height: 22px;
    fill: #6b7a90;
    transition: fill 0.15s ease;
}

/* Hover */
.topbar-left span.hover .k-svg-icon {
    fill: #3a6ea5;
}

/* Active */
.topbar-left span.active .k-svg-icon {
    fill: #2b6cb0;
}

/* 🔑 THIS is the icon you actually see */
.topbar-right .k-svg-icon {
    width: 22px;
    height: 22px;
    fill: #6b7a90;
    transition: fill 0.15s ease;
}

/* Hover */
.topbar-right span.hover .k-svg-icon {
    fill: #3a6ea5;
}

/* Active */
.topbar-right span.active .k-svg-icon {
    fill: #2b6cb0;
}

body.avatar-open .avatar-panel {
    transform: translateX(0);
}

body.avatar-open .avatar-panel-overlay {
    opacity: 1;
    pointer-events: auto;
}

/* =========================
   AVATAR PANEL IMAGE FIX
   ========================= */

.avatar-panel-header {
    display: flex;
    align-items: center;
    gap: 14px;
}

.avatar-large {
    width: 48px; /* 🔑 lock size */
    height: 48px;
    min-width: 48px; /* prevent flex stretch */
    min-height: 48px;
    border-radius: 50%;
    object-fit: cover; /* crop instead of stretch */
    display: block;
}

/* =========================
   AVATAR PANEL MENU
   ========================= */

.avatar-panel-menu {
    list-style: none;
    margin: 0;
    padding: 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

    /* Menu items */
    .avatar-panel-menu li {
        padding: 10px 12px;
        border-radius: 6px;
        cursor: pointer;
        font-size: 14px;
        font-weight: 500;
        color: #111827;
        display: flex;
        align-items: center;
        gap: 10px;
        transition: background-color 0.15s ease, color 0.15s ease;
    }

        /* Hover */
        .avatar-panel-menu li:hover {
            background: #f3f4f6;
        }

        /* Divider */
        .avatar-panel-menu li.divider {
            height: 1px;
            background: #e5e7eb;
            margin: 8px 0;
            padding: 0;
            pointer-events: none;
        }

        /* Sign out (danger) */
        .avatar-panel-menu li.signout {
            color: #b91c1c;
            font-weight: 600;
        }

            .avatar-panel-menu li.signout:hover {
                background: rgba(185, 28, 28, 0.08);
            }

.statera-menubar li,
.statera-menubar .k-menu,
.statera-menubar .k-menu ul,
.statera-menubar .k-item {
    list-style: none !important;
    margin: 0;
    padding: 0;
}

.statera-main-content ul {
    list-style: none;
    padding: 0;
}

.statera-main {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
}


/* Force Kendo tab content to participate in flex layout */






/* ============================= */
/* STATERA STICKY FOOTER         */
/* ============================= */

.statera-footer {
    flex: 0 0 auto; /* 🔑 footer height is fixed */
    height: 44px;
    position: relative;
    bottom: 0;
    z-index: 100;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    height: 44px;
    padding: 0 16px;
    background: linear-gradient( to right, #2f5d87, #2b577f );
    color: #e8eef5;
    font-size: 13px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    position: relative; /* NOT sticky */
}

/* LEFT PANEL */
.footer-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-logo {
    width: 24px;
    height: 24px;
    border-radius: 50%; /* 👈 makes it circular */
    background: rgba(255, 255, 255, 0.15);
    padding: 4px; /* space between logo + circle */
    box-sizing: content-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.footer-app-name {
    font-weight: 600;
    letter-spacing: 0.3px;
}

/* CENTER PANEL */
.footer-center {
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.footer-muted {
    color: rgba(232, 238, 245, 0.7);
}

/* RIGHT PANEL */
.footer-right {
    white-space: nowrap;
    font-size: 12px;
    opacity: 0.85;
}


/* Top bar icon*/
.topbar-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    cursor: pointer;
    color: #3b6fa3;
    opacity: 0.85;
    transition: background-color 0.18s ease, color 0.18s ease, transform 0.12s ease;
}

/* Hover */
.topbar-icon:hover {
    background-color: rgba(59, 111, 163, 0.12);
    color: #2f5d87;
    opacity: 1;
}

/* Keyboard focus */
.topbar-icon:focus-visible {
    outline: 2px solid rgba(59, 111, 163, 0.5);
    outline-offset: 2px;
}

/* Active / pressed */
.topbar-icon:active {
    transform: scale(0.94);
}

.topbar-search input {
    width: 360px;
    height: 40px;
    padding-left: 40px; /* space for icon */
    padding-right: 14px;
    border-radius: 10px;
    border: 1px solid #c9d4e2;
    font-size: 14px;
    background: #ffffff;
    color: #24384d;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.topbar-search {
    position: relative;
    display: flex;
    align-items: center;
}

    /* INPUT */
    .topbar-search input {
        width: 360px;
        height: 40px;
        padding-left: 40px;
        padding-right: 14px;
        border-radius: 10px;
        border: 1px solid #c9d4e2;
        font-size: 14px;
        background: #ffffff;
        color: #24384d;
        position: relative;
        z-index: 1; /* 👈 input sits below icon */

        transition: border-color 0.18s ease, box-shadow 0.18s ease;
    }

/* ICON */
.search-icon {
    position: absolute;
    left: 14px;
    font-size: 16px;
    color: #3b6fa3;
    opacity: 0.7;
    z-index: 2; /* 👈 icon above input */
    pointer-events: none;
}

.topbar-search .k-icon {
    width: 16px;
    height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    line-height: 1;
}

/* ============================= */
/* TOP BAR SEARCH (LOCKED)       */
/* ============================= */

.topbar-search {
    display: flex;
    align-items: center;
    width: 360px; /* 👈 FIXED, intentional */
    height: 38px;
    background: #ffffff;
    border: 1px solid #c9d4e2;
    border-radius: 25px;
    padding: 0 12px;
    flex: 0 0 auto; /* 👈 DO NOT GROW */
}

    /* SEARCH ICON */
    .topbar-search .k-icon {
        width: 16px;
        height: 16px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 16px;
        color: #3b6fa3;
        opacity: 0.75;
        margin-right: 8px;
        flex-shrink: 0;
    }

    /* INPUT */
    .topbar-search input {
        flex: 1;
        min-width: 0; /* 👈 critical for flex inputs */

        height: 100%;
        border: none;
        outline: none;
        font-size: 14px;
        background: transparent;
        color: #24384d;
    }

        /* PLACEHOLDER */
        .topbar-search input::placeholder {
            color: #8aa1b7;
        }


/* ============================= */
/* APPLICATIONS SLIDE PANEL     */
/* ============================= */

.app-panel-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    z-index: 900;
}

.app-panel {
    position: fixed;
    top: 0;
    left: 0;
    width: 320px;
    height: 100vh;
    background: #ffffff;
    box-shadow: 2px 0 18px rgba(0, 0, 0, 0.18);
    transform: translateX(-100%);
    transition: transform 0.28s ease;
    z-index: 901;
    display: flex;
    flex-direction: column;
}

    /* OPEN STATE */
    .app-panel.open {
        transform: translateX(0);
    }

.app-panel-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

/* HEADER */
.app-panel-header {
    height: 52px;
    padding: 0 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #e2e8f0;
    font-weight: 600;
}

/* CLOSE BUTTON */
.app-panel-close {
    border: none;
    background: none;
    font-size: 22px;
    cursor: pointer;
}

/* CONTENT */
.app-panel-content {
    padding: 16px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

/* APP TILE */
.app-tile {
    padding: 14px;
    border-radius: 10px;
    background: #f5f7fb;
    text-align: center;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.12s ease;
}

    .app-tile:hover {
        background: #e8eef5;
        transform: translateY(-1px);
    }

.statera-workspace {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.statera-workspace-body {
    display: flex;
    flex: 1;
    min-height: 0; /* CRITICAL for flex children */
}

.statera-content {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    overflow: hidden !important;
}

#mainTabs {
    flex: 1;
    min-height: 0;
}

    /*#mainTabs > .k-tabstrip {
        display: flex;
        flex-direction: column;
        height: 100%;
    }

    #mainTabs .k-content {
        flex: 1;
        overflow: hidden;
    }*/


.tab-iframe-host {
    width: 100%;
    height: 100%;
    position: relative;
}

.tab-iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.app-error-banner {
    background: #fdecea;
    border-left: 4px solid #d93025;
    padding: 12px 16px;
    margin-bottom: 16px;
    border-radius: 6px;
}

    .app-error-banner .error-id {
        font-size: 12px;
        opacity: 0.75;
        margin-top: 6px;
    }

/* =========================================================
   GLOBAL ERROR STRIP (API / SYSTEM ERRORS)
   ========================================================= */

.error-strip {
    position: fixed;
    top: 12px; /* space from top */
    top: 0;
    left: 50%;
    right: 0;
    z-index: 10000;
    display: none;
    pointer-events: none;
    width: calc(100% - 32px); /* responsive on small screens */
}

.error-strip {
    position: fixed;
    top: 12px; /* space from top */
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    display: none; /* hidden by default */
    max-width: 900px;
    width: calc(100% - 32px); /* responsive on small screens */
}

    .error-strip.show {
        display: block;
        pointer-events: auto;
    }

/* --- container --- */
.error-strip-content {
    margin: 0;
    max-width: 960px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 18px;
    background: linear-gradient( 135deg, #fdecea, #fff5f4 );
    border-left: 5px solid #d93025;
    border-radius: 10px;
    box-shadow: 0 10px 28px rgba(0,0,0,.12), 0 2px 6px rgba(0,0,0,.06);
    animation: errorSlideDown 260ms ease-out;
    transform: translateY(12px); /* visual spacing without scroll */
}

/* =========================================================
   TEXT
   ========================================================= */

.error-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.error-title {
    font-size: 15px;
    font-weight: 600;
    color: #7a1b1b;
}

.error-detail {
    font-size: 14px;
    color: #5f1d1d;
}

.error-meta {
    font-size: 12px;
    color: #8a4a4a;
    opacity: 0.85;
}

/* =========================================================
   CLOSE BUTTON
   ========================================================= */

.error-close {
    flex-shrink: 0;
    background: transparent;
    border: none;
    font-size: 18px;
    line-height: 1;
    color: #7a1b1b;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 6px;
    transition: background-color 120ms ease, color 120ms ease;
}

    .error-close:hover {
        background-color: rgba(217,48,37,0.12);
        color: #b42318;
    }

    .error-close:focus-visible {
        outline: 2px solid #d93025;
        outline-offset: 2px;
    }

/* =========================================================
   ANIMATION
   ========================================================= */

@keyframes errorSlideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 768px) {
    .error-strip-content {
        margin: 8px 12px 0;
        border-radius: 8px;
    }
}

/* ===========================
   GLOBAL APP LOADER
   =========================== */

.app-loader {
    position: fixed;
    inset: 0;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

    .app-loader.hidden {
        opacity: 0;
        visibility: hidden;
    }

.loader-content {
    text-align: center;
}

.loader-logo {
    width: 120px;
    height: 120px;
    animation: pulse 1.8s ease-in-out infinite, rise 1.8s ease-in-out infinite;
}

.loader-text {
    margin-top: 14px;
    font-size: 14px;
    color: #6b7280;
    letter-spacing: 0.3px;
}

/* Subtle breathing effect */
@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.85;
    }

    50% {
        transform: scale(1.04);
        opacity: 1;
    }

    100% {
        transform: scale(1);
        opacity: 0.85;
    }
}

/* Slight upward motion = “data rising” */
@keyframes rise {
    0% {
        translate: 0 0;
    }

    50% {
        translate: 0 -4px;
    }

    100% {
        translate: 0 0;
    }
}



/* Context tree */
/*.context-tree {
    width: 260px;
    background: #ffffff;
    border-right: 1px solid #e5e7eb;
    padding: 8px;
    overflow-y: auto;
}

    .context-tree.hidden {
        display: none;
    }

.context-tree-header {
    height: 48px;
    padding: 0 14px;
    display: flex;
    align-items: center;
    background: linear-gradient( 180deg, #2b6cb0,*/ /* steel blue */
    /*#245a94 );
    color: #ffffff;
    font-weight: 600;
    font-size: 14px;
    border-bottom: 1px solid rgba(0,0,0,.15);
}

.context-tree-title {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}*/



    /* Prevent focus bleed between components */
    .statera-app-rail li:focus,
    .sub-nav li:focus {
        outline: none;
    }

.statera-app-rail .rail-menu > li {
    position: relative; /* 🔑 THIS IS THE FIX */
}

/*Removed*/

    /* Selected row background */
    /*.sub-nav .k-treeview-leaf.k-selected) {
        background: rgba(37, 99, 235, 0.14);
    }*/

/* ==========================================
   KENDO TREEVIEW – FORCE FLAT (NO INDENT)
   ========================================== */







.statera-body {
    display: flex;
    flex: 1 1 auto;
    min-height: 0;
}

.statera-workspace,
.statera-workspace-body,
.statera-content {
    display: flex;
    flex: 1 1 auto;
    min-height: 0;
}


   /* #mainTabs .k-tabstrip-item.k-active {
        background: #ffffff;
        border-bottom-color: transparent;
    }*/




/* TAB HEADER BAR (wrapper) */
/*#mainTabs .k-tabstrip-items-wrapper {
    min-height: 0px;
    display: flex;
    align-items: stretch;*/ /* 🔑 NOT center */
    /*padding: 0 0px;
}*/

/* TAB LIST (this is what was missing) */
/*#mainTabs .k-tabstrip-items {
    display: flex;
    align-items: stretch;
    height: 100%;*/ /* 🔑 fills the wrapper */
    /*gap: 0px;
}*/

/* INDIVIDUAL TAB */
/*#mainTabs .k-tabstrip-item {
    display: flex;
    align-items: stretch;
}*/

    /* TAB LINK (controls height via padding) */
    /*#mainTabs .k-tabstrip-item .k-link {
        display: flex;
        align-items: center;
        padding: 0 0px;
        height: 100%;*/ /* 🔑 fills tab */
        /*font-size: 14px;
        font-weight: 600;
        line-height: 1;
    }

#mainTabs .k-tabstrip-content.k-active {
    display: flex !important;
    flex: 1 1 auto;
    min-height: 0;
    padding: 0;
}*/

/* ===== MAIN TABS – FINAL LOCK ===== */

.statera-content {
    display: flex !important;
    flex: 1 1 auto !important;
    min-height: 0 !important;
}

/* flex chain */
.statera-content,
#mainTabs {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
}

.statera-body {
    display: flex;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden; /* 🔑 */
}

.global-search-wrapper {
    position: relative;
    width: 320px; /* or 100% */
}

/* The input */
#globalSearch {
    width: 100%;
    box-sizing: border-box;
}


/* Hide ComboBox dropdown button */
.k-combobox .k-select {
    display: none !important;
}

/* Let input take full width */
.k-combobox .k-input {
    padding-right: 8px;
}

.autocomplete-results {
    position: fixed;
    display: none;
    width: 360px;
    max-height: 320px;
    overflow-y: auto;
    background-color: #ffffff; /* 👈 solid background */
    border: 1px solid #cbd5e1;
    box-shadow: 0 8px 24px rgba(0,0,0,.15);
    border-radius: 4px;
    box-shadow: 0 8px 24px rgba(0,0,0,.15);
    z-index: 2147483647;
}

.autocomplete-results.visible {
    display: block;
}

/* Group headers */
.search-group {
    padding: 8px 14px;
    font-size: 12px;
    font-weight: 600;
    color: #4b6ea9;
    background: #f3f6fb;
    text-transform: uppercase;
}

/* Items */
.search-item {
    padding: 10px 14px;
    cursor: pointer;
}

    .search-item:hover {
        background: #eef4ff;
    }

#global-search-results {
    display: none;
}

    #global-search-results.visible {
        display: block;
    }


#global-search-results {
    background-color: #ffffff !important;
}

.search-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.search-item-icon {
    color: #64748b; /* muted slate */
    font-size: 14px;
    flex-shrink: 0;
}

    .search-item-icon.right {
        margin-left: auto; /* optional extra safety */
    }

/* Backdrop */
.iframe-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    z-index: 3000;
}

/* Centered sliding panel */
.iframe-panel {
    position: absolute;
    top: -100%;
    left: 50%;
    transform: translateX(-50%);
    width: 80vw;
    max-width: 1100px;
    height: 80vh;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,.35);
    transition: top 0.35s cubic-bezier(.25,.8,.25,1);
    overflow: hidden;
}

    /* Iframe fills panel */
    .iframe-panel iframe {
        width: 100%;
        height: 100%;
        border: none;
    }

/* OPEN STATE */
.iframe-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

    .iframe-overlay.open .iframe-panel {
        top: 50%;
        transform: translate(-50%, -50%);
    }

/* Overlay backdrop */
.iframe-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.35);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    z-index: 3000;
}

/* Panel */
.iframe-panel {
    position: absolute;
    top: -100%;
    left: 50%;
    transform: translateX(-50%);
    width: 80vw;
    max-width: 1100px;
    height: 80vh;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,.35);
    transition: top 0.35s cubic-bezier(.25,.8,.25,1), transform 0.35s cubic-bezier(.25,.8,.25,1);
    overflow: hidden;
}

/* OPEN STATE */
.iframe-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

    .iframe-overlay.open .iframe-panel {
        top: 50%;
        transform: translate(-50%, -50%);
    }

#globalSearch {
    outline: none;
    border: none; /* or your custom border */
    box-shadow: none;
    -webkit-appearance: none;
    appearance: none;
}

    #globalSearch:focus {
        outline: none;
        box-shadow: none;
        border-color: transparent; /* optional */
    }

    /* 🔥 Kill Chrome autofill styling */
    #globalSearch:-webkit-autofill,
    #globalSearch:-webkit-autofill:hover,
    #globalSearch:-webkit-autofill:focus,
    #globalSearch:-webkit-autofill:active {
        -webkit-box-shadow: 0 0 0 1000px #eef4ff inset !important;
        box-shadow: 0 0 0 1000px #eef4ff inset !important;
        -webkit-text-fill-color: #1f2937 !important;
        caret-color: #1f2937;
        transition: background-color 9999s ease-out 0s;
    }

.search-input-wrapper {
    flex: 1; /* 👈 THIS is the key */
    position: relative;
}


/* ===== Toast base ===== */
/* ===== Base toast ===== */
.toast {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 2147483647;
    min-width: 280px;
    max-width: 360px;
    padding: 14px 16px;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    /* START off-screen: bottom-right */
    opacity: 0;
    transform: translate(120%, 40px);
    transition: transform 0.45s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease;
    pointer-events: auto;
}

    /* ===== ENTER: slide in from right ===== */
    .toast.show {
        opacity: 1;
        transform: translate(0, 0);
    }

    /* ===== EXIT: slide DOWN and out ===== */
    .toast.hide {
        opacity: 0;
        transform: translate(0, 160%);
    }

/* ===== Success theme with green left accent ===== */
.toast-success {
    background: #ecfdf5; /* soft green */
    border: 1px solid #bbf7d0;
    border-left: 6px solid #22c55e;
    color: #065f46;
}

/* ===== Content ===== */
.toast-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.toast-title {
    font-weight: 600;
    font-size: 0.95rem;
}

.toast-message {
    font-size: 0.85rem;
    opacity: 0.9;
}

.statera-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

    .statera-modal-backdrop.hidden {
        display: none;
    }

.statera-confirm {
    width: 360px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 20px 40px rgba(0,0,0,.25);
    overflow: hidden;
}

.confirm-header {
    padding: 14px 16px;
    font-weight: 600;
    border-bottom: 1px solid #e5e7eb;
}

.confirm-body {
    padding: 16px;
    color: #374151;
}

.confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 12px 16px;
    border-top: 1px solid #e5e7eb;
}

.confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 14px 16px;
    border-top: 1px solid #e5e7eb;
}

/* Base button */
.btn-confirm {
    min-width: 88px;
    padding: 6px 16px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 6px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background-color .15s ease, border-color .15s ease, box-shadow .15s ease;
}

/* Secondary (No) */
.btn-secondary {
    background: #ffffff;
    color: #374151;
    border-color: #d1d5db;
}

    .btn-secondary:hover {
        background: #f9fafb;
        border-color: #9ca3af;
    }

/* Primary (Yes) */
.btn-primary {
    background: #2563eb; /* Statera blue */
    color: #ffffff;
    border-color: #2563eb;
}

    .btn-primary:hover {
        background: #1d4ed8;
        border-color: #1d4ed8;
    }

/* Focus (keyboard users ❤️) */
.btn-confirm:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .35);
}

/* Optional: subtle press */
.btn-confirm:active {
    transform: translateY(1px);
}
