﻿/* =========================================================================
   2026-09 — Global design tokens (from admin diff styling reference).
   Loaded first so every downstream rule + AdminLTE/Bootstrap component
   inherits the new font stack (Geist Sans / Geist Mono) and the neutral
   text / surface / border palette from the reference doc.

   Notes:
     * Brand color (btn-primary blue) is DELIBERATELY NOT overridden here —
       Unimate already standardised on Bootstrap primary #0d6efd for
       create/edit/add buttons, so we keep it. The reference doc itself
       calls the brand color out as separately overridable.
     * Bootstrap variables are re-pointed at our tokens so tables, cards,
       borders and body text automatically pick up the new palette without
       touching per-page CSS.
   ========================================================================= */
:root {
    --font-sans: "Geist", "Geist Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;

    --text-heading:   #0A0A0A;
    --text-primary:   #262626;
    --text-body:      #404040;
    --text-secondary: #525252;
    --text-muted:     #737373;
    --text-subtle:    #A3A3A3;
    --text-disabled:  #CFCFCF;

    --surface-app:            #FAFAFA;
    --surface-default:        #FFFFFF;
    --surface-sidebar:        #FBFBFB;
    --surface-table-header:   #FCFCFC;
    --surface-input:          #FCFCFC;
    --border-default:         #ECECEC;
    --border-subtle:          #F0F0F0;
    --border-extra-subtle:    #F3F3F3;
    --border-divider:         #F7F7F7;

    --delta-pos: #059669;
    --delta-neg: #DC2626;

    --success-tint: #ECFDF5;  --success-text: #059669;  --success-solid: #10B981;
    --warning-tint: #FFFBEB;  --warning-text: #D97706;  --warning-solid: #F59E0B;
    --danger-tint:  #FEF2F2;  --danger-text:  #DC2626;  --danger-solid:  #EF4444;
    --info-tint:    #EFF6FF;  --info-text:    #2563EB;  --info-solid:    #3B82F6;
    --idle-tint:    #FEFCE8;  --idle-text:    #CA8A04;
    --secondary-tint: #FAFAFA; --secondary-text: #262626;

    /* Bootstrap variable re-pointing — inherited by every .btn / .table /
       .card / .form-control / .badge etc. that reads these vars. */
    --bs-font-sans-serif:   var(--font-sans);
    --bs-font-monospace:    var(--font-mono);
    --bs-body-font-family:  var(--font-sans);
    --bs-body-color:        var(--text-body);
    --bs-body-color-rgb:    64, 64, 64;
    --bs-body-bg:           var(--surface-default);
    --bs-body-bg-rgb:       255, 255, 255;
    --bs-secondary-color:   var(--text-secondary);
    --bs-tertiary-color:    var(--text-muted);
    --bs-border-color:      var(--border-default);
    --bs-border-color-translucent: var(--border-default);
    --bs-heading-color:     var(--text-heading);
}

html, body {
    font-family: var(--font-sans);
    color: var(--text-body);
    background-color: var(--surface-default);
}
body {
    /* 2026-09 — Nudged down three steps from the reference "body" (14px/1.6)
       for a denser feel. Table sizes below step down by the same amount
       (11.5px cells, 11px headers). Any further reduction starts to hurt
       legibility on hi-DPI displays. */
    font-size: 12px;
    line-height: 1.45;
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: var(--font-sans);
    color: var(--text-heading);
}

/* 2026-09 — Preserve colored-background contrast. The heading color rule
   above sets an EXPLICIT color which stops inheritance, so a heading inside
   a .text-white / .bg-primary / .bg-dark etc. wrapper (modal headers,
   coloured section banners, dark cards) would render dark-on-dark and become
   unreadable. Force those to inherit their ancestor's color instead. */
