/* Animaciones */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideIn {
  from {
    transform: scale(0.95);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}



/* Caja del formulario centrada y grande */
.ticket-form-container {
  background: #fafafa;
  /* blanco suave */
  padding: 40px;
  border-radius: 14px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
  animation: slideIn 0.8s ease;

  /* Ocupa gran parte del ancho */
  width: 100%;
  max-width: 800px;

  /* Centrado vertical dentro del panel central */
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}

/* Formulario */
.ticket-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Grupos de campos */
.ticket-form-group {
  display: flex;
  flex-direction: column;
}

.ticket-form-group label {
  font-weight: 600;
  margin-bottom: 8px;
  color: #444;
  font-size: 16px;
}

.ticket-form-group input,
.ticket-form-group textarea,
.ticket-form-group select {
  padding: 14px;
  border: 1px solid #ccc;
  border-radius: 10px;
  font-size: 16px;
  background: #fdfdfd;
  transition: border-color 0.2s;
}

.ticket-form-group input:focus,
.ticket-form-group textarea:focus,
.ticket-form-group select:focus {
  border-color: #4a90e2;
  outline: none;
}

/* Textarea más grande */
.ticket-form-group textarea {
  min-height: 120px;
  resize: vertical;
}

/* Botones */
.ticket-form-actions {
  display: flex;
  gap: 15px;
  margin-top: 15px;
}

.ticket-btn-primary {
  background: #4a90e2;
  color: white;
  border: none;
  padding: 14px 20px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  flex: 1;
  transition: background 0.3s ease;
}

.ticket-btn-primary:hover {
  background: #357ab7;
}

.ticket-btn-secondary {
  background: #e0e0e0;
  color: #333;
  border: none;
  padding: 14px 20px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 16px;
  flex: 1;
  transition: background 0.3s ease;
}

.ticket-btn-secondary:hover {
  background: #ccc;
}


/* mail */

.mail-card {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
  padding: 30px;
  width: 100%;
  /* Ocupa todo el ancho disponible */
  max-width: 1200px;
  /* Más ancho que antes */
  margin: 20px auto;
  /* Centrado y con separación arriba/abajo */
}

.mail-group {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
}

.mail-label {
  font-weight: 600;
  margin-bottom: 8px;
  color: #222;
  font-size: 1rem;
}

.mail-select,
.mail-input,
.mail-textarea {
  padding: 12px 14px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 1rem;
  font-family: inherit;
  width: 100%;
  box-sizing: border-box;
}

.mail-textarea {
  resize: vertical;
  min-height: 180px;
  /* más alto para que se vea cómodo */
}

.mail-actions {
  text-align: right;
  margin-top: 20px;
}

.mail-button {
  background-color: #0d6efd;
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  padding: 12px 24px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s;
}

.mail-button:hover {
  background-color: #0b5ed7;
}




.chat-container {
  border: 1px solid #ccc;
  height: 150px;
  overflow-y: auto;
  padding: 10px;
  background-color: #f9f9f9;
}

.chat-message {
  max-width: 70%;
  padding: 8px 12px;
  margin: 5px 0;
  border-radius: 15px;
  clear: both;
  word-wrap: break-word;
}

.chat-admin {
  background-color: #d1ecf1;
  color: #0c5460;
  float: right;
  text-align: right;
}

.chat-cliente {
  background-color: #e2e3e5;
  color: #383d41;
  float: left;
  text-align: left;
}



/* ventas y compras vista */

.vc-container {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
}

.vc-toolbar {
  background: #ffffff;
  border-bottom: 1px solid #dcdcdc;
  padding: 10px 15px;
  display: flex;
  align-items: center;
  gap: 10px;

  /* Altura fija */
  height: 60px;
  box-sizing: border-box;
}

.btn-cl1 {
  background: #0d6efd;
}

.btn-cl2 {
  background: #167509;
}

.vc-file-btn {

  color: white;
  padding: 8px 15px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  user-select: none;
}

.vc-file-btn i {
  font-size: 16px;
}

.vc-file-btn input[type="file"] {
  display: none;
}

.vc-content {
  flex: 1;
  overflow: auto;
  background: #f8f9fa;
  padding: 10px;
  border-top: 1px solid #eee;
}

/* loader para la carga del archivo, se puede usar en otras vistas, mover despues */
/* Fondo oscuro translúcido */
.loader-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  display: none;
  /* Oculto por defecto */
}

/* Animación circular */
.loader {
  width: 60px;
  height: 60px;
  border: 6px solid #dcdcdc;
  border-top-color: #3498db;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.loader-text {
  color: white;
  margin-top: 15px;
  font-size: 18px;
  font-weight: bold;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}


/* estilo para formulario de modal o contenedor agrupando labels y selects*/

.form-group2 {
  margin-bottom: 15px;
  display: flex;
  flex-direction: column;
}

.form-group2 label {
  margin-bottom: 5px;
  font-weight: bold;
  font-size: 14px;
  color: #333;
}

.form-group2 input,
.form-group2 select {
  padding: 8px 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  width: 100%;
  box-sizing: border-box;
}

.form-group2 input:focus,
.form-group2 select:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 3px rgba(0, 123, 255, 0.5);
}