body:has(.pc-shell), .pc-dialog {
  --pc-bg: #0e171d;
  --pc-panel: #18252e;
  --pc-sink: #111d25;
  --pc-edge: #374a52;
  --pc-ink: #eef5f1;
  --pc-muted: #a8bdc2;
  --pc-mint: #9adbc8;
  --pc-lilac: #bdcae9;
  --pc-gold: #ebc489;
}
body:has(.pc-shell), .app-shell:has(.pc-shell) { background: var(--pc-bg); color: var(--pc-ink); }
.app-shell:has(.pc-shell) > .rail { background: #17262b; border-right: 1px solid var(--pc-edge); }
.app-shell:has(.pc-shell) .step-button.active { background: #243b38; border-color: #5d847a; }
.app-shell:has(.pc-shell) .workspace > .topbar { --ink: var(--pc-ink); --muted: var(--pc-muted); --line: var(--pc-edge); color: var(--pc-ink); }
.app-shell:has(.pc-shell) .topbar :is(button, select) { background: var(--pc-panel); color: var(--pc-ink); border-color: var(--pc-edge); color-scheme: dark; }
.main-panel:has(.pc-shell) { min-height: 0; padding: 0; border: 0; background: none; box-shadow: none; }
.pc-shell, .pc-dialog { color: var(--pc-ink); color-scheme: dark; }
.pc-shell { display: grid; gap: 14px; min-width: 0; container-type: inline-size; scroll-margin-top: 15px; }
.pc-shell :is(h3, p), .pc-dialog :is(h3, p) { margin: 0; letter-spacing: 0; overflow-wrap: anywhere; }
.pc-shell svg, .pc-dialog svg { width: 17px; height: 17px; flex: none; }
.pc-tabs { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; border-bottom: 1px solid var(--pc-edge); padding-bottom: 7px; }
.pc-tabs button { padding: 5px 9px; min-height: 35px; border: 1px solid transparent; border-radius: 6px; background: none; color: var(--pc-muted); font: inherit; font-size: 13px; }
.pc-tabs button[aria-current="page"], .pc-tabs button[aria-pressed="true"] { color: var(--pc-mint); background: #203531; border-color: #40655d; font-weight: 750; }
.pc-tabs button[aria-current="page"]::after { display: block; width: 20px; margin: 2px auto 0; border-top: 1px solid var(--pc-mint); content: ""; }
.pc-tight { margin-bottom: 8px; }
.pc-identity, .pc-admin-hero { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px; min-width: 0; padding: 18px 20px; border: 1px solid #476259; border-radius: 8px; background: #1b302d; }
.pc-identity-main, .pc-identity-actions, .pc-worn { display: flex; align-items: center; gap: 11px; flex-wrap: wrap; min-width: 0; }
.pc-identity-main { flex: 1 1 230px; flex-wrap: nowrap; }
.pc-identity-main > div { min-width: 0; }
.pc-identity p, .pc-admin-hero p { color: var(--pc-mint); font-size: 12px; font-weight: 650; }
.pc-identity h3, .pc-admin-hero h3 { margin-top: 3px; font-size: 28px; line-height: 1.18; }
.pc-identity h3 span { display: inline-block; vertical-align: 4px; padding: 3px 6px; border: 1px solid #6c8271; border-radius: 5px; font-size: 13px; color: #dceec5; background: #32493e; }
.pc-identity-meta { margin-top: 5px; color: var(--pc-muted); font-size: 13px; }
.pc-avatar { display: grid; width: 55px; height: 55px; flex: 0 0 55px; place-items: center; overflow: hidden; border: 1px solid #6a9185; border-radius: 8px; background: #28483f; color: var(--pc-mint); font-size: 21px; font-weight: 800; }
.pc-avatar img { width: 100%; height: 100%; object-fit: cover; }
.pc-worn { color: var(--pc-gold); max-width: 280px; overflow-wrap: anywhere; }
.pc-worn .pc-medal-art { width: 46px; height: 46px; }
.pc-metrics, .pc-launchers { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.pc-metric { --pc-tone: var(--pc-mint); display: grid; grid-template-rows: auto auto minmax(4px,auto) auto auto; align-content: start; align-items: start; gap: 5px; min-width: 0; min-height: 138px; padding: 13px 14px; text-align: left; color: var(--pc-ink); border: 1px solid var(--pc-edge); border-radius: 8px; background: var(--pc-panel); }
.pc-metric:nth-child(2) { --pc-tone: var(--pc-lilac); }
.pc-metric:nth-child(n+3) { --pc-tone: var(--pc-gold); }
.pc-metric-label, .pc-metric-detail { display: inline-flex; align-items: center; gap: 5px; font-weight: 700; font-size: 13px; overflow-wrap: anywhere; min-width: 0; }
.pc-metric-label svg, .pc-metric-detail { color: var(--pc-tone); }
.pc-metric-line { overflow-wrap: anywhere; color: var(--pc-muted); font-size: 13px; }
.pc-metric-line strong { color: var(--pc-ink); font-size: 31px; line-height: 1.2; font-variant-numeric: tabular-nums; }
.pc-metric small { color: var(--pc-muted); overflow-wrap: anywhere; }
.pc-metric progress { width: 100%; height: 5px; max-width: 100%; accent-color: var(--pc-tone); }
.pc-map { position: relative; isolation: isolate; overflow: hidden; padding: 14px 18px; border: 1px solid #466168; border-radius: 8px; background: #152931; }
.pc-map-heading { display: flex; align-items: center; justify-content: space-between; gap: 4px 10px; flex-wrap: wrap; }
.pc-map-heading h3 { font-size: 21px; }
.pc-map-heading > span { color: var(--pc-muted); font-size: 13px; }
.pc-map-art { position: absolute; z-index: -1; inset: 0; width: 100% !important; height: 100% !important; pointer-events: none; }
.pc-map-art path { fill: none; stroke: #759f9c29; stroke-width: 1.1; }
.pc-map-art .pc-trail { stroke: #8dbab2a8; stroke-width: 2.6; stroke-dasharray: 5 3; }
.pc-map-nodes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(122px, 100%), 1fr)); align-items: start; gap: 8px; min-height: 130px; margin: 0; padding: 16px 10px 6px; list-style: none; }
.pc-map-nodes li { min-width: 0; }
.pc-map-nodes button { display: grid; justify-items: center; gap: 3px; width: 100%; padding: 3px 2px; border: 1px solid transparent; border-radius: 6px; background: none; color: var(--pc-ink); text-align: center; overflow-wrap: anywhere; }
.pc-map-nodes li:nth-child(2n + 1) { margin-top: 15px; }
.pc-map-nodes button strong { font-size: 18px; }
.pc-map-nodes button :is(span:not(.pc-node), small) { color: var(--pc-muted); font-size: 12px; }
.pc-node { display: grid; width: 34px; height: 34px; place-items: center; border: 1px solid #7b9e9e; border-radius: 50%; background: #294047; color: #a8cece; }
.pc-map-nodes button[aria-current="step"] .pc-node { background: #26463d; border: 2px solid var(--pc-mint); box-shadow: 0 0 0 4px #9adbc828; color: var(--pc-mint); }
.pc-map-history { margin-top: 5px; color: var(--pc-muted); font-size: 12px; }
.pc-map-history button { margin: 4px 5px 0 0; }
.pc-next, .pc-band-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 14px; }
.pc-next { min-width: 0; padding: 10px 14px; border: 1px solid #5c5342; border-radius: 8px; background: #282724; }
.pc-next > div { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pc-next small, .pc-next svg { color: var(--pc-gold); }
.pc-next strong { display: block; overflow-wrap: anywhere; }
.pc-launchers { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pc-launchers button { display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: 9px; text-align: left; padding: 12px; min-height: 68px; border: 1px solid var(--pc-edge); border-radius: 8px; background: var(--pc-panel); color: var(--pc-ink); }
.pc-launcher-icon { display: grid; place-items: center; width: 31px; height: 31px; border-radius: 5px; background: #3b3328; color: var(--pc-gold); }
.pc-launchers button:nth-child(2) .pc-launcher-icon { background: #28423a; color: var(--pc-mint); }
.pc-launchers button:nth-child(3) .pc-launcher-icon { background: #30374b; color: var(--pc-lilac); }
.pc-launchers button span :is(strong, small) { display: block; overflow-wrap: anywhere; }
.pc-launchers small { color: var(--pc-muted); font-size: 11px; line-height: 1.45; }
.pc-band { min-width: 0; padding: 11px 2px 3px; border-top: 1px solid var(--pc-edge); }
.pc-band-head { margin-bottom: 9px; }
.pc-band-head h3 { font-size: 17px; }
.pc-band-head input { min-width: 0; max-width: 240px; }
.pc-list { min-width: 0; display: grid; gap: 1px; margin: 0; padding: 0; list-style: none; }
.pc-list-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, auto); align-items: center; gap: 8px; padding: 8px 10px; border-block-end: 1px solid #283941; min-width: 0; background: #152129; }
.pc-list-row:first-child { border-start-start-radius: 7px; border-start-end-radius: 7px; }
.pc-list-row:last-child { border-end-start-radius: 7px; border-end-end-radius: 7px; }
.pc-list-row > div { min-width: 0; }
.pc-list-row strong, .pc-list-row small { display: block; overflow-wrap: anywhere; }
.pc-list-row small { margin-top: 2px; color: var(--pc-muted); font-size: 12px; }
.pc-row-actions, .pc-pills { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 6px; }
.pc-state, .pc-amount { display: inline-flex; align-items: center; padding: 3px 6px; min-height: 23px; border: 1px solid #496268; border-radius: 4px; color: #bdd4d6; background: #243840; font-size: 12px; font-weight: 700; white-space: normal; }
.pc-state:is([data-state="approved"],[data-state="fulfilled"],[data-state="paid"]), .pc-amount { color: var(--pc-mint); background: #213b34; border-color: #496f61; }
.pc-state:is([data-state="pending"],[data-state="returned"]) { color: var(--pc-gold); background: #3b3024; border-color: #71593d; }
.pc-state:is([data-state="rejected"],[data-state="expired"]) { color: #e7afb4; background: #35282f; border-color: #654953; }
.pc-empty, .pc-page-message { padding: 11px 13px; background: #15232a; border: 1px solid #32494e; border-radius: 7px; color: var(--pc-muted); }
.pc-page-message { display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.pc-badge-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(120px,100%),1fr)); gap: 10px; }
.pc-badge { display: grid; justify-items: center; align-content: start; min-width: 0; gap: 5px; padding: 12px 6px; border: 1px solid var(--pc-edge); border-radius: 8px; background: var(--pc-panel); color: var(--pc-ink); overflow-wrap: anywhere; }
.pc-badge .pc-medal-art { width: 63px; height: 63px; }
.pc-badge-detail .pc-medal-art { width: 84px; height: 84px; }
.pc-badge-detail { display: flex; align-items: center; gap: 12px; }
:is(.pc-badge,.pc-badge-detail)[data-earned="false"] .pc-medal-art { filter: grayscale(1); opacity: .55; }
.pc-badge span, .pc-filter-caption { color: var(--pc-muted); font-size: 12px; }
.pc-admin-hero { background: #26302b; border-color: #5e6951; }
.pc-admin-hero h3 { font-size: 23px; }
.pc-admin-tabs { margin-top: -6px; }
.pc-shell :is(.primary-button,.secondary-button,.danger-button), .pc-dialog :is(.primary-button,.secondary-button,.danger-button) { min-height: 34px; min-width: 0; gap: 4px; padding: 4px 8px; border-radius: 6px; white-space: normal; overflow-wrap: anywhere; }
:is(.pc-shell,.pc-dialog) .secondary-button { background: #223239; color: var(--pc-ink); border-color: #496068; }
:is(.pc-shell,.pc-dialog) .primary-button { background: #a1deca; color: #142b25; border-color: #a1deca; }
:is(.pc-shell,.pc-dialog) .danger-button { background: #402b30; color: #ffc5c7; border-color: #86545d; }
:is(.pc-shell,.pc-dialog) :is(a,button,input,select,textarea,summary):focus-visible { outline: 2px solid var(--pc-mint); outline-offset: 1px; }
:is(.pc-shell,.pc-dialog) :is(input:not([type="checkbox"]), select, textarea) { min-height: 35px; padding: 6px 8px; background: var(--pc-sink); color: var(--pc-ink); border: 1px solid var(--pc-edge); border-radius: 6px; font: inherit; }
.pc-dialog { width: min(700px, calc(100vw - 20px)); max-width: calc(100vw - 20px); padding: 0; border: 1px solid var(--pc-edge); border-radius: 8px; background: var(--pc-panel); }
.pc-dialog:not([open]) { display: none; }
.pc-dialog[open] { display: grid; grid-template-rows: auto minmax(0,1fr) auto; max-height: min(760px, calc(100dvh - 20px)); overflow: hidden; }
.pc-dialog::backdrop { background: #060c11cc; }
.pc-dialog-head, .pc-dialog-actions { background: #1a2931; border-color: var(--pc-edge); }
.pc-dialog-head { padding: 10px 14px; }
.pc-dialog-head h3 { font-size: 19px; }
.pc-dialog .pc-close { display: grid; width: 34px; place-items: center; }
.pc-dialog-body { display: grid; align-content: start; gap: 10px; min-height: 0; min-width: 0; padding: 13px 14px; overflow: auto; }
.pc-dialog-actions { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 14px; }
.pc-form { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px 10px; align-items: start; }
.pc-form > :is(.pc-facts,.pc-rule), .pc-wide { grid-column: 1 / -1; }
.pc-field { display: grid; min-width: 0; gap: 5px; color: var(--pc-muted); font-size: 12px; overflow-wrap: anywhere; }
.pc-field :is(input,select,textarea) { min-width: 0; width: 100%; }
.pc-field textarea { resize: vertical; }
.pc-check { display: flex; gap: 6px; align-items: center; min-height: 34px; overflow-wrap: anywhere; }
.pc-check input { accent-color: var(--pc-mint); }
.pc-fieldset { min-width: 0; margin: 0; padding: 8px; border: 1px solid var(--pc-edge); border-radius: 6px; }
.pc-fieldset legend { color: var(--pc-ink); font-size: 13px; }
.pc-custom-labels > summary { cursor: pointer; color: var(--pc-mint); font-weight: 650; }
.pc-custom-labels[open] > .pc-form { margin-top: 10px; }
.pc-dynamic > button { margin-top: 8px; }
.pc-custom-row { display: grid; grid-template-columns: minmax(0,1fr) 34px; gap: 8px; align-items: start; padding: 10px 0; }
.pc-custom-row + .pc-custom-row { border-top: 1px solid var(--pc-edge); }
.pc-dialog .pc-row-remove { width: 34px; display: grid; place-items: center; }
.pc-row-remove svg { fill: none; stroke: currentColor; stroke-width: 1.7; }
.pc-form-note { color: var(--pc-muted); font-size: 13px; }
.pc-people-pick { display: flex; flex-wrap: wrap; gap: 5px 12px; max-height: 200px; overflow: auto; }
.pc-config-levels { display: grid; gap: 7px; }
.pc-member-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 110px) auto; align-items: end; gap: 6px; margin-bottom: 7px; }
.pc-facts { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(128px,100%),1fr)); gap: 7px; margin: 0; }
.pc-fact { min-width: 0; border-inline-start: 2px solid #547870; padding-inline-start: 8px; overflow-wrap: anywhere; }
.pc-fact dt { color: var(--pc-muted); font-size: 12px; }
.pc-fact dd { margin: 2px 0 0; font-weight: 750; }
.pc-rule, .pc-review-note, .pc-card-preview { display: grid; justify-items: start; gap: 5px; padding-block: 6px; }
.pc-copy { white-space: pre-wrap; color: var(--pc-muted); font-size: 13px; }
.pc-link { display: inline-flex; align-items: center; gap: 3px; color: var(--pc-mint); font-size: 13px; }
.pc-form-error { color: #ffc3be; font-size: 13px; }
.pc-form-error:empty { display: none; }
@container (max-width: 760px) {
  .pc-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pc-map-nodes { grid-template-columns: repeat(auto-fit,minmax(min(67px,100%),1fr)); padding-inline: 0; }
  .pc-launchers { gap: 6px; }
  .pc-launchers button { grid-template-columns: minmax(0,1fr); justify-items: start; gap: 4px; }
  .pc-launchers button > svg { display: none; }
}
@container (max-width: 400px) {
  .pc-identity, .pc-admin-hero, .pc-map { padding: 10px; }
  .pc-identity h3, .pc-admin-hero h3 { font-size: 21px; }
  .pc-avatar { width: 41px; height: 41px; flex-basis: 41px; }
  .pc-metric { padding: 8px; min-height: 127px; }
  .pc-metric-line strong { font-size: 23px; }
  .pc-list-row { grid-template-columns: minmax(0,1fr); }
  .pc-list-row .pc-row-actions { justify-content: flex-start; }
  .pc-map-nodes li:nth-child(2n + 1) { margin-top: 2px; }
}
@media (max-width: 440px) {
  .pc-form { grid-template-columns: minmax(0,1fr); }
  .pc-dialog-body { padding: 9px 10px; }
  .pc-dialog-head, .pc-dialog-actions { padding: 8px 10px; }
}
@media (hover: hover) {
  .pc-shell :is(button,.pc-badge):hover, .pc-dialog button:hover { border-color: #6c968b; }
  .pc-metric:hover, .pc-launchers button:hover { background: #203138; }
}
@media (prefers-reduced-motion: no-preference) {
  .pc-metric, .pc-launchers button, .pc-tabs button { transition: border-color .16s ease, background .16s ease; }
}
