@font-face {
  font-family: "Product Sans";
  src: url("ProductSans-Light.otf") format("opentype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Product Sans";
  src: url("ProductSans-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Product Sans";
  src: url("ProductSans-LightItalic.otf") format("opentype");
  font-weight: 300;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Product Sans";
  src: url("ProductSans-Italic.otf") format("opentype");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

/* Placeholder styles */
.placeholder-text {
  color: #999 !important;
  font-style: italic;
  user-select: none;
  pointer-events: none;
}

/* Google Fonts para seleção de fonte */

/* Define customizable brand color and font */
:root {
  --brand-color: #707070;
  --font-family: "Product Sans", Arial, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  background: #f5f5f5;
  color: #333;
  line-height: 1;
  /* ensure full-height layout so footer can be pushed to bottom */
  min-height: 100vh;
  padding-top: 40px; /* Space for the fixed menu */
}

.container {
  /* Fixed pixel sheet size requested: 900 x 1273 px */
  width: 900px;
  height: 1250px;
  margin: 20px auto;
  background: white;
  padding: 20px;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.header {
  /* text-align: center; */
  padding: 30px 38px;
  /* border-bottom: 2px solid var(--brand-color); */
  min-height: 137px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.logo {
  width: 150px;
  /* margin-bottom: 20px; */
  transition: box-shadow 120ms ease, transform 120ms ease;
  margin-left: 30px;
}

/* Controls container next to header logo */
.logo-controls {
  margin-top: 8px;
}

/* Visual feedback when dragging an image over the logo */
.logo.logo-drag-over {
  box-shadow: 0 0 0 4px rgba(51, 122, 183, 0.15);
  transform: translateY(-2px);
}

/* Keep .btn-export look consistent for logo button small size */
.logo-controls .btn-export {
  padding: 8px 12px;
  font-size: 14px;
  display: inline-block;
}

.order-title {
  font-size: 24px;
  color: #4e4e4e;
  font-weight: 400;
  float: right;
  margin-right: 22px;
}

/* Added PDF export button styles */
.btn-export-pdf {
  background: #e74c3c;
  color: white;
  border: none;
  padding: 10px 18px;
  cursor: pointer;
  font-family: "Product Sans", Arial, sans-serif;
  font-size: 14px;
  font-weight: 600;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background 0.2s ease;
  position: absolute;
  right: 38px;
  top: 50px;
}

.btn-export-pdf:hover {
  background: #c0392b;
}

.btn-export-pdf i {
  font-size: 16px;
}

/* New style for export button */
.btn-export {
  background: #4caf50;
  color: white;
  border: none;
  padding: 10px 20px;
  margin-top: 15px;
  cursor: pointer;
  font-family: "Product Sans", Arial, sans-serif;
  font-size: 16px;
  font-weight: 600;
  border-radius: 4px;
}

.btn-export:hover {
  background: #45a049;
}

.section-title {
  background: var(--brand-color);
  color: white;
  padding: 3px 15px;
  font-size: 16px;
  font-weight: 400;
  margin: 10px 0 15px;
  text-align: center;
  border-radius: 3px 3px 0 0;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
}

.customer-info {
  margin-bottom: 5px;
  display: grid;
  grid-template-columns: 1fr 1fr; /* two columns: left = Cliente, right = Empresa */
  /* gap: 0px; */
  align-items: baseline;
}
/* Ensure the section title spans both columns */
.customer-info > .section-title {
  grid-column: 1 / -1;
  margin-bottom: 6px;
}

/* Make each group's internal grid a single column (fields stacked) */
.info-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  padding: 13px;
  FONT-SIZE: 14px;
}

/* Desktop: botão toggle oculto, campos extras sempre visíveis */
.client-fields-toggle {
  display: none;
}
.client-fields-extra {
  max-height: none;
  overflow: visible;
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.info-item {
  display: flex;
  gap: 10px;
}

.info-item label {
  font-weight: 600;
  color: var(--brand-color);
  min-width: 80px;
}

.info-item span[contenteditable="true"] {
  cursor: text;
  outline: none;
  text-transform: uppercase;
}

.info-item span[contenteditable="true"]:focus {
  background: #fff8e1;
  border-radius: 2px;
  padding: 2px 4px;
}

.info-item span[contenteditable="true"]:hover {
  background: #f5f5f5;
  border-radius: 2px;
}

.items-table {
  margin-bottom: 0px;
}

.table-header,
.table-row,
.table-input {
  display: grid;
  grid-template-columns: 40px 2fr 49px 71px 95px 95px 40px;
  gap: 6px;
  padding: 3px 7px;
  align-items: center;
}

/* Replaced color-mix(...) with a solid brand-color background for compatibility */
.table-header {
  background: var(--brand-color);
  color: #ffffff;
  font-weight: 100;
  font-size: 14px;
  margin: -15px 0 12px 0;
  padding: 3px 12px;
  opacity: 0.5;
  border-radius: 0 0 3px 3px;
}

.table-row {
  border-bottom: 1px solid #e0e0e0;
  cursor: grab; /* Indicate draggable */
  font-size: 14px;
}

.table-row:active {
  cursor: grabbing;
}

.table-row:hover {
  background: #f9f9f9;
}

.table-row.dragging {
  opacity: 0.5;
  background: #e0f2f1; /* Light cyan background for visual feedback */
}

.table-row.drag-over-top {
  border-top: 2px solid var(--brand-color);
}

.table-row.drag-over-bottom {
  border-bottom: 2px solid var(--brand-color);
}

.col-desc {
  text-align: left;
}
.col-unit {
  text-align: center;
}

/* Select de unidade */
.unit-select {
  border: 1px solid #ddd;
  border-radius: 4px;
  background: #fff;
  font-family: inherit;
  font-size: inherit;
  text-align: center;
  text-transform: uppercase;
  cursor: pointer;
  outline: none;
  padding: 2px 4px;
  color: #333;
}
.unit-select:focus {
  border-color: var(--brand-color);
  box-shadow: 0 0 0 2px rgba(var(--brand-color-rgb, 0,123,255), 0.15);
}

/* Select no form inline */
form#add-item-form .unit-select {
  width: 100%;
  height: 100%;
  border: none;
  background: transparent;
  padding: 8px 4px;
}

/* Select dentro da célula da tabela */
.table-row .col-unit .unit-select {
  width: 100%;
  border: none;
  background: #fff8e1;
  padding: 2px;
  font-size: inherit;
}

.col-qty {
  text-align: right;
}
.col-price {
  text-align: right;
}
.col-total {
  text-align: right; /* font-weight: 600; */
}
.col-action {
  text-align: center;
}
.col-num {
  text-align: center;
  font-weight: 600;
  color: var(--brand-color);
}

.col-total[contenteditable="true"] {
  cursor: text;
  outline: none;
}

.col-total[contenteditable="true"]:focus {
  background: #fff8e1;
  border-radius: 2px;
  padding: 2px 4px;
}

.col-total[contenteditable="true"]:hover {
  background: #f5f5f5;
  border-radius: 2px;
}

.col-desc[contenteditable="true"],
.col-qty[contenteditable="true"],
.col-price[contenteditable="true"] {
  cursor: text;
  outline: none;
}

.col-desc[contenteditable="true"]:focus,
.col-qty[contenteditable="true"]:focus,
.col-price[contenteditable="true"]:focus {
  background: #fff8e1;
  border-radius: 2px;
  padding: 2px 4px;
}

.col-desc[contenteditable="true"]:hover,
.col-qty[contenteditable="true"]:hover,
.col-price[contenteditable="true"]:hover {
  background: #f5f5f5;
  border-radius: 2px;
}

/* Unit cell hover effect (não é contentEditable, mas é clicável) */
.table-row .col-unit:hover {
  background: #f5f5f5;
  border-radius: 2px;
  cursor: pointer;
}

.table-input {
  background: #f3f3f3;
  margin-top: 10px;
}

.table-input input {
  padding: 8px;
  border: 1px solid #c8c8c8;
  font-family: "Product Sans", Arial, sans-serif;
  font-size: 14px;
}

.table-input input:focus {
  outline: none;
  border-color: var(--brand-color);
}

.btn-add {
  background: #9d9d9d;
  color: white;
  border: none;
  padding: 9px 16px;
  cursor: pointer;
  font-family: "Product Sans", Arial, sans-serif;
  font-size: 14px;
  font-weight: 600;
  border-radius: 0;
  /* Make the OK button occupy the 'total' column and the following 'action' column so it reaches the end */
  grid-column: 6 / 8;
  text-align: center;
  border-radius: 3px;
}

/* Replace color-mix hover darkening with a simple slightly darker fallback using rgba overlay */
.btn-add:hover {
  background: #737373; /* slightly darker visual feedback */
}

.btn-delete {
  background: color-mix(in srgb, var(--brand-color) 15%, white);
  color: white;
  border: none;
  width: 17px;
  border-radius: 0;
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
  height: 20px;
}

/* The above color-mix kept as-is only if not used by html2canvas; ensure fallback background to brand color */
.btn-delete {
  background: red;
  opacity: 0.4;
}

.btn-delete:hover {
  background: red;
  opacity: 0.9;
}

.calculator {
  display: none;
  background: #607d8b;
  color: white;
  padding: 20px;
  margin: 20px 0;
  border-radius: 4px;
}

.calculator-panel {
  width: 500px;
  max-width: calc(100% - 32px);
  background: #607d8b;
  /* color: white; */
  padding: 20px;
  border-radius: 6px;
}

.calc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.calc-header h3 {
  font-size: 18px;
  font-weight: 400;
  margin: 0;
}

.btn-close {
  background: white;
  color: #607d8b;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}

.btn-close:hover {
  background: #ff5722;
  color: white;
}

.calc-body {
  margin-top: 15px;
}

.calc-body select,
.calc-body input {
  width: 100%;
  padding: 10px;
  margin-bottom: 10px;
  border: none;
  border-radius: 2px;
  font-family: "Product Sans", Arial, sans-serif;
  font-size: 14px;
  border: 1px solid #ccc;
}

.calc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
/* New: wrap each input with label below */
.calc-field {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}
.calc-field input {
  width: 100%;
}
.calc-label {
  margin-top: -5px;
  font-size: 13px;
  color: #555;
  text-align: center;
  user-select: none;
}

.calc-results {
  background: rgba(255, 255, 255, 0.1);
  padding: 15px;
  margin: 15px 0;
  border-radius: 2px;
}

.result-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 16px;
}

.result-item label {
  font-weight: 400;
}

.result-item span {
  font-weight: 600;
  /* color: #555; */
}

.btn-use {
  width: 100%;
  background: #4caf50;
  color: white;
  border: none;
  padding: 12px;
  cursor: pointer;
  font-family: "Product Sans", Arial, sans-serif;
  font-size: 16px;
  font-weight: 600;
}

.btn-use:hover {
  background: #45a049;
}

.order-total {
  background: var(--brand-color);
  color: white;
  padding: 7px 20px;
  text-align: right;
  font-size: 17px;
  margin: 20px 0;
  border-radius: 3px;
}

.order-total strong {
  font-size: 17px;
}

#grand-total {
  cursor: text;
  outline: none;
}

#grand-total:focus {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  padding: 2px 6px;
}

#grand-total:hover {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
}

.terms-section {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 15px;
  margin: 0px 0 13px 0;
  align-items: stretch;
}

.term-box {
  position: relative;
  border: 2px solid var(--brand-color);
  padding: 32px 7px 15px; /* extra top padding to accomodate header label */
  text-align: center;
  border-radius: 0;
  border-radius: 3px;
}

.term-box.hidden {
  display: none;
}

.term-box label {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  background: var(--brand-color);
  color: #fff;
  font-weight: 100;
  padding: 2px 10px;
  font-size: 14px;
  border-top-left-radius: 2px;
  border-top-right-radius: 2px;
  text-align: left;
  border-radius: 0;
  text-align: center;
  padding: 4px 0px 3px 0;
}

.term-value {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 3px;
}

.term-note {
  font-size: 12px;
  color: #666;
  font-style: italic;
  margin-top: 0px;
  line-height: 13px;
}

.term-value[contenteditable="true"],
.term-note[contenteditable="true"] {
  cursor: text;
  outline: none;
  text-decoration: none;
}

.term-value[contenteditable="true"]:focus,
.term-note[contenteditable="true"]:focus {
  background: #fff8e1;
  border-radius: 2px;
  padding: 2px 4px;
}

.term-value[contenteditable="true"]:hover,
.term-note[contenteditable="true"]:hover {
  background: #f5f5f5;
  border-radius: 2px;
}

/* Custom term delete button */
.term-box .delete-term-btn {
  position: absolute;
  top: 0px;
  right: 0px;
  background: rgba(220, 53, 69, 0.85);
  color: white;
  border: none;
  border-radius: 0 2px 0 3px;
  width: 22px;
  height: 22px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  z-index: 10;
  padding: 0;
}

.term-box:hover .delete-term-btn {
  display: flex;
}

/* Add custom term button */
.btn-add-term {
  background: #fff;
  color: var(--brand-color);
  border: 2px solid var(--brand-color);
  border-radius: 3px;
  padding: 4px 10px;
  cursor: pointer;
  font-size: 16px;
  display: inline-flex;
  gap: 4px;
  opacity: 0.85;
  transition: opacity 0.2s;
  justify-content: center;
  align-items: center;
}

.btn-add-term:hover {
  opacity: 1;
}

/* Terms section header */
.terms-section-header,
.items-section-footer {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin: 10px 0 5px 0;
  padding: 0 2px;
}

#term-avista {
  display: none; /* Hide the old PIX term box as it's replaced */
}

