:root {
    --odd-color: white;
    --even-color: #f1f1f1b8;
    --item-selected-color: black;
}

[data-bs-theme="darkly"] {
    --odd-color: gray;
    --even-color: black;
    --item-selected-color: white;
}

[data-bs-theme="Blazing Dark"] {
    --odd-color: gray;
    --even-color: black;
    --item-selected-color: white;
}

html, body {
    height: 100%;
}

app {
    display: block;
    height: 100%;
}

.header-logo {
    background-image: url('../images/logologin.png');
    background-position: center;
    background-size: contain;
    background-repeat: no-repeat;
    width: 190px;
    height: 40px;
}

#blazor-error-ui {
    background: inherit;
    bottom: 0;
    display: none;
    position: fixed;
    width: 100%;
    height: 100%;
    z-index: 100001;
}

.tree-list /* Target all styles within the tree-list component */
.tree-list-container {
    width: 100%; /* Enable responsive behavior */
}

.dx-column {
    box-sizing: border-box; /* Ensure padding/border don't affect width */
}

/* Row Styles */
.dx-row {
    color: #222; /* Darker gray for better contrast */
    font-size: 14px; /* Standard font size */
}

.bold-header .dx-treelist-headers .dx-row .dx-column-lines .dx-header-row .dx-treelist-table .dx-treelist-table-fixed .dx-treelist-content .dx-treelist-scroll-container {
    font-weight: bold !important;
}

.tree-list .dx-row:nth-child(even) {
  background-color: #f5f5f5; /* Light gray background color for even rows */
}

.dx-row:last-child {
    background-color: #f5f5f5; /* Very light gray background */
    border-bottom: 1px solid #ddd; /* Light gray border on bottom */
}

/* Selection & Hover Styles */
.dx-selection .dx-row {
    background-color: #4285f4; /* Google blue (primary) */
    color: #fff; /* White font color for contrast */
}

.dx-row:hover {
    background-color: #e6e6e6; /* Lighter gray on hover */
}

/* Expanded Row Styles */
.dx-treelist-expanded .dx-row {
    border-left: 3px solid #4285f4; /* Thicker left border for expanded rows */
    padding-left: 20px; /* Increased indent for hierarchy */
}

/* Row Border Styles */
.dx-row {
    border-bottom: 1px solid #ddd; /* Light gray border between rows */
}

/* Header Row Styles */
.dx-header-row {
    background-color: #f0f0f0; /* Light gray background for headers */
    color: #555; /* Dark gray font color */
    font-weight: bold; /* Bold font for headers */
    padding: 5px 10px; /* Add some padding for visual separation */
    border-bottom: 1px solid #ddd; /* Light gray border on bottom */
}

/* Select All Checkbox Styles (optional) */
.dx-header-row .dx-select-checkbox {
    background-color: #fff; /* White background */
    border-color: #ccc; /* Light gray border */
}

.dx-header-row .dx-checkbox-hover-on.dx-select-checkbox {
    background-color: #e6e6e6; /* Light gray background on hover */
}

/* Existing styles for tree list container and controls */
.tree-list-container {
    display: flex;
    flex-direction: column; /* Stack controls and tree list vertically */
    width: 100%; /* Ensure the container takes full width */
}

.tree-list-controls {
    display: flex; /* Arrange buttons horizontally */
    margin-bottom: 5px; /* Add some spacing below buttons */
}

.dx-expand-all-button {
    text-indent: -9999px;
    width: 20px; /* Set a fixed width for buttons */
    height: 20px; /* Set a fixed height for buttons */
    background-repeat: no-repeat; /* Prevent image tiling */
    background-position: center center; /* Center image within button */
    background-size: cover;
    border: none; /* Remove the border */
    /* Set background image for expand and collapse buttons */
    background-image: url('../../images/plus-svgrepo-com.svg') !important; /* Expand icon */
    margin-right: 5px; /* Add margin to right of each button */
}

.dx-collapse-all-button {
    text-indent: -9999px;
    width: 23px; /* Set a fixed width for buttons */
    height: 20px; /* Set a fixed height for buttons */
    background-size: cover;
    background-repeat: no-repeat; /* Prevent image tiling */
    background-position: center center; /* Center image within button */
    border: none; /* Remove the border */
    /* Set background image for expand and collapse buttons */
    background-image: url('../../images/minus-circle-svgrepo-com.svg') !important; /* Expand icon */
    margin-right: 5px; /* Add margin to right of each button */
}

.dx-AutoFit-button {
    text-indent: -9999px;
    width: 23px; /* Set a fixed width for buttons */
    height: 20px; /* Set a fixed height for buttons */
    background-size: cover;
    background-repeat: no-repeat; /* Prevent image tiling */
    background-position: center center; /* Center image within button */
    border: none; /* Remove the border */
    /* Set background image for expand and collapse buttons */
    background-image: url('../../images/resize-double-arrows-svgrepo-com.svg') !important; /* Expand icon */
    margin-right: 5px; /* Add margin to right of each button */
}

.logoncontainer {
    display: flex;
    width: 100%;
    height: 100%;
    background-color: #5156be;
}

