/* ============================================================================
   CloudHQ brand theme — additive override layer over Minton (style.css)
   Loaded AFTER style.css on every page. Reversible: remove the <link>/<script>
   and the base Minton theme returns untouched.

   Brand palette source: cloudhq.com theme tokens + official brand kit.
     orange  #ff9000  (primary accent; BLACK text on orange, per brand)
     blue    #0089ff  (secondary accent)
     neutrals: #000 / #1c1c1c / #4A5568 / #718096 / #dedede / #f8f8f8 / #fff
     fonts:  Lato (headings/strong) + Source Sans Pro (body)

   Light is the base; dark applies via prefers-color-scheme (system default)
   and is forced by [data-theme]. The theme-chq.js toggle sets data-theme.
   ============================================================================ */

/* ---- Vendored brand fonts (local, no runtime CDN) ----------------------- */
@font-face {
  font-family: 'Source Sans Pro';
  src: url('../fonts/SourceSansPro-Regular.ttf') format('truetype');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Lato';
  src: url('../fonts/Lato-Bold.ttf') format('truetype');
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Lato';
  src: url('../fonts/Lato-Black.ttf') format('truetype');
  font-weight: 900; font-style: normal; font-display: swap;
}

/* ---- Design tokens ------------------------------------------------------ */
:root {
  /* brand (mode-independent) */
  --chq-orange:      #ff9000;
  --chq-orange-700:  #e07f00;
  --chq-orange-text: #000000;   /* text that sits on orange */
  --chq-blue:        #0089ff;
  --chq-blue-700:    #0070d1;

  /* semantic — LIGHT (default) */
  --surface-0: #f4f5f7;   /* app background            */
  --surface-1: #ffffff;   /* cards / panels / chrome   */
  --surface-2: #eef0f3;   /* subtle fills / hover rows */
  --chrome-bg:   #ffffff; /* topbar + sidebar          */
  --chrome-bd:   #e2e5ea; /* chrome divider            */
  --text:        #1c1c1c;
  --text-muted:  #5b6470;
  --text-faint:  #8a93a0;
  --border:      #dde1e7;
  --link:        var(--chq-orange);
  --link-hover:  var(--chq-blue);
  --nav-fg:      #4a5568; /* sidebar/topbar item text  */
  --nav-fg-hi:   #1c1c1c; /* hovered/active item text  */
  --nav-active-bg: rgba(255,144,0,0.12);
  --input-bg:    #ffffff;
  --code-bg:     #edeff2;  /* code / pre blocks */
  --code-fg:     #243040;
  --code-bd:     #dfe3e8;
  --shadow:      0 1px 2px rgba(16,24,40,.06), 0 1px 3px rgba(16,24,40,.10);

  --font-body: 'Source Sans Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-head: 'Lato', var(--font-body);

  color-scheme: light;
}

/* Dark palette — single source of truth. theme-chq.js resolves 'system' to
   the OS preference and always sets data-theme, so this one block covers both
   the explicit-dark toggle and system-dark — no media-query duplicate to
   drift out of sync (that drift previously dropped --code-* in system-dark). */
:root[data-theme="dark"] {
  --surface-0: #141617;
  --surface-1: #1c1c1c;
  --surface-2: #26292b;
  --chrome-bg:   #000000;
  --chrome-bd:   #2a2d30;
  --text:        #e7e9ec;
  --text-muted:  #a7b0bb;
  --text-faint:  #767f8a;
  --border:      #2d3136;
  --nav-fg:      #b9c0c9;
  --nav-fg-hi:   #ffffff;
  --nav-active-bg: rgba(255,144,0,0.16);
  --input-bg:    #23272a;
  --code-bg:     #101214;
  --code-fg:     #d6dae0;
  --code-bd:     #2a2e33;
  --shadow:      0 1px 2px rgba(0,0,0,.5), 0 2px 6px rgba(0,0,0,.4);
  color-scheme: dark;
}

/* ---- Typography --------------------------------------------------------- */
body { font-family: var(--font-body) !important; }
h1,h2,h3,h4,h5,h6,.h1,.h2,.h3,.h4,.h5,.h6,
.page-title,.menu-title { font-family: var(--font-head) !important; }
b,strong,th,.font-weight-bold,.font-weight-bolder,.btn { font-family: var(--font-head); font-weight: 700; }

/* ---- App surfaces ------------------------------------------------------- */
html, body { background: var(--surface-0) !important; color: var(--text) !important; }

