.admin-orders-box {
  display: flex;
  justify-content: center;
  width: 100%;
}

#admin-orders {
  max-width: 912px;
  width: 100%;
  font-size: 0.875rem;
  color: rgba(66, 66, 66, 1);
  border: 1px solid rgba(0, 0, 0, 0.14);
  border-radius: 4px;
  overflow: hidden;
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.12),
    0 1px 2px rgba(0, 0, 0, 0.08);
}

.admin-orders__search-fields {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 16px 20px 16px;
  font-size: 1rem;
}

.admin-orders__info-row {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-bottom: 25px;
  position: relative;
}

.admin-orders__info-row-hover {
  display: inline-flex;
  align-content: center;
  justify-content: center;
  gap: 6px;
}

.admin-orders__info-row-hover:hover ~ .admin-orders__info-row-info {
  opacity: 1;
  z-index: 1;
}

.admin-orders__info-row h2 {
  margin: 0;
  text-align: center;
  text-wrap: nowrap;
}

.admin-orders__info-row .admin-orders__info-row-icon {
  width: 24px;
  height: 24px;
  display: block;
  fill: rgba(33, 150, 243);
}

.admin-orders__info-row-info {
  opacity: 0;
  padding: 12px 15px;
  top: 36px;
  left: -16px;
  right: -16px;
  position: absolute;
  text-align: center;
  color: white;
  background-color: rgba(22, 77, 128, 1);
  font-size: 0.875rem;
  line-height: 1.4;
  z-index: -1;
  transition: opacity 0.2s;
}

.admin-orders__search-fields-row {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  width: 100%;
  gap: 30px;
}

.admin-orders__info-row + .admin-orders__search-fields-row {
  gap: 20px;
  margin-bottom: 30px;
}

.admin-orders__search-field {
  position: relative;
  display: inline-flex;
}

.admin-orders__info-row
  + .admin-orders__search-fields-row
  .admin-orders__search-field {
  flex: 0 1 270px;
}

.admin-orders__search-field input {
  padding: 0;
  font: inherit;
  border: none;
  border-radius: 4px;
  background: transparent;
  width: 100%;
}

.admin-orders__search-field input:focus {
  outline: none;
}

