@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');

/* Горниот насловен ред со TopMenu да заземе цела ширина на header; инаку Navbar може да изгледа „исечен“. */
#main-header > nav.navbar.b-bar,
#main-header > .navbar {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
}

/* Fullscreen помош/видео модал: под layout sider изгледа „под“ навбарот.
   На широк екран колоната со header+содржина мора да има повисок stacking од sider. */
@media (min-width: 992px) {
    .b-layout-sider {
        z-index: 0;
    }

    .b-layout-body {
        position: relative;
        z-index: 1;
    }
}

/* Дополнително: помош модал над sider доколку браузерско stacking сè уште меша. */
#erp-help-video-modal.modal {
    z-index: 100060 !important;
}

/* VideoModal iframe/viewport — глобално (не само scoped bundle): без ова iframe останува ~300×150px. */
#erp-help-video-modal .help-modal-viewport {
    position: relative;
    width: 100%;
    height: clamp(280px, 58vh, 640px);
    background-color: #0f172a;
    border-radius: 0.375rem;
    overflow: hidden;
}

#erp-help-video-modal .help-video-modal-scope.help-modal-layout-fullscreen .help-modal-viewport {
    height: clamp(340px, min(92vh - 11rem, 1180px), 1180px);
}

#erp-help-video-modal .help-modal-media-fill {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

:root {
    --custom-blue: #006B99;
    --custom-blue-dark: #005377; /* darker shade for border */
    --custom-blue-light: rgba(0, 107, 153, 0.6); /* lighter shade for glow */
    --header-height: 6rem; /* Default fallback, updated by JavaScript */
    --resizer-height: 10px; /* Default resizer height, updated by JavaScript */
}

/* Fallback for browsers without dvh support */
@supports not (height: 100dvh) {
    :root {
        --viewport-height: 100vh;
    }
}

@supports (height: 100dvh) {
    :root {
        --viewport-height: 100dvh;
    }
}

html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}


.content {
    padding-top: 1.1rem;
}

.b-is-autocomplete-suggestion:hover,
.b-is-autocomplete-suggestion.focus {
    background-color: #cff4fc !important;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

.invisible-btn {
    display: none !important;
}

#blazor-error-ui {
    background: lightyellow;
    top: 0; /* Change from 'bottom' to 'top' */
    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: 9999;
}

    #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+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.no-outline:focus {
    outline: none;
}

.selectedDiv {
    outline: none !important;
}

input[type=number] {
    text-align: right;
}

.input-grid {
    border-top-style: hidden;
    border-right-style: hidden;
    border-left-style: hidden;
    border-bottom-style: hidden;
    background: transparent;
    width: 100%;
}

.checkbox-grid {
    width: 1.2em;
    height: 1.2em;
    border-radius: 0.25em;
    flex: none;
}

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Firefox */
input[type=number] {
    -moz-appearance: textfield;
}

.resizer {
    background-color: transparent;
    cursor: ns-resize;
    width: 100%;
    height: 10px;
}

/* overflows */
.overflow-y-scroll {
    overflow-y: scroll;
}


.custom-checkbox .custom-control-indicator {
    border-radius: .25rem;
}

