.order-nav {
  position: relative;
}

.order-badge {
  position: absolute;
  top: 2px;
  left: calc(50% + 8px);
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border: 2px solid #080808;
  border-radius: 9px;
  background: #ff1018;
  color: #fff;
  display: none;
  place-items: center;
  font-size: 10px;
  line-height: 1;
  font-weight: 900;
}

.order-badge.show {
  display: grid;
}

.order-add-btn {
  width: 100%;
  min-height: 62px;
  margin-top: 20px;
  padding: 12px 17px;
  border: 0;
  border-radius: 16px;
  background: #ff1018;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  box-shadow: 0 0 18px rgba(255, 16, 24, .38);
  font-weight: 900;
}

.order-add-btn:active {
  transform: scale(.985);
  background: #e90008;
}

.order-add-btn.continue {
  border: 2px solid #ff1018;
  background: #101010;
  box-shadow: 0 0 12px rgba(255, 16, 24, .45), inset 0 0 12px rgba(255, 16, 24, .08);
}

.order-add-btn.continue:active {
  background: #1a1a1a;
}

.order-remove-product-btn {
  width: 100%;
  min-height: 42px;
  margin-top: 9px;
  border: 1px solid #5a2527;
  border-radius: 12px;
  background: #160708;
  color: #ff8589;
  font-size: 11px;
  font-weight: 900;
}

.order-remove-product-btn[hidden] {
  display: none;
}

.order-remove-product-btn:focus-visible {
  outline: 2px solid #ff8589;
  outline-offset: 2px;
}

.order-add-btn:focus-visible,
.order-send:focus-visible,
.order-continue:focus-visible,
.order-clear:focus-visible,
.quantity button:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.order-add-icon {
  font-size: 27px;
  line-height: 1;
}

.order-add-btn strong,
.order-add-btn small {
  display: block;
}

.order-add-btn small {
  margin-top: 3px;
  color: #ffd8da;
  font-size: 11px;
  font-weight: 700;
}

.order-modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  padding: 0;
  background: rgba(0, 0, 0, .88);
  backdrop-filter: blur(8px);
  display: none;
  align-items: flex-end;
  justify-content: center;
}

.order-modal.show {
  display: flex;
}

.order-card {
  position: relative;
  width: min(760px, 100%);
  max-height: 94vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid #3a3a3a;
  border-bottom: 0;
  border-radius: 24px 24px 0 0;
  background: linear-gradient(180deg, #101010, #030303);
  box-shadow: 0 -10px 45px rgba(255, 0, 0, .18);
}

.order-head {
  position: static;
  padding: 24px 66px 17px 18px;
  border-bottom: 1px solid #262626;
  background: transparent;
}

.order-kicker {
  color: #ff3038;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1.4px;
}

.order-head h2 {
  margin: 4px 0 5px;
  font-size: 25px;
  line-height: 1.1;
}

.order-head p {
  margin: 0;
  color: #999;
  font-size: 13px;
  line-height: 1.4;
}

.order-empty {
  min-height: 270px;
  padding: 40px 22px 100px;
  display: none;
  place-items: center;
  align-content: center;
  gap: 8px;
  text-align: center;
}

.order-empty.show {
  display: grid;
}

.order-empty b {
  font-size: 19px;
}

.order-empty span {
  color: #888;
  font-size: 13px;
}

.order-list {
  padding: 4px 18px 0;
}

.order-item {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid #282828;
}

.order-item-image {
  width: 72px;
  height: 72px;
  border: 1px solid #303030;
  border-radius: 10px;
  background: #151515;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.order-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.order-item-image span {
  color: #666;
  font-size: 10px;
}

.order-item-copy {
  min-width: 0;
}

.order-item-copy b {
  display: block;
  font-size: 14px;
  line-height: 1.25;
}

.order-item-copy small {
  display: block;
  margin-top: 4px;
  color: #888;
  font-size: 11px;
  line-height: 1.3;
}

.order-item-copy strong {
  display: block;
  margin-top: 7px;
  color: #fff;
  font-size: 14px;
}

.order-item-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 7px;
}

.quantity {
  height: 38px;
  display: grid;
  grid-template-columns: 38px 34px 38px;
  align-items: stretch;
  border: 1px solid #3a3a3a;
  border-radius: 10px;
  overflow: hidden;
  background: #111;
}

.quantity button {
  min-width: 38px;
  border: 0;
  background: #1b1b1b;
  color: #fff;
  font-size: 21px;
  line-height: 1;
}

.quantity output {
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 13px;
  font-weight: 900;
}

.order-remove {
  border: 0;
  background: transparent;
  color: #ff777b;
  padding: 4px;
  font-size: 11px;
  font-weight: 800;
}

.order-summary {
  padding: 18px 18px calc(28px + env(safe-area-inset-bottom));
}

.order-summary > div:first-child {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

.order-summary > div:first-child span {
  color: #aaa;
  font-size: 14px;
}

.order-summary > div:first-child strong {
  font-size: 25px;
}

.order-summary label {
  display: block;
  margin-bottom: 7px;
  color: #ccc;
  font-size: 13px;
  font-weight: 800;
}

.order-summary textarea {
  width: 100%;
  resize: vertical;
  min-height: 82px;
  padding: 12px;
  border: 1px solid #3a3a3a;
  border-radius: 11px;
  outline: none;
  background: #090909;
  color: #fff;
  font: inherit;
  font-size: 14px;
}

.order-summary textarea:focus {
  border-color: #ff1018;
  box-shadow: 0 0 12px rgba(255, 16, 24, .16);
}

.order-summary > small {
  display: block;
  margin: 7px 0 17px;
  color: #777;
  font-size: 11px;
  line-height: 1.4;
}

.order-send,
.order-continue,
.order-clear {
  width: 100%;
  min-height: 50px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-decoration: none;
}

.order-send {
  border: 0;
  background: #18c763;
  color: #fff;
  box-shadow: 0 0 20px rgba(24, 199, 99, .25);
}

.order-send span {
  font-size: 23px;
}

.order-continue {
  margin-top: 10px;
  border: 1px solid #444;
  background: #151515;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.order-clear {
  min-height: 38px;
  margin-top: 7px;
  border: 0;
  background: transparent;
  color: #ff777b;
  font-size: 11px;
  font-weight: 800;
}

@media (max-width: 390px) {
  .bottom button,
  .bottom a {
    font-size: 9px;
  }

  .order-item {
    grid-template-columns: 62px minmax(0, 1fr);
  }

  .order-item-image {
    width: 62px;
    height: 62px;
  }

  .order-item-actions {
    grid-column: 1 / -1;
    flex-direction: row;
    justify-content: flex-end;
    align-items: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .order-card {
    scroll-behavior: auto;
  }
}
