/**
 * ZERTI admin layer: zerti-features-inventory.css
 * Inventory warehouse, categories, product editor, reviews
 * Loaded via assets/css/zerti-admin.css manifest and includes/admin/assets.php.
 * @see docs/DESIGN-SYSTEM.md
 */

    }

    #zertiAdmin .zerti-shop-invoice__totals {

        width: 100%;
    }
}

/* Inventory — product categories manager */
#zertiAdmin .zerti-inv-categories {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-width: 0;
    min-height: 0;
    max-height: 100%;
    width: 100%;
    max-width: 100%;
    flex: 1 1 0;
    align-self: stretch;
    overflow: hidden;
    position: relative;
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 9pt;
    font-weight: 500;
    line-height: 1.35;
}

#zertiAdmin .zerti-inv-categories .zerti-inventory-view__title,
#zertiAdmin .zerti-inv-categories .form-label,
#zertiAdmin .zerti-inv-categories .btn,
#zertiAdmin .zerti-inv-categories .alert,
#zertiAdmin .zerti-inv-categories .modal-title,
#zertiAdmin .zerti-inv-categories .modal-body,
#zertiAdmin .zerti-inv-categories .text-body-secondary,
#zertiAdmin .zerti-inv-categories .small,
#zertiAdmin .zerti-inv-categories__tree-empty,
#zertiAdmin .zerti-inv-categories__meta-line {
    font-size: 9pt;
}

#zertiAdmin .zerti-inv-categories__tree-empty {
    text-align: center;
}

#zertiAdmin .zerti-inv-categories__toolbar {
    flex: 0 0 auto;
}

#zertiAdmin .zerti-component-inventory-categories,
#zertiAdmin .zerti-component-inventory-brands,
#zertiAdmin .zerti-component-inventory-tags,
#zertiAdmin .zerti-component-inventory-attributes,
#zertiAdmin .zerti-component-inventory-attribute-groups {
    display: flex;
    flex-direction: column;
    flex: 1 1 0;
    min-height: 0;
    max-height: 100%;
    width: 100%;
    max-width: 100%;
    align-self: stretch;
    overflow: hidden;
    direction: inherit;
}

#zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__toolbar,
#zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__toolbar,
#zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__toolbar,
#zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__toolbar,
#zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__toolbar,
#zertiAdmin .zerti-component-inventory-comments .zerti-inv-reviews__toolbar {
    direction: inherit;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    width: 100%;
    padding: clamp(0.65rem, 1.5vw, 1rem) clamp(0.65rem, 1.5vw, 1rem) 0;
}

#zertiAdmin .zerti-inv-categories__search-label {
    display: inline-flex;
    align-items: center;
    margin: 0;
}

#zertiAdmin .zerti-inv-categories__search-icon {
    flex-shrink: 0;
    line-height: 1;
    color: var(--zerti-docs-muted);
}

#zertiAdmin .zerti-inv-categories__search-input,
#zertiAdmin .zerti-bulk-action-safety-gate__search-input {
    min-width: min(100%, 14rem);
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border);
}

#zertiAdmin .zerti-inv-categories__search-input {
    text-align: center;
}

#zertiAdmin .zerti-inv-categories__search-input::placeholder,
#zertiAdmin .zerti-bulk-action-safety-gate__search-input::placeholder {
    color: var(--zerti-docs-muted);
    opacity: 1;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__search-input,
#zertiAdmin[data-bs-theme='dark'] .zerti-bulk-action-safety-gate__search-input {
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border);
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__search-input::placeholder,
#zertiAdmin[data-bs-theme='dark'] .zerti-bulk-action-safety-gate__search-input::placeholder {
    color: var(--zerti-docs-muted);
    opacity: 1;
}

@media (max-width: 991.98px) {
    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__toolbar,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__toolbar,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__toolbar,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__toolbar,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__toolbar,
    #zertiAdmin .zerti-component-inventory-comments .zerti-inv-reviews__toolbar {
        justify-content: center;
    }
}

#zertiAdmin .zerti-inv-categories__layout {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: stretch;
    align-self: stretch;
    direction: inherit;
    gap: 0.75rem;
    flex: 1 1 0;
    min-width: 0;
    min-height: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
    overflow-y: hidden;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: color-mix(in srgb, var(--zerti-docs-muted) 50%, var(--zerti-docs-border)) transparent;
}

body.toplevel_page_zerti-admin #zertiAdmin .zerti-inv-categories__layout::-webkit-scrollbar {
    width: var(--zerti-scrollbar-size, 1px);
    height: var(--zerti-scrollbar-size, 1px);
    display: block;
    background: transparent;
}

body.toplevel_page_zerti-admin #zertiAdmin .zerti-inv-categories__layout::-webkit-scrollbar-thumb {
    background-color: color-mix(in srgb, var(--zerti-docs-muted) 50%, var(--zerti-docs-border));
    border-radius: 999px;
}

body.toplevel_page_zerti-admin #zertiAdmin .zerti-inv-categories__layout::-webkit-scrollbar-thumb:hover {
    background-color: color-mix(in srgb, var(--zerti-bs-purple) 42%, var(--zerti-docs-muted));
}

body.toplevel_page_zerti-admin #zertiAdmin .zerti-inv-categories__layout::-webkit-scrollbar-track {
    background: transparent;
}

#zertiAdmin .zerti-inv-categories__tree-panel,
#zertiAdmin .zerti-inv-categories__editor {
    min-width: 0;
    min-height: 0;
    max-width: none;
    width: auto;
    box-sizing: border-box;
    border-color: var(--zerti-docs-border);
}

#zertiAdmin .zerti-inv-categories__tree-panel {
    display: flex;
    flex-direction: column;
    flex: 3 1 0;
    align-self: stretch;
    min-height: 0;
    overflow: hidden;
}

#zertiAdmin .zerti-inv-categories__editor {
    display: flex;
    flex-direction: column;
    flex: 2 1 0;
    align-self: flex-start;
    height: auto;
    min-height: 0;
    max-height: none;
    overflow: visible;
}

#zertiAdmin .zerti-inv-categories__editor.zerti-inv-categories__editor--collapsed {
    display: flex;
    flex-direction: column;
    align-self: flex-start;
    height: auto;
    min-height: 0;
    max-height: none;
    overflow: visible;
}

@media (min-width: 992px) {
    /* RTL row: editor on the right, tree on the left — fixed 60% / 40% widths. */
    #zertiAdmin .zerti-inv-categories__layout {
        align-items: stretch;
    }

    #zertiAdmin .zerti-inv-categories__tree-panel {
        order: 2;
        flex: 3 1 0;
        min-width: 0;
        max-width: none;
        width: auto;
        min-height: 0;
        align-self: stretch;
    }

    #zertiAdmin .zerti-inv-categories__editor,
    #zertiAdmin .zerti-inv-categories__editor.zerti-inv-categories__editor--collapsed,
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) {
        order: 1;
        flex: 2 1 0;
        min-width: 0;
        max-width: none;
        width: auto;
        align-self: flex-start;
        height: auto;
        min-height: 0;
        max-height: 100%;
        overflow: visible;
    }

    #zertiAdmin .zerti-inv-categories__tree-scroll {
        flex: 1 1 0;
        min-height: 0;
        overflow-x: hidden;
        overflow-y: auto;
    }
}

/* Mobile + tablet: stack tree and editor, each full width. */
@media (max-width: 991.98px) {
    #zertiAdmin .zerti-inv-categories__layout {
        flex-direction: column;
        align-items: flex-start;
    }

    #zertiAdmin .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-inv-categories__editor {
        flex: 0 0 auto;
        order: 0;
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }

    #zertiAdmin .zerti-inv-categories__tree-panel {
        align-self: stretch;
        min-height: clamp(10rem, 28vh, 16rem);
        max-height: clamp(14rem, 42vh, 26rem);
    }

    #zertiAdmin .zerti-inv-categories__editor,
    #zertiAdmin .zerti-inv-categories__editor.zerti-inv-categories__editor--collapsed,
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) {
        align-self: stretch;
        width: 100%;
        max-width: 100%;
    }

    /* Stack scrolls in layout; tree list scrolls inside clamped panel. */
    #zertiAdmin .zerti-panel-slot > .zerti-component.zerti-component-inventory-categories,
    #zertiAdmin .zerti-panel-slot > .zerti-component.zerti-component-inventory-brands,
    #zertiAdmin .zerti-panel-slot > .zerti-component.zerti-component-inventory-tags,
    #zertiAdmin .zerti-panel-slot > .zerti-component.zerti-component-inventory-attributes,
    #zertiAdmin .zerti-panel-slot > .zerti-component.zerti-component-inventory-attribute-groups {
        flex: 1 1 0;
        min-height: 0;
        height: 100%;
        max-height: 100%;
        overflow: hidden;
    }

    #zertiAdmin .zerti-component-inventory-categories,
    #zertiAdmin .zerti-component-inventory-brands,
    #zertiAdmin .zerti-component-inventory-tags,
    #zertiAdmin .zerti-component-inventory-attributes,
    #zertiAdmin .zerti-component-inventory-attribute-groups {
        flex: 1 1 0;
        min-height: 0;
        max-height: 100%;
        overflow: hidden;
    }

    #zertiAdmin .zerti-inv-categories {
        flex: 1 1 0;
        min-height: 0;
        max-height: 100%;
        overflow: hidden;
    }

    #zertiAdmin .zerti-inv-categories__layout {
        flex: 1 1 0;
        min-height: 0;
        max-height: 100%;
        overflow-x: hidden;
        overflow-y: auto;
    }

    #zertiAdmin .zerti-inv-categories__tree-scroll {
        overflow-x: hidden;
        overflow-y: auto;
        scrollbar-width: thin;
        scrollbar-color: color-mix(in srgb, var(--zerti-docs-muted) 50%, var(--zerti-docs-border)) transparent;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-inv-categories__tree-scroll::-webkit-scrollbar {
        width: var(--zerti-scrollbar-size, 1px);
        display: block;
        background: transparent;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb {
        background-color: color-mix(in srgb, var(--zerti-docs-muted) 50%, var(--zerti-docs-border));
        border-radius: 999px;
    }
}

