/* ESTILOS ESPECÍFICOS PARA TICKETS */
/* Los estilos de header, sidebar y elementos generales están en global.css */

.title h1{
  font-family: anton;
  font-size: 40px;
  margin-top: -10px;
}

/* Encabezado de información del cliente y documento */
.headerInfo {
  display: flex;
  justify-content: space-between;
  background-color: #fff;
  margin: 1%;
  padding: 3%;
  margin-right: 4%;
  border-radius: 10px;
  border: 1px solid #001d3d22;
  font-family: Arial, Helvetica, sans-serif;
}

/* Sección izquierda: Datos del cliente */
.leftSection {
  width: 30%;
  padding-right: 20px;
}

.leftSection h3 {
  font-family: Anton;
  text-transform: uppercase;
  color: #001D3D;
  font-size: 14px;
  margin-bottom: 1px;
}

.leftSection select {
  width: 100%;
  padding: 6px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  border: 1px solid #001d3d42;
  border-radius: 5px;
  margin-top: 2%;
  margin-bottom: 2px;
}

.leftSection p {
  margin-top: 10px;
  font-family: Arial, Helvetica, sans-serif;
  color: #001D3D;
}

/* Sección derecha: Documento */
.rightSection {
  width: 30%;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rightSection h2 {
  font-family: Anton;
  text-transform: uppercase;
  color: #001D3D;
  font-size: 40px;
  margin-bottom: 1px;
}

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

.rightSection select,
.rightSection label,
.rightSection input {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 14px;
}

/* Contenido principal de tickets */
.mainDash {
  color: #001D3D;
  text-align: right;
  font-family: Arial, Helvetica, sans-serif;
  background-color: #fff;
  padding: 3%;
  height: 70%;
  margin: 1%;
  margin-right: 4%;
  border-radius: 10px;
  border: 1px solid #001d3d22;
}

.mainDash button {
  color: white;
  font-family: Arial, Helvetica, sans-serif;
  background-color: #001D3D;
  border-radius: 30px;
  padding: 8px;
  padding-left: 3%;
  padding-right: 3%;
  margin-top: 8px;
  margin-bottom: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.mainDash button:hover {
  background-color: #fff;
  color: #001D3D;
  border: 2px solid #001D3D;
  transform: translateY(-2px);
}

/* Tablas específicas de tickets */
.mainDash table {
  width: 100%;
  font-family: Arial, Helvetica, sans-serif;
  overflow: hidden;
}

#productTableBody td {
  font-family: 'Helvetica', sans-serif;
  font-size: 12px;
  padding: 13px;
  text-align: center;
}

#productTableBody td:nth-child(3) {
  text-align: left !important;
}

/* Sección de totales */
.totalsSection {
  width: 45%;
  margin-left: auto;
  margin-top: 20px;
}

.totalsTable {
  width: 100%;
  border-collapse: collapse;
  font-family: Helvetica, sans-serif;
  font-size: 12px;
  background-color: #f8f9fa;
  border: 1px solid #ccc;
  border-radius: 8px;
  box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.1);
}

.totalsTable td {
  padding: 6px 10px;
  text-align: right;
  color: #001D3D;
  border: none;
}

.totalsValue {
  font-weight: bold;
}

/* Footer específico de tickets */
.footerContentDash {
  padding-left: 1%;
  padding-right: 5%;
  padding-top: 0.5%;
  padding-bottom: 5%;
}

.footerContentDash button {
  color: white;
  font-family: Arial, Helvetica, sans-serif;
  background-color: #001D3D;
  border-radius: 30px;
  padding: 8px;
  padding-left: 3%;
  padding-right: 3%;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-right: 1%;
}

.footerContentDash button:hover {
  color: #001D3D;
  background-color: #fff;
  border: 2px solid #001D3D;
  transform: translateY(-2px);
}