.admin-orders__search-field label {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  transform-origin: left top;
  color: rgba(0, 0, 0, 0.54);
  text-wrap: nowrap;
  pointer-events: none;
  transition:
    transform 150ms cubic-bezier(0.4, 0, 0.2, 1),
    color 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* Floated: on focus and when there is a value */
.admin-orders__search-field.always-up label,
.admin-orders__search-field:has(input:focus) label,
.admin-orders__search-field:has(input:not(:placeholder-shown)) label {
  transform: translateY(-120%) scale(0.85);
}

.admin-orders__search-field:has(input:focus) label {
  color: #005a8b;
}

.admin-orders__search-field input[type="date"] {
  cursor: text;
}

.admin-orders__search-field
  input[type="date"]::-webkit-calendar-picker-indicator {
  cursor: pointer;
}

.admin-orders__search-field-underline {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  border-bottom: 1px solid rgba(189, 189, 189, 1);
  transition:
    border-bottom 0.2s,
    border-color 0.2s;
  pointer-events: none;
}

.admin-orders__search-field
  input:focus
  ~ .admin-orders__search-field-underline {
  border-bottom: 1px solid #005a8b;
}

.admin-orders__clear-button,
.admin-orders__search-button {
  box-shadow:
    0px 3px 1px -2px rgba(0, 0, 0, 0.2),
    0px 2px 2px 0px rgba(0, 0, 0, 0.14),
    0px 1px 5px 0px rgba(0, 0, 0, 0.12);
  min-width: 64px;
  padding: 6px 16px;
  border-radius: 4px;
  border: 0;
  cursor: pointer;
}

.admin-orders__clear-button {
  background-color: rgba(212, 162, 62, 1);
}

.admin-orders__clear-button:hover {
  background-color: rgba(192, 142, 42, 1);
}

.admin-orders__search-button {
  color: white;
  background-color: rgba(22, 77, 128, 1);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.admin-orders__search-button:hover {
  background-color: rgba(9, 30, 50, 1);
}

.admin-orders__search-button span {
  display: inline-flex;
  align-items: center;
}

.admin-orders__search-button svg {
  display: block;
  width: 20px;
  height: 20px;
  fill: white;
}

.admin-orders__table {
  width: 100%;
  table-layout: fixed;
}

.admin-orders__table-row {
  border-bottom: 1px solid #ddd;
}

.admin-orders__table-row:has(a) {
  cursor: pointer;
}

.admin-orders__table-row:has(a):hover {
  background-color: rgba(0, 0, 0, 0.0392156862745098);
}

.admin-orders__table th {
  padding: 6px 24px 6px 16px;
  background-color: #005a8b !important;
  border: none !important;
}

.admin-orders__table th:nth-child(1) {
  width: 20%;
}
.admin-orders__table th:nth-child(2) {
  width: 60%;
}
.admin-orders__table th:nth-child(3) {
  width: 20%;
}

.admin-orders__cell-label {
  display: none;
  flex: 0 0 40%;
}

.admin-orders__sort-label {
  color: white !important;
  font-weight: 600;
  padding: 0;
  border: none;
  cursor: pointer;
  background-color: unset;
  text-wrap: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
}

.admin-orders__sort-label:hover,
.admin-orders__sort-label:hover .admin-orders__sort-label-icon {
  opacity: 0.64;
}

.admin-orders__sort-label span {
  display: inline-flex;
  align-items: center;
}

.admin-orders__sort-label-icon {
  display: block;
  width: 18px;
  height: 18px;
  fill: transparent;
  transition:
    opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms,
    transform 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

.admin-orders__sort-label[data-direction="asc"] .admin-orders__sort-label-icon,
.admin-orders__sort-label[data-direction="desc"]
  .admin-orders__sort-label-icon {
  fill: white;
}

.admin-orders__sort-label[data-direction="desc"]
  .admin-orders__sort-label-icon {
  transform: rotate(180deg);
}

.admin-orders__mobile-sort-row {
  display: none;
}

.admin-orders__table .admin-orders__mobile-sort-cell {
  display: block;
  width: 100%;
  height: auto;
  padding: 24px 10px 0 10px;
  border: none !important;
}

.admin-orders__mobile-sort-field {
  position: relative;
  display: block;
  width: 100%;
  padding-top: 6px;
}

.admin-orders__mobile-sort-label {
  position: absolute;
  font-size: 1rem;
  left: 0;
  top: 50%;
  font-weight: 500;
  transform: translateY(-105%) scale(0.85);
  transform-origin: left top;
  color: rgba(0, 0, 0, 0.54);
  text-wrap: nowrap;
  pointer-events: none;
  transition: color 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

.admin-orders__mobile-sort-field:has(#mobile-sort:focus)
  .admin-orders__mobile-sort-label {
  color: #005a8b;
}

#mobile-sort {
  appearance: none;
  border: none;
  border-bottom: 1px solid rgba(189, 189, 189, 1);
  width: 100%;
  background: transparent;
  font: inherit;
  font-weight: 500;
  cursor: pointer;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='rgba(0,0,0,0.54)'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 4px center;
  padding-right: 30px;
}

#mobile-sort:focus,
#mobile-sort:focus-visible {
  outline: none;
  border-bottom: 1px solid #005a8b;
}

.admin-orders__loading-row[hidden],
.admin-orders__loading-cell[hidden] {
  display: none !important;
}

.admin-orders__loading-cell {
  padding: 0 !important;
  background-color: transparent !important;
  border: none !important;
  width: 100% !important;
  height: auto !important;
}

.admin-orders__progress {
  position: relative;
  display: block;
  height: 4px;
  overflow: hidden;
  background-color: rgba(212, 162, 62, 0.3);
}

.admin-orders__progress::before,
.admin-orders__progress::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  background-color: rgba(212, 162, 62, 1);
  will-change: left, right;
}

.admin-orders__progress::before {
  animation: admin-orders-progress-1 2.1s
    cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
}

.admin-orders__progress::after {
  animation: admin-orders-progress-2 2.1s cubic-bezier(0.165, 0.84, 0.44, 1)
    1.15s infinite;
}

@keyframes admin-orders-progress-1 {
  0% {
    left: -35%;
    right: 100%;
  }
  60% {
    left: 100%;
    right: -90%;
  }
  100% {
    left: 100%;
    right: -90%;
  }
}

@keyframes admin-orders-progress-2 {
  0% {
    left: -200%;
    right: 100%;
  }
  60% {
    left: 107%;
    right: -8%;
  }
  100% {
    left: 107%;
    right: -8%;
  }
}

.admin-orders__table td {
  display: table-cell;
  text-align: start;
  font-weight: 400;
  line-height: 1.43;
  border: none !important;
  border-bottom: 1px solid #ddd !important;
  letter-spacing: 0.01071em;
  vertical-align: inherit;
  height: 53px;
  padding: 0;
}

.admin-orders__table td > a {
  display: block;
  height: 100%;
  box-sizing: border-box;
  padding: 6px 24px 6px 16px;
  color: inherit !important;
  text-decoration: none !important;
}

.admin-orders__table td > a.admin-orders__order-names-container {
  display: flex;
}

.admin-orders__order-names-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.admin-orders__order-name,
.admin-orders__order-title {
  overflow-wrap: break-word;
}

.admin-orders__pager {
  display: flex;
  justify-content: flex-end;
  width: 100%;
  gap: 25px;
  align-items: center;
  min-height: 52px;
  padding: 5px;
}

#rows-per-page {
  appearance: none;
  background: transparent;
  border: none;
  font: inherit;
  color: inherit;
  padding: 0 24px 0 8px;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='rgba(0,0,0,0.54)'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 4px center;
  cursor: pointer;
}

#rows-per-page:focus {
  outline: none;
}

