/* =================================================================
   Own shop (shop.html, bestellt.html): same world, the cart is the Bon
   ================================================================= */
.shop-head { background: var(--ruby); color: var(--paper); padding-block: clamp(1.6rem, 1rem + 2.4vw, 3rem); }
.shop-head-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-4); }
.shop-head h1 { font-size: var(--t-h1); }
.steps { display: flex; gap: var(--s-2); list-style: none; margin: 0; padding: 0; font-weight: 700; font-stretch: 88%; font-size: 0.95rem; }
.steps li { display: inline-flex; align-items: center; gap: 0.45em; padding: 0.35em 0.9em 0.35em 0.4em; border-radius: var(--r-pill); background: rgb(34 16 12 / 0.25); color: rgb(255 245 230 / 0.8); }
.steps b { display: grid; place-items: center; width: 1.7em; height: 1.7em; border-radius: 50%; background: rgb(255 245 230 / 0.2); font-variant-numeric: tabular-nums; }
.steps[data-step="1"] li:nth-child(1), .steps[data-step="2"] li:nth-child(-n+2), .steps[data-step="3"] li { background: var(--paper); color: var(--ink); }
.steps[data-step="1"] li:nth-child(1) b, .steps[data-step="2"] li:nth-child(-n+2) b, .steps[data-step="3"] li b { background: var(--crust); }

.shop-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 400px); gap: clamp(1.5rem, 1rem + 3vw, 4rem); align-items: start; padding-bottom: var(--s-8); }
.shop-main { min-width: 0; }

.mode { margin-top: var(--s-6); background: var(--bon); border: 3px solid var(--ink); border-radius: var(--r-l); padding: clamp(1.1rem, 0.8rem + 1.4vw, 1.8rem); box-shadow: 0 8px 0 var(--ink); }
.mode h2 { font-size: var(--t-h3); margin-bottom: var(--s-4); }
.mode.nudge { animation: nudge 0.5s var(--ease-out); }
@keyframes nudge { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-3); }
.seg button {
  display: flex; align-items: center; justify-content: center; gap: 0.6rem; min-height: 72px;
  border: 3px solid var(--ink); border-radius: var(--r-m); background: var(--paper); cursor: pointer;
  font-family: var(--f-display); font-size: clamp(1.15rem, 1rem + 0.8vw, 1.6rem);
  transition: background-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.seg button svg { width: 52px; height: 52px; transition: transform var(--dur-base) var(--ease-out); }
.seg button:hover { transform: translateY(-2px); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.seg button[aria-pressed="true"] svg { transform: rotate(-10deg) scale(1.08); }
.zones { margin-top: var(--s-5); }
.zones .field-label { display: block; }
.plz-row { position: relative; max-width: 260px; }
.plz-input {
  width: 100%; min-height: 64px; padding: 0 3.6rem 0 1.1rem;
  border: 3px solid var(--ink); border-radius: var(--r-m); background: var(--paper); color: var(--ink);
  font-family: var(--f-display); font-size: 1.9rem; letter-spacing: 0.12em; font-variant-numeric: tabular-nums;
  transition: border-color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
}
.plz-input::placeholder { color: rgb(34 16 12 / 0.25); }
.plz-input:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.plz-check { position: absolute; right: 0.7rem; top: 50%; translate: 0 -50%; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; color: var(--paper); }
.plz-check:empty { display: none; }
.plz-check svg { width: 24px; height: 24px; }
.zones[data-state="ok"] .plz-input { border-color: var(--ok); background: #f1f8ec; }
.zones[data-state="ok"] .plz-check { background: var(--ok); animation: pop var(--dur-base) var(--ease-out); }
.zones[data-state="no"] .plz-input { border-color: var(--ruby); }
.zones[data-state="no"] .plz-check { background: var(--ruby); animation: pop var(--dur-base) var(--ease-out); }
@keyframes pop { from { transform: scale(0.4); } }
.plz-result { margin-top: var(--s-3); }
.plz-result p { margin: 0; }
.plz-hint { color: var(--ink-soft); font-size: var(--t-small); }
.plz-ok b { color: var(--ok); }
.plz-no b { color: var(--ruby); }
.plz-result .btn { margin-top: var(--s-3); }
.mode-hint { margin-top: var(--s-4); font-weight: 600; color: var(--ink-soft); }
.mode-hint:empty { display: none; }

.again { margin-top: var(--s-5); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-3); padding: 0.8rem 1rem; border: 2.5px dashed var(--ink); border-radius: var(--r-m); font-weight: 700; }
.again[hidden] { display: none; }
.shop .menu-tools { margin-top: var(--s-5); border-block: 2px solid var(--ink); }
.skeleton { display: grid; gap: var(--s-3); margin-top: var(--s-6); }
.skeleton span { height: 64px; border-radius: var(--r-m); background: linear-gradient(90deg, var(--paper-2), var(--bon), var(--paper-2)); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
.shop.is-ready .skeleton { display: none; }
@keyframes shimmer { to { background-position: -200% 0; } }
.load-error { margin-top: var(--s-6); padding: var(--s-4); border: 2.5px solid var(--ruby); border-radius: var(--r-m); font-weight: 700; }

.sitems { list-style: none; margin: 0; padding: 0; }
.sitem { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: var(--s-4); padding: 0.75rem 0.2rem; border-bottom: 2px dashed var(--line); }
.sitem h3 { font-family: var(--f-text); font-weight: 750; font-stretch: 92%; font-size: 1.1rem; line-height: 1.3; letter-spacing: 0; }
.sitem small { display: block; color: var(--ink-soft); font-size: 0.85rem; font-weight: 500; }
.sitem .price { font-weight: 800; font-size: 1.12rem; font-variant-numeric: tabular-nums; }
.sitems--sauce { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--s-6); }
.qty { display: flex; align-items: center; gap: 0.35rem; min-width: 128px; justify-content: flex-end; }
.qty .add, .qty .step {
  display: grid; place-items: center; border: 0; cursor: pointer; border-radius: 50%;
  transition: transform var(--dur-fast) var(--ease-out), background-color var(--dur-fast);
}
.qty .add { width: 48px; height: 48px; background: var(--crust); color: var(--ink); border: 2.5px solid var(--ink); box-shadow: 0 3px 0 var(--ink); }
.qty .add:hover { background: var(--crust-hover); transform: translateY(-1px) rotate(90deg); }
.qty .add:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--ink); }
.qty .step { width: 44px; height: 44px; background: var(--ink); color: var(--paper); }
.qty .step:hover { background: var(--ruby); }
.qty .step:active { transform: scale(0.9); }
.qty svg { width: 20px; height: 20px; }
.qty output { min-width: 2ch; text-align: center; font-weight: 800; font-size: 1.15rem; font-variant-numeric: tabular-nums; }