.text-white h1, .text-white h2, .text-white h3,
.text-white h4, .text-white h5, .text-white h6,
.text-white .h1, .text-white .h2, .text-white .h3,
.text-white .h4, .text-white .h5, .text-white .h6,
.bg-primary h1, .bg-primary h2, .bg-primary h3,
.bg-primary h4, .bg-primary h5, .bg-primary h6,
.bg-primary .h1, .bg-primary .h2, .bg-primary .h3,
.bg-primary .h4, .bg-primary .h5, .bg-primary .h6,
.bg-success h1, .bg-success h2, .bg-success h3,
.bg-success h4, .bg-success h5, .bg-success h6,
.bg-danger h1, .bg-danger h2, .bg-danger h3,
.bg-danger h4, .bg-danger h5, .bg-danger h6,
.bg-warning h1, .bg-warning h2, .bg-warning h3,
.bg-warning h4, .bg-warning h5, .bg-warning h6,
.bg-info h1, .bg-info h2, .bg-info h3,
.bg-info h4, .bg-info h5, .bg-info h6,
.bg-dark h1, .bg-dark h2, .bg-dark h3,
.bg-dark h4, .bg-dark h5, .bg-dark h6,
.bg-secondary h1, .bg-secondary h2, .bg-secondary h3,
.bg-secondary h4, .bg-secondary h5, .bg-secondary h6 {
    color: inherit;
}

/* 2026-09 — AdminLTE KPI tiles (.small-box + .text-bg-primary / -success /
   -warning / -danger). The .text-bg-* utility sets both background and a
   white foreground; the global heading colour rule above stops <h3> from
   inheriting it, leaving big numbers black-on-dark. Force inheritance for
   the whole tile so both the number and the caption stay white on the
   coloured background. Applies to Dashboard, Check In, Check Out, Tasks
   and Items — anywhere the same tile pattern is used. */
.small-box h1, .small-box h2, .small-box h3,
.small-box h4, .small-box h5, .small-box h6,
.small-box .h1, .small-box .h2, .small-box .h3,
.small-box .h4, .small-box .h5, .small-box .h6,
.small-box p {
    color: inherit;
}

.section-title {
    font-family: var(--font-sans);
    font-size: 15px;
    line-height: 1.35;
    font-weight: 600;
    color: var(--text-heading);
}

.mono,
code, kbd, pre, samp {
    font-family: var(--font-mono);
}

/* Diff / delta helpers (opt-in classes for numeric + green/red change cells). */
.diff-num       { font-family: var(--font-mono); text-align: right; font-variant-numeric: tabular-nums; }
.diff-delta.pos { color: var(--delta-pos); }
.diff-delta.neg { color: var(--delta-neg); }
.diff-ctx       { color: var(--text-subtle); }
.diff-empty     { color: var(--text-subtle); text-align: center; height: 64px; }

/* =========================================================================
   Legacy custom.css rules (pre-2026-09) follow.
   ========================================================================= */

.label {
    /* 2026-09 — Bumped up (0.75rem → 0.875rem, i.e. 12px → 14px) so form
       field labels don't fight the reduced body/table sizes. Applies to
       both the legacy .label utility and Bootstrap's .form-label. */
    font-size: 0.875rem;
}
.form-label {
    /* 2026-09 — Bumped from --text-secondary (#525252) to --text-primary
       (#262626) so field labels read as legible headings against white
       card backgrounds. Weight 500 to distinguish them from body copy. */
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-primary);
}
/* Small-variant labels (e.g. <label class="form-label small">) stay compact
   but sit one step above the ambient body size so they're still legible. */
.form-label.small,
label.small {
    font-size: 0.8rem;
}
.form-control {
    font-size: 0.8rem;
}
/* 2026-09 — Tables now follow reference typography: body 13px/1.55 #404040,
   headers 12.5px/500 #737373 on #FCFCFC, dividers #ECECEC. Font-family is
   forced to Geist so pages that render bare <table> without .table still
   pick it up. Older 0.75rem sizing was replaced. */