/* New PIX Payment Section Styles */
#pix-payment-section {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f8f8f8;
  border-radius: 17px;
  padding: 25px 39px;
  margin: 20px 0;
  gap: 20px;
  position: relative;
}
.pix-gear-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: transparent;
  border: none;
  color: #999;
  font-size: 16px;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s;
  opacity: 0;
}
#pix-payment-section:hover .pix-gear-btn {
  opacity: 1;
}
.pix-gear-btn:hover {
  background: rgba(0,0,0,0.08);
  color: #555;
}
#pix-payment-section.hidden {
  display: none !important;
}

.pix-info {
  flex: 1;
}

.pix-title {
  font-size: 18px;
  font-weight: 400;
  color: var(--brand-color);
  margin-bottom: 10px;
}

#pix-value-container {
  font-size: 16px;
  margin-bottom: 5px;
}

#pix-value-container strong {
  font-size: inherit;
  font-weight: 400;
  color: var(--brand-color);
  font-size: 28px;
}

#pix-parcels-note {
  font-size: 15px;
  color: #555;
  font-style: italic;
  margin-bottom: 15px;
  cursor: text;
  margin: 11px 0 16px 0px;
}

.pix-copy-label {
  font-size: 12px;
  color: #666;
  margin-bottom: 5px;
}

