/* NAVNIT BLISTER | MASTER / ENTRY / QUOTATION FORMS
   Shared app controls remain in style.css. This file only contains
   form-layout styling using the nb-form-* naming pattern.
   Load after style.css. */

:root {
  --nb-form-text: #364452;
  --nb-form-focus: #ca7124;
}

.nb-rich-text-page {
  min-width: 0;
  padding: 14px;
}

.nb-quill-editor .ql-toolbar.ql-snow {
  border-color: #d1d8df;
  background: #f7f8fa;
}

.nb-quill-editor .ql-container.ql-snow {
  border-color: #d1d8df;
}

.nb-quill-editor .ql-editor {
  color: #414b55;
  font-family: inherit;
  font-size: 14px;
}

.nb-rich-text-quill-editor.ql-container.ql-snow {
  height: 65vh;
  min-height: 320px;
}

.nb-rich-text-fieldset {
  min-width: 0;
  margin: 0;
  border: 0;
  padding: 0;
}

.nb-rich-text-page .nb-rich-text-quill-editor {
  min-width: 0;
}

.nb-email-quill-editor.ql-container.ql-snow {
  height: 260px;
  min-height: 220px;
  max-height: 320px;
  border-radius: 3px;
}

.nb-email-quill-editor .ql-editor {
  min-height: 220px;
  max-height: 320px;
  overflow-y: auto;
}

.nb-quill-editor .ql-toolbar button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.nb-quill-editor .ql-editor[contenteditable='false'] {
  background: #eef1f4;
}

.nb-form-screen-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
  padding: 4px 8px 8px;
}

.nb-form-screen-actions .btn {
  width: 250px;
  height: 40px;
  min-height: 40px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
}

@media (min-width: 1200px) {
  .nb-quotation-actions {
    display: flex;
    margin-right: -5px;
    margin-left: -5px;
  }

  .nb-quotation-actions > .nb-quotation-action {
    width: auto;
    min-width: 0;
    flex: 1 1 0;
    float: none;
    padding-right: 5px;
    padding-left: 5px;
  }

  .nb-quotation-actions .btn {
    padding-right: 4px;
    padding-left: 4px;
    font-size: 12px;
  }
}

/* Quotation form layout */
.nb-form-content {
  min-height: 0;
  flex: 1 1 auto;
  min-width: 0;
  padding: 8px;
  background: #fff;
  color: var(--nb-form-text);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.nb-quotation-form-content .form-group {
  margin-bottom: 11px;
}

.nb-form-content .form-group > label {
  margin-bottom: 2px;
  color: #4e5459;
  font-size: 12px;
  font-weight: 400;
}

.nb-form-panel {
  min-width: 0;
  padding: 14px;
  border: 1px solid #dfe5eb;
  border-radius: 5px;
  background: #fff;
}

.nb-costing-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-right: -7px;
  margin-left: -7px;
}

.nb-costing-fields::before,
.nb-costing-fields::after {
  display: none;
}

.nb-costing-fields > [class*='col-'] {
  width: auto;
  min-width: 0;
  padding-right: 7px;
  padding-left: 7px;
}

.nb-costing-fields .form-control {
  min-width: 0;
}

@media (max-width: 359px) {
  .nb-costing-fields {
    grid-template-columns: minmax(0, 1fr);
  }
}

.nb-account-section + .nb-account-section {
  margin-top: 14px;
}

#toast-container.toast-top-right {
  position: fixed;
  z-index: 2147483647;
  top: 16px;
  right: 16px;
  left: auto;
  pointer-events: none;
}

#toast-container > .toast {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(420px, calc(100vw - 32px));
  min-height: 82px;
  margin: 0 0 12px;
  padding: 18px 46px 18px 74px !important;
  overflow: hidden;
  border: 1.5px solid transparent;
  border-radius: 10px;
  background-image: none !important;
  opacity: 1 !important;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.12) !important;
  pointer-events: auto;
  white-space: pre-line;
}

#toast-container > .toast:hover {
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.16) !important;
}

#toast-container > .toast-info {
  border-color: #9acfea;
  background-color: #d9edf7 !important;
  color: #2b6684 !important;
}

