/* Laskar Jaya — checkout & keranjang. Token warna/bentuk diambil dari css/style.css (:root). */

.page-shop {
  --err: #A63A2B;
  --err-tint: #FBEFEC;
  --brass-tint: #FBF4E6;
  --brass-ink: #7A5615;
}

.shop {
  padding-block: 28px 72px;
  outline: none;
}
@media (min-width: 768px) {
  .shop { padding-block: 48px 112px; }
}

.i {
  width: 18px;
  height: 18px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Kepala halaman + stepper ---------- */

.shop-head { margin-bottom: 24px; }
.shop-head .eyebrow { margin-bottom: 10px; }
.shop-title {
  font-size: clamp(2rem, 1.4rem + 2.4vw, 2.75rem);
  line-height: 1.1;
}

.stepper {
  counter-reset: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  max-width: 640px;
  margin-top: 24px;
}
.stepper-item { position: relative; }
.stepper-item + .stepper-item::before {
  content: "";
  position: absolute;
  top: 21px;
  left: calc(-50% + 22px);
  right: calc(50% + 22px);
  height: 1px;
  background: var(--line-strong);
}
.stepper-item.is-done::before,
.stepper-item.is-current::before { background: var(--jade); }

.stepper-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: 100%;
  min-height: 44px;
  padding: 4px 2px;
  border: 0;
  background: none;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
}
.stepper-btn:disabled { cursor: default; }
.stepper-num {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface);
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  transition: background-color .2s, border-color .2s, color .2s;
}
.stepper-label {
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
}
.stepper-item.is-current .stepper-num {
  background: var(--jade);
  border-color: var(--jade);
  color: #fff;
}
.stepper-item.is-current .stepper-label { color: var(--ink); }
.stepper-item.is-done .stepper-num {
  background: var(--jade-tint);
  border-color: var(--jade);
  color: var(--jade-dark);
}
.stepper-item.is-done .stepper-label { color: var(--jade-dark); }
.stepper-item.is-done .stepper-btn:not(:disabled):hover .stepper-label { text-decoration: underline; text-underline-offset: 3px; }
@media (min-width: 560px) {
  .stepper-label { font-size: 0.85rem; }
}

/* ---------- Grid: konten + ringkasan ---------- */

.shop-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.shop-main { min-width: 0; }

@media (min-width: 960px) {
  .shop-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 40px;
    align-items: start;
  }
  .shop-main { grid-column: 1; grid-row: 1; }
  .summary {
    grid-column: 2;
    grid-row: 1;
    position: sticky;
    top: calc(var(--header-h) + 24px);
  }
}
.shop-grid.is-confirm { display: block; }
.shop-grid.is-confirm .shop-main { max-width: 860px; margin-inline: auto; }
.shop-grid.is-empty { display: block; }
.shop-grid.is-empty .summary { display: none; }
.shop-grid.is-empty .shop-main { max-width: 720px; }

/* ---------- Ringkasan pesanan ---------- */

.summary {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
}
.summary[hidden] { display: none; }

.summary-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 56px;
  padding: 10px 16px;
  border: 0;
  border-radius: var(--radius-card);
  background: none;
  color: var(--jade-dark);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}
.summary-toggle-label { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.summary-chev { width: 16px; height: 16px; transition: transform .25s var(--ease-out); }
.summary.is-open .summary-chev { transform: rotate(180deg); }
.summary-toggle-total {
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.summary-body {
  display: none;
  padding: 4px 16px 18px;
  border-top: 1px solid var(--line);
}
.summary.is-open .summary-body { display: block; }
.summary-title { display: none; }

@media (max-width: 959px) {
  /* Di langkah 1 isi keranjang sudah menjadi ringkasan. */
  .shop-grid[data-step="1"] .summary { display: none; }
}
@media (min-width: 960px) {
  .summary-toggle { display: none; }
  .summary-body { display: block; padding: 24px; border-top: 0; }
  .summary-title {
    display: block;
    margin-bottom: 14px;
    font-size: 1.1rem;
    letter-spacing: -0.015em;
  }
}

.summary-list { border-bottom: 1px solid var(--line); }
.summary-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  padding: 12px 0;
  font-size: 0.93rem;
}
.summary-item + .summary-item { border-top: 1px dashed var(--line); }
.summary-item-name { display: flex; flex-direction: column; gap: 2px; font-weight: 600; line-height: 1.35; }
.summary-item-qty { color: var(--muted); font-size: 0.82rem; font-weight: 500; }
.summary-item-price { font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.summary-empty { padding: 12px 0; color: var(--muted); font-size: 0.92rem; }

.summary-totals { padding-top: 10px; }
.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 4px 0;
  font-size: 0.93rem;
  color: var(--muted);
}
.summary-row dd { color: var(--ink); font-variant-numeric: tabular-nums; }
.summary-row-total { margin-top: 6px; padding-top: 12px; border-top: 1px solid var(--line); color: var(--ink); font-weight: 700; }
.summary-row-total dd { font-size: 1.3rem; letter-spacing: -0.02em; }
.summary-note {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.55;
}

/* ---------- Panel langkah ---------- */

.panel {
  padding: 20px 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
}
.panel[hidden] { display: none; }
@media (min-width: 640px) {
  .panel { padding: 32px; }
}
.panel-title {
  font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.6rem);
  line-height: 1.2;
  outline: none;
}
.panel-lead {
  margin-top: 8px;
  max-width: 62ch;
  color: var(--muted);
  font-size: 0.95rem;
}