.card-box, .card, .modal-content, .dropdown-menu,
.notification-list .notify-all {
  background-color: var(--surface-1) !important;
  color: var(--text);
  border-color: var(--border) !important;
}
.card-box { box-shadow: var(--shadow); }
/* page-title band + footer: blend into the content surface (no navy bars) */
.page-title-box {
  background: transparent !important;
  box-shadow: none !important;
}
.page-title { color: var(--text) !important; }
.page-title-box .breadcrumb { background: transparent !important; }
.page-title-box .breadcrumb-item a { color: var(--text-muted); }
.page-title-box .breadcrumb-item.active,
.page-title-box .breadcrumb-item + .breadcrumb-item::before { color: var(--text-faint); }
.footer {
  background: transparent !important;
  color: var(--text-muted);
}
.footer a { color: var(--link); }
.text-muted, .text-dark small { color: var(--text-muted) !important; }
hr { border-color: var(--border); }

/* ---- Dropdown menus (profile + notifications) --------------------------- */
.dropdown-menu { color: var(--text); }
.dropdown-menu .dropdown-item,
.dropdown-item.notify-item,
.dropdown-item.notify-item span,
.dropdown-menu .notify-details,
.dropdown-menu .notify-details span { color: var(--text) !important; }
.dropdown-menu .noti-title,
.dropdown-menu .noti-title h5,
.dropdown-menu .noti-title small { color: var(--text-muted) !important; }
.dropdown-menu .dropdown-item i { color: var(--text-muted); }
.dropdown-item:hover, .dropdown-item:focus,
.dropdown-item.notify-item:hover {
  background-color: var(--surface-2) !important;
  color: var(--text) !important;
}
.dropdown-divider { border-color: var(--border) !important; }

/* ---- Top bar ------------------------------------------------------------ */
.topbar .topbar-left,
.navbar-custom {
  background-color: var(--chrome-bg) !important;
}
.topbar .topbar-left { border-bottom: 1px solid var(--chrome-bd); }
.navbar-custom { border-bottom: 1px solid var(--chrome-bd); }
.navbar-custom .nav-link,
.navbar-custom .noti-icon,
.button-menu-mobile i { color: var(--nav-fg) !important; }
.navbar-custom .nav-link:hover,
.navbar-custom .noti-icon:hover { color: var(--nav-fg-hi) !important; }

/* ---- Logo (brand kit) --------------------------------------------------- */
.topbar .topbar-left .logo {
  display: flex; align-items: center; justify-content: center;
  height: 70px; padding: 0 12px;
}
.topbar .topbar-left .logo i,
.topbar .topbar-left .logo span { display: none !important; }   /* kill old text/icon */
.topbar .topbar-left .logo .chq-logo-word { display: block; height: 34px; width: auto; }
.topbar .topbar-left .logo .chq-logo-mark { display: none;  height: 34px; width: auto; }
/* At >=768px Minton keeps the topbar-left at 240px even when the sidebar is
   collapsed, so the full wordmark always fits — no mark swap here (it would
   float misaligned over the narrow rail). The cloud mark is used only on
   true mobile (<768px), handled in the mobile media block below.
   grey "Cloud" reads fine on both chromes; no filter needed */

/* ---- Sidebar ------------------------------------------------------------ */
.side-menu.left {
  background: var(--chrome-bg) !important;
  border-right: 1px solid var(--chrome-bd);
  box-shadow: none;
}
.menu-title { color: var(--text-faint) !important; }
#sidebar-menu > ul > li > a { color: var(--nav-fg) !important; }
#sidebar-menu > ul > li > a:hover { color: var(--nav-fg-hi) !important; background: var(--surface-2); }
#sidebar-menu ul li a i { color: var(--text-faint); }
#sidebar-menu > ul > li > a.active {
  background: var(--nav-active-bg) !important;
  color: var(--nav-fg-hi) !important;
  box-shadow: inset 3px 0 0 var(--chq-orange);
}
#sidebar-menu > ul > li > a.active i { color: var(--chq-orange); }
#sidebar-menu ul ul a { color: var(--nav-fg) !important; }
#sidebar-menu ul ul a:hover { color: var(--nav-fg-hi) !important; }
.menu-arrow, .menu-arrow:before { color: var(--text-faint) !important; }

/* ---- Links -------------------------------------------------------------- */
a { color: var(--link); }
a:hover, a:focus, a:active { color: var(--link-hover); }

