/* Theme is a display preference. The current workspace remains the default. */
.theme-toggle,
.dam-shell .dam-topbar-actions > .theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  padding: 10px;
  flex: 0 0 44px;
  border: 1px solid #414936;
  border-radius: 8px;
  color: #d9d8bd;
  background: #1c2118;
  font-size: 12px;
  line-height: 1.5;
  white-space: nowrap;
}
.theme-toggle:hover,
.dam-shell .dam-topbar-actions > .theme-toggle:hover {
  color: #f1d187;
  background: #2b3122;
  border-color: #857347;
}
.theme-toggle:focus-visible {
  outline: 2px solid #a88330;
  outline-offset: 3px;
}
.theme-toggle > :is(.theme-icon-light, .theme-icon-dark) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.theme-toggle svg { display: block; width: 20px; height: 20px; }
.theme-toggle [data-theme-label] { display: none; }
.theme-toggle > .theme-icon-dark { display: none; }
.login-theme-controls { display: flex; justify-content: flex-end; margin: -12px -12px 20px 0; }

/* Off-white canvas, white surfaces and a dark navigation rail match the DIME reference. */
:root[data-theme="light"] {
  color-scheme: light;
  color: #263238;
  background: #f6f6f3;
  --theme-page: #f6f6f3;
  --theme-surface: #ffffff;
  --theme-raised: #f0f3eb;
  --theme-text: #263238;
  --theme-muted: #68716c;
  --theme-line: #dce1d7;
  --theme-accent: #805b15;
  --theme-gold-soft: #f7edce;
  --theme-sage: #f3f6ee;
  --theme-sage-text: #526340;
  --muted: var(--theme-muted);
  --line: var(--theme-line);
  --panel: var(--theme-surface);
  --border: var(--theme-line);
  --text: var(--theme-text);
  --green: #3d7250;
}
:root[data-theme="light"] body { background: var(--theme-page); color: var(--theme-text); }
:root[data-theme="light"] .dam-shell {
  --dam-surface: var(--theme-surface);
  --dam-raised: var(--theme-raised);
  --dam-text: var(--theme-text);
  --dam-muted: var(--theme-muted);
  background: var(--theme-page);
  color: var(--theme-text);
}
:root[data-theme="light"] .theme-toggle,
:root[data-theme="light"] .dam-shell .dam-topbar-actions > .theme-toggle {
  color: #526340;
  background: #f4f6ef;
  border-color: #d6dfc7;
}
:root[data-theme="light"] .theme-toggle:hover,
:root[data-theme="light"] .dam-shell .dam-topbar-actions > .theme-toggle:hover {
  color: #35432a;
  background: #eaf0df;
  border-color: #97a582;
}
:root[data-theme="light"] .theme-toggle > .theme-icon-light { display: none; }
:root[data-theme="light"] .theme-toggle > .theme-icon-dark { display: inline-flex; }