#zertiAdmin .zerti-main-content .zerti-inv-categories__tree-panel.card > .card-body {
    flex: 1 1 0;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

#zertiAdmin .zerti-inv-categories__tree-scroll {
    flex: 1 1 0;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    direction: inherit;
    unicode-bidi: isolate;
    overscroll-behavior: contain;
}

#zertiAdmin .zerti-inv-categories__editor-scroll {
    flex: 0 0 auto;
    height: auto;
    overflow: visible;
    direction: inherit;
    unicode-bidi: isolate;
}

body.toplevel_page_zerti-admin #zertiAdmin .zerti-inv-categories__editor-scroll::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
    background: transparent;
}

/* Category tree scrollport follows #zertiAdmin dir; editor inner keeps field layout per direction. */
#zertiAdmin .zerti-inv-categories__tree-scroll-inner {
    direction: inherit;
    min-height: 0;
    unicode-bidi: isolate;
}

#zertiAdmin .zerti-inv-categories__editor-scroll-inner {
    direction: inherit;
    min-height: auto;
    height: auto;
}

#zertiAdmin[dir='rtl'] .zerti-inv-categories__editor-scroll-inner .zerti-inv-categories__form,
#zertiAdmin[dir='rtl'] .zerti-inv-categories__editor-scroll-inner .card-body {
    direction: rtl;
}

#zertiAdmin[dir='ltr'] .zerti-inv-categories__editor-scroll-inner .zerti-inv-categories__form,
#zertiAdmin[dir='ltr'] .zerti-inv-categories__editor-scroll-inner .card-body {
    direction: ltr;
}

#zertiAdmin .zerti-inv-categories__tree-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1.5rem;
    font-size: 9pt;
}

#zertiAdmin .zerti-inv-categories__tree {
    direction: inherit;
    padding: 0;
    margin: 0;
    width: 100%;
    box-sizing: border-box;
}

#zertiAdmin .zerti-inv-categories__tree-level {
    direction: inherit;
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
    box-sizing: border-box;
}

#zertiAdmin .zerti-inv-categories__tree-item > .zerti-inv-categories__tree-level {
    margin: 0;
    padding: 0;
    /* Indent nested levels on the inline-start side (follows tree direction). */
    padding-inline-start: var(--zerti-cat-indent, 1.25rem);
    width: 100%;
    box-sizing: border-box;
}

#zertiAdmin .zerti-inv-categories__tree-item {
    display: block;
    width: 100%;
}

#zertiAdmin .zerti-inv-categories__tree-row {
    --zerti-cat-indent: 1.25rem;
    direction: inherit;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 0.4rem;
    width: 100%;
    box-sizing: border-box;
    padding-block: 0.35rem;
    padding-inline-end: 0.5rem;
    padding-inline-start: 0.35rem;
    border-radius: 0.35rem;
    transition: background-color 0.12s ease;
}

#zertiAdmin .zerti-inv-categories__tree-row:hover {
    background: color-mix(in srgb, var(--zerti-bs-purple) 8%, transparent);
}

#zertiAdmin .zerti-inv-categories__tree-row--active {
    background: color-mix(in srgb, var(--zerti-bs-purple) 14%, transparent);
    border-inline-start: 3px solid var(--zerti-bs-purple);
}

#zertiAdmin .zerti-inv-categories__tree-toggle {
    width: 1.25rem;
    height: 1.25rem;
    flex: 0 0 auto;
    color: var(--zerti-docs-text);
    text-decoration: none;
    line-height: 1;
}

#zertiAdmin .zerti-inv-categories__tree-toggle-spacer {
    display: inline-block;
    width: 1.25rem;
    flex: 0 0 auto;
}

#zertiAdmin .zerti-inv-categories__tree-thumb {
    width: 1.65rem;
    height: 1.65rem;
    flex: 0 0 auto;
    border-radius: 0.25rem;
}

#zertiAdmin .zerti-inv-categories__tree-thumb-wrap {
    width: 1.65rem;
    height: 1.65rem;
    flex: 0 0 1.65rem;
    border-radius: 0.25rem;
    overflow: hidden;
    display: block;
    background: var(--bs-tertiary-bg, #e9ecef);
}

#zertiAdmin img.zerti-inv-categories__tree-thumb {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

#zertiAdmin .zerti-inv-categories__tree-thumb--empty {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--bs-tertiary-bg, #e9ecef);
    color: var(--bs-secondary-color);
    font-size: 9pt;
}

#zertiAdmin .zerti-inv-categories__tree-name {
    flex: 1 1 auto;
    min-width: 0;
    font-size: 9pt;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border: 0;
    background: transparent;
    color: inherit;
    text-align: start;
    padding: 0;
    line-height: 1.35;
}

#zertiAdmin .zerti-inv-categories__tree-name--branch {
    cursor: pointer;
}

#zertiAdmin .zerti-inv-categories__tree-name--branch:hover,
#zertiAdmin .zerti-inv-categories__tree-name--branch:focus-visible {
    color: var(--zerti-link-hover-color, #adb5bd);
}

#zertiAdmin .zerti-inv-categories__tree-toggle:hover,
#zertiAdmin .zerti-inv-categories__tree-toggle:focus-visible {
    color: var(--zerti-link-hover-color, #adb5bd);
}

#zertiAdmin .zerti-inv-categories__tree-name:disabled {
    cursor: default;
    opacity: 1;
}

#zertiAdmin .zerti-inv-categories__tree-edit-btn {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 9pt;
    font-weight: 500;
    padding: 0;
    width: 1.55rem;
    min-width: 1.55rem;
    min-height: 0;
    height: 1.55rem;
    line-height: 1;
    border-radius: 0.5rem;
}

#zertiAdmin .zerti-inv-categories__tree-count {
    flex: 0 0 auto;
    font-size: 9pt;
    font-weight: 500;
}

#zertiAdmin .zerti-inv-categories__editor-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 0.75rem;
    padding: 0.65rem 0.85rem;
    border-bottom: 1px solid transparent;
    flex: 0 0 auto;
}

#zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-bar {
    border-bottom-color: var(--zerti-docs-border);
}

#zertiAdmin .zerti-inv-categories__editor-bar-title {
    flex: 1 1 auto;
    min-width: 0;
    line-height: 1.45;
}

#zertiAdmin .zerti-inv-categories__editor-body {
    overflow: visible;
    max-height: none;
    opacity: 1;
    flex: 0 0 auto;
    height: auto;
    min-height: 0;
}

#zertiAdmin .zerti-inv-categories__editor--collapsed .zerti-inv-categories__editor-body {
    display: none;
    max-height: 0;
    opacity: 0;
    pointer-events: none;
    padding: 0;
    margin: 0;
    border: 0;
}

/* Editor card — height fits content; width stays 40% (flex 2:3 with tree on desktop). */
#zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) {
    display: flex;
    flex-direction: column;
    flex: 2 1 0;
    align-self: flex-start;
    height: auto;
    min-height: 0;
    max-height: none;
    overflow: visible;
}

@media (min-width: 992px) {
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed),
    #zertiAdmin .zerti-inv-categories__editor.zerti-inv-categories__editor--collapsed {
        align-self: flex-start;
        height: auto;
        max-height: 100%;
    }

    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-body,
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll,
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll-inner,
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .card-body {
        display: block;
        flex: 0 0 auto;
        height: auto;
        min-height: 0;
        max-height: none;
        overflow: visible;
    }
}

@media (max-width: 991.98px) {
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) {
        align-self: stretch;
        height: auto;
        max-height: none;
        overflow: visible;
    }

    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-body,
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll,
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll-inner,
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .card-body {
        display: block;
        flex: 0 0 auto;
        height: auto;
        min-height: 0;
        max-height: none;
        overflow: visible;
    }
}

#zertiAdmin .zerti-inv-categories__editor .card-body {
    overflow: visible;
}

/* Nested editor card-body must not grow (beats .zerti-main-content .card .card-body). */
#zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll-inner > .card-body {
    flex: 0 0 auto;
    display: block;
    min-height: 0;
    height: auto;
    max-height: none;
    overflow: visible;
}

@media (max-width: 991.98px) {
    #zertiAdmin .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) {
        flex: 0 0 auto;
        align-self: stretch;
        width: 100%;
        max-width: 100%;
    }
}

#zertiAdmin .zerti-inv-categories__form .form-label {
    margin-bottom: 0.25rem;
    font-size: 9pt;
    font-weight: 500;
    line-height: 1.35;
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-inv-categories__form .form-check-label {
    font-size: 9pt;
    font-weight: 500;
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-inv-categories__form label[for='zertiCatName'],
#zertiAdmin .zerti-inv-categories__form label[for='zertiCatSlug'],
#zertiAdmin .zerti-inv-categories__form label[for='zertiTagName'],
#zertiAdmin .zerti-inv-categories__form label[for='zertiTagSlug'],
#zertiAdmin .zerti-inv-categories__form label[for='zertiAttrName'],
#zertiAdmin .zerti-inv-categories__form label[for='zertiAttrSlug'] {
    padding-top: 5px;
}

#zertiAdmin .zerti-inv-categories__form .row > [class*='col-'] {
    min-width: 0;
}

#zertiAdmin .zerti-inv-categories__form .row.g-3 {
    --bs-gutter-y: 0.65rem;
}

#zertiAdmin .zerti-inv-categories__form .form-control {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    min-height: 0;
    padding-block: 0;
    padding-inline: 0.45rem;
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 9pt;
    font-weight: 500;
    line-height: 1.2;
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border: 1px solid var(--zerti-docs-border);
    border-radius: 0.5rem;
    box-shadow: none;
}

#zertiAdmin .zerti-inv-categories__form .form-control:not(textarea) {
    height: 1.55rem;
}

