/* Earkart override: readable email bodies in dark mode.
 * Incoming emails are rendered by vue-letter with the sender's inline styles
 * intact (Outlook signatures set color:#000 / black). The dark theme does not
 * touch those, so text disappears on the dark bubble. Served by nginx at
 * /custom/earkart.css and injected into index.html via sub_filter.
 * Scope: only the .native-html email body, only in .dark. Agent-side UI untouched. */

.dark .native-html,
.dark .native-html * {
  color: hsl(var(--foreground)) !important;
  background-color: transparent !important;
  border-color: hsl(var(--border)) !important;
}

/* keep links, mentions and quoted text distinguishable */
.dark .native-html a                     { color: hsl(var(--link)) !important; text-decoration: underline; }
.dark .native-html [class$="_ld-mention"],
.dark .native-html .ld-mention           { color: hsl(var(--primary)) !important; background-color: hsl(var(--primary) / 0.12) !important; }
.dark .native-html blockquote            { color: hsl(var(--muted-foreground)) !important; border-left: 3px solid hsl(var(--border)) !important; padding-left: .75rem; }
.dark .native-html hr                    { border-color: hsl(var(--border)) !important; }

/* tables from Outlook/Gmail */
.dark .native-html table,
.dark .native-html td,
.dark .native-html th                    { background-color: transparent !important; border-color: hsl(var(--border)) !important; }

/* images: don't invert, but stop white signature boxes glaring */
.dark .native-html img                   { background-color: transparent !important; }
