/* digreg.dev branding layer on top of the Elastic skin.
   The palette (accent #2b4bff, ink #0d0d10, paper #f3f0e8) is baked into
   the skin via styles/colors.less + a lessc recompile matching the real
   digreg.dev site tokens (2026-11-16 retheme) — see
   styles.min.css.bak-rebrand-20261116 / colors.less.bak-rebrand-20261116
   for the pre-retheme version, styles.bak-retheme-20261113 for the one
   before that. This file adds what the LESS build can't: webfont, a
   couple of native browser-chrome fixes Elastic leaves unstyled, the
   login/sidebar logo, and the two credit lines. */

@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wdth,wght@12..96,75..100,200..800&display=swap');

body, #layout-content, #login-form, .popupmenu, .message-list, table.list {
  font-family: 'Bricolage Grotesque', system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

::selection { background: rgba(43, 75, 255, .35); }

/* Login screen + sidebar logo (2026-11-16): real digreg.dev SVG
   wordmark, swapped light/dark via the same html.dark-mode class
   Elastic already toggles (see includes/layout.html) — inchiostro
   (dark ink) variant on light background, carta (light/cream) variant
   on dark background. */
#logo.digreg-logo-wrap {
  opacity: 1 !important; /* undo Elastic's dark-mode opacity:.8 meant for the old image logo */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
}
.digreg-logo {
  height: 46px;
  width: auto;
  display: none;
}
html:not(.dark-mode) .digreg-logo-light { display: block; }
html.dark-mode .digreg-logo-dark { display: block; }
.digreg-logo-tag {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .18em;
  color: #2b4bff;
}
/* Sidebar rail (#layout-menu) is permanently dark (@color-taskmenu-background,
   ink #0d0d10) regardless of the page's own light/dark mode — so it always
   needs the "carta" (light-text) logo variant, not the html.dark-mode toggle
   used on the login screen. */
#logo.digreg-logo-wrap-menu {
  display: flex;
  align-items: center;
  justify-content: center;
}
#logo.digreg-logo-wrap-menu .digreg-logo {
  height: 20px;
  display: none;
}
#logo.digreg-logo-wrap-menu .digreg-logo-dark {
  display: block;
}

/* Slightly softer, more rounded surfaces, echoing digreg.dev's radius scale */
#login-form,
#login-form input,
.popupmenu,
.listing tbody tr {
  border-radius: 10px;
}

/* The login submit button (#rcmloginsubmit) ships with ZERO CSS from
   Elastic — it's rendered entirely by native browser/OS button chrome
   (different radius/color than the rest of the form, most visible on
   iOS Safari). Style it explicitly so it's actually part of our design
   instead of whatever the OS defaults to. */
#rcmloginsubmit {
  appearance: none;
  -webkit-appearance: none;
  background: #2b4bff;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  font-family: 'Bricolage Grotesque', system-ui, -apple-system, sans-serif;
}
#rcmloginsubmit:hover,
#rcmloginsubmit:focus {
  background: #1f38d1;
}

/* Elastic gives every direct child <div> of #login-footer a generic
   light "info card" background (#ebeef3), meant for things like the
   OAuth button row — with no dark-mode variant. Our credit line
   inherited that unrelated card styling. Kill it; this is a plain
   footer line, not a card. */
#login-footer > .digreg-credit-login {
  background: transparent !important;
  padding: 0 !important;
  border-radius: 0 !important;
  margin-top: .75rem;
}

.digreg-credit-login {
  text-align: center;
  font-size: 12px;
  opacity: .75;
}

/* Sidebar credit — static last item in #layout-menu (see
   templates/includes/menu.html), same element on desktop rail and the
   mobile fullscreen menu overlay. */
#digreg-sidebar-credit {
  padding: .6rem .5rem calc(.6rem + env(safe-area-inset-bottom, 0px));
  text-align: center;
  font-size: 10px;
  line-height: 1.3;
  color: #dfe3ee;
  opacity: .55;
  border-top: 1px solid rgba(255, 255, 255, .08);
}
#digreg-sidebar-credit:hover {
  opacity: .85;
}
#digreg-sidebar-credit a {
  color: #2b4bff;
}

.digreg-credit a {
  color: #2b4bff;
  text-decoration: none;
}
.digreg-credit a:hover,
#digreg-sidebar-credit a:hover {
  text-decoration: underline;
}
.digreg-heart {
  color: #ff6b6b;
}
