* {
  box-sizing: border-box;
}

:root {
  --brand-accent: #eda300;
  --brand-accent-hover: #d49400;
  --brand-accent-focus: rgba(237, 163, 0, 0.35);
  --brand-support: #2f6fb4;
  --brand-support-hover: #255e99;
  --brand-support-focus: rgba(47, 111, 180, 0.28);
}

body {
  margin: 0;
  font-family: "Helvetica Neue", Arial, sans-serif;
  background: #f5f3ef;
  color: #1c1c1c;
}

.container {
  max-width: 1100px;
  margin: 40px auto;
  padding: 0 24px 60px;
}

.page-header {
  margin-bottom: 24px;
  padding-bottom: 14px;
  border-bottom: 1px solid #dfdbd1;
}

.page-header h1 {
  margin: 0;
  font-size: 30px;
}

.page-header__bar {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto auto;
  gap: 18px;
  align-items: center;
}

.page-header__title {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.page-header__logo {
  height: 88px;
  width: auto;
  max-width: 239px;
  object-fit: contain;
  flex: 0 0 auto;
}

.page-header p {
  margin: 10px 0 0;
  color: #555;
}

.card {
  background: #fff;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
}

.card h2 {
  margin-top: 0;
  margin-bottom: 16px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.proposal-summary-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(280px, 1fr);
  gap: 24px;
  align-items: start;
}

.proposal-summary-block h2 {
  margin-bottom: 16px;
}

.proposal-summary-block--contact {
  padding-left: 24px;
  border-left: 1px solid #e9e1d1;
}

.proposal-contact-grid {
  grid-template-columns: 1fr;
}

label {
  display: flex;
  flex-direction: column;
  font-weight: 600;
  font-size: 14px;
  gap: 6px;
}

label.debug-toggle {
  flex-direction: row;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  margin-bottom: 16px;
}

label.debug-toggle input {
  width: 16px;
  height: 16px;
  accent-color: var(--brand-accent);
}

input,
textarea,
select {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid #d9d9d9;
  font-size: 14px;
  font: inherit;
  line-height: 1.35;
}

textarea {
  width: 100%;
  min-height: 96px;
  resize: vertical;
  font-family: "Helvetica Neue", Arial, sans-serif;
}

input:disabled,
textarea:disabled,
select:disabled {
  background: #f5f1e8;
  color: #544b3d;
  border-color: #ddd2c1;
  cursor: not-allowed;
}

.rich-editor {
  margin-top: 8px;
}

.terms-toolbar {
  border: 1px solid #d9d9d9;
  border-radius: 10px 10px 0 0;
  background: #f7f5f2;
}

.terms-editor {
  border: 1px solid #d9d9d9;
  border-top: none;
  border-radius: 0 0 10px 10px;
  min-height: 140px;
  background: #fff;
  font-size: 14px;
}

.terms-editor .ql-editor {
  min-height: 140px;
  padding: 12px;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
}

.item-input-wrapper {
  position: relative;
}

.autocomplete-results {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: #fff;
  border: 1px solid #e2e2e2;
  border-radius: 10px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
  padding: 6px 0;
  max-height: 240px;
  overflow-y: auto;
  display: none;
  z-index: 10;
}

.autocomplete-results.is-open {
  display: block;
}

.autocomplete-portal {
  position: fixed;
  background: #fff;
  border: 1px solid #e2e2e2;
  border-radius: 10px;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.14);
  padding: 6px 0;
  min-width: 420px;
  max-width: 640px;
  max-height: 320px;
  overflow-y: auto;
  display: none;
  z-index: 9999;
}

.autocomplete-portal.is-open {
  display: block;
}

.autocomplete-result {
  width: 100%;
  background: transparent;
  border: none;
  padding: 12px 14px;
  text-align: left;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  font-size: 13px;
  color: #1c1c1c;
}

.resultRow {
  align-items: flex-start;
  min-height: 56px;
}

.resultMeta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 0;
}

.resultCode {
  display: block;
  font-size: 13px;
  font-weight: 700;
}

.resultDesc {
  font-size: 12px;
  color: #555;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.resultPrice {
  font-weight: 600;
  white-space: nowrap;
  align-self: center;
}

.autocomplete-result.is-active,
.autocomplete-result:hover {
  background: #f3efe9;
}

.autocomplete-empty {
  padding: 8px 12px;
  font-size: 13px;
  color: #666;
}

.table-wrapper {
  overflow-x: auto;
  padding-right: 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  min-width: 0;
}

