/* The playable ads pages (/playables and /playables/{game}): the list of games, the manifest-driven settings form,
   and the phone preview beside it. Theme colours come from MudBlazor's variables, so both themes work. */

/* ------------------------------------------------------------------ the list */

.pl-games { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 520px), 1fr)); gap: 16px; }
.pl-game { display: flex; overflow: hidden; border-radius: var(--mud-default-borderradius); }
.pl-game-art {
    flex: 0 0 132px;
    display: flex;
    align-items: center;
    justify-content: center;
    /* The playable's own sky blue, as a picture of the game rather than a theme colour. */
    background: radial-gradient(circle at 30% 20%, #9fe3f6 0%, #64cbe9 45%, #2e8fd8 100%);
}
.pl-game-art-icon { width: 64px !important; height: 64px !important; color: #fff; filter: drop-shadow(0 4px 10px rgba(10, 40, 80, 0.35)); }
.pl-game-body { flex: 1 1 auto; min-width: 0; padding: 16px 20px; display: flex; flex-direction: column; gap: 12px; }
.pl-game-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.pl-game-head .mud-chip { margin: 0; }
.pl-game-facts { grid-template-columns: minmax(96px, max-content) 1fr; }
.pl-game-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
@media (max-width: 600px) {
    .pl-game { flex-direction: column; }
    .pl-game-art { flex-basis: 96px; }
}

/* ------------------------------------------------------------------ the editor: page layout */

.pl-subtitle { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: 0.875rem; }
.pl-subtitle .mud-chip { margin: 0; }

/* The form scrolls on the left; the preview stays in view on the right, from the top of the page down. On a
   narrow window the preview sits between the page's title and the form. */
.pl-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) clamp(340px, 30vw, 440px);
    grid-template-areas: "head preview" "form preview";
    grid-template-rows: auto 1fr;
    column-gap: 24px;
    align-items: start;
}
.pl-head { grid-area: head; min-width: 0; }
.pl-form { grid-area: form; min-width: 0; }
.pl-preview-column { grid-area: preview; position: sticky; top: 64px; min-width: 0; }
.pl-head .admin-page-header { margin-bottom: 16px; }
@media (max-width: 1180px) {
    .pl-layout { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "preview" "form"; grid-template-rows: auto; }
    .pl-preview-column { position: static; margin-bottom: 20px; }
}

.pl-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 20px;
    margin-bottom: 12px;
}
.pl-search { flex: 1 1 260px; max-width: 440px; }
.pl-search.mud-input-control, .pl-search .mud-input-control { margin-top: 0 !important; }
.pl-search .mud-input.mud-input-outlined { background: var(--mud-palette-surface); }
.pl-changed-only { margin: 0 !important; }
.pl-counts { display: inline-flex; align-items: center; font-size: 0.8125rem; color: var(--mud-palette-text-secondary); white-space: nowrap; }
.pl-counts-gap { display: inline-block; width: 14px; }

.pl-errors .admin-list { margin-top: 6px; }
.pl-link {
    border: 0;
    padding: 0;
    background: none;
    font: inherit;
    color: inherit;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
    cursor: pointer;
}

/* ------------------------------------------------------------------ sections */