#toast-container > .toast-warning {
  border-color: #e2cf93;
  background-color: #fcf8e3 !important;
  color: #8a6d3b !important;
}

#toast-container > .toast-error {
  border-color: #dca7a7;
  background-color: #f2dede !important;
  color: #a94442 !important;
}

#toast-container > .toast-success {
  border-color: #b2dba1;
  background-color: #dff0d8 !important;
  color: #3c763d !important;
}

#toast-container .toast-message {
  display: flex;
  align-items: center;
  margin: 0;
  color: inherit !important;
  font-size: 15px;
  line-height: 1.45;
  word-break: break-word;
}

#toast-container .nb-toast-body {
  min-width: 0;
  color: inherit;
}

#toast-container .nb-toast-heading {
  font-weight: 700;
}

#toast-container .nb-toast-text {
  font-weight: 500;
}

#toast-container .nb-toast-icon-wrap {
  position: absolute;
  top: 50%;
  left: 16px;
  display: flex;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  color: inherit;
  transform: translateY(-50%);
}

#toast-container .nb-toast-ring-svg {
  position: absolute;
  inset: 0;
  width: 44px;
  height: 44px;
  transform: rotate(-90deg);
}

#toast-container .nb-toast-ring-track {
  fill: none;
  stroke: currentColor;
  stroke-opacity: 0.2;
  stroke-width: 3;
}

#toast-container .nb-toast-ring-progress {
  fill: none;
  stroke: currentColor;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-dasharray: 119.38;
  stroke-dashoffset: 0;
  animation-name: nb-toast-ring-countdown;
  animation-timing-function: linear;
  animation-fill-mode: forwards;
}

#toast-container > .toast:hover .nb-toast-ring-progress {
  animation-play-state: paused;
}

#toast-container .nb-toast-glyph {
  position: relative;
  z-index: 1;
  width: 22px;
  height: 22px;
}

@keyframes nb-toast-ring-countdown {
  from {
    stroke-dashoffset: 0;
  }
  to {
    stroke-dashoffset: 119.38;
  }
}

#toast-container .toast-close-button {
  position: absolute;
  top: 50%;
  right: 14px;
  width: 28px;
  height: 28px;
  padding: 0;
  border-radius: 50%;
  color: inherit !important;
  font-size: 24px;
  font-weight: 600;
  line-height: 26px;
  text-align: center;
  text-shadow: none !important;
  opacity: 0.45 !important;
  transform: translateY(-50%);
  transition: opacity 0.15s ease, background-color 0.15s ease;
}

#toast-container .toast-close-button:hover,
#toast-container .toast-close-button:focus {
  background: rgba(0, 0, 0, 0.06);
  opacity: 0.85 !important;
}

@media (max-width: 767px) {
  #toast-container.toast-top-right {
    top: 12px;
    right: 12px;
    left: auto;
  }

  #toast-container > .toast {
    width: min(340px, calc(100vw - 24px));
    min-height: 76px;
    padding: 16px 42px 16px 66px !important;
    border-radius: 10px;
  }

  #toast-container .nb-toast-icon-wrap,
  #toast-container .nb-toast-ring-svg {
    width: 38px;
    height: 38px;
  }

  #toast-container .nb-toast-icon-wrap {
    left: 14px;
  }

  #toast-container .nb-toast-glyph {
    width: 19px;
    height: 19px;
  }

  #toast-container .toast-message {
    font-size: 14px;
  }
}

.nb-account-form .form-group {
  margin-bottom: 8px;
}

.nb-form-costing {
  border-color: #fefcf7;
  background: #f5f3f1ad;
}

.nb-form-costing .form-control {
  height: 34px;
  padding: 5px 9px;
  font-size: 13px;
}

.nb-form-panel-title {
  margin: 0 0 8px;
  color: #767b7f;
  font-size: 14px;
  font-weight: 600;
}

.nb-po-material-table {
  table-layout: fixed;
}

.nb-po-page {
  padding: 8px 10px 12px;
  background: #f5f7fa;
}