/* the Bon as cart */
.sheet { position: sticky; top: calc(var(--header-h) + 1.2rem); margin-top: var(--s-6); }
.sheet-inner { max-height: calc(100dvh - var(--header-h) - 2.4rem); overflow: auto; overscroll-behavior: contain; padding-bottom: 6px; scrollbar-width: thin; }
.sheet-close { display: none; }
.shop-bon { margin: -6px 4% 0; }
.shop-bon .bon-lines { min-height: 0; }
.shop-bon .bon-lines li { grid-template-columns: 2.6ch minmax(0, 1fr) auto; align-items: center; }
.shop-bon .bon-lines li .n { overflow-wrap: anywhere; }
.bon-step { grid-column: 2 / -1; display: flex; gap: 0.4rem; margin-top: 0.15rem; }
.bon-step button { width: 44px; height: 36px; border-radius: var(--r-pill); border: 2px solid var(--ink); background: var(--bon); color: var(--ink); display: grid; place-items: center; cursor: pointer; }
.bon-step button:hover { background: var(--paper-2); }
.bon-step svg { width: 16px; height: 16px; }
.shop-bon .bon-lines li.bon-empty { display: flex; align-items: center; gap: var(--s-3); color: var(--ink-soft); font-weight: 600; }
.bon-empty svg { width: 56px; flex: none; }
.bon-fulfil { margin-top: var(--s-3); font-size: 0.9rem; font-weight: 700; color: var(--ink-soft); }
.min-gap { margin-top: var(--s-2); padding: 0.5rem 0.75rem; border-radius: var(--r-s); background: var(--paper-2); font-weight: 700; font-size: 0.92rem; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: var(--shadow-btn); }
.btn[data-loading="true"] { opacity: 0.8; cursor: progress; }