.dropdown-invalid input[type=search] {
    border-color: #dc3545;
    padding-right: calc(1.5em + 0.75rem) !important;
    background-image: url(data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' stroke='%23dc3545' viewBox='0 0 12 12'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e);
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.field-invalid-feedback {
    width: 100%;
    margin-top: 0.25rem;
    font-size: 80%;
    color: #dc3545;
}

.dxbl-btn-toolbar[disabled] {
    pointer-events: auto;
    opacity: 1;
}

.context-menu-scroll {
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 99999;
    position: absolute;
}

.submenu {
    position: fixed;
    display: none; /* Initially hidden */
    top: 0;
    left: 100%; /* Position to the right of the parent item */
    z-index: 999999 !important; /* Ensure submenu is above other elements */
}

.context-menu {
    background-color: #f9f9f9;
    border: 1px solid #ccc;
    min-width: 360px;
    font-size: 0.875rem;
    white-space: nowrap;
}

.dropdown-submenu {
    display: block;
    width: 100%;
    padding: .25rem 1.5rem;
    clear: both;
    font-weight: 400;
    color: #212529;
    text-align: inherit;
    white-space: nowrap;
    background-color: transparent;
    border: 0;
}

    .dropdown-submenu > .dropdown-item {
        display: none;
    }

/* rotate caret on hover */
.dropdown-menu > li > a:hover:after {
    text-decoration: underline;
    transform: rotate(-90deg);
}


.number-text-input {
    text-align: right;
}

.filteInput {
    border-top-style: hidden;
    border-right-style: hidden;
    border-left-style: hidden;
    border-bottom-style: hidden;
    width: 100%;
    outline: none !important;
}

    .filteInput:focus {
        outline: none;
        box-shadow: 0 0 2px 2px #0dcaf0;
        border-color: #0056b3; /* Darker, more intense blue border */
        border-width: 1px; /* Thicker border on focus */
        transition: all 0.2s ease-in-out; /* Smooth transition for the effect */
    }

.readonly-div {
    min-height: 38px;
    display: block;
    padding: 0.375rem 0.75rem; /* Same padding as Bootstrap form-control */
    font-size: 1rem; /* Same font size */
    line-height: 1.5; /* Same line height */
    color: #495057; /* Default text color for form controls */
    background-color: #e9ecef; /* Light grey background color */
    border: 1px solid #ced4da; /* Same border as Bootstrap form-control */
    border-radius: 0.25rem; /* Same border radius */
}

.form-check-add {
    padding-top: 13px !important;
    display: flex !important; /* Use flexbox for vertical alignment */
    align-items: center !important; /* Center items vertically */
    height: 90px !important; /* Match the height of a Bootstrap form group */
    font-weight: 500;
}

.form-check-input-add {
    margin-top: 0px !important; /* Remove top margin for better alignment */
    margin-right: 10px !important; /* Add some space between checkbox and label */
}

.scrollableImage {
    overflow-y: auto;
    background-color: lightblue;
    padding: 20px;
    height: 100%;
}

.widget-card {
    height: 250px;
    min-height: 250px;
    max-height: 250px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.widget-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    overflow: hidden;
}

.widget-title-container {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.widget-title {
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 1px;
    margin-top: 1px;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.last-update-label {
    font-size: 10px;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.widget-body {
    display: flex;
    flex-direction: column;
    height: 100%;
}


.widget-body-text {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.widget-card > .card-body {
    display: flex;
    flex-direction: column;
}

.chart-box {
    flex: 1;
    min-height: 230px;
    width: 100%;
    position: relative;
}

.refresh-button {
    position: absolute;
    top: 5px;
    right: 5px;
    z-index: 10;
    border-radius: 50%;
    padding: 5px 8px;
    cursor: pointer;
}

    .refresh-button:hover {
        background: lightgray;
    }

.gridSum {
    font-size: 14px;
    text-align: right
}

.styleLabelCommon {
    background-color: #6B7280 !important;
    font-size: 13px !important;
    color: #fff;
    font-weight: 600;
    position: relative; /* Ensure the pseudo-elements are positioned relative to the td */
    padding: 5px 0; /* Add padding for the content */
    box-sizing: border-box; /* Ensure  */
}

table tr:first-of-type .styleLabelCommon::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px; /* Adjust shadow height */
    background: linear-gradient(to bottom, rgba(107, 114, 128, 1), transparent);
    pointer-events: none; /* Prevents it from interfering with interactions */
}

.styleLabelCommon::after {
    content: "";
    position: absolute;
    bottom: 0; /* Place the border at the bottom */
    left: 0;
    width: 100%;
    height: 1px; /* Small height for the border */
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.2), transparent);
    pointer-events: none; /* Prevents it from interfering with interactions */
}

.styleDataCommon {
    color: black !important;
    font-size: 13px !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    position: relative; /* Ensures shadow is positioned properly */
}

    .styleDataCommon::after {
        content: "";
        position: absolute;
        bottom: 0; /* Place the border at the bottom */
        left: 0;
        width: 100%;
        height: 1px; /* Small height for the border */
        background: linear-gradient(to bottom, rgba(0, 0, 0, 0.2), transparent);
        pointer-events: none; /* Prevents it from interfering with interactions */
    }

table tr:first-of-type .styleDataCommon::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px; /* Adjust shadow height */
    background: linear-gradient(to bottom, rgba(107, 114, 128, 1), transparent);
    pointer-events: none; /* Prevents it from interfering with interactions */
}

.json-snippet {
    background-color: #f4f4f9;
    border: 1px solid #ddd;
    padding: 10px;
    border-radius: 5px;
    height: 120px; /* Fixed height */
    overflow-y: auto; /* Vertical scroll */
    overflow-x: auto; /* Horizontal scroll */
    white-space: pre-wrap;
    font-family: Consolas, "Courier New", monospace;
    color: #333;
}

    .json-snippet .key {
        color: #d14;
    }

    .json-snippet .string {
        color: #093;
    }

    .json-snippet .number {
        color: #1c00cf;
    }

    .json-snippet .boolean {
        color: #aa0d91;
    }

    .json-snippet .null {
        color: #808080;
    }

.flex-column-center {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.bg-secondary-opacity-25 {
    background-color: rgba(108, 117, 125, 0.25) !important; /* Bootstrap's secondary color with 25% opacity */
}

.bg-warning-opacity-25 {
    background-color: rgba(255, 193, 7, 0.25) !important; /* Bootstrap warning color with 25% opacity */
}

.bg-primary-opacity-25 {
    background-color: rgba(13, 110, 253, 0.25) !important; /* Bootstrap primary color with 25% opacity */
}

.bg-success-opacity-25 {
    background-color: rgba(25, 135, 84, 0.25) !important; /* Bootstrap success color with 25% opacity */
}

.bg-danger-opacity-25 {
    background-color: rgba(220, 53, 69, 0.25) !important; /* Bootstrap danger color with 25% opacity */
}

.bg-info-opacity-25 {
    background-color: rgba(13, 202, 240, 0.25) !important; /* Bootstrap info color with 25% opacity */
}

.bg-light-opacity-25 {
    background-color: rgba(248, 249, 250, 0.25) !important; /* Bootstrap light color with 25% opacity */
}

.bg-dark-opacity-25 {
    background-color: rgba(33, 37, 41, 0.25) !important; /* Bootstrap dark color with 25% opacity */
}

.bg-success-opacity-25 {
    background-color: rgba(25, 135, 84, 0.25) !important; /* Bootstrap success color with 25% opacity */
}

.bg-warning-opacity-50 {
    background-color: rgba(255, 193, 7, 0.50) !important;
}

.bg-primary-opacity-50 {
    background-color: rgba(13, 110, 253, 0.50) !important;
}

.bg-success-opacity-50 {
    background-color: rgba(25, 135, 84, 0.50) !important;
}

.no-border-sides {
}


.bg-custom-blue {
    background-color: var(--custom-blue) !important; /* override Bootstrap if needed */
    color: white !important; /* make sure text stays visible */
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.05em;
}

.bg-custom-blue-footer {
    background-color: var(--custom-blue) !important; /* override Bootstrap if needed */
    color: white !important; /* make sure text stays visible */
    font-size: 0.8rem; /* keep the size small */
    font-weight: 400; /* make it bolder so it looks fuller */
    letter-spacing: normal; /* remove spacing, tighter looks fuller */
   
}

.bg-primary {
    background-color: var(--custom-blue) !important;
}

.card-header.bg-primary {
    background-color: var(--custom-blue) !important;
}

.text-primary {
    color: var(--custom-blue) !important;
}

.border-primary {
    border-color: var(--custom-blue) !important;
}

.btn-primary {
    background-color: var(--custom-blue) !important;
    border-color: var(--custom-blue) !important;
}

    .btn-primary:hover {
        background-color: #004F73 !important; /* darker shade for hover */
        border-color: #004F73 !important;
    }

.title-bar,
.title-bar * {
    color: var(--custom-blue) !important;
}
/* Tab link styles */
.nav-tabs .nav-link {
    color: var(--custom-blue) !important;
}

    .nav-tabs .nav-link.active.show {
        color: #000 !important;
    }

.amount-box {
    position: relative;
    /* почист градиент */
    background: linear-gradient(145deg, #d8efe2, #b9dcc9);
    border-radius: 15px;
    padding: 0.9rem 1.3rem;
    min-height: 110px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-end;
    font-family: 'Lato', sans-serif;
    /* помалку heavy shadow */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 2px 4px rgba(0, 0, 0, 0.3);
    transition: all 0.2s ease;
    overflow: hidden;
}

    /* subtle hover depth */
    .amount-box:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08), 0 4px 8px rgba(0, 0, 0, 0.06);
    }

    /* cleaner footer accent */
    .amount-box::after {
        content: "";
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 6px;
        background: linear-gradient(90deg, #2f9a64, #248a57);
        border-bottom-left-radius: 20px;
        border-bottom-right-radius: 20px;
    }

.amount-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}

.amount-icon {
    font-size: 0.85rem;
    color: #1f7f4d;
}

.amount-title {
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    font-weight: 700;
    color: #1b5e3a;
}

.amount-value {
    font-size: clamp(2.2rem, 3vw, 2.8rem);
    font-weight: 900; /* појако */
    color: #1a2e25;
    line-height: 1.05;
}
/* Compact spacing for header action buttons */
.receipt-action-btn {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    padding: 0.45rem 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 500;
    color: #2d3748;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.09), 0 1px 2px rgba(0, 0, 0, 0.1);
    transition: all 0.15s ease;
}

    .receipt-action-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08), 0 3px 6px rgba(0, 0, 0, 0.06);
    }

    .receipt-action-btn:active {
        transform: translateY(0);
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
    }

