/* estilos-geral.css – combinado automaticamente a partir de: reset.css, utilities.css, typography.css, messages.css, buttons.css, forms.css, tables.css, layout.css, search.css, modals.css */

/* ===== INÍCIO: css/reset.css ===== */

/* ============================================================================
   CSS RESET & BASE STYLES
   ============================================================================ */

[type=button]:focus,
[type=button]:hover,
[type=submit]:focus,
[type=submit]:hover,
button:focus,
button:hover {
  color: #fff;
  background-color: #f8f9fa;
  text-decoration: none;
}

/* ===== FIM: css/reset.css ===== */


/* ===== INÍCIO: css/utilities.css ===== */

/* ============================================================================
   UTILITY CLASSES
   ============================================================================ */

.loading,
.no-results {
  padding: 10px;
  color: #666;
  font-style: italic;
}

.no-results {
  text-align: center;
}

.error {
  padding: 10px;
  color: #721c24;
  background-color: #f8d7da;
  border-radius: 4px;
}

/* ===== FIM: css/utilities.css ===== */


/* ===== INÍCIO: css/typography.css ===== */

/* ============================================================================
   TYPOGRAPHY
   ============================================================================ */

h3 {
  font-family: "Rubik", sans-serif;
  color: #2c3338;
  margin: 0 0 15px;
  padding-bottom: 10px;
  border-bottom: 2px solid #c21a26;
  font-size: 1.4em;
}

.pesquisa-rapida-header h3 {
  margin: 0;
  font-size: 1.3em;
  color: #333;
  border-bottom: none;
  padding-bottom: 0;
}

.ponto-rapido-container h3 {
  margin: 0;
  font-size: 1.3em;
  color: #333;
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 15px;
  font-family: "Rubik", sans-serif;
}

.cliente-nome {
  margin: 0;
  font-size: 1.4em;
  color: #333;
}

.cliente-codigo {
  font-size: 1em;
  color: #666;
  font-weight: 500;
}

/* ===== FIM: css/typography.css ===== */


/* ===== INÍCIO: css/messages.css ===== */

/* ============================================================================
   MESSAGES SYSTEM
   ============================================================================ */

.anotacao-message,
#localizacao-message {
  margin-top: 10px;
  padding: 10px;
  border-radius: 4px;
  display: none;
}

.anotacao-message.success,
#localizacao-message.success {
  display: block;
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.anotacao-message.error,
#localizacao-message.error {
  display: block;
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* ===== FIM: css/messages.css ===== */


/* ===== INÍCIO: css/buttons.css ===== */

/* ============================================================================
   BUTTON SYSTEM
   ============================================================================ */

.atualizar-localizacao-btn,
.vitrola-btn,
.enviar-anotacao-btn,
.pesquisar-btn,
.vitrola-login-button,
.calcular-desconto-btn,
.registrar-ponto-btn {
  background: #c21a26;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 10px 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all .3s ease;
  text-decoration: none;
  display: inline-block;
}

.atualizar-localizacao-btn:hover,
.vitrola-btn:hover,
.enviar-anotacao-btn:hover,
.pesquisar-btn:hover,
.vitrola-login-button:hover,
.calcular-desconto-btn:hover,
.registrar-ponto-btn:hover {
  background: #a50d17;
  color: #fff;
  text-decoration: none;
}

.limpar-btn {
  background-color: #6c757d;
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 10px 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all .3s ease;
  text-decoration: none;
  display: inline-block;
}

.limpar-btn:hover {
  background-color: #5a6268;
  color: #fff;
  text-decoration: none;
}

.vitrola-login-button {
  width: 100%;
  padding: 12px;
  font-size: 16px;
}

.vitrola-login-button:disabled,
.atualizar-localizacao-btn:disabled {
  background: #888;
  cursor: not-allowed;
  opacity: .7;
}

.registrar-ponto-btn {
  display: block;
  width: 100%;
  padding: 15px;
  font-size: 16px;
  text-align: center;
  margin-bottom: 20px;
}

.registrar-ponto-btn.entrada {
  background-color: #c21a26;
}

.registrar-ponto-btn.entrada:hover {
  background-color: #a50d17;
}

.registrar-ponto-btn.saida {
  background-color: #6c63ff;
}

.registrar-ponto-btn.saida:hover {
  background-color: #5a52d5;
}

/* ===== FIM: css/buttons.css ===== */


/* ===== INÍCIO: css/forms.css ===== */

/* ============================================================================
   FORMS & INPUTS
   ============================================================================ */

