/* PF List Plus — toolbar, cards, highlight, cursor, inline edit */

.pf-lp-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.pf-lp-sel-count {
    font-size: 12px;
}

.pf-lp-bar {
    position: relative;
}

.pf-lp-dot {
    color: #efab48;
    font-size: 9px;
    vertical-align: middle;
}

.pf-lp-columns-panel {
    position: absolute;
    top: 100%;
    left: 90px;
    z-index: 200;
    margin-top: 4px;
    width: 300px;
    background: #fff;
    border: 1px solid #d5dbe1;
    border-radius: 6px;
    box-shadow: 0 6px 20px rgba(20, 30, 40, 0.18);
    padding: 8px;
}

.pf-lp-columns-list {
    max-height: 320px;
    overflow-y: auto;
    margin-bottom: 8px;
}

.pf-lp-columns-row {
    display: block;
    font-weight: normal;
    margin: 0;
    padding: 3px 6px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12.5px;
}

.pf-lp-columns-row:hover {
    background: #f2f5f8;
}

.pf-lp-columns-actions {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    border-top: 1px solid #eceff2;
    padding-top: 8px;
}

.pf-lp-hint {
    font-size: 11px;
    margin-left: auto;
}

/* ------------------------------------------------ cards */

.pf-lp-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 12px;
    margin-top: 4px;
}

.pf-lp-card {
    position: relative;
    background: #fff;
    border: 1px solid #e3e7eb;
    border-left-width: 4px;
    border-radius: 6px;
    padding: 10px 12px 10px 14px;
    box-shadow: 0 1px 3px rgba(20, 30, 40, 0.06);
    transition: box-shadow 0.12s ease, transform 0.12s ease;
    outline: none;
}

.pf-lp-cards[data-pf-style="priority"] .pf-lp-card:hover {
    box-shadow: 0 3px 10px rgba(20, 30, 40, 0.13);
    transform: translateY(-1px);
}