.nb-po-page .nb-form-action-fieldset {
  min-width: 0;
  margin: 0;
  border: 0;
  padding: 0;
}

.nb-po-container {
  overflow: visible;
  border: 1px solid #e0e6ec;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 3px 12px rgba(35, 49, 63, 0.06);
  padding: 4px 12px 8px;
}

.nb-po-panel {
  overflow: visible;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.nb-po-panel .panel-heading {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 0 10px;
  border: 0;
  background: transparent;
}

.nb-po-panel .panel-title {
  color: #344250;
  font-size: 15px;
  font-weight: 650;
}

.nb-po-panel .panel-body {
  padding: 4px 0 16px;
}

.nb-po-materials-panel {
  border-top: 1px solid #e9edf1;
}

.nb-po-materials-panel .panel-heading {
  padding-top: 17px;
}

.nb-po-panel .form-group {
  margin-bottom: 14px;
}

.nb-po-panel label {
  margin-bottom: 6px;
  color: #536170;
  font-size: 12px;
  font-weight: 600;
}

.nb-po-panel .form-control {
  height: 40px;
  border-color: #d7dee6;
  border-radius: 5px;
  color: #344250;
  font-size: 13px;
  box-shadow: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.nb-po-panel .form-control:focus {
  border-color: #ed9b54;
  box-shadow: 0 0 0 3px rgba(245, 130, 32, 0.12);
}

.nb-po-panel textarea.form-control {
  height: auto;
  min-height: 76px;
  resize: vertical;
}

.nb-po-panel .form-control[readonly] {
  background: #f3f5f7;
  color: #687684;
}

.nb-po-panel-hint {
  color: #84909b;
  font-size: 11px;
}

.nb-po-material-add-field {
  padding-top: 25px;
}

.nb-po-material-add-field .btn {
  min-height: 40px;
  border-radius: 5px;
  font-weight: 600;
}

.nb-po-material-table {
  margin-bottom: 0;
  border-color: #e1e6eb;
  font-size: 12px;
}

.nb-po-material-table > thead > tr > th {
  border-bottom-width: 1px;
  background: #f4f6f8;
  color: #4f5d6a;
  font-weight: 600;
  vertical-align: middle;
}

.nb-po-material-table > tbody > tr > td {
  vertical-align: middle;
}

.nb-po-material-table .form-control {
  height: 32px;
  padding: 5px 8px;
  font-size: 12px;
}

.nb-po-material-table .btn-danger {
  border-radius: 4px;
}

.nb-po-totals {
  margin: 12px 0 14px;
}

.nb-po-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin-right: -7px;
  margin-left: -7px;
  padding-top: 4px;
}

.nb-po-actions > [class*='col-'] {
  padding-right: 7px;
  padding-left: 7px;
}

.nb-po-actions .btn {
  min-height: 42px;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 600;
}

@media (max-width: 767px) {
  .nb-po-page {
    padding: 12px 10px 20px;
  }

  .nb-po-container {
    padding: 4px 12px 10px;
  }

  .nb-po-panel .panel-body {
    padding: 4px 0 12px;
  }

  .nb-po-panel .panel-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
    padding: 13px 0 8px;
  }

  .nb-po-material-add-field {
    padding-top: 0;
  }

  .nb-po-material-table {
    min-width: 760px;
  }

  .nb-po-totals {
    margin-top: 4px;
  }

  .nb-po-actions {
    display: block;
  }
}

.nb-form-identification {
  margin-bottom: 12px;
}

.nb-form-workspace {
  margin-bottom: 12px;
}

.nb-form-workspace > [class*='col-'],
.nb-form-lower-grid > [class*='col-'] {
  padding-right: 6px;
  padding-left: 6px;
}

.nb-form-workspace.row,
.nb-form-lower-grid.row {
  margin-right: -6px;
  margin-left: -6px;
}

.nb-form-rate-strip {
  margin-top: 10px;
}

.nb-form-rate-strip-highlight .form-control {
  border-color: #e8df8a;
  background: #fffde1;
}