.form-row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.form-row label {
  font-weight: 600;
  min-width: 150px;
}

.form-row input[type="text"] {
  flex-grow: 1;
  min-width: 200px;
  padding: 10px;
  border: 2px solid #e0e0e0;
  border-radius: 4px;
  font-size: 16px;
  transition: border-color .3s ease;
}

.form-row input[type="text"]:focus,
#pesquisa-termo:focus,
.vitrola-login-form input:focus,
#anotacao-texto:focus {
  border-color: #c21a26;
  outline: none;
}

#pesquisa-termo,
.vitrola-login-form input,
#anotacao-texto {
  padding: 10px;
  border: 2px solid #e0e0e0;
  border-radius: 4px;
  font-size: 16px;
  transition: border-color .3s ease;
}

#produto-input,
#cliente-input,
#cidade-input {
  width: 100%;
  padding: 14px 40px 14px 34px;
  border: 2px solid #c21a26;
  border-radius: 12px;
  font-size: 16px;
  transition: all 0.3s;
}

#produto-input:focus,
#cliente-input:focus,
#cidade-input:focus {
  outline: none;
  border-color: #c21a26;
  box-shadow: 0 0 0 3px rgba(194, 26, 38, 0.1);
}

.pesquisa-rapida-container input[type="text"] {
  padding: 14px;
  border: 2px solid #c21a26;
  border-radius: 6px;
  font-size: 16px;
  transition: all .3s ease;
}

.pesquisa-rapida-container input[type="text"]:focus {
  box-shadow: 0 0 0 3px rgba(194, 26, 38, .2);
  outline: none;
}

/* Search row */
.search-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.search-row button {
  flex-shrink: 0;
}

#pesquisa-termo {
  flex-grow: 1;
}

/* Textarea */
#anotacao-texto {
  width: 100%;
  resize: vertical;
  min-height: 100px;
  margin-bottom: 10px;
}

/* Location form */
.localizacao-form-container {
  margin-bottom: 20px;
  background: #f8f9fa;
  padding: 15px;
  border-radius: 4px;
  border-left: 4px solid #c21a26;
}

/* ===== FIM: css/forms.css ===== */


/* ===== INÍCIO: css/tables.css ===== */

/* ============================================================================
   TABLES
   ============================================================================ */

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
  margin-block-end: 0;
  background: #fff;
  font-size: .95em;
}

th {
  background-color: #c21a26;
  color: #fff;
  font-weight: 600;
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #ddd;
}

td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #ddd;
}

tr:hover {
  background-color: #fff5f5;
}

.row-vencido td {
  background-color: #fff5f5;
  color: #c21a26;
  font-weight: 600;
}

/* ===== FIM: css/tables.css ===== */


/* ===== INÍCIO: css/layout.css ===== */

/* ============================================================================
   LAYOUT COMPONENTS
   ============================================================================ */

.dados-capa,
.dados-produto,
.dados-cliente,
.dimensoes-table,
.localizacao-table,
.movimentacoes-table,
.expositores-table,
.notas-table,
.financeiro-table,
.credito-table,
.enviar-anotacao-container,
.pesquisar-anotacao-container,
.ultimas-anotacoes-container,
.rentabilidade-table,
.ponto-container {
  margin: 15px 0;
}

.dados-capa {
  margin-bottom: 30px;
}

.cliente-cabecalho {
  margin: 15px 0;
  padding: 20px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  background: #f8f9fa;
  box-shadow: 0 2px 4px rgba(0, 0, 0, .05);
  border-left: 4px solid #c21a26;
  margin-bottom: 15px;
}

.cliente-cabecalho+.enviar-anotacao-container {
  margin-top: 0;
}

/* ============================================================================
   INFO DISPLAY COMPONENTS
   ============================================================================ */

.dados-produto .info-box,
.dados-cliente .info-box,
.financeiro-table .info-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dados-produto .info-row,
.dados-cliente .info-row,
.financeiro-table .info-row {
  display: flex;
  flex-direction: column;
  padding: 12px;
  background: #f8f9fa;
  border-radius: 4px;
  border-left: 4px solid #c21a26;
  break-inside: avoid;
}

.dados-produto .info-label,
.dados-cliente .info-label,
.financeiro-table .info-label {
  font-weight: 600;
  color: #2c3338;
  margin-bottom: 5px;
  font-size: .95em;
}

