/* One palette for the actual profile, shared hover cards and owner previews. */
:root[data-theme] .mini-profile[data-profile-theme=custom]{--mp-text:var(--pt-text);--mp-muted:var(--pt-muted);--mp-accent:var(--pt-icon);color:var(--pt-text)}
:root[data-theme] .mini-profile[data-profile-theme=custom] .mini-profile-body{background:linear-gradient(180deg,var(--pt-primary),var(--pt-secondary));border-color:var(--pt-line);color:var(--pt-text)}
:root[data-theme] .mini-profile[data-profile-theme=custom] .mini-profile-role{background:color-mix(in srgb,var(--pt-icon) 10%,transparent);border-color:var(--pt-line);color:var(--pt-icon)}
:root[data-theme] .mini-profile[data-profile-theme=custom] :is(.mini-profile-role>svg,.mini-profile-age>svg,.mini-profile-metric-value>svg){color:var(--pt-icon)}
:root[data-theme] .mini-profile[data-profile-theme=custom] :is(.mini-profile-metric-value>strong,.mini-profile-age>strong){color:var(--pt-text)}
:root[data-theme] .mini-profile[data-profile-theme=custom] :is(.mini-profile-metric,.mini-profile-age){border-color:var(--pt-line)}
:root[data-theme] .mini-profile[data-profile-theme=custom] .mini-profile-close{color:var(--pt-text);border-color:var(--pt-line);background:var(--pt-top)}
.cab-appearance-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(280px,1fr);align-items:start;gap:24px}
.cab-appearance-controls{min-width:0;display:grid;gap:16px}.cab-appearance-controls>.cab-card{margin:0}.cab-appearance-controls>.cab-two-cols{grid-template-columns:minmax(0,1fr);margin:0;gap:16px}
.cab-appearance-controls .cab-slots{grid-template-columns:repeat(2,minmax(0,1fr))}
.cab-appearance-preview{position:sticky;top:24px;min-width:0;padding:22px;border:1px solid var(--line);border-radius:16px;background:var(--surface)}
.cab-preview-heading{margin-bottom:18px}.cab-preview-heading h3{margin:0 0 6px;color:var(--text);font-size:14px}.cab-preview-heading>span{font-size:10px;color:var(--muted)}
.cab-preview-tabs{display:flex;gap:4px;background:var(--surface-hi);border:1px solid var(--line);padding:4px;border-radius:9px;margin-bottom:22px}
.cab-preview-tabs button{flex:1;min-width:0;padding:9px 5px;color:var(--muted);font-size:11px;border-radius:6px}.cab-preview-tabs [aria-selected=true]{color:var(--text);background:var(--accent-wash);box-shadow:0 1px 5px #0001}
.mini-profile.mini-profile-preview{position:relative;inset:auto;width:100%;max-width:360px;max-height:none;margin:0 auto;z-index:0;animation:none;isolation:isolate;display:block;overflow:visible;pointer-events:auto}
.mini-profile-preview .mini-profile-body{max-height:none;box-shadow:0 12px 30px #0002;overflow:hidden}.mini-profile-preview .mini-profile-content{padding:0 20px 20px}.mini-profile-preview .mini-profile-name{font-size:21px}.mini-profile-preview .mini-profile-open{min-width:0;justify-content:center;cursor:default}
.mini-profile-preview .mini-profile-membership{display:flex;align-items:center;gap:8px;padding:14px 0;color:var(--mp-muted);font-size:10px}.mini-profile-membership svg{color:var(--mp-accent)}
.cab-preview-bio{margin:0 0 4px;color:var(--mp-text);font-size:11px;line-height:1.7;overflow-wrap:anywhere;white-space:pre-wrap}.cab-preview-more{display:grid;place-items:center;width:38px;flex:none;border:1px solid var(--pt-line,var(--line));border-radius:8px;color:var(--mp-accent)}
.cab-preview-profile-link{display:flex;justify-content:center;margin:20px auto 0}.cab-appearance-preview.is-profile .mini-profile-preview{max-width:none}.cab-appearance-preview.is-profile .mini-profile-cover{height:145px}.cab-appearance-preview.is-profile .mini-profile-avatar{width:86px;height:86px;flex-basis:86px}
.cab-theme-editor fieldset{border:0;margin:0;padding:0;min-width:0}.cab-theme-switch{display:flex;align-items:center;gap:9px;font-size:12px;color:var(--text);margin-bottom:20px}.cab-theme-switch input{accent-color:var(--accent);width:16px;height:16px}
.cab-theme-colors{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.cab-theme-color{display:grid;gap:10px;min-width:0}.cab-theme-color>span:first-child{font-size:11px;color:var(--muted)}
.cab-theme-color-fields{display:flex;align-items:center;gap:8px;background:var(--surface-hi);border:1px solid var(--line);padding:7px;border-radius:10px;min-width:0}
.cab-theme-color-fields input[type=color]{width:32px;height:32px;flex:0 0 32px;border:0;padding:0;border-radius:7px;background:transparent;cursor:pointer}.cab-theme-color-fields input[type=color]::-webkit-color-swatch-wrapper{padding:0}.cab-theme-color-fields input[type=color]::-webkit-color-swatch{border:0;border-radius:6px}
.cab-theme-color-fields input[type=text]{width:100%;min-width:0;max-width:90px;border:0;outline:0;background:transparent;color:var(--text);font:11px/1.5 monospace}.cab-theme-color-fields:focus-within{outline:2px solid var(--accent-edge);outline-offset:2px}
.cab-theme-presets{display:flex;gap:10px;flex-wrap:wrap;margin:18px 0}.cab-theme-presets button{width:30px;height:30px;border-radius:50%;background:linear-gradient(145deg,var(--swatch-top),var(--swatch-bottom));border:1px solid var(--line);box-shadow:inset 0 0 0 3px var(--surface)}
.cab-theme-presets button[aria-pressed=true]{outline:2px solid var(--accent);outline-offset:2px}.cab-theme-editor fieldset:disabled{opacity:.5}.cab-theme-editor>.cab-inline-link{margin-top:14px}.cab-theme-editor .cab-form-footer{flex-wrap:wrap;gap:12px}.cab-theme-editor .cab-save-actions{margin-left:auto}
@media(max-width:1050px){.cab-appearance-layout{grid-template-columns:minmax(0,1fr)}.cab-appearance-preview{position:relative;top:auto;grid-row:1;padding:20px}.mini-profile.mini-profile-preview{max-width:344px}.cab-appearance-controls>.cab-two-cols{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){.cab-appearance-controls>.cab-two-cols{grid-template-columns:minmax(0,1fr)}.cab-appearance-preview{padding:16px}.cab-theme-color-fields{gap:5px;padding:5px}.cab-theme-color-fields input[type=text]{font-size:10px}.cab-theme-colors{gap:8px}.cab-theme-presets{gap:12px}}

:root[data-theme] .mini-profile[data-profile-theme=custom] .mini-profile-metric{background:color-mix(in srgb,var(--pt-text) 4%,transparent)!important;border-color:var(--pt-line)!important}
:root[data-theme] .mini-profile[data-profile-theme=custom] .mini-profile-body{background-color:var(--pt-secondary)!important;border-color:var(--pt-line)!important}
.cab-appearance-preview.has-frame .cab-preview-tabs{margin-bottom:60px}.mini-profile-preview .mini-profile-actions{display:flex;align-items:stretch;gap:8px}.mini-profile-preview .mini-profile-open{flex:1;width:auto}.mini-profile-preview .cab-preview-more{min-height:40px}


/* Keep every frame/effect inside the preview's own layout area. */
.cab-preview-stage{box-sizing:border-box;width:100%;min-width:0;overflow:clip;isolation:isolate;position:relative;padding:10px 8px;contain:paint}
.cab-appearance-preview.has-frame .cab-preview-tabs{margin-bottom:18px}
.cab-preview-art-switch{display:flex;align-items:center;gap:8px;margin:12px 0 0;color:var(--muted);font-size:10px}.cab-preview-art-switch input{width:14px;height:14px;accent-color:var(--accent)}
.cab-theme-color-button{display:block;flex:0 0 32px;width:32px;height:32px;padding:0;background:var(--picker-color);border:1px solid #ffffff26;border-radius:7px;cursor:pointer;box-shadow:inset 0 0 0 1px #0001}.cab-theme-color-button:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.profile-color-picker{box-sizing:border-box;position:fixed;inset:auto;margin:0;padding:16px;width:min(308px,calc(100vw - 24px));max-height:calc(100dvh - 24px);overflow-y:auto;overscroll-behavior:contain;background:var(--surface,#17151d);color:var(--text,#eeeaf6);border:1px solid var(--line,#ffffff20);border-radius:14px;box-shadow:0 16px 60px #0007;z-index:2147483647;font:12px/1.5 Community,Arial,sans-serif;scrollbar-width:thin}
.profile-color-picker[hidden]{display:none!important}.profile-color-picker *{box-sizing:border-box}.profile-color-picker header{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px;gap:12px}.profile-color-picker h3{font:600 13px/1.4 Community,Arial,sans-serif;color:var(--text);margin:0}.profile-color-picker header button{width:26px;height:26px;font-size:21px;line-height:1;color:var(--muted);border-radius:6px;background:var(--surface-hi)}
.profile-picker-sv{position:relative;width:100%;height:165px;border-radius:8px;isolation:isolate;background:linear-gradient(to top,#000,transparent),linear-gradient(to right,#fff,transparent),var(--picker-hue,#f00);touch-action:none;cursor:crosshair;outline:1px solid #0002;user-select:none}
.profile-picker-sv:focus-visible{outline:2px solid var(--accent);outline-offset:3px}.profile-picker-sv i{position:absolute;width:14px;height:14px;border:2px solid #fff;border-radius:50%;box-shadow:0 0 0 1px #000b,0 1px 5px #0006;transform:translate(-50%,-50%);pointer-events:none}
.profile-picker-label{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.profile-picker-hue{display:block;margin:17px 0 15px}.profile-picker-hue input{display:block;appearance:none;-webkit-appearance:none;width:100%;height:10px;margin:0;padding:0;border:0;border-radius:10px;background:linear-gradient(to right,#f00,#ff0,#0f0,#0ff,#00f,#f0f,#f00);cursor:pointer;touch-action:pan-y}
.profile-picker-hue input::-webkit-slider-thumb{-webkit-appearance:none;width:10px;height:18px;border:2px solid #fff;border-radius:4px;background:var(--picker-hue);box-shadow:0 0 0 1px #0005}.profile-picker-hue input::-moz-range-thumb{width:8px;height:16px;border:2px solid #fff;border-radius:4px;background:var(--picker-hue)}
.profile-picker-value{display:flex;align-items:center;gap:7px;padding:8px;border:1px solid var(--line);border-radius:9px;background:var(--surface-hi)}.profile-picker-value>span{width:23px;height:23px;flex:none;border:1px solid #ffffff25;border-radius:5px}.profile-picker-value label{flex:1;min-width:0}.profile-picker-value input{width:100%;min-width:0;padding:0;border:0;background:none;color:var(--text);font:13px/1.5 monospace}.profile-picker-value button{display:grid;place-items:center;width:27px;height:28px;flex:none;border:0;border-radius:5px;background:transparent;color:var(--secondary,var(--text));cursor:pointer}.profile-picker-value button:hover{background:var(--accent-wash);color:var(--accent)}
.profile-color-picker svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.profile-color-picker [aria-invalid=true]{outline:1px solid #e76e8c;outline-offset:3px}
.profile-picker-rgb{margin:10px 0;color:var(--muted);font-size:10px}.profile-picker-rgb summary{cursor:pointer;padding:3px 0}.profile-picker-rgb>div{display:flex;gap:10px;margin-top:7px}.profile-picker-rgb label{display:flex;align-items:center;gap:5px;flex:1;min-width:0}.profile-picker-rgb input{width:100%;min-width:0;padding:5px;border:1px solid var(--line);border-radius:5px;background:var(--surface-hi);color:var(--text);font:11px monospace}
.profile-picker-swatches{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}.profile-picker-swatches button{width:30px;height:30px;flex:none;border:1px solid #ffffff35;border-radius:6px;box-shadow:inset 0 0 0 1px #0001;cursor:pointer}.profile-picker-swatches button:hover{outline:2px solid var(--accent-edge);outline-offset:2px}.profile-picker-recents small{display:block;margin-top:12px;color:var(--muted);font-size:10px}
.profile-picker-status{font-size:10px;min-height:15px;margin:11px 0;color:var(--muted)}.profile-color-picker footer{display:flex;justify-content:flex-end;gap:8px;padding-top:11px;border-top:1px solid var(--line)}.profile-color-picker footer button{padding:8px 13px;border:1px solid var(--line);border-radius:7px;font-size:11px;cursor:pointer;color:var(--text);background:var(--surface-hi)}.profile-color-picker [data-picker-done]{background:var(--action-fill,#6f61cc);color:#fff;border-color:transparent}
@media(max-width:480px){.profile-color-picker{width:min(300px,calc(100vw - 24px));padding:14px}.profile-picker-sv{height:152px}.profile-picker-swatches{gap:7px}.profile-picker-swatches button{width:29px;height:29px}}

.profile-picker-status:empty{display:none}.profile-color-picker footer{margin-top:14px}@media(max-width:480px){.profile-picker-value input{font-size:16px}}

/* Colors belong to the identity plate; page background, controls and other cards keep site colors. */
:root[data-theme] .np[data-profile-theme=custom] .np_hero{--np-text:var(--pt-text);--np-muted:var(--pt-muted);--np-dim:var(--pt-muted);background:linear-gradient(180deg,var(--pt-primary),var(--pt-secondary));border-color:var(--pt-line);color:var(--pt-text)}
:root[data-theme] .np[data-profile-theme=custom] .np_hero_main{color:var(--pt-text)!important}
:root[data-theme] .np[data-profile-theme=custom] .np_hero_main :is(.np_bio,.np_offline){color:var(--pt-muted)!important}
:root[data-theme] .np[data-profile-theme=custom] .np_fact span{color:var(--pt-muted)}
:root[data-theme] .np[data-profile-theme=custom] .np_hero :is(.np_acts iconify-icon,.np_fact iconify-icon){color:var(--pt-icon)}
:root[data-theme] .np[data-profile-theme=custom].np_glass .np_hero{background:linear-gradient(180deg,color-mix(in srgb,var(--pt-primary) 85%,transparent),color-mix(in srgb,var(--pt-secondary) 85%,transparent))}
:root[data-theme] .np[data-profile-theme=custom].np_cover_clean .np_hero{background:transparent}
:root[data-theme] .np[data-profile-theme=custom].np_cover_clean .np_hero_main{background:linear-gradient(180deg,var(--pt-primary),color-mix(in srgb,var(--pt-primary),var(--pt-secondary)))}
:root[data-theme] .np[data-profile-theme=custom].np_cover_clean .np_facts{background:linear-gradient(180deg,color-mix(in srgb,var(--pt-primary),var(--pt-secondary)),var(--pt-secondary))}
:root[data-theme] .np[data-profile-theme=custom].np_cover_clean.np_glass :is(.np_hero_main,.np_facts){background:linear-gradient(180deg,color-mix(in srgb,var(--pt-primary) 85%,transparent),color-mix(in srgb,var(--pt-secondary) 85%,transparent))}