.pix-code-container {
  display: flex;
  align-items: center;
}

#pix-brcode {
  flex: 1;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 2px;
  font-family: monospace;
  font-size: 11px;
  background: #fff;
  resize: none;
  height: 60px;
  line-height: 1.4;
  color: #333;
}

#copy-pix-btn {
  background: var(--brand-color);
  color: white;
  border: none;
  padding: 0 15px;
  height: 60px;
  cursor: pointer;
  margin-left: -1px; /* Overlap border */
  border-top-right-radius: 2px;
  border-bottom-right-radius: 2px;
  font-weight: 600;
}

#copy-pix-btn:hover {
  background: rgba(51, 122, 183, 0.85);
}

.pix-qr-container {
  text-align: center;
}

.pix-payment-header {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 14px;
  color: #555;
}

.pix-logo-img {
  height: 20px;
}

#pix-sinal-value {
  margin-top: 8px;
  font-size: 20px;
  font-weight: 100;
  color: var(--brand-color);
}

.qr-section {
  display: none;
} /* QR removed from markup; keep safe no-op rule */

.footer {
  text-align: center;
  padding: 10px 0;
  border-top: 2px solid #ddd;
  color: #666;
  font-size: 14px;
  /* push footer to the bottom of the container */
  margin-top: auto;
}

.footer p {
  margin: 5px 0;
}

.footer p[contenteditable="true"] {
  text-transform: uppercase;
}

.footer p span[contenteditable="true"] {
  cursor: text;
  outline: none;
  border-radius: 2px;
  padding: 1px 2px;
  text-transform: uppercase;
}

.footer p span[contenteditable="true"]:hover {
  background: #f5f5f5;
}

.footer p span[contenteditable="true"]:focus {
  background: #fff8e1;
}

