:root{
    --bg:#f3f5f8;
    --panel:#ffffff;
    --line:#d6dde7;
    --ink:#0f172a;
    --muted:#64748b;
    --brand:#0ea5a4;
    --nav:#0b1220;
    --nav2:#0f1b2d;

    --btn:#e8eef6;
    --btnInk:#102a43;

    --danger:#b91c1c;
    --ok:#059669;

    --barH:36px;
    --barRadius:8px;
    --barBg:#f8fafc;
    --barBorder:#d7dee8;
  }

  *{box-sizing:border-box}
  body{
    margin:0;
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    background:#f4f6f9;
    color:var(--ink);
  }

    .app{
    display:flex;
    min-height:100vh;
  }

  .sidebar{
    position:fixed;
    top:0;
    left:0;
    bottom:0;
    width:190px;
    background:linear-gradient(180deg,var(--nav),var(--nav2));
    color:#dbeafe;
    padding:14px 10px;
    border-right:1px solid rgba(255,255,255,.08);
    overflow-y:auto;
    z-index:40;
  }
  .brandBox{
  display:flex;
  gap:8px;
  align-items:center;
  padding:8px;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.08);
  border-radius:14px;
  margin-bottom:12px;
}

/* NEW: logo size control */
.sidebarLogo{
  width:46px;
  height:46px;
  object-fit:contain;
  border-radius:10px;
  flex:0 0 auto;
}

.brandTitle{
  line-height:1.15;
}

.brandTitle span{
  display:block;
  font-size:10px;
  color:#cbd5e1;
}

/* keep your existing nav styles unchanged */
.navSection{margin-top:14px;}

.navSection h4{
  margin:12px 10px 8px;
  font-size:12px;
  letter-spacing:.06em;
  color:#93c5fd;
  text-transform:uppercase;
  font-weight:700;
}
    .navItem{
  display:flex;
  align-items:center;
  gap:8px;
  padding:10px 14px;
  border-radius:0; /* remove rounding */
  margin:0; /* remove spacing gaps */
  cursor:pointer;
  color:#dbeafe;
  font-size:14px;
  user-select:none;
}
  .navItem:hover{background:rgba(255,255,255,.06)}
  .navDot{width:8px;height:8px;border-radius:99px;background:rgba(148,163,184,.6);}
  .navItem.active {
  background: #f8fafc; /* very light, almost white */
  border-radius: 0; /* remove rounded corners */
}

.navItem.navBusy{
  pointer-events:none;
  opacity:.55;
}

.navItem.loading{
  opacity:1;
}