.action-content {
    display: flex;
    align-items: center;
    gap: 8px;
}

.action-icon {
    font-size: 0.9rem;
}

.action-title {
    white-space: nowrap;
    font-size: 0.85rem;
    font-weight: 500; /* појако */
}

.action-shortcut {
    background: #eef2ff;
    color: #2563eb;
    padding: 2px 8px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 600;
}

.bg-color-light-green {
    background-color: #d4edda; /* Light green, like Bootstrap's alert-success */
}

.bg-custom-blue-footer::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0px;
    width: 100%;
    height: 2px;
    border-radius: 12px;
    overflow: hidden !important;
    background-color: var(--custom-blue);
}

.v-grid {
    overflow-x: hidden !important;
    overflow-y: scroll; /* vertical scroll visible */
    -webkit-overflow-scrolling: touch;
    border-radius: 10px;
    box-shadow: 0 4px 7px rgba(0,0,0,0.3);
    background: white;
    scrollbar-width: thin; /* auto, thin, none */
    scrollbar-color: rgba(0, 107, 153, 0.4) rgba(224, 224, 224, 0.3);
}
    .v-grid thead tr:first-child th {
        padding: 9px;
        padding-bottom: 2px;
    }

    .v-grid thead tr:last-child th {
        padding: 4px;
    }

    .v-grid thead tr:first-child th:last-child {
        border-top-right-radius: 10px;
    }

    .v-grid tfoot tr:last-child td:last-child {
        border-bottom-right-radius: 0px;
    }