.checkout { display: grid; gap: var(--s-4); padding-top: var(--s-4); }
.back { justify-self: start; display: inline-flex; align-items: center; gap: 0.4rem; min-height: 44px; padding: 0 0.6rem 0 0.2rem; border: 0; background: none; color: var(--ink); cursor: pointer; font-weight: 800; font-stretch: 88%; }
.back svg { width: 20px; height: 20px; }
.pay-sum { display: flex; justify-content: space-between; align-items: baseline; gap: var(--s-3); padding-bottom: var(--s-3); border-bottom: 2px dashed var(--line); font-weight: 700; color: var(--ink-soft); }
.pay-sum b { font-family: var(--f-display); font-weight: 400; font-size: 1.6rem; color: var(--ink); white-space: nowrap; }
.f { display: grid; gap: 0.35rem; }
.f > span { font-weight: 800; font-stretch: 88%; }
.f small { font-weight: 500; color: var(--ink-soft); }
.f input, .f textarea {
  width: 100%; min-height: 50px; padding: 0.7rem 0.9rem; border: 2.5px solid var(--ink); border-radius: var(--r-s);
  background: var(--paper); color: var(--ink); font-size: 1.05rem; resize: vertical;
}
.f input::placeholder, .f textarea::placeholder { color: #7a655a; }
.f input:focus-visible, .f textarea:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; }
.f input:user-invalid { border-color: var(--ruby); background: #fff0ee; }
.pay { border: 0; padding: 0; margin: 0; display: grid; gap: var(--s-2); min-width: 0; }
.pay legend { padding: 0; margin-bottom: var(--s-2); }
.pay label { display: flex; align-items: center; gap: 0.7rem; min-height: 52px; padding: 0 1rem; border: 2.5px solid var(--ink); border-radius: var(--r-s); cursor: pointer; font-weight: 700; }
.pay label:has(input:checked) { background: var(--ink); color: var(--paper); }
.pay label.is-off { opacity: 0.55; cursor: not-allowed; border-style: dashed; }
.pay input { width: 20px; height: 20px; accent-color: var(--crust); }
.pay small { font-weight: 600; margin-left: auto; padding: 0.1rem 0.5rem; border-radius: var(--r-pill); background: var(--paper-2); color: var(--ink); }
.remember { display: flex; align-items: center; gap: 0.6rem; min-height: 44px; font-weight: 600; cursor: pointer; }
.remember input { width: 22px; height: 22px; }
.shop-closed { margin: 0 0 var(--s-3, 1rem); padding: 0.85rem 1rem; border-radius: var(--r-s); background: #fff0ee; border: 2.5px solid var(--ruby); font-weight: 800; }
.form-error { padding: 0.75rem 1rem; border-radius: var(--r-s); background: #fff0ee; border: 2.5px solid var(--ruby); font-weight: 700; }
.checkout .btn { width: 100%; }

.cart-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: var(--z-bar); padding: 0.6rem var(--gutter) calc(0.6rem + env(safe-area-inset-bottom)); background: var(--ink); box-shadow: inset 0 3px 0 var(--crust); display: none; }
.cart-bar button { width: 100%; min-height: 56px; display: flex; align-items: center; gap: var(--s-3); padding: 0 1.1rem; border: 3px solid var(--crust); border-radius: var(--r-pill); background: var(--crust); color: var(--ink); cursor: pointer; font-weight: 800; font-stretch: 88%; font-size: 1.05rem; }
.cart-bar-n { padding: 0.2rem 0.6rem; border-radius: var(--r-pill); background: var(--ink); color: var(--paper); font-size: 0.85rem; }
.cart-bar b { margin-left: auto; font-variant-numeric: tabular-nums; }

/* confirmation */
.confirm-wrap { max-width: 560px; padding-block: var(--s-7) var(--s-8); }
.print-wrap { position: relative; }
.printer { position: relative; z-index: 2; }
.printer-top {
  display: flex; align-items: center; gap: 0.7rem; height: 58px; padding: 0 1.2rem;
  background: var(--ink-soft); color: var(--paper); border: 3px solid var(--ink); border-bottom: 0; border-radius: var(--r-m) var(--r-m) 0 0;
}
.printer-top b { font-family: var(--f-display); font-size: 0.95rem; letter-spacing: 0.04em; }
.printer-led { width: 12px; height: 12px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px rgb(47 125 50 / 0.3); }
.is-printing .printer-led { background: var(--crust); box-shadow: 0 0 0 3px rgb(244 165 28 / 0.35); animation: blink 0.3s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0.25; } }
.printer-grille { margin-left: auto; width: 64px; height: 14px; background: repeating-linear-gradient(90deg, var(--ink) 0 4px, transparent 4px 9px); opacity: 0.7; }
.printer-front { height: 34px; background: var(--ink); border-radius: 0 0 var(--r-s) var(--r-s); padding: 13px 1rem 0; box-shadow: 0 10px 0 -4px rgb(34 16 12 / 0.25); }
.printer-slot { display: block; height: 8px; border-radius: 4px; background: #000; box-shadow: inset 0 2px 0 rgb(255 255 255 / 0.12); }
.printer-feed { position: relative; margin: -16px 1.4rem 0; padding: 0 12px 40px; overflow: hidden; }
.confirm-bon { margin: 0; position: relative; padding-top: 2.2rem; transform-origin: 50% 0; }
.shop-bon .bon-head span span, .confirm-bon .bon-head span span { display: inline; margin: 0; letter-spacing: inherit; }
.confirm-bon .bon-head { padding-right: 3.5rem; padding-left: 3.5rem; }
.confirm-bon h1 { font-size: var(--t-h2); text-align: center; margin: var(--s-5) 0 var(--s-3); }
.confirm-stamp { position: absolute; right: -0.6rem; top: 7rem; width: 120px; rotate: 12deg; z-index: 3; }
.confirm-stamp span { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--f-display); font-size: 1rem; }
.confirm-how { margin-top: var(--s-3); font-weight: 700; }
.track-cta { display: flex; justify-content: center; margin-top: var(--s-2); }
.track-cta .btn { width: min(100%, 420px); justify-content: center; }
.next { list-style: none; padding: 0; margin: var(--s-6) 0; display: grid; gap: var(--s-3); }
.next li { padding: 0.9rem 1.1rem; border: 2.5px solid var(--ink); border-radius: var(--r-m); background: var(--bon); }
.next b { color: var(--ruby); }

@media (max-width: 899px) {
  .shop-grid { grid-template-columns: minmax(0, 1fr); }
  .cart-bar:not([hidden]) { display: block; }
  .shop ~ .site-footer { padding-bottom: calc(6rem + env(safe-area-inset-bottom)); }
  .sheet {
    position: fixed; inset: auto 0 0 0; margin: 0; z-index: calc(var(--z-bar) + 1);
    transform: translateY(105%); transition: transform var(--dur-base) var(--ease-out), visibility 0s linear var(--dur-base);
    background: var(--paper); border: 3px solid var(--ink); border-bottom: 0; border-radius: var(--r-l) var(--r-l) 0 0;
    box-shadow: 0 -20px 50px -10px rgb(34 16 12 / 0.45); visibility: hidden;
  }
  .sheet.is-open { transform: none; visibility: visible; transition: transform var(--dur-base) var(--ease-out); }
  .sheet-inner { max-height: 88dvh; padding: 3.4rem 0 calc(1rem + env(safe-area-inset-bottom)); }
  .sheet-close { display: grid; place-items: center; position: absolute; right: 0.8rem; top: 0.7rem; width: 44px; height: 44px; border-radius: 50%; border: 2.5px solid var(--ink); background: var(--bon); color: var(--ink); cursor: pointer; z-index: 3; }
  .sheet-close svg { width: 20px; height: 20px; }
  body.sheet-open { overflow: hidden; }
  body.sheet-open::after { content: ""; position: fixed; inset: 0; background: rgb(34 16 12 / 0.45); z-index: var(--z-bar); }
  .sitems--sauce { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .steps { width: 100%; }
  .steps li { flex: 1; justify-content: center; padding: 0.35em 0.3em; font-size: 0.82rem; }
  .seg button { min-height: 64px; }
  .seg button svg { width: 40px; height: 40px; }
  .confirm-stamp { right: -0.2rem; width: 100px; }
  .confirm-stamp span { font-size: 0.78rem; }
  .printer-feed { margin-inline: 0.8rem; padding-inline: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  .sheet, .sheet.is-open { transition: none; }
  .skeleton span { animation: none; }
  .mode.nudge { animation: none; outline: 3px solid var(--ruby); }
  .qty .add:hover { transform: none; }
  .is-printing .printer-led, .plz-check { animation: none !important; }
}

/* Judge 19.11: shop photos, options popup (Menü drink, burger sauces), age check */
.sitem.has-img { grid-template-columns: 64px minmax(0, 1fr) auto auto; }
.sitem-img { width: 64px; height: 64px; border-radius: var(--r-s); object-fit: cover; background: var(--paper-2); outline: 1px solid rgb(0 0 0 / 0.08); outline-offset: -1px; }
.shop-bon .bon-lines li .n small { display: block; font-size: 0.82rem; font-weight: 500; color: var(--ink-soft); }
.bon-opt { display: inline-block; margin-top: 0.15rem; padding: 0.15rem 0; border: 0; background: none; color: var(--ink); font: inherit; font-size: 0.85rem; font-weight: 800; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; min-height: 32px; }
.bon-opt.is-missing { color: var(--ruby); }
.opt-dialog { box-sizing: border-box; width: min(32rem, calc(100vw - 1.5rem)); max-width: calc(100vw - 1.5rem); overflow-x: hidden; max-height: min(85vh, 46rem); padding: 0; border: 3px solid var(--ink); border-radius: var(--r-m); background: var(--paper); color: var(--ink); box-shadow: 0 10px 0 -4px rgb(34 16 12 / 0.25); }
.opt-dialog::backdrop { background: rgb(34 16 12 / 0.55); }
.opt-form { display: grid; gap: var(--s-4); padding: 1.1rem 1.1rem 0; }
.opt-form h2 { font-family: var(--f-display); font-weight: 400; font-size: 1.35rem; line-height: 1.2; }
.opt-form fieldset { border: 0; margin: 0; padding: 0; display: grid; gap: 0.35rem; min-width: 0; }
.opt-form legend { padding: 0; margin-bottom: 0.4rem; font-weight: 800; font-stretch: 88%; }
.opt-form legend small { font-weight: 600; color: var(--ink-soft); }
.opt { display: flex; align-items: center; gap: 0.7rem; min-height: 44px; padding: 0 0.8rem; border: 2px solid var(--line); border-radius: var(--r-s); cursor: pointer; font-weight: 650; }
.opt:has(input:checked) { border-color: var(--ink); background: var(--paper-2); }
.opt:has(input:disabled) { opacity: 0.45; cursor: not-allowed; }
.opt input { width: 20px; height: 20px; accent-color: var(--ink); flex: none; }
.opt b { margin-left: auto; font-variant-numeric: tabular-nums; }
.opt-actions { position: sticky; bottom: 0; display: grid; grid-template-columns: auto 1fr; gap: var(--s-2); padding: 0.8rem 0 1rem; background: var(--paper); border-top: 2px dashed var(--line); }
.age-check { padding: 0.6rem 0.8rem; border: 2.5px solid var(--ink); border-radius: var(--r-s); }
.f textarea { font-family: inherit; }
@media (max-width: 420px) { .sitem.has-img { grid-template-columns: 52px minmax(0, 1fr) auto; } .sitem.has-img .qty { grid-column: 2 / -1; justify-self: end; } .sitem-img { width: 52px; height: 52px; } }
.bon-optline { display: block; font-size: 0.85rem; font-weight: 500; opacity: 0.8; }
.opt-form, .opt-form > *, .opt, .opt span { min-width: 0; }
.opt span { overflow-wrap: anywhere; }
.opt-form h2 { overflow-wrap: anywhere; }
.opt-actions .btn { min-width: 0; padding-inline: 0.9rem; white-space: normal; }
@media (max-width: 420px) { .opt-form { padding: 0.9rem 0.8rem 0; } .opt-actions { grid-template-columns: 1fr; } .opt-actions [data-opt-cancel] { order: 2; } }
@media (max-width: 400px) {
  .seg button { flex-direction: column; gap: 0.2rem; min-height: 88px; padding: 0.4rem; font-size: 0.98rem; min-width: 0; }
  .seg button svg { width: 40px; height: 40px; }
  .seg button span { min-width: 0; overflow-wrap: anywhere; }
}
.opt-more { border-top: 2px dashed var(--line); padding-top: var(--s-3); }
.opt-more > summary { cursor: pointer; font-weight: 800; font-stretch: 88%; min-height: 44px; display: flex; align-items: center; list-style: none; }
.opt-more > summary::-webkit-details-marker { display: none; }
.opt-more > summary::before { content: "+"; display: inline-grid; place-items: center; width: 26px; height: 26px; margin-right: 0.5rem; border: 2px solid var(--ink); border-radius: 4px; font-weight: 900; }
.opt-more[open] > summary::before { content: "−"; }
/* Judge 20.11: real food in the first phone screen of the shop */
.shop-teaser { display: flex; gap: var(--s-3); flex-wrap: wrap; }
.shop-teaser a { display: grid; justify-items: center; gap: 0.25rem; color: var(--paper); text-decoration: none; font-weight: 800; font-size: 0.85rem; }
.shop-teaser img { width: 72px; height: 72px; border-radius: var(--r-s); object-fit: cover; border: 2px solid var(--paper); }
.shop-teaser a:hover img { transform: translateY(-2px); }
@media (max-width: 420px) { .shop-teaser img { width: 60px; height: 60px; } .shop-teaser { gap: var(--s-2); } }