#zertiAdmin .zerti-inv-categories__form .zerti-admin-select,
#zertiAdmin .zerti-inv-categories__form select.form-select {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    min-height: 0;
    height: 1.55rem;
    padding-block: 0;
    padding-inline-start: var(--zerti-select-pad-inline-start, 0.45rem);
    padding-inline-end: var(--zerti-select-pad-inline-end, 1.75rem);
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 9pt;
    font-weight: 500;
    line-height: 1.2;
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%236b7280' d='M4.2 6.2a.75.75 0 0 1 1.06 0L8 8.94l2.74-2.74a.75.75 0 1 1 1.06 1.06L8.53 10.53a.75.75 0 0 1-1.06 0L4.2 7.26a.75.75 0 0 1 0-1.06Z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: var(--zerti-select-chevron-pos, left 0.4rem center);
    background-size: 0.7rem;
    border: 1px solid var(--zerti-docs-border);
    border-radius: 0.5rem;
    appearance: none;
    cursor: pointer;
    direction: inherit;
    text-align: var(--zerti-select-text-align);
    text-align-last: var(--zerti-select-text-align);
    box-shadow: none;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form .zerti-admin-select,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form select.form-select {
    background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%23adb5bd' d='M4.2 6.2a.75.75 0 0 1 1.06 0L8 8.94l2.74-2.74a.75.75 0 1 1 1.06 1.06L8.53 10.53a.75.75 0 0 1-1.06 0L4.2 7.26a.75.75 0 0 1 0-1.06Z'/%3E%3C/svg%3E");
}

#zertiAdmin .zerti-inv-categories__form .zerti-admin-select:hover,
#zertiAdmin .zerti-inv-categories__form select.form-select:hover {
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 35%, var(--zerti-docs-border));
}

#zertiAdmin .zerti-inv-categories__form .zerti-admin-select:focus,
#zertiAdmin .zerti-inv-categories__form .zerti-admin-select:focus-visible,
#zertiAdmin .zerti-inv-categories__form select.form-select:focus,
#zertiAdmin .zerti-inv-categories__form select.form-select:focus-visible {
    outline: 0;
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 55%, var(--zerti-docs-border));
    box-shadow: 0 0 0 0.2rem color-mix(in srgb, var(--zerti-bs-purple) 22%, transparent);
}

#zertiAdmin .zerti-inv-categories .btn {
    box-sizing: border-box;
    min-height: 0;
    height: 1.55rem;
    padding-block: 0;
    padding-inline: 0.55rem;
    line-height: 1.2;
    border-radius: 0.5rem;
}

#zertiAdmin .zerti-inv-categories .btn .fa-solid,
#zertiAdmin .zerti-inv-categories .btn .fa-regular {
    font-size: 0.7rem;
}

#zertiAdmin .zerti-inv-categories__form .form-control::placeholder {
    color: var(--zerti-docs-muted);
    opacity: 1;
}

#zertiAdmin .zerti-inv-categories__form .form-control:hover {
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 35%, var(--zerti-docs-border));
}

#zertiAdmin .zerti-inv-categories__form .form-control:focus,
#zertiAdmin .zerti-inv-categories__form .form-control:focus-visible {
    outline: 0;
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 55%, var(--zerti-docs-border));
    box-shadow: 0 0 0 0.2rem color-mix(in srgb, var(--zerti-bs-purple) 22%, transparent);
}

#zertiAdmin .zerti-inv-categories__form textarea.form-control {
    height: auto;
    min-height: 3.25rem;
    padding-block: 0.35rem;
    line-height: 1.35;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__search-input,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form .form-control,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form .zerti-admin-select,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form select.form-select {
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border);
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__search-input::placeholder,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form .form-control::placeholder {
    color: var(--zerti-docs-muted);
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__search-input:focus,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__search-input:focus-visible,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form .form-control:focus,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form .form-control:focus-visible,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form .zerti-admin-select:focus,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form .zerti-admin-select:focus-visible,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form select.form-select:focus,
#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__form select.form-select:focus-visible {
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
}

#zertiAdmin .zerti-inv-categories__thumb-preview {
    width: 5.5rem;
    height: 5.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex: 0 0 auto;
    position: relative;
    padding: 0;
}

#zertiAdmin .zerti-inv-categories__thumb-preview > .zerti-inv-categories__thumb-img {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    margin: 0;
    padding: 0;
    border: 0;
    object-fit: cover;
    object-position: center;
}

/* Inventory warehouse — add product toolbar (exit-button style) */
#zertiAdmin .zerti-products-panel-toolbar {
    direction: ltr;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 0.5rem;
}

/* Inventory — product editor */
#zertiAdmin .zerti-inventory-product-edit {
    font-size: 9pt;
    line-height: 1.4;
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-inventory-product-edit__form .form-label,
#zertiAdmin .zerti-inventory-product-edit__form .form-check-label,
#zertiAdmin .zerti-inventory-product-edit__form .form-text,
#zertiAdmin .zerti-inventory-product-edit .h6 {
    font-size: 9pt;
}

#zertiAdmin .zerti-inventory-product-edit .zerti-shop-invoice__title {
    font-size: 9pt;
    font-weight: 700;
}

#zertiAdmin .zerti-inventory-product-edit .zerti-shop-invoice__seller,
#zertiAdmin .zerti-inventory-product-edit .alert,
#zertiAdmin .zerti-inventory-product-edit .btn,
#zertiAdmin .zerti-inventory-product-edit .table {
    font-size: 9pt;
}

#zertiAdmin .zerti-inventory-product-edit__form .form-control,
#zertiAdmin .zerti-inventory-product-edit__form .form-select,
#zertiAdmin .zerti-inventory-product-edit__form .input-group-text {
    font-family: inherit;
    font-size: 9pt;
    font-weight: 500;
    line-height: 1.35;
    min-height: 1.55rem;
    padding: 0.12rem 0.45rem;
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border: 1px solid var(--zerti-docs-border);
    border-radius: 0.5rem;
    box-shadow: none;
}

#zertiAdmin .zerti-inventory-product-edit__form textarea.form-control {
    min-height: 3.5rem;
    padding: 0.35rem 0.45rem;
}

#zertiAdmin .zerti-inventory-product-edit__form .zerti-jalali-date-input.form-control,
#zertiAdmin .zerti-inventory-product-edit__form input[type='number'].form-control {
    min-height: 1.55rem;
}

#zertiAdmin .zerti-inventory-product-edit__form .form-control::placeholder {
    color: var(--zerti-docs-muted);
    opacity: 1;
}

#zertiAdmin .zerti-inventory-product-edit__form .form-control:hover,
#zertiAdmin .zerti-inventory-product-edit__form .form-select:hover {
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 35%, var(--zerti-docs-border));
}

#zertiAdmin .zerti-inventory-product-edit__form .form-control:focus,
#zertiAdmin .zerti-inventory-product-edit__form .form-select:focus,
#zertiAdmin .zerti-inventory-product-edit__form .form-control:focus-visible,
#zertiAdmin .zerti-inventory-product-edit__form .form-select:focus-visible {
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 55%, var(--zerti-docs-border));
    box-shadow: 0 0 0 0.15rem color-mix(in srgb, var(--zerti-bs-purple) 22%, transparent);
    outline: 0;
}

#zertiAdmin .zerti-inventory-product-edit__form .form-control:disabled,
#zertiAdmin .zerti-inventory-product-edit__form .form-select:disabled,
#zertiAdmin .zerti-inventory-product-edit__form .form-control[readonly] {
    color: color-mix(in srgb, var(--zerti-docs-text) 72%, var(--zerti-docs-muted));
    background-color: color-mix(in srgb, var(--zerti-docs-subtle-bg) 82%, var(--zerti-docs-border));
    opacity: 1;
}

#zertiAdmin .zerti-inventory-product-edit__form .form-select {
    padding-inline-start: var(--zerti-select-pad-inline-start, 0.45rem);
    padding-inline-end: var(--zerti-select-pad-inline-end, 1.85rem);
    background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%236b7280' d='M4.2 6.2a.75.75 0 0 1 1.06 0L8 8.94l2.74-2.74a.75.75 0 1 1 1.06 1.06L8.53 10.53a.75.75 0 0 1-1.06 0L4.2 7.26a.75.75 0 0 1 0-1.06Z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: var(--zerti-select-chevron-pos, left 0.45rem center);
    background-size: 0.75rem;
    appearance: none;
    cursor: pointer;
    direction: inherit;
    text-align: var(--zerti-select-text-align);
    text-align-last: var(--zerti-select-text-align);
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inventory-product-edit__form .form-select {
    background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%23adb5bd' d='M4.2 6.2a.75.75 0 0 1 1.06 0L8 8.94l2.74-2.74a.75.75 0 1 1 1.06 1.06L8.53 10.53a.75.75 0 0 1-1.06 0L4.2 7.26a.75.75 0 0 1 0-1.06Z'/%3E%3C/svg%3E");
}

#zertiAdmin .zerti-inventory-product-edit__form .form-select option,
#zertiAdmin .zerti-inventory-product-edit__form .form-select optgroup {
    background-color: var(--zerti-docs-bg);
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-inventory-product-edit__form .input-group-sm > .btn {
    min-height: 1.55rem;
    padding: 0.12rem 0.45rem;
    font-size: 9pt;
}

/* WooCommerce-like product editor shell */
#zertiAdmin .zerti-inventory-product-edit,
#zertiAdmin .zerti-wc-product-editor__form {
    width: 100%;
    max-width: none;
    align-self: stretch;
    box-sizing: border-box;
}

/* New / edit product: panel slot is fixed height; scroll the form (toolbar stays put). */
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-product-editor__toolbar,
#zertiAdmin .zerti-inventory-product-edit > .alert {
    flex: 0 0 auto;
}

#zertiAdmin .zerti-inventory-product-edit > .zerti-inventory-product-edit__form {
    flex: 1 1 0;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    /* Compensate for .row.g-3 negative margin-top so the first card is not clipped */
    padding-top: 1rem;
    padding-bottom: 0.5rem;
}