.dados-produto .info-value,
.dados-cliente .info-value,
.financeiro-table .info-value {
  color: #c21a26;
  word-wrap: break-word;
  line-height: 1.4;
}

.financeiro-table .negative-credit {
  border-left: 4px solid #e74c3c;
}

.financeiro-table .negative-credit .info-value {
  color: #e74c3c;
}

/* ============================================================================
   SPECIAL COMPONENTS
   ============================================================================ */

/* Product Image */
.produto-imagem {
  flex: 1 1 250px;
  max-width: 300px;
  min-width: 200px;
  margin: 0 auto;
  margin-top: 5px;
}

.produto-imagem img {
  width: 100%;
  height: auto;
  max-height: 300px;
  object-fit: contain;
}

/* Price Row */
.preco-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 12px;
  background: #f8f9fa;
  border-radius: 4px;
  border-left: 4px solid #c21a26;
}

.preco-container {
  display: flex;
  flex-direction: column;
}

.preco-label {
  font-weight: 600;
  color: #2c3338;
  margin-bottom: 5px;
  font-size: .95em;
}

.preco-valor {
  color: #c21a26;
  font-size: .95em;
  margin-bottom: 5px;
}

.botao-container {
  display: flex;
  align-items: center;
}

/* Navigation */
.back-arrow-container {
  margin-bottom: 15px;
}

.back-arrow {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #c21a26;
  text-decoration: none;
  font-weight: 500;
  transition: color .2s ease;
}

.back-arrow:hover {
  color: #a50d17;
  text-decoration: none;
}

.back-arrow svg {
  stroke: currentColor;
}

.back-arrow span {
  font-size: 14px;
}

/* Copy button */
.anotacao-copy-btn {
  background: none;
  border: none;
  color: #666;
  cursor: pointer;
  padding: 4px;
  border-radius: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .3s ease;
  position: absolute;
  right: 0;
  top: 0;
}

.anotacao-copy-btn:hover {
  background-color: #f0f0f0;
  color: #c21a26;
}

.anotacao-copy-btn:active {
  transform: scale(.95);
}

.anotacao-copy-btn.copied {
  color: #28a745;
  background-color: #e7f5eb;
}

/* Sinopse toggle */
.sinopse-toggle {
  display: flex;
  align-items: center;
  background: none;
  border: none;
  color: #c21a26;
  font-weight: 600;
  font-size: 14px;
  padding: 8px 0;
  margin-top: 5px;
  cursor: pointer;
  transition: color .2s ease;
}

.sinopse-toggle:hover,
.sinopse-toggle:focus {
  background-color: #f8f9fa !important;
  color: #a50d17 !important;
}

.sinopse-toggle svg {
  margin-left: 5px;
  transition: transform .3s ease;
}

/* ============================================================================
   LAYOUT SECTIONS
   ============================================================================ */

.pesquisa-rapida-section {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
}

.pesquisa-rapida-container {
  flex: 1;
  min-width: 300px;
  background: #fff;
  border-radius: 8px;
  padding: 15px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, .1);
}

.pesquisa-rapida-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.pesquisa-rapida-header svg {
  color: #c21a26;
  stroke-width: 1.5;
}

/* ============================================================================
   SINOPSE DISPLAY
   ============================================================================ */

.sinopse-container {
  position: relative;
}

.sinopse-content {
  position: relative;
  width: 100%;
}

.sinopse-text {
  transition: max-height .3s ease-out;
  overflow: hidden;
}

.sinopse-text.collapsed {
  max-height: 50px;
  position: relative;
}

.sinopse-text.collapsed::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 40px;
  background: linear-gradient(transparent, #f8f9fa);
  pointer-events: none;
}

.collapse-text,
.collapse-icon {
  display: none;
}

.expand-text,
.expand-icon {
  display: inline-flex;
}

.sinopse-text:not(.collapsed)+.sinopse-toggle .collapse-text,
.sinopse-text:not(.collapsed)+.sinopse-toggle .collapse-icon {
  display: inline-flex;
}

.sinopse-text:not(.collapsed)+.sinopse-toggle .expand-text,
.sinopse-text:not(.collapsed)+.sinopse-toggle .expand-icon {
  display: none;
}

/* ============================================================================
   FINANCIAL COMPONENTS
   ============================================================================ */

.financeiro-summary {
  margin-bottom: 20px;
}

/* ===== FIM: css/layout.css ===== */


/* ===== INÍCIO: css/search.css ===== */

/* ============================================================================
   SEARCH COMPONENTS
   ============================================================================ */