.navItem.loading::after{
  content:"Working...";
  margin-left:auto;
  font-size:11px;
  font-weight:600;
  color:#93c5fd;
}

  .navItem.active .navDot{background:#34d399}
.navItem.active{
  background:rgba(255,255,255,0.04); /* very subtle light overlay */
  border-radius:0;
  border-left:3px solid #22c55e;
}

      .main{
    flex:1;
    display:flex;
    flex-direction:column;
    min-width:0;
    margin-left:190px;
    min-height:100vh;
  }

    .topbar{
    position:fixed;
    top:0;
    left:190px;
    right:0;
    height:56px;
    background:linear-gradient(180deg,#1f2937,#111827);
    color:#e5e7eb;
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:0 18px;
    border-bottom:1px solid rgba(255,255,255,.08);
    z-index:35;
  }
  .crumbs{font-size:14px;color:#cbd5e1;}
  .crumbs b{color:#e5e7eb;font-weight:800}

    .topActions{
    display:flex;
    gap:10px;
    align-items:center;
  }

  .topComponentHost{
    display:flex;
    align-items:center;
    margin-right:6px;
  }

.topComponentSelect{
  height:32px;
  min-width:132px;
  padding:5px 9px;
  border-radius:8px;
  border:1px solid rgba(255,255,255,.18);
  background:rgba(255,255,255,.08);
  color:#e5e7eb;
  font-size:13px;
  font-weight:600;
  outline:none;
}

.topComponentSelect option{
  background:#ffffff;
  color:#0f172a;
  font-weight:500;
}

  .topbar .seg{
    display:flex;
    gap:8px;
    align-items:center;
  }

  .topbar .seg button{
    padding:7px 14px;
    border-radius:10px;
    border:1px solid rgba(255,255,255,.18);
    background:rgba(255,255,255,.08);
    color:#e5e7eb;
    cursor:pointer;
    font-size:13px;
    font-weight:800;
    min-width:110px;
    height:36px;
  }

  .topbar .seg button:hover{
    background:rgba(255,255,255,.14);
  }

  .topbar .seg button.active{
    background:#dcfce7;
    border-color:#22c55e;
    color:#065f46;
  }
  .pill{
    border:1px solid rgba(255,255,255,.14);
    background:rgba(255,255,255,.06);
    color:#e5e7eb;
    padding:8px 12px;border-radius:999px;
    cursor:pointer;font-size:13px;user-select:none;
  }
  .pill:hover{background:rgba(255,255,255,.10)}

      .content{
    padding:74px 18px 18px;
    min-width:0;
    overflow:visible;
  }

    .card{
  background:#ffffff;
  border:1px solid #e5e7eb;
  border-radius:14px;
  padding:14px;
  box-shadow:0 1px 2px rgba(15,23,42,0.05);
  transition:all 0.2s ease;
}
.card:hover{
  box-shadow:0 4px 10px rgba(15,23,42,0.08);
  transform:translateY(-1px);
}

  .cardTitle{font-size:26px;font-weight:900;margin:0 0 4px;}
  .cardSub{margin:0 0 14px;color:var(--muted);font-size:14px;}

  .row{
    display:flex;gap:10px;flex-wrap:wrap;align-items:center;
    justify-content:space-between;margin-bottom:12px;
  }
  .leftTools{display:flex;gap:10px;flex-wrap:wrap;align-items:center;}
  .rightTools{display:flex;gap:10px;flex-wrap:wrap;align-items:center;}

  .seg{display:flex;gap:8px;align-items:center;}
  .seg button{
    padding:7px 14px;border-radius:8px;border:1px solid #d1d5db;
    background:#ffffff;color:#0f172a;cursor:pointer;
    font-size:13px;font-weight:800;min-width:110px;height:34px;
  }
  .seg button:hover{background:#f8fafc;}
  .seg button.active{background:#dcfce7;border-color:#22c55e;color:#065f46;}

  .btn{
    padding:8px 14px;border-radius:10px;
    border:1px solid var(--line);
    background:#fff;color:#111827;
    cursor:pointer;font-size:13px;font-weight:800;
  }
  .btn:hover{background:#f8fafc}
  .btn.danger{color:var(--danger);border-color:#f3b4b4;background:#fff5f5;}
  .btn.ok{color:#065f46;border-color:#a7f3d0;background:#ecfdf5;}
  .btn.sm{padding:6px 10px;border-radius:10px;font-size:12px;}

  table{
    width:100%;
    border-collapse:separate;border-spacing:0;
    overflow:hidden;border:1px solid var(--line);
    border-radius:10px;
  }
    thead th{
    text-align:left;font-size:13px;color:#334155;
    background:#f8fafc;padding:10px 12px;
    border-bottom:1px solid var(--line);font-weight:900;
    position: sticky;
    top: 0;
    z-index: 2;
  }
  tbody td{padding:10px 12px;border-bottom:1px solid #eef2f7;font-size:13px;color:#0f172a;}
  tbody tr:hover{background:#fbfdff;cursor:pointer;}
  tbody tr:last-child td{border-bottom:none;}

       .aggTable thead th{
    font-size:11px;
    line-height:1.2;
    padding:8px 10px;
    vertical-align:bottom;
    white-space:normal;
    word-break:normal;
  }

  .aggTable tbody td{
    font-size:12px;
    line-height:1.3;
    padding:8px 10px;
    vertical-align:top;
  }

  .aggTable thead th:nth-child(3),
  .aggTable tbody td:nth-child(3){
    min-width:180px;
  }

  .aggTable thead th:nth-child(9),
  .aggTable tbody td:nth-child(9){
    min-width:150px;
  }

  .aggTable thead th:nth-child(14),
  .aggTable tbody td:nth-child(14){
    min-width:180px;
  }

  .aggTable thead th:nth-child(16),
  .aggTable tbody td:nth-child(16){
    min-width:150px;
  }

  .aggTable thead th:nth-child(17),
  .aggTable tbody td:nth-child(17){
    min-width:160px;
  }

  .empty{color:var(--muted);padding:12px;}

  .modalOverlay{
    position:fixed;inset:0;
    background:rgba(2,6,23,.55);
    display:none;align-items:center;justify-content:center;
    padding:18px;z-index:999;
  }
  .modal{
    width:min(1100px, 100%);
    max-height: calc(100vh - 36px);
    overflow:auto;background:#fff;border-radius:18px;
    border:1px solid rgba(255,255,255,.10);
    box-shadow: 0 14px 60px rgba(0,0,0,.35);
  }
  .modalHeader{
    display:flex;align-items:center;justify-content:space-between;
    padding:16px 18px;border-bottom:1px solid var(--line);
  }
  .modalHeader h2{margin:0;font-size:22px;font-weight:950;}
  .modalBody{padding:16px 18px 20px;}
  .modalFooter{
    display:flex;justify-content:flex-end;gap:10px;
    padding:14px 18px;border-top:1px solid var(--line);
    background:#fbfdff;position:sticky;bottom:0;
  }

  .formGrid.compact{
    display:grid;
    grid-template-columns: repeat(4, minmax(180px, 1fr));
    gap: 12px 18px;
    align-items:end;
    max-width: 980px;
  }
  @media (max-width: 1100px){
    .formGrid.compact{ grid-template-columns: repeat(2, minmax(200px, 1fr)); }
  }
  @media (max-width: 700px){
    .formGrid.compact{ grid-template-columns: 1fr; max-width:100%; }
  }
  .field.compact label{
    display:block;margin:0 0 6px;
    font-size:12px;font-weight:700;color:#334155;
  }
  .field.compact input[type="text"],
  .field.compact input[type="number"],
  .field.compact input[type="date"],
  .field.compact select{
    width:100%;height: var(--barH);
    padding: 6px 10px;border-radius: var(--barRadius);
    border: 1px solid var(--barBorder);
    background: var(--barBg);
    font-size:14px;font-weight:400;outline:none;
  }
  .field.compact input:focus,
  .field.compact select:focus{
    border-color:#a8c8ff;
    box-shadow: 0 0 0 3px rgba(168,200,255,.28);
  }
  .inline.compact{display:flex;gap:10px;align-items:center;flex-wrap:wrap;}
  .span2{ grid-column: span 2; }
  .span4{ grid-column: 1 / -1; }

  .checkRow{
    display:flex;gap:18px;align-items:center;flex-wrap:wrap;margin-top:8px;
  }
  .checkRow label{
    display:flex;gap:8px;align-items:center;
    font-size:13px;font-weight:700;color:#334155;
  }
  .helpText{color:var(--muted);font-size:12px;margin:8px 0 0;}

  .photoWrap{display:flex;gap:12px;align-items:flex-start;flex-wrap:wrap;}
  .photoBox{
    width:150px;height:180px;border:1px solid var(--line);
    border-radius:14px;background:#f8fafc;
    display:flex;align-items:center;justify-content:center;
    overflow:hidden;cursor:pointer;
  }
  .photoBox img{width:100%;height:100%;object-fit:cover;}

  .notice{
    padding:10px 12px;background:#f8fafc;border:1px solid var(--line);
    border-radius:12px;color:#334155;font-size:13px;
  }

    .componentDock{
    display:none;
  }

  .countBadge{
    font-weight:900;
    font-size:14px;
    color:#0f172a;
    padding:6px 10px;
    border-radius:999px;
    border:1px solid var(--line);
    background:#fff;
  }

  .errorBox{
    border:1px solid #fecaca;
    background:#fff7f7;
    color:#991b1b;
    border-radius:12px;
    padding:14px;
    margin-top:12px;
    white-space:pre-wrap;
  }
/* Category / Condition column wrap */
tbody td:nth-child(9){
  max-width: 140px;
  white-space: normal;
  word-break: break-word;
}

thead th:nth-child(9){
  min-width: 140px;
  white-space: normal;
  word-break: normal;
}

/* ===== Dashboard Card Hover Polish ===== */
.card {
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(15,23,42,.08);
  border-color: #cbd5f5;
}

/* IMPORTANT: do not transform the main module workspace card,
   because module modals are rendered inside it */
#viewCard{
  transition:none;
}

#viewCard:hover{
  transform:none;
  box-shadow: 0 1px 0 rgba(15,23,42,.03);
  border-color: var(--line);
}

/* Slightly softer effect for dense tables */
table tr {
  transition: background 0.12s ease;
}

table tr:hover {
  background: #f8fafc;
}

/* ===== Neutral Table Striping ===== */
tbody tr:nth-child(even){
  background:#f8fafc;
}

tbody tr:hover{
  background:#eef2f7;
}

.loginScreen{
  position:fixed;
  inset:0;
  z-index:99999;
  background:linear-gradient(180deg,#0b1220,#0f1b2d);
  display:flex;
  align-items:center;
  justify-content:center;
  padding:20px;
}

.loginCard{
  width:min(420px,100%);
  background:#ffffff;
  border-radius:20px;
  padding:24px;
  box-shadow:0 20px 70px rgba(0,0,0,.35);
  text-align:center;
}

.loginCard img{
  width:82px;
  height:82px;
  object-fit:contain;
  border-radius:16px;
  margin-bottom:12px;
}

.loginCard h1{
  margin:0 0 6px;
  font-size:24px;
  font-weight:950;
  color:#0f172a;
}

.loginCard p{
  margin:0 0 18px;
  color:#64748b;
  font-size:13px;
}

.loginCard input{
  width:100%;
  height:42px;
  border:1px solid #d6dde7;
  border-radius:12px;
  padding:8px 12px;
  font-size:15px;
  outline:none;
}

.loginCard button{
  width:100%;
  margin-top:12px;
  height:42px;
  border:0;
  border-radius:12px;
  background:#0ea5a4;
  color:white;
  font-weight:900;
  cursor:pointer;
}

.loginError{
  display:none;
  margin-top:10px;
  color:#b91c1c;
  font-size:13px;
  font-weight:800;
}


.mobileMenuBtn{
  background:#0f172a;
  border:1px solid rgba(255,255,255,.25);
}

.mobileOverlay{
  display:none;
}

@media (max-width: 800px){
  .mobileMenuBtn{
    display:flex;
    position:fixed;
    top:12px;
    left:10px;
    z-index:80;
    width:42px;
    height:40px;
    border:1px solid rgba(255,255,255,.18);
    border-radius:10px;
    background:#111827;
    color:#ffffff;
    align-items:center;
    justify-content:center;
    font-size:22px;
    font-weight:700;
    cursor:pointer;
  }

  .sidebar{
    transform:translateX(-105%);
    transition:transform .2s ease;
    z-index:90;
  }

  body.mobileNavOpen .sidebar{
    transform:translateX(0);
  }

  .mobileOverlay{
    display:none;
    position:fixed;
    inset:0;
    background:rgba(15,23,42,.45);
    z-index:85;
  }

  body.mobileNavOpen .mobileOverlay{
    display:block;
  }

  .main{
    margin-left:0;
  }

  .topbar{
    left:0;
    min-height:72px;
    height:auto;
    padding:10px 10px 10px 62px;
    align-items:center;
    justify-content:flex-start;
    flex-wrap:wrap;
    gap:8px;
  }

  .crumbs{
    width:100%;
    font-size:12px;
    line-height:1.25;
  }

  .topActions{
  width:100%;
  display:flex;
  gap:6px;
  align-items:center;
  justify-content:flex-start;
  flex-wrap:wrap;
}

/* HIDE desktop back/forward pills on mobile */
#btnBack,
#btnForward{
  display:none;
}

.topComponentHost{
  margin-right:0;
}

.topComponentSelect{
  height:32px;
  min-width:118px;
  padding:5px 9px;
  border-radius:999px;
  background:rgba(255,255,255,.06);
  color:#e5e7eb;
  border:1px solid rgba(255,255,255,.14);
  font-size:12px;
  font-weight:500;
}

.pill{
  padding:7px 10px;
  font-size:12px;
  font-weight:500;
}

.content{
  padding:98px 10px 14px;
}

.row,
.leftTools,
.rightTools{
  align-items:stretch;
}

.leftTools > *,
.rightTools > *{
  width:100%;
  max-width:100%;
}

.seg{
  flex-wrap:wrap;
  width:100%;
}

.seg button{
  flex:1;
  min-width:90px;
}

table{
  display:block;
  overflow-x:auto;
  white-space:nowrap;
}

.modal{
  width:100%;
  max-height:calc(100vh - 20px);
  border-radius:14px;
}

.formGrid.compact{
  grid-template-columns:1fr !important;
}

.span2,
.span4{
  grid-column:1 / -1;
}
}

@media (max-width: 800px){

  /* Mobile dashboard/card polish */
  .card{
    border-radius:12px;
    padding:12px;
  }

  .cardTitle{
    font-size:20px;
  }

  .cardSub{
    font-size:12px;
    margin-bottom:10px;
  }

  /* Dashboard metric cards become compact blocks */
  #viewCard .card{
    padding:10px;
    border-radius:10px;
    box-shadow:none;
  }

  #viewCard [style*="grid-template-columns"]{
    grid-template-columns:1fr !important;
    gap:10px !important;
  }

  #viewCard h2,
  #viewCard h3{
    font-size:16px !important;
    margin-bottom:6px !important;
  }

  #viewCard p{
    font-size:12px !important;
    line-height:1.35 !important;
  }

  #viewCard .countBadge{
    font-size:12px;
    padding:5px 8px;
  }

  /* Make dashboard tables/sections breathe better */
  #viewCard table{
    font-size:12px;
  }

  #viewCard thead th,
  #viewCard tbody td{
    padding:7px 8px;
    font-size:12px;
  }

  /* Reduce large dashboard numbers */
  #viewCard [style*="font-size:32px"],
  #viewCard [style*="font-size:34px"],
  #viewCard [style*="font-size:36px"],
  #viewCard [style*="font-size:40px"]{
    font-size:22px !important;
  }

  /* Reports graph + summary table: full width on mobile */
  #rp_chart_wrap{
    width:100% !important;
    max-width:100% !important;
  }

  #rp_chart_wrap > div[style*="display:flex"]{
    display:block !important;
    width:100% !important;
  }

  #rp_chart_wrap > div[style*="display:flex"] > div{
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin-bottom:12px;
  }

  #rp_chart_summary{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    overflow-x:auto;
  }

  #rp_chart_summary table{
    display:table !important;
    width:100% !important;
    min-width:100% !important;
    table-layout:fixed;
  }

  #rp_chart_summary th,
  #rp_chart_summary td{
    width:auto !important;
  }
}
.hamburger{
  width:22px;
  height:2px;
  background:#ffffff;
  display:block;
  position:relative;
  border-radius:2px;
}