th,
td {
  text-align: left;
  padding: 10px;
  border-bottom: 1px solid #ececec;
}

th {
  background: #f8f5f1;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 12px;
}

#items-table th {
  background: var(--brand-accent);
  color: #ffffff;
}

.description-col {
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
}

#items-table th.description-col,
#items-table td.description-col {
  width: 42%;
}

#items-table th.qty-col,
#items-table td.qty-col {
  width: 80px;
  text-align: right;
}

#items-table th.unit-price-col,
#items-table td.unit-price-col {
  width: 120px;
  text-align: right;
}

#items-table input {
  width: 100%;
}

/* Prevent right-edge clipping of actions button while retaining table layout. */
.actions-col {
  width: 90px;
  min-width: 90px;
}

.line-items-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.quotes-list-header {
  margin-bottom: 16px;
}

.quotes-filter-control {
  margin: 0;
  padding: 14px 16px;
  border: 1px solid #e6decd;
  border-radius: 12px;
  background: #faf8f4;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45);
  gap: 8px;
}

.quotes-filter-control select {
  min-width: 200px;
  margin-top: 0;
}

.quotes-filter-bar {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

.quotes-filter-control--search {
  min-width: min(320px, 100%);
  flex: 1 1 260px;
}

.quotes-filter-control--search input {
  min-width: 220px;
}

.quotes-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #ece6d9;
}

.quotes-pagination__summary {
  margin: 0;
}

.quotes-page-size-control {
  margin: 0;
  gap: 8px;
}

.quotes-page-size-control select {
  min-width: 96px;
}

.quotes-pagination__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.line-items-actions {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 10px;
  background: #f8f5f1;
}

.line-items-actions label {
  margin: 0;
}

.line-items-actions select {
  min-width: 210px;
}

.line-items-add-row {
  padding-top: 12px;
  padding-left: 10px;
}

button {
  border: none;
  border-radius: 999px;
  padding: 10px 18px;
  font-weight: 600;
  cursor: pointer;
  background: var(--brand-accent);
  color: #fff;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

button,
.button-link,
.button-link--outline,
.button-ghost {
  max-width: 100%;
}

button:hover {
  background: var(--brand-accent-hover);
}

button:focus-visible {
  outline: 2px solid transparent;
  box-shadow: 0 0 0 3px var(--brand-accent-focus);
}

.line-item-actions {
  text-align: right;
}

.remove-line-item {
  background: transparent;
  color: #c0392b;
  border: 1px solid #e0b4ae;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  min-height: 40px;
  min-width: 40px;
}

.remove-line-item:hover {
  background: #fbeaea;
}

button.primary {
  width: 100%;
  padding: 14px;
  font-size: 16px;
}

#add-line,
#add-line-item-detail {
  background: var(--brand-support);
}

#add-line:hover,
#add-line-item-detail:hover {
  background: var(--brand-support-hover);
}

#add-line:focus-visible,
#add-line-item-detail:focus-visible {
  box-shadow: 0 0 0 3px var(--brand-support-focus);
}

.totals {
  max-width: 280px;
  margin-left: auto;
  margin-top: 16px;
  border-top: 1px solid #e6e6e6;
  padding-top: 12px;
}

.totals-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.totals-row--grand {
  font-size: 18px;
  font-weight: 700;
}

.hint {
  margin-top: 12px;
  color: #555;
}

.extended {
  text-align: right;
}

.catalog-search input {
  max-width: 420px;
}

.catalog-results {
  margin-top: 16px;
  display: grid;
  gap: 12px;
}

.catalog-result {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  background: #f9f6f1;
  border-radius: 10px;
}

.catalog-result__desc {
  margin-top: 4px;
  font-size: 13px;
  color: #555;
}

.catalog-result__price {
  font-weight: 600;
  white-space: nowrap;
}


@media (max-width: 980px) {
  .page-header__bar {
    grid-template-columns: 1fr;
    justify-items: start;
    gap: 12px;
  }

  .auth-controls {
    width: 100%;
    justify-content: flex-start;
  }
}

@media (max-width: 560px) {
  .page-header h1 {
    font-size: 24px;
  }

  .page-header__logo {
    height: 69px;
  }

  .page-nav {
    width: 100%;
  }

  .page-nav a {
    flex: 1;
  }

  .signed-in-user {
    max-width: 100%;
  }
}