.panel-actions {
  display: flex;
  flex-direction: column-reverse;
  gap: 10px;
  margin-top: 28px;
}
.panel-actions[hidden], [data-cart-filled][hidden] { display: none; }
.panel-actions .btn { width: 100%; }
@media (min-width: 560px) {
  .panel-actions { flex-direction: row; justify-content: space-between; align-items: center; }
  .panel-actions .btn { width: auto; }
}

.link-btn {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 4px;
  border: 0;
  background: none;
  color: var(--jade);
  font: inherit;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: rgb(15 92 77 / .35);
  text-underline-offset: 4px;
  cursor: pointer;
}
.link-btn:hover { text-decoration-color: currentColor; }

/* ---------- Langkah 1: keranjang ---------- */

.cart-list { margin-top: 12px; }
.cart-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "info remove"
    "qty subtotal";
  align-items: center;
  gap: 12px 12px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.cart-item-side { display: contents; }
.cart-item-info { grid-area: info; min-width: 0; align-self: start; }
.cart-item .qty { grid-area: qty; justify-self: start; }
.cart-item-subtotal { grid-area: subtotal; justify-self: end; }
.remove-btn { grid-area: remove; align-self: start; justify-self: end; }

.cart-item-cat {
  color: var(--brass-ink);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.cart-item-name {
  margin-top: 2px;
  font-size: 1.05rem;
  line-height: 1.3;
  letter-spacing: -0.012em;
}
.cart-item-price { margin-top: 4px; font-size: 0.92rem; color: var(--ink); font-variant-numeric: tabular-nums; }
.cart-item-eta { margin-top: 2px; font-size: 0.84rem; color: var(--muted); }
.cart-item-subtotal {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

@media (min-width: 720px) {
  .cart-item {
    grid-template-columns: minmax(0, 1fr) auto 130px auto;
    grid-template-areas: "info qty subtotal remove";
    gap: 20px;
  }
  .cart-item .qty, .cart-item-subtotal, .remove-btn { align-self: center; }
}

.qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-btn);
  background: var(--surface);
}
.qty-btn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  cursor: pointer;
  border-radius: var(--radius-btn);
  transition: background-color .15s, color .15s;
}
.qty-btn:hover:not(:disabled) { background: var(--jade-tint); color: var(--jade-dark); }
.qty-btn:disabled { color: var(--line-strong); cursor: not-allowed; }
.qty-btn .i { width: 16px; height: 16px; }
.qty-input {
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-inline: 1px solid var(--line);
  background: none;
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
  appearance: textfield;
}
.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-input:focus-visible { outline-offset: -2px; border-radius: 0; }
.qty-unit { display: none; padding: 0 12px 0 6px; color: var(--muted); font-size: 0.85rem; }
@media (min-width: 420px) {
  .qty-unit { display: inline; }
}

.remove-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 44px;
  min-height: 44px;
  padding: 0 6px;
  border: 0;
  border-radius: var(--radius-btn);
  background: none;
  color: var(--muted);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: color .15s, background-color .15s;
}
.remove-btn:hover { color: var(--err); background: var(--err-tint); }
.remove-btn span { display: none; }
@media (min-width: 720px) {
  .remove-btn { padding: 0 10px; }
  .remove-btn span { display: inline; }
}