.search-wrapper {
  position: relative;
  width: 100%;
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #888;
  pointer-events: none;
}

.produto-search,
.cidade-search,
.cliente-search {
  position: relative;
}

.cidade-search label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #333;
}

.cidade-filtro-info {
  padding: 8px 10px;
  background-color: #f8f9fa;
  border-bottom: 1px solid #ddd;
  color: #333;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#produto-suggestions,
#suggestions-container,
#cidade-suggestions {
  position: absolute;
  width: 100%;
  background: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  max-height: 375px;
  overflow-y: auto;
  border-radius: 8px;
  margin-top: 4px;
}

#produto-suggestions ul,
#suggestions-container ul,
#cidade-suggestions ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

#produto-suggestions li,
#suggestions-container li,
#cidade-suggestions li {
  padding: 10px;
  cursor: pointer;
  border-bottom: 1px solid #eee;
  transition: background-color .2s;
}

#produto-suggestions li,
#suggestions-container li {
  display: flex;
}

#produto-suggestions li:hover,
#suggestions-container li:hover,
#cidade-suggestions li:hover {
  background-color: #f8f9fa;
}

.suggestion-img {
  width: 50px;
  height: 50px;
  object-fit: contain;
  margin-right: 10px;
}

.suggestion-text {
  flex: 1;
}

/* Estilos para sugestÃ£o do Ãºltimo cliente */
.ultimo-cliente-sugestao {
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 6px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.sugestao-header {
  background: #e9ecef;
  padding: 8px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #dee2e6;
}

.sugestao-titulo {
  font-size: 14px;
  font-weight: 600;
  color: #495057;
}

.fechar-sugestao {
  background: none;
  border: none;
  font-size: 18px;
  color: #6c757d;
  cursor: pointer;
  padding: 0;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.fechar-sugestao:hover {
  background: #dee2e6;
  color: #495057;
}

.sugestao-cliente {
  padding: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.sugestao-cliente:hover {
  background: #e9ecef;
}

.sugestao-cliente strong {
  color: #c21a26;
}

.usar-cliente-btn {
  background: #c21a26;
  color: white;
  border: none;
  border-radius: 4px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.usar-cliente-btn:hover {
  background: #a50d17;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.usar-cliente-btn:active {
  transform: translateY(0);
}

/* ===== FIM: css/search.css ===== */


/* ===== INÍCIO: css/modals.css ===== */

/* ============================================================================
   MODALS
   ============================================================================ */

.desconto-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 9999;
  overflow-y: auto;
}

.desconto-modal.active {
  display: block;
}

.desconto-modal-content {
  position: relative;
  background: white;
  margin: 5% auto;
  padding: 20px;
  width: 90%;
  max-width: 600px;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  animation: modalOpen 0.3s ease-out;
}

@keyframes modalOpen {
  from {
    opacity: 0;
    transform: translateY(-40px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.desconto-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid #c21a26;
  margin-bottom: 20px;
}

.desconto-modal-header h3 {
  margin: 0;
  padding: 0;
  border: none;
}

.fechar-modal {
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #666;
  transition: color 0.2s;
}

.fechar-modal:hover {
  color: #c21a26;
}

.produto-info {
  background: #f8f9fa;
  padding: 10px 15px;
  border-radius: 4px;
  margin-bottom: 20px;
  border-left: 4px solid #c21a26;
}

.produto-info p {
  margin: 8px 0;
}

.pesquisa-cliente-container {
  margin-bottom: 20px;
}

.pesquisa-cliente-container h4 {
  margin: 0px 0px 10px 0px;
  font-size: 1.1em;
  color: #333;
}

.resultado-calculo {
  padding: 15px;
  background: #f8f9fa;
  border-radius: 4px;
  margin-top: 20px;
}

.loading-calculo {
  text-align: center;
  color: #666;
  font-style: italic;
  padding: 10px;
}

.calculo-info {
  display: none;
}

.cliente-selecionado,
.preco-calculado,
.desconto-aplicado {
  margin: 8px 0;
  padding: 8px;
}

.cliente-selecionado {
  background: #ffe6e5;
  border-radius: 4px;
}

.preco-calculado {
  background: #e7f5eb;
  border-radius: 4px;
}

.preco-final {
  color: #28a745;
  font-size: 1.2em;
  font-weight: bold;
}

.desconto-aplicado {
  background: #fff3cd;
  border-radius: 4px;
}

body.modal-open {
  overflow: hidden;
}

/* ===== FIM: css/modals.css ===== */