@media (max-width: 700px) {
  .container {
    margin-top: 20px;
  }

  button.primary {
    font-size: 15px;
  }

  .proposal-summary-layout {
    grid-template-columns: 1fr;
  }

  .proposal-summary-block--contact {
    padding-left: 0;
    border-left: 0;
    border-top: 1px solid #e9e1d1;
    padding-top: 20px;
  }

  .reset-password-page {
    min-height: auto;
    padding-top: 32px;
    padding-bottom: 24px;
  }

  .reset-password-card {
    width: 100%;
    padding: 28px 24px;
  }
}

@media (max-width: 760px) {
  .container {
    margin: 18px auto 0;
    padding: 0 14px 40px;
  }

  .card {
    padding: 18px 16px;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  input,
  textarea,
  select {
    font-size: 16px;
  }

  .table-wrapper {
    padding-right: 0;
  }

  .line-items-header,
  .quotes-filter-bar,
  .quotes-pagination,
  .page-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .page-actions > * {
    width: 100%;
  }

  .line-items-actions,
  .quotes-filter-control,
  .quotes-page-size-control {
    width: 100%;
    min-width: 0;
  }

  .quotes-filter-control--search {
    min-width: 0;
  }

  .quotes-filter-control select,
  .quotes-filter-control input,
  .quotes-page-size-control select,
  .line-items-actions select {
    min-width: 0;
    width: 100%;
  }

  .quotes-filter-bar > button {
    width: 100%;
  }

  .totals {
    max-width: none;
    width: 100%;
  }

  .quote-detail-top-actions {
    width: 100%;
    justify-content: stretch;
  }

  .quote-detail-top-actions button {
    flex: 1 1 100%;
  }

  .quote-edit-banner {
    flex-direction: column;
    align-items: flex-start;
  }

  .quote-edit-banner__jump {
    margin-left: 0;
  }

  .autocomplete-portal {
    left: 12px !important;
    right: 12px !important;
    min-width: 0;
    width: auto !important;
    max-width: calc(100vw - 24px);
  }

  .autocomplete-result {
    flex-direction: column;
    align-items: flex-start;
  }

  .resultPrice {
    align-self: flex-start;
  }
}

/* Mobile preview breakpoint: adjust as needed for line items table. */
@media (max-width: 768px) {
  .table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  #items-table {
    min-width: 720px;
  }
}

@media (max-width: 760px) {
  #items-table {
    min-width: 0;
    table-layout: auto;
  }

  #items-table thead,
  #quote-items-table thead,
  .quotes-table thead {
    display: none;
  }

  #items-table,
  #quote-items-table,
  .quotes-table {
    min-width: 0;
    table-layout: auto;
  }

  #quote-items-table colgroup {
    display: none;
  }

  #items-table tbody,
  #quote-items-table tbody,
  .quotes-table tbody,
  #items-table tbody tr,
  #quote-items-table tbody tr,
  .quotes-table tbody tr {
    display: block;
  }

  #items-table tbody tr,
  #quote-items-table tbody tr,
  .quotes-table tbody tr {
    display: block;
    border: 1px solid #ececec;
    border-radius: 12px;
    margin-bottom: 12px;
    padding: 4px 0;
    background: #fff;
  }

  #items-table tbody td,
  #quote-items-table tbody td,
  .quotes-table tbody td {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: 10px 12px;
    border-bottom: 1px solid #f0f0f0;
    width: 100%;
  }

  #items-table tbody td::before,
  #quote-items-table tbody td::before,
  .quotes-table tbody td::before {
    content: attr(data-label);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 11px;
    color: #666;
    flex: 0 0 auto;
  }

  #items-table tbody td:last-child,
  #quote-items-table tbody td:last-child,
  .quotes-table tbody td:last-child {
    border-bottom: none;
  }

  #items-table td.line-item-actions {
    align-items: flex-end;
  }

  #items-table td.line-item-actions::before {
    content: "";
  }

  #items-table input {
    min-width: 0;
    width: 100%;
  }

  #quote-items-body .quote-item-cell--qty,
  #quote-items-body .quote-item-cell--price,
  #quote-items-body .quote-item-cell--total,
  #quote-items-body .quote-item-cell--actions,
  .quotes-table tbody td {
    text-align: left;
    white-space: normal;
  }

  #quote-items-body .quote-item-cell--actions:empty {
    display: none;
  }

  #quote-items-body .quote-item-row--edit td.quote-item-cell--total {
    padding-top: 10px;
  }

  .quote-item-remove-btn,
  .quotes-table tbody td:last-child a {
    display: inline-flex;
    width: 100%;
    justify-content: center;
  }
}

