/* TELERIK ADJUSTMENTS */

:root {
    /*   DISABLED FROM TELERIK V11, CAUSES A STRANGE CSS BUG IN TEXTBOXES   */
    /*    --kendo-form-font-size: 0.8rem;
    --kendo-font-size: var(--app-font-size);*/
    --kendo-font-family: var(--app-font-family);
    --kendo-color-primary: var(--app-color-primary);
    --kendo-color-primary-hover: var(--app-color-primary);
    --kendo-color-primary-subtle: var(--app-color-primary-subtle);
    --kendo-color-info-subtle: var(--app-color-primary-subtle);
    --kendo-color-primary-on-surface: var(--kendo-color-primary);
    --kendo-color-primary-subtle-hover: var(--app-color-tertiary-subtle);
    --kendo-color-on-base: var(--app-color-text);
    --kendo-color-on-app-surface: var(--app-color-text);
    --kendo-disabled-text: var(--app-color-text-disabled);
    --kendo-drawer-border: var(--app-menu-border-color);
    --kendo-drawer-mini-initial-width: 0px;
    --kendo-drawer-item-focus-shadow: none;
    --kendo-drawer-item-text: var(--app-menu-color);
    --kendo-drawer-item-bg: var(--app-menu-background-color);
    --kendo-drawer-item-selected-text: var(--app-menu-selected-color);
    --kendo-drawer-item-selected-bg: var(--app-menu-selected-background-color);
    --kendo-drawer-item-hover-text: var(--app-menu-hover-color);
    --kendo-drawer-item-hover-bg: var(--app-menu-hover-background-color);
    --kendo-drawer-item-selected-hover-text: var(--app-menu-selected-hover-color);
    --kendo-drawer-item-selected-hover-bg: var(--app-menu-selected-hover-background-color);
    --kendo-breadcrumb-bg: none;
    --kendo-breadcrumb-link-disabled-text: #8a8886;
    --kendo-grid-header-font-weight: var(--app-font-weight-bold);
    --kendo-grid-selected-bg: var(--app-grid-selected-background-color);
    --kendo-grid-sticky-border: var(--kendo-component-border);
    --kendo-grid-sticky-header-border: var(--kendo-component-border);
    --kendo-grid-sticky-cell-border-width: 0;
    --kendo-menu-item-focus-outline-style: none;
    /*--kendo-menu-popup-shadow: none;*/
    --kendo-form-label-font-weight: 500; /*Form label weight */
    --kendo-form-fieldset-margin: 0; /* form margin */
    --kendo-form-label-margin-bottom: 0.25rem; /*Form label margin from component*/
    --kendo-form-fieldset-margin: 0; /*Form fieldset margin*/
    --kendo-font-weight-bold: var(--app-font-weight-bold);
    --kendo-menu-item-focus-outline-offset: 0;
    --kendo-overlay-opacity: 0.65; /* used by the spinner, default is 0.4 */
    --kendo-toolbar-flat-border: rgba(0,0,0,0) !important;
    --kendo-checkbox-indeterminate-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3crect x='3' y='3' width='10' height='10' rx='2' fill='%23597F6B'/%3e%3c/svg%3e"); /*597F6B is the primary color*/
    --transition-duration: 150ms;
    --kendo-notification-success-bg: #278200;
    --kendo-notification-success-text: white;
    --kendo-notification-warning-bg: #F5A600;
    --kendo-notification-warning-text: white;
    --kendo-notification-error-bg: #D51923;
    --kendo-notification-error-text: white;
    --kendo-notification-info-bg: #3d3d3d;
    --kendo-notification-info-text: white;
    --kendo-notification-dark-bg: #3d3d3d;
    --kendo-notification-dark-text: white;
}

/* TELERIK GRID */
/* Background color of sorted column */
col.k-sorted, .k-table-th.k-sorted {
    background-color: var(--app-color-background);
}

td.k-grid-content-sticky {
    padding: 0;
}

