.item-table-list-container {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

.item-table-container {
    display: flex;
    flex-direction: row;
    width: 100%;
    min-width: 0;
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

.item-table-grid-container {
    position: relative;
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

.item-table-grid-container > div[role='grid'] {
    height: unset !important;
}

.item-table-pinned-rows-container {
    position: relative;
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
}

.item-table-pinned-rows-grid-container {
    position: relative;
    flex: 0 1 auto;
    min-width: 0;
}

.item-table-pinned-rows-grid-container.with-header {
    position: relative;
}

.item-table-pinned-rows-grid-container.header-fixed {
    position: fixed !important;
    top: 65px;
    z-index: 15;
    background-color: var(--theme-bg-primary);
    box-shadow: 0 -1px 0 0 var(--theme-colors-border);
    transition: position 0.2s ease-in-out;
}

.item-table-pinned-rows-grid-container.header-window-bar {
    top: 95px;
}

.item-table-list-container.header-fixed-margin {
    margin-top: 36px !important;
}

.sticky-header {
    position: fixed;
    z-index: 15;
    display: flex;
    flex-direction: row;
    overflow: visible;
    pointer-events: none;
    background-color: var(--theme-colors-background);
    border-bottom: 1px solid var(--theme-colors-border);
}

.sticky-header-row {
    display: flex;
    flex-direction: row;
    width: 100%;
}

.sticky-header-section {
    display: flex;
    flex-direction: row;
    overflow: hidden;
    pointer-events: auto;
}

.sticky-group-row {
    position: fixed;
    z-index: 15;
    display: flex;
    flex-direction: row;
    padding: 0;
    margin: 0;
    pointer-events: none;
    background-color: var(--theme-colors-background);
    border-bottom: 1px solid var(--theme-colors-border);
}

.sticky-group-row-content {
    display: flex;
    flex-direction: row;
    width: 100%;
}

.sticky-group-row-section {
    display: flex;
    flex-direction: row;
    overflow: hidden;
    pointer-events: auto;
}

.item-table-pinned-rows-grid-container.with-header::after {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 1px;
    content: '';
    background-color: var(--theme-colors-border);
}

.item-table-pinned-columns-grid-container {
    position: relative;
    display: flex;
    flex: 0 1 auto;
    flex-direction: column;
    min-height: 0;
}

.item-table-pinned-intersection-grid-container {
    position: relative;
    flex: 0 1 auto;
    min-width: 0;
}

.item-table-pinned-intersection-grid-container.with-header {
    position: relative;
}

.item-table-pinned-intersection-grid-container.with-header::after {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 1px;
    content: '';
    background-color: var(--theme-colors-border);
}

.item-table-pinned-columns-container {
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
    min-height: 0;
    overflow-x: visible; /* Allow group headers to extend beyond container */
    overflow-y: auto; /* Maintain vertical scrolling */
}

.item-table-pinned-right-columns-container {
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
    min-height: 0;
    overflow-x: visible;
}

.no-scrollbar {
    scrollbar-width: none;
}

.height-100 {
    height: 100%;
}

.item-table-container :global(.os-scrollbar) {
    z-index: 2;
}

.item-table-pinned-header-shadow {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    z-index: 1;
    height: 8px;
    pointer-events: none;

    @mixin dark {
        background: linear-gradient(
            to bottom,
            color-mix(in srgb, var(--theme-colors-background) 85%, black) 0%,
            color-mix(in srgb, var(--theme-colors-background) 92%, black) 50%,
            transparent 100%
        );
    }

    @mixin light {
        background: linear-gradient(
            to bottom,
            color-mix(in srgb, var(--theme-colors-background) 92%, black) 0%,
            color-mix(in srgb, var(--theme-colors-background) 96%, black) 50%,
            transparent 100%
        );
    }
}

.item-table-left-scroll-shadow {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
    width: 8px;
    pointer-events: none;

    @mixin dark {
        background: linear-gradient(
            to right,
            color-mix(in srgb, var(--theme-colors-background) 85%, black) 0%,
            color-mix(in srgb, var(--theme-colors-background) 92%, black) 50%,
            transparent 100%
        );
    }

    @mixin light {
        background: linear-gradient(
            to right,
            color-mix(in srgb, var(--theme-colors-background) 92%, black) 0%,
            color-mix(in srgb, var(--theme-colors-background) 96%, black) 50%,
            transparent 100%
        );
    }
}

.item-table-right-scroll-shadow {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    width: 8px;
    pointer-events: none;

    @mixin dark {
        background: linear-gradient(
            to left,
            color-mix(in srgb, var(--theme-colors-background) 85%, black) 0%,
            color-mix(in srgb, var(--theme-colors-background) 92%, black) 50%,
            transparent 100%
        );
    }

    @mixin light {
        background: linear-gradient(
            to left,
            color-mix(in srgb, var(--theme-colors-background) 92%, black) 0%,
            color-mix(in srgb, var(--theme-colors-background) 96%, black) 50%,
            transparent 100%
        );
    }
}

.item-table-top-scroll-shadow {
    position: absolute;
    top: var(--header-height, 40px);
    right: 0;
    left: 0;
    z-index: 1;
    height: 8px;
    pointer-events: none;

    @mixin dark {
        background: linear-gradient(
            to bottom,
            color-mix(in srgb, var(--theme-colors-background) 85%, black) 0%,
            color-mix(in srgb, var(--theme-colors-background) 92%, black) 50%,
            transparent 100%
        );
    }

    @mixin light {
        background: linear-gradient(
            to bottom,
            color-mix(in srgb, var(--theme-colors-background) 92%, black) 0%,
            color-mix(in srgb, var(--theme-colors-background) 96%, black) 50%,
            transparent 100%
        );
    }
}