.nb-form-rate-strip-muted {
  padding-top: 10px;
  border-top: 1px solid #e0e0e0;
}

.nb-form-gap-grid {
  margin-top: 10px;
}

.nb-form-fields-material {
  margin-top: 10px;
  padding-top: 9px;
  border-top: 1px solid #e5e9ed;
}

.nb-form-costing .row {
  margin-right: -6px;
  margin-left: -6px;
}

.nb-form-costing .row > [class*='col-'] {
  padding-right: 6px;
  padding-left: 6px;
}

.nb-form-drawing-panel {
  display: flex;
  flex-direction: column;
}

@media (min-width: 992px) {
  .nb-form-workspace.row {
    display: flex;
    align-items: stretch;
  }

  .nb-form-workspace > [class*='col-'] {
    display: flex;
    flex-direction: column;
  }

  .nb-form-costing,
  .nb-form-drawing-panel {
    flex: 1 1 auto;
  }

  .nb-form-drawing-canvas {
    flex: 1 1 auto;
    max-height: none;
  }
}

.nb-form-drawing-title {
  min-height: 24px;
  margin: 0 0 8px;
  color: #45515b;
  font-size: 13px;
  font-weight: 600;
}

.nb-form-drawing-canvas {
  display: block;
  width: 100%;
  min-height: 200px;
  border: 1px solid #d3d9df;
  background: #fff;
}

.nb-form-candidate-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 9px;
}

.nb-form-candidate-label {
  flex: 0 0 100%;
  color: #78838d;
  font-size: 11px;
}

.nb-form-candidate-chip {
  display: inline-block;
  padding: 4px 7px;
  border: 1px solid #d3d9df;
  border-radius: 3px;
  background: #f7f8f9;
  color: #45515b;
  font-size: 11px;
  line-height: 1.4;
}

.nb-form-candidate-chip.selected {
  border-color: #f58220;
  background: #fff2e7;
  color: #9c4c0c;
  font-weight: 600;
}

.nb-form-lower-grid {
  margin-bottom: 12px;
}

.nb-form-cost-table {
  width: 100%;
  margin: 0 0 12px;
  border-collapse: collapse;
  table-layout: fixed;
  color: #59636c;
  font-size: 14px;
}

.nb-form-cost-table > thead > tr > th,
.nb-form-cost-table > tbody > tr > th,
.nb-form-cost-table > tbody > tr > td {
  padding: 5px 6px;
  border-bottom: 1px solid #e7eaed79;
  vertical-align: middle;
}

.nb-form-cost-table > thead > tr > th {
  color: #4f5b66;
  font-size: 14px;
  font-weight: 700;
  text-align: left;
}

.nb-form-cost-table > tbody > tr > th {
  width: 40%;
  font-weight: 400;
  text-align: left;
}

.nb-form-cost-table > thead > tr > th:nth-child(2),
.nb-form-cost-table > tbody > tr > td:nth-child(2) {
  width: 20%;
}

.nb-form-cost-table > thead > tr > th:nth-child(3),
.nb-form-cost-table > tbody > tr > td:nth-child(3) {
  width: 40%;
}

.nb-form-cost-table > tbody > tr > td {
  background: transparent;
  text-align: left;
}

.nb-form-cost-table .form-control {
  height: 35px;
  padding: 5px 7px;
  font-size: 14px;
  text-align: left;
}

.nb-form-cost-table td:empty::after {
  content: '\00a0';
}

.nb-form-terms-column {
  min-width: 0;
}

.nb-form-terms-column > .nb-form-panel + .nb-form-panel {
  margin-top: 12px;
}

.nb-form-currency-panel.row {
  margin: 0 -6px;
}

.nb-form-currency-panel > [class*='col-'] {
  padding-right: 6px;
  padding-left: 6px;
}

.nb-form-total-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 0 12px;
  overflow: hidden;
  border: 1px solid #dfe5eb;
  border-radius: 5px;
  background: #fff;
}

.nb-form-total-row {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
}

.nb-form-total-row + .nb-form-total-row {
  border-left: 1px solid #dfe5eb;
}

.nb-form-total-row span {
  min-width: 0;
  color: #77818a;
  font-size: 14px;
}