.cart-subtotal {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding-top: 18px;
  font-weight: 600;
}
.cart-subtotal strong {
  font-size: 1.3rem;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.cart-empty {
  padding: 28px 4px 12px;
  text-align: center;
}
.cart-empty[hidden] { display: none; }
.cart-empty-mark {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: var(--jade-tint);
  color: var(--jade);
}
.cart-empty-mark svg {
  width: 38px;
  height: 38px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.cart-empty-title { font-size: 1.2rem; font-weight: 700; letter-spacing: -0.015em; }
.cart-empty-text { max-width: 42ch; margin: 8px auto 0; color: var(--muted); }
.cart-empty-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 22px;
}
@media (max-width: 479px) {
  .cart-empty-actions .btn { width: 100%; }
}

/* ---------- Langkah 2: form ---------- */

.form { margin-top: 22px; }
.form-alert {
  margin-bottom: 20px;
  padding: 12px 14px;
  border: 1px solid rgb(166 58 43 / .25);
  border-left: 3px solid var(--err);
  border-radius: var(--radius-btn);
  background: var(--err-tint);
  color: var(--err);
  font-size: 0.92rem;
  font-weight: 600;
}
.form-alert[hidden] { display: none; }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.field-row { display: grid; grid-template-columns: minmax(0, 1fr); column-gap: 16px; }
@media (min-width: 640px) {
  .field-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.field label:not(.check) { font-size: 0.92rem; font-weight: 600; }
.req { color: var(--brass); font-weight: 700; }
.opt { color: var(--muted); font-weight: 500; }

.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-btn);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  line-height: 1.45;
  transition: border-color .15s, box-shadow .15s;
}
.field textarea { min-height: 116px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #8A929A; }
.field input:hover, .field textarea:hover { border-color: #BDB7AA; }
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--jade);
  box-shadow: 0 0 0 3px rgb(15 92 77 / .16);
}
.field.has-error input, .field.has-error textarea { border-color: var(--err); }
.field.has-error input:focus, .field.has-error textarea:focus { box-shadow: 0 0 0 3px rgb(166 58 43 / .16); }

.field-hint { color: var(--muted); font-size: 0.84rem; line-height: 1.5; }
.field-error { color: var(--err); font-size: 0.87rem; font-weight: 600; line-height: 1.45; }
.field-error:empty { display: none; }

.field-check { margin-top: 6px; }
.check {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-height: 44px;
  padding: 10px 0;
  font-size: 0.95rem;
  line-height: 1.5;
  cursor: pointer;
}
.check input {
  position: absolute;
  top: 10px;
  left: 0;
  width: 24px;
  height: 24px;
  margin: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 1;
}
.check-box {
  display: grid;
  place-items: center;
  flex: none;
  width: 24px;
  height: 24px;
  margin-top: 0;
  border: 1.5px solid var(--line-strong);
  border-radius: 6px;
  background: var(--surface);
  transition: background-color .15s, border-color .15s;
}
.check-box svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: #fff;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0;
  transform: scale(.6);
  transition: opacity .15s, transform .15s var(--ease-out);
}
.check input:checked + .check-box { background: var(--jade); border-color: var(--jade); }
.check input:checked + .check-box svg { opacity: 1; transform: none; }
.check input:focus-visible + .check-box { outline: 2px solid var(--focus); outline-offset: 3px; }
.field-check.has-error .check-box { border-color: var(--err); }
.check-text a, .pay-agree a {
  color: var(--jade);
  font-weight: 600;
  text-underline-offset: 3px;
}

/* ---------- Langkah 3: pembayaran ---------- */

.methods { margin: 0; padding: 0; border: 0; min-width: 0; }
.methods-legend { padding: 0; margin-bottom: 12px; font-weight: 700; font-size: 1rem; }
.method { position: relative; display: block; margin-bottom: 10px; cursor: pointer; }
.method input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}
.method-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-card);
  background: var(--surface);
  transition: border-color .15s, box-shadow .15s, background-color .15s;
}
.method:hover .method-card { border-color: #BDB7AA; }
.method input:checked + .method-card {
  border-color: var(--jade);
  box-shadow: inset 0 0 0 1px var(--jade);
  background: #FAFCFB;
}
.method input:focus-visible + .method-card { outline: 2px solid var(--focus); outline-offset: 3px; }
.methods.has-error .method-card { border-color: var(--err); }

.method-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-btn);
  background: var(--jade-tint);
  color: var(--jade);
}
.method-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.method-text { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.method-name { font-weight: 700; }
.method-desc { color: var(--muted); font-size: 0.9rem; line-height: 1.5; }
.method-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  align-self: flex-start;
  margin-top: 6px;
  color: var(--jade-dark);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.method-tag::before {
  content: "";
  width: 5px;
  height: 5px;
  background: var(--brass);
  transform: rotate(45deg);
}
.method-radio {
  flex: none;
  width: 22px;
  height: 22px;
  margin-top: 11px;
  border: 1.5px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface);
  transition: border-color .15s, box-shadow .15s;
}
.method input:checked + .method-card .method-radio {
  border-color: var(--jade);
  box-shadow: inset 0 0 0 5px var(--jade);
}