table th,
table td {
    font-family: var(--font-sans);
    vertical-align: middle;
}
.table {
    --bs-table-color:        var(--text-body);
    --bs-table-bg:           var(--surface-default);
    --bs-table-border-color: var(--border-default);
    color: var(--text-body);
}
.table > thead > tr > th,
.table > thead th,
table > thead > tr > th {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    background-color: var(--surface-table-header);
    border-bottom: 1px solid var(--border-default);
}
.table > tbody > tr > td,
table > tbody > tr > td,
.table > tbody > tr > th {
    font-size: 11.5px;
    line-height: 1.4;
    color: var(--text-body);
    border-bottom: 1px solid var(--border-default);
}
.table th,
.table td {
    padding: 0.5rem 0.5rem;
}
/* Row-hover surface tint from reference. */
.table-hover > tbody > tr:hover > *,
.table-hover > tbody > tr:hover > td {
    --bs-table-bg-state: color-mix(in srgb, var(--surface-app) 60%, transparent);
    background-color: color-mix(in srgb, var(--surface-app) 60%, transparent);
}
/*.table th{
    background-color:#f5e9a3;
    color:#f55050;
}*/
#blazor-error-ui {

    display: none !important;
}

.tdgray {
    background-color: lightgray !important;
}

.hh-grayBox {
    padding: 15px;
}

.order-tracking {
    text-align: center;
    width: 33.33%;
    position: relative;
    display: block;
}

    .order-tracking .is-complete {
        display: block;
        position: relative;
        border-radius: 50%;
        height: 30px;
        width: 30px;
        border: 0px solid #AFAFAF;
        background-color: #f7be16;
        margin: 0 auto;
        transition: background 0.25s linear;
        -webkit-transition: background 0.25s linear;
        z-index: 2;
    }

        .order-tracking .is-complete:after {
            display: block;
            position: absolute;
            content: '';
            height: 14px;
            width: 7px;
            top: -2px;
            bottom: 0;
            left: 5px;
            margin: auto 0;
            border: 0px solid #AFAFAF;
            border-width: 0px 2px 2px 0;
            transform: rotate(45deg);
            opacity: 0;
        }

    .order-tracking.completed .is-complete {
        border-color: #27aa80;
        border-width: 0px;
        background-color: #27aa80;
    }

        .order-tracking.completed .is-complete:after {
            border-color: #fff;
            border-width: 0px 3px 3px 0;
            width: 7px;
            left: 11px;
            opacity: 1;
        }

    .order-tracking p {
        color: #A4A4A4;
        font-size: 16px;
        margin-top: 8px;
        margin-bottom: 0;
        line-height: 20px;
    }

        .order-tracking p span {
            font-size: 14px;
        }

    .order-tracking.completed p {
        color: #000;
    }

    .order-tracking::before {
        content: '';
        display: block;
        height: 3px;
        width: calc(100% - 40px);
        background-color: #f7be16;
        top: 13px;
        position: absolute;
        left: calc(-50% + 20px);
        z-index: 0;
    }

    .order-tracking:first-child:before {
        display: none;
    }

    .order-tracking.completed:before {
        background-color: #27aa80;
    }

.document-list-item {
    padding: 10px;
    margin: 15px;
}




/* Adjust for tablets and medium screens */
@media (min-width: 577px) and (max-width: 768px) {
}

.app-footer {
    text-align: center;
}