.nb-form-total-row strong {
  flex: 0 0 auto;
  color: #33404d;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}

.nb-form-grand-total {
  border-left: 2px solid #b7e8d9 !important;
  background: #d9f6ed;
}

.nb-form-grand-total span,
.nb-form-grand-total strong {
  color: #203d35;
  font-weight: 700;
}

.nb-form-grand-total span {
  font-size: 15px;
}

.nb-form-grand-total strong {
  font-size: 20px;
}

.nb-form-modal-backdrop {
  position: fixed;
  z-index: 1100;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(22, 30, 38, 0.55);
}

.nb-form-confirmation-backdrop {
  z-index: 1200;
}

.nb-form-progress-backdrop {
  position: fixed;
  z-index: 1300;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow: hidden;
  background: rgba(22, 30, 38, 0.48);
  overscroll-behavior: none;
  touch-action: none;
}

.nb-form-progress-dialog {
  display: flex;
  min-width: 220px;
  min-height: 96px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 12px;
  padding: 20px 24px;
  border: 1px solid #dfe5eb;
  border-radius: 6px;
  background: #fff;
  color: #364452;
  font-size: 14px;
  text-align: center;
  box-shadow: 0 10px 30px rgba(22, 30, 38, 0.2);
}

.nb-form-progress-spinner {
  width: 34px;
  height: 34px;
  border: 4px solid #e5e9ed;
  border-top-color: #f58220;
  border-radius: 50%;
  animation: nb-form-progress-spin 0.75s linear infinite;
}

@keyframes nb-form-progress-spin {
  to {
    transform: rotate(360deg);
  }
}

.nb-form-modal {
  display: flex;
  width: min(760px, 100%);
  max-height: calc(100vh - 32px);
  flex-direction: column;
  overflow: hidden;
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.25);
}

.nb-form-modal > header,
.nb-form-modal > footer {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  padding: 13px 17px;
  border-bottom: 1px solid #dfe5eb;
}

.nb-form-modal > header h3 {
  margin: 0;
  font-size: 20px;
}

.nb-form-modal > footer {
  justify-content: flex-end;
  gap: 8px;
  border-top: 1px solid #dfe5eb;
  border-bottom: 0;
}

.nb-form-modal-close {
  border: 0;
  background: transparent;
  color: #727c85;
  font-size: 24px;
}

.nb-whatsapp-modal {
  width: min(620px, 100%);
}

.nb-whatsapp-message {
  min-height: 260px;
  resize: vertical;
  white-space: pre-wrap;
}

.nb-form-modal > footer.nb-whatsapp-modal-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.nb-whatsapp-modal-actions .btn {
  width: 100%;
  height: 40px;
}

.nb-form-modal-body {
  display: block;
  overflow: auto;
  padding: 17px;
}

.nb-form-modal-body > .form-group {
  margin-bottom: 12px;
}

@media (max-width: 991px) {
  .nb-form-terms-column {
    margin-top: 12px;
  }
}