.hamburger::before,
.hamburger::after{
  content:"";
  position:absolute;
  left:0;
  width:22px;
  height:2px;
  background:#ffffff;
  border-radius:2px;
}

.hamburger::before{
  top:-6px;
}

.hamburger::after{
  top:6px;
}


/* MB360 v1.1 - OTP, fast navigation and All Components Chatter */
.otpLoginCard label{display:block;text-align:left;font-size:12px;font-weight:800;color:#475569;margin:8px 0 6px}.otpStep{width:100%}.loginStatus{font-size:12px;color:#047857;font-weight:700;margin-top:10px;min-height:16px}.loginHelp{font-size:11px;color:#64748b;margin-top:12px;line-height:1.4}.loginSecondary{margin-top:7px!important;background:#e2e8f0!important;color:#334155!important}.userPill{max-width:220px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;padding:7px 10px;border-radius:999px;background:rgba(255,255,255,.08);font-size:11px;color:#e2e8f0}.navUnread{margin-left:auto;min-width:18px;height:18px;padding:0 5px;border-radius:99px;background:#ef4444;color:#fff;font-size:10px;display:grid;place-items:center}.adminSummaryGrid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.miniInfo{border:1px solid var(--line);border-radius:12px;padding:14px;background:#f8fafc}.miniInfo b,.miniInfo span{display:block}.miniInfo span{margin-top:5px;color:#475569;font-size:13px;text-transform:capitalize}
.mb-read-only .btn.ok,.mb-read-only #btnNewCreate{opacity:.65}
.chatterHeader{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 18px;border:1px solid #cde6ea;border-radius:16px;background:linear-gradient(135deg,#e9fbf8 0%,#eef6ff 55%,#f8f5ff 100%);box-shadow:0 8px 24px rgba(15,23,42,.06)}.chatterTitleWrap{display:flex;align-items:center;gap:12px;min-width:0}.chatterTitleIcon{width:44px;height:44px;flex:0 0 44px;border-radius:14px;display:grid;place-items:center;background:linear-gradient(145deg,#0f8f87,#2563a8);color:#fff;font-size:22px;box-shadow:0 8px 18px rgba(15,143,135,.20)}.chatterTitleText{min-width:0}.chatterTitleLine{display:flex;align-items:center;gap:9px;flex-wrap:wrap}.chatterTitleLine .cardTitle{margin:0;color:#123a55;font-size:22px;letter-spacing:-.02em}.chatterScopePill{display:inline-flex;align-items:center;gap:5px;padding:4px 9px;border-radius:999px;background:#fff;border:1px solid #bfdce3;color:#16726f;font-size:10px;font-weight:850;box-shadow:0 2px 7px rgba(15,23,42,.05)}.chatterHeader .cardSub{margin:4px 0 0;color:#526b7e}.presenceWrap{position:relative}.onlineCount{border:1px solid #cbd5e1;background:#fff;border-radius:999px;padding:8px 12px;font-weight:750;color:#334155;cursor:pointer}.onlineDot{display:inline-block;width:8px;height:8px;border-radius:50%;background:#22c55e;margin-right:5px}.onlineList{position:absolute;right:0;top:42px;width:260px;max-height:300px;overflow:auto;background:#fff;border:1px solid #dbe3ed;border-radius:14px;box-shadow:0 15px 35px rgba(15,23,42,.17);padding:8px;z-index:80}.onlinePerson{display:flex;gap:9px;align-items:center;padding:9px;border-radius:9px}.onlinePerson:hover{background:#f8fafc}.onlinePerson b,.onlinePerson small{display:block}.onlinePerson small{font-size:10px;color:#64748b;margin-top:2px}.mbChatShell{margin-top:14px;border:1px solid #dbe3ed;border-radius:16px;overflow:visible;background:#f8fafc}.mbChatFeed{height:min(61vh,640px);min-height:360px;overflow:auto;padding:20px;background:#edf3f9;display:flex;flex-direction:column;gap:11px}.mbChatMessage{display:flex;gap:9px;align-items:flex-end;max-width:min(76%,760px)}.mbChatMessage.mine{align-self:flex-end;flex-direction:row-reverse}.mbChatAvatar{width:38px;height:38px;flex:0 0 38px;border-radius:50%;display:grid;place-items:center;background:#dbeafe;color:#1e4f83;font-size:12px;font-weight:850;position:relative}.mbChatAvatar.online:after{content:"";position:absolute;right:0;bottom:0;width:9px;height:9px;border-radius:50%;background:#22c55e;border:2px solid #edf3f9}.mbChatBubble{position:relative;background:#fff;border-radius:16px 16px 16px 5px;padding:9px 12px 10px;min-width:130px;box-shadow:0 2px 8px rgba(15,23,42,.08)}.mine .mbChatBubble{background:#1f8d8a;color:#fff;border-radius:16px 16px 5px 16px}.mbChatMeta{display:flex;gap:8px;align-items:baseline;flex-wrap:wrap;margin-bottom:3px}.mbChatMeta b{font-size:12px}.mbChatMeta span{font-size:10px;color:#64748b}.mine .mbChatMeta span{color:rgba(255,255,255,.75)}.mbChatBubble p{font-size:14px;line-height:1.42;margin:2px 0;word-break:break-word}.emojiOnly .mbChatBubble,.emojiOnly.mine .mbChatBubble{background:transparent;box-shadow:none;color:inherit;min-width:0}.emojiOnly .mbChatBubble p{font-size:44px;line-height:1.1}.emojiOnly .mbChatMeta{color:#334155}.emojiOnly .mbChatMeta span{color:#64748b}.mbChatFile{display:block;margin-top:7px;border:0;border-radius:9px;padding:7px 9px;background:rgba(100,116,139,.12);color:inherit;cursor:pointer}.mbMsgMenu{position:absolute;top:4px;right:6px}.mine .mbMsgMenu{right:auto;left:6px}.mbMsgMenuBtn{border:0;background:transparent;color:inherit;opacity:.65;cursor:pointer}.mbMsgMenuPop{position:absolute;right:0;top:25px;min-width:115px;background:#fff;color:#334155;border:1px solid #dbe3ed;border-radius:10px;box-shadow:0 10px 24px rgba(15,23,42,.16);padding:5px;z-index:20}.mine .mbMsgMenuPop{right:auto;left:0}.mbMsgMenuPop button{width:100%;text-align:left;border:0;background:transparent;padding:7px 8px;border-radius:7px;cursor:pointer}.mbMsgMenuPop button:hover{background:#f1f5f9}.mbReactBtn{position:absolute;bottom:-13px;right:8px;border:0;background:#fff;border-radius:99px;box-shadow:0 2px 8px rgba(15,23,42,.14);cursor:pointer;opacity:0}.mbChatMessage:hover .mbReactBtn{opacity:1}.mine .mbReactBtn{right:auto;left:8px}.mbReactionPicker{position:absolute;bottom:-42px;right:0;display:flex;gap:2px;background:#fff;padding:5px 7px;border-radius:99px;box-shadow:0 8px 24px rgba(15,23,42,.16);z-index:25}.mine .mbReactionPicker{right:auto;left:0}.mbReactionPicker button{border:0;background:transparent;font-size:18px;cursor:pointer}.mbChatReactions{display:flex;gap:4px;flex-wrap:wrap;margin-top:7px}.mbReactionChip{border:0;border-radius:99px;background:#e8eef6;padding:2px 7px;font-size:11px;cursor:pointer}.mine .mbReactionChip{background:rgba(255,255,255,.18);color:#fff}.mbReactionChip.mineReacted{outline:1px solid currentColor}.chatReplyQuote{display:flex;flex-direction:column;width:100%;text-align:left;border:0;border-left:3px solid #60a5fa;background:rgba(96,165,250,.11);border-radius:6px;padding:6px 8px;margin-bottom:6px;color:inherit}.chatReplyQuote b{font-size:11px}.chatReplyQuote span{font-size:11px;opacity:.78;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:420px}.mbChatTyping{height:21px;padding:3px 18px;background:#edf3f9;color:#64748b;font-size:11px;font-style:italic}.mbChatCompose{position:relative;padding:12px 14px;background:#f8fafc}.mbChatInputWrap{display:flex;align-items:flex-end;gap:8px;background:#dfe8f3;border:1px solid #cbd9e9;border-radius:25px;padding:6px 7px 6px 14px}.mbChatInputWrap textarea{flex:1;min-height:42px;max-height:130px;border:0!important;background:transparent!important;box-shadow:none!important;resize:none;padding:10px 4px;font:inherit;outline:0}.mbChatSend{width:42px;height:42px;flex:0 0 42px;border:0;border-radius:50%;background:#168783;color:#fff;font-size:18px;cursor:pointer}.mbChatTools{display:flex;gap:10px;align-items:center;padding:7px 5px 0;font-size:12px;color:#52657b;position:relative}.mbChatTools button,.mbChatTools label{border:0;background:transparent;color:#405a78;cursor:pointer;font-size:12px}.mbChatTools small{margin-left:auto}.mbEmojiPicker{position:absolute;left:14px;bottom:calc(100% + 10px);width:360px;max-width:calc(100vw - 55px);max-height:290px;overflow:auto;display:grid;grid-template-columns:repeat(7,1fr);gap:6px;background:#fff;border:1px solid #dbe3ed;border-radius:16px;box-shadow:0 18px 42px rgba(15,23,42,.22);padding:12px;z-index:120;transform-origin:bottom left}.mbEmojiPicker:after{content:"";position:absolute;left:25px;bottom:-7px;width:14px;height:14px;background:#fff;border-right:1px solid #dbe3ed;border-bottom:1px solid #dbe3ed;transform:rotate(45deg)}.mbEmojiPicker[hidden]{display:none}.mbEmojiPicker button{border:0;background:#f1f5f9;border-radius:9px;min-height:40px;font-size:24px;cursor:pointer}.composerReply{display:flex;justify-content:space-between;gap:8px;background:#eaf2fb;border-left:3px solid #3b82f6;border-radius:8px;padding:7px 9px;margin-bottom:7px}.composerReply div{min-width:0}.composerReply b,.composerReply span{display:block;font-size:11px}.composerReply span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:600px}.composerReply button{border:0;background:transparent;font-size:18px;cursor:pointer}
@media(max-width:900px){.adminSummaryGrid{grid-template-columns:repeat(2,minmax(0,1fr))}.mbChatMessage{max-width:90%}.userPill{display:none}}
@media(max-width:560px){.adminSummaryGrid{grid-template-columns:1fr}.chatterHeader{align-items:flex-start;padding:13px 14px}.chatterTitleIcon{width:38px;height:38px;flex-basis:38px;font-size:19px}.chatterTitleLine .cardTitle{font-size:19px}.mbChatFeed{padding:12px;min-height:330px}.mbChatMessage{max-width:96%}.mbChatAvatar{width:34px;height:34px;flex-basis:34px}.mbEmojiPicker{left:8px;width:calc(100vw - 58px);grid-template-columns:repeat(5,1fr)}.mbChatTools small{display:none}}

.mb-read-only .main .btn.ok,.mb-read-only .main .btn.danger,.mb-read-only .modal .btn.ok,.mb-read-only .modal .btn.danger,.mb-read-only #btnNewCreate{pointer-events:none!important;opacity:.42!important;filter:grayscale(.25)}

/* MB360 v1.1.1 — Staff Chatter navigation */
.navChatter{font-weight:800;position:relative}
.navChatter .navDot{box-shadow:0 0 0 3px rgba(34,197,94,.12)}
.navUnread[hidden]{display:none!important}
.navUnread{margin-left:auto;min-width:19px;height:19px;padding:0 5px;border-radius:999px;background:#ef4444;color:#fff;font-size:10px;font-weight:900;line-height:19px;text-align:center;box-shadow:0 0 0 2px rgba(255,255,255,.10)}

/* MB360 v1.1.3 — WhatsApp-style Staff Chatter polish */
.chatterHeader{
  background:linear-gradient(135deg,#dffafa 0%,#eefcfc 48%,#e8f1f1 100%);
  border-color:#b9e8e8;
  box-shadow:0 10px 28px rgba(71,209,209,.14);
}
.chatterTitleIcon{background:linear-gradient(145deg,#47d1d1,#75a3a3);box-shadow:0 8px 18px rgba(71,209,209,.28)}
.chatterTitleLine .cardTitle{color:#1f5d5d}
.chatterScopePill{border-color:#aee4e4;color:#2b7777;background:#fff}
.chatterHeader .cardSub{color:#4f7373}

.mbChatContent{position:relative;min-width:130px;max-width:100%}
.mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble{
  background:#75a3a3;
  color:#fff;
}
.mbChatMessage.mine:not(.emojiOnly) .mbChatBubble{
  background:#00cc99;
  color:#fff;
}
.mbChatMessage.incoming:not(.emojiOnly) .mbChatMeta span,
.mbChatMessage.mine:not(.emojiOnly) .mbChatMeta span{color:rgba(255,255,255,.82)}
.mbChatMessage.incoming:not(.emojiOnly) .mbChatMeta b,
.mbChatMessage.mine:not(.emojiOnly) .mbChatMeta b{color:#fff}
.mbChatMessage.incoming:not(.emojiOnly) .chatReplyQuote,
.mbChatMessage.mine:not(.emojiOnly) .chatReplyQuote{
  background:rgba(255,255,255,.16);
  border-left-color:rgba(255,255,255,.8);
  color:#fff;
}
.mbChatMessage.incoming:not(.emojiOnly) .mbChatFile,
.mbChatMessage.mine:not(.emojiOnly) .mbChatFile{background:rgba(255,255,255,.16);color:#fff}

/* Reactions and quick actions live below the bubble, never inside it. */
.mbChatBelow{display:flex;align-items:center;gap:6px;min-height:23px;margin-top:3px;padding:0 5px;position:relative}
.mine .mbChatBelow{justify-content:flex-end}
.mbChatReactions{display:flex;gap:4px;flex-wrap:wrap;margin:0}
.mbReactionChip{border:0!important;border-radius:999px;background:transparent!important;padding:1px 4px;font-size:18px;line-height:1.15;cursor:pointer;box-shadow:none!important;color:#334155;display:inline-flex;align-items:center;gap:2px}
.mbReactionChip.mineReacted{outline:0;background:transparent!important;transform:scale(1.05)}
.mbQuickActions{display:flex;align-items:center;gap:2px;opacity:0;transition:opacity .15s ease}
.mbChatMessage:hover .mbQuickActions,.mbChatMessage:focus-within .mbQuickActions{opacity:1}
.mbQuickActions button{width:27px;height:27px;display:grid;place-items:center;border:0;border-radius:50%;background:#fff;color:#496d6d;box-shadow:0 2px 7px rgba(15,23,42,.12);cursor:pointer;font-size:14px}
.mbQuickActions button:hover{background:#e9ffff;color:#187b7b}
.mbReactBtn{position:static;opacity:1;box-shadow:0 2px 7px rgba(15,23,42,.12)}
.mine .mbReactBtn{position:static}
.mbReplyBtn{display:grid}
.mbReactionPicker{position:absolute;bottom:30px;left:4px;right:auto;display:flex;gap:2px;background:#fff;padding:6px 8px;border-radius:999px;box-shadow:0 8px 24px rgba(15,23,42,.18);z-index:125;border:1px solid #e2e8f0}
.mine .mbReactionPicker{left:auto;right:4px}
.mbReactionPicker button{border:0!important;background:transparent!important;font-size:26px;line-height:1;cursor:pointer;padding:3px 4px;border-radius:0;box-shadow:none!important}
.mbReactionPicker button:hover{background:transparent!important;transform:scale(1.16)}

/* Message menu and delete choices. */
.mbMsgMenuPop{min-width:145px;z-index:130}
.mbMsgMenuPop button{font-size:12px}
.mbDeleteDialog[hidden]{display:none}
.mbDeleteDialog{position:fixed;inset:0;background:rgba(15,23,42,.38);display:grid;place-items:center;z-index:500;padding:18px}
.mbDeleteCard{width:min(410px,calc(100vw - 36px));background:#fff;border-radius:18px;padding:18px;box-shadow:0 22px 60px rgba(15,23,42,.28)}
.mbDeleteCard h3{margin:0 0 4px;color:#173f3f;font-size:19px}
.mbDeleteCard>p{margin:0 0 14px;color:#64748b;font-size:13px}
.mbDeleteChoices{display:grid;gap:8px}
.mbDeleteChoices>button{display:flex;align-items:center;gap:11px;width:100%;border:1px solid #dbe5e5;background:#f9fcfc;border-radius:13px;padding:11px 12px;text-align:left;cursor:pointer;color:#334155}
.mbDeleteChoices>button:hover{background:#eefafa;border-color:#b9e2e2}
.mbDeleteChoices>button>span{font-size:19px}
.mbDeleteChoices b,.mbDeleteChoices small{display:block}
.mbDeleteChoices small{font-size:10px;color:#64748b;margin-top:2px}
.mbDeleteChoices .deleteForEveryone{color:#b42318;background:#fff8f7;border-color:#f1d1cd}
.mbDeleteChoices .deleteForEveryone:hover{background:#fff0ee;border-color:#e9b5af}
.mbDeleteCancel{width:100%;margin-top:10px;border:0;border-radius:11px;padding:10px;background:#eef2f2;color:#426565;font-weight:750;cursor:pointer}

/* Composer: visually separate the popup from the typing area. */
.mbChatCompose{padding-top:14px}
.mbEmojiPicker{bottom:calc(100% + 16px);border-color:#cfe2e2;box-shadow:0 20px 48px rgba(15,23,42,.25)}
.mbChatInputWrap{background:#edf5f5;border-color:#cbdede}
.mbChatSend{background:#47d1d1;color:#fff;box-shadow:0 4px 12px rgba(71,209,209,.28)}
.mbChatSend:hover{filter:brightness(.95)}
.mbChatTools small b{color:#2e7777}

@media(max-width:700px){
  .mbQuickActions{opacity:1}
  .mbChatBelow{min-height:26px}
  .mbReactionPicker{max-width:calc(100vw - 70px);overflow-x:auto}
}


/* MB360 v1.1.4 — Chatter refinements */
.mbChatMessage.mine:not(.emojiOnly) .mbChatBubble{background:#00cc99;color:#fff}
.mbReactionChip .reactionEmoji{font-size:22px;line-height:1}
.mbReactionChip .reactionCount{font-size:11px;font-weight:800;color:#64748b;line-height:1}
.mbChatTools #mbEmojiBtn{display:inline-flex;align-items:center;gap:6px;font-size:14px;font-weight:750;padding:3px 5px}
.mbChatTools #mbEmojiBtn .composerEmojiIcon{font-size:24px;line-height:1}
.mbQuickActions .mbDeleteQuickBtn{color:#a33;background:#fff}
.mbQuickActions .mbDeleteQuickBtn:hover{background:#fff1f0;color:#b42318}
\n\n/* MB360 v1.1.5 — final WhatsApp-style Chatter corrections */
.mbChatMessage.mine:not(.emojiOnly) .mbChatBubble{background:#00cc99!important;color:#fff!important}
.mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble{background:#75a3a3!important;color:#fff!important}

/* Reactions: larger, clean and borderless under each bubble. */
.mbChatBelow{margin-top:4px;min-height:31px;gap:8px}
.mbChatReactions{gap:6px;align-items:center}
.mbReactionChip,
.mbReactionChip.mineReacted{
  border:0!important;outline:0!important;background:transparent!important;
  box-shadow:none!important;border-radius:0!important;padding:0 2px!important;
  display:inline-flex;align-items:center;gap:3px;transform:none!important
}
.mbReactionChip .reactionEmoji{font-size:29px!important;line-height:1!important}
.mbReactionChip .reactionCount{font-size:12px!important;font-weight:850;color:#52657b!important;line-height:1}
.mbReactionChip:hover .reactionEmoji{transform:scale(1.12)}

/* Reply / React / Delete are message-level actions beneath the bubble. */
.mbQuickActions{opacity:1!important;gap:5px}
.mbQuickActions button{
  width:30px;height:30px;border:0!important;box-shadow:none!important;
  background:transparent!important;color:#48666f;font-size:18px
}
.mbQuickActions button:hover{background:rgba(255,255,255,.6)!important;color:#176b69;transform:scale(1.08)}
.mbQuickActions .mbDeleteQuickBtn{color:#b42318!important}

/* Larger composer emoji button. */
.mbChatTools #mbEmojiBtn{font-size:15px!important;gap:7px;padding:5px 7px!important}
.mbChatTools #mbEmojiBtn .composerEmojiIcon{font-size:31px!important;line-height:1!important}

/* Emoji picker stays clearly above the composer. */
.mbEmojiPicker{bottom:calc(100% + 18px)!important;z-index:220!important}
.mbEmojiPicker button{font-size:27px!important}

/* Make the per-message overflow affordance easier to discover. */
.mbMsgMenuBtn{font-size:20px!important;font-weight:900;opacity:.82!important;padding:0 3px!important}

/* MB360 v1.1.6 — deleted-message cleanup + subtle chatter navigation */
.navChatter{
  font-weight:400;
}
.navChatter.active{
  font-weight:400;
}
.navChatter .navUnread{
  position:relative;
  align-self:flex-start;
  margin-left:0;
  margin-top:-5px;
  min-width:15px;
  height:15px;
  padding:0 4px;
  border-radius:999px;
  background:#ef4444;
  color:#fff;
  font-size:9px;
  font-weight:800;
  line-height:15px;
  text-align:center;
  box-shadow:none;
}

/* A deleted message becomes a small quiet placeholder instead of a full chat bubble. */
.mbChatMessage.deleted{
  max-width:260px;
  gap:0;
  opacity:.96;
}
.mbChatMessage.deleted .mbChatAvatar{
  display:none;
}
.mbChatMessage.deleted .mbChatContent{
  min-width:0;
}
.mbChatMessage.deleted .mbChatBubble,
.mbChatMessage.deleted.mine .mbChatBubble,
.mbChatMessage.deleted.incoming .mbChatBubble{
  min-width:0;
  max-width:230px;
  padding:7px 11px;
  border:1px solid #e2e8f0;
  border-radius:11px;
  background:#f8fafc!important;
  color:#64748b!important;
  box-shadow:0 1px 3px rgba(15,23,42,.05);
}
.mbChatMessage.deleted .mbChatMeta{
  display:none;
}
.mbChatMessage.deleted .mbChatBubble p{
  margin:0;
  font-size:12px;
  line-height:1.25;
  color:#64748b!important;
  white-space:nowrap;
}
.mbChatMessage.deleted .mbChatBubble p em{
  font-style:italic;
  font-weight:500;
}
.mbChatMessage.deleted .chatReplyQuote,
.mbChatMessage.deleted .mbMsgMenu,
.mbChatMessage.deleted .mbChatBelow{
  display:none!important;
}


/* MB360 v1.1.7 — deleted messages are lines only, never bubbles */
.mbChatDeletedLine{
  display:flex;
  width:100%;
  margin:5px 0;
  padding:0 12px;
  box-sizing:border-box;
  pointer-events:none;
}
.mbChatDeletedLine.mine{justify-content:flex-end;}
.mbChatDeletedLine.incoming{justify-content:flex-start;}
.mbChatDeletedLine span{
  display:inline-block;
  padding:0;
  border:0;
  background:transparent;
  box-shadow:none;
  color:#94a3b8;
  font-size:12px;
  font-style:italic;
  font-weight:400;
  line-height:1.35;
}

/* MB360 v1.1.8 — chat readability refinements */
/* Keep sender/title/meta sizing unchanged; enlarge only the main message text. */
.mbChatBubble p{
  font-size:17px!important;
  line-height:1.48!important;
}
/* Keep deleted-message placeholder intentionally small/subtle. */
.mbChatDeletedLine span{
  font-size:12px!important;
  line-height:1.35!important;
}
/* Slightly reduce the composer emoji indicator from the previous oversized version. */
.mbChatTools #mbEmojiBtn .composerEmojiIcon{
  font-size:27px!important;
  line-height:1!important;
}

/* MB360 v1.1.9 — stronger chatter readability + sticky compact emoji control */
/* Main message body only: keep sender/title/meta sizes unchanged. */
.mbChatBubble p{
  font-size:20px!important;
  line-height:1.52!important;
}

/* Keep the composer/tool area visible while the chatter/page is scrolled. */
.mbChatCompose{
  position:sticky!important;
  bottom:0!important;
  z-index:140!important;
  background:#f8fafc!important;
  box-shadow:0 -5px 14px rgba(15,23,42,.06);
}

/* Reduce the bottom Emoji indicator while keeping it easy to tap. */
.mbChatTools #mbEmojiBtn{
  font-size:13px!important;
  padding:3px 5px!important;
  gap:5px!important;
}
.mbChatTools #mbEmojiBtn .composerEmojiIcon{
  font-size:22px!important;
  line-height:1!important;
}

/* Mobile must remain readable instead of visually shrinking the conversation. */
@media(max-width:560px){
  .mbChatBubble p{
    font-size:19px!important;
    line-height:1.5!important;
  }
  .mbChatTools #mbEmojiBtn{
    font-size:12px!important;
    padding:2px 4px!important;
    gap:4px!important;
  }
  .mbChatTools #mbEmojiBtn .composerEmojiIcon{
    font-size:20px!important;
  }
  .mbChatCompose{
    bottom:0!important;
  }
}

/* MB360 v1.1.10 — full-bleed chatter + stronger mobile readability */
/* Flatten only the Staff Chatter workspace; other modules keep their cards. */
#viewCard:has(.chatterHeader){
  padding:0!important;
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  background:#edf3f9!important;
  overflow:visible!important;
}
#viewCard:has(.chatterHeader):hover{
  border:0!important;
  box-shadow:none!important;
}
.chatterHeader{
  margin:0!important;
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  background:#e7f8f7!important;
  padding:14px 18px!important;
}
.mbChatShell{
  margin-top:0!important;
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  background:#edf3f9!important;
  overflow:visible!important;
}
.mbChatFeed{
  border:0!important;
  border-radius:0!important;
  background:#edf3f9!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  scrollbar-gutter:stable;
}
/* Remove the thin empty strip immediately before the composer. */
.mbChatTyping:empty{
  display:none!important;
  height:0!important;
  min-height:0!important;
  padding:0!important;
  margin:0!important;
  border:0!important;
}
.mbChatTyping{
  border:0!important;
}
.mbChatCompose{
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  background:#f8fafc!important;
}
/* Main chat text: larger on desktop and especially on phones. */
.mbChatBubble p{
  font-size:21px!important;
  line-height:1.5!important;
}
/* Bottom emoji trigger: compact but still easy to tap; remains sticky with composer. */
.mbChatTools #mbEmojiBtn{
  font-size:12px!important;
  padding:2px 4px!important;
  gap:4px!important;
}
.mbChatTools #mbEmojiBtn .composerEmojiIcon{
  font-size:19px!important;
  line-height:1!important;
}
@media(max-width:560px){
  #viewCard:has(.chatterHeader){
    margin-left:-14px!important;
    margin-right:-14px!important;
  }
  .chatterHeader{
    padding:12px 14px!important;
  }
  .mbChatFeed{
    padding:12px 10px!important;
  }
  .mbChatBubble p{
    font-size:22px!important;
    line-height:1.48!important;
  }
  .mbChatTools #mbEmojiBtn{
    font-size:11px!important;
    padding:2px 3px!important;
    gap:3px!important;
  }
  .mbChatTools #mbEmojiBtn .composerEmojiIcon{
    font-size:17px!important;
  }
}


/* MB360 v1.1.14 — definitive chatter typography + simplified message metadata */
/* Desktop message body: slightly smaller. */
#viewCard .mbChatFeed .mbChatMessage:not(.emojiOnly) .mbChatBubble > p{
  font-size:17px!important;
  line-height:1.48!important;
  -webkit-text-size-adjust:100%;
  text-size-adjust:100%;
}

/* Message header now contains time only. Put it quietly at the top edge. */
#viewCard .mbChatMeta.mbChatTimeOnly{
  display:flex!important;
  margin:0 0 3px!important;
  padding:0!important;
  min-height:0!important;
  line-height:1!important;
}
#viewCard .mbChatMessage.incoming .mbChatMeta.mbChatTimeOnly{justify-content:flex-start!important;}
#viewCard .mbChatMessage.mine .mbChatMeta.mbChatTimeOnly{justify-content:flex-end!important;}
#viewCard .mbChatMeta.mbChatTimeOnly span{
  font-size:9px!important;
  line-height:1.1!important;
  font-weight:500!important;
  opacity:.72!important;
  color:inherit!important;
}

/* Phones: intentionally large message text. Two detection paths ensure this
   applies even on mobile browsers that report an unusual CSS viewport width. */
@media screen and (max-width:900px){
  html{-webkit-text-size-adjust:100%!important;text-size-adjust:100%!important;}
  #viewCard .mbChatFeed .mbChatMessage:not(.emojiOnly) .mbChatBubble > p{
    font-size:26px!important;
    line-height:1.46!important;
  }
  #viewCard .mbChatFeed .mbChatMessage{max-width:88%!important;}
}
@media screen and (hover:none) and (pointer:coarse){
  #viewCard .mbChatFeed .mbChatMessage:not(.emojiOnly) .mbChatBubble > p{
    font-size:26px!important;
    line-height:1.46!important;
  }
}


/* MB360 v1.1.15 — chatter bubble colours + balanced text sizing */
.mbChatMessage.mine:not(.emojiOnly) .mbChatBubble{
  background:#70dbdb!important;
  color:#000!important;
}
.mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble{
  background:#b3cccc!important;
  color:#000!important;
}
.mbChatMessage:not(.emojiOnly) .mbChatBubble,
.mbChatMessage:not(.emojiOnly) .mbChatBubble p,
.mbChatMessage:not(.emojiOnly) .mbChatBubble span,
.mbChatMessage:not(.emojiOnly) .mbChatBubble b,
.mbChatMessage:not(.emojiOnly) .mbChatBubble em,
.mbChatMessage:not(.emojiOnly) .mbChatBubble button,
.mbChatMessage:not(.emojiOnly) .mbChatBubble a{
  color:#000!important;
}
#viewCard .mbChatMessage:not(.emojiOnly) .mbChatBubble p{
  font-size:16px!important;
  line-height:1.45!important;
}
@media screen and (max-width:900px){
  #viewCard .mbChatMessage:not(.emojiOnly) .mbChatBubble p{
    font-size:20px!important;
    line-height:1.46!important;
  }
}
@media screen and (hover:none) and (pointer:coarse){
  #viewCard .mbChatMessage:not(.emojiOnly) .mbChatBubble p{
    font-size:20px!important;
    line-height:1.46!important;
  }
}


/* MB360 v1.1.16 — softer chatter palette, compact typography, vertical-only composer scroll */

/* Conversation itself never scrolls sideways. */
#viewCard .mbChatFeed{
  overflow-y:auto!important;
  overflow-x:hidden!important;
  overscroll-behavior-x:none;
}

/* Softer outgoing bubble: muted teal, white text. */
#viewCard .mbChatMessage.mine:not(.emojiOnly) .mbChatBubble{
  background:#6fb8b8!important;
  color:#fff!important;
}
#viewCard .mbChatMessage.mine:not(.emojiOnly) .mbChatBubble,
#viewCard .mbChatMessage.mine:not(.emojiOnly) .mbChatBubble p,
#viewCard .mbChatMessage.mine:not(.emojiOnly) .mbChatBubble span,
#viewCard .mbChatMessage.mine:not(.emojiOnly) .mbChatBubble b,
#viewCard .mbChatMessage.mine:not(.emojiOnly) .mbChatBubble em,
#viewCard .mbChatMessage.mine:not(.emojiOnly) .mbChatBubble button,
#viewCard .mbChatMessage.mine:not(.emojiOnly) .mbChatBubble a{
  color:#fff!important;
}

/* Softer incoming bubble: pale grey-teal, black text. */
#viewCard .mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble{
  background:#d9e6e6!important;
  color:#000!important;
}
#viewCard .mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble,
#viewCard .mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble p,
#viewCard .mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble span,
#viewCard .mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble b,
#viewCard .mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble em,
#viewCard .mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble button,
#viewCard .mbChatMessage.incoming:not(.emojiOnly) .mbChatBubble a{
  color:#000!important;
}

/* Smaller, balanced body text. */
#viewCard .mbChatFeed .mbChatMessage:not(.emojiOnly) .mbChatBubble > p{
  font-size:15px!important;
  line-height:1.42!important;
}
@media screen and (max-width:900px), screen and (hover:none) and (pointer:coarse){
  #viewCard .mbChatFeed .mbChatMessage:not(.emojiOnly) .mbChatBubble > p{
    font-size:17px!important;
    line-height:1.44!important;
  }
}

/* Composer: vertical scrolling only; long text wraps instead of creating horizontal scroll. */
#viewCard .mbChatInputWrap{
  min-width:0!important;
  overflow:hidden!important;
}
#viewCard .mbChatInputWrap textarea{
  min-width:0!important;
  width:100%!important;
  max-width:100%!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  white-space:pre-wrap!important;
  overflow-wrap:anywhere!important;
  word-break:break-word!important;
  resize:none!important;
}

/* Keep native pinch zoom available on the chat page. */
html,body,#viewCard{
  touch-action:pan-x pan-y pinch-zoom;
}
