@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');

html, body {
    height: 100%;
    margin: 0;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;

    /* Make page-wide backgrounds (Index/Login) cover the full viewport */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

html, body {
    overflow-x: hidden;
}

h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.content {
    padding-top: 1.1rem;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4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Mi44OTUgMy45MTUgMS4zMzIgMi43MTU2IDIuMTI1MiAzLjA1NyAzLjUwNTkgNi42NzQgMS40MTUgOC4wNzU5IDUuNTYwMyA2LjY3NjMgOS42MTUgMy43OTI2LjU5ODQgNS45MzQ3IDguMzY1OSA0LjY5MTYgNi43NDYgOS43MDg1IDMuMzIyyQkxAjEzNzI2OCBBMjQuMjcyIDAgMTIzNi42NjIgNC4wMDcgODguMDA1NCA4Ni4wNzUgOS4wMjI1IDIuNzQgNS41NjIgRFoiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.menu-manager-header {
    background-color: #fff;
}

/* Ensure sticky table header stays below nav dropdowns */
.menu-price-book thead.sticky-top {
    z-index: 10; /* lower than Bootstrap dropdown-menu (1000) */
}

/* Tenant theme shells */
.theme-default {
    background-color: #f8f9fa;
    color: #212529;
}

.theme-customer1 {
    background-color: #001f3f;
    color: #ffffff;
}

.theme-gl {
    background-color: #f5f5ff;
    color: #222244;
}

/* Optional: card style for login container */
.theme-default .login-card,
.theme-customer1 .login-card,
.theme-gl .login-card {
    border-radius: 12px;
    box-shadow: 0 0.75rem 1.5rem rgba(0,0,0,.15);
}

/* Example: different login button colors per tenant */
.theme-customer1 .btn-primary {
    background-color: #ff851b;
    border-color: #ff851b;
}

.theme-gl .btn-primary {
    background-color: #2ecc40;
    border-color: #2ecc40;
}

.theme-gl .bg-primary {
    color: #663e01;
}

/* When the landing page is active, lock the viewport — no scrollbar */
/*html:has(.tenant-landing),
html:has(.tenant-landing) body {
    overflow: hidden;
    height: 100%;
    margin: 0;
}*/

/* The navbar is empty for unauthenticated users — hide it on the landing page
   so .tenant-landing can fill the full viewport without overflow */
/*html:has(.tenant-landing) .app-navbar {
    display: none !important;
}*/

/* Remove any layout padding/margin around the landing page
   and override the scoped .page flex-direction: row */
html:has(.tenant-landing) .page,
html:has(.tenant-landing) main {
    padding: 0 !important;
    margin: 0 !important;
    display: block !important;      /* neutralize scoped flex-direction: row */
    width: 100% !important;
}

/* Shared tenant landing layout for Index/Login */
.tenant-landing {
    position: relative;             /* positioning parent for topbar & overlay */
    height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;         /* stack topbar above content */
    align-items: stretch;
    overflow: hidden;
    width: 100%;
}

/* Crisp full-bleed background image via <img> */
.tenant-landing-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;          /* fills container without distortion */
    object-position: center;
    z-index: 0;
    pointer-events: none;
    user-select: none;
}

/* Near-transparent overlay — lets the image shine through */
.tenant-landing-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.10) 0%,
        rgba(255, 255, 255, 0.05) 100%
    );
}

.tenant-landing-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    flex: 1;                        /* fill remaining space below topbar */
    display: flex;
    align-items: center;            /* vertically center hero + login */
    justify-content: center;
    padding: 0 0.5rem;
}

@media (min-width: 768px) {
    .tenant-landing-inner {
        padding: 0 1rem;
    }
}

.tenant-logo {
    max-height: 72px;
    width: auto;
}

@media (min-width: 768px) {
    .tenant-logo {
        max-height: 96px;
    }
}

/* Dashboard container card on Index */
.tenant-dashboard-card {
    border-radius: 1rem;
}

/* Center Login component on Index page */
.index-login-center {
    min-height: 60vh;              /* vertical space to center within */
    display: flex;
    align-items: center;           /* vertical center */
    justify-content: center;       /* horizontal center */
}

/* ── Text readability over vivid backgrounds ────────────── */

/* Default & GL themes (dark text on bright images) — white halo */
.tenant-landing-inner h1,
.tenant-landing-inner .display-6,
.tenant-landing-inner .lead {
    text-shadow:
        0 0 8px  rgba(255, 255, 255, 0.9),
        0 1px 3px rgba(255, 255, 255, 0.7);
}

.tenant-landing-inner .text-muted {
    color: #495057 !important;      /* slightly darker than Bootstrap default */
    text-shadow:
        0 0 6px  rgba(255, 255, 255, 0.85),
        0 1px 2px rgba(255, 255, 255, 0.6);
}

.tenant-landing-inner .small {
    text-shadow:
        0 0 4px rgba(255, 255, 255, 0.8);
}

/* Customer1 theme (white text on dark images) — dark drop shadow */
.theme-customer1 .tenant-landing-inner h1,
.theme-customer1 .tenant-landing-inner .display-6,
.theme-customer1 .tenant-landing-inner .lead {
    text-shadow:
        0 2px 6px rgba(0, 0, 0, 0.7),
        0 0 12px  rgba(0, 0, 0, 0.4);
}

.theme-customer1 .tenant-landing-inner .text-muted {
    color: #ccc !important;
    text-shadow:
        0 1px 4px rgba(0, 0, 0, 0.6);
}

.theme-customer1 .tenant-landing-inner .small {
    text-shadow:
        0 1px 4px rgba(0, 0, 0, 0.5);
}

/* ── Frosted-glass login card over background ───────────── */
.tenant-landing .login-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(12px) saturate(1.4);
    -webkit-backdrop-filter: blur(12px) saturate(1.4);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.12),
        0 2px 8px  rgba(0, 0, 0, 0.08);
}

.theme-customer1 .tenant-landing .login-card {
    background: rgba(0, 15, 30, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.3),
        0 2px 8px  rgba(0, 0, 0, 0.2);
}

.theme-customer1 .tenant-landing .login-card .form-control {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.theme-gl .tenant-landing .login-card {
    background: rgba(245, 245, 255, 0.7);
    border: 1px solid rgba(200, 200, 255, 0.3);
}

/* ── Branded top bar on landing page ────────────────────── */
.tenant-topbar {
    position: relative;
    z-index: 3;
    width: 100%;
    flex-shrink: 0;                 /* don't collapse when content is tall */
    padding: 0.6rem 0;
    background: rgba(255, 255, 255, 0.90);
    backdrop-filter: blur(10px) saturate(1.2);
    -webkit-backdrop-filter: blur(10px) saturate(1.2);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.10);
}

.tenant-topbar-logo {
    height: 28px;
    width: auto;
}

.tenant-topbar-title {
    font-size: 1.1rem;
    color: #212529;
    letter-spacing: 0.02em;
}

/* Dark theme variant */
.theme-customer1 .tenant-topbar {
    background: rgba(0, 15, 30, 0.85);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.theme-customer1 .tenant-topbar-title {
    color: #ffffff;
}

/* GL theme variant */
.theme-gl .tenant-topbar {
    background: rgba(245, 245, 255, 0.90);
}

.theme-gl .tenant-topbar-title {
    color: #222244;
}