@media (min-width: 768px) and (max-width: 991px) {
  .nb-rich-text-shell {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 0;
    overflow: hidden;
  }

  .nb-rich-text-content,
  .nb-rich-text-form,
  .nb-rich-text-fieldset,
  .nb-rich-text-page {
    display: flex;
    min-height: 0;
    flex-direction: column;
  }

  .nb-rich-text-content,
  .nb-rich-text-form,
  .nb-rich-text-fieldset,
  .nb-rich-text-page {
    flex: 1 1 auto;
  }

  .nb-rich-text-content {
    overflow: hidden;
    padding: 0;
  }

  .nb-rich-text-page {
    margin: 0;
    padding: 10px;
  }

  .nb-rich-text-page > .nb-rich-text-quill-editor {
    display: flex;
    min-height: 0;
    flex: 1 1 auto;
    flex-direction: column;
  }

  .nb-rich-text-page .ql-toolbar.ql-snow {
    flex: 0 0 auto;
  }

  .nb-rich-text-page .nb-rich-text-quill-editor.ql-container.ql-snow {
    height: auto;
    min-height: 0;
    flex: 1 1 auto;
    overflow: hidden;
  }

  .nb-rich-text-page .ql-editor {
    height: 100%;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nb-rich-text-form > .nb-form-screen-actions {
    position: sticky;
    z-index: 2;
    bottom: 0;
    flex: 0 0 auto;
    margin: 0;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
    border-top: 1px solid #e6e9ed;
    background: #fff;
  }

  .nb-rich-text-form > .nb-form-screen-actions .btn {
    width: 250px;
    height: 40px;
    min-height: 40px;
    font-size: 14px;
  }
}

@media (max-width: 767px) {
  .nb-rich-text-shell {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    min-height: 0;
    overflow: hidden;
  }

  .nb-rich-text-content {
    display: flex;
    min-height: 0;
    flex: 1 1 auto;
    flex-direction: column;
    overflow: hidden;
    padding: 0;
  }

  .nb-rich-text-form {
    display: flex;
    min-height: 0;
    flex: 1 1 auto;
    flex-direction: column;
  }

  .nb-rich-text-fieldset {
    display: flex;
    min-height: 0;
    flex: 1 1 auto;
    flex-direction: column;
  }

  .nb-rich-text-page {
    display: flex;
    min-height: 0;
    flex: 1 1 auto;
    flex-direction: column;
    margin: 0;
    padding: 8px;
    border: 0;
    border-radius: 0;
  }

  .nb-rich-text-page > .nb-rich-text-quill-editor {
    display: flex;
    min-height: 0;
    flex: 1 1 auto;
    flex-direction: column;
  }

  .nb-rich-text-page .ql-toolbar.ql-snow {
    flex: 0 0 auto;
  }

  .nb-rich-text-page .nb-rich-text-quill-editor.ql-container.ql-snow {
    height: auto;
    min-height: 0;
    flex: 1 1 auto;
    overflow: hidden;
  }

  .nb-rich-text-page .ql-editor {
    height: 100%;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nb-rich-text-form > .nb-form-screen-actions {
    position: sticky;
    z-index: 2;
    bottom: 0;
    flex: 0 0 auto;
    margin: 0;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
    border-top: 1px solid #e6e9ed;
    background: #fff;
  }

  .nb-rich-text-form > .nb-form-screen-actions .btn {
    width: 250px;
    height: 40px;
    min-height: 40px;
    font-size: 14px;
  }

  body.nb-app-mobile-webview .nb-rich-text-shell {
    height: 100vh;
    height: 100dvh;
    min-height: 0;
  }

  .nb-body-container > .nb-form-content:not(.nb-rich-text-content) {
    padding: 4px 10px 18px;
  }

  .nb-form-content:not(.nb-rich-text-content) {
    flex: 0 0 auto;
    overflow: visible;
  }

  .nb-form-fields-material {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    grid-template-areas:
      'material material material material material material'
      'thickness thickness thickness product-qty product-qty product-qty'
      'vendor vendor vendor vendor vendor vendor'
      'gravity gravity gravity sheet-qty sheet-qty sheet-qty'
      'misc misc misc misc misc misc'
      'development development development misc-cost misc-cost misc-cost';
    margin-right: -6px;
    margin-left: -6px;
  }

  .nb-form-fields-material > .row {
    display: contents;
  }

  .nb-form-fields-material > .row::before,
  .nb-form-fields-material > .row::after {
    display: none;
  }

  .nb-form-fields-material > .row > [class*='col-'] {
    float: none;
    width: auto;
    min-width: 0;
    padding-right: 6px;
    padding-left: 6px;
  }

  .nb-quotation-field-material { grid-area: material; }
  .nb-quotation-field-thickness { grid-area: thickness; }
  .nb-quotation-field-product-qty { grid-area: product-qty; }
  .nb-quotation-field-vendor { grid-area: vendor; }
  .nb-quotation-field-specific-gravity { grid-area: gravity; }
  .nb-quotation-field-sheet-qty { grid-area: sheet-qty; }
  .nb-quotation-field-misc { grid-area: misc; }
  .nb-quotation-field-development-cost { grid-area: development; }
  .nb-quotation-field-misc-cost { grid-area: misc-cost; }

  .nb-form-rate-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-right: -4px;
    margin-left: -4px;
  }

  .nb-form-rate-strip::before,
  .nb-form-rate-strip::after {
    display: none;
  }

  .nb-form-rate-strip > .nb-quotation-field-rate,
  .nb-form-rate-strip > .nb-quotation-field-cost {
    float: none;
    width: auto;
    min-width: 0;
    padding-right: 4px;
    padding-left: 4px;
  }

  .nb-form-rate-strip .form-group > label {
    min-height: 2.5em;
    font-size: 10px;
    line-height: 1.25;
    overflow-wrap: anywhere;
  }

  .nb-form-rate-strip .form-control {
    min-width: 0;
    padding-right: 4px;
    padding-left: 4px;
    font-size: 12px;
  }

  .nb-form-total-strip {
    grid-template-columns: minmax(0, 1fr);
  }

  .nb-form-total-row {
    padding: 9px 12px;
  }

  .nb-form-total-row + .nb-form-total-row {
    border-top: 1px solid #dfe5eb;
    border-left: 0;
  }

  .nb-form-grand-total {
    border-top: 2px solid #b7e8d9 !important;
    border-left: 0 !important;
  }

  .nb-quotation-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-right: -5px;
    margin-left: -5px;
  }

  .nb-quotation-actions::before,
  .nb-quotation-actions::after {
    display: none;
  }

  .nb-quotation-actions > .nb-quotation-action {
    float: none;
    width: auto;
    min-width: 0;
    padding-right: 5px;
    padding-left: 5px;
  }

  .nb-quotation-actions .btn {
    min-height: 42px;
    padding: 6px 4px;
    font-size: 11px;
    line-height: 1.25;
    white-space: normal;
  }
}