.logonleft,
.logonright {
    flex: 1;
    text-align: center;
    transition: all 0.3s;
    display: flex;
    position: relative;
    top: 0;
    width: 100%;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.logonleft {
    flex: 25%;
    float: left;
    left: 0;
    background-color: ghostwhite;
}

.logonright {
    flex: 75%;
    float: right;
    right: 0;
    background-image: url('../../images/auth-bg.jpg');
    background-repeat: no-repeat;
    background-size: 100% 100%;
}

.logondivider {
    display: flex;
    justify-content: center;
    align-items: center;
}

@media (max-width: 576px) {
    .hideinmob {
        display: none;
    }
}

/* Editors and captions */
.dxbl-text-edit {
    border-radius: 8px;
    padding: 6px 2px ;
}

.dxbl-fl .dxbl-fl-item.dxbl-fl-item-horizontal > .dxbl-fl-cpt {
    padding: 10px;
}

/* List and dialogs */
.dxbl-dropdown > .dxbl-dropdown-dialog, .dxbl-itemlist-dropdown > .dxbl-dropdown-dialog {
    border: thick;
    border-radius: 8px;
}

html:not(.dxSafari) .dxbl-list-box-render-container > .dxbl-scroll-viewer > .dxbl-scroll-viewer-content > table > tbody > tr.dxbl-list-box-item-selected:not(.dxbl-list-box-item-disabled) > td, html:not(.dxSafari) .dxbl-list-box > .dxbl-scroll-viewer > .dxbl-scroll-viewer-content > table > tbody > tr.dxbl-list-box-item-selected:not(.dxbl-list-box-item-disabled) > td {
    background-color: var(--dxbl-list-box-item-selected-bg,unset);
    color: var(--item-selected-color) !important;
}

.logon-toolbar button {
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
    background-color: cornflowerblue;
    border: none;
}

.logon-viewsite .dxbl-text-edit-input {
    border-radius: 8px;
}

.logon-main {
    max-width: 400px;
    min-width: 400px;
    width: 400px;
    border-radius: 8px;
    background-color: transparent;
    border: none !important;
    box-shadow: none !important;
}

.logon-slogan-text {
    position: absolute;
    bottom: 20px;
    font-size: 1.5vw;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 1px 15% 1px 15%;
    background-color: cornflowerblue;
}

.dxbl-tabs > .dxbl-tabs-tablist.dxbl-tabs-tablist-scrollable {
    background-color: transparent;
}

.bg-overlay {
    inset: 0;
    opacity: 0.3;
    background-color: #000;
}

.dxbl-toolbar.dxbl-toolbar-adaptive > .dxbl-btn-toolbar > div > .dxbl-toolbar-item > .dxbl-btn {
    border-radius: 8px;
    padding: 10px;
}

.dxbl-btn-secondary {
    border-radius: 8px;
    padding: 10px;
}

.dxbl-btn-primary {
    border-radius: 8px;
    padding: 10px;
}

/* Grid */
tr:nth-child(odd) {
    background-color: var(--odd-color);
}

tr:nth-child(even) {
    background-color: var(--even-color);
}

.dxbl-grid-header-row {
    background-color: var(--even-color) !important;
}
/* Grid */

.app .main-content > .grid-content, .xaf-masterdetail-listview > .grid-content {
    border-radius: 8px;
}

dxbl-grid-header-content {
    padding: 6px 0
}

.dxbl-grid .dxbl-grid-table > tbody > tr > td > .dxbl-checkbox, .dxbl-grid .dxbl-grid-table > tfoot > tr > td > .dxbl-checkbox, .dxbl-grid .dxbl-grid-table > thead > tr > td > .dxbl-checkbox {
    padding: 6px 0;
}

.time-span-editor {
    display: flex;
    gap: 0.5rem;
    align-items: flex-end;
}

.time-span-editor .dxbs-spin-edit {
    width: 100px;
}

.dx-toolbar {
    z-index: 10;
    background-color: white;
    position: relative;
    padding: 5px 10px;
}

.dx-gantt {
    height: 100% !important;
}

    .dx-gantt .dx-toolbar-items-container {
        overflow: visible;
    }
    /*.dx-gantt .dx-treelist {
        width: 40% !important;*/ /* Adjust percentage as needed */
        /*min-width: 400px !important;
    }*/

.dx-gantt-splitter {
    width: 8px !important;
    background-color: #f0f0f0 !important;
}

.dx-treelist-container .dx-treelist-table .dx-column-indicators {
    min-width: 300px;
}

body:not(.dxbl-theme-fluent) .logon-main div[data-item-name="PasswordHint"] + .xaf-static-text {
    opacity: 0.5;
    font-size: 0.75rem;
}

.dxbl-theme-fluent.xaf-size-s .logon-main div[data-item-name="LogonText"] + .xaf-static-text {
    font-size: var(--DS-font-size-caption-1);
    line-height: var(--DS-line-height-caption-1);
    font-weight: var(--DS-font-weight-caption-1);
}

.dxbl-theme-fluent.xaf-size-m .logon-main div[data-item-name="LogonText"] + .xaf-static-text {
    font-size: var(--DS-font-size-body-1);
    line-height: var(--DS-line-height-body-1);
    font-weight: var(--DS-font-weight-body-1);
}

.dxbl-theme-fluent.xaf-size-s .logon-main .xaf-static-text {
    font-size: var(--DS-font-size-caption-2);
    line-height: var(--DS-line-height-caption-2);
    font-weight: var(--DS-font-weight-caption-2);
}

.dxbl-theme-fluent.xaf-size-m .logon-main .xaf-static-text {
    font-size: var(--DS-font-size-caption-1);
    line-height: var(--DS-line-height-caption-1);
    font-weight: var(--DS-font-weight-caption-1);
}