/*
 * RTL two-column layout: sidebar (publish / image) on the physical left, main cards on the right.
 * CSS grid + 1fr prevents the "shrink-to-content + empty strip" gap between columns.
 */
#zertiAdmin .zerti-wc-product-editor__form > .row {
    display: grid;
    width: 100%;
    max-width: none;
    margin-inline: 0;
    --zerti-wc-editor-sidebar-w: min(17.5rem, 28%);
    grid-template-columns: 1fr var(--zerti-wc-editor-sidebar-w);
    gap: 1rem;
    direction: rtl;
}

#zertiAdmin .zerti-wc-product-editor__form > .row > .zerti-wc-product-editor__primary,
#zertiAdmin .zerti-wc-product-editor__form > .row > .zerti-wc-product-editor__sidebar {
    width: 100%;
    max-width: none;
    min-width: 0;
    padding: 0;
    margin: 0;
}

#zertiAdmin .zerti-wc-product-editor__primary .card,
#zertiAdmin .zerti-wc-product-editor__primary .zerti-wc-product-data,
#zertiAdmin .zerti-wc-product-editor__primary .zerti-wc-postbox {
    width: 100%;
    max-width: none;
}

@media (max-width: 1199.98px) {
    #zertiAdmin .zerti-wc-product-editor__form > .row {
        grid-template-columns: 1fr;
        direction: inherit;
    }
}

#zertiAdmin .zerti-wc-product-editor__sidebar {
    position: sticky;
    top: 0.5rem;
    align-self: flex-start;
}

#zertiAdmin .zerti-wc-postbox {
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 38%, transparent);
    border: 1px solid var(--zerti-docs-border) !important;
    border-radius: var(--zerti-component-panel-radius, 12px);
    overflow: hidden;
}

#zertiAdmin .zerti-wc-postbox__header {
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 65%, transparent);
    border-bottom: 1px solid var(--zerti-docs-border);
}

/* Product editor blocks — no outer holding card; 0.5rem rounded shell */
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--title,
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--editor,
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--meta,
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-product-data {
    --zerti-wc-postbox-radius: 0.5rem;
    background: transparent;
    border: 1px solid var(--zerti-docs-border) !important;
    box-shadow: none;
    border-radius: var(--zerti-wc-postbox-radius);
    overflow: hidden;
}

#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--title > .zerti-wc-postbox__body,
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--editor > .zerti-wc-postbox__body {
    padding: 0;
}

#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--meta > .zerti-wc-postbox__inside {
    padding: 0.75rem 1rem;
    background: var(--zerti-docs-bg);
    border-radius: 0 0 var(--zerti-wc-postbox-radius) var(--zerti-wc-postbox-radius);
}

#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--title > .zerti-wc-postbox__header,
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--editor > .zerti-wc-postbox__header,
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-postbox--meta > .zerti-wc-postbox__header,
#zertiAdmin .zerti-inventory-product-edit .zerti-wc-product-data__head {
    border-radius: var(--zerti-wc-postbox-radius) var(--zerti-wc-postbox-radius) 0 0;
}

#zertiAdmin .zerti-inventory-product-edit__form .zerti-wc-postbox--title .zerti-wc-editor-title-input {
    width: 100%;
    max-width: none;
    font-size: 10pt;
    font-weight: 400;
    line-height: 1.35;
    min-height: 2.25rem;
    padding: 0.35rem 0.5rem;
    background-color: var(--zerti-docs-bg);
    border: none;
    border-radius: 0 0 var(--zerti-wc-postbox-radius) var(--zerti-wc-postbox-radius);
    color: var(--zerti-docs-text);
    box-shadow: none;
}

#zertiAdmin .zerti-inventory-product-edit__form .zerti-wc-postbox--title .zerti-wc-editor-title-input:hover {
    border-color: transparent;
}

#zertiAdmin .zerti-inventory-product-edit__form .zerti-wc-postbox--title .zerti-wc-editor-title-input:focus,
#zertiAdmin .zerti-inventory-product-edit__form .zerti-wc-postbox--title .zerti-wc-editor-title-input:focus-visible {
    border-color: transparent;
    box-shadow: 0 0 0 0.15rem color-mix(in srgb, var(--zerti-bs-purple) 22%, transparent);
    outline: 0;
}

#zertiAdmin .zerti-wc-postbox--title .zerti-wc-postbox__header label {
    font-size: inherit;
    font-weight: inherit;
    color: inherit;
    cursor: pointer;
}

#zertiAdmin .zerti-inventory-product-edit .zerti-wc-product-data__head {
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 65%, transparent);
    border-bottom: 1px solid var(--zerti-docs-border);
}

#zertiAdmin .zerti-wc-product-data__type-wrap {
    min-width: 0;
    flex: 1 1 auto;
}

#zertiAdmin .zerti-wc-product-data__type-label {
    font-weight: 600;
    color: var(--zerti-docs-text);
    white-space: nowrap;
}

#zertiAdmin .zerti-wc-product-data__type-sep {
    font-weight: 400;
}

#zertiAdmin .zerti-wc-product-data__type-select {
    min-width: 11.5rem;
    max-width: 100%;
    width: auto;
    flex: 0 1 16rem;
    background-color: var(--zerti-docs-bg);
    border-color: var(--zerti-docs-border);
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-wc-product-data__type-select:focus,
#zertiAdmin .zerti-wc-product-data__type-select:focus-visible {
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 55%, var(--zerti-docs-border));
    box-shadow: 0 0 0 0.2rem color-mix(in srgb, var(--zerti-bs-purple) 22%, transparent);
    outline: 0;
}

#zertiAdmin .zerti-wc-product-data__flags {
    flex: 0 1 auto;
}

#zertiAdmin .zerti-inventory-product-edit .zerti-wc-product-data__body {
    min-height: 16rem;
    background: var(--zerti-docs-bg);
    border-radius: 0 0 var(--zerti-wc-postbox-radius, 0.5rem) var(--zerti-wc-postbox-radius, 0.5rem);
}

#zertiAdmin .zerti-wc-tabs {
    flex: 0 0 10.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
    border-inline-start: 1px solid var(--zerti-docs-border);
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 48%, transparent);
}

#zertiAdmin .zerti-wc-tabs__item {
    margin: 0;
    padding: 0;
}

#zertiAdmin .zerti-wc-tabs__item.disabled {
    opacity: 0.4;
    pointer-events: none;
}

#zertiAdmin .zerti-wc-tabs__link {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    width: 100%;
    padding: 0.5rem 0.7rem;
    font-size: 9pt;
    font-weight: 500;
    color: var(--zerti-docs-muted);
    text-decoration: none;
    border: none;
    background: transparent;
    border-inline-start: 3px solid transparent;
}

#zertiAdmin .zerti-wc-tabs__link i {
    width: 1rem;
    text-align: center;
    opacity: 0.85;
}

#zertiAdmin .zerti-wc-tabs__item.active .zerti-wc-tabs__link,
#zertiAdmin .zerti-wc-tabs__link.active {
    color: var(--zerti-docs-text);
    background: var(--zerti-docs-bg);
    border-inline-start-color: var(--zerti-bs-purple);
    font-weight: 600;
}

#zertiAdmin .zerti-wc-panels {
    min-width: 0;
    background: var(--zerti-docs-bg);
}

#zertiAdmin .zerti-wc-panel {
    display: none;
    padding: 0;
}

#zertiAdmin .zerti-wc-panel.active {
    display: block;
}

#zertiAdmin .zerti-wc-panel--disabled {
    opacity: 0.65;
    pointer-events: none;
}

#zertiAdmin .zerti-wc-options-group {
    border-top: 1px solid var(--zerti-docs-border);
    padding: 0;
}

#zertiAdmin .zerti-wc-options-group:first-child {
    border-top: none;
}

#zertiAdmin .zerti-wc-form-field {
    display: grid;
    grid-template-columns: minmax(7.5rem, 22%) minmax(0, 1fr);
    gap: 0.35rem 0.85rem;
    align-items: start;
    margin: 0;
    padding: 0.55rem 1rem;
    border-bottom: 1px solid color-mix(in srgb, var(--zerti-docs-border) 45%, transparent);
}

#zertiAdmin .zerti-wc-form-field:last-child {
    border-bottom: none;
}

#zertiAdmin .zerti-wc-form-field label {
    grid-column: 1;
    margin: 0;
    padding-top: 0.2rem;
    font-size: 9pt;
    font-weight: 600;
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-wc-form-field__description {
    display: block;
    grid-column: 2;
    font-size: 8pt;
    color: var(--zerti-docs-muted);
    margin-top: 0.2rem;
}

#zertiAdmin .zerti-wc-form-field > :not(label):not(.zerti-wc-form-field__description) {
    grid-column: 2;
    min-width: 0;
}

#zertiAdmin .zerti-wc-form-field--wide {
    grid-template-columns: 1fr;
}

#zertiAdmin .zerti-wc-form-field--wide label {
    grid-column: 1;
}

#zertiAdmin .zerti-wc-form-field--wide > :not(label):not(.zerti-wc-form-field__description) {
    grid-column: 1;
}

#zertiAdmin .zerti-wc-form-field .form-control,
#zertiAdmin .zerti-wc-form-field .form-select {
    max-width: 100%;
}

#zertiAdmin .zerti-wc-form-field--wide .zerti-product-linked-picker {
    width: 100%;
}

#zertiAdmin .zerti-wc-panel-toolbar {
    border-bottom: 1px solid color-mix(in srgb, var(--zerti-docs-border) 45%, transparent);
    padding-bottom: 1rem;
}

#zertiAdmin .zerti-wc-attributes-table thead th,
#zertiAdmin .zerti-wc-downloads-table thead th {
    font-size: 9pt;
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 55%, transparent);
}

#zertiAdmin .zerti-variations-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0 1rem 1rem;
}

#zertiAdmin .zerti-variation-item {
    border: 1px solid color-mix(in srgb, var(--zerti-docs-border) 55%, transparent);
    border-radius: 0.375rem;
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 35%, transparent);
}

#zertiAdmin .zerti-variation-item__head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid color-mix(in srgb, var(--zerti-docs-border) 40%, transparent);
}

