.order-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

#open-order {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  flex: 0 0 auto;
  min-height: 42px;
  padding: 7px 8px 7px 16px;
  border: 1px solid var(--ink);
  border-radius: 100px;
  background: var(--ink);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
#open-order:hover { background: #3e5746; }
#order-count {
  display: inline-grid;
  place-items: center;
  min-width: 27px;
  height: 27px;
  padding-inline: 5px;
  border-radius: 100px;
  background: #fff;
  color: var(--ink);
  line-height: 1;
}

#order-dialog {
  width: min(560px, calc(100% - 32px));
  max-width: 100%;
  max-height: min(90vh, 760px);
  max-height: min(90dvh, 760px);
  overflow-y: auto;
}
#order-dialog .dialog-head { position: relative; }
#close-order {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  padding: 0 0 3px;
  border: 0;
  border-radius: 50%;
  background: var(--soft);
  font-size: 27px;
  line-height: 1;
}
#close-order:hover { background: #e6e3d9; }
#order-body { padding: 22px 24px 24px; }
.order-intro { color: #657065; font-size: 13px; }
.order-list, .order-receipt-list { margin: 0; padding: 0; list-style: none; }
.order-list { margin-top: 4px; }
.order-item { padding: 17px 0; border-bottom: 1px solid var(--line); }
.order-item-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 15px; }
.order-item-heading h3 { font: 500 23px/1.2 var(--serif); letter-spacing: -.035em; }
.order-item-heading strong, .order-receipt-item strong { flex-shrink: 0; font-size: 14px; font-weight: 650; white-space: nowrap; }
.order-unit { margin-top: 4px; color: #657065; font-size: 12px; }
.order-item-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 13px; }
.order-quantity { display: inline-flex; align-items: center; gap: 4px; }
.order-quantity-button {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  font-size: 20px;
  line-height: 1;
}
.order-quantity-button:hover { background: var(--soft); }
.order-quantity-value { min-width: 28px; text-align: center; font-size: 14px; font-weight: 600; }
.order-remove, .order-return {
  border: 0;
  background: transparent;
  color: #5c695f;
  font-size: 13px;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.order-remove { min-height: 40px; padding: 7px 0 7px 8px; }
.order-remove:hover, .order-return:hover { color: var(--sienna); }
.order-total { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 20px 0 14px; font-size: 15px; font-weight: 600; }
.order-total strong { font: 500 26px/1.1 var(--serif); letter-spacing: -.035em; white-space: nowrap; }
.order-notice { margin: 0 0 17px; padding: 12px 14px; border-left: 2px solid var(--sienna); background: var(--soft); color: #4d5b50; font-size: 13px; line-height: 1.5; }
.order-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  padding: 11px 18px;
  border: 1px solid var(--ink);
  border-radius: 100px;
  background: var(--ink);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
}
.order-submit:hover { background: #3e5746; }
.order-return { display: block; margin: 11px auto 0; min-height: 40px; padding: 8px 12px; }
.order-empty { padding: 14px 6px 4px; text-align: center; }
.order-empty-mark, .order-confirmation-mark { display: grid; place-items: center; margin: 0 auto 15px; width: 52px; height: 52px; border-radius: 50%; background: var(--soft); color: var(--sienna); font-size: 26px; }
.order-empty h3, .order-confirmation h3 { font: 500 27px/1.15 var(--serif); letter-spacing: -.04em; }
.order-empty p, .order-confirmation p { max-width: 34ch; margin: 10px auto 0; color: #5c695f; font-size: 14px; line-height: 1.55; }
.order-empty .order-return { margin-top: 20px; }
.order-confirmation { padding: 8px 0 19px; text-align: center; }
.order-confirmation h3:focus { outline-offset: 4px; }
.order-receipt-list { border-top: 1px solid var(--line); }
.order-receipt-item { display: flex; justify-content: space-between; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.order-receipt-item span { min-width: 0; overflow-wrap: anywhere; }

@media (max-width: 480px) {
  #open-order[data-nonempty="true"] {
    position: fixed;
    z-index: 10;
    right: max(16px, env(safe-area-inset-right));
    bottom: max(16px, env(safe-area-inset-bottom));
    box-shadow: 0 5px 22px #253b3040;
  }
  #order-body { padding: 19px 18px 20px; }
  .order-item-heading h3 { font-size: 21px; }
}