.footer .footer-item {
  white-space: nowrap;
  display: inline;
}

.footer .footer-item.has-sep::before {
  content: '\25AA  ';
}

/* New Context Menu Styles */
.context-menu {
  position: fixed;
  background: #ffffff;
  border: none;
  box-shadow: 0 2px 6px 2px rgba(60,64,67,.15), 0 1px 2px 0 rgba(60,64,67,.3);
  border-radius: 4px;
  padding: 8px 0;
  min-width: 200px;
  font-family: "Product Sans", Arial, sans-serif;
  z-index: 10000;
}

.context-menu ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.context-menu li {
  padding: 0 16px;
  height: 32px;
  cursor: pointer;
  font-size: 14px;
  color: #3c4043;
  display: flex;
  align-items: center;
  user-select: none;
  transition: background-color 100ms ease;
}

.context-menu li > span {
  /* flex: 1; */
}

.context-menu li .cm-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  margin-right: 16px;
  flex: 0 0 20px;
  font-size: 18px;
  color: #5f6368;
}

.context-menu li:hover {
  background: rgba(0, 0, 0, 0.04);
}

.context-menu li:hover .cm-icon {
  color: #5f6368;
}

.context-menu li.menu-separator {
  height: 0;
  padding: 0;
  margin: 8px 0;
  border-top: 1px solid #e0e0e0;
  cursor: default;
}

.context-menu li.menu-separator:hover {
  background: none;
}

.context-menu li input[type="color"] {
  width: 24px;
  height: 24px;
  border: 1px solid #dadce0;
  border-radius: 4px;
  padding: 0;
  background: none;
  cursor: pointer;
  margin-left: auto;
}

.context-menu li input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--brand-color);
  margin-left: auto;
}

/* Accordion: on desktop context menu, hide headers and show body items flat */
.cm-accordion-header {
  display: none;
}
.cm-accordion-body {
  padding: 0;
  margin: 0;
  border-top: 1px solid #e0e0e0;
  padding-top: 8px;
  margin-top: 8px;
}
.cm-accordion-body:first-child,
.cm-accordion-header:first-child + .cm-accordion-body {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}
.cm-accordion-arrow {
  display: none;
}

/* Term visibility list items */
#term-visibility-list {
  border-top: 1px solid #e0e0e0;
  margin-top: 8px;
  padding-top: 8px;
}

#term-visibility-list li {
  padding: 0 16px;
  height: 32px;
  font-size: 14px;
  color: #3c4043;
  display: flex;
  align-items: center;
}

#term-visibility-list li label {
  flex: 1;
  cursor: pointer;
  margin-left: 0;
}

/* New Desktop Menu Styles */
.desktop-menu {
    display: none; /* Hidden by default on mobile */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #E9E9E9; /* Light gray background */
    border-bottom: 1px solid #C5C5C5;
    z-index: 1001;
    font-family: "Product Sans", Arial, sans-serif;
    font-size: 14px;
}

.desktop-menu ul {
    list-style: none;
    margin: 0;
    padding: 0 10px;
    display: flex;
}

.desktop-menu {
    display: flex;
}

.desktop-menu ul li {
    position: relative;
}

.desktop-menu ul li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    text-decoration: none;
    color: #333;
    border: 1px solid transparent;
}

.desktop-menu > ul > li:hover > a {
    background-color: #D3E5F9;
    border: 1px solid #9ABEE6;
}

.desktop-menu ul ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #F7F7F7;
    border: 1px solid #C5C5C5;
    min-width: 240px;
    flex-direction: column;
    padding: 5px 0;
    box-shadow: 0 3px 5px rgba(0,0,0,0.1);
}

.desktop-menu ul li:hover > ul {
    display: block;
}

.desktop-menu ul ul li a {
    padding: 8px 20px;
    display: flex;
    justify-content: space-between;
}

.desktop-menu ul ul li a:hover {
    background-color: #D3E5F9;
    border-color: transparent;
}

.desktop-menu a i {
    margin-right: 15px;
    width: 20px;
    text-align: center;
    color: #555;
}

.desktop-menu .menu-separator-desktop {
    padding: 0;
    margin: 5px 0;
}

.desktop-menu .menu-separator-desktop hr {
    border: none;
    border-top: 1px solid #E0E0E0;
}

.desktop-menu .shortcut {
    color: #888;
    font-size: 12px;
}

.desktop-menu .menu-header {
    padding: 8px 10px;
    font-weight: bold;
    color: #888;
    font-size: 12px;
    text-transform: uppercase;
}

.user-menu {
    /* margin-left: auto; */
    float: right;
}

/* Show desktop menu and hide hamburger on larger screens */
@media (min-width: 769px) {
    .desktop-menu {
        display: flex;
        justify-content: space-between;
    }
    #hamburger-menu-btn {
        display: none !important;
    }
}

/* ===== ASSINATURA DIGITAL ===== */
#assinatura-section {
    margin: 20px 0;
    padding: 24px;
    background: #f9fafb;
    border-radius: 12px;
    border: 2px dashed #d1d5db;
    text-align: center;
}
#assinatura-canvas {
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #fff;
    display: block;
    margin: 12px auto;
    cursor: crosshair;
    touch-action: none;
    max-width: 100%;
}
.assinatura-realizada { text-align: center; }
.assinatura-img {
    max-width: 300px;
    border-bottom: 2px solid #333;
    display: block;
    margin: 0 auto 8px;
}
.assinatura-badge {
    color: #16a34a;
    font-weight: 600;
    margin-top: 10px;
    font-size: 14px;
}
.assinatura-meta {
    font-size: 13px;
    color: #666;
    margin-top: 6px;
    line-height: 1.6;
}
.assinatura-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 12px;
    flex-wrap: wrap;
    align-items: center;
}
#assinatura-nome {
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 13px;
    font-family: var(--font-family);
    min-width: 200px;
}
#assinatura-limpar {
    padding: 8px 16px;
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 13px;
    font-family: var(--font-family);
    cursor: pointer;
}
#assinatura-confirmar {
    padding: 8px 20px;
    background: #16a34a;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-family: var(--font-family);
    font-weight: 600;
    cursor: pointer;
}
#assinatura-confirmar:disabled { opacity: 0.6; cursor: not-allowed; }

