/* Employer Brand Research: back-office brand layer (Brand Guidelines v1.1, October 2026).
   Served from /static/ebr/css/backoffice.css and loaded last by
   themes/ebr/templates/admin/core/base.html, on the repository site only.
   Covers the log in, registration and account pages and every manager screen.
   Colours: only the five approved values. Status colours (success, warning, alert) stay as Janeway
   has them, because they carry meaning. */

/* Type. Clear Sans is self-hosted. The back office asks for "Open Sans" in dozens of rules; the second
   set of faces below answers that name with Clear Sans, so no rule needs rewriting and nothing is
   fetched from Google. */
@font-face { font-family: "Clear Sans"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/ClearSans-Regular.woff2") format("woff2"); }
@font-face { font-family: "Clear Sans"; font-style: italic; font-weight: 400; font-display: swap;
  src: url("../fonts/ClearSans-Italic.woff2") format("woff2"); }
@font-face { font-family: "Clear Sans"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../fonts/ClearSans-Bold.woff2") format("woff2"); }
@font-face { font-family: "Clear Sans"; font-style: italic; font-weight: 700; font-display: swap;
  src: url("../fonts/ClearSans-BoldItalic.woff2") format("woff2"); }
@font-face { font-family: "Open Sans"; font-style: normal; font-weight: 300 500; font-display: swap;
  src: url("../fonts/ClearSans-Regular.woff2") format("woff2"); }
@font-face { font-family: "Open Sans"; font-style: italic; font-weight: 300 500; font-display: swap;
  src: url("../fonts/ClearSans-Italic.woff2") format("woff2"); }
@font-face { font-family: "Open Sans"; font-style: normal; font-weight: 600 800; font-display: swap;
  src: url("../fonts/ClearSans-Bold.woff2") format("woff2"); }
@font-face { font-family: "Open Sans"; font-style: italic; font-weight: 600 800; font-display: swap;
  src: url("../fonts/ClearSans-BoldItalic.woff2") format("woff2"); }

:root {
  --ebr-cobalt: #2454E6;
  --ebr-ink: #1C2433;
  --ebr-paper: #F6F7FB;
  --ebr-white: #FFFFFF;
  --ebr-citrus: #DFFF70;
  --ebr-rule: rgba(28, 36, 51, 0.14);
  --ebr-muted: rgba(28, 36, 51, 0.78);
  --ebr-font: "Clear Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  /* Janeway's own link and secondary colours */
  --clr-blue-medium: #2454E6;
  --clr-navy: #1C2433;
}

body { font-family: var(--ebr-font); color: var(--ebr-ink); background: var(--ebr-paper); font-weight: 400; }
h1, h2, h3, h4, h5, h6 { font-family: var(--ebr-font); color: var(--ebr-ink); }
a:hover, a:focus { color: var(--ebr-ink); }
a:focus-visible, .button:focus-visible { outline: 2px solid var(--ebr-cobalt); outline-offset: 2px; }

/* Top bar: the Cobalt lockup with name in place of the site name, linked to the site's home page */
.ebr-backoffice header { background: var(--ebr-white); border-bottom: 1px solid var(--ebr-rule); }
.ebr-backoffice header h1 { line-height: 0; margin: 0; padding: 8px 0; }
.ebr-backoffice header h1 a {
  display: inline-block; width: 98px; height: 44px; vertical-align: middle;
  background: url("../img/ebr-lockup-cobalt.svg") center / contain no-repeat;
  color: transparent; font-size: 0; overflow: hidden;
}
.ebr-backoffice header .profile p { color: var(--ebr-ink); }
.ebr-backoffice .avatar { background: var(--ebr-cobalt); color: var(--ebr-white); font-weight: 700; }
.ebr-backoffice header .button { color: var(--ebr-ink); background: var(--ebr-white); }

/* Sidebar: Ink, with a Cobalt title row carrying the white Reader */
.ebr-backoffice .off-canvas { background: var(--ebr-ink); }
.ebr-backoffice .off-canvas .menu > li.title > a {
  position: relative; height: 60px; padding: 0 0 0 64px; line-height: 60px; font-size: 0;
  background: var(--ebr-cobalt) url("../img/ebr-reader-white.svg") 20px center / auto 34px no-repeat;
  border-bottom: 0;
}
.ebr-backoffice .off-canvas .menu > li.title > a i { display: none; }
.ebr-backoffice .off-canvas .menu > li.title > a::after {
  content: "EBR back office"; font-size: 0.875rem; font-weight: 700; color: var(--ebr-white);
  letter-spacing: 0.02em;
}
.ebr-backoffice .off-canvas .menu > li > a {
  color: rgba(255, 255, 255, 0.82); font-weight: 400; border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.ebr-backoffice .off-canvas .menu > li > a:hover,
.ebr-backoffice .off-canvas .menu > li > a:focus {
  background: rgba(255, 255, 255, 0.06); color: var(--ebr-white); box-shadow: inset 3px 0 0 var(--ebr-cobalt);
}
.ebr-backoffice .off-canvas .menu > li.subtitle > a {
  color: rgba(255, 255, 255, 0.62); font-weight: 700; font-size: 0.75rem;
}
.ebr-backoffice .off-canvas .close-button { color: var(--ebr-white); }

/* Page titles */
.ebr-backoffice .title h1 { color: var(--ebr-ink); font-weight: 700; }
.ebr-backoffice .title p { color: var(--ebr-muted); font-weight: 400; }
.ebr-backoffice .breadcrumbs a { color: var(--ebr-cobalt); }

/* Buttons: Cobalt with White text, square corners, as on the public site; Ink on hover.
   Success, warning and alert keep Janeway's colours, because they carry meaning. */
.ebr-backoffice .button { border-radius: 0; font-weight: 700; }
.ebr-backoffice .button:not(.success):not(.warning):not(.alert):not(.hollow):not(.clear):not(.orcid-button) {
  background-color: var(--ebr-cobalt); color: var(--ebr-white);
}
.ebr-backoffice .button:not(.success):not(.warning):not(.alert):not(.hollow):not(.clear):not(.orcid-button):hover,
.ebr-backoffice .button:not(.success):not(.warning):not(.alert):not(.hollow):not(.clear):not(.orcid-button):focus {
  background-color: var(--ebr-ink); color: var(--ebr-white);
}
.ebr-backoffice header .button[data-toggle="offCanvas"] { background: var(--ebr-white); color: var(--ebr-ink); font-weight: 400; }

/* Forms and panels */
.ebr-backoffice input[type="text"], .ebr-backoffice input[type="email"], .ebr-backoffice input[type="password"],
.ebr-backoffice input[type="search"], .ebr-backoffice input[type="url"], .ebr-backoffice select, .ebr-backoffice textarea {
  border-color: var(--ebr-rule); box-shadow: none; color: var(--ebr-ink); border-radius: 0;
}
.ebr-backoffice input:focus, .ebr-backoffice select:focus, .ebr-backoffice textarea:focus {
  border-color: var(--ebr-cobalt); box-shadow: 0 0 0 1px var(--ebr-cobalt);
}
.ebr-backoffice .card, .ebr-backoffice .box { border-radius: 0; box-shadow: none; border: 1px solid var(--ebr-rule); }

/* Signed out (log in, registration, password reset): no empty sidebar, content centred */
.ebr-signed-out .off-canvas.position-left { display: none; }
.ebr-signed-out .off-canvas-content { margin-left: 0 !important; }
.ebr-signed-out header .button[data-toggle="offCanvas"] { display: none; }
.ebr-signed-out .title h1 { text-align: center; }

/* The repository's Login text, above the log in and registration forms */
.ebr-login-text { padding: 0 0 0.5rem; }
.ebr-login-text .row {
  width: 100%; max-width: min(calc(100vw - (2 * var(--small-inline-margin, 1rem))), 24rem); margin: 0 auto; background: var(--ebr-white); border: 1px solid var(--ebr-rule);
  border-left: 3px solid var(--ebr-cobalt); padding: 1rem 1.25rem;
}
.ebr-login-text--core_register .row { max-width: min(calc(100vw - (2 * var(--small-inline-margin, 1rem))), 56rem); }
.ebr-login-text p { margin: 0 0 0.5rem; font-size: 1rem; line-height: 1.5; color: var(--ebr-ink); }
.ebr-login-text p:last-child { margin-bottom: 0; }