.v-grid-empty-row {
    background-color: #fff !important;
}

.tableModif {
}

    .tableModif thead tr,
    .tableModif thead th {
        border-top: hidden;
    }

    .tableModif tfoot tr,
    .tableModif tfoot th {
        border: none !important;
    }

.dropdown-display {
    font-size: 0.95rem;
}

.receipt-card {
    box-shadow: 0 4px 11px rgba(0,0,0,0.1);
}

/* ---------- Appointment Scheduler ---------- */
.appt-scheduled       { background: rgba(180, 248, 200)       !important; color: #1a1a1a !important; }
.appt-canceled        { background: rgba(255, 174, 188)       !important; color: #1a1a1a !important; }
.appt-emergency       { background: rgba(251, 231, 198)       !important; color: #1a1a1a !important; }
.appt-workorder       { background: rgba(251, 168, 19)        !important; color: #1a1a1a !important; }
.appt-finished        { background: rgba(160, 231, 229)       !important; color: #1a1a1a !important; }
.appt-default         { background: rgba(160, 231, 229)       !important; color: #1a1a1a !important; }

.appt-scheduled.appt-past  { background: rgba(180, 248, 200, 0.35) !important; }
.appt-canceled.appt-past   { background: rgba(255, 174, 188, 0.35) !important; }
.appt-emergency.appt-past  { background: rgba(251, 231, 198, 0.35) !important; }
.appt-workorder.appt-past  { background: rgba(251, 168, 19, 0.35)  !important; }
.appt-finished.appt-past   { background: rgba(160, 231, 229, 0.35) !important; }
.appt-default.appt-past    { background: rgba(160, 231, 229, 0.35) !important; }

.slot-nonworking  { background: rgba(255, 174, 188, 0.3) !important; }
.slot-today       { background: rgba(160, 231, 229, 0.3) !important; }
.slot-past        { background: rgba(200, 200, 200, 0.35) !important; }
.slot-weekend     { background: rgba(251, 231, 198, 0.3) !important; }

/* Appointment Legend */
.legend-card {
    margin-top: 0.5rem;
    padding: 0.75rem;
    background-color: #f9f9f9;
    border: 1px solid #dee2e6;
    border-radius: 6px;
}

.legend-title {
    margin: 0 0 0.5rem 0;
    font-size: 0.95rem;
}

.legend-content {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.legend-tables {
    flex: 1;
}

.legend-table {
    width: 100%;
    border-collapse: collapse;
}

.legend-label-cell {
    width: 220px;
    vertical-align: top;
    padding: 0.5rem;
}

.legend-items {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.legend-item {
    display: flex;
    align-items: center;
}

.legend-swatch {
    width: 20px;
    height: 20px;
    border: 1px solid #ccc;
    display: inline-block;
    margin-right: 8px;
    border-radius: 3px;
}

.legend-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0.5rem;
    width: 35%;
}

.vgrid-column-settings-sortable-item {
    user-select: none;
}

    .vgrid-column-settings-sortable-item .drag-handle {
        cursor: grab;
        user-select: none;
    }

/* Blazor Server – overlay кога падне SignalR врската (стопиран dev сервер, rebuild, sleep…).
   На /login изгледа како „искршена“ форма бидејќи цел екран се затемнува. */
#components-reconnect-modal {
    z-index: 2147483000 !important;
    box-sizing: border-box;
}

#components-reconnect-modal.components-reconnect-show,
#components-reconnect-modal.components-reconnect-failed,
#components-reconnect-modal.components-reconnect-rejected,
#components-reconnect-modal.components-rejoining,
#components-reconnect-modal.show {
    position: fixed !important;
    inset: 0 !important;
    display: flex !important;
    flex-direction: column;
    align-items: center !important;
    justify-content: center !important;
    padding: 1rem !important;
    background: rgba(15, 23, 42, 0.55) !important;
    backdrop-filter: blur(3px);
}

#components-reconnect-modal.components-reconnect-show .components-reconnect-dialog,
#components-reconnect-modal.components-reconnect-failed .components-reconnect-dialog,
#components-reconnect-modal.components-reconnect-rejected .components-reconnect-dialog,
#components-reconnect-modal.components-rejoining .components-reconnect-dialog,
#components-reconnect-modal.components-reconnect-show > div,
#components-reconnect-modal.components-reconnect-failed > div,
#components-reconnect-modal .components-rejoining,
#components-reconnect-modal .components-reconnect-failed {
    max-width: 24rem;
    width: 100%;
    margin: 0 auto;
    padding: 1.25rem 1.5rem !important;
    border-radius: 12px;
    background: #fff !important;
    color: #0f172a !important;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.22);
    font-size: 0.95rem;
    line-height: 1.45;
    text-align: center;
}

#components-reconnect-modal button,
#components-reconnect-modal a.btn {
    font-weight: 600;
    color: var(--custom-blue, #006B99) !important;
    margin-top: 0.75rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: 1px solid var(--custom-blue, #006B99);
    background: #fff;
    cursor: pointer;
}