@media print {
  /* Added print styles to preserve desktop layout and hide UI elements */
  body {
    background: white;
    margin: 0;
    padding: 0;
  }

  .container {
    width: 900px;
    height: auto;
    margin: 0;
    padding: 20px;
    box-shadow: none;
  }

  /* Hide interactive elements */
  .calculator,
  .btn-delete,
  .col-action,
  .table-input,
  .btn-export-pdf,
  .context-menu,
  #logo-file,
  #cnpj-search-btn,
  #cep-search-btn,
  .non-printable,
  .no-print,
  .placeholder-text,
  #logo-placeholder,
  #edit-logo-btn,
  #delete-logo-btn,
  #ai-enhance-logo-btn,
  #hamburger-menu-btn,
  #mobile-action-bar,
  #add-item-form,
  .delete-term-btn,
  .terms-section-header,
  .btn-add-term,
  .client-fields-toggle {
    display: none !important;
  }

  .client-fields-extra {
    max-height: none !important;
    overflow: visible !important;
  }

  /* Ensure proper page breaks */
  .header,
  .customer-info,
  .items-section,
  .terms-section,
  #pix-payment-section {
    page-break-inside: avoid;
  }

  /* Force desktop proportions */
  .header {
    min-height: 137px;
  }

  /* Ensure text remains selectable */
  * {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  /* Preserve colors */
  .section-title,
  .order-total,
  .table-header,
  .term-box label {
    background: var(--brand-color) !important;
    color: white !important;
  }

  /* Ensure QR code and images print properly */
  img,
  canvas {
    max-width: 100%;
    page-break-inside: avoid;
  }
}

.order-qr {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: 22px;
  margin-top: 8px;
}
.order-qr img {
  border: 1px solid #e0e0e0;
  background: white;
  padding: 4px;
  width: 110px;
  height: 110px;
  object-fit: contain;
}

form#add-item-form {
  padding: 5px 6px 0px 0;
  border-radius: 5px;
}

/* Override specifically for the "Ãƒâ‚¬ vista no pix" term so it uses a distinct default green */
#term-avista label {
  background: #00851f; /* label background */
}
#term-avista .term-note {
  color: #004e13; /* slightly darker note color for contrast (optional) */
}
#term-avista .term-value,
#term-avista .term-value strong {
  color: #004e13; /* ensure visible/contrasting text color inside the avista box */
}

.pix-qr-code {
  width: 150px;
  height: 150px;
  /* border: 1px solid #e0e0e0; */
  margin: 0 auto;
  display: block;
  cursor: pointer;
  background-color: white;
  transition: all 0.2s ease-in-out;
  padding: 5px;
}

.pix-qr-code.visible {
  transform: scale(1.05);
}

/* PIX key type modal */
.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 99999;
}
.modal-panel {
  position: relative;
  background: #fff;
  border-radius: 6px;
  width: 340px;
  max-width: calc(100% - 32px);
  padding: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
  z-index: 100000;
}
.modal-panel h3 {
  margin: 0 0 10px 0;
  font-size: 16px;
  color: var(--brand-color);
  font-weight: 600;
  text-align: left;
}
.modal-body {
  margin-bottom: 12px;
}
.modal-label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  color: #333;
}
.modal-select {
  width: 100%;
  padding: 8px;
  font-size: 14px;
  border: 1px solid #ddd;
  border-radius: 4px;
}
.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.btn-save {
  background: var(--brand-color);
  color: #fff;
  border: none;
  padding: 8px 12px;
  border-radius: 4px;
  cursor: pointer;
}
.btn-cancel {
  background: #f0f0f0;
  color: #333;
  border: none;
  padding: 8px 12px;
  border-radius: 4px;
  cursor: pointer;
}

/* Modal Cadastros - Abas Verticais */
#cadastros-modal .modal-panel {
  height: 80vh;
  max-height: 700px;
}
.cadastros-tabs {
  border-radius: 6px 0 0 6px;
}
.cadastros-tab {
  transition: all 0.2s ease;
}
.cadastros-tab:hover {
  background: rgba(255,255,255,0.15) !important;
}
.cadastros-tab.active {
  background: rgba(255,255,255,0.2) !important;
  color: #fff !important;
}
.cadastros-tab span {
  display: block;
  transform: rotate(180deg);
}
.cadastros-content {
  flex-direction: column;
}
.btn-secondary {
  background: #6c757d;
  color: #fff;
  border: 1px solid #6c757d;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.btn-secondary:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}
.btn-secondary:active {
  transform: translateY(0);
}
.btn-donate {
  background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 2px 8px rgba(40, 167, 69, 0.3);
}
.btn-donate:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(40, 167, 69, 0.4);
}
.btn-donate:active {
  transform: translateY(0);
}
.btn-donate i {
  animation: heartbeat 1.5s ease-in-out infinite;
}
@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  14% { transform: scale(1.2); }
  28% { transform: scale(1); }
  42% { transform: scale(1.2); }
  56% { transform: scale(1); }
}
.modal-input {
  width: 100%;
  padding: 8px;
  font-size: 14px;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-sizing: border-box;
  margin-bottom: 10px;
}
.modal-input:focus {
  border-color: var(--brand-color);
  outline: none;
  box-shadow: 0 0 0 2px rgba(51, 122, 183, 0.15);
}
.modal-input-error {
  border-color: #dc3545 !important;
  box-shadow: 0 0 0 2px rgba(220, 53, 69, 0.15) !important;
}
.pix-type-btn {
  background: transparent;
  border: none;
  /* padding: 3px 8px; */
  /* border-radius: 4px; */
  /* font-size: 14px; */
  cursor: pointer;
  color: #666;
  font-family: "Product Sans";
}
.pix-type-btn:focus {
  outline: 2px solid rgba(51, 122, 183, 0.4);
}

