/* Project Center named layouts: picker, Save / Rename and Manage dialogs. Colours come from the theme variables, so both themes pass. */
.pcl-picker { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ms-text); }
.pcl-picker-label { font-weight: 600; }
.pcl-select { height: 28px; min-width: 160px; max-width: 280px; border: 1px solid var(--ms-border-dark); border-radius: 2px; padding: 0 6px; font-size: 12.5px; background: var(--ms-surface); color: var(--ms-text); }

.pcl-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, .4); z-index: 500; display: flex; align-items: center; justify-content: center; }
/* Save opens over Manage when a row is renamed. */
#pcLayoutSaveModal { z-index: 510; }
.pcl-dialog { background: var(--ms-surface); color: var(--ms-text); border-radius: 4px; width: 720px; max-width: 96vw; max-height: 90vh; display: flex; flex-direction: column; box-shadow: 0 8px 32px rgba(0, 0, 0, .22); font-size: 12.5px; }
.pcl-dialog-narrow { width: 440px; }
.pcl-dialog:focus { outline: none; }
.pcl-form { display: flex; flex-direction: column; min-height: 0; }
.pcl-title { margin: 0; padding: 15px 20px 10px; font-size: 15px; font-weight: 700; border-bottom: 1px solid var(--ms-border); }
.pcl-body { padding: 14px 20px; display: flex; flex-direction: column; gap: 10px; overflow: auto; min-height: 0; }
.pcl-note { margin: 0; color: var(--ms-text-sec); }
.pcl-field { display: flex; flex-direction: column; gap: 4px; }
.pcl-label { font-weight: 600; }
.pcl-req { font-weight: 400; color: var(--ms-text-sec); }
.pcl-input { width: 100%; height: 32px; border: 1px solid var(--ms-border-dark); border-radius: 2px; font-size: 13px; padding: 0 10px; background: var(--ms-surface); color: var(--ms-text); }
.pcl-input[aria-invalid="true"] { border-color: var(--ms-error); box-shadow: 0 0 0 1px var(--ms-error); }
.pcl-field-error, .pcl-error { margin: 0; color: var(--ms-error); font-weight: 600; }
.pcl-checks { display: flex; flex-direction: column; gap: 6px; }
.pcl-check { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.pcl-check input:disabled + span { color: var(--ms-text-sec); }
.pcl-hint { margin: 0; color: var(--ms-text-sec); font-style: italic; }
.pcl-footer { padding: 12px 20px; border-top: 1px solid var(--ms-border); display: flex; gap: 8px; justify-content: flex-end; }

.pcl-table-wrap { max-height: 56vh; overflow: auto; border: 1px solid var(--ms-border); border-radius: 2px; }
.pcl-table { width: 100%; border-collapse: collapse; }
.pcl-table th, .pcl-table td { padding: 6px 8px; text-align: left; vertical-align: middle; border-bottom: 1px solid var(--ms-border); }
.pcl-table thead th { position: sticky; top: 0; background: var(--ms-surface); color: var(--ms-text-sec); font-weight: 700; z-index: 1; }
.pcl-table tbody th { font-weight: 600; overflow-wrap: anywhere; }
.pcl-table tbody tr:hover { background: var(--ms-row-hover); }
.pcl-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.pcl-act { white-space: nowrap; }
.pcl-danger { border-color: var(--ms-error); color: var(--ms-error); }
.pcl-confirm-text { font-weight: 600; overflow-wrap: anywhere; }
.pcl-muted { color: var(--ms-text-sec); }
.pcl-empty { margin: 10px 0; color: var(--ms-text-sec); }

/* Layouts side panel: switch, save as, reset, and the saved layouts as a list (a table does not fit 340px). */
.pcl-panel { font-size: 12.5px; color: var(--ms-text); }
.pcl-panel-body { display: flex; flex-direction: column; gap: 10px; }
.pcl-panel .pcl-picker { display: flex; flex-direction: column; align-items: stretch; gap: 4px; }
.pcl-panel .pcl-select { max-width: none; width: 100%; }
.pcl-panel .rb-btn { border-color: var(--ms-border-dark); }
.pcl-panel .rb-btn.pcl-danger { border-color: var(--ms-error); }
.pcl-subtitle { margin: 6px 0 0; font-size: 13px; font-weight: 700; padding-top: 10px; border-top: 1px solid var(--ms-border); }
.pcl-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pcl-item { border: 1px solid var(--ms-border); border-radius: 4px; padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.pcl-item-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.pcl-item-name { font-weight: 600; overflow-wrap: anywhere; }
.pcl-tag { font-size: 11px; padding: 1px 6px; border-radius: 10px; background: var(--ms-gray-bg); color: var(--ms-text); }

@media (forced-colors: active) {
  .pcl-input[aria-invalid="true"], .pcl-danger { border-color: Mark; }
}