.review {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.review-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.review-title { font-size: 1rem; }
.review-list { margin-top: 6px; }
.review-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  padding: 8px 0;
  border-bottom: 1px dashed var(--line);
  font-size: 0.93rem;
}
.review-row:last-child { border-bottom: 0; }
.review-row dt { color: var(--muted); font-size: 0.82rem; }
.review-row dd { overflow-wrap: anywhere; white-space: pre-line; }
@media (min-width: 520px) {
  .review-row { grid-template-columns: 130px minmax(0, 1fr); gap: 16px; }
  .review-row dt { font-size: 0.9rem; }
}

.pay-agree { margin-top: 20px; color: var(--muted); font-size: 0.88rem; }

/* ---------- Langkah 4: konfirmasi / invoice ---------- */

.invoice-print-head { display: none; }
.confirm-head { padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
}
.status-pending {
  background: var(--brass-tint);
  border: 1px solid rgb(184 134 47 / .35);
  color: var(--brass-ink);
}
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brass);
  animation: lj-pulse 2s ease-in-out infinite;
}
@keyframes lj-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgb(184 134 47 / .45); }
  50% { box-shadow: 0 0 0 5px rgb(184 134 47 / 0); }
}
.confirm-title {
  margin-top: 14px;
  font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.2rem);
}
.confirm-lead { margin-top: 8px; color: var(--muted); max-width: 60ch; }
.confirm-lead strong { color: var(--ink); font-variant-numeric: tabular-nums; }