#zertiAdmin .zerti-variation-item--collapsed .zerti-variation-item__head {
    border-bottom: none;
}

#zertiAdmin .zerti-variation-item__toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0;
    text-decoration: none;
    color: var(--zerti-docs-text);
    font-weight: 500;
}

#zertiAdmin .zerti-variation-item__toggle:hover,
#zertiAdmin .zerti-variation-item__toggle:focus {
    color: var(--zerti-docs-text);
    text-decoration: none;
}

#zertiAdmin .zerti-variation-item__chevron {
    width: 0.875rem;
    flex-shrink: 0;
}

#zertiAdmin .zerti-variation-item__body {
    padding: 0.75rem;
}

#zertiAdmin .zerti-variation-item__body .form-label {
    color: var(--zerti-docs-muted);
}

#zertiAdmin .zerti-variation-item--draft [data-zerti-variation-picks] {
    width: 100%;
}

#zertiAdmin .zerti-variation-item--draft [data-zerti-variation-pick] {
    min-width: 8rem;
}

#zertiAdmin .zerti-product-attr-values {
    width: 100%;
}

#zertiAdmin .zerti-product-attr-values-global {
    width: 100%;
}

#zertiAdmin .zerti-product-attr-values-select {
    width: 100%;
}

#zertiAdmin .zerti-product-attr-values-global .select2-container {
    width: 100% !important;
    max-width: 100%;
}

/* Product attribute chips — reuse .zerti-admin-select2 tokens; × separator per chip. */
#zertiAdmin .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__choice__remove {
    border-inline-end: 1px solid color-mix(in srgb, var(--zerti-bs-purple) 22%, var(--zerti-docs-border));
    padding-inline: 0.15rem 0.35rem;
    margin-inline-end: 0.3rem;
}

/* Beat WooCommerce select2.css (loads after zerti-admin) — readable in both themes. */
#zertiAdmin .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple,
#zertiAdmin .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple {
    background-color: var(--zerti-docs-subtle-bg) !important;
    border-color: var(--zerti-docs-border) !important;
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple .select2-selection__rendered,
#zertiAdmin .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__rendered {
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple .select2-selection__placeholder,
#zertiAdmin .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__placeholder {
    color: var(--zerti-docs-muted) !important;
}

#zertiAdmin .zerti-product-attr-values-global .select2-container--default .select2-search--inline .select2-search__field,
#zertiAdmin .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-search--inline .select2-search__field {
    color: var(--zerti-docs-text) !important;
}

#zertiAdmin .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple .select2-selection__choice,
#zertiAdmin .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__choice {
    color: var(--zerti-docs-text) !important;
    background-color: color-mix(in srgb, var(--zerti-bs-purple) 12%, var(--zerti-docs-subtle-bg)) !important;
    border: 1px solid color-mix(in srgb, var(--zerti-bs-purple) 30%, var(--zerti-docs-border)) !important;
}

#zertiAdmin .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple .select2-selection__choice__display,
#zertiAdmin .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__choice__display {
    color: inherit !important;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple,
#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple {
    background-color: var(--zerti-docs-subtle-bg) !important;
    border-color: var(--zerti-docs-border) !important;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple .select2-selection__choice,
#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__choice {
    color: #212529 !important;
    background-color: #ced4da !important;
    border-color: #adb5bd !important;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple .select2-selection__choice__display,
#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__choice__display {
    color: #212529 !important;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple .select2-selection__choice__remove,
#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__choice__remove {
    color: #495057 !important;
    border-inline-end-color: #6c757d !important;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover,
#zertiAdmin[data-bs-theme='dark'] .zerti-product-attr-values-global .select2-container.zerti-admin-select2 .select2-selection--multiple .select2-selection__choice__remove:hover {
    color: #212529 !important;
}

#zertiAdmin .zerti-product-attr-values-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.35rem 0.5rem;
    margin-top: 0.5rem;
}

@media (max-width: 767.98px) {
    #zertiAdmin .zerti-wc-product-data__body {
        flex-direction: column !important;
    }

    #zertiAdmin .zerti-wc-tabs {
        flex: 0 0 auto;
        width: 100%;
        border-inline-start: none;
        border-bottom: 1px solid var(--zerti-docs-border);
        display: flex;
        flex-wrap: wrap;
    }

    #zertiAdmin .zerti-wc-tabs__item {
        flex: 1 1 auto;
    }

    #zertiAdmin .zerti-wc-tabs__link {
        justify-content: center;
        border-inline-start: none;
        border-bottom: 3px solid transparent;
    }

    #zertiAdmin .zerti-wc-tabs__item.active .zerti-wc-tabs__link {
        border-bottom-color: var(--zerti-bs-purple);
        border-inline-start-color: transparent;
    }

    #zertiAdmin .zerti-wc-form-field {
        grid-template-columns: 1fr;
    }

    #zertiAdmin .zerti-wc-form-field label,
    #zertiAdmin .zerti-wc-form-field > :not(label):not(.zerti-wc-form-field__description) {
        grid-column: 1;
    }
}

#zertiAdmin .zerti-inventory-product-edit__image-preview {
    width: 100%;
    max-width: 12rem;
    aspect-ratio: 1;
    margin-inline: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    border: 1px solid color-mix(in srgb, var(--zerti-docs-border) 70%, transparent);
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 55%, transparent);
    color: var(--zerti-docs-muted);
    overflow: hidden;
}

#zertiAdmin .zerti-inventory-product-edit__image-preview--empty {
    font-size: 2rem;
    opacity: 0.65;
}

#zertiAdmin .zerti-inventory-product-edit__image-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

#zertiAdmin .zerti-inventory-product-edit__cat-tree {
    max-height: 14rem;
    overflow-y: auto;
    direction: inherit;
}

#zertiAdmin .zerti-product-cat-tree {
    direction: inherit;
    width: 100%;
}

#zertiAdmin .zerti-product-cat-tree__level {
    list-style: none;
    margin: 0;
    padding: 0;
    width: 100%;
    direction: inherit;
}

#zertiAdmin .zerti-product-cat-tree__item {
    display: block;
    width: 100%;
}

#zertiAdmin .zerti-product-cat-tree__row {
    --zerti-cat-indent: 10px;
    direction: inherit;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 0.35rem;
    padding-block: 0.2rem;
    padding-inline-end: 0.25rem;
    padding-inline-start: calc(var(--zerti-cat-depth, 0) * var(--zerti-cat-indent));
    border-radius: 0.35rem;
}

#zertiAdmin .zerti-product-cat-tree__row:hover {
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 55%, transparent);
}

#zertiAdmin .zerti-product-cat-tree__toggle {
    width: 1.25rem;
    height: 1.25rem;
    flex: 0 0 auto;
    color: var(--zerti-docs-text, inherit);
    text-decoration: none;
    line-height: 1;
}

#zertiAdmin .zerti-product-cat-tree__toggle-spacer {
    display: inline-block;
    width: 1.25rem;
    flex: 0 0 auto;
}

#zertiAdmin .zerti-product-cat-tree__check {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 5px;
    flex: 1 1 auto;
    min-width: 0;
    padding: 0;
    min-height: 0;
}

#zertiAdmin .zerti-product-cat-tree__check .form-check-label {
    font-size: 9pt;
    line-height: 1.35;
    padding: 0;
    margin: 0;
    flex: 1 1 auto;
    min-width: 0;
    align-self: center;
    text-align: start;
}

#zertiAdmin .zerti-product-cat-tree__children[hidden] {
    display: none !important;
}

#zertiAdmin .zerti-inventory-product-edit__gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    direction: ltr;
}

#zertiAdmin .zerti-inventory-product-edit__gallery-item {
    position: relative;
    width: 4.25rem;
    height: 4.25rem;
    border-radius: 0.375rem;
    overflow: hidden;
    border: 1px solid color-mix(in srgb, var(--zerti-docs-border) 70%, transparent);
}

#zertiAdmin .zerti-inventory-product-edit__gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

#zertiAdmin .zerti-inventory-product-edit__gallery-item [data-zerti-gallery-remove] {
    position: absolute;
    top: 2px;
    inset-inline-end: 2px;
    line-height: 1;
    padding: 0 0.35rem;
    min-width: 0;
}

#zertiAdmin .zerti-inventory-product-edit__footer {
    border-color: color-mix(in srgb, var(--zerti-docs-border) 55%, transparent) !important;
}

#zertiAdmin .zerti-inventory-product-save[disabled],
#zertiAdmin .zerti-inventory-product-save[aria-busy='true'] {
    opacity: 0.65;
    cursor: progress;
}

#zertiAdmin [data-zerti-product-stock-qty-wrap][hidden],
#zertiAdmin [data-zerti-product-stock-status-wrap][hidden],
#zertiAdmin [data-zerti-downloads-panel][hidden] {
    display: none !important;
}

#zertiAdmin .zerti-product-linked-picker__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    direction: rtl;
}

#zertiAdmin .zerti-product-linked-picker__chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.15rem 0.45rem;
    border-radius: 999px;
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 65%, transparent);
    border: 1px solid color-mix(in srgb, var(--zerti-docs-border) 60%, transparent);
    font-size: 9pt;
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-product-linked-picker__search .form-control {
    min-height: 1.55rem;
}

#zertiAdmin .zerti-product-linked-picker__results {
    position: absolute;
    z-index: 20;
    inset-inline: 0;
    top: 100%;
    margin-top: 2px;
    max-height: 12rem;
    overflow-y: auto;
    background: var(--zerti-docs-bg);
    color: var(--zerti-docs-text);
    border: 1px solid var(--zerti-docs-border);
    border-radius: 0.375rem;
    box-shadow: 0 4px 12px color-mix(in srgb, #000 12%, transparent);
}

#zertiAdmin .zerti-product-linked-picker__result {
    display: block;
    width: 100%;
    text-align: start;
    border: none;
    background: transparent;
    color: var(--zerti-docs-text);
    padding: 0.3rem 0.55rem;
    font-size: 9pt;
}