@media (max-width: 359px) {
  .nb-form-screen-actions .btn,
  .nb-rich-text-form > .nb-form-screen-actions .btn {
    width: 100%;
  }

  .nb-form-rate-strip {
    grid-template-columns: minmax(0, 1fr);
  }

  .nb-form-rate-strip .form-group > label {
    min-height: 0;
    font-size: 12px;
  }
}

/* FastSelect remains a third-party component; these rules are scoped without renaming its internal classes. */
.nb-form-content .fstdiv,
.nb-body-container .fstdiv {
  width: 100%;
  min-height: 35px;
}

.nb-form-content .fstdropdown,
.nb-body-container .fstdropdown {
  min-height: 35px;
  border: 1px solid #cfd7df;
  border-radius: 2px;
  font-family: inherit;
  box-shadow: none;
}

.nb-form-content .fstdropdown > .fstselected,
.nb-body-container .fstdropdown > .fstselected {
  min-height: 33px;
  padding: 5px 28px 5px 8px;
  color: #414b55;
  font-size: 14px;
  box-shadow: none;
}

.nb-form-content .fstdropdown[aria-disabled='true'],
.nb-body-container .fstdropdown[aria-disabled='true'] {
  opacity: 0.65;
  pointer-events: none;
}

.nb-form-content .fstdropdown .fstsearchinput,
.nb-body-container .fstdropdown .fstsearchinput {
  border-color: #d1d8df;
  font: inherit;
}

.nb-form-content .fstdropdown.open,
.nb-body-container .fstdropdown.open {
  border-color: var(--nb-form-focus);
  box-shadow: 0 0 0 3px rgba(202, 113, 36, 0.1);
}

.nb-po-panel .fstdiv,
.nb-master-modal-fields .fstdiv {
  min-height: 40px;
}

.nb-po-panel .fstdropdown,
.nb-master-modal-fields .fstdropdown {
  min-height: 40px;
  border-color: #d7dee6;
  border-radius: 5px;
}

.nb-po-panel .fstdropdown > .fstselected,
.nb-master-modal-fields .fstdropdown > .fstselected {
  min-height: 38px;
  padding: 8px 28px 8px 10px;
  color: #344250;
  font-size: 13px;
}