.page-nav {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px;
  border: 1px solid #d9d3c5;
  border-radius: 999px;
  background: #f8f5ef;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.page-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  color: #5b5240;
  border-radius: 999px;
  padding: 8px 18px;
  min-height: 36px;
  line-height: 1;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.page-nav a:hover {
  background: #efe9de;
  transform: translateY(-1px);
}

.page-nav a[aria-current="page"] {
  background: var(--brand-accent);
  color: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.auth-controls {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.signed-in-user {
  font-size: 13px;
  color: #464646;
  background: #f2eee6;
  border: 1px solid #ddd7cc;
  border-radius: 999px;
  padding: 7px 12px;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.button-link,
.button-link--outline,
.button-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  border-radius: 999px;
  padding: 8px 14px;
}

.button-link {
  border: 1px solid var(--brand-accent);
  background: var(--brand-accent);
  color: #fff;
}

.button-link:hover {
  background: var(--brand-accent-hover);
}

.button-link--outline {
  color: #51493a;
  border: 1px solid #d3cebf;
  background: #fff;
}

.button-link--outline:hover {
  background: #f5f3ed;
}

.button-ghost {
  border: 1px solid #d3cebf;
  background: transparent;
  color: #51493a;
}

.button-ghost:hover {
  background: #f5f3ed;
}

.button-ghost:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  background: transparent;
}

.auth-card {
  max-width: 600px;
}

.auth-grid {
  margin-bottom: 16px;
}

.reset-password-page {
  min-height: calc(100vh - 80px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 40px;
  padding-bottom: 40px;
}

.reset-password-card {
  width: min(100%, 720px);
  padding: 44px 48px;
  margin-bottom: 0;
}

.reset-password-card h1 {
  margin-bottom: 12px;
  font-size: 34px;
}

.reset-password-card .hint {
  margin-bottom: 24px;
  max-width: 42ch;
  font-size: 15px;
}

.reset-password-card .auth-grid {
  display: grid;
  gap: 20px;
  margin-bottom: 0;
}

.reset-password-card input[type="password"] {
  min-height: 48px;
}

.reset-password-card button {
  justify-self: start;
  min-width: 180px;
}

.reset-password-card #reset-password-status {
  margin: 0;
  min-height: 1.25rem;
}

button.secondary {
  background: #efefef;
  color: #333;
  border: 1px solid #d7d7d7;
}

button.secondary:hover {
  background: #dfdfdf;
}

button.danger {
  background: #c9354c;
  color: #fff;
  border: 1px solid #a8293d;
}

button.danger:hover {
  background: #b42f44;
}

.page-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
  flex-wrap: wrap;
}


body.auth-pending main {
  visibility: hidden;
}


.quote-detail-page {
  display: grid;
  gap: 18px;
}

.quote-detail-header {
  border-bottom: 1px solid #ece6d8;
  padding-bottom: 10px;
}

.quote-detail-header__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.quote-detail-top-actions {
  margin-top: 0;
  justify-content: flex-end;
}

.quote-edit-banner {
  margin-top: 12px;
  margin-bottom: 16px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #7f5f16;
  background: #ffefc6;
  color: #4f3a08;
  font-size: 14px;
  display: none;
  gap: 8px;
  align-items: baseline;
  flex-wrap: wrap;
}

.quote-edit-mode .quote-detail-header {
  border-bottom-color: #cfb470;
}

.quote-edit-mode .quote-edit-banner {
  display: flex;
}

.quote-edit-banner__jump {
  margin-left: auto;
  color: #4f3a08;
  font-weight: 700;
  text-decoration: underline;
}

.quote-edit-banner__jump:hover {
  color: #2f2205;
}

.quote-edit-save-anchor {
  scroll-margin-top: 160px;
}

.quote-detail-header .hint {
  margin: 6px 0 0;
}

.quote-detail-history-jump a {
  color: #5e3aa1;
  font-weight: 700;
  text-decoration: underline;
}

.quote-detail-history-jump a:hover {
  color: #4a2c83;
}

.quote-detail-section {
  padding: 14px;
  border: 1px solid #eee8dd;
  border-radius: 12px;
  background: #fcfbf9;
  margin-bottom: 14px;
}

.quote-view-mode #detail-edit-form input:disabled,
.quote-view-mode #detail-edit-form select:disabled {
  border: 0;
  background: transparent;
  padding: 0;
  color: #1f1f1f;
  font-size: 14px;
  font-weight: 500;
  cursor: default;
  appearance: none;
}

.quote-view-mode #detail-edit-form label {
  gap: 4px;
}

.quote-view-mode #detail-edit-form label::after {
  content: "";
  display: block;
  border-bottom: 1px solid #efe9dd;
  margin-top: 7px;
}