@media screen and (max-width: 600px) {

    td.text-align-center a {
        text-align: right;
        width: 100%;
        display: inline-block;
        padding-right: 10px;
    }

    .dropdown-menu.dropdown-menu-lg.dropdown-menu-end.show {
        right: -150%;
    }

    .dropdown-menu-end[data-bs-popper] {
        right: -75px;
        left: auto;
    }

    .table-responsive table {
        border: 1px solid #ccc;
        border-collapse: collapse;
        margin: 0;
        padding: 0;
        width: 100%;
        table-layout: fixed;
    }

        .table-responsive table caption {
            font-size: 1.5em;
            margin: .5em 0 .75em;
        }

        .table-responsive table tr {
            background-color: #f8f8f8;
            border: 1px solid #ddd;
            padding: .35em;
        }

        .table-responsive table th,
        .table-responsive table td {
            padding: 15px;
            text-align: center;
        }

        .table-responsive table th {
            font-size: .85em;
            letter-spacing: .1em;
            text-transform: uppercase;
        }

    .table-responsive table {
        border: 0;
    }

        .table-responsive table caption {
            font-size: 1.3em;
        }

        .table-responsive table thead {
            border: none;
            clip: rect(0 0 0 0);
            height: 1px;
            margin: -1px;
            overflow: hidden;
            padding: 0;
            position: absolute;
            width: 1px;
        }

        .table-responsive table tr {
            border-bottom: 3px solid #ddd;
            display: block;
            margin-bottom: .625em;
        }

        .table-responsive table td {
            border-bottom: 1px solid #ddd;
            display: block;
            font-size: .8em;
            text-align: right;
        }

            .table-responsive table td::before {
                /*
    * aria-label has no advantage, it won't be read inside a table
    content: attr(aria-label);
    */
                content: attr(data-label);
                float: left;
                font-weight: bold;
                text-transform: uppercase;
                /*                line-height: 5px;*/
            }

            .table-responsive table td:last-child {
                border-bottom: 0;
            }

    .row > * {
        margin-right: auto;
        margin-left: auto;
    }

    .info-box .progress-description, .info-box .info-box-text {
        display: block;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: break-spaces;
    }

    input {
        margin-bottom: 15px;
    }

    .card-body.p-0.table-responsive {
        padding: 5px !important;
    }

    .card-body.p-0 .table tbody > tr > td:first-of-type {
        padding-left: 15px;
    }

    .table-responsive table td.special::before {
        content: attr(data-label);
        float: left;
        font-weight: bold;
        text-transform: uppercase;
        line-height: 15px;
    }
}
/* Small Tablets (Portrait) - iPad Mini */
@media (min-width: 600px) and (max-width: 768px) {
    .info-box .progress-description, .info-box .info-box-text {
        display: block;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: break-spaces;
    }
}

/* Standard Tablets (Landscape) - iPad, Samsung Tab */
@media (min-width: 769px) and (max-width: 1024px) {
    .info-box .progress-description, .info-box .info-box-text {
        display: block;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: break-spaces;
    }
}

/* Large Tablets - iPad Pro */
@media (min-width: 1025px) and (max-width: 1200px) {
    .info-box .progress-description, .info-box .info-box-text {
        display: block;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: break-spaces;
    }
}

.topcheck thead, .topcheck tbody, .topcheck tfoot, .topcheck tr, .topcheck td, .topcheck th {
    border-color: inherit;
    border-style: solid;
    border-width: 0;
    border-bottom: 0;
    border-top: 0.5px solid #d5cccc;
}

.topcheck .table {
    margin-bottom: 0rem;
}

.topcheck .card-title {
    font-size: 2.1rem;
    font-weight: 600;
}

.small-box {
    text-align: center;
}

.label-danger {
    background-color: #EB5E28;
}

.label {
    padding: 3px 8px;
    border-radius: 5px;
    color: #FFFFFF;
    font-weight: 500;
    font-size: 0.75em;
    text-transform: uppercase;
    display: inline-block;
    line-height: 1.5em;
}

.label-success {
    background-color: #7AC29A;
}

.label-info {
    background-color: #68B3C8;
}

aside.app-sidebar.bg-body-secondary.shadow {
    background-color: #152944 !important;
}

.label-active {
    background-color: #198754;
}

.label-inprogress {
    background-color: #000080;
}

.label-upcoming {
    background-color: #dc3545;
}

.small-box.text-bg-primary {
    background-color: #152944 !important;
}

div.brand-text.fw-full-light {
    font-weight: 800;
    font-size: 2.5rem;
    color: #fff;
}

svg.small-box-icon {
    color: #294574;
}

.small-box .small-box-icon {
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 0;
    height: 70px;
    font-size: 70px;
    color: #294574;
    transition: transform 0.3s linear;
}

.leftAligned .small-box {
    text-align: left;
    padding-left: 20px;
    padding-top: 10px;
}

.bgNavy .card-header {
    background-color: #152944 !important;
    color: #fff;
}

button.btn.btn-dark {
    background-color: #152944;
    font-size: 12px;
}


.sidebar-wrapper a i.nav-icon {
    /*    color: #fff;*/
}


