﻿/* tag-pill.css — unified pill/badge component and PillsRenderer */

/* ── PillsRenderer ──────────────────────────────────────────────── */

.pr-wrapper {
    position: relative;
    display: flex;
    width: 100%;
    align-items: flex-start;
    min-height: 22px;
}

.pr-wrapper.pr-editable {
    padding-right: 20px;
}

.pr-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
}

.pr-pill {
    display: inline-flex;
    align-items: center;
    font-size: 10px;
    padding: 2px 6px 2px 4px;
    border-radius: 2px;
    white-space: nowrap;
    cursor: default;
}

.pr-pill-icon {
    font-size: 11px;
    margin-right: 3px;
    line-height: 1;
}

/* IconOnly mode — transparent pill, icon fills the full height, no margin */
.pr-pill.pr-icon-only {
    background: transparent !important;
    border: none !important;
    padding: 0;
}

.pr-pill.pr-icon-only .pr-pill-icon {
    font-size: 16px;
    width: 16px;
    height: 16px;
    margin: 0;
    line-height: 16px;
    text-align: center;
}

.pr-label {
    font-weight: 600;
    letter-spacing: 0.2px;
}

/* Edit button - floats top-right, visible only on row hover */
.pr-edit-btn {
    position: absolute;
    top: 0;
    right: 0;
    opacity: 0;
    transition: opacity 0.12s ease;
    cursor: pointer;
}

.pr-edit-btn.dxbl-btn {
    border-color: transparent;
}

.pr-edit-btn.dxbl-btn:hover {
    border-color: revert;
}

/* Show on wrapper hover */
.pr-wrapper.pr-editable:hover .pr-edit-btn {
    opacity: 1;
}

/* Always visible (detail view) */
.pr-wrapper.pr-btn-always .pr-edit-btn {
    opacity: 1;
}

/* Inline variant — sits in flow after the last pill, not absolutely positioned */
.pr-edit-btn-inline {
    position: static;
    opacity: 1;
    flex-shrink: 0;
    align-self: center;
}

.pr-edit-btn-inline.dxbl-btn {
    border-color: transparent;
}

.pr-edit-btn-inline.dxbl-btn:hover {
    border-color: revert;
}



/* ── DxIconPicker ────────────────────────────────────────────────── */

.dxip-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dxip-item i,
.dxip-selected i {
    font-size: 14px;
    width: 16px;
    text-align: center;
    flex-shrink: 0;
}

.dxip-selected {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 4px;
}

.dxip-null {
    padding: 0 4px;
    color: var(--bs-secondary-color, #6c757d);
}

/* ── TagFilterMenuComponent ─────────────────────────────────────── */

.tf-menu {
    padding: 8px;
    min-width: 180px;
    max-width: 300px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tf-empty {
    font-size: 11px;
    color: #888;
}

.tf-list {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.tf-row {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    user-select: none;
    padding: 2px 4px;
    border-radius: 3px;
}

.tf-row:hover {
    background: #f0f0f0;
}

.tf-checkbox {
    cursor: pointer;
    flex-shrink: 0;
}

.tf-mode-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.tf-mode-label {
    font-size: 11px;
    color: #888;
}

.tf-mode-toggle {
    display: flex;
    border: 1px solid #ccc;
    border-radius: 3px;
    overflow: hidden;
}

.tf-mode-btn {
    font-size: 10px;
    font-weight: 700;
    padding: 2px 8px;
    cursor: pointer;
    background: #f5f5f5;
    color: #888;
    border: none;
    letter-spacing: 0.5px;
}

.tf-mode-btn.tf-mode-active {
    background: #0078d4;
    color: #fff;
}

.tf-clear-row {
    border-top: 1px solid #eee;
    padding-top: 6px;
}

.tf-clear-link {
    font-size: 11px;
    color: #0078d4;
    cursor: pointer;
}

.tf-clear-link:hover {
    text-decoration: underline;
}

/* ── tag-pill (legacy) ──────────────────────────────────────────── */

.tag-pill {
    display: inline-flex;
    align-items: stretch;
    border-radius: 4px;
    overflow: hidden;
    font-size: inherit;
    font-weight: 600;
    letter-spacing: 0.03em;
    white-space: nowrap;
    line-height: 1;
    border: 1px solid color-mix(in srgb, var(--tp-color) 40%, white);
    font-family: inherit;
}

.tag-pill-sm {
    font-size: 10px;
}

.tp-left {
    display: flex;
    align-items: center;
    padding: 3px 8px;
    background: color-mix(in srgb, var(--tp-color) 10%, white);
    color: var(--tp-color);
}

.tp-slot {
    display: flex;
    align-items: center;
    padding: 3px 8px;
    background: transparent;
    border-left: 1px solid color-mix(in srgb, var(--tp-color) 40%, white);
    font-weight: 600;
}

.tag-pill-sm .tp-left,
.tag-pill-sm .tp-slot {
    padding: 1px 5px;
}