.quote-detail-section h3 {
  margin: 0 0 12px;
  font-size: 16px;
}

.quote-detail-notes {
  background: #f8f5ef;
}

#terms-notes-display {
  font-size: 14px;
  line-height: 1.5;
  color: #1f1f1f;
}

#terms-notes-display:empty::after {
  content: "No notes";
  color: #999;
  font-style: italic;
}

#terms-notes-editor-wrap .terms-editor {
  min-height: 80px;
}

#quote-conflict {
  color: #a83f2f;
  font-weight: 600;
  background: #fce8e5;
  border: 1px solid #e8b4ac;
  border-radius: 8px;
  padding: 10px 12px;
}

#quote-items-table {
  width: 100%;
  table-layout: fixed;
}

#quote-items-body .quote-item-row td {
  vertical-align: middle;
  padding: 14px 12px;
}

#quote-items-table .quote-items-col--item {
  width: 28%;
}

#quote-items-table .quote-items-col--description {
  width: 27%;
}

#quote-items-table .quote-items-col--qty {
  width: 9%;
}

#quote-items-table .quote-items-col--unit {
  width: 12%;
}

#quote-items-table .quote-items-col--total {
  width: 13%;
}

.quote-edit-mode #quote-items-table .quote-items-col--actions {
  width: 11%;
}

.quote-view-mode #quote-items-table .quote-items-col--actions {
  width: 0;
}

.quote-view-mode .quote-item-cell--actions,
.quote-view-mode .quote-item-actions-header {
  display: none;
}

.quote-line-items-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
}

body.quote-view-mode .quote-line-items-actions {
  display: none;
}

.quote-item-actions-header {
  text-align: center;
}

#quote-items-body .quote-item-row--view td {
  font-size: 14px;
}

#quote-items-body .quote-item-row--view td.quote-item-cell--description {
  color: #3d3d3d;
}

#quote-items-table th:nth-child(3),
#quote-items-table th:nth-child(4),
#quote-items-table th:nth-child(5),
#quote-items-body .quote-item-cell--qty,
#quote-items-body .quote-item-cell--price,
#quote-items-body .quote-item-cell--total {
  text-align: right;
  white-space: nowrap;
}

#quote-items-body .quote-item-cell--actions {
  text-align: center;
}

.quote-item-remove-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  min-width: 96px;
  white-space: nowrap;
}

#quote-items-body .quote-item-row--edit input {
  min-height: 38px;
  min-width: 0;
  width: 100%;
}

#quote-items-body .quote-item-row--edit td {
  vertical-align: top;
}

#quote-items-body .quote-item-row--edit td.quote-item-cell--qty input,
#quote-items-body .quote-item-row--edit td.quote-item-cell--price input {
  text-align: right;
  padding: 8px 6px;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

#quote-items-body .quote-item-row--edit td.quote-item-cell--qty,
#quote-items-body .quote-item-row--edit td.quote-item-cell--price {
  padding-left: 4px;
  padding-right: 4px;
}

#quote-items-body .quote-item-row--edit td.quote-item-cell--total {
  padding-top: 20px;
}

.quote-items-total {
  text-align: right;
  margin: 12px 2px 0;
}

.quote-history-section {
  background: #faf8f4;
}

.quote-history-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.quote-history-list {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
  display: grid;
  gap: 10px;
}

.quote-history-item,
.quote-history-empty {
  border: 1px solid #e6decd;
  border-radius: 10px;
  background: #fff;
  padding: 12px;
}

.quote-history-item__top {
  display: flex;
  align-items: center;
  gap: 8px;
}

.quote-history-version {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  border-radius: 999px;
  padding: 3px 9px;
  background: #f4ebd8;
  color: #5b4c2e;
  font-weight: 700;
  font-size: 12px;
}

.quote-history-action {
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 11px;
  color: #6b614d;
  font-weight: 700;
}

.quote-history-meta,
.quote-history-note,
.quote-history-fields {
  margin: 8px 0 0;
  font-size: 13px;
  color: #403b30;
}

.quote-history-details {
  margin-top: 8px;
}

.quote-history-diff-list {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.quote-history-diff-item {
  font-size: 13px;
  color: #403b30;
  line-height: 1.45;
}

.quote-history-diff-item--more {
  color: #6b614d;
  font-style: italic;
}

.quote-history-diff-value {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  background: #f4efe3;
  color: #433928;
}

.quote-history-diff-arrow {
  display: inline-block;
  margin: 0 4px;
  color: #8b7b5f;
  font-weight: 700;
}