.pf-lp-accent-success { border-left-color: #7cb342; }
.pf-lp-accent-danger  { border-left-color: #e05353; }
.pf-lp-accent-warning { border-left-color: #efab48; }
.pf-lp-accent-primary { border-left-color: #4d8fce; }
.pf-lp-accent-info    { border-left-color: #55b5c8; }
.pf-lp-accent-default { border-left-color: #b8c2cc; }

.pf-lp-card-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 6px;
}

.pf-lp-card-title {
    font-weight: 600;
    font-size: 13.5px;
}

.pf-lp-card-badges {
    display: flex;
    gap: 4px;
    flex-shrink: 0;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.pf-lp-badge {
    display: inline-block;
    font-size: 10.5px;
    font-weight: 600;
    line-height: 1;
    padding: 4px 7px;
    border-radius: 9px;
    background: #eef1f4;
    color: #4a5560;
    white-space: nowrap;
}

.pf-lp-badge-success { background: #e5f2d9; color: #4a7427; }
.pf-lp-badge-danger  { background: #fbe3e3; color: #a03030; }
.pf-lp-badge-warning { background: #fcefd9; color: #96660f; }
.pf-lp-badge-primary { background: #e0ecf7; color: #2b5f92; }
.pf-lp-badge-update  { background: #fcefd9; color: #d88a12; font-size: 12px; padding: 2px 6px; }

.pf-lp-card-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3px 14px;
}

.pf-lp-card-row {
    min-width: 0;
    padding: 1px 2px;
    border-radius: 3px;
}

.pf-lp-card-label {
    display: block;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #93a1ae;
}

.pf-lp-card-value {
    display: block;
    font-size: 12.5px;
    color: #2d3540;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pf-lp-empty {
    padding: 24px;
    text-align: center;
}

/* ------------------------------------------------ column resize */

th.pf-lp-resizable {
    position: relative;
}

.pf-lp-resize {
    position: absolute;
    top: 0;
    right: -3px;
    width: 7px;
    height: 100%;
    cursor: col-resize;
    z-index: 5;
}

.pf-lp-resize:hover,
body.pf-lp-resizing .pf-lp-resize {
    background: linear-gradient(to right, transparent 2px, #9dc3e6 2px, #9dc3e6 4px, transparent 4px);
}

body.pf-lp-resizing {
    cursor: col-resize;
    user-select: none;
    -webkit-user-select: none;
}

/* ------------------------------------------------ highlight (updates) */

tr.pf-lp-highlight > td:first-child {
    box-shadow: inset 3px 0 0 #efab48;
}

tr.pf-lp-highlight,
.pf-lp-card.pf-lp-highlight {
    background-color: #fffaf0;
}

/* ------------------------------------------------ keyboard cursor */

tr.pf-lp-cursor > td {
    background-color: #eef4fb !important;
}

.pf-lp-card.pf-lp-cursor {
    box-shadow: 0 0 0 2px #4d8fce;
}

/* ------------------------------------------------ inline edit */

.pf-lp-editing {
    background: #f4f8fd;
    outline: 2px solid #9dc3e6;
    outline-offset: -2px;
}

/* The editor lives inside a table cell: without a raised stacking context
   the FOLLOWING rows paint on top of its dropdown, which both hides it and
   swallows its clicks. Lift the editing row/cell and unclip overflow. */
td.pf-lp-editing,
.pf-lp-card-row.pf-lp-editing {
    position: relative;
    z-index: 60;
    overflow: visible !important;
    min-width: 180px;
}

tr.pf-lp-editing-row {
    position: relative;
    z-index: 60;
}

.pf-lp-card.pf-lp-editing-row {
    z-index: 60;
    overflow: visible;
}

/* While an edit is open the list container must not clip a dropdown that
   extends past the last row. */
.pf-lp-edit-open {
    overflow: visible !important;
}

/* Selectize / bootstrap panels inside the editor stay on top. */
.pf-lp-editing .selectize-dropdown,
.pf-lp-editing .dropdown-menu,
.pf-lp-editing .ui-datepicker,
.pf-lp-editing .datepicker {
    z-index: 1060;
}

.pf-lp-card-row.pf-lp-editing .pf-lp-card-label {
    display: none;
}

/* ------------------------------------------------ card flags footer */

.pf-lp-card-flags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 8px;
    padding-top: 7px;
    border-top: 1px dashed #e6eaee;
}

.pf-lp-flag {
    display: inline-block;
    font-size: 10px;
    font-weight: 600;
    line-height: 1;
    padding: 3px 7px;
    border-radius: 3px;
    border: 1px solid transparent;
    white-space: nowrap;
}

.pf-lp-flag-default { background: #f0f3f6; color: #51606e; border-color: #dde3e9; }
.pf-lp-flag-success { background: #e5f2d9; color: #4a7427; border-color: #cfe6b8; }
.pf-lp-flag-danger  { background: #fbe3e3; color: #a03030; border-color: #f3c6c6; }
.pf-lp-flag-warning { background: #fcefd9; color: #96660f; border-color: #f5ddb0; }
.pf-lp-flag-primary { background: #e0ecf7; color: #2b5f92; border-color: #c4dbf0; }
.pf-lp-flag-info    { background: #e0f2f5; color: #22707e; border-color: #bfe2e8; }

/* ------------------------------------------------ status value coloring */

.pf-lp-value-success { color: #4a7427 !important; font-weight: 600; }
.pf-lp-value-danger  { color: #a03030 !important; font-weight: 600; }
.pf-lp-value-warning { color: #96660f !important; font-weight: 600; }
.pf-lp-value-primary { color: #2b5f92 !important; font-weight: 600; }
.pf-lp-value-info    { color: #22707e !important; font-weight: 600; }
.pf-lp-value-default { font-weight: 600; }

/* ------------------------------------------------ column drag-reorder */

body.pf-lp-reordering {
    cursor: grabbing;
    user-select: none;
    -webkit-user-select: none;
}

th.pf-lp-drag-src {
    opacity: 0.45;
}

th.pf-lp-drop-target {
    box-shadow: inset 3px 0 0 #4d8fce;
}

th.pf-lp-drop-after {
    box-shadow: inset -3px 0 0 #4d8fce;
}
