body {
  background-color: rgba(240, 130, 130, .2);
  padding-top: 80px;
}

header {
  padding: 15px 20px;
  background-color: var(--primary-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--secondary-color);
  z-index: 100;
  position: fixed;
  top: 0;
  height: 80px;
  right: 0;
  left: 0;
}

.close_btn {
  background-color: transparent;
  color: white;
  border: none;
  padding: 5px 8px;
  font-size: 1.0rem;
  font-weight: 500;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.close_btn:hover {
  background-color: rgb(220, 14, 14);
}

.sales_card, .purchases_card {
  display: none;
  margin: 20px 10px;
  border-radius: 2px;
  overflow: scroll;
  scrollbar-width: none;
}

.sales_card.active, .purchases_card.active {
  display: block;
}

.button_card {
  display: flex;
  padding: 10px 8px;
  overflow-x: scroll;
  scrollbar-width: none;
  position: sticky;
  z-index: 100;
  top: 80px;
  background-color: white;
}

.button_card button {
 font-size: 1.0rem;
 border: none;
 padding: 8px 12px;
 text-wrap: nowrap;
 background-color: transparent;
 font-weight: 600;
 color: rgb(44, 43, 43);
 border: 1px solid rgba(1, 1, 16, 0.1);
 margin-right: 8px;
 border-radius: 7px;
 transition: all 0.3s ease;
 cursor: pointer;
}

.button_card button.active {
  background-color: var(--primary-color);
  color: rgb(127, 171, 131);
}

.button_card button:hover {
  background-color: var(--primary-color);
  color: rgb(191, 185, 185);
}

.head, .head2, .total_card {
  display: flex;
  flex-direction: column;
  margin: auto;
  line-height: 1.8;
  width: 96%;
  font-weight: 600;
  align-items: center;
  justify-content: center;
  margin-bottom: 30px;
  padding: 30px 10px 20px 10px;
  border-bottom: 3px solid black;

}

.head h2 {
  font-weight: 600;
}

.head p {
  font-size: 1.0rem;
}

.head2 {
  align-items: start;
  border: none;
  margin-top: -30px;
}

.total_card {
  border: none;
  margin-top: -10px;
  gap: 20px;
  flex-direction: row;
}

.head2 p, .total_card p, .total_card b {
  font-size: 1.0rem;
}

table {
  width: 98%;
  border-collapse: collapse;
  margin: 2vh auto;
  background-color: white;
  border: 1px solid black;
  font-size: 1.0rem;
}

th, td {
  padding: 10px 15px;
  text-align: left;
  color: black;
  border: 1px solid black; 
}

th {
  background-color: rgba(16, 16, 16, 0.9);
  color: rgb(232, 229, 229);
}

table a {
  font-size: 1.0rem;
  text-decoration: none;
  padding: 8px 12px;
  color: green;
}

.print_card {
  border: none;
  width: fit-content;
  background-color: rgb(2, 2, 101);
  color: white;
  padding: 8px 20px;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1.0rem;
  position: absolute;
  right: 50%;
  transform: translate(50%, -20px);
  font-weight: 600;
}

.print_card:hover {
  background-color: rgb(4, 4, 139);
}

.purchases_card table, .purchases_full table {
  background-color: rgba(248, 244, 244, 0.9);
}

@media print {
  header, .button_card, button {
    display: none;
  }

  body {
    padding-top: 0;
  }
 
}
