/* Styles for js/ui.js -- 2026 Modern UI Design System for Pia Day Spa.
   Replaces jquery.mobile-1.4.5.min.css, nativedroid2.css, waves and animate.css.
   App-specific overrides and layouts stay in css/apptonline.css, which loads after this. */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --bn-font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --bn-bg: #f3f8f4;
  --bn-surface: #ffffff;
  --bn-surface-soft: #eef5ef;
  --bn-surface-tint: #f4faee;
  --bn-text: #18281c;
  --bn-text-muted: #586a5c;
  --bn-primary: #467c17;
  --bn-primary-hover: #3c6b13;
  --bn-primary-light: #e5f3d8;
  --bn-accent: #c24618;
  --bn-danger: #c62b1d;
  --bn-border: #dce7de;
  --bn-radius-sm: 10px;
  --bn-radius-md: 14px;
  --bn-radius-lg: 20px;
  --bn-radius-xl: 26px;
  --bn-shadow-sm: 0 2px 8px rgba(20, 45, 25, 0.05);
  --bn-shadow-md: 0 10px 30px -5px rgba(20, 45, 25, 0.07), 0 4px 12px -2px rgba(20, 45, 25, 0.04);
  --bn-shadow-lg: 0 20px 45px -10px rgba(20, 45, 25, 0.14), 0 8px 20px -4px rgba(20, 45, 25, 0.06);
  --bn-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html { -webkit-text-size-adjust: 100%; box-sizing: border-box; }
*, *:before, *:after { box-sizing: inherit; }
body {
  margin: 0;
  font-family: var(--bn-font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--bn-text);
  background: var(--bn-bg);
  -webkit-font-smoothing: antialiased;
  /* apptonline.css hides the body until scripts are ready. If a script error stops that from
     happening, show the page anyway after 2s instead of leaving a blank screen. */
  animation: bn-ui-reveal 0s linear 2s forwards;
}
body.nd2-ready { opacity: 1; animation: none; }
@keyframes bn-ui-reveal { to { opacity: 1; } }

/* WCAG 2.1 AA: Skip link, screen-reader-only utility, and visible keyboard focus rings */
.bn-skip-link {
  position: absolute;
  top: -100px;
  left: 12px;
  z-index: 3000;
  padding: 10px 16px;
  border-radius: 10px;
  background: #18281c;
  color: #ffffff !important;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--bn-shadow-lg);
}
.bn-skip-link:focus {
  top: 12px;
  outline: 3px solid #b7e08f;
  outline-offset: 2px;
}
.bn-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 3px solid #2f5c14;
  outline-offset: 2px;
}
.ui-input-text :where(input, textarea):focus-visible {
  outline: none;
}

input, select, textarea, button { font-family: inherit; line-height: 1.4; }
[data-role="popup"]:not(.ui-popup), [data-role="panel"]:not(.ui-panel) { display: none; }

/* Modern type scale */
h1, h2, h3, h4, h5, h6 { line-height: 1.25; font-weight: 700; color: var(--bn-text); letter-spacing: -0.02em; }
h1 { font-size: 32px; }
h2 { font-size: 24px; }
h3 { font-size: 19px; }
h4 { font-weight: 600; font-size: 16px; }
h5 { font-size: 15px; }
h6 { font-size: 13.5px; }
p { font-size: 15px; line-height: 1.5; color: var(--bn-text-muted); }
.align-right { text-align: right; }
.align-left { text-align: left; }
.align-center { text-align: center; }

.ui-page { position: relative; background: transparent; min-height: 100vh; }
.ui-page a { color: var(--bn-primary); text-decoration: none; transition: color 0.2s ease; }
.ui-content { padding: 16px; max-width: 540px; margin: 0 auto; }

/* header */
.ui-header {
  position: relative;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--bn-text);
  font-weight: 700;
  border-bottom: 1px solid var(--bn-border);
  box-shadow: var(--bn-shadow-sm);
}
.ui-header-fixed { position: sticky; top: 0; }
.ui-header .ui-title {
  display: block; min-height: 1.1em; margin: 0 64px; padding: 14px 0;
  font-size: 17px; line-height: 1.4; font-weight: 700; letter-spacing: -0.01em;
  text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  color: var(--bn-text);
}

