/* /PN ARTs — kosár és pénztár (oldalsáv) */

.overlay {
  position: fixed; inset: 0; z-index: 90; background: rgba(10, 10, 10, .55);
  opacity: 0; visibility: hidden; transition: opacity .6s var(--ease), visibility 0s .6s;
}
.overlay.show { opacity: 1; visibility: visible; transition: opacity .6s var(--ease), visibility 0s; }

.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 100; width: min(540px, 100%);
  display: flex; flex-direction: column; background: var(--paper); border-left: 1px solid var(--ink);
  transform: translateX(100%); visibility: hidden;
  transition: transform .8s var(--ease), visibility 0s .8s;
}
.drawer.open { transform: none; visibility: visible; transition: transform .8s var(--ease), visibility 0s; }

.drawer-head { display: flex; align-items: center; gap: 14px; padding: 18px 22px; border-bottom: 1px solid var(--ink); }
.drawer-title { font-family: var(--display); font-weight: 600; font-size: 26px; letter-spacing: -.035em; margin: 0; }
.steps { display: flex; margin-left: auto; }
.steps span { padding: 6px 9px; border: 1px solid var(--line); border-left-width: 0; font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); white-space: nowrap; transition: background .4s, color .4s; }
.steps span:first-child { border-left-width: 1px; }
.steps span.active { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.steps span.passed { color: var(--ink); }
.drawer-close { flex: none; width: 40px; height: 40px; border: 1px solid var(--ink); background: none; position: relative; transition: background .4s; }
.drawer-close::before, .drawer-close::after { content: ''; position: absolute; left: 11px; right: 11px; top: 50%; height: 1.5px; background: var(--ink); transition: background .4s, transform .5s var(--ease); }
.drawer-close::before { transform: rotate(45deg); }
.drawer-close::after { transform: rotate(-45deg); }
.drawer-close:hover { background: var(--ink); }
.drawer-close:hover::before, .drawer-close:hover::after { background: var(--paper); }
.drawer-close:hover::before { transform: rotate(135deg); }
.drawer-close:hover::after { transform: rotate(45deg); }

.drawer-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 4px 22px 26px; }
.drawer-foot { border-top: 1px solid var(--ink); padding: 16px 22px 20px; background: var(--paper); }
.drawer-foot:empty { display: none; }
.view-in { animation: viewIn .7s var(--ease) both; }
@keyframes viewIn { from { opacity: 0; transform: translateX(24px); } to { opacity: 1; transform: none; } }

/* Kosár tételek */
.cart-item { display: grid; grid-template-columns: 76px 1fr auto; gap: 16px; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--line); }
.cart-thumb { width: 76px; aspect-ratio: 4 / 5; overflow: hidden; background: var(--paper-2); }
.cart-thumb img, .cart-thumb .ph { width: 100%; height: 100%; object-fit: cover; }
.cart-name { font-family: var(--display); font-weight: 700; font-size: 17px; line-height: 1.15; margin: 0 0 4px; }
.cart-unit { font-size: 12.5px; color: var(--muted); }
.cart-side { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.cart-line { font-family: var(--display); font-weight: 700; white-space: nowrap; }
.qty { display: inline-flex; align-items: stretch; border: 1px solid var(--ink); }
.qty button { width: 30px; height: 30px; border: 0; background: none; font-size: 16px; line-height: 1; transition: background .3s, color .3s; }
.qty button:hover { background: var(--ink); color: var(--paper); }
.qty output { min-width: 28px; display: grid; place-items: center; font-weight: 800; font-size: 13px; }
.link-btn { background: none; border: 0; padding: 0; font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; text-decoration: underline; text-underline-offset: 4px; color: var(--muted); }
.link-btn:hover { color: var(--ink); }

.cart-empty { text-align: center; padding: 64px 10px 30px; }
.cart-empty .slash { display: block; width: 92px; height: 112px; margin: 0 auto 26px; background: linear-gradient(135deg, var(--ink) 0 40%, transparent 40% 54%, var(--ink) 54% 100%); clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); }
.cart-empty p { color: var(--muted); margin: 0 0 26px; }

.ship-progress { margin: 18px 0 4px; font-size: 13px; }
.ship-bar { height: 3px; background: var(--paper-2); margin-top: 8px; overflow: hidden; }
.ship-bar i { display: block; height: 100%; background: var(--ink); transform-origin: left; transition: transform .8s var(--ease); }

/* Összesítő */
.totals { display: grid; gap: 6px; margin-bottom: 14px; font-size: 14px; }
.totals div { display: flex; justify-content: space-between; gap: 12px; }
.totals .grand { padding-top: 10px; margin-top: 4px; border-top: 1px solid var(--ink); font-family: var(--display); font-weight: 600; font-size: 21px; letter-spacing: -.02em; }
.foot-note { font-size: 11.5px; color: var(--muted); text-align: center; margin: 10px 0 0; }

