/* Identical profile layout in both sites; only the palette changes. */
body dialog.persi-profile-dialog {
  --profile-accent:#345f91;--profile-ink:#243a54;--profile-line:#c7d3e1;
  --profile-field:#8096b0;--profile-soft:#edf2f8;--profile-muted:#526478;
  --profile-heading:#284b73;--profile-hover:#2d527f;--profile-edge:#233f64;--profile-secondary:#f1f5fa;--profile-secondary-hover:#e5eef8;--profile-disabled:#e9eef5;--profile-disabled-ink:#7b899b;--profile-disabled-line:#ccd6e3;
  box-sizing:border-box;direction:rtl;text-align:right;font-family:Vazirmatn,PersiColorful,Tahoma,Arial,sans-serif;
  width:min(650px,calc(100% - 28px));max-width:650px;max-height:calc(100vh - 28px);max-height:calc(100dvh - 28px);
  position:fixed;inset:0;margin:auto;padding:26px 28px 28px;border:1px solid var(--profile-line);border-radius:18px;
  background:#fffefa;color:var(--profile-ink);box-shadow:0 12px 38px #243a541a;overflow:auto;overscroll-behavior:contain;
  scrollbar-width:thin;scrollbar-color:var(--profile-line) transparent;
}
body dialog.persi-profile-dialog[data-profile-theme="green"] {
  --profile-accent:#476337;--profile-ink:#344a24;--profile-line:#cdd6c2;
  --profile-field:#8b9a7c;--profile-soft:#f1f5ea;--profile-muted:#58634f;
  --profile-heading:#344a24;--profile-hover:#3b552d;--profile-edge:#2f4822;--profile-secondary:#f1f5ea;--profile-secondary-hover:#e8efdd;--profile-disabled:#eef1e9;--profile-disabled-ink:#7d8873;--profile-disabled-line:#d4ddcb;
}
body dialog.persi-profile-dialog *,body dialog.persi-profile-dialog *::before,body dialog.persi-profile-dialog *::after{box-sizing:border-box}
body dialog.persi-profile-dialog::backdrop{background:#24364b66;backdrop-filter:blur(2px)}
body dialog.persi-profile-dialog[data-profile-theme="green"]::backdrop{background:#27341d66}
body dialog.persi-profile-dialog:not([open]),body dialog.persi-profile-dialog [hidden]{display:none!important}
body dialog.persi-profile-dialog .persi-profile-header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 22px;padding:0;border:0;background:transparent}
body dialog.persi-profile-dialog .persi-profile-header h2{margin:0!important;padding:0;font-size:24px;font-weight:700;color:var(--profile-heading);line-height:1.8;text-align:right}
body dialog.persi-profile-dialog button.persi-profile-close{display:inline-flex;align-items:center;justify-content:center;flex:0 0 44px;width:44px;min-width:44px;height:44px;min-height:44px;padding:10px;margin:0;border:0;border-radius:11px;background:transparent;color:var(--profile-muted);box-shadow:none;transform:none;cursor:pointer}
body dialog.persi-profile-dialog button.persi-profile-close:hover{background:var(--profile-soft)}
body dialog.persi-profile-dialog .persi-profile-close svg{width:23px;height:23px;display:block;pointer-events:none}
body dialog.persi-profile-dialog form{display:block;margin:0;padding:0}
body dialog.persi-profile-dialog .persi-profile-fields{display:grid;gap:15px}
body dialog.persi-profile-dialog .persi-profile-field{display:grid;gap:7px;min-width:0}
body dialog.persi-profile-dialog .persi-profile-field label{margin:0;font-size:13px;font-weight:600;color:var(--profile-ink);line-height:1.8}
body dialog.persi-profile-dialog .persi-profile-field :is(input,textarea){display:block;width:100%;min-width:0;min-height:47px;height:auto;margin:0;padding:11px 13px;border:1px solid var(--profile-field);border-radius:11px;background:#fff;color:var(--profile-ink);font:400 16px/1.8 Vazirmatn,PersiColorful,Tahoma,Arial,sans-serif;text-align:right;box-shadow:inset 0 1px 2px #284b7308;outline:none}
body dialog.persi-profile-dialog .persi-profile-field [dir=ltr]{text-align:left;direction:ltr}
body dialog.persi-profile-dialog .persi-profile-field textarea{min-height:98px;resize:vertical}
body dialog.persi-profile-dialog .persi-profile-field [readonly]{background:var(--profile-soft);color:var(--profile-muted)}
body dialog.persi-profile-dialog .persi-profile-field :is(input,textarea):focus{border-color:var(--profile-accent);outline:2px solid var(--profile-line);outline-offset:1px}
body dialog.persi-profile-dialog .persi-profile-actions{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;margin:25px 0 0;padding:22px 0 0;border:0;border-top:1px solid var(--profile-line)}
body dialog.persi-profile-dialog .persi-profile-actions button{width:100%;min-width:0;min-height:52px;margin:0;padding:11px 13px;border:1px solid var(--profile-accent);border-radius:10px;background:var(--profile-accent);color:#fff;font:600 14px/1.8 Vazirmatn,PersiColorful,Tahoma,Arial,sans-serif;white-space:normal;cursor:pointer;transform:none;box-shadow:0 3px 0 var(--profile-edge),0 6px 12px #284b7314,inset 0 1px 0 #ffffff29}
body dialog.persi-profile-dialog .persi-profile-actions button.persi-profile-secondary{background:var(--profile-secondary);color:var(--profile-heading);border-color:var(--profile-field);box-shadow:0 2px 0 var(--profile-line)}
body dialog.persi-profile-dialog .persi-profile-actions button:not(:disabled):hover{background:var(--profile-hover);filter:none}
body dialog.persi-profile-dialog .persi-profile-actions button.persi-profile-secondary:not(:disabled):hover{background:var(--profile-secondary-hover)}
body dialog.persi-profile-dialog .persi-profile-actions button:disabled{background:var(--profile-disabled);color:var(--profile-disabled-ink);border-color:var(--profile-disabled-line);cursor:not-allowed;box-shadow:none;opacity:1;filter:none}
body dialog.persi-profile-dialog button:focus-visible{outline:3px solid var(--profile-field);outline-offset:3px}
body dialog.persi-profile-dialog [data-profile-status]{margin:0 0 18px;font-size:13px;line-height:1.9;color:var(--profile-muted);overflow-wrap:anywhere}
body dialog.persi-profile-dialog [data-profile-status][role=alert]{color:#a43e34}
body dialog.persi-profile-dialog.persi-profile-confirm{width:min(450px,calc(100% - 28px));max-width:450px;padding:22px 24px 26px;box-shadow:0 16px 50px #12263e38}
body dialog.persi-profile-dialog.persi-profile-confirm .persi-profile-header{margin-bottom:24px}
body dialog.persi-profile-dialog.persi-profile-confirm .persi-profile-header h2{font-size:20px}
body dialog.persi-profile-dialog.persi-profile-confirm p{margin:0;font-size:14px;line-height:1.9;color:var(--profile-muted)}
body dialog.persi-profile-dialog.persi-profile-confirm .persi-profile-actions{grid-template-columns:1fr;gap:13px;margin:0;padding:0;border:0}
/* Specificity against the existing appearance plugin, without changing its files. */
body[data-pm-appearance] #profile-dialog.persi-profile-dialog{padding:26px 28px 28px;width:min(650px,calc(100% - 28px));background:#fffefa;color:var(--profile-ink);border-color:var(--profile-line);box-shadow:0 12px 38px #243a541a}
body[data-pm-appearance] #profile-dialog.persi-profile-dialog h2{color:var(--profile-heading)}
@media(max-width:500px){
 body dialog.persi-profile-dialog,body[data-pm-appearance] #profile-dialog.persi-profile-dialog{padding:18px 18px 22px}
 body dialog.persi-profile-dialog .persi-profile-header{margin-bottom:18px}
 body dialog.persi-profile-dialog .persi-profile-header h2,body[data-pm-appearance] #profile-dialog.persi-profile-dialog .persi-profile-header h2{font-size:22px}
 body dialog.persi-profile-dialog.persi-profile-confirm .persi-profile-header h2{font-size:18px}
 body dialog.persi-profile-dialog .persi-profile-actions{grid-template-columns:1fr;gap:11px}
}

body dialog.persi-profile-dialog .persi-profile-review{display:flex;align-items:center;gap:10px;margin:22px 0 0;padding:0;font:500 14px/1.9 Vazirmatn,PersiColorful,Tahoma,Arial,sans-serif;color:var(--profile-ink)}
body dialog.persi-profile-dialog .persi-profile-review input[type=checkbox]{appearance:auto;display:inline-block;flex:0 0 20px;width:20px;height:20px;min-width:20px;min-height:20px;margin:0;padding:0;accent-color:var(--profile-accent);opacity:1;cursor:default;box-shadow:none}
body dialog.persi-profile-dialog .persi-profile-review span{display:block}