/* buttons */
.ui-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  position: relative; margin: 0; padding: 13px 20px;
  font: 600 15px/1.3 var(--bn-font);
  letter-spacing: -0.01em;
  text-transform: none; text-align: center;
  text-decoration: none; color: var(--bn-text);
  background: var(--bn-surface-soft);
  border: 1px solid transparent;
  border-radius: var(--bn-radius-md);
  cursor: pointer; user-select: none; -webkit-user-select: none;
  transition: all 0.22s var(--bn-ease);
  white-space: normal; overflow-wrap: anywhere;
}
.ui-page .ui-btn, a.ui-btn:visited { color: inherit; }
.ui-btn:hover { background-color: #e2ede4; transform: translateY(-1px); }
.ui-btn:active { transform: translateY(0); }
.ui-btn-inline { display: inline-flex; vertical-align: middle; width: auto; }
.ui-btn.ui-btn-raised {
  background-color: var(--bn-surface);
  border-color: var(--bn-border);
  box-shadow: var(--bn-shadow-sm);
}
.ui-btn.ui-btn-raised:hover {
  background-color: #f9fcf9;
  border-color: #c8d8cb;
  box-shadow: 0 4px 12px rgba(20, 45, 25, 0.08);
}
.ui-btn.ui-btn-fab {
  border-radius: 999px;
  min-width: 48px;
  min-height: 48px;
  padding: 12px 20px;
}
.ui-btn-fab > i.fa { margin: 0; padding: 0; font-size: 1.25em; }
.ui-btn.clr-primary { color: var(--bn-primary); font-weight: 700; }
.ui-btn.clr-warning { color: var(--bn-danger); }
.ui-btn.ui-btn-raised.clr-primary {
  background: linear-gradient(180deg, #4b831a 0%, #3d6d14 100%);
  border-color: #366011;
  color: #ffffff !important;
  box-shadow: 0 6px 18px -3px rgba(61, 109, 20, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
.ui-btn.ui-btn-raised.clr-primary:hover {
  background: linear-gradient(180deg, #437617 0%, #345f10 100%);
  box-shadow: 0 8px 22px -3px rgba(61, 109, 20, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
.ui-btn.ui-btn-raised.clr-warning {
  background-color: var(--bn-danger);
  border-color: var(--bn-danger);
  color: #ffffff !important;
}
.ui-mini { font-size: 13px; padding: 8px 14px; border-radius: var(--bn-radius-sm); }
.ui-btn.ui-disabled, .ui-state-disabled, .ui-btn[disabled] { opacity: 0.45; pointer-events: none; box-shadow: none; }

/* header buttons */
.ui-header > .ui-btn {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 10;
  box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center;
  margin: 0; padding: 0; width: 40px; height: 40px; font-size: 18px;
  color: var(--bn-text); background-color: var(--bn-surface-soft);
  border-radius: 50%; overflow: hidden;
}
.ui-header > .ui-btn:hover { background-color: #dfeadd; transform: translateY(-50%); }
.ui-header > .ui-btn-left { left: 12px; }
.ui-header > .ui-btn-right { right: 12px; }

/* text inputs and selects: modern filled pill/rounded fields */
label {
  display: block; margin: 0 0 6px;
  font-size: 13.5px; font-weight: 600;
  color: #2c3e30; letter-spacing: -0.01em;
}
.ui-input-text, .ui-select {
  position: relative;
  margin: 0 0 16px;
  padding: 0;
  background-color: var(--bn-surface-soft);
  border: 1.5px solid #768a7c;
  border-radius: var(--bn-radius-md);
  transition: background-color 0.2s var(--bn-ease), border-color 0.2s var(--bn-ease), box-shadow 0.2s var(--bn-ease);
}
.ui-input-text:has(textarea) {
  background-color: var(--bn-surface);
  border-color: #768a7c;
  box-shadow: inset 0 1px 3px rgba(20, 45, 25, 0.05), 0 2px 6px rgba(20, 45, 25, 0.03);
}
.ui-input-text:focus-within {
  background-color: var(--bn-surface);
  border-color: var(--bn-primary);
  box-shadow: 0 0 0 4px rgba(91, 154, 36, 0.14);
}
.ui-input-text-error { border-color: var(--bn-danger) !important; }
.ui-input-text-error:focus-within {
  box-shadow: 0 0 0 4px rgba(198, 43, 29, 0.16);
}
.bn-field-error {
  color: var(--bn-danger);
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.35;
  margin: -10px 0 12px;
}
.ui-input-text input, .ui-input-text textarea {
  box-sizing: border-box; display: block; width: 100%; min-height: 48px;
  margin: 0; padding: 12px 16px;
  font-size: 15px; line-height: 1.4; font-weight: 500;
  color: var(--bn-text); background: transparent;
  border: 0; border-radius: var(--bn-radius-md); outline: 0;
}
.ui-input-text input::placeholder, .ui-input-text textarea::placeholder {
  color: #5e7062; font-weight: 400;
}
.ui-input-text textarea { padding: 12px 16px; min-height: 96px; }
.ui-input-text:after { display: none; }
.ui-input-has-clear input, .ui-input-has-pw input { padding-right: 42px; }
.bn-pw-toggle {
  position: absolute; top: 50%; right: 8px; width: 32px; height: 32px; margin-top: -16px;
  border-radius: 50%; border: 0; background: transparent;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 16px; color: #5b6e60; cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.bn-pw-toggle:hover { background-color: rgba(24, 40, 28, 0.08); color: var(--bn-text); }
.ui-input-clear {
  position: absolute; top: 50%; right: 10px; width: 24px; height: 24px; margin-top: -12px;
  border-radius: 50%; text-align: center; font-size: 16px; line-height: 24px; font-weight: 700;
  color: #5b6e60; text-decoration: none; cursor: pointer;
  background-color: rgba(24, 40, 28, 0.08);
  transition: background-color 0.15s ease, color 0.15s ease;
}
.ui-input-clear:hover { background-color: rgba(24, 40, 28, 0.16); color: var(--bn-text); }
.ui-page a.ui-input-clear { color: #5b6e60; }
.ui-input-clear-hidden { display: none !important; }

.ui-select { margin: 0 0 16px; background: transparent; border: 0; }
.ui-select select {
  box-sizing: border-box; display: block; width: 100%; min-height: 48px;
  margin: 0; padding: 11px 40px 11px 16px;
  font-size: 15px; font-weight: 500; color: var(--bn-text);
  border: 1.5px solid #768a7c; border-radius: var(--bn-radius-md); outline: 0;
  -webkit-appearance: none; appearance: none;
  background: var(--bn-surface-soft) url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2214%22%20height%3D%2214%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%234a5d4e%22%20stroke-width%3D%222.5%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpolyline%20points%3D%226%209%2012%2015%2018%209%22%3E%3C%2Fpolyline%3E%3C%2Fsvg%3E") no-repeat right 14px center;
  cursor: pointer;
  transition: background-color 0.2s var(--bn-ease), border-color 0.2s var(--bn-ease), box-shadow 0.2s var(--bn-ease);
}
.ui-select select:focus {
  background-color: var(--bn-surface);
  border-color: var(--bn-primary);
  box-shadow: 0 0 0 4px rgba(91, 154, 36, 0.14);
}

/* checkboxes and radios */
.ui-checkbox, .ui-radio {
  position: relative; margin: 8px 0;
  background-color: var(--bn-surface);
  border: 1px solid var(--bn-border);
  border-radius: var(--bn-radius-md);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
.ui-checkbox:has(input:checked), .ui-radio:has(input:checked) {
  border-color: var(--bn-primary);
  background-color: var(--bn-surface-tint);
}
.ui-checkbox input, .ui-radio input {
  position: absolute; left: 14px; width: 18px; height: 18px; margin: 0;
  accent-color: var(--bn-primary); z-index: 1; cursor: pointer;
}
.ui-checkbox input { top: 50%; transform: translateY(-50%); }
.ui-radio input { top: 50%; transform: translateY(-50%); }
:where(.ui-checkbox, .ui-radio) > label.ui-btn { margin: 0; padding: 13px 16px 13px 42px; }
.ui-checkbox > label.ui-btn, .ui-radio > label.ui-btn {
  display: block; text-align: left; text-transform: none;
  font-size: 15px; font-weight: 500;
  white-space: normal; color: var(--bn-text);
  background-color: transparent; border-radius: var(--bn-radius-md);
}
.ui-controlgroup { margin: 8px 0; padding: 0; border: 0; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.ui-controlgroup .ui-checkbox, .ui-controlgroup .ui-radio { margin: 0; }
.ui-controlgroup-label { padding: 0 2px; font-weight: 700; color: var(--bn-text); }

/* lists */
.ui-listview { margin: 12px 0; padding: 0; list-style: none; }
.ui-content .ui-listview { margin: 0 0 12px; }
.ui-content .ui-listview-inset { margin: 12px 0; }
.ui-listview > li { position: relative; display: block; border-bottom: 1px solid #edf2ee; }
.ui-listview > li:last-child { border-bottom: 0; }
.ui-listview > .ui-li-static { padding: 12px 16px; }
.ui-listview > li > a.ui-btn {
  display: block; margin: 0; padding: 13px 16px;
  text-align: left; text-transform: none;
  background: var(--bn-surface); border-radius: 0;
}
.ui-listview > li > a.ui-btn:hover { background: var(--bn-surface-tint); transform: none; }
.ui-listview > .ui-li-divider {
  padding: 8px 16px; font-size: 12px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.05em; line-height: 1.4; color: var(--bn-text-muted); background: transparent;
}
.ui-listview-inset {
  margin: 12px 0; border-radius: var(--bn-radius-md);
  border: 1px solid var(--bn-border);
  box-shadow: var(--bn-shadow-sm); overflow: hidden; background: var(--bn-surface);
}
.ui-listview > li h1, .ui-listview > li h2, .ui-listview > li h3, .ui-listview > li h4, .ui-listview > li h5, .ui-listview > li h6 {
  display: block; margin: 4px 0; font-size: 15px; font-weight: 700; text-transform: none;
  white-space: normal; overflow-wrap: anywhere;
}
.ui-listview > li p {
  display: block; margin: 4px 0; font-size: 13.5px; font-weight: 400; color: var(--bn-text-muted);
  text-transform: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* collapsibles (accordions) - smooth animated expansion and retraction */
.ui-collapsible-set { margin: 12px 0; display: flex; flex-direction: column; gap: 10px; }
.ui-collapsible {
  margin: 0 0 10px;
  background-color: var(--bn-surface);
  border: 1px solid var(--bn-border);
  border-radius: var(--bn-radius-md);
  box-shadow: var(--bn-shadow-sm);
  overflow: hidden;
  transition: border-color 0.25s var(--bn-ease), box-shadow 0.25s var(--bn-ease);
}
.ui-content .ui-collapsible { margin: 0 0 10px; }
.ui-collapsible:not(.ui-collapsible-collapsed) {
  border-color: #b7d49e;
  box-shadow: var(--bn-shadow-md);
}
.ui-collapsible-heading { margin: 0; padding: 0; position: relative; }
.ui-collapsible-heading-toggle.ui-btn {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; padding: 15px 46px 15px 18px;
  text-align: left; font-weight: 700; font-size: 15px;
  color: var(--bn-text);
  background-color: var(--bn-surface-tint);
  border-radius: 0;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.ui-collapsible-collapsed .ui-collapsible-heading-toggle.ui-btn {
  background-color: var(--bn-surface);
}
.ui-collapsible-heading-toggle.ui-btn:hover {
  background-color: var(--bn-surface-soft);
  transform: none;
}
.ui-collapsible-heading-toggle.ui-btn:after {
  content: ""; position: absolute; top: 50%; right: 16px; left: auto;
  width: 20px; height: 20px; margin-top: -10px;
  background: no-repeat center center url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2218%22%20height%3D%2218%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%235b9a24%22%20stroke-width%3D%222.5%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpolyline%20points%3D%226%209%2012%2015%2018%209%22%3E%3C%2Fpolyline%3E%3C%2Fsvg%3E");
  transform: rotate(180deg);
  transition: transform 0.3s var(--bn-ease);
}
.ui-collapsible-collapsed .ui-collapsible-heading-toggle.ui-btn:after {
  background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2218%22%20height%3D%2218%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%235b6e60%22%20stroke-width%3D%222.5%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpolyline%20points%3D%226%209%2012%2015%2018%209%22%3E%3C%2Fpolyline%3E%3C%2Fsvg%3E");
  transform: rotate(0deg);
}
.ui-collapsible-content {
  padding: 14px 18px;
  color: var(--bn-text);
  border-top: 1px solid #edf2ee;
  animation: bn-accordion-open 0.28s var(--bn-ease);
}
.ui-collapsible-collapsed > .ui-collapsible-content { display: none; }
@keyframes bn-accordion-open {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* tabs */
.nd2Tabs { display: block; margin: 0; padding: 0; list-style: none; white-space: nowrap; overflow-x: auto; }
.nd2Tabs li {
  display: inline-block; padding: 0 14px; line-height: 46px; text-align: center;
  font-size: 14px; font-weight: 600; color: rgba(255,255,255,.75); cursor: pointer;
  transition: color 0.25s ease;
}
.nd2Tabs li:hover, .nd2Tabs .nd2Tabs-active { color: #fff; }
.nd2Tabs .nd2Tabs-active { position: relative; }
.nd2Tabs .nd2Tabs-active:after { content: ""; position: absolute; left: 10%; bottom: 0; width: 80%; height: 3px; border-radius: 3px 3px 0 0; background: #fff; }
.nd2Tabs-content-tab { display: none; }
.nd2Tabs-content-tab.nd2Tab-active {
  display: block; position: relative;
  animation: bn-tab-fade 0.28s var(--bn-ease);
}
@keyframes bn-tab-fade {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* popups (centred by CSS with smooth scale/fade animation) */
.ui-popup-screen {
  position: fixed; inset: 0; z-index: 2200;
  background: rgba(15, 28, 18, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 1;
  transition: opacity 0.22s var(--bn-ease);
}
.ui-popup-container {
  position: fixed; inset: 0; display: flex; align-items: center; justify-content: center;
  padding: 16px;
  pointer-events: none; z-index: 2201;
}
.ui-popup-container > .ui-popup {
  pointer-events: auto;
  width: 100%;
  max-width: 420px;
  max-height: calc(100vh - 32px);
  overflow: auto;
  padding: 22px 22px 18px;
  color: var(--bn-text);
  background: var(--bn-surface);
  border-radius: var(--bn-radius-lg);
  box-shadow: var(--bn-shadow-lg);
  border: 1px solid var(--bn-border);
  transform: scale(1) translateY(0);
  opacity: 1;
  transition: transform 0.25s var(--bn-ease), opacity 0.22s var(--bn-ease);
}
.ui-screen-hidden { opacity: 0; pointer-events: none; display: none; }
.ui-popup-hidden { pointer-events: none; display: none; }
.ui-popup-hidden > .ui-popup { transform: scale(0.95) translateY(8px); opacity: 0; }
.ui-popup .ui-content { padding: 0; max-width: none; }
.ui-popup .ui-content > p { margin: 0 0 16px; font-size: 15px; line-height: 1.55; color: var(--bn-text); }

/* side panel */
.ui-panel {
  position: fixed; top: 0; bottom: 0; left: 0; z-index: 2000;
  box-sizing: border-box; width: 304px; max-width: 86vw;
  padding: 16px; overflow-y: auto; color: var(--bn-text);
  background: var(--bn-surface);
  box-shadow: var(--bn-shadow-lg);
  transform: translateX(-105%);
  visibility: hidden;
  transition: transform 0.32s var(--bn-ease), visibility 0.32s var(--bn-ease);
}
.ui-panel.ui-panel-open {
  transform: none;
  visibility: visible;
  /* Opening focus must work before the slide animation starts. */
  transition-property: transform;
}
.ui-panel .ui-listview { margin: 0 -16px; }
.ui-panel .ui-listview .ui-btn { font-weight: 500; border-radius: 0; }
.ui-panel-dismiss {
  position: fixed; inset: 0; z-index: 1999;
  background: rgba(15, 28, 18, 0.35);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.32s var(--bn-ease), visibility 0.32s var(--bn-ease);
}
.ui-panel-dismiss-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.nd2-sidepanel-profile {
  position: relative; margin: -16px -16px 16px; padding: 36px 16px 24px;
  overflow: hidden; border-bottom: 1px solid var(--bn-border);
}
.nd2-sidepanel-profile:after {
  content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: -1;
  background: linear-gradient(135deg, #254614 0%, #447817 100%);
}
.nd2-sidepanel-profile .profile-thumbnail {
  display: inline-block; width: 64px; height: 64px; margin: 0 auto;
  border-radius: 50%; overflow: hidden; border: 2px solid rgba(255,255,255,.35);
}
.nd2-sidepanel-profile .profile-text { color: #fff; }
.nd2-sidepanel-profile .profile-text strong { display: block; line-height: 1.3; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nd2-sidepanel-profile .profile-text .subline { display: block; font-size: 12.5px; line-height: 1.3; opacity: 0.85; }

.row { display: flex; flex-wrap: wrap; box-sizing: border-box; margin: 0 -.5rem; }
.col-xs-4, .col-xs-8 { box-sizing: border-box; padding: 0 .5rem; }
.col-xs-4 { flex-basis: 33.333%; max-width: 33.333%; }
.col-xs-8 { flex-basis: 66.667%; max-width: 66.667%; }
.center-xs { justify-content: center; text-align: center; }

/* toast */
.nd2-toast {
  position: fixed; bottom: 20px; left: 50%; z-index: 2300;
  box-sizing: border-box; width: auto; min-width: 280px; max-width: calc(100vw - 32px);
  padding: 12px 22px; line-height: 1.4; font-size: 14px; font-weight: 600;
  color: #fff; background: #1e2f22; border-radius: 999px;
  box-shadow: var(--bn-shadow-lg);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  transform: translate(-50%, 0); transition: bottom 0.35s var(--bn-ease), opacity 0.35s var(--bn-ease);
}
.nd2-toast.nd2-toast-off { bottom: -100px; opacity: 0; }

/* cards */
.nd2-card {
  display: block; max-width: 480px; margin: 16px auto; overflow: hidden;
  background: var(--bn-surface);
  border-radius: var(--bn-radius-lg);
  border: 1px solid var(--bn-border);
  box-shadow: var(--bn-shadow-md);
}
.nd2-card .card-title { padding: 20px 18px; }
.nd2-card .card-title.has-supporting-text { padding: 20px 18px 12px; }
.nd2-card .card-title .card-primary-title {
  margin: 0; max-width: 90%; font-size: 19px; line-height: 1.3; font-weight: 700;
  white-space: normal; overflow-wrap: anywhere;
}
.nd2-card .card-title .card-subtitle {
  margin: 2px 0 0; max-width: 90%; font-size: 13.5px; line-height: 1.4; font-weight: 500; color: var(--bn-text-muted);
  white-space: normal; overflow-wrap: anywhere;
}
.nd2-card .card-title.has-avatar .card-primary-title, .nd2-card .card-title.has-avatar .card-subtitle { font-size: 15.5px; line-height: 20px; }
.nd2-card .card-title .card-avatar {
  display: flex; align-items: center; justify-content: center;
  float: left; width: 42px; height: 42px; margin-right: 14px;
  overflow: hidden; border-radius: 50%; background-color: var(--bn-surface-soft);
}
.nd2-card .card-supporting-text { display: block; margin: 0; padding: 16px 18px; font-size: 15px; line-height: 1.6; }
.nd2-card .card-supporting-text.has-title { padding-top: 0; }
.nd2-card .card-action { padding: 10px 14px; }
.nd2-card .card-action.has-separator { border-top: 1px solid #edf2ee; }

/* loading indicator */
#modal {
  position: fixed;
  inset: 0;
  z-index: 2400;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(15, 28, 18, 0.42);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.ui-loader {
  position: relative;
  top: auto;
  left: auto;
  z-index: 2401;
  display: inline-flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-width: 148px;
  min-height: 118px;
  margin: 0;
  padding: 22px 26px;
  background: var(--bn-surface);
  border: 1px solid var(--bn-border);
  border-radius: 20px;
  box-shadow: var(--bn-shadow-lg);
  opacity: 1 !important;
  text-align: center;
}
.ui-loader .ui-icon-loading {
  display: block;
  box-sizing: border-box;
  width: 38px;
  height: 38px;
  border: 3.5px solid #e2ede4;
  border-top-color: var(--bn-primary);
  border-radius: 50%;
  animation: bn-ui-spin 0.72s linear infinite;
}
.ui-loader h1,
.ui-loader h1.bn-loader-text,
.ui-loader .bn-loader-heading,
.ui-loader .bn-loader-heading.bn-loader-text {
  position: static !important;
  margin: 0 !important;
  width: auto !important;
  height: auto !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.3 !important;
  color: var(--bn-text) !important;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: visible;
}
@keyframes bn-ui-spin { to { transform: rotate(360deg); } }

/* Bootstrap replacements (#ModalDetails) */
.modal { display: none; position: fixed; inset: 0; z-index: 1201; overflow-y: auto; }
.modal-backdrop { position: fixed; inset: 0; z-index: 1200; background: rgba(15, 28, 18, 0.5); backdrop-filter: blur(3px); display: none; }
body.modal-open { overflow: hidden; }
.modal-dialog { box-sizing: border-box; max-width: 500px; margin: 1rem auto; padding: 0 .75rem; }
@media (min-width: 576px) { .modal-dialog { margin: 2rem auto; padding: 0; } }
.modal-content { background: #fff; border-radius: var(--bn-radius-lg); box-shadow: var(--bn-shadow-lg); overflow: hidden; border: 1px solid var(--bn-border); }
.modal-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--bn-border); }
.modal-title { margin: 0; font-size: 18px; line-height: 1.4; font-weight: 700; color: var(--bn-text); }
.modal-header .btn-close { box-sizing: content-box; width: 1em; height: 1em; padding: .25em; border: 0; background: transparent; cursor: pointer;
  opacity: .5; font-size: 2.1em; line-height: .5; color: #000; }
.modal-header .btn-close:hover { opacity: .85; }
.modal-header .btn-close:before { content: "\00d7"; }
.modal-body { padding: 20px; font-size: 15px; line-height: 1.5; color: var(--bn-text); }
#ModalDetails *, #ModalDetails *:before, #ModalDetails *:after { box-sizing: border-box; }
#ModalDetails .container { width: 100%; padding: 0 .75rem; margin: 0 auto; }
#ModalDetails .row { display: flex; flex-wrap: wrap; margin: 0 -.75rem; }
#ModalDetails .row > * { flex-shrink: 0; width: 100%; max-width: 100%; padding: 0 .75rem; }
@media (min-width: 768px) { #ModalDetails .row > .col-md-6 { width: 50%; } }
#ModalDetails .input-group { position: relative; display: flex; align-items: stretch; width: 100%; }
#ModalDetails .input-group-text { display: flex; align-items: center; padding: .5rem .85rem; font-size: 14px; font-weight: 600; line-height: 1.5; color: var(--bn-text-muted);
  background: var(--bn-surface-soft); border: 1px solid var(--bn-border); border-radius: var(--bn-radius-sm) 0 0 var(--bn-radius-sm); white-space: nowrap; }
#ModalDetails .form-control { display: block; width: 100%; padding: .55rem .85rem; font: inherit; font-size: 15px; line-height: 1.5; color: var(--bn-text);
  background: #fff; border: 1px solid var(--bn-border); border-radius: var(--bn-radius-sm); }
#ModalDetails .form-control:focus { outline: 0; border-color: var(--bn-primary); box-shadow: 0 0 0 3px rgba(91, 154, 36, 0.15); }
#ModalDetails .form-control:disabled { background: #f2f5f3; }
#ModalDetails .input-group > .form-control { flex: 1 1 auto; width: 1%; min-width: 0; border-radius: 0 var(--bn-radius-sm) var(--bn-radius-sm) 0; }
#ModalDetails .input-group > .input-group-text + .form-control { border-left: 0; }
#ModalDetails .btn { display: inline-block; padding: .5rem 1rem; font: inherit; font-size: 14px; font-weight: 600; line-height: 1.5; text-align: center; cursor: pointer;
  border: 1px solid transparent; border-radius: var(--bn-radius-sm); }
#ModalDetails .btn-secondary { color: #fff; background: #5b6e60; border-color: #5b6e60; }
#ModalDetails .btn:disabled { opacity: .65; cursor: default; pointer-events: none; }
#ModalDetails .mb-1 { margin-bottom: .35rem; }
#ModalDetails .float-end { float: right; }
.d-none { display: none !important; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