/* Pénztár űrlap */
.co-section { margin-top: 24px; }
.co-legend { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 600; font-size: 18px; letter-spacing: -.02em; margin: 0 0 12px; padding: 0; }
.co-legend .n { font-family: var(--body); font-size: 10.5px; font-weight: 800; letter-spacing: .14em; background: var(--ink); color: var(--paper); padding: 3px 7px; }
fieldset.co-section { border: 0; padding: 0; min-width: 0; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.field label { font-size: 10.5px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.field input, .field textarea {
  width: 100%; font: inherit; font-size: 15px; padding: 12px 14px; border: 1px solid var(--ink); border-radius: 0;
  background: var(--white); color: var(--ink); transition: box-shadow .3s;
}
.field textarea { min-height: 76px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; box-shadow: inset 0 0 0 1px var(--ink), 4px 4px 0 var(--ink); }
.field .err { display: none; font-size: 12px; font-weight: 700; color: var(--error); }
.field.invalid input, .field.invalid textarea { border-color: var(--error); box-shadow: inset 0 0 0 1px var(--error); }
.field.invalid .err { display: block; }
.row-2 { display: grid; grid-template-columns: 1fr 2fr; gap: 12px; }
.row-2b { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.opt {
  display: grid; grid-template-columns: 20px 1fr auto; gap: 12px; align-items: start; padding: 14px 16px;
  border: 1px solid var(--line); margin-bottom: 8px; cursor: pointer; background: var(--white);
  transition: border-color .3s, box-shadow .3s;
}
.opt:hover { border-color: var(--ink); }
.opt.checked { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.opt input { appearance: none; -webkit-appearance: none; width: 18px; height: 18px; margin: 2px 0 0; border: 1px solid var(--ink); border-radius: 50%; display: grid; place-content: center; background: var(--white); }
.opt input::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--ink); transform: scale(0); transition: transform .35s var(--ease); }
.opt input:checked::before { transform: scale(1); }
.opt input:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.opt-title { display: block; font-weight: 800; font-size: 14.5px; }
.opt-desc { display: block; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.opt-price { font-family: var(--display); font-weight: 700; font-size: 14px; white-space: nowrap; }
.opt-tag { display: inline-block; font-family: var(--display); font-weight: 800; font-size: 11px; letter-spacing: .06em; border: 1.5px solid var(--ink); padding: 1px 5px; margin-right: 6px; vertical-align: 1px; }
.co-hint { font-size: 12.5px; color: var(--muted); margin: 4px 0 0; }

.check { display: grid; grid-template-columns: 20px 1fr; gap: 12px; align-items: start; font-size: 13px; margin-top: 20px; cursor: pointer; }
.check input { appearance: none; -webkit-appearance: none; width: 18px; height: 18px; margin: 1px 0 0; border: 1px solid var(--ink); background: var(--white); display: grid; place-content: center; }
.check input::before { content: ''; width: 10px; height: 10px; background: var(--ink); transform: scale(0); transition: transform .3s var(--ease); }
.check input:checked::before { transform: scale(1); }
.check.invalid { color: var(--error); }
.check.invalid input { border-color: var(--error); }

.summary-mini { margin-top: 24px; padding: 14px 16px; background: var(--paper-2); font-size: 13px; }
.summary-mini div { display: flex; justify-content: space-between; gap: 10px; padding: 3px 0; }

/* Kész */
.done { padding: 30px 0 10px; }
.done-mark { width: 84px; height: 84px; background: var(--ink); position: relative; margin-bottom: 26px; animation: wipeUp .9s var(--ease-io) both; }
.done-mark::after { content: ''; position: absolute; left: 26px; top: 20px; width: 20px; height: 36px; border: solid var(--paper); border-width: 0 4px 4px 0; transform: rotate(45deg); }
.done h3 { font-family: var(--display); font-weight: 600; font-size: 30px; letter-spacing: -.035em; line-height: 1.05; margin: 0 0 10px; }
.done .order-no { display: inline-block; font-family: var(--display); font-weight: 700; border: 1px solid var(--ink); padding: 6px 10px; margin: 6px 0 18px; letter-spacing: .06em; }
.done p { color: var(--muted); margin: 0 0 14px; font-size: 14.5px; }
.done .steps-list { list-style: none; padding: 0; margin: 18px 0 22px; border-top: 1px solid var(--ink); }
.done .steps-list li { display: grid; grid-template-columns: 34px 1fr; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.done .steps-list b { font-family: var(--display); }
.done .actions { display: grid; gap: 10px; }

@media (max-width: 480px) {
  .drawer-head { flex-wrap: wrap; padding: 14px 16px; }
  .steps { order: 3; width: 100%; margin: 4px 0 0; }
  .steps span { flex: 1; text-align: center; }
  .drawer-close { margin-left: auto; }
  .drawer-body { padding: 4px 16px 22px; }
  .drawer-foot { padding: 14px 16px 16px; }
  .row-2 { grid-template-columns: 1fr 1.6fr; }
}