/* ---- Buttons (primary = brand orange, black text) ----------------------- */
.btn-primary,
.btn-custom.btn-primary {
  background-color: var(--chq-orange) !important;
  border-color: var(--chq-orange) !important;
  color: var(--chq-orange-text) !important;
}
.btn-primary:hover, .btn-primary:focus, .btn-primary:active, .btn-primary.active,
.show > .btn-primary.dropdown-toggle {
  background-color: var(--chq-orange-700) !important;
  border-color: var(--chq-orange-700) !important;
  color: var(--chq-orange-text) !important;
}
.btn-primary:focus, .btn-primary.focus {
  box-shadow: 0 0 0 .2rem rgba(255,144,0,.4) !important;
}
.btn-info { background-color: var(--chq-blue) !important; border-color: var(--chq-blue) !important; color:#fff !important; }
.btn-info:hover, .btn-info:focus { background-color: var(--chq-blue-700) !important; border-color: var(--chq-blue-700) !important; }
.btn-outline-primary { color: var(--chq-orange) !important; border-color: var(--chq-orange) !important; }
.btn-outline-primary:hover { background: var(--chq-orange) !important; color: var(--chq-orange-text) !important; }
/* De-emphasized secondary button (e.g. staff SSO on login) — neutral/muted,
   clearly secondary to the solid primary. */
.btn-ghost {
  background: transparent !important;
  color: var(--text-muted) !important;
  border: 1px solid var(--border) !important;
}
.btn-ghost:hover, .btn-ghost:focus {
  background: var(--surface-2) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}

/* ---- Forms -------------------------------------------------------------- */
.form-control, .custom-select {
  background-color: var(--input-bg); color: var(--text); border-color: var(--border);
}
.form-control:focus {
  background-color: var(--input-bg); color: var(--text);
  border-color: var(--chq-orange); box-shadow: 0 0 0 .15rem rgba(255,144,0,.2);
}
.form-control::placeholder { color: var(--text-faint); }
/* Input-group icon addons (e.g. login Email/Password glyphs) were Minton
   navy #526170; match the sidebar chrome (chrome-bg + nav-fg) in both themes. */
.input-group-text {
  background-color: var(--chrome-bg) !important;
  color: var(--nav-fg) !important;
  border-color: var(--border) !important;
}
/* Custom checkbox (e.g. login "Remember me") was Minton navy #3d4853 box
   with a grey tick; theme the box off --input-bg and the checked state orange. */
.checkbox label::before {
  background-color: var(--input-bg) !important;
  border-color: var(--border) !important;
}
.checkbox input[type="checkbox"]:checked + label::before {
  background-color: var(--chq-orange) !important;
  border-color: var(--chq-orange) !important;
}
.checkbox input[type="checkbox"]:checked + label::after { color: var(--chq-orange-text) !important; }

/* ---- Tables ------------------------------------------------------------- */
.table { color: var(--text); }
.table thead th, .table td, .table th { border-color: var(--border) !important; }
.table-hover tbody tr:hover { background-color: var(--surface-2); color: var(--text); }
.table .thead-light th, .table thead.thead-dark th { background: var(--surface-2); color: var(--text); border-color: var(--border); }

/* ---- Code / pre blocks (design-summary pages, markdown) ----------------- */
pre, code, kbd, pre.building-summary {
  background-color: var(--code-bg) !important;
  border-color: var(--code-bd) !important;
}
pre, pre.building-summary { color: var(--code-fg) !important; }
code { color: var(--code-fg); }           /* inline code: readable in both modes */
pre code { color: inherit; background: transparent !important; }

/* ---- DataTables Editor lightbox (New/Edit modal on DT pages) ------------ */
/* Its panel is hardcoded white; our dark --text cascaded in → invisible.
   Theme the whole lightbox off the tokens so it reads in both modes. */
/* Only div.DTE is the visible panel. NOT .DTED_Lightbox_Content_Wrapper —
   that's a viewport-tall scroll container; painting it made a giant card
   with the form floating in the middle (false top/bottom padding). */
div.DTE,
.DTE_Body_Content,
.DTE_Form_Content {
  background-color: var(--surface-1) !important;
  color: var(--text) !important;
}
div.DTE { border-color: var(--border) !important; }
/* Field row hover: editor default is #f9f9f9 (light) → unreadable in dark */
div.DTE_Body div.DTE_Body_Content div.DTE_Field:hover {
  background-color: var(--surface-2) !important;
  border-color: var(--border) !important;
}
.DTE_Header, .DTE_Footer {
  background-color: var(--surface-2) !important;
  border-color: var(--border) !important;
  color: var(--text) !important;
}
.DTE_Header_Content, .DTE_Footer_Content { color: var(--text) !important; }
.DTE_Label { color: var(--text) !important; }
.DTE_Field_Info, .DTE_Field_Message, .DTE_Form_Info { color: var(--text-muted) !important; }
.DTE_Field input,
.DTE_Field select,
.DTE_Field textarea {
  background-color: var(--input-bg) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}
.DTE_Field input:focus,
.DTE_Field select:focus,
.DTE_Field textarea:focus { border-color: var(--chq-orange) !important; }
/* Close (×) button: editor default is a black circle; my old override put a
   static bg behind the glyph. Token-based circle, transparent glyph bg. */
.DTED_Lightbox_Close {
  background-color: var(--text) !important;      /* dark circle in light, light in dark */
  border-color: var(--surface-1) !important;
  box-shadow: 0 1px 3px rgba(0,0,0,.4) !important;
}
.DTED_Lightbox_Close:after {
  background: none !important;                    /* no static text background */
  color: var(--surface-1) !important;             /* × contrasts with the circle */
}
.DTED_Lightbox_Close:hover { background-color: var(--chq-orange) !important; }
.DTED_Lightbox_Close:hover:after { color: var(--chq-orange-text) !important; }
/* Editor action button (bare .btn, grey #dcdcdc + light text = invisible) → brand primary */
.DTE_Footer button.btn, .DTE_Form_Buttons button.btn {
  background-color: var(--chq-orange) !important;
  border-color: var(--chq-orange) !important;
  color: var(--chq-orange-text) !important;
}
.DTE_Footer button.btn:hover, .DTE_Form_Buttons button.btn:hover {
  background-color: var(--chq-orange-700) !important;
  border-color: var(--chq-orange-700) !important;
}

/* ---- DataTables pager (Bootstrap-4 integration) ------------------------- */
/* Non-active .page-link was hardcoded navy #526170 in both modes. */
.pagination .page-link {
  background-color: var(--surface-1) !important;
  color: var(--link) !important;
  border-color: var(--border) !important;
}
.pagination .page-link:hover {
  background-color: var(--surface-2) !important;
  color: var(--link-hover) !important;
  border-color: var(--border) !important;
}
.page-item.active .page-link {
  background-color: var(--chq-orange) !important;
  border-color: var(--chq-orange) !important;
  color: var(--chq-orange-text) !important;
}
.page-item.disabled .page-link {
  background-color: var(--surface-1) !important;
  color: var(--text-faint) !important;
  border-color: var(--border) !important;
}

/* ---- FullCalendar 2.9 (Site Calendars) ---------------------------------- */
/* Legacy style.css paints FC navy (#3d4853 cells / #485561 chrome) in BOTH
   modes, with dark day-numbers — unreadable on white in light mode and off the
   token palette in dark. Re-theme the structural bits off the tokens; event
   colours (cal-cat-* in pages-calendar.php) are brand-fixed and left alone. */
.fc { color: var(--text); }
.fc-toolbar h2 { color: var(--text) !important; }

/* Grid borders */
.fc td, .fc th,
.fc-unthemed thead, .fc-unthemed tbody,
.fc-unthemed .fc-divider, .fc-unthemed .fc-row,
.fc-unthemed .fc-popover { border-color: var(--border) !important; }

/* Body cells + day-of-week headers. Light: a soft off-white (surface-0) rather
   than stark card-white, so the grid reads as a calendar not a sheet of paper.
   Dark keeps surface-1 (its cells already look right). */
.fc-widget-content { background: var(--surface-0) !important; }
:root[data-theme="dark"] .fc-widget-content { background: var(--surface-1) !important; }
.fc-day-header, .fc-widget-header {
  background: var(--surface-2) !important;
  color: var(--text) !important;
}
.fc-day-number, .fc-week-number,
.fc-axis, .fc-time { color: var(--text-muted) !important; }
.fc-other-month { background: var(--surface-2) !important; }

/* Today: FC's default pale-yellow / legacy slate → brand orange tint */
.fc-unthemed .fc-today,
.fc .fc-today.fc-state-highlight { background: var(--nav-active-bg) !important; }

/* Toolbar buttons (prev/next/today, month/week/day) */
.fc-button.fc-state-default {
  background: var(--surface-2) !important;
  background-image: none !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
  text-shadow: none !important;
  box-shadow: none !important;
}
.fc-button.fc-state-hover { background: var(--surface-1) !important; color: var(--text) !important; }
.fc-button.fc-state-active,
.fc-button.fc-state-down {
  background: var(--chq-orange) !important;
  border-color: var(--chq-orange) !important;
  color: var(--chq-orange-text) !important;
}
.fc-button.fc-state-disabled { color: var(--text-faint) !important; opacity: .65; }

/* ---- Badges / misc accents --------------------------------------------- */
.badge-primary { background-color: var(--chq-orange); color: var(--chq-orange-text); }
.badge-info { background-color: var(--chq-blue); }
.bg-primary { background-color: var(--chq-orange) !important; }
.text-primary { color: var(--chq-orange) !important; }

/* ---- Login / account pages (brand lockup swapped in via markup) --------- */
.wrapper-page { max-width: 400px; }
.logo-lg { line-height: normal !important; }
.logo-lg i, .logo-lg span { display: none !important; }   /* kill old text/icon logo */
.chq-lockup { display: block; max-width: 220px; margin: 0 auto 8px; height: auto; }
.chq-lockup--dark { display: none; }   /* light lockup is the default */
:root[data-theme="dark"] .chq-lockup--light { display: none; }
:root[data-theme="dark"] .chq-lockup--dark  { display: block; }

/* ---- Theme toggle button (injected into topbar by theme-chq.js) --------- */
.chq-theme-toggle {
  background: none; border: 0; cursor: pointer; padding: 0;
  line-height: 70px; color: var(--nav-fg); font-size: 20px;
}
.chq-theme-toggle:hover { color: var(--chq-orange); }
.chq-theme-toggle .mdi { vertical-align: middle; }
/* floating fallback on pages without a topbar (e.g. login) */
.chq-theme-toggle--floating {
  position: fixed; right: 18px; bottom: 18px; z-index: 1050;
  width: 42px; height: 42px; line-height: 42px; border-radius: 50%;
  background: var(--surface-1); color: var(--nav-fg);
  box-shadow: var(--shadow); border: 1px solid var(--border);
}

/* ---- Mobile navigation -------------------------------------------------- */
/* Hamburger: was hardcoded Minton orange (#ff9000) → themed chrome. */
.button-menu-mobile {
  background-color: var(--chrome-bg) !important;
  color: var(--nav-fg) !important;
  border-right: 1px solid var(--chrome-bd);
}
.button-menu-mobile:hover, .button-menu-mobile:focus { color: var(--chq-orange) !important; }

/* Backdrop behind the open mobile drawer (shown/hidden by theme-chq.js).
   Sits below the sidebar (z-index 10) and above page content. */
.chq-nav-backdrop {
  position: fixed; inset: 0; z-index: 9;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0; visibility: hidden;
  transition: opacity .2s ease;
  cursor: pointer;            /* reads as dismissable; also helps iOS synthesize the tap click */
  touch-action: manipulation; /* no 300ms delay / double-tap zoom on the dismiss tap */
}
.chq-nav-backdrop.is-visible { opacity: 1; visibility: visible; }

@media (max-width: 767px) {
  /* Narrow topbar clips the wordmark → show the cloud mark only. */
  .topbar .topbar-left .logo .chq-logo-word { display: none !important; }
  .topbar .topbar-left .logo .chq-logo-mark { display: block !important; }

  /* Hamburger to the far left so the primary tap target isn't the
     home-linked logo (avoids accidental navigation home on a mistap). */
  .topbar .button-menu-mobile { position: absolute; left: 0; top: 0; z-index: 3; height: 70px; }
  .topbar .topbar-left { margin-left: 62px; }

  /* Kill the load flash: the drawer is CSS-hidden from first paint and only
     shown once Minton marks it open (forced + not collapsed), so it never
     renders on-screen before the layout JS runs. */
  .side-menu.left { margin-left: -250px; }
  #wrapper.forced:not(.enlarged) .side-menu.left { margin-left: 0; }

  /* Constrain the drawer to the viewport so a long staff nav scrolls INSIDE
     the drawer instead of page-scrolling the dimmed background with it. */
  .side-menu.left { position: fixed; top: 70px; bottom: 0; height: auto; }
  .side-menu.left .sidebar-inner {
    height: 100%;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  /* Lock background scroll while the drawer is open. */
  body.chq-nav-open { overflow: hidden; }

  /* Smooth the drawer slide — only once layout has settled. */
  body.chq-nav-ready .side-menu.left { transition: margin-left .25s ease, width .25s ease; }
}
@media (min-width: 768px) {
  .chq-nav-backdrop { display: none !important; }   /* desktop never needs it */

  /* Collapsing the sidebar swaps body .fixed-left → .fixed-left-void, which
     drops position:fixed and leaves the rail position:absolute — so it
     scrolls out of view on long pages. Keep it pinned + full height to
     match the expanded state. */
  #wrapper.enlarged .side-menu.left {
    position: fixed;
    top: 70px;
    bottom: 0;
    height: auto;
  }
  /* A long nav overflows the collapsed rail; Minton leaves the inner
     overflow:visible (for the hover-widen flyout label), which blocks
     scrolling. Enable vertical scroll — the clipped flyout label is
     replaced by native title tooltips (set in theme-chq.js). */
  #wrapper.enlarged .side-menu.left .sidebar-inner {
    overflow-y: auto;
    overflow-x: hidden;
  }
  /* Collapsed hover was Minton navy (#3d4853); match the expanded hover
     exactly (surface-2 fill, token text, icon unchanged). */
  #wrapper.enlarged .left.side-menu #sidebar-menu ul > li:hover > a {
    background: var(--surface-2) !important;
    color: var(--nav-fg-hi) !important;
  }
}

