/* Opermin Mail by CoreMail — azul grafito y ámbar sobre el tema Elastic
   (su acento propio es celeste #37beff, por eso se pisa con !important). */

/* Botones principales: Entrar, Redactar, Enviar, Guardar. */
.btn-primary,
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active,
.btn-primary.disabled,
.btn-primary:disabled,
#layout-menu a.compose,
.floating-action-buttons a.button {
  background-color: #0F6E8C !important;
  border-color: #0B566E !important;
  color: #fff !important;
}
.btn-primary:hover,
#layout-menu a.compose:hover { background-color: #0B566E !important; }

/* Enlaces y acentos. */
a, a:hover, a:focus, .link { color: #0B566E; }
.form-control:focus, .custom-select:focus, input:focus, textarea:focus, select:focus {
  border-color: #58A7BE !important;
  box-shadow: 0 0 0 .2rem rgba(15, 110, 140, .25) !important;
}
.custom-control-input:checked ~ .custom-control-label::before,
.custom-switch .custom-control-input:checked ~ .custom-control-label::before,
input.form-check-input:checked {
  background-color: #0F6E8C !important;
  border-color: #0F6E8C !important;
}

/* Menú lateral: azul grafito de la marca, ítem activo resaltado. */
#layout-menu { background-color: #0B2430 !important; }
#layout-menu .menu a,
#layout-menu .popover-header a,
#layout-menu .special-buttons a { color: #C3DCE5 !important; }
#layout-menu .menu a.selected,
#layout-menu .menu a:hover { color: #fff !important; background-color: rgba(88, 167, 190, .22) !important; }
#layout-menu #logo { padding: 10px 6px; }

/* Listas: correo seleccionado, carpeta activa y contadores de no leídos. */
.listing li.selected > a,
.listing li.selected,
table.listing tr.selected td,
table.records-table tr.selected td,
table.messagelist tr.selected td {
  background-color: #EAF4F8 !important;
  color: #062B38 !important;
}
.listing li.selected > a { border-left: 3px solid #F2A33C; }
.unreadcount, .badge-primary { background-color: #0F6E8C !important; color: #fff !important; }
table.messagelist tr.unread td span.subject a,
table.messagelist tr.unread td.subject span.subject a { color: #062B38; }

/* Login: fondo con degradado de la marca y tarjeta blanca. */
body.task-login {
  background: #071822 linear-gradient(160deg, #0B2430 0%, #0F4C5C 60%, #0F6E8C 130%) !important;
}
body.task-login #layout-content { background: transparent !important; }
body.task-login #login-form {
  background: #fff;
  border-radius: 18px;
  padding: 28px 30px 22px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, .45);
  max-width: 400px;
}
body.task-login #logo { max-width: 290px; margin-bottom: 8px; }
body.task-login #login-footer,
body.task-login #login-footer a { color: #AECBD6 !important; }

/* Pie de la pantalla de entrada: "Opermin Mail by CoreMail". */
#opermin-pie {
  position: fixed;
  left: 0; right: 0; bottom: 14px;
  text-align: center;
  font-size: 12.5px;
  letter-spacing: .06em;
  color: #9FC2CF;
  pointer-events: none;
}
#opermin-pie span { color: #F2A33C; }

/* Modo oscuro de Elastic: mismo azul. */
html.dark-mode .listing li.selected > a,
html.dark-mode table.messagelist tr.selected td {
  background-color: rgba(15, 110, 140, .32) !important;
  color: #fff !important;
}
html.dark-mode a, html.dark-mode .link { color: #8FCADC; }
html.dark-mode body.task-login #login-form { background: #0E2733; }

/* El logo siempre a color completo (Elastic lo atenúa en modo oscuro). */
html.dark-mode #logo, #logo { filter: none !important; opacity: 1 !important; }