/* Each section is its own card: they read as a list down the tab. */
.pl-sections.mud-expansion-panels { display: flex; flex-direction: column; gap: 10px; background: transparent; border: 0 !important; box-shadow: none; }
.pl-sections .mud-expand-panel.pl-section {
    border: 1px solid var(--mud-palette-lines-default) !important;
    border-radius: var(--mud-default-borderradius) !important;
    margin: 0 !important;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.pl-sections .mud-expand-panel.pl-section.mud-panel-expanded { border-color: rgba(var(--mud-palette-primary-rgb), 0.45) !important; box-shadow: 0 6px 22px rgba(var(--mud-palette-primary-rgb), 0.08); }
.pl-sections .mud-expand-panel .mud-expand-panel-header.pl-section-head { padding: 12px 18px; min-height: 56px; }
.pl-sections .mud-expand-panel-content { padding: 0 18px 12px !important; }

.pl-section-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; min-width: 0; }
.pl-section-words { display: flex; flex-direction: column; gap: 3px; flex: 1 1 220px; min-width: 0; }
.pl-section-label { font-weight: 700; font-size: 0.975rem; line-height: 1.25; }
.pl-section-hint { font-size: 0.8125rem; color: var(--mud-palette-text-secondary); line-height: 1.35; }
.pl-section-count {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 2px 9px;
    border-radius: 999px;
    color: var(--mud-palette-primary);
    background: rgba(var(--mud-palette-primary-rgb), 0.1);
    white-space: nowrap;
}
.pl-section-count-unsaved { color: #8a5a00; background: rgba(224, 154, 26, 0.16); }
.mud-theme-dark .pl-section-count-unsaved, .mud-dark .pl-section-count-unsaved { color: var(--mud-palette-warning); }
.pl-section-screen {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 0.75rem;
    color: var(--mud-palette-text-secondary);
    white-space: nowrap;
    margin-right: 6px;
}
.pl-section-screen .mud-icon-root { font-size: 1rem; }
.pl-section-foot { display: flex; justify-content: flex-end; padding-top: 6px; border-top: 1px dashed var(--mud-palette-lines-default); margin-top: 4px; }

/* Search results: the same sections, laid flat, each under where it lives. */
.pl-section-flat { padding: 12px 18px 10px; margin-bottom: 10px; border-radius: var(--mud-default-borderradius); }
.pl-section-flat-head { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 0.9rem; padding-bottom: 6px; }

/* ------------------------------------------------------------------ fields */

.pl-fields { display: flex; flex-direction: column; }
.pl-field {
    display: grid;
    grid-template-columns: minmax(130px, 190px) minmax(0, 1fr) 36px;
    align-items: start;
    gap: 6px 14px;
    padding: 12px 0;
    border-top: 1px solid var(--mud-palette-table-lines);
    scroll-margin-top: 96px;
}
.pl-field:first-child { border-top: 0; }
.pl-field-label { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-height: 40px; font-weight: 600; font-size: 0.875rem; line-height: 1.3; }
.pl-field-label label { cursor: default; }
.pl-field-editor { min-width: 0; display: flex; flex-direction: column; justify-content: center; min-height: 40px; }
.pl-field-reset { display: flex; align-items: center; justify-content: center; min-height: 40px; }
.pl-field-hint { font-size: 0.75rem; color: var(--mud-palette-text-secondary); margin-top: 4px; line-height: 1.4; }
.pl-field-problem { font-size: 0.8125rem; color: var(--mud-palette-error); margin-top: 4px; font-weight: 600; }
.pl-field-has-error { background: linear-gradient(90deg, rgba(214, 69, 69, 0.07), transparent 70%); border-radius: 8px; padding-left: 8px; padding-right: 4px; }
/* MudBlazor's dense outlined inputs keep a top margin for a label these fields do not use. */
.pl-field-editor .mud-input-control { margin-top: 0 !important; margin-bottom: 0 !important; }
@media (max-width: 640px) {
    .pl-field { grid-template-columns: minmax(0, 1fr) 36px; }
    .pl-field-label { grid-column: 1; min-height: 0; }
    .pl-field-reset { grid-column: 2; grid-row: 1; min-height: 0; }
    .pl-field-editor { grid-column: 1 / -1; }
}

/* The dot before a label: hollow = default, filled = changed from the default, amber = changed and not saved. */
.pl-dot {
    display: inline-block;
    flex: none;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    margin-right: 6px;
    vertical-align: middle;
    box-sizing: border-box;
}
.pl-dot-default { border: 1.5px solid var(--mud-palette-lines-inputs); }
.pl-dot-custom { background: var(--mud-palette-primary); }
.pl-dot-unsaved { background: var(--mud-palette-warning); box-shadow: 0 0 0 3px rgba(224, 154, 26, 0.22); }
.pl-tag {
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 1px 6px;
    border-radius: 6px;
    color: var(--mud-palette-info);
    background: rgba(45, 127, 249, 0.1);
}

.pl-number { display: flex; align-items: center; gap: 16px; }
.pl-slider { flex: 1 1 auto; min-width: 100px; }
.pl-number-box { flex: 0 0 128px; max-width: 128px; }
.pl-number-box .mud-input-adornment-text { color: var(--mud-palette-text-secondary); font-weight: 600; }

.pl-color { display: flex; align-items: center; gap: 10px; }
.pl-color-input { flex: 0 1 220px; max-width: 220px; }
.pl-swatch {
    flex: none;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid rgba(0, 0, 0, 0.18);
    /* The colour over a light and a dark square, so a see-through colour shows it is. */
    background:
        linear-gradient(var(--pl-swatch, transparent), var(--pl-swatch, transparent)),
        repeating-conic-gradient(rgba(127, 127, 140, 0.35) 0% 25%, #fff 0% 50%) 50% / 10px 10px;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.35);
}
.pl-swatch-sm { width: 14px; height: 14px; border-radius: 4px; display: inline-block; vertical-align: -2px; margin-right: 6px; box-shadow: none; }
.pl-swatch-none {
    background:
        linear-gradient(135deg, transparent 46%, var(--mud-palette-error) 46% 54%, transparent 54%),
        repeating-conic-gradient(rgba(127, 127, 140, 0.2) 0% 25%, transparent 0% 50%) 50% / 10px 10px;
}
.pl-color-words { font-size: 0.875rem; color: var(--mud-palette-text-secondary); }

.pl-toggles { width: fit-content; max-width: 100%; }
.pl-toggles .mud-toggle-item { text-transform: none; font-weight: 600; padding-inline: 14px; }
.pl-switch { margin: 0 !important; }

.pl-image { display: flex; align-items: flex-start; gap: 14px; }
.pl-image-thumb {
    flex: none;
    width: 76px;
    height: 76px;
    border-radius: 12px;
    border: 1px solid var(--mud-palette-lines-default);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: repeating-conic-gradient(rgba(127, 127, 140, 0.16) 0% 25%, transparent 0% 50%) 50% / 12px 12px;
}
.pl-image-thumb img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.pl-image-info { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pl-image-name { font-weight: 600; font-size: 0.875rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-image-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.pl-image-actions .mud-file-upload { width: auto; margin: 0; flex: none; }
.pl-pictures { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.pl-pictures .admin-store-pick:disabled { opacity: 0.55; cursor: not-allowed; }

.pl-unknown { display: flex; align-items: flex-start; gap: 6px; font-size: 0.8125rem; color: var(--mud-palette-text-secondary); }

/* ------------------------------------------------------------------ changes list (save dialog, history) */

.pl-changes { display: flex; flex-direction: column; gap: 10px; max-height: 320px; overflow-y: auto; padding-right: 4px; }
.pl-changes-where { font-size: 0.75rem; font-weight: 700; color: var(--mud-palette-text-secondary); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 2px; }
.pl-change { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 10px; padding: 4px 0; font-size: 0.875rem; border-bottom: 1px solid var(--mud-palette-table-lines); }
.pl-change-label { font-weight: 600; flex: 0 0 150px; }
.pl-change-values { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; min-width: 0; }
.pl-change-old { color: var(--mud-palette-text-secondary); text-decoration: line-through; text-decoration-color: rgba(127, 127, 140, 0.6); overflow-wrap: anywhere; }
.pl-change-new { font-weight: 600; overflow-wrap: anywhere; }
.pl-change-arrow { color: var(--mud-palette-text-secondary); }

/* ------------------------------------------------------------------ the phone preview */

.pv-card {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 88px);
    min-height: 560px;
    padding: 12px 14px 14px;
    border-radius: var(--mud-default-borderradius);
}
@media (max-width: 1180px) { .pv-card { height: 760px; min-height: 0; } }
@media (max-width: 600px) { .pv-card { height: 640px; } }

.pv-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.pv-title { min-width: 0; }
.pv-heading { font-weight: 700 !important; line-height: 1.2 !important; }
.pv-status { display: flex; align-items: center; font-size: 0.75rem; color: var(--mud-palette-text-secondary); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pv-tools { display: flex; align-items: center; gap: 2px; flex: none; }
.pv-divider { width: 1px; height: 20px; background: var(--mud-palette-lines-default); margin: 0 4px; }

.pv-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; flex: none; }
.pv-dot-on { background: var(--mud-palette-success); box-shadow: 0 0 0 3px rgba(46, 158, 91, 0.18); }
.pv-dot-busy { background: var(--mud-palette-warning); animation: pv-pulse 1s ease-in-out infinite; }
.pv-dot-off { background: var(--mud-palette-error); }
@keyframes pv-pulse { 50% { opacity: 0.35; } }

.pv-screens {
    display: flex;
    gap: 2px;
    padding: 3px;
    margin: 10px 0;
    border-radius: 999px;
    background: var(--mud-palette-background-gray);
    border: 1px solid var(--mud-palette-lines-default);
    overflow-x: auto;
    scrollbar-width: none;
}
.pv-screen {
    flex: 1 0 auto;
    border: 0;
    background: transparent;
    padding: 5px 10px;
    border-radius: 999px;
    font: inherit;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
    cursor: pointer;
    white-space: nowrap;
    transition: background-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}
.pv-screen:hover:not(:disabled) { color: var(--mud-palette-text-primary); }
.pv-screen:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: 1px; }
.pv-screen:disabled { cursor: default; opacity: 0.55; }
.pv-screen-on { background: var(--mud-palette-surface); color: var(--mud-palette-primary); box-shadow: 0 1px 4px rgba(20, 20, 40, 0.14); }

/* The stage: the room the phone is scaled into (js/playable-preview.js sets --pv-scale, --pv-w, --pv-h). */
.pv-stage {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    border-radius: 14px;
    background:
        radial-gradient(ellipse at 50% 0%, rgba(var(--mud-palette-primary-rgb), 0.10), transparent 65%),
        var(--mud-palette-background-gray);
    overflow: hidden;
}
.pv-device {
    --s: var(--pv-scale, 0.5);
    position: relative;
    flex: none;
    width: calc((var(--pv-w, 390px) + 24px) * var(--s));
    height: calc((var(--pv-h, 844px) + 24px) * var(--s));
    border-radius: calc(56px * var(--s));
    background: linear-gradient(160deg, #2b2a36, #111018 60%);
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.06) inset,
        0 18px 40px rgba(10, 10, 30, 0.28),
        0 2px 6px rgba(10, 10, 30, 0.2);
    transition: width 0.25s ease, height 0.25s ease;
}
.pv-frame {
    position: absolute;
    left: calc(12px * var(--s));
    top: calc(12px * var(--s));
    width: var(--pv-w, 390px);
    height: var(--pv-h, 844px);
    transform: scale(var(--s));
    transform-origin: 0 0;
    border: 0;
    border-radius: 44px;
    background: #64cbe9;
    display: block;
}
.pv-overlay {
    position: absolute;
    inset: calc(12px * var(--s));
    border-radius: calc(44px * var(--s));
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 20px;
    text-align: center;
    font-size: 0.8125rem;
    line-height: 1.45;
    color: #eef3ff;
    background: linear-gradient(180deg, rgba(20, 40, 80, 0.86), rgba(15, 20, 40, 0.92));
}
.pv-overlay .admin-mono { overflow-wrap: anywhere; color: #fff; }

.pv-warnings {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 10px;
    padding: 8px 10px;
    border-radius: 8px;
    font-size: 0.8125rem;
    background: rgba(224, 154, 26, 0.12);
    max-height: 120px;
    overflow-y: auto;
}
.pv-warnings > .mud-icon-root { color: var(--mud-palette-warning); flex: none; margin-top: 1px; }
.pv-warnings .admin-list { margin-top: 2px; }

@media (prefers-reduced-motion: reduce) {
    .pv-dot-busy { animation: none; }
    .pv-device, .pv-screen, .pl-sections .mud-expand-panel.pl-section { transition: none; }
}

/* ------------------------------------------------------------------ top bar extras */

.pl-busy { margin: -10px 0 12px; border-radius: 4px; }
.pl-menu-line { display: flex; flex-direction: column; line-height: 1.3; }

/* ------------------------------------------------------------------ version history (a panel over the right side) */

.pl-history-scrim { position: fixed; inset: 48px 0 0 0; background: rgba(15, 14, 30, 0.32); z-index: 1140; animation: pl-fade 0.15s ease; }
.pl-history {
    position: fixed;
    top: 48px;
    right: 0;
    bottom: 0;
    width: min(620px, 100vw);
    /* Above the app bar and drawer (1100), below MudBlazor popovers (1200) and dialogs (1400): its menus and questions show over it. */
    z-index: 1150;
    display: flex;
    flex-direction: column;
    background: var(--mud-palette-surface);
    border-left: 1px solid var(--mud-palette-lines-default);
    animation: pl-slide 0.2s ease;
}
@keyframes pl-fade { from { opacity: 0; } }
@keyframes pl-slide { from { transform: translateX(24px); opacity: 0; } }
.pl-history-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 16px 12px 20px;
    border-bottom: 1px solid var(--mud-palette-lines-default);
}
.pl-history-body { flex: 1 1 auto; overflow-y: auto; padding: 12px 16px 24px; display: flex; flex-direction: column; gap: 8px; }

.pl-version { border: 1px solid var(--mud-palette-lines-default); border-radius: var(--mud-default-borderradius); background: var(--mud-palette-surface); }
.pl-version-open { border-color: rgba(var(--mud-palette-primary-rgb), 0.5); box-shadow: 0 6px 22px rgba(var(--mud-palette-primary-rgb), 0.08); }
.pl-version-main {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 10px 12px;
    border: 0;
    background: none;
    font: inherit;
    color: inherit;
    text-align: left;
    cursor: pointer;
    border-radius: var(--mud-default-borderradius);
}
.pl-version-main:hover { background: var(--mud-palette-action-default-hover); }
.pl-version-main:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.pl-version-no {
    flex: none;
    min-width: 44px;
    padding: 4px 8px;
    border-radius: 8px;
    text-align: center;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    color: var(--mud-palette-primary);
    background: rgba(var(--mud-palette-primary-rgb), 0.1);
}
.pl-version-text { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pl-version-note { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-version-chips { display: flex; gap: 4px; flex: none; }
.pl-version-chips .mud-chip { margin: 0; }
.pl-version-caret { flex: none; color: var(--mud-palette-text-secondary); }
.pl-version-detail { padding: 4px 14px 14px; border-top: 1px dashed var(--mud-palette-lines-default); }
.pl-version-compare { margin: 10px 0 8px; }
.pl-version-same { display: flex; align-items: center; gap: 6px; font-size: 0.875rem; color: var(--mud-palette-text-secondary); padding: 6px 0; }
.pl-version-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.pl-version-detail .pl-changes { max-height: 260px; }

/* ------------------------------------------------------------------ publish and export dialogs */

.pl-publish-link { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 10px; font-size: 0.875rem; }
.pl-publish-link .admin-copy code { overflow-wrap: anywhere; }
.pl-publish-note { padding-left: 0 !important; }

.pl-export-file { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; background: var(--mud-palette-background-gray); border: 1px solid var(--mud-palette-lines-default); }
.pl-export-file-icon { color: var(--mud-palette-primary); flex: none; }
.pl-export-file-words { min-width: 0; }
.pl-export-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.pl-export-size { margin-top: 16px; }
.pl-export-size-words { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; font-size: 0.95rem; }
.pl-export-size-words > b, .pl-export-size-words > span:not(.admin-grow) { white-space: nowrap; }
.pl-export-size-words > .admin-grow { flex: 1 1 auto; }
.pl-export-size-words .mud-chip { margin: 0; }
.pl-export-size-over .pl-export-size-words b { color: var(--mud-palette-error); }
.pl-export-over { color: var(--mud-palette-error); font-weight: 600; }
.pl-export-steps { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--mud-palette-lines-default); }
.pl-export-steps ol { margin: 6px 0 8px 20px; padding: 0; font-size: 0.875rem; line-height: 1.5; }
.pl-export-problem { display: flex; gap: 14px; align-items: flex-start; }
.pl-export-problem-icon { color: var(--mud-palette-warning); flex: none; }

@media (prefers-reduced-motion: reduce) {
    .pl-history, .pl-history-scrim { animation: none; }
}
.pl-tag-hosted { color: var(--mud-palette-tertiary); background: rgba(31, 168, 154, 0.12); }

/* ------------------------------------------------------------------ the tab strip (wraps instead of scrolling) */

.pl-tabbar {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 6px;
    margin-bottom: 12px;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: var(--mud-default-borderradius);
    background: var(--mud-palette-surface);
}
.pl-tabbtn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    font: inherit;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
    cursor: pointer;
    white-space: nowrap;
    transition: background-color 0.12s ease, color 0.12s ease;
}
.pl-tabbtn:hover { background: var(--mud-palette-action-default-hover); color: var(--mud-palette-text-primary); }
.pl-tabbtn:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: 1px; }
.pl-tabbtn-on, .pl-tabbtn-on:hover { color: var(--mud-palette-primary); background: rgba(var(--mud-palette-primary-rgb), 0.1); }
.pl-tabcount {
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    font-size: 0.6875rem;
    font-weight: 800;
    line-height: 18px;
    text-align: center;
    color: #fff;
    background: var(--mud-palette-primary);
}
.pl-tabcount-unsaved { background: var(--mud-palette-warning); color: #231A05; }
.pl-tabcount-error { background: var(--mud-palette-error); }