.k-grid td, .k-grid tr .k-table-td {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.k-grid .k-master-row.k-table-row td.k-grid-content-sticky, .k-grid .k-master-row.k-table-row .k-table-td.k-grid-content-sticky {
    overflow: visible;
}
/* Row height*/
/*.k-grid .k-table-td {
    padding-block: 5px;
    height: 25px;
}*/
/* Header height*/
/*.k-grid .k-table-th {
    height: 20px;
}*/
/* Fixes trimming of the text in the grid pager*/
.k-input-value-text {
    overflow: visible;
}


.k-column-resizer:hover {
    background-color: var(--kendo-grid-selected-bg);
}

/* Hide '...' text overflow on grid contextmenu column */
.k-table-td:has(> .softsol-grid-contextmenu) {
    text-overflow: clip;
    padding-top: 0;
    padding-bottom: 0;
}

/* Hide '...' text overflow on grid checkbox column */
.k-table-th:has(> .k-checkbox-wrap), .k-table-td:has(> span .k-checkbox-wrap) {
    text-overflow: clip;
}

/* TELERIK WINDOW */
.k-window {
    border: none;
    border-width: 0;
}

.k-window-title {
    color: var(--kendo-form-text);
}

/* TELERIK BREADCRUMB */
.k-breadcrumb-item-text {
    margin-left: 5px;
}

.k-breadcrumb-root-link:focus, .k-breadcrumb-root-link.k-focus {
    border: none;
    box-shadow: none;
}

/* TELERIK MENU POPUP*/
.k-menu-popup {
    box-shadow: var(--kendo-popup-shadow, var(--kendo-box-shadow-depth-2, none));
}

/* Align icons in dropdown menu */
.k-menu-link .k-button-icon {
    width: 15px;
    text-align: center;
}

/* TELERIK BUTTON */
/* Remove focus border */
.k-button:focus, .k-button.k-focus {
    outline: 0;
}
    .k-button:focus::after, .k-button.k-focus::after {
        outline: 0;
    }

.k-menu-item:focus, .k-menu-item:focus-visible, .k-menu-item.k-focus {
    outline: 0;
    border: none;
}
    .k-menu-item:focus::after, .k-menu-item:focus-visible, .k-menu-item.k-focus::after {
        outline: 0;
        border: none;
    }

/*TELERIK Tabstrip*/
/* Prevent unwanted focus styling on tab click */
.k-tabstrip:focus, .k-tabstrip .k-item:focus, .k-tabstrip .k-link:focus {
    outline: none;
    box-shadow: none;
    animation: none;
}

.k-button-solid:focus, .k-button-solid.k-focus {
    box-shadow: none;
}

.k-tabstrip-content:focus, .k-tabstrip-content.k-focus, .k-tabstrip > .k-content:focus, .k-tabstrip > .k-content.k-focus {
    outline: none;
}

/* Make tab content use all given space without scrollbar */
.k-tabstrip-content {
    display: flex !important;
    flex-direction: column;
}

/* Fixes the bold font when clicking on a tab. In the old scenario, both the active and the clicked tabs change to bold, which moves all tabs a pixel to the right*/
.k-tabstrip-items .k-item:active {
    font-weight: normal;
}

/* DROP DOWN / COMBOBOX */
/* Drop down clear buttons fix (components grow 1px in height when clear button is visible*/
.k-clear-value {
    height: inherit;
}

.k-list-item:focus, .k-list-optionlabel:focus, .k-list-custom-value:focus, .k-list-item.k-focus, .k-focus.k-list-optionlabel, .k-focus.k-list-custom-value {
    box-shadow: none;
}

/* Multicolumn dropdrown cursor */
.k-dropdowngrid-popup .k-table-td {
    cursor: pointer;
}

/* Speed up animations */
.k-child-animation-container {
    transition-duration: var(--transition-duration) !important;
}
.k-slide-down-exit, .k-slide-down-exit-active, .k-slide-down-enter, .k-slide-down-enter-active {
    transition-duration: var(--transition-duration) !important;
}
.fast-animation.k-popup.k-reset {
    transition-duration: var(--transition-duration) !important;
}

/* Fix context menu disabled color */
.k-menu-group .k-item.k-disabled > .k-link {
    color: var(--kendo-disabled-text);
}

/* CHECKBOX */
.k-checkbox:focus, .k-checkbox.k-focus {
    outline: none;
}

/* FORM */
/*Hide empty form group*/
.k-form-legend:empty {
    padding: 0;
    margin: 0;
    border: none;
    display: none;
    visibility: hidden;
}

.k-grid a {
    color: var(--app-color-primary);
}

.k-grid a:hover {
    color: var(--app-color-primary-dark);
}

/*Placeholder color*/
.k-input-inner::placeholder {
    color: var(--kendo-color-secondary);
}

.k-svg-icon {
    height: 100%;
}

.k-input > label.k-input-inner {
    /* Padding-y twice (top & bottom) + 1 relative font height */
    min-height: calc(2 * var(--INTERNAL--kendo-input-padding-y, var(--kendo-spacing-1\.5, 0.375rem)) + 1rem);
}

.k-input:has(label.k-input-inner) {
    border: none;
}

/* Protect context menu from colour overrides*/
.telerik-blazor.k-button-icon.fa-ellipsis-vertical {
    color: black;
}

.telerik-blazor.k-stepper .k-step .k-step-label:only-child {
    box-shadow: inset 0 0 0 var(--kendo-stepper-indicator-focus-size, var(--kendo-spacing-0\.5, 0.125rem)) color-mix(in srgb, var(--kendo-color-border, #8a8886) 16%, transparent);
}

.telerik-blazor.k-stepper .k-step.k-step-done .k-step-label:only-child {
    background-color: var(--app-color-primary);
    color: var(--app-color-background);
}

.telerik-blazor.k-stepper .k-step.k-step-current .k-step-label:only-child {
    box-shadow: inset 0 0 0 var(--kendo-stepper-indicator-focus-size, var(--kendo-spacing-0\.5, 0.125rem)) var(--app-color-primary) !important;
}

.k-window:focus, .k-window.k-focus {
    outline-width: 0;
}


input[type="text"]::placeholder {
    color: var(--kendo-input-placeholder-text, var(--kendo-color-subtle, #605e5c));
}

.k-form-field > .k-label {
    font-weight: var(--kendo-form-label-font-weight);
}

.k-toolbar {
    display: flex;
    flex-wrap: wrap !important;
}

.k-window {
    max-height: 99%;
}

.k-window-content {
    display: flex;
}