:root {
  --bg-void: #f6f8fc;
  --surface: #ffffff;
  --surface-2: #eef2f8;
  --border: #d6deea;
  --text-primary: #1e2a3a;
  --text-secondary: #5b6b82;
  --accent-indigo: #4e63d8;
  --accent-lavender: #6e78e8;
  --accent-cyan: #0b8fb0;
}

html.dark-mode {
  --bg-void: #0a0a0f;
  --surface: #12121a;
  --surface-2: #0f0f17;
  --border: #1e1e2e;
  --text-primary: #e4e4ef;
  --text-secondary: #8888a0;
  --accent-indigo: #6366f1;
  --accent-lavender: #a78bfa;
  --accent-cyan: #06b6d4;
}

html,
body {
  background: var(--bg-void) !important;
  color: var(--text-primary) !important;
  scrollbar-color: var(--accent-indigo) var(--surface-2) !important;
}

::-webkit-scrollbar {
  width: 10px !important;
  height: 10px !important;
}

::-webkit-scrollbar-track {
  background: var(--surface-2) !important;
}

::-webkit-scrollbar-thumb {
  background: var(--accent-indigo) !important;
  border-radius: 8px !important;
  border: 2px solid var(--surface-2) !important;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-lavender) !important;
}

#layout-menu a.active,
#taskmenu a.selected,
#topnav a.active,
a:hover,
a:focus {
  color: var(--text-primary) !important;
  background-color: color-mix(in srgb, var(--accent-indigo) 20%, transparent) !important;
}

.listing tr.selected td,
.listing li.selected,
.messagelist tr.selected td,
.folderlist li.selected > a {
  background: color-mix(in srgb, var(--accent-indigo) 24%, transparent) !important;
  color: var(--text-primary) !important;
}

.listing tbody tr:hover,
#messagelist tbody tr:hover,
#folderlist-content li:hover {
  background: color-mix(in srgb, var(--accent-indigo) 14%, transparent) !important;
}

.listing.iconized tr td:before,
.listing.iconized li > i:before,
.messagelist td.subject span.msgicon.status:before,
.messagelist span.flagged:before {
  color: var(--accent-indigo) !important;
}

.messagelist tr.selected td.subject span.msgicon.status:before,
.messagelist tr.selected span.flagged:before {
  color: var(--accent-lavender) !important;
}

#logo {
  content: url('/skins/otheru/images/otheru-logo.svg') !important;
  width: 128px !important;
  height: 128px !important;
  object-fit: contain !important;
}

html.dark-mode .message-htmlpart {
  background: var(--surface-2) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--border) !important;
  border-radius: 8px !important;
  padding: 0.5rem !important;
}

html.dark-mode #messagepartframe {
  background: var(--surface-2) !important;
}

html.dark-mode.email-force-dark .message-htmlpart,
html.dark-mode .email-force-dark .message-htmlpart {
  background: #11161c !important;
  color: #e8edf5 !important;
}

html.dark-mode.email-force-dark .message-htmlpart *:not(img):not(svg):not(video):not(canvas):not(path):not(i),
html.dark-mode .email-force-dark .message-htmlpart *:not(img):not(svg):not(video):not(canvas):not(path):not(i) {
  background-color: transparent !important;
  color: #e8edf5 !important;
  border-color: #304050 !important;
}

html.dark-mode.email-force-dark .message-htmlpart a,
html.dark-mode .email-force-dark .message-htmlpart a {
  color: #8cc8ff !important;
}

html.dark-mode.email-force-dark .message-htmlpart blockquote,
html.dark-mode .email-force-dark .message-htmlpart blockquote {
  background: #151d26 !important;
  color: #b9d2ea !important;
  border-left-color: #5b87b3 !important;
}
