/*
 * Po Syncfusion.Blazor.Themes — app.css ładuje się Wcześniej i przegrywa kolejnością.
 * Tylko kolor przy .hpz-readonly-look (IsReadonly z Parameters → ReadonlyLookClass).
 * https://www.syncfusion.com/feedback/16878
 */

.hpz-readonly-look .e-input-group,
.hpz-readonly-look .e-control-wrapper,
.hpz-readonly-look .e-float-input,
.hpz-readonly-look .e-float-input.e-control-wrapper,
.hpz-readonly-look .e-float-input.e-input-group,
.hpz-readonly-look .e-input-group.e-control-wrapper,
.hpz-readonly-look .e-date-wrapper,
.hpz-readonly-look .e-datetime-wrapper,
.hpz-readonly-look .e-ddl,
.hpz-readonly-look .e-ddl.e-input-group,
.hpz-readonly-look .e-numeric,
.hpz-readonly-look .e-numeric.e-control-wrapper,
.hpz-readonly-look .e-multiselect,
.hpz-readonly-look .e-checkbox-wrapper {
    background-color: var(--bs-secondary-bg, #e9ecef) !important;
    background-image: none !important;
}

.hpz-readonly-look .e-input-group .e-input,
.hpz-readonly-look .e-control-wrapper .e-input,
.hpz-readonly-look .e-float-input .e-input,
.hpz-readonly-look .e-float-input input,
.hpz-readonly-look .e-input-group input.e-input,
.hpz-readonly-look .e-input-group textarea.e-input,
.hpz-readonly-look input.e-input,
.hpz-readonly-look textarea.e-input {
    background-color: transparent !important;
    background-image: none !important;
}

/* Column chooser — Bootstrap list-style override + sensible height */
.e-grid .e-ccdlg .e-ccul-ele,
.e-grid-popup .e-ccdlg .e-ccul-ele,
.e-grid .e-ccdlg li.e-cclist,
.e-grid-popup .e-ccdlg li.e-cclist {
    list-style: none;
}

.e-grid .e-ccdlg .e-cc-contentdiv,
.e-grid-popup .e-ccdlg .e-cc-contentdiv {
    max-height: min(60vh, 420px);
}

/* Grid — niebieskie zaznaczenie wierszy (Syncfusion 34: e-cellselectionbackground) */
:root {
    --color-sf-table-bg-color-selected: #9cb8e9;
}

.e-grid td.e-cellselectionbackground,
.e-grid td.e-selectionbackground {
    background: #9cb8e9 !important;
    color: inherit;
}

.e-grid.e-gridhover tr.e-row:hover td.e-cellselectionbackground,
.e-grid.e-gridhover tr.e-row:hover td.e-selectionbackground {
    background: #d6d6d6 !important;
}

/* MultiSelect (checkbox) — zaznaczona pozycja na liście od razu niebieska */
.e-popup.e-multi-select-list-wrapper.e-checkbox .e-list-item.e-active,
.e-popup.e-multi-select-list-wrapper.e-checkbox .e-list-item.e-active.e-hover {
    background-color: var(--color-sf-content-bg-color-selected, #0d6efd);
    color: var(--color-sf-content-text-color-selected, #fff);
}

/* DropDownList — fokus na aktywnej pozycji nie może być szary */
.e-dropdownbase .e-list-item.e-active.e-item-focus {
    background-color: var(--color-sf-content-bg-color-selected, #0d6efd);
    color: var(--color-sf-content-text-color-selected, #fff);
}