/* Elementos específicos - Información del cliente */
#clientName,
#clientPhone {
  display: block;
  margin-top: 10px;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13px;
  color: #001D3D;
}

/* Responsive específico para tickets */
@media (max-width: 768px) {
  .headerInfo {
    flex-direction: column;
    gap: 20px;
  }
  
  .leftSection,
  .rightSection {
    width: 100%;
  }
  
  .rightSection h2 {
    font-size: 30px;
  }
  
  .totalsSection {
    width: 100%;
  }
  
  .mainDash {
    height: auto;
  }
}


/* ========================================
   SECCIÓN DE HISTORIAL
   ======================================== */

.historySection {
  margin-bottom: 3rem;
  margin-left: 0%;
}

.historyContainer {
  background-color: #fff;
  border-radius: 15px;
  padding: 2rem;
  box-shadow: 0 4px 6px rgba(0, 29, 61, 0.1);
  border: 1px solid #001d3d20;
}

.historyContainer h2 {
  font-family: 'Anton', sans-serif;
  text-transform: uppercase;
  color: #001D3D;
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
  text-align: center;
  border-bottom: 3px solid #001D3D;
  padding-bottom: 0.5rem;
}

.noHistoryMessage {
  text-align: center;
  padding: 3rem;
  font-family: Arial, Helvetica, sans-serif;
  color: #666;
  font-size: 1.1rem;
}

/* Tabla de historial */
.historyTable {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-family: Arial, Helvetica, sans-serif;
  background-color: #fff;
}

.historyTable thead {
  background-color: #001D3D;
  color: white;
}

.historyTable th {
  padding: 12px 15px;
  text-align: left;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
}

.historyTable td {
  padding: 12px 15px;
  border-bottom: 1px solid #EBF4FF;
  font-size: 0.9rem;
  color: #001D3D;
}

.historyTable tbody tr:hover {
  background-color: #f8f9fa;
  transition: background-color 0.2s ease;
}

.historyTable tbody tr:nth-child(even) {
  background-color: #fafbfc;
}

/* Botones de acción en historial */
.historyActionBtn {
  color: white;
  font-family: Arial, Helvetica, sans-serif;
  background-color: #001D3D;
  border: none;
  border-radius: 8px;
  padding: 6px 15px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.historyActionBtn:hover {
  background-color: #fff;
  color: #001D3D;
  border: 2px solid #001D3D;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 29, 61, 0.2);
}

.historyActionBtn:disabled {
  background-color: #ccc;
  cursor: not-allowed;
  transform: none;
}

/* Paginación */
.paginationContainer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #001d3d20;
}

.paginationBtn {
  color: white;
  font-family: Arial, Helvetica, sans-serif;
  background-color: #001D3D;
  border: none;
  border-radius: 8px;
  padding: 8px 20px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.paginationBtn:hover:not(:disabled) {
  background-color: #003366;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 29, 61, 0.2);
}

.paginationBtn:disabled {
  background-color: #ccc;
  cursor: not-allowed;
  opacity: 0.5;
}

.pageInfo {
  font-family: Arial, Helvetica, sans-serif;
  color: #001D3D;
  font-weight: 600;
  font-size: 0.95rem;
}

/* Botón de eliminar - estilo diferente */
.historyActionBtn.deleteBtn {
  background-color: #dc3545;
  margin-left: 10px;
}

.historyActionBtn.deleteBtn:hover {
  background-color: #fff;
  color: #dc3545;
  border: 2px solid #dc3545;
}

/* Ajuste de espacio entre botones */
.historyTable td {
  white-space: nowrap;
}

.historyActionBtn + .historyActionBtn {
  margin-left: 8px;
}

/* Responsive para historial */
@media (max-width: 768px) {
  .historyTable {
    font-size: 0.8rem;
  }
  
  .historyTable th,
  .historyTable td {
    padding: 8px 10px;
  }
  
  .paginationContainer {
    flex-direction: column;
    gap: 1rem;
  }
}