#rows-per-page:focus-visible {
  outline: 2px solid #005a8b;
  outline-offset: 2px;
  border-radius: 2px;
}

.admin-orders__rows-label-short {
  display: none;
}

.admin-orders__page-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px;
  aspect-ratio: 1;
  border: none;
  border-radius: 50%;
  background-color: transparent;
  color: rgba(0, 0, 0, 0.54);
  cursor: pointer;
  transition: background-color 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

.admin-orders__page-button:hover:not(:disabled) {
  background-color: rgba(0, 0, 0, 0.06);
}

.admin-orders__page-button:disabled {
  color: rgba(0, 0, 0, 0.26);
  cursor: default;
}

.admin-orders__page-button svg {
  display: block;
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.admin-orders__empty {
  padding-left: 16px !important;
}

@media (max-width: 645px) {
  .admin-orders__search-fields {
    padding: 8px 10px 10px 10px;
  }

  .admin-orders__header-row {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }

  .admin-orders__mobile-sort-row {
    display: flex;
  }

  .admin-orders__table thead,
  .admin-orders__table .admin-orders__loading-row,
  .admin-orders__table .admin-orders__loading-cell {
    display: block;
  }

  .admin-orders__table,
  .admin-orders__table tbody,
  .admin-orders__table-row,
  .admin-orders__table td {
    display: block;
    width: 100%;
  }

  .admin-orders__table td {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 8px 10px 8px 10px;
    border-bottom: none !important;
    text-align: start;
    height: auto;
  }

  .admin-orders__table td > a {
    flex: 1 1 auto;
    height: auto;
    padding: 0;
  }

  .admin-orders__cell-label {
    display: block;
    font-weight: 600;
    color: rgba(0, 0, 0, 0.6);
  }
  .admin-orders__order-names-container {
    flex-direction: row;
    gap: 10px;
  }

  .admin-orders__empty {
    padding-left: 1ch !important;
  }

  .admin-orders__pager {
    padding: 5px 10px;
    gap: 15px;
  }

  #rows-per-page {
    padding: 0 24px 0 4px;
  }

  .admin-orders__rows-label-full {
    display: none;
  }

  .admin-orders__rows-label-short {
    display: inline;
  }

  .admin-orders__page-button {
    padding: 6px;
  }

  .admin-orders__page-button svg {
    width: 20px;
    height: 20px;
  }

  .admin-orders__page-button[data-page="last"],
  .admin-orders__page-button[data-page="first"] {
    display: none;
  }
}

@media (max-width: 450px) {
  .admin-orders__order-names-container {
    flex-direction: column;
    gap: 10px;
  }
}

@media (max-width: 400px) {
  .admin-orders__pager {
    flex-wrap: wrap;
    justify-content: center;
  }
}

@media (max-width: 300px) {
  .admin-orders__table td {
    flex-direction: column;
    justify-content: flex-start;
    gap: 12px;
    padding: 8px 10px 8px 10px;
  }
}