/* Sidebar tokens stay dark so navigation and identity never inherit light-page ink. */
:root[data-theme="light"] :is(.dam-sidebar, .sidebar) {
  --muted: #afb2a7;
  --line: #3e4039;
  --panel: #292b26;
  --text: #eeeae1;
  --dam-text: #eeeae1;
  --dam-muted: #afb2a7;
  --dam-surface: #292b26;
  --dam-raised: #32352d;
  color: #eeeae1;
  background: #242523;
  border-color: #3e4039;
  scrollbar-color: #55584e transparent;
}
:root[data-theme="light"] .dam-scope { background: #2a2c27; border-color: #42443b; }
:root[data-theme="light"] .dam-scope .avatar { background: #403926; color: #e6bd62; }
:root[data-theme="light"] .dam-brand :is(span, .brand-space) { color: #c8c9bf; }
:root[data-theme="light"] .dam-nav :is(a, button) { color: #bcc0b5; }
:root[data-theme="light"] .dam-nav :is(a, button):hover { background: #33362e; color: #f0efe5; }
:root[data-theme="light"] .dam-nav :is(.active, .is-active, [aria-current="page"]),
:root[data-theme="light"] .dam-nav :is(.active, .is-active, [aria-current="page"]):hover {
  color: #302912;
  background: #ebd99f;
  border-color: #ebd99f;
}
:root[data-theme="light"] .dam-nav .counter,
:root[data-theme="light"] .dam-sidebar .dam-count { background: #49422c; color: #efd99b; }
:root[data-theme="light"] .dam-nav :is(.active, [aria-current="page"]) :is(.counter, .dam-count) {
  background: #dcc47f;
  color: #3d3216;
}
:root[data-theme="light"] :is(.dam-folder-disclosure, .dam-management) > summary { background: #242523; color: #aeb4a4; }
:root[data-theme="light"] :is(.dam-folder-disclosure, .dam-management) > summary:hover { background: #33362e; color: #f0efe5; }
:root[data-theme="light"] .dam-folder-row { color: #bcc2b0; }
:root[data-theme="light"] .dam-folder-row:hover { background: #33362e; color: #f0efe5; }
:root[data-theme="light"] .dam-folder-row:is(.is-selected, .active, .is-active),
:root[data-theme="light"] .dam-folder-row :is(.active, [aria-current="page"]) {
  background: #393e31;
  color: #f1e8c6;
  border-color: #565e46;
}
:root[data-theme="light"] .dam-folder-toggle:hover,
:root[data-theme="light"] .dam-tree-toggle:hover { background: #464d3b; color: #f0efe5; }
:root[data-theme="light"] .dam-sidebar-footer strong { color: #e0e3d7; }
:root[data-theme="light"] .dam-sidebar-footer small { color: #afb8a3; }

/* Workspace chrome and controls. Native media and rendered mailer content are untouched. */
:root[data-theme="light"] .dam-main :is(.dam-topbar, .topbar) { background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] .dam-topbar-title { color: #45504b; }
:root[data-theme="light"] .dam-topbar-scope { color: var(--theme-muted); border-color: var(--theme-line); }
:root[data-theme="light"] .dam-shell .dam-topbar-actions .dam-private {
  background: var(--theme-sage);
  color: var(--theme-sage-text);
  border-color: #d6dfc7;
}
:root[data-theme="light"] .dam-demo-switch { color: var(--theme-muted); }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) :is(input, select, textarea),
:root[data-theme="light"] #modal .modal-body .field :is(input, select, textarea),
:root[data-theme="light"] .dam-shell .mg-page :is(.mg-search input, .mg-filter select),
:root[data-theme="light"] .home-settings-panel :is(input, textarea) {
  color: var(--theme-text);
  background: #ffffff;
  border-color: #cfd7cd;
  color-scheme: light;
}
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) :is(input, textarea)::placeholder,
:root[data-theme="light"] .dam-shell .mg-search input::placeholder { color: #79847c; opacity: 1; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) :is(input, select, textarea):focus { border-color: #aa853d; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) :is(input, select, textarea):disabled { background: #f1f3ef; color: #7b847a; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) .btn {
  background: #ffffff;
  border-color: #cfd7c7;
  color: #37432d;
}
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) .btn:hover { background: #edf2e5; border-color: #a7b596; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) .btn.primary { background: #e6bd62; color: #282315; border-color: #e6bd62; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) .btn.primary:hover { background: #efd08b; border-color: #efd08b; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal, .login, .wf-join) .btn.subtle { background: #edf1e6; color: #4d6040; border-color: transparent; }
:root[data-theme="light"] .dam-main .dam-topbar-actions > button,
:root[data-theme="light"] :is(.dam-menu-toggle, .dam-icon-button) { color: #536442; background: #f5f7f0; border-color: #d5dfc8; }
:root[data-theme="light"] .dam-main .dam-topbar-actions > button:hover,
:root[data-theme="light"] :is(.dam-menu-toggle, .dam-icon-button):hover { background: #eaf0df; color: #35432a; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal) .btn.danger,
:root[data-theme="light"] .dam-shell .mg-card-actions .danger { color: #a13c2e; border-color: #d6a69a; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal) .btn.danger:hover,
:root[data-theme="light"] .dam-shell .mg-card-actions .danger:hover { background: #fff0ea; color: #8d2e22; border-color: #c38b7f; }
:root[data-theme="light"] .dam-shell :is(.small-note, .back) { color: var(--theme-muted); }
:root[data-theme="light"] :is(.dam-library-header .eyebrow, .dam-main .eyebrow, .dashboard-role, .dam-identity-label) { color: var(--theme-accent); }
:root[data-theme="light"] .dam-breadcrumbs,
:root[data-theme="light"] .dam-breadcrumbs :is(a, button, svg) { color: #737d68; }
:root[data-theme="light"] .dam-breadcrumbs [aria-current="page"] { color: #39452e; }
:root[data-theme="light"] :is(.dam-breadcrumbs a:hover, .dam-breadcrumbs button:hover, .dam-collection-body h3 a:hover) { color: var(--theme-accent); }
:root[data-theme="light"] .dam-resource { background: var(--theme-sage); color: #6d541c; border-color: #d5dfc5; }
:root[data-theme="light"] .dam-resource:hover { background: #ecf1e3; border-color: #b7c49f; color: #624611; }

/* Home, discovery and collections share quiet white surfaces. */
:root[data-theme="light"] .dashboard-identity,
:root[data-theme="light"] .dam-store-identity { background: #f0f3e9; border-color: var(--theme-line); }
:root[data-theme="light"] .dashboard-identity .dashboard-identity-facts dd,
:root[data-theme="light"] .dam-store-identity dd { color: var(--theme-text); }
:root[data-theme="light"] .dam-store-identity dt { color: var(--theme-muted); }
:root[data-theme="light"] .dashboard-identity .dashboard-identity-link,
:root[data-theme="light"] .dam-store-identity > a { color: var(--theme-accent); }
:root[data-theme="light"] .dam-shell .dashboard-overview { background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] :is(.dashboard-metric-value, .dashboard-task-heading h2, .dashboard-task-title) { color: var(--theme-text); }
:root[data-theme="light"] :is(.dashboard-metric-icon, .dashboard-task-icon) { color: #806727; }
:root[data-theme="light"] .dashboard-metric-icon { background: #f3eddc; }
:root[data-theme="light"] .dashboard-task { background: #f8faf5; border-color: #e0e5d8; }
:root[data-theme="light"] .dashboard-task:hover { background: #eef3e5; border-color: #b7c69f; }
:root[data-theme="light"] .dashboard-task-count { background: #f4e8c2; color: #6e5014; }
:root[data-theme="light"] .dashboard-task-arrow { color: #77846a; }
:root[data-theme="light"] .dashboard-management a,
:root[data-theme="light"] .dam-home-links a { color: #5a6849; }
:root[data-theme="light"] :is(.dashboard-management a:hover, .dam-home-links a:hover) { color: var(--theme-accent); }
:root[data-theme="light"] .dam-home-access { color: #46543c; }
:root[data-theme="light"] .dam-toolbar,
:root[data-theme="light"] .dam-shell .dam-main .mg-page .mg-toolbar { background: transparent; border: 0; }
:root[data-theme="light"] .dam-search { background: #ffffff; color: #69775f; border-color: #cfd7c5; }
:root[data-theme="light"] .dam-search input { background: transparent; color: var(--theme-text); }
:root[data-theme="light"] .dam-search input::placeholder { color: #76816d; }
:root[data-theme="light"] .dam-view-toggle { background: #ffffff; border-color: #d0d9c6; }
:root[data-theme="light"] .dam-view-toggle button { color: #76816b; }
:root[data-theme="light"] .dam-view-toggle :is(.active, [aria-pressed="true"]) { background: #e8eddc; color: #716027; }
:root[data-theme="light"] .dam-view-toggle button:hover { color: #6c541c; }
:root[data-theme="light"] .dam-toolbar .btn[aria-expanded="true"] { background: var(--theme-gold-soft); color: #6d521b; border-color: #ccb77e; }
:root[data-theme="light"] .dam-filter-row { background: var(--theme-sage); border-color: #d8e0cd; }
:root[data-theme="light"] .dam-filter-row label { color: #5d6b50; }
:root[data-theme="light"] :is(.dam-results-summary h2, .dam-results-heading h2, .dam-section-label h2, .dam-section-heading) { color: #384332; }
:root[data-theme="light"] .dam-folder-tile { background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] .dam-folder-tile:hover { background: #f6f8f1; border-color: #b2c098; }
:root[data-theme="light"] .dam-folder-tile strong { color: #37432d; }
:root[data-theme="light"] .dam-folder-tile :is(.dam-folder-icon, .folder-icon),
:root[data-theme="light"] .dam-folder-tile > svg:first-child { background: #f2eddb; color: #8a702b; }
:root[data-theme="light"] .dam-folder-tile > svg:last-child { color: #8a977d; }
.dam-main .collection-tile strong { font-size: 13px; }
.dam-main .collection-tile small { font-size: 11px; line-height: 1.5; }
:root[data-theme="light"] .collection-tile { background: var(--theme-surface); border-color: var(--theme-line); color: var(--theme-text); }
:root[data-theme="light"] .collection-tile:hover { background: #f6f8f1; border-color: #b2c098; }
:root[data-theme="light"] .collection-tile strong { color: var(--theme-text); }
:root[data-theme="light"] .collection-tile small { color: var(--theme-muted); }
:root[data-theme="light"] .collection-tile .folder-icon { background: #f2eddb; color: #8a702b; }
:root[data-theme="light"] .collection-tile .arrow { color: #68765b; }
:root[data-theme="light"] :is(.dam-asset-card, .dam-shell .dam-collection-card) { background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] .dam-asset-card:hover,
:root[data-theme="light"] .dam-collection-card:hover { border-color: #a8b792; }
:root[data-theme="light"] .dam-asset-card:is(.is-selected, [aria-selected="true"], .bt-selected) { background: #fffbf0; border-color: #b18b37; box-shadow: 0 0 0 1px #b18b37; }
:root[data-theme="light"] .dam-asset-body :is(h3, .dam-asset-title) { color: #37432e; }
:root[data-theme="light"] .dam-asset-title:hover { color: var(--theme-accent); }
:root[data-theme="light"] .dam-asset-thumb { background: #f0f2eb; border-color: var(--theme-line); }
:root[data-theme="light"] .dam-asset-thumb .pdf-preview,
:root[data-theme="light"] .dam-inspector-preview .pdf-preview { background: #f0f2eb; color: #8b7639; }
:root[data-theme="light"] .dam-asset-thumb .pdf-preview svg,
:root[data-theme="light"] .dam-file-icon { color: #927c3e; }
:root[data-theme="light"] .dam-asset-actions { border-color: var(--theme-line); }
:root[data-theme="light"] .dam-asset-actions :is(.tag, .dam-asset-tag),
:root[data-theme="light"] .dam-inspector-tags :is(.tag, span),
:root[data-theme="light"] .dam-inspector .tag { background: #eaf0de; color: #4d623b; }
:root[data-theme="light"] .dam-asset-actions :is(.download, .dam-info-button, a) { color: #647650; }
:root[data-theme="light"] .dam-asset-actions :is(.download, .dam-info-button, a):hover { background: #edf2e5; color: #6c521a; }
:root[data-theme="light"] .dam-shell .dam-collection-cover { background: #edf1e5; }
:root[data-theme="light"] .dam-collection-cover > span:first-child:not(.dam-collection-audience) { color: #839264; }
:root[data-theme="light"] .dam-collection-open { color: #5b6d45; }
:root[data-theme="light"] .dam-collection-open:hover { color: var(--theme-accent); }
:root[data-theme="light"] :is(.dam-empty, .empty) { background: #fafbf7; border-color: #c6d0b9; }
:root[data-theme="light"] :is(.dam-empty h2, .dam-empty h3, .empty h3, .dam-inspector-empty h3) { color: var(--theme-text); }
:root[data-theme="light"] :is(.dam-empty > span, .dam-empty > svg) { color: #8a966d; }
:root[data-theme="light"] .dam-empty p,
:root[data-theme="light"] .dam-inspector-empty { color: var(--theme-muted); }

/* Details, notifications and all review workflows. */
:root[data-theme="light"] .dam-inspector { background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] :is(.dam-inspector-header, .dam-inspector-meta) { border-color: var(--theme-line); }
:root[data-theme="light"] .dam-inspector-header button { color: #637650; }
:root[data-theme="light"] .dam-inspector-header button:hover { background: #edf2e5; color: #624b19; }
:root[data-theme="light"] .dam-inspector-title,
:root[data-theme="light"] .dam-inspector-meta dd { color: var(--theme-text); }
:root[data-theme="light"] :is(.dam-inspector-meta dt, .dam-inspector-section h4, .dam-inspector-section p) { color: var(--theme-muted); }
:root[data-theme="light"] .dam-inspector-preview { background: #f0f2eb; border-color: var(--theme-line); }
:root[data-theme="light"] .dam-inspector-preview > span svg { color: #927c3e; }
:root[data-theme="light"] .dam-inspector-preview .btn { color: #37432d; background: #fffffff0; border-color: #ced7c1; }
:root[data-theme="light"] .dam-inspector-preview .btn:hover { background: #edf2e5f0; color: #6d521b; }
:root[data-theme="light"] .dam-inspector-collections a { background: #f5f8ef; border-color: #d8e1cb; color: #51673d; }
:root[data-theme="light"] .dam-inspector-collections a:hover { background: #edf3e2; border-color: #b1c099; color: #6d521b; }
:root[data-theme="light"] .dam-inspector-footer { background: #f6f8f1; color: var(--theme-muted); border-color: var(--theme-line); }
:root[data-theme="light"] .dam-inspector-content,
:root[data-theme="light"] .dam-inspector-body,
:root[data-theme="light"] .dam-inspector-scroll { scrollbar-color: #b6c0aa transparent; }
:root[data-theme="light"] .dam-shell .hq-notifications > summary { background: #f6f8f0; color: #806626; border-color: #d4dec5; }
:root[data-theme="light"] .dam-shell .hq-notifications[open] > summary,
:root[data-theme="light"] .dam-shell .hq-notifications > summary:hover { background: #eaf0df; border-color: #b3c299; }
:root[data-theme="light"] .hq-notification-panel { background: #ffffff; border-color: var(--theme-line); box-shadow: 0 16px 45px #2b35231f; }
:root[data-theme="light"] .hq-notification-panel p { color: var(--theme-muted); }
:root[data-theme="light"] .hq-notification-panel nav a { background: #f8faf4; border-color: #dce4cf; color: var(--theme-text); }
:root[data-theme="light"] .hq-notification-panel nav a:hover { background: #edf3e2; border-color: #b6c698; }
:root[data-theme="light"] .hq-notification-panel nav strong { color: var(--theme-accent); }
:root[data-theme="light"] :is(.wf-record, .wf-join, .ct-inbox, .ct-submission) { background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] .wf-update { background: #f4f6ed; }
:root[data-theme="light"] .wf-update strong { color: var(--theme-accent); }
:root[data-theme="light"] :is(.ct-storage, .ct-upload-notice) { background: #faf4e6; border-color: #e4d5ab; }
:root[data-theme="light"] .ct-collection-picker legend { color: var(--theme-accent); }
:root[data-theme="light"] .ct-review-preview { background: #f5f7f0; border-color: var(--theme-line); }
:root[data-theme="light"] .ct-review-preview a { color: var(--theme-accent); }
:root[data-theme="light"] .ct-review-preview :is(.preview-large, video),
:root[data-theme="light"] .dam-inspector-preview video { background: #141414; }

/* Management pages, tables, organization records and import details. */
:root[data-theme="light"] .dam-shell .mg-stats > div { background: #ffffff; }
:root[data-theme="light"] .dam-shell .dam-main .mg-page :is(.panel, .mg-guidance, .mg-source-summary) { background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] .dam-shell .mg-guidance { background: var(--theme-sage); }
:root[data-theme="light"] .dam-shell .mg-guidance strong { color: #35432c; }
:root[data-theme="light"] .dam-shell :is(.mg-guidance p, .mg-person small, .mg-search > span, .mg-filter > span, .mg-state-header p, .mg-store-header p, .mg-locations small, .mg-organization-empty, .mg-footnote, .mg-source-summary p, .mg-permission-list p, .mg-page .field) { color: var(--theme-muted); }
:root[data-theme="light"] .dam-shell .mg-empty h2 { color: var(--theme-text); }
:root[data-theme="light"] .dam-main table,
:root[data-theme="light"] .dam-shell :is(.mg-people-table, .mg-state, .mg-store, .mg-activity) { background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] .dam-main th,
:root[data-theme="light"] .dam-shell :is(.mg-people-table th, .mg-state-header) { background: #f1f4eb; }
:root[data-theme="light"] .dam-shell .mg-people-table tr:hover { background: #f6f9ef; }
:root[data-theme="light"] .dam-shell .mg-avatar { background: #e8eddf; color: #536642; }
:root[data-theme="light"] .dam-shell :is(.mg-you, .mg-state-code) { background: var(--theme-gold-soft); color: var(--theme-accent); }
:root[data-theme="light"] .dam-shell .mg-locations > li { border-color: var(--theme-line); }
:root[data-theme="light"] .dam-shell .mg-activity p { color: #53634a; }
:root[data-theme="light"] .dam-shell :is(.mg-activity small, .mg-activity time, .mg-people-table td[data-label]:not(:first-child)::before) { color: var(--theme-muted); }
:root[data-theme="light"] .dam-shell .mg-connection-dot.is-connected { box-shadow: 0 0 0 4px #3d725014; }
:root[data-theme="light"] .dam-shell .mg-page .notice,
:root[data-theme="light"] .notice,
:root[data-theme="light"] #modal .notice { color: #56633f; background: #f1f5e8; border-color: #d5dfbd; }
:root[data-theme="light"] .notice strong { color: #715b1d; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal) .status { color: #3a6c46; background: #e4f0e3; }
:root[data-theme="light"] :is(.dam-main, .dam-inspector, #modal) .status.draft { color: #775c1d; background: #f6ebc9; }
:root[data-theme="light"] :is(.dam-main, #modal) .tag { color: #556746; background: #edf2e3; }
:root[data-theme="light"] :is(.dam-main, #modal) .legacy-tags { background: #f6f8f0; }
:root[data-theme="light"] .tag-assignment legend { color: var(--theme-accent); }

/* Dialogs live beside the app root, so they need the same light tokens explicitly. */
:root[data-theme="light"] :is(dialog, #modal, .login) { color: var(--theme-text); background: #ffffff; border-color: var(--theme-line); }
:root[data-theme="light"] .login .brand-space { color: var(--theme-muted); }
:root[data-theme="light"] .login .brand-line { background: var(--theme-line); }
:root[data-theme="light"] dialog::backdrop { background: #14201687; }
:root[data-theme="light"] #modal :is(.modal-head, .modal-footer) { background: #fafbf7; border-color: var(--theme-line); }
:root[data-theme="light"] #modal .modal-footer { box-shadow: 0 -8px 18px #2f3a2410; }
:root[data-theme="light"] #modal .modal-head button { color: var(--theme-muted); }
:root[data-theme="light"] #modal .modal-head button:hover { background: #edf2e5; color: #37432d; }
:root[data-theme="light"] .modal-body label.field,
:root[data-theme="light"] #modal .modal-body .field { color: #526049; }
:root[data-theme="light"] #modal .modal-body .small-note { color: var(--theme-muted); }
:root[data-theme="light"] :is(.error, #modal .error) { color: #a13c2e; }
:root[data-theme="light"] .au-file-picker input::file-selector-button { background: #f3f6ed; border-color: #cdd9bd; color: #4c6138; }
:root[data-theme="light"] .bt-selected-assets,
:root[data-theme="light"] .bt-modes label { background: #f8faf4; }
:root[data-theme="light"] .bt-modes label:has(input:checked) { background: #faf3df; border-color: #b18b37; }
:root[data-theme="light"] .bt-guidance { background: #faf4e3; border-color: #e0cc94; }
:root[data-theme="light"] .bt-guidance p { color: #735d23; }
:root[data-theme="light"] .bt-replace-confirm { background: #fff1e9; border-color: #d5b49d; }
:root[data-theme="light"] .bt-selection { background: #faf4e3; border-color: #dbc88e; }
:root[data-theme="light"] .dam-asset-card > .bt-asset-select { background: #f6f8f0; border-color: var(--theme-line); }
:root[data-theme="light"] .dam-asset-card > .bt-asset-select:hover { background: #eef3e3; color: #4d603c; }
:root[data-theme="light"] .dam-asset-card.bt-selected > .bt-asset-select { background: #f3e9c9; color: #775b1e; border-color: #ddc991; }
:root[data-theme="light"] .email-choices label { border-color: var(--theme-line); }
:root[data-theme="light"] .email-preview { background: #fafbf7; border-color: var(--theme-line); }

/* Keep select chevrons and text clear of the edge across page-specific styles.
   Native selects retain their keyboard, touch picker and option semantics. */
:root {
  --select-chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='m4 6 4 4 4-4' fill='none' stroke='%23c1c8b5' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
:root[data-theme="light"] {
  --select-chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='m4 6 4 4 4-4' fill='none' stroke='%23546259' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) {
  -webkit-appearance: none;
  appearance: none;
  background-image: var(--select-chevron) !important;
  background-repeat: no-repeat !important;
  background-size: 16px 16px !important;
  background-position: right 14px center !important;
  padding-inline-end: 44px !important;
}
select:not([multiple]):is(:not([size]), [size="0"], [size="1"]):dir(rtl) { background-position: left 14px center !important; }
@media (forced-colors: active) {
  select:not([multiple]):is(:not([size]), [size="0"], [size="1"]) {
    -webkit-appearance: auto;
    appearance: auto;
    background-image: none !important;
    padding-inline-end: 14px !important;
  }
}
