/* V50: each action keeps its own color under the existing raised-button finish. */
body[data-portal] :is(#v49-documents,#modal:has([data-v28-attendance-form],.v28-session)) .button[data-v28-tone],body[data-portal] .button[data-v50-tone]{--action-color:var(--v28-tone)!important}
body[data-portal] :is([data-v35-form="delete-report"],[data-v35-form="delete-message"]) [type="submit"]{--action-color:#ae2943!important}
body[data-portal] :is([data-v35-form="delete-report"],[data-v35-form="delete-message"]) [data-action="close-modal"]{--action-color:#566775!important}
body[data-portal] :is(#v35-team,#modal) .v38-wf-button{--action-color:var(--v38-wf-color)!important}
body[data-portal] :is(#v35-team,#modal) .v38-wf-remove{--v38-wf-color:#ae2943;--v38-wf-hover:#c13d54}
body[data-portal] :is(#v35-team,#modal) .v38-wf-neutral{--v38-wf-color:#566775;--v38-wf-hover:#6b7d8c}
body[data-portal] #v35-team [data-action="delete-team-group"],body[data-portal] #v35-team [data-action="remove-team-member"]{--action-color:#ae2943!important}
body[data-portal] .button[class*="v50-action-"]{--action-color:var(--v50-action,#486476)!important;--v28-tone:var(--v50-action,#486476)!important;background-color:var(--v50-action,#486476)!important;background-image:linear-gradient(180deg,#ffffff40,#ffffff10 27%,transparent 45%,#00000025)!important;color:#fff!important;border-color:#a8c0d8!important;text-shadow:0 1px 1px #0002;box-shadow:0 3px 6px #17374724,inset 0 1px 0 #ffffff60,inset 0 -2px 0 #00000020!important}
body[data-portal] .v50-action-new-folder{--v50-action:#177263}
body[data-portal] .v50-action-files,body[data-portal] .v50-action-save,body[data-portal] .v50-action-create{--v50-action:#267443}
body[data-portal] .v50-action-directory{--v50-action:#515b9c}
body[data-portal] .v50-action-rename,body[data-portal] .v50-action-edit{--v50-action:#946521}
body[data-portal] .v50-action-move{--v50-action:#714694}
body[data-portal] .v50-action-delete{--v50-action:#ae2943}
body[data-portal] .v50-action-cancel{--v50-action:#566775}
body[data-portal] .v50-action-download{--v50-action:#2d69a7}
body[data-portal] .v50-action-refresh{--v50-action:#765340}
body[data-portal] .v50-action-search{--v50-action:#147b90}
body[data-portal] .v50-action-presence{--v50-action:#147761}
body[data-portal] .v50-action-link{--v50-action:#74469a}
body[data-portal] .v50-action-documents{--v50-action:#2e68a6}
body[data-portal] .v50-action-export{--v50-action:#a25322}
body[data-portal] .v50-action-calendar{--v50-action:#505c9b}
body[data-portal] .v50-action-cancel-upload{--v50-action:#8b4b72}
/* Breadcrumbs are navigation, with unobtrusive focusable labels. */
body[data-portal] #v49-documents .v49-doc-crumbs .button{background:none!important;background-image:none!important;color:#42636d!important;border:0!important;box-shadow:none!important;text-shadow:none!important;border-radius:5px!important;min-height:28px!important;padding:4px 7px!important;font-size:12px!important;line-height:1.4}
body[data-portal] #v49-documents .v49-doc-crumbs .button:last-child{color:#195d4e!important}
.v49-doc-menu>div{z-index:10050;box-sizing:border-box;overflow-y:auto;overscroll-behavior:contain}
body[data-portal] #v49-documents .v49-doc-menu .button{white-space:normal!important;width:100%;min-height:42px!important;text-align:center}
.v49-doc-form-actions{position:sticky;bottom:-1px;z-index:3;padding:16px 0 4px;background:#f4f8fa;border-top:1px solid #d3e0e5;flex-wrap:wrap}
.v50-doc-form{min-width:0}
body[data-portal] #modal:has(.v50-doc-form) .modal-body{max-height:calc(90dvh - 130px);overflow-y:auto;padding-bottom:0}
body[data-portal] #modal:has(.v50-doc-form){max-height:94dvh}
@supports not (height:100dvh){body[data-portal] #modal:has(.v50-doc-form) .modal-body{max-height:calc(90vh - 130px)}body[data-portal] #modal:has(.v50-doc-form){max-height:94vh}}
@media(max-width:600px){.v49-doc-form-actions .button{min-width:100px}.v49-doc-menu>div{min-width:0}.v49-doc-heading{gap:12px}.v49-doc-heading .v49-doc-button{flex:none}}
/* V51: explicit catalog actions and the embedded, existing client directory. */
body[data-portal] .button[data-v51-tone],body[data-portal] #v35-team [data-v35-tab="clients"] .button[data-v28-tone]{--button-color:var(--v28-tone)!important;--action-color:var(--v28-tone)!important;background-color:var(--v28-tone)!important}
body[data-portal] #v35-team [data-v35-tab="clients"] .toolbar{display:flex;flex-wrap:wrap;gap:10px}
/* Equal columns keep the last row compact at intermediate window widths. */
#v35-team{container-name:activity;container-type:inline-size}
#v35-team .v35-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px;overflow:visible;align-items:stretch}
#v35-team .v35-tabs .v36-tab{width:100%;min-width:0;min-height:52px;white-space:normal;overflow-wrap:anywhere;line-height:1.35;padding:11px 8px;font-size:14px}
#v35-team .v35-tabs .v36-tab:focus-visible{outline:2px solid #28644e;outline-offset:2px}
@container activity (min-width:700px){#v35-team .v35-tabs{grid-template-columns:repeat(6,minmax(0,1fr))}#v35-team .v35-tabs .v36-tab{font-size:15px;padding:12px 10px}}
@container activity (min-width:1450px){#v35-team .v35-tabs{grid-template-columns:repeat(var(--v51-tab-count,11),minmax(0,1fr))}}
@supports not (container-type:inline-size){@media(min-width:1100px){#v35-team .v35-tabs{grid-template-columns:repeat(6,minmax(0,1fr))}}@media(min-width:1850px){#v35-team .v35-tabs{grid-template-columns:repeat(var(--v51-tab-count,11),minmax(0,1fr))}}}

/* V51 team cards: details is violet; editing retains its gold action. */
body[data-portal] #v35-team [data-v35-action="person-details"]{--action-color:#714694!important;--action-ink:#fff}
