/* ===================================================================
   IT.jo brand theme for Tactical RMM (Quasar)
   Design intent: this should read as an IT.jo product, not a
   re-colored default dashboard. Flat surfaces over heavy Material
   shadows, Manrope type, generous radius, brand gradient as the one
   accent move (header + login) rather than everywhere.
   =================================================================== */

@font-face { font-family:'Manrope'; font-style:normal; font-weight:400; font-display:swap; src:url(/fonts/manrope-400.ttf) format('truetype'); }
@font-face { font-family:'Manrope'; font-style:normal; font-weight:500; font-display:swap; src:url(/fonts/manrope-500.ttf) format('truetype'); }
@font-face { font-family:'Manrope'; font-style:normal; font-weight:600; font-display:swap; src:url(/fonts/manrope-600.ttf) format('truetype'); }
@font-face { font-family:'Manrope'; font-style:normal; font-weight:700; font-display:swap; src:url(/fonts/manrope-700.ttf) format('truetype'); }
@font-face { font-family:'Manrope'; font-style:normal; font-weight:800; font-display:swap; src:url(/fonts/manrope-800.ttf) format('truetype'); }

:root {
  /* Quasar theme hooks */
  --q-primary: #1554FA;
  --q-secondary: #6963FC;
  --q-dark: #050E21;
  --q-dark-page: #0C1730;

  /* IT.jo palette (from it.jo/assets/css/itjo.css) */
  --it-brand: #1554FA;
  --it-brand-2: #6963FC;
  --it-ink: #050E21;
  --it-ink-2: #0C1730;
  --it-ink-3: #1E2A48;
  --it-line: #E1E6F0;
  --it-muted: #5A6478;
  --it-muted-dark: #98A3BC;
  --it-paper: #FFFFFF;
  --it-paper-2: #F4F6FB;
  --it-radius: 10px;
}

html, body, #q-app {
  font-family: 'Manrope', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
}