/* ── Calendar priority badge ──────────────────────────────────────────────
   Shared by Site Calendars (list grid, box, detail modal) and the home
   "Upcoming Dates" widget. Only the exceptions are badged — Planned is the
   default and carries no marker, so it doesn't compete with the discipline
   colour. Uppercase chip for clear visibility. */
.cal-prio-badge { display:inline-block; font-size:10.5px; font-weight:700; text-transform:uppercase; letter-spacing:.4px; padding:2px 8px; border-radius:10px; line-height:1.5; white-space:nowrap; }
.cal-prio-badge.p-emergency { background:#b00020; color:#fff; }
.cal-prio-badge.p-expedited { background:#ff9000; color:#3a2800; }

/* ── Summernote editor (service-notice email composer) ─────────────────────
   mail-servicenotice.php is the one page still using Summernote. The Minton
   base (style.css) paints it in legacy navy (#414d59 toolbar/statusbar,
   #3d4853 editable, #485561 buttons), so it renders as a navy island inside
   the CHQ surfaces — jarring in both light and dark. Remap every Summernote
   surface onto the shared tokens; token-driven, so this one block covers both
   modes. theme-chq.css loads after style.css, so these win the cascade. */
.note-editor.note-frame {
  border-color: var(--border) !important;
  border-radius: 4px;
  overflow: hidden;
}

/* toolbar + status bar */
.note-editor .note-toolbar {
  background-color: var(--surface-2) !important;
  border-bottom: 1px solid var(--border) !important;
}
.note-editor .note-statusbar,
.note-editor .note-statusbar .note-resizebar {
  background-color: var(--surface-2) !important;
  border-top: 1px solid var(--border);
}

/* editing area + placeholder */
.note-editor.note-frame .note-editing-area .note-editable {
  background-color: var(--input-bg) !important;
  color: var(--text) !important;
}
.note-editor .note-placeholder,
.note-editable .note-placeholder { color: var(--text-faint) !important; }

/* toolbar buttons (Summernote renders them .btn.btn-light.note-btn; Minton
   also reaches them via .note-editor .btn-default) */
.note-editor .note-toolbar .note-btn,
.note-editor .note-toolbar .btn-light,
.note-editor .btn-default,
.note-editor .note-btn-group .btn-light {
  background-color: transparent !important;
  border-color: transparent !important;
  color: var(--text-muted) !important;
}
.note-editor .note-toolbar .note-btn:hover,
.note-editor .note-toolbar .note-btn.active,
.note-editor .note-toolbar .note-btn:focus,
.note-editor .note-toolbar .btn-light:hover {
  background-color: var(--surface-1) !important;
  border-color: var(--border) !important;
  color: var(--text) !important;
}

/* dropdown menus (font name / style / paragraph pickers) */
.note-btn-group .dropdown-menu {
  background-color: var(--surface-1) !important;
  border-color: var(--border) !important;
}
.note-btn-group .dropdown-menu > li > a,
.note-btn-group .dropdown-item { color: var(--text) !important; }
.note-btn-group .dropdown-menu > li > a:hover,
.note-btn-group .dropdown-item:hover { background-color: var(--surface-2) !important; }

/* code view textarea */
.note-editor .note-codable {
  background-color: var(--code-bg) !important;
  color: var(--code-fg) !important;
}