td span.badge.text-bg-danger {
    background-color: #152944 !important;
}

td span.badge.text-bg-success {
    background-color: #294574 !important;
}

.settings-card {
    border-radius: 0.5rem;
    padding: 1.2rem;
    text-align: center;
    transition: transform 0.2s;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

    .settings-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    }

.settings-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.settings-text {
    font-weight: 500;
    font-size: 1.1rem;
}

h3, .h3 {
    font-size: 1.15rem;
}

.card-primary, .bg-primary, .text-bg-primary {
    background-color: #152944;
}

.modal-header.bg-light.text-center {
    background-color: #152944 !important;
}

    .modal-header.bg-light.text-center .brand-text.fw-small-light {
        color: #fff;
        margin-left: 10px;
        line-height: 10px;
        font-size: 1.4rem;
    }

    .modal-header.bg-light.text-center a {
        text-decoration: none;
    }


.upload-box {
    border: 2px dashed #ccc;
    padding: 20px;
    border-radius: 10px;
    background-color: #f8f9fa;
    cursor: pointer;
    transition: background-color 0.2s ease;
    width: 100%;
}

    .upload-box:hover {
        background-color: #e9ecef;
    }

.upload-text {
    font-weight: 500;
    color: #555;
}

body, html {
    height: 100%;
}

.card {
    border-radius: 16px;
}

.form-switch .form-check-input.custom-switch {
    width: 50px;
    height: 25px;
    background-color: #dee2e6;
    border-radius: 25px;
    position: relative;
    appearance: none;
    transition: background-color 0.3s ease;
    cursor: pointer;
}

    .form-switch .form-check-input.custom-switch:checked {
        background-color: #0d6efd;
    }

    .form-switch .form-check-input.custom-switch::before {
        content: "";
        position: absolute;
        top: 2px;
        left: 2px;
        width: 21px;
        height: 21px;
        background-color: white;
        border-radius: 50%;
        transition: transform 0.3s ease;
    }

    .form-switch .form-check-input.custom-switch:checked::before {
        transform: translateX(25px);
    }

h2 {
    font-family: 'Segoe UI', sans-serif;
    letter-spacing: 0.5px;
}

#toast {
    position: fixed;
    bottom: 5px;
    right: 5px;
    z-index: 2147483647 !important;
}
.required::after {
    content: " *";
    color: red;
    font-weight: bold;
}
.modal-content {
    position: relative; /* make sure overlay is positioned correctly */
}

.saving-overlay {
    position: fixed; /* cover screen regardless of scroll */
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.6);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 2000; /* above modal */
    pointer-events: auto; /* block user interaction */
}


.field-error-highlight {
    border-color: #dc3545 !important;
    border-width: 2px !important;
    background-color: #fff5f5 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

.error-field-container {
    transition: all 0.3s ease;
    animation: pulse-highlight 2s ease-in-out;
}

.validation-message.text-danger {
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: block;
    font-weight: 500;
    color: #dc3545 !important;
    animation: fadeIn 0.5s ease-in;
}

.form-label.required::after {
    content: " *";
    color: #dc3545;
}

.error-toast-content {
    text-align: left;
}

@keyframes pulse-highlight {
    0% {
        background-color: #fff5f5;
    }

    50% {
        background-color: #ffe6e6;
    }

    100% {
        background-color: #fff5f5;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Ensure validation messages are visible */
.validation-message {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}
@media (max-width: 992px) {
    .isolate-table table {
        display: table !important;
        width: max-content !important;
        min-width: 1600px !important;
    }

    .isolate-table thead {
        display: table-header-group !important;
    }

    .isolate-table tbody {
        display: table-row-group !important;
    }

    .isolate-table tr {
        display: table-row !important;
    }

    .isolate-table th,
    .isolate-table td {
        display: table-cell !important;
        white-space: nowrap !important;
    }
}

/* scrolling container */
.job-table-scroll {
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;

}

.badge {
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.4px;
}

    .badge i {
        font-size: 0.75rem;
    }


.modal {
    z-index: 1055 !important;
}

.modal-backdrop {
    z-index: 1050 !important;
}