#zertiAdmin .zerti-product-linked-picker__result:hover,
#zertiAdmin .zerti-product-linked-picker__result:focus {
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 75%, transparent);
}

#zertiAdmin .zerti-product-tags-input .form-control {
    min-height: 1.55rem;
}

/* Product tags/brands autocomplete must escape postbox overflow clipping */
#zertiAdmin #tagsdiv-product_tag.zerti-wc-postbox,
#zertiAdmin #tagsdiv-product_tag .zerti-wc-postbox__inside,
#zertiAdmin [id^='brandsdiv-'].zerti-wc-postbox,
#zertiAdmin [id^='brandsdiv-'] .zerti-wc-postbox__inside,
#zertiAdmin .zerti-wc-postbox--tags-open,
#zertiAdmin .zerti-wc-postbox--tags-open .zerti-wc-postbox__inside,
#zertiAdmin .zerti-wc-postbox--brands-open,
#zertiAdmin .zerti-wc-postbox--brands-open .zerti-wc-postbox__inside {
    overflow: visible;
}

#zertiAdmin .zerti-wc-postbox--tags-open,
#zertiAdmin .zerti-wc-postbox--brands-open {
    position: relative;
    z-index: 15;
}

#zertiAdmin .zerti-product-tags-input--open {
    position: relative;
    z-index: 16;
}

#zertiAdmin .zerti-product-tags-input__results {
    position: absolute;
    z-index: 1060;
    inset-inline: 0;
    top: 100%;
    margin-top: 2px;
    max-height: 12rem;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: var(--zerti-docs-bg);
    color: var(--zerti-docs-text);
    border: 1px solid var(--zerti-docs-border);
    border-radius: 0.375rem;
    box-shadow: 0 4px 16px color-mix(in srgb, #000 18%, transparent);
}

#zertiAdmin .zerti-product-tags-input__result {
    display: block;
    width: 100%;
    text-align: start;
    border: none;
    background: transparent;
    color: var(--zerti-docs-text);
    padding: 0.3rem 0.55rem;
    font-size: 9pt;
}

#zertiAdmin .zerti-product-tags-input__result:hover,
#zertiAdmin .zerti-product-tags-input__result:focus {
    background: color-mix(in srgb, var(--zerti-docs-subtle-bg) 75%, transparent);
}

#zertiAdmin .zerti-product-attributes-table th,
#zertiAdmin .zerti-product-attributes-table td {
    font-size: 9pt;
}

#zertiAdmin .zerti-product-attributes-table th {
    font-weight: 600;
}

#zertiAdmin .zerti-wc-publish-fields .form-label {
    font-size: 9pt;
}

/* Inventory — product tags / brands / attributes (reuse categories layout) */
#zertiAdmin .zerti-component-inventory-tags,
#zertiAdmin .zerti-component-inventory-brands,
#zertiAdmin .zerti-component-inventory-attributes,
#zertiAdmin .zerti-component-inventory-attribute-groups {
    display: flex;
    flex-direction: column;
    flex: 1 1 0;
    min-height: 0;
    max-height: 100%;
    width: 100%;
    max-width: 100%;
    align-self: stretch;
    overflow: hidden;
}

#zertiAdmin .zerti-inv-categories--flat .zerti-inv-categories__tree-toggle,
#zertiAdmin .zerti-inv-categories--flat .zerti-inv-categories__tree-toggle-spacer {
    display: none;
}

/* Inventory — product reviews (comments) */
#zertiAdmin .zerti-component-inventory-comments {
    display: flex;
    flex-direction: column;
    flex: 1 1 0;
    min-height: 0;
    max-height: 100%;
    width: 100%;
    max-width: 100%;
    align-self: stretch;
    overflow: hidden;
    box-sizing: border-box;
}

#zertiAdmin .zerti-inv-reviews {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1 1 0;
    min-height: 0;
    max-height: 100%;
    min-width: 0;
    width: 100%;
    max-width: none;
    align-self: stretch;
    overflow: hidden;
    box-sizing: border-box;
    position: relative;
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 9pt;
}