/* When body has .hide-nonprint, hide elements marked as non-printable in the UI (non-destructive toggle) */
body.hide-nonprint .non-printable {
  display: none !important;
}

/* Product Config Modal Styles */
#product-config-list input {
  outline: none;
}

#product-config-list input:focus {
  border-color: var(--brand-color);
  box-shadow: 0 0 0 2px rgba(51, 122, 183, 0.15);
}

#product-config-list .btn-save {
  cursor: pointer;
  transition: background-color 120ms ease;
}

#product-config-list .btn-save:hover {
  background: rgba(51, 122, 183, 0.1);
}

#product-config-modal .modal-panel {
  width: 700px;
}

/* Estilo para labels do menu de visibilidade de termos */
#term-visibility-list li label {
  margin-left: 17px;
}

/* Largura mínima para campos editáveis */
.info-item span[contenteditable="true"] {
  min-width: 120px;
}

/* ========== ESTILOS DOS MODAIS NOVOS ========== */

/* Tutorial Modal */
#tutorial-modal .modal-panel {
  background: #fff;
}

#tutorial-modal h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--brand-color);
  border-bottom: 2px solid var(--brand-color);
  padding-bottom: 15px;
  margin-bottom: 0;
}

.tutorial-section {
  margin-bottom: 25px;
  padding-bottom: 20px;
  border-bottom: 1px solid #eee;
}

.tutorial-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.tutorial-section h4 {
  color: var(--brand-color);
  font-size: 16px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.tutorial-section h4 i {
  width: 20px;
  text-align: center;
}

.tutorial-section ol,
.tutorial-section ul {
  margin: 0;
  padding-left: 25px;
  line-height: 1.8;
  color: #555;
}

.tutorial-section ol li,
.tutorial-section ul li {
  margin-bottom: 5px;
}

.tutorial-section p {
  margin: 0;
  line-height: 1.6;
  color: #555;
}

.tutorial-section strong {
  color: var(--brand-color);
  font-weight: 600;
}

/* About Modal */
#about-modal .modal-panel {
  background: #fff;
}

/* Sugestões Modal */
#sugestoes-modal .modal-panel {
  background: #fff;
}

#sugestoes-modal h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--brand-color);
}

#sugestoes-modal h3 i {
  color: #f39c12;
}

#sugestao-mensagem {
  font-family: inherit;
}

#sugestao-mensagem:focus {
  outline: none;
  border-color: var(--brand-color);
  box-shadow: 0 0 0 3px rgba(51, 122, 183, 0.1);
}

#sugestoes-send i {
  margin-right: 5px;
}

/* ============================================================
   MOBILE RESPONSIVE - Só aplica em telas menores que 769px
   NÃO afeta desktop em absolutamente nada.
   ============================================================ */

/* Barra de ações mobile - oculta no desktop */
#mobile-action-bar {
  display: none;
}