a { color: var(--it-brand); }
::selection { background: var(--it-brand); color: #fff; }

/* thin, brand-tinted scrollbar instead of generic white */
::-webkit-scrollbar-thumb { background-color: #6b7aa6a6 !important; }
::-webkit-scrollbar-thumb:hover { background-color: var(--it-brand-2) !important; }

/* ---- Typography: give headings real weight (Manrope reads thin below 600) ---- */
.text-h1, .text-h2, .text-h3, .text-h4, .text-h5 { font-weight: 800 !important; letter-spacing: -.01em; }
.text-h6 { font-weight: 700 !important; }
.q-btn, .q-item__label, .q-table th { font-weight: 600; }

/* ---- Buttons: drop Material all-caps + heavy shadow, brand radius ---- */
.q-btn { text-transform: none !important; border-radius: calc(var(--it-radius) - 2px) !important; letter-spacing: normal; }
.q-btn.q-btn--standard { box-shadow: none !important; }
.q-btn--unelevated.bg-primary, .q-btn--unelevated.text-primary {
  background-image: linear-gradient(135deg, var(--it-brand) 0%, var(--it-brand-2) 150%) !important;
}

/* ---- Cards / menus / dialogs: flat surface + 1px line instead of Material elevation ---- */
.q-card, .q-menu, .q-dialog__inner > div {
  border-radius: var(--it-radius) !important;
  box-shadow: 0 1px 2px rgba(5,14,33,.06), 0 1px 0 rgba(5,14,33,.04) !important;
}
.body--light .q-card, .body--light .q-menu, .body--light .q-dialog__inner > div {
  border: 1px solid var(--it-line);
}
.body--dark .q-card, .body--dark .q-menu, .body--dark .q-dialog__inner > div {
  background: var(--it-ink-2) !important;
  border: 1px solid #ffffff14;
}

/* ---- Page background per theme ---- */
.body--light { background: var(--it-paper-2); }
.body--dark { background: var(--it-ink) !important; }

/* ---- Tables: calmer header, no harsh black border ---- */
.body--light .q-table__card, .body--light .q-table thead { background: var(--it-paper-2) !important; }
.body--dark .q-table__card { background: var(--it-ink-2) !important; }
.q-table thead th { font-weight: 700; }

/* ---- Sidebar / drawer: modern pill nav instead of flat Material list ----
   Quasar QDrawer always renders as <aside class="q-drawer ...">; target the
   tag directly too so this wins regardless of which app-level class/specificity
   the drawer content wrapper happens to carry. */
body.body--dark aside.q-drawer,
body.body--dark aside.q-drawer .q-drawer__content {
  background: linear-gradient(180deg, var(--it-ink) 0%, var(--it-ink-2) 100%) !important;
  border-right: 1px solid #ffffff14;
}
body.body--light aside.q-drawer,
body.body--light aside.q-drawer .q-drawer__content {
  background: var(--it-paper) !important;
  border-right: 1px solid var(--it-line);
}

.q-drawer .q-item {
  margin: 2px 10px;
  border-radius: 8px;
  min-height: 42px;
  transition: background-color .15s ease, color .15s ease;
}
.q-drawer .q-item:hover:not(.q-item--active) {
  background: rgba(21,84,250,.08);
}
.q-drawer .q-item--active,
.q-drawer .q-item.q-router-link--active {
  color: var(--it-brand) !important;
  background: rgba(21,84,250,.12) !important;
  font-weight: 700;
  box-shadow: inset 3px 0 0 var(--it-brand);
}
.body--dark .q-drawer .q-item--active,
.body--dark .q-drawer .q-item.q-router-link--active {
  background: rgba(105,99,252,.16) !important;
}
.q-drawer .q-item__section--avatar {
  color: inherit;
  min-width: 40px;
}

/* ---- Header + terminal toolbar (hardcoded bg-grey-9 #424242!important in the app) ---- */
.bg-grey-9 {
  background: linear-gradient(90deg, var(--it-ink) 0%, var(--it-ink-2) 55%, var(--it-brand) 160%) !important;
  border-bottom: 2px solid var(--it-brand-2);
}

/* ---- Login page ---- */
.bg-image {
  background: linear-gradient(135deg, var(--it-ink) 0%, var(--it-ink-2) 55%, var(--it-brand) 150%) !important;
}
.bg-image .q-card, .bg-image .q-card.q-card--dark {
  background: var(--it-paper) !important;
  border: none;
}
.bg-image .text-center.q-pt-lg {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.bg-image .text-center.q-pt-lg::before {
  content: "";
  display: block;
  width: 200px;
  height: 89px;
  background-image: url('/images/itjo-logo.png');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}
.bg-image .text-h4.ellipsis {
  font-size: 1.05rem;
  font-weight: 700 !important;
  letter-spacing: .5px;
  color: var(--it-ink) !important;
  opacity: .7;
}

/* ---- "FileBar" menu (File/View/Agents/Settings/Tools/Reporting/Help)
   and the client-tree panel: these sit directly on the plain page bg with
   no brand treatment of their own (Quasar q-toolbar / q-splitter have no
   default background), which is exactly why they still read as "default
   product white", not IT.jo. ---- */
body.body--light .q-toolbar {
  background: var(--it-paper-2) !important;
  border-bottom: 1px solid var(--it-line);
}
body.body--dark .q-toolbar {
  background: var(--it-ink-2) !important;
  border-bottom: 1px solid #ffffff14;
}
/* the main header (bg-grey-9) has its own toolbar nested inside it -
   don't let the generic rule above paint over the header's brand gradient */
.bg-grey-9 .q-toolbar {
  background: transparent !important;
  border-bottom: none !important;
}

body.body--light .q-splitter__before {
  background: var(--it-paper-2) !important;
  border-right: 1px solid var(--it-line);
}
body.body--dark .q-splitter__before {
  background: var(--it-ink-2) !important;
  border-right: 1px solid #ffffff14;
}
.q-splitter__separator { background-color: var(--it-line) !important; }
body.body--dark .q-splitter__separator { background-color: #ffffff1f !important; }

/* client tree: brand-tint active/home + hover, same pill language as the drawer */
.q-splitter__before .q-item {
  border-radius: 8px;
  margin: 1px 6px;
}
.q-splitter__before .q-item--active {
  background: rgba(21,84,250,.12) !important;
  color: var(--it-brand) !important;
  font-weight: 700;
}
.q-splitter__before .q-item:hover:not(.q-item--active) {
  background: rgba(21,84,250,.07);
}

/* ---- 2026-11-16: sign-in card is forced white above, so the dark-theme fields
   (white text on a translucent white fill) were invisible. Give every field,
   label and text inside the sign-in card light-surface colours, and size the
   card sensibly instead of the app's inline width:30%. ---- */
.bg-image .q-card, .bg-image .q-card.q-card--dark {
  color: var(--it-ink) !important;
  width: min(92vw, 420px) !important;
}
.bg-image .q-card .q-field__control {
  background: var(--it-paper-2) !important;
  color: var(--it-brand) !important;
  border-radius: 8px 8px 0 0;
}
.bg-image .q-card .q-field__control:before {
  background: transparent !important;
  border-bottom: 1px solid rgba(5,14,33,.35) !important;
}
.bg-image .q-card .q-field__control:hover:before { border-bottom-color: var(--it-ink) !important; }
.bg-image .q-card .q-field__native,
.bg-image .q-card .q-field__input,
.bg-image .q-card .q-field__prefix,
.bg-image .q-card .q-field__suffix { color: var(--it-ink) !important; caret-color: var(--it-brand); }
.bg-image .q-card .q-field__label,
.bg-image .q-card .q-field__marginal,
.bg-image .q-card .q-field__bottom,
.bg-image .q-card .q-field__messages { color: var(--it-muted) !important; }
.bg-image .q-card .q-field--focused .q-field__label { color: var(--it-brand) !important; }
.bg-image .q-card .q-field--error .q-field__label,
.bg-image .q-card .q-field--error .q-field__bottom,
.bg-image .q-card .q-field--error .q-field__messages { color: #C10015 !important; }
.bg-image .q-card .q-card__section, .bg-image .q-card .text-subtitle1, .bg-image .q-card .text-subtitle2, .bg-image .q-card p { color: var(--it-ink); }
.bg-image .q-card input:-webkit-autofill { -webkit-text-fill-color: var(--it-ink) !important; box-shadow: 0 0 0 40px var(--it-paper-2) inset !important; }