/* Reviews modals: under body; data-bs-theme synced from #zertiAdmin in JS. */
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='dark'],
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[data-bs-theme='dark'] {
    color-scheme: dark;
    --zerti-bs-purple: #712cf9;
    --zerti-bs-purple-hover: #6528e0;
    --zerti-color-white-text: color-mix(in srgb, #000000 5%, #ffffff);
    --zerti-docs-bg: #212529;
    --zerti-docs-subtle-bg: #2b3035;
    --zerti-docs-border: #495057;
    --zerti-docs-text: #dee2e6;
    --zerti-docs-muted: #adb5bd;
    --bs-modal-bg: #2b3035;
    --bs-modal-color: #dee2e6;
    --bs-modal-border-color: #495057;
    --bs-border-color: #495057;
    --bs-body-bg: #2b3035;
    --bs-body-color: #dee2e6;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='light'],
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[data-bs-theme='light'] {
    color-scheme: light;
    --zerti-bs-purple: #712cf9;
    --zerti-bs-purple-hover: #6528e0;
    --zerti-color-white-text: color-mix(in srgb, #000000 5%, #ffffff);
    --zerti-docs-bg: #fff;
    --zerti-docs-subtle-bg: #f8f9fa;
    --zerti-docs-border: #dee2e6;
    --zerti-docs-text: #212529;
    --zerti-docs-muted: #6c757d;
    --bs-modal-bg: #fff;
    --bs-modal-color: #212529;
    --bs-modal-border-color: #dee2e6;
    --bs-border-color: #dee2e6;
    --bs-body-bg: #fff;
    --bs-body-color: #212529;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .modal-content,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .modal-content {
    text-align: start;
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 8pt;
    font-weight: 400;
    background-color: var(--bs-modal-bg);
    color: var(--bs-modal-color);
    border-color: var(--bs-modal-border-color);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[dir='rtl'] .modal-content,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[dir='rtl'] .modal-content {
    direction: rtl;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[dir='ltr'] .modal-content,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[dir='ltr'] .modal-content {
    direction: ltr;
    text-align: left;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .modal-header,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .modal-footer,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .modal-header,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .modal-footer {
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 8pt;
    font-weight: 400;
    border-color: var(--bs-modal-border-color);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .modal-body,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .modal-body {
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 8pt;
    font-weight: 400;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .modal-title,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .modal-title {
    font-size: 8pt;
    font-weight: 400;
    color: var(--bs-modal-color);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .form-label,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .form-text,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .form-label {
    font-size: 8pt;
    font-weight: 400;
    color: var(--zerti-docs-text);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .form-text {
    color: var(--zerti-docs-muted);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .form-control,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .form-select,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .form-control {
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 8pt;
    font-weight: 400;
    background-color: var(--zerti-docs-subtle-bg);
    color: var(--zerti-docs-text);
    border-color: var(--zerti-docs-border);
}

/* Dropdown chevron/text follow #zertiAdmin[dir] (see :has rules below). */
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.form-select,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.zerti-admin-select {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    min-height: 1.55rem;
    padding-block: 0.12rem;
    line-height: 1.4;
    appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%236b7280' d='M4.2 6.2a.75.75 0 0 1 1.06 0L8 8.94l2.74-2.74a.75.75 0 1 1 1.06 1.06L8.53 10.53a.75.75 0 0 1-1.06 0L4.2 7.26a.75.75 0 0 1 0-1.06Z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-size: 0.9rem;
    box-shadow: none;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='dark'] select.form-select,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='dark'] select.zerti-admin-select {
    background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%23adb5bd' d='M4.2 6.2a.75.75 0 0 1 1.06 0L8 8.94l2.74-2.74a.75.75 0 1 1 1.06 1.06L8.53 10.53a.75.75 0 0 1-1.06 0L4.2 7.26a.75.75 0 0 1 0-1.06Z'/%3E%3C/svg%3E");
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.form-select:hover,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.zerti-admin-select:hover {
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 35%, var(--zerti-docs-border));
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.form-select:focus,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.form-select:focus-visible,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.zerti-admin-select:focus,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.zerti-admin-select:focus-visible {
    outline: 0;
    border-color: color-mix(in srgb, var(--zerti-bs-purple) 55%, var(--zerti-docs-border));
    box-shadow: 0 0 0 0.2rem color-mix(in srgb, var(--zerti-bs-purple) 22%, transparent);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.form-select option,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.form-select optgroup,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.zerti-admin-select option,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal select.zerti-admin-select optgroup {
    background-color: var(--zerti-docs-bg);
    color: var(--zerti-docs-text);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .btn,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .btn {
    font-family: 'Vazirmatn', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 8pt;
    font-weight: 400;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='dark'] .btn-close,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[data-bs-theme='dark'] .btn-close {
    filter: invert(1) grayscale(100%);
    opacity: 0.75;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='light'] .btn-close,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[data-bs-theme='light'] .btn-close {
    filter: none;
    opacity: 0.65;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .alert,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .alert {
    font-size: 8pt;
    font-weight: 400;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='dark'] .alert-danger,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[data-bs-theme='dark'] .alert-danger {
    background-color: color-mix(in srgb, #dc3545 18%, var(--zerti-docs-subtle-bg));
    border-color: color-mix(in srgb, #dc3545 45%, var(--zerti-docs-border));
    color: var(--zerti-docs-text);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='dark'] .alert-success,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[data-bs-theme='dark'] .alert-success {
    background-color: color-mix(in srgb, #198754 18%, var(--zerti-docs-subtle-bg));
    border-color: color-mix(in srgb, #198754 45%, var(--zerti-docs-border));
    color: var(--zerti-docs-text);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .btn.btn-primary {
    --bs-btn-color: var(--zerti-color-white-text);
    --bs-btn-bg: transparent;
    --bs-btn-border-color: transparent;
    --bs-btn-hover-color: var(--zerti-color-white-text);
    --bs-btn-hover-bg: transparent;
    --bs-btn-hover-border-color: transparent;
    --bs-btn-active-color: var(--zerti-color-white-text);
    --bs-btn-active-bg: transparent;
    --bs-btn-active-border-color: transparent;
    color: var(--zerti-color-white-text);
    border: 1px solid rgba(255, 255, 255, 0.18);
    background-image: linear-gradient(135deg, #4c1d95 0%, #5b21b6 18%, #712cf9 45%, #4c6ef5 72%, #228be6 100%);
    background-size: 200% 100%;
    background-position: 0% 50%;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .btn.btn-primary:hover {
    background-position: 100% 50%;
    filter: brightness(1.07);
    box-shadow: 0 4px 14px rgba(113, 44, 249, 0.45);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .btn-outline-secondary,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .btn-outline-secondary {
    color: var(--zerti-docs-text);
    border-color: var(--zerti-docs-border);
    background-color: transparent;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .btn-outline-secondary:hover,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal .btn-outline-secondary:hover {
    background-color: color-mix(in srgb, var(--zerti-docs-muted) 14%, transparent);
    color: var(--zerti-docs-text);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .btn-outline-danger {
    color: #ea868f;
    border-color: color-mix(in srgb, #dc3545 55%, var(--zerti-docs-border));
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='light'] .btn-outline-danger {
    color: #842029;
    border-color: #f1aeb5;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .btn-outline-danger:hover {
    background-color: color-mix(in srgb, #dc3545 16%, transparent);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='light'] .alert-danger,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[data-bs-theme='light'] .alert-danger {
    background-color: #f8d7da;
    border-color: #f1aeb5;
    color: #58151c;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal[data-bs-theme='light'] .alert-success,
body.toplevel_page_zerti-admin .zerti-inv-reviews__delete-modal[data-bs-theme='light'] .alert-success {
    background-color: #d1e7dd;
    border-color: #badbcc;
    color: #0a3622;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .zerti-inv-reviews__product-line.text-muted {
    color: var(--zerti-docs-muted) !important;
    font-size: 8pt;
    font-weight: 400;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .zerti-inv-reviews__meta-label {
    color: var(--zerti-docs-muted);
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .zerti-inv-reviews__detail-link {
    color: var(--zerti-bs-purple);
    text-decoration: none;
    font-weight: 500;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .zerti-inv-reviews__detail-link:hover,
body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .zerti-inv-reviews__detail-link:focus-visible {
    color: var(--zerti-bs-purple-hover);
    text-decoration: underline;
}

body.toplevel_page_zerti-admin .zerti-inv-reviews__edit-modal .modal-body .small {
    font-size: 8pt;
}

#zertiAdmin .zerti-inv-reviews__list-head {
    flex: 0 0 auto;
    padding: 0.5rem 0.75rem;
    direction: rtl;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-inv-reviews__list-head {
    direction: ltr;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

#zertiAdmin .zerti-inv-reviews__status-filter {
    min-width: 9rem;
    max-width: 11rem;
    font-size: 9pt;
    font-weight: 500;
    height: 1.55rem;
    padding-block: 0.08rem;
    padding-inline: 0.45rem 1.75rem;
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border);
    border-radius: 0.5rem;
}

/* Comments grid loading overlay: remove border/shadow chrome around "Loading..." */
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-overlay-loading-center,
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-overlay-no-rows-center {
    border: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-overlay-loading-wrapper {
    background: transparent !important;
}

#zertiAdmin .zerti-inv-reviews__layout {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: stretch;
    align-self: stretch;
    gap: 0.5rem;
    flex: 1 1 0;
    min-height: 0;
    max-height: 100%;
    min-width: 0;
    width: 100%;
    max-width: none;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: color-mix(in srgb, var(--zerti-docs-muted) 55%, transparent) transparent;
    box-sizing: border-box;
}

#zertiAdmin .zerti-inv-reviews__layout::-webkit-scrollbar {
    width: 6px;
}

#zertiAdmin .zerti-inv-reviews__layout::-webkit-scrollbar-thumb {
    background: color-mix(in srgb, var(--zerti-docs-muted) 45%, transparent);
    border-radius: 999px;
}

@media (min-width: 992px) {
    #zertiAdmin .zerti-inv-reviews__layout {
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: stretch;
        width: 100%;
        max-height: 100%;
    }

    /* RTL row: list 60% (fills row height), editor 40% (content height). */
    #zertiAdmin .zerti-inv-reviews__list-panel {
        min-height: 100%;
        height: auto;
        align-self: stretch;
        box-sizing: border-box;
        flex: 1 1 0;
        min-width: 0;
        max-width: 100%;
        width: 100%;
    }

    #zertiAdmin .zerti-inv-reviews__editor,
    #zertiAdmin .zerti-inv-reviews__editor.zerti-inv-reviews__editor--collapsed,
    #zertiAdmin .zerti-inv-reviews__editor:not(.zerti-inv-reviews__editor--collapsed) {
        flex: 2 1 0;
        min-width: 0;
        max-width: none;
        width: auto;
        height: auto;
        min-height: 0;
        box-sizing: border-box;
    }

    #zertiAdmin .zerti-inv-reviews__editor.zerti-inv-reviews__editor--collapsed {
        align-self: stretch;
        min-height: 100%;
    }

    #zertiAdmin .zerti-inv-reviews__editor:not(.zerti-inv-reviews__editor--collapsed) {
        align-self: flex-start;
    }

    #zertiAdmin .zerti-inv-reviews__editor.zerti-inv-reviews__editor--collapsed::after {
        content: '';
        display: block;
        flex: 1 1 auto;
        min-height: 0;
    }
}

/* Tablet + mobile: comments list — same flex fill as customers (old list+editor stack rules removed). */
@media (max-width: 991.98px) {
    #zertiAdmin .zerti-panel-slot > .zerti-component.zerti-component-inventory-comments {
        flex: 1 1 0;
        min-height: 0;
        height: 100%;
        max-height: 100%;
        overflow: hidden;
    }

    #zertiAdmin .zerti-component-inventory-comments {
        flex: 1 1 0;
        min-height: 0;
        max-height: 100%;
        overflow: hidden;
    }

    #zertiAdmin .zerti-inv-reviews {
        flex: 1 1 0;
        min-height: 0;
        height: 100%;
        max-height: 100%;
        overflow: hidden;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-wrap {
        overflow: hidden;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid-toolbar {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
        direction: ltr;
        gap: 0.5rem;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid-toolbar-search {
        flex: 1 1 auto;
        min-width: 0;
        width: auto;
        justify-content: flex-start;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid-toolbar-actions {
        flex: 0 0 auto;
        width: auto;
        justify-content: flex-end;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid-toolbar-search .zerti-inv-categories__search-input {
        text-align: start;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid-toolbar-actions .zerti-inv-reviews__status-filter {
        min-width: min(100%, 10rem);
        max-width: min(100%, 16rem);
        margin-inline: 0;
        text-align: start;
        text-align-last: auto;
        padding-inline: 0.45rem 1.75rem;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid {
        width: 100%;
        min-width: 0;
        padding: 0.5rem 0.45rem;
        --ag-cell-horizontal-padding: 0.35rem;
        --ag-row-height: 3.5rem;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid--compact .ag-center-cols-viewport {
        overflow-x: hidden;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid--compact .ag-header-cell,
    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid--compact .ag-cell {
        min-width: 0;
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid--compact .ag-row {
        border-bottom: 1px solid color-mix(in srgb, var(--zerti-docs-border) 35%, transparent);
    }

    #zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid--compact .ag-cell {
        white-space: normal;
        line-height: 1.35;
        word-break: break-word;
        overflow: hidden;
    }
}

#zertiAdmin .zerti-inv-reviews__list-panel,
#zertiAdmin .zerti-inv-reviews__editor {
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-inv-reviews__list-panel.card {
    border: 0;
    background: transparent;
    box-shadow: none;
    overflow: hidden;
}

#zertiAdmin .zerti-inv-reviews__list-panel > .card-body {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#zertiAdmin .zerti-inv-reviews__editor > .zerti-inv-reviews__editor-bar {
    flex: 0 0 auto;
}

#zertiAdmin .zerti-inv-reviews__editor > .zerti-inv-reviews__editor-body {
    flex: 1 1 0;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

#zertiAdmin .zerti-inv-reviews__editor:not(.zerti-inv-reviews__editor--collapsed) {
    display: flex;
    flex-direction: column;
    align-self: flex-start;
    height: auto;
    max-height: none;
    overflow: visible;
}

#zertiAdmin .zerti-inv-reviews__editor:not(.zerti-inv-reviews__editor--collapsed) > .zerti-inv-reviews__editor-body {
    flex: 0 0 auto;
    height: auto;
    max-height: none;
    overflow: visible;
}

#zertiAdmin .zerti-inv-reviews__editor:not(.zerti-inv-reviews__editor--collapsed) > .card-body {
    flex: 0 0 auto;
    min-height: 0;
    height: auto;
    max-height: none;
    overflow: visible;
}

#zertiAdmin .zerti-inv-reviews__editor:not(.zerti-inv-reviews__editor--collapsed) > .zerti-inv-reviews__editor-bar.card-body {
    display: flex;
}

#zertiAdmin .zerti-inv-reviews__grid-wrap {
    flex: 1 1 0;
    min-height: 0;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    margin: 0;
    width: 100%;
    overflow: hidden;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-wrap {
    flex: 1 1 0;
    min-height: 0;
    height: 100%;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 14px;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-panel {
    flex: 1 1 0;
    min-height: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-wrap .zerti-inv-reviews__list-head {
    flex: 0 0 auto;
    border-radius: 14px 14px 0 0;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid {
    --ag-wrapper-border-radius: 0 0 14px 14px;
    max-height: 100%;
    box-sizing: border-box;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-root-wrapper {
    border-radius: 0 0 14px 14px;
    overflow: hidden;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-body-viewport {
    min-height: 0;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-root-wrapper,
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-root-wrapper-body {
    min-height: 0;
    max-height: 100%;
    overflow: hidden;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-root,
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-header,
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-body-viewport,
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-center-cols-viewport,
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-center-cols-container {
    background: transparent;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-header {
    border-bottom: 1px solid color-mix(in srgb, var(--zerti-docs-border) 70%, transparent);
    box-shadow: 0 1px 0 color-mix(in srgb, var(--zerti-docs-text) 4%, transparent) inset;
    border-radius: 0;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-header-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-header-row-column-filter,
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-floating-filter,
#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-floating-filter-body {
    display: none !important;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-row {
    border-bottom: 1px solid color-mix(in srgb, var(--zerti-docs-border) 40%, transparent);
    cursor: pointer;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-row.zerti-reviews-grid-row--active {
    background: color-mix(in srgb, var(--zerti-bs-purple) 18%, transparent);
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-header-cell-label {
    justify-content: center;
    width: 100%;
    font-weight: 700;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-header-cell-text {
    font-size: 9pt;
    font-weight: 700;
    line-height: 1.35;
    text-align: center;
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-cell {
    font-weight: 400;
    font-size: 9pt;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .zerti-reviews-grid-cell {
    justify-content: center;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .ag-cell-value {
    width: 100%;
    text-align: center;
}

#zertiAdmin .zerti-component-inventory-comments .zerti-reviews-grid .badge {
    font-weight: 400;
    font-size: 9pt;
    padding: 0.42em 0.72em;
    line-height: 1.2;
}

#zertiAdmin .zerti-inv-reviews__editor--collapsed .zerti-inv-reviews__editor-body {
    display: none !important;
}

#zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__editor--collapsed .zerti-inv-categories__editor-body {
    display: none !important;
}

@media (min-width: 992px) {
    /*
     * Taxonomy shell: flex column — toolbar auto, __layout fills remainder.
     * List card stretches; editor card height follows its content.
     */
    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories {
        display: flex;
        flex-direction: column;
        flex: 1 1 0;
        min-height: 0;
        max-height: 100%;
        gap: 0.75rem;
        overflow: hidden;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__layout,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__layout,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__layout,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__layout,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__layout {
        flex: 1 1 0;
        min-height: 0;
        overflow-x: hidden;
        overflow-y: hidden;
        align-items: stretch;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__tree-panel {
        flex: 3 1 0;
        align-self: stretch;
        min-height: 0;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__editor,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__editor,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__editor,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__editor,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__editor {
        flex: 2 1 0;
        align-self: flex-start;
        height: auto;
        min-height: 0;
        max-height: 100%;
        overflow: visible;
        display: flex;
        flex-direction: column;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__tree-panel.card > .card-body {
        flex: 1 1 0;
        min-height: 0;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__tree-scroll {
        flex: 1 1 0;
        min-height: 0;
        overflow-x: hidden;
        overflow-y: auto;
        direction: inherit;
        unicode-bidi: isolate;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll-inner,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll-inner,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll-inner,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll-inner,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__tree-scroll-inner {
        min-height: 0;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar {
        width: var(--zerti-scrollbar-size, 1px);
        display: block;
        background: transparent;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb {
        background-color: color-mix(in srgb, var(--zerti-docs-muted) 50%, var(--zerti-docs-border));
        border-radius: 999px;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb:hover {
        background-color: color-mix(in srgb, var(--zerti-bs-purple) 42%, var(--zerti-docs-muted));
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar-track {
        background: transparent;
    }
}

@media (max-width: 991.98px) {
    /* Categories/tags/brands/attributes list card: internal scroll on tablet/mobile; bar on physical left. */
    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__layout,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__layout,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__layout,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__layout,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__layout {
        overflow-x: hidden;
        overflow-y: auto;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-panel,
    #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__tree-panel {
        overflow: hidden;
        display: flex;
        flex-direction: column;
        flex: 0 0 auto;
        min-height: clamp(10rem, 28vh, 16rem);
        max-height: clamp(14rem, 42vh, 26rem);
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-panel.card > .card-body {
        flex: 1 1 0;
        min-height: 0;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll {
        flex: 1 1 0;
        min-height: 0;
        overflow-x: hidden;
        overflow-y: auto;
        direction: inherit;
        unicode-bidi: isolate;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        scrollbar-color: color-mix(in srgb, var(--zerti-docs-muted) 50%, var(--zerti-docs-border)) transparent;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar {
        width: var(--zerti-scrollbar-size, 1px);
        display: block;
        background: transparent;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb {
        background-color: color-mix(in srgb, var(--zerti-docs-muted) 50%, var(--zerti-docs-border));
        border-radius: 999px;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb:hover,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb:hover {
        background-color: color-mix(in srgb, var(--zerti-bs-purple) 42%, var(--zerti-docs-muted));
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-track,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar-track {
        background: transparent;
    }
}

#zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__editor--collapsed .zerti-inv-categories__editor-body {
    display: none !important;
}

#zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__editor--collapsed .zerti-inv-categories__editor-body {
    display: none !important;
}

#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor--collapsed .zerti-inv-categories__editor-body {
    display: none !important;
}


#zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor-scroll-inner > .card-body {
    padding-top: 5px !important;
}

#zertiAdmin .zerti-inv-attribute-groups-picklist {
    max-height: 16rem;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

/* Attribute groups — scroll without visible scrollbars (matches global ZERTI chrome). */
#zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__layout,
#zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__tree-scroll,
#zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__editor-scroll,
#zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-attribute-groups-picklist {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__layout::-webkit-scrollbar,
body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attribute-groups .zerti-inv-categories__editor-scroll::-webkit-scrollbar,
body.toplevel_page_zerti-admin #zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-attribute-groups-picklist::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
    background: transparent;
}

#zertiAdmin .zerti-inv-attribute-groups-picklist__item {
    padding: 0.2rem 0.35rem;
    border-radius: 6px;
}

#zertiAdmin .zerti-inv-attribute-groups-picklist__item:hover {
    background: color-mix(in srgb, var(--zerti-docs-text) 6%, transparent);
}

#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__terms-list .list-group-item.active {
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border);
}

#zertiAdmin .zerti-inv-categories__term-search-input {
    min-width: min(100%, 10rem);
    text-align: center;
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border);
}

#zertiAdmin .zerti-inv-categories__term-search-input::placeholder {
    color: var(--zerti-docs-muted);
    opacity: 1;
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__term-search-input {
    color: var(--zerti-docs-text);
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border);
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories__term-search-input::placeholder {
    color: var(--zerti-docs-muted);
    opacity: 1;
}

/* Inventory — attributes editor: compact Zerti form */
#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__form,
#zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__form {
    display: flex;
    flex-direction: column;
    flex: 0 0 auto;
    font-size: 9pt;
}

#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-body,
#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll,
#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll-inner,
#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .card-body,
#zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-body,
#zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll,
#zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll-inner,
#zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .card-body {
    display: block;
    flex: 0 0 auto;
    height: auto;
    min-height: 0;
    max-height: none;
    overflow: visible;
}

/* Desktop: editor column height follows form; cap at layout and scroll when long. */
@media (min-width: 992px) {
    #zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed),
    #zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed),
    #zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor.zerti-inv-categories__editor--collapsed,
    #zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor.zerti-inv-categories__editor--collapsed {
        align-self: flex-start;
        height: auto;
        max-height: 100%;
        min-height: 0;
        overflow: hidden;
    }

    #zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-body,
    #zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-body {
        display: flex;
        flex-direction: column;
        flex: 0 0 auto;
        min-height: 0;
        max-height: none;
        overflow: visible;
    }

    #zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll,
    #zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll {
        flex: 0 0 auto;
        height: auto;
        overflow: visible;
    }

    #zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll-inner,
    #zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .card-body,
    #zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .zerti-inv-categories__editor-scroll-inner,
    #zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__editor:not(.zerti-inv-categories__editor--collapsed) .card-body {
        flex: 0 0 auto;
    }
}

#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__form-footer,
#zertiAdmin .zerti-inv-categories--attribute-groups .zerti-inv-categories__form-footer {
    flex-shrink: 0;
}

#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__terms-panel {
    flex-shrink: 0;
}

#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__term-form {
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border) !important;
}

#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__term-form-title {
    font-size: 9pt;
    color: var(--zerti-docs-text);
}

#zertiAdmin .zerti-inv-categories--attributes .zerti-inv-categories__terms-panel > h6 {
    font-size: 9pt;
    color: var(--zerti-docs-text);
}

#zertiAdmin[data-bs-theme='dark'] .zerti-inv-categories--attributes .zerti-inv-categories__term-form {
    background-color: var(--zerti-docs-subtle-bg);
    border-color: var(--zerti-docs-border) !important;
}

/* Trailing mobile: categories/tags/brands/attributes list scroll inside card (wins cascade). */
@media (max-width: 991.98px) {
    #zertiAdmin .zerti-main-content .zerti-component-inventory-categories .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-main-content .zerti-component-inventory-tags .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-main-content .zerti-component-inventory-brands .zerti-inv-categories__tree-panel.card > .card-body,
    #zertiAdmin .zerti-main-content .zerti-component-inventory-attributes .zerti-inv-categories__tree-panel.card > .card-body {
        flex: 1 1 0;
        min-height: 0;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }

    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin,
    #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin,
    #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin,
    #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin,
    #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll {
        flex: 1 1 0;
        min-height: 0;
        overflow-x: hidden;
        overflow-y: auto;
        direction: inherit;
        unicode-bidi: isolate;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        scrollbar-color: color-mix(in srgb, var(--zerti-docs-muted) 50%, var(--zerti-docs-border)) transparent;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-brands .zerti-inv-categories__tree-scroll::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-attributes .zerti-inv-categories__tree-scroll::-webkit-scrollbar {
        width: var(--zerti-scrollbar-size, 1px);
        display: block;
        background: transparent;
    }

    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-categories .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll.zerti-scrollbar-thin::-webkit-scrollbar-thumb,
    body.toplevel_page_zerti-admin #zertiAdmin .zerti-component-inventory-tags .zerti-inv-categories__tree-scroll::-webkit-scrollbar-thumb,
