/* One field language throughout CRM; geometry and select chevrons remain feature-owned. */
:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea){background-color:var(--field-bg);border:1px solid var(--field-line);color:var(--ink);transition:border-color .15s,background-color .15s,box-shadow .15s}
:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea):hover:not(:disabled):not([readonly]){background-color:var(--field-hover);border-color:var(--field-focus)}
:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea):focus{outline:none;border-color:var(--field-focus);box-shadow:0 0 0 3px var(--field-ring)}
:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea)::placeholder{color:var(--field-placeholder);opacity:1}
:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea)[readonly]{background-color:var(--surface-3);border-style:dashed;cursor:default}
:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea):disabled{opacity:.55;cursor:not-allowed;background-color:var(--surface-3)}
:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea)[aria-invalid=true]{border-color:var(--field-error)}
:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea)[aria-invalid=true]:focus{box-shadow:0 0 0 3px color-mix(in srgb,var(--field-error) 20%,transparent)}
:root :is(#app,#modal-root,#call-root) :is(.task-search,.mail-work-search,.mc-recipients,.mc-editor-shell,.messenger-shell .message-form){background-color:var(--field-bg);border:1px solid var(--field-line);transition:border-color .15s,background-color .15s,box-shadow .15s}
:root :is(#app,#modal-root,#call-root) :is(.task-search,.mail-work-search,.mc-recipients,.mc-editor-shell,.messenger-shell .message-form):hover{border-color:var(--field-focus)}
:root :is(#app,#modal-root,#call-root) :is(.task-search,.mail-work-search,.mc-recipients,.mc-editor-shell,.messenger-shell .message-form):focus-within{outline:none;border-color:var(--field-focus);box-shadow:0 0 0 3px var(--field-ring)}
:root :is(#app,#modal-root) .tc-field>.tc-edit:not(.tc-status-control .tc-edit){background-color:var(--field-bg);border-color:var(--field-line);transition:border-color .15s,background-color .15s,box-shadow .15s}
:root :is(#app,#modal-root) .tc-field>.tc-edit:not(.tc-status-control .tc-edit):hover{background-color:var(--field-hover);border-color:var(--field-focus);box-shadow:0 0 0 1px var(--field-focus)}
:root :is(#app,#modal-root) .tc-field>.tc-edit:not(.tc-status-control .tc-edit):focus-visible{outline:none;border-color:var(--field-focus);box-shadow:0 0 0 3px var(--field-ring)}

:root :is(#app,#modal-root) :is(.tc-label,.portal-filter-field,.task-filter-field,.field,.mc-address-field>label){color:var(--field-label)}
:root :is(#app,#modal-root) .tc-field .tc-pencil{color:var(--field-label);opacity:.7}
:root :is(#app,#modal-root) .tc-field>.tc-readonly:not(.tc-status-control .tc-readonly){background-color:var(--surface-2);border:1px dashed var(--card-section-border);border-radius:var(--r-sm)}
:root :is(#app,#modal-root) .tc-card{border-color:var(--card-section-border);box-shadow:0 3px 12px rgb(29 48 85 / 5%)}
/* Composite fields have one outline, including recipients, search and message composer. */
:root :is(#app,#modal-root) :is(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea){background-color:transparent;border-color:transparent;box-shadow:none;outline:none;color:var(--ink)}
:root :is(#app,#modal-root) :is(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea)::placeholder{color:var(--field-placeholder);opacity:1}
:root #modal-root .mc-editor:focus{box-shadow:none}
:root[data-theme=dark] :is(#app,#modal-root,#call-root) :is(input,select,textarea){color:#fff}
@media(prefers-reduced-motion:reduce){:root :is(#app,#modal-root,#call-root) :is(input:not([type=checkbox],[type=radio],[type=file],[type=hidden],[type=range],[type=button],[type=submit],[type=reset],[type=image]),select,textarea):not(.task-search input,.mail-work-search input,#mc-recipient,.messenger-shell .message-input textarea),:root :is(#app,#modal-root,#call-root) :is(.task-search,.mail-work-search,.mc-recipients,.mc-editor-shell,.messenger-shell .message-form),:root :is(#app,#modal-root) .tc-field>.tc-edit:not(.tc-status-control .tc-edit){transition:none}}

.inline-save-hint{font-size:var(--fs-xs);line-height:1.5;color:var(--muted);margin:6px 0 0}.inline-save-hint:has(+.tc-inline-actions){max-width:100%}form[data-inline-saving=true]{cursor:progress}form[data-inline-saving=true] .inline-save-hint{color:var(--accent)}