@media (max-width: 768px) {

  /* --- BODY & CONTAINER --- */
  body {
    padding-top: 0 !important;
    min-height: 100vh;
    min-height: 100dvh;
  }

  button#add-custom-term-btn {
    position: relative;
}

  .container {
    width: 100% !important;
    height: auto !important;
    margin: 0 !important;
    padding: 10px !important;
    box-shadow: none !important;
    border-radius: 0;
    padding-bottom: 80px !important; /* espaço para barra de ações */
  }

  /* --- HEADER --- */
  .header {
    padding: 21px 26px 16px!important;
    min-height: auto !important;
    gap: 8px;
    display: flex;
  }

  .logo {
    width: 120px !important;
    margin-left: 0 !important;
  }

  .order-title {
    float: none !important;
    margin-right: 0 !important;
    font-size: 18px !important;
    text-align: center;
  }

  .btn-export-pdf {
    position: static !important;
    display: none !important; /* controlado pela barra mobile */
  }

  /* --- HAMBURGER --- */
  #hamburger-menu-btn {
    top: 8px !important;
    right: 8px !important;
    display: none !important; /* substituído pela barra mobile */
  }

  /* --- DESKTOP MENU --- */
  .desktop-menu {
    display: none !important;
  }

  /* --- CUSTOMER INFO (1 coluna no mobile) --- */
  .customer-info {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
  }

  .info-grid {
    padding: 8px !important;
    font-size: 13px !important;
    gap: 8px !important;
  }

  .info-item {
    flex-direction: row;
    gap: 0 !important;
  }

  /* Esconder labels no mobile — usar placeholders */
  .info-item label {
    display: none !important;
  }

  .info-item span[contenteditable="true"] {
    font-size: 13px !important;
    width: 100% !important;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 10px 12px !important;
    background: #fafafa;
    min-height: 20px;
  }

  .info-item span[contenteditable="true"]:focus {
    border-color: var(--brand-color) !important;
    background: #fff !important;
    box-shadow: 0 0 0 2px rgba(var(--brand-color-rgb, 0,123,255), 0.1);
  }

  /* Placeholder via ::before quando o span está vazio */
  .info-item span[contenteditable="true"]:empty::before {
    content: attr(data-placeholder);
    color: #aaa;
    font-style: normal;
    pointer-events: none;
    text-transform: none;
  }

  /* Botão seta para expandir campos extras */
  .client-fields-toggle {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 100%;
    background: none;
    border: none;
    border-top: 1px dashed #ddd;
    padding: 6px 0;
    cursor: pointer;
    color: #999;
    font-size: 14px;
    transition: color 0.2s;
  }
  .client-fields-toggle:hover,
  .client-fields-toggle:active {
    color: var(--brand-color);
  }
  .client-fields-toggle i {
    transition: transform 0.3s ease;
  }

  /* Campos extras — sanfona colapsada */
  .client-fields-extra {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
  }
  .client-fields-extra.expanded {
    max-height: 600px;
  }

  /* --- TABELA DE ITENS (mobile) --- */

  /* Cabeçalho: mostrar como barra de labels compacta */
  .table-header {
    display: flex !important;
    padding: 6px 8px !important;
    border-bottom: 2px solid var(--brand-color);
    background: #f8f8f8;
    font-size: 9px !important;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    color: #999;
    margin-bottom: 3px;
  }

  /* Primeira linha do header: # e Descrição */
  .table-header .col-num {
    width: 24px;
    flex-shrink: 0;
  }
  .table-header .col-desc {
    flex: 1;
    min-width: 0;
  }
  .table-header .col-action {
    display: none !important;
  }

  /* Colunas numéricas do header alinhadas com os itens */
  .table-header .col-unit  {width: 13%;text-align: center;}
  .table-header .col-qty   {width: 6%;text-align: right;}
  .table-header .col-price {width: 17%;text-align: right;}
  .table-header .col-total {width: 16%;text-align: right;}

  /* Cada item: flexbox com wrap para criar 2 linhas */
  .table-row {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 0 !important;
    padding: 10px 8px !important;
    border-bottom: 1px solid #e8e8e8;
    align-items: baseline;
  }

  /* === LINHA 1: #  Descrição  [X] === */
  .table-row .col-num {
    order: 1;
    width: 24px;
    flex-shrink: 0;
    font-weight: 700;
    color: var(--brand-color);
    font-size: 12px;
  }

  .table-row .col-desc {
    order: 2;
    flex: 1;
    min-width: 0;
    font-weight: 500;
    font-size: 12px !important;
    overflow: hidden;
    text-overflow: ellipsis;
    /* white-space: nowrap; */
  }

  .table-row .col-action {
    order: 3;
    flex-shrink: 0;
    margin-left: 4px;
  }

  /* Quebra de linha forçada após o botão delete */
  .table-row .col-action::after {
    content: '';
    display: block;
    width: 100%;
    order: 4;
  }

  /* === LINHA 2: Unid | Qde | V.Unit | V.Total (alinhados com header) === */
  .table-row .col-unit,
  .table-row .col-qty,
  .table-row .col-price,
  .table-row .col-total {
    order: 10;
    font-size: 12px !important;
    color: #666;
    margin-top: 4px;
    padding-top: 4px;
  }

  .table-row .col-unit  {width: 11%;text-align: center;}
  .table-row .col-qty   {width: 9%;text-align: right;}
  .table-row .col-price {width: 18%;text-align: right;}
  .table-row .col-total {width: 18%;text-align: right;font-weight: 600;color: #333;}

.btn-delete {
    background: red;
    opacity: 0.4;
  display: none;
}

  
  
  /* --- FORMULÁRIO ADD ITEM: oculto no mobile, usar botão + modal --- */
  form#add-item-form {
    display: none !important;
  }

  .items-section-footer {
    display: flex !important;
  }

  /* --- TERMOS / CONDIÇÕES (5 colunas -> 3 colunas) --- */
  .terms-section {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 8px !important;
    padding: 11px;
    margin: 4px -10px 3px -10px;
    background-color: color-mix(in srgb, var(--brand-color), transparent 81%);
    zoom: 0.9;
  }

  .term-box {
    padding: 28px 5px 10px !important;
    font-size: 12px !important;
    background: #fff;
    border: 1px solid var(--brand-color);
  }

  .term-box label {
    font-size: 12px !important;
    padding: 3px 5px !important;
  }

  /* --- SEÇÕES AUXILIARES (calculadora, totais, etc) --- */
  .calculator {
    position: static !important;
    width: 100% !important;
    margin: 10px 0 !important;
  }

  .calculator-panel {
    width: 100% !important;
    max-width: 100% !important;
  }

  /* --- MODAIS - TELA CHEIA NO MOBILE --- */
  .modal-panel,
  #empresa-modal .modal-panel,
  #cadastros-modal .modal-panel,
  #tutorial-modal .modal-panel,
  #footer-edit-modal .modal-panel,
  #load-order-modal .modal-panel,
  #about-modal .modal-panel,
  #sugestoes-modal .modal-panel,
  #parcelas-modal .modal-panel,
  #parcelas-juros-modal .modal-panel,
  #product-config-modal .modal-panel,
  #pix-input-modal .modal-panel,
  #pix-type-modal .modal-panel,
  #cliente-edit-modal .modal-panel,
  #contato-edit-modal .modal-panel,
  #termos-modal .modal-panel {
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
    max-height: 100% !important;
    border-radius: 0 !important;
    margin: 0 !important;
    padding: 16px !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  .modal {
    align-items: stretch !important;
  }

  .modal-panel h3 {
    font-size: 18px !important;
    padding-right: 30px; /* espaço para botão fechar */
  }

  .modal-panel input,
  .modal-panel select,
  .modal-panel textarea {
    font-size: 16px !important; /* previne zoom do iOS */
    padding: 12px !important;
  }

  .modal-panel button,
  .modal-panel .btn-save,
  .modal-panel .btn-cancel {
    padding: 12px 16px !important;
    font-size: 15px !important;
    min-height: 44px; /* área de toque mínima */
  }

  .modal-actions {
    flex-direction: column !important;
    gap: 8px !important;
  }

  .modal-actions button {
    width: 100% !important;
  }

  /* --- COLOR PALETTE MODAL --- */
  #color-palette-modal > div:last-child {
    max-width: 100% !important;
    width: 100% !important;
    border-radius: 12px 12px 0 0 !important;
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
  }

  /* --- CONTEXT MENU COMO PAINEL MOBILE --- */
  .context-menu.mobile-menu-open,
  .context-menu {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    border-radius: 0 !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    z-index: 99998 !important;
    padding: 15px 0 80px !important;
    background: #fff !important;
    box-shadow: none !important;
  }

  .context-menu ul {
    padding: 0 !important;
  }

  .context-menu li {
    padding: 14px 20px !important;
    font-size: 16px !important;
    min-height: 48px;
    display: flex;
    align-items: center;
  }

  .context-menu li .cm-icon {
    width: 28px !important;
    font-size: 18px !important;
  }

  .context-menu .menu-separator {
    min-height: 1px !important;
    padding: 0 !important;
    margin: 4px 16px !important;
  }

  /* --- ACCORDION MOBILE MENU --- */
  .cm-accordion-body {
    display: block !important;
    border-top: none !important;
    padding-top: 0 !important;
    margin-top: 0 !important;
  }
  .cm-accordion-arrow {
    display: inline-block !important;
  }
  .cm-accordion-header {
    display: flex !important;
    padding: 14px 20px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    color: #1f2937 !important;
    min-height: 48px;
    display: flex !important;
    align-items: center;
    cursor: pointer;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    user-select: none;
    position: relative;
  }

  .cm-accordion-header:hover {
    background: #f3f4f6 !important;
  }

  .cm-accordion-header .cm-icon {
    color: var(--brand-color) !important;
    width: 28px !important;
    font-size: 18px !important;
  }

  .cm-accordion-header .cm-accordion-arrow {
    position: absolute;
    right: 20px;
    font-size: 12px;
    color: #9ca3af;
    transition: transform 0.25s ease;
  }

  .cm-accordion-header.open .cm-accordion-arrow {
    transform: rotate(180deg);
  }

  .cm-accordion-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: #fff;
  }

  .cm-accordion-body.open {
    max-height: 600px;
  }

  .cm-accordion-body li {
    padding-left: 36px !important;
    font-size: 15px !important;
    color: #374151 !important;
    border-bottom: none;
  }

  .cm-accordion-body li .cm-icon {
    font-size: 15px !important;
    color: #6b7280 !important;
    width: 24px !important;
  }

  /* --- BARRA DE AÇÕES MOBILE (RODAPÉ) --- */
  #mobile-action-bar {
    display: flex !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-top: 1px solid #e0e0e0;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.08);
    z-index: 99999;
    padding: 6px 0;
    padding-bottom: calc(6px + env(safe-area-inset-bottom, 0px));
    justify-content: space-around;
    align-items: center;
  }

  #mobile-action-bar button {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    background: none;
    border: none;
    color: #666;
    font-size: 10px;
    font-family: inherit;
    padding: 6px 12px;
    cursor: pointer;
    min-width: 60px;
    -webkit-tap-highlight-color: transparent;
  }

  #mobile-action-bar button i {
    font-size: 20px;
    color: var(--brand-color);
  }

  #mobile-action-bar button:active {
    opacity: 0.6;
  }

  #mobile-action-bar button.has-changes i {
    color: #dc3545 !important;
    animation: pulse-save 1.5s ease-in-out infinite;
  }
  #mobile-action-bar button.has-changes span {
    color: #dc3545 !important;
    font-weight: 600;
  }

  @keyframes pulse-save {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
  }

  /* --- PIX SECTION --- */
  #pix-payment-section {
    /* width: 100% !important; */
    padding: 26px 21px !important;
    zoom: 0.8;
    border-radius: 0;
    margin-right: -12px;
    margin-left: -12px;
  }

  /* --- FOOTER (mobile: itens em linha contínua, ícone não separa do valor) --- */
  .footer {
    padding: 10px 8px !important;
    font-size: 11px !important;
    border-top: 1px solid #ddd;
    margin-top: 15px;
    text-align: center;
    zoom: 1.1;
  }

  .footer p {
    margin: 0 !important;
    font-size: 11px !important;
    display: inline;
  }

  /* Cada item (ícone + valor) não quebra internamente */
  .footer .footer-item {
    display: inline;
    white-space: nowrap;
  }

  .footer-section {
    font-size: 11px !important;  
    padding: 8px !important;
  } 

  /* --- LOGO CONTROLS --- */ 
  .logo-controls {
    display: none; /* ocultar no mobile, usar menu */
  }
 
  /* --- SECTION TITLES --- */ 
  .section-title {
    font-size: 13px !important; 
    padding: 6px 10px !important;
  } 

  /* --- CADASTROS MODAL TABS --- */
  #cadastros-modal .modal-panel {
    flex-direction: column !important;
  }

  .pix-qr-container { 
    
}

} /* fim @media (max-width: 768px) */ 


button#add-custom-term-btn {}