.invoice-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin-top: 22px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--line);
  overflow: hidden;
}
.invoice-meta > div { padding: 12px 14px; background: var(--paper); min-width: 0; }
.invoice-meta dt {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.invoice-meta dd { margin-top: 2px; font-weight: 600; font-size: 0.95rem; overflow-wrap: anywhere; }
.invoice-no { color: var(--jade-dark); font-size: 1.05rem !important; font-variant-numeric: tabular-nums; letter-spacing: 0.02em; }
.invoice-total { font-variant-numeric: tabular-nums; }
@media (max-width: 719px) {
  .invoice-meta > div:nth-child(1), .invoice-meta > div:nth-child(4) { grid-column: 1 / -1; }
}
@media (min-width: 720px) {
  .invoice-meta { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.invoice-block { margin-top: 28px; }
.invoice-sub {
  margin-bottom: 10px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--jade);
}

.invoice-table { width: 100%; border-collapse: collapse; font-size: 0.94rem; }
.invoice-table th, .invoice-table td { padding: 12px 0; text-align: left; vertical-align: top; }
.invoice-table thead th {
  padding-top: 0;
  border-bottom: 1px solid var(--line-strong);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
}
.invoice-table tbody td { border-bottom: 1px solid var(--line); }
.invoice-table .num { text-align: right; white-space: nowrap; padding-left: 16px; font-variant-numeric: tabular-nums; }
.invoice-table tfoot th, .invoice-table tfoot td { padding-top: 14px; font-weight: 700; font-size: 1.05rem; }
.invoice-table tfoot td { font-size: 1.25rem; letter-spacing: -0.02em; }
.inv-item-name { font-weight: 600; }
.inv-item-unit { display: none; }

@media (max-width: 559px) {
  .invoice-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .invoice-table tbody tr, .invoice-table tfoot tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    border-bottom: 1px solid var(--line);
  }
  .invoice-table tbody td { border-bottom: 0; padding: 0; }
  .invoice-table tbody td:first-child { grid-column: 1 / -1; padding-top: 12px; }
  .invoice-table tbody td[data-label="Jumlah"] { text-align: left; padding: 2px 0 12px; color: var(--muted); font-size: 0.86rem; }
  .invoice-table tbody td[data-label="Harga"] { display: none; }
  .invoice-table tbody td[data-label="Subtotal"] { padding: 0 0 12px; align-self: end; font-weight: 600; }
  .invoice-table tfoot tr { border-bottom: 0; }
  .invoice-table tfoot th { padding-left: 0; }
  .inv-item-unit { display: inline; }
}

.next-list { counter-reset: lj-next; }
.next-list li {
  position: relative;
  padding: 0 0 14px 44px;
  counter-increment: lj-next;
  color: var(--muted);
  font-size: 0.95rem;
}
.next-list li strong { color: var(--ink); }
.next-list li::before {
  content: counter(lj-next, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: -4px;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.5rem;
  line-height: 1.2;
  color: var(--brass);
}

.confirm-actions {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}
.confirm-actions .btn { padding-inline: 14px; }
@media (min-width: 640px) {
  .confirm-actions { display: flex; flex-wrap: wrap; }
  .confirm-actions .btn { padding-inline: 22px; }
}
.shop.is-confirm .shop-head { max-width: 860px; margin-inline: auto; }
.confirm-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 4px 10px;
  margin-top: 18px;
  color: var(--muted);
}
@media (max-width: 479px) {
  .confirm-foot { flex-direction: column; }
  .confirm-foot > span { display: none; }
}

/* ---------- Toast ---------- */

.shop-toast {
  position: fixed;
  left: 50%;
  bottom: 16px;
  z-index: 120;
  display: flex;
  align-items: center;
  gap: 14px;
  width: max-content;
  max-width: calc(100% - 32px);
  padding: 8px 8px 8px 16px;
  min-height: 52px;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  font-size: 0.92rem;
  box-shadow: 0 18px 40px -18px rgb(16 24 31 / .55);
  transform: translate(-50%, 16px);
  opacity: 0;
  transition: transform .25s var(--ease-out), opacity .2s;
}
.shop-toast > span { padding-block: 6px; }
.shop-toast:not(:has(button)) { padding-right: 16px; }
.shop-toast.is-in { transform: translate(-50%, 0); opacity: 1; }
.shop-toast[hidden] { display: none; }
.shop-toast-btn {
  flex: none;
  min-height: 44px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: rgb(255 255 255 / .08);
  color: var(--brass-soft);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.shop-toast-btn:hover { background: rgb(255 255 255 / .16); }

@media (prefers-reduced-motion: reduce) {
  .status-dot { animation: none; }
  .shop-toast, .stepper-num, .summary-chev, .check-box svg { transition: none; }
}

/* ---------- Cetak / simpan invoice ---------- */

@media print {
  @page { margin: 16mm; }
  body, .page-shop { background: #fff !important; color: #000; font-size: 11pt; }
  .skip-link, .site-header, .menu-sheet, .site-footer, .shop-head, .summary,
  .confirm-actions, .confirm-foot, .shop-toast, .toast { display: none !important; }
  .shop { padding: 0; }
  .container { max-width: none; padding: 0; }
  .shop-grid, .shop-grid.is-confirm .shop-main { display: block; max-width: none; }
  .panel { border: 0; box-shadow: none; padding: 0; }
  .panel:not(.panel-confirm) { display: none !important; }
  .invoice-print-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    padding-bottom: 12px;
    margin-bottom: 18px;
    border-bottom: 2px solid var(--jade);
  }
  .invoice-brand { display: inline-flex; align-items: baseline; gap: 8px; font-weight: 800; font-size: 14pt; color: var(--jade); }
  .invoice-brand-mono { font-family: var(--font-serif); font-style: italic; font-weight: 400; color: var(--brass); }
  .invoice-print-contact { color: #444; font-size: 9pt; }
  .status, .invoice-meta, .invoice-meta > div { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .status-dot { animation: none; }
  .invoice-meta { grid-template-columns: repeat(3, 1fr); }
  .invoice-table thead { position: static; width: auto; height: auto; clip: auto; }
  .invoice-table tbody tr, .invoice-table tfoot tr { display: table-row; }
  .invoice-table tbody td { display: table-cell !important; padding: 8px 0 !important; border-bottom: 1px solid #ddd; }
  .invoice-table .num { padding-left: 16px !important; }
  .inv-item-unit { display: none !important; }
  .invoice-block, .invoice-table tr { break-inside: avoid; }
  a { color: inherit; text-decoration: none; }
}
