/* Delivery demo: the address steps, the delivery row, checkout and order page (phone engine, .pat-dv-*)
   and the same screens on a computer or iPad (site, .ct-dv-*). Colours come from the venue theme. */

/* ---------- phone: address and address details ---------- */
.pat-dv-page { display: flex; flex-direction: column; gap: 12px; padding: 8px 16px 32px; }
.pat-dv-title { font-size: 28px; line-height: 1.1; margin: 8px 0 0; }
.pat-dv-lead { margin: 0 0 8px; font-size: 17px; line-height: 1.35; }
.pat-dv-search { display: flex; align-items: center; gap: 12px; height: 64px; padding: 0 16px; border: 1px solid var(--c-stroke); border-radius: 14px; background: var(--brand-bg, #fff); }
.pat-dv-search:focus-within { outline: 2px solid var(--brand-ink, #000); outline-offset: -1px; }
.pat-dv-search > svg { flex: none; }
.pat-dv-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; padding: 0; font: inherit; font-size: 17px; color: inherit; }
.pat-dv-locate { display: grid; place-items: center; flex: none; width: 36px; height: 36px; padding: 0; border: 0; background: none; color: inherit !important; }
.pat-dv-sub { margin: 12px 0 0; font-size: 16px; font-weight: 400; color: var(--c-secondary); }
.pat .pat-dv-sub { font-family: inherit; letter-spacing: 0; }
.pat-dv-list { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; }
.pat-dv-list button { display: flex; align-items: center; gap: 14px; width: 100%; padding: 13px 0; border: 0; background: none; text-align: left; font: inherit; color: inherit !important; }
.pat-dv-list button > span { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.pat-dv-list strong { font-size: 17px; font-weight: 500; }
.pat-dv-list small { font-size: 14px; color: var(--c-secondary); }
.pat-dv-list svg { flex: none; }
.pat-dv-list button > svg:last-child { opacity: 0.55; }

/* A map frame: the drawing is zoomed and placed from --px / --py / --zoom so the pin (50% across, 46% down) marks that point. */
.pat-dv-map, .ct-dv-map { position: relative; height: 150px; border-radius: 14px; overflow: hidden; background: #f2efe9; container-type: size; user-select: none; -webkit-user-select: none; }
.pat-dv-map > img, .ct-dv-map > img { position: absolute; display: block; max-width: none; height: auto; width: calc(var(--zoom, 1.6) * 100cqw); left: clamp(calc(100cqw - var(--zoom, 1.6) * 100cqw), calc(50cqw - var(--px, 50) / 100 * var(--zoom, 1.6) * 100cqw), 0px); top: clamp(calc(100cqh - var(--zoom, 1.6) * 100cqw * 0.6293), calc(46cqh - var(--py, 50) / 100 * var(--zoom, 1.6) * 100cqw * 0.6293), 0px); pointer-events: none; }
[data-pan] { cursor: grab; touch-action: none; }
[data-pan].is-panning { cursor: grabbing; }
.pat-dv-pin { position: absolute; left: 50%; top: 46%; transform: translate(-50%, -100%); color: var(--brand-primary, #000); filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.3)); }
.pat-dv-pin svg { width: 30px; height: 36px; fill: currentColor; }
.pat-dv-adjust { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); height: 32px; padding: 0 16px; border: 0; border-radius: 999px; background: var(--brand-bg, #fff); color: var(--brand-ink, #000) !important; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.14); font: inherit; font-size: 13px; font-weight: 600; letter-spacing: 0.03em; text-transform: uppercase; }
.pat-dv-static { display: flex; flex-direction: column; justify-content: center; gap: 2px; min-height: 64px; padding: 0 16px; border: 1px solid var(--c-stroke); border-radius: 12px; font-size: 16px; color: var(--c-secondary); }
.pat-dv-static small { font-size: 12px; }
.pat .pat-dv-page .pat-dv-rule { align-self: stretch; width: auto; height: 8px; margin: 22px -16px 4px; border: 0; background: var(--brand-soft, rgba(0, 0, 0, 0.06)); }

/* ---------- phone: the address selector on the landing (Figma "Couch ordering") ---------- */
.pat-dv-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 16px 20px; }
.pat-dv-addr { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; padding: 0; border: 0; background: none; text-align: left; font: inherit; color: inherit !important; }
.pat-dv-addr strong { display: flex; align-items: center; gap: 6px; max-width: 100%; font-size: 17px; font-weight: 600; }
.pat-dv-addr strong span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pat-dv-addr strong svg { flex: none; width: 18px; height: 18px; }
.pat-dv-addr small { font-size: 14px; color: var(--c-secondary); }
.pat-dv-asap { flex: none; height: 36px; padding: 0 18px; border: 0; border-radius: 999px; background: var(--brand-soft, #f2f2f2); font: inherit; font-size: 14px; font-weight: 500; color: inherit !important; }

/* ---------- phone: checkout ---------- */
.pat-dv-block .pat-dv-map { margin-bottom: 4px; }
.pat-dv-line { display: flex; align-items: center; gap: 14px; width: 100%; padding: 8px 0; border: 0; background: none; text-align: left; font: inherit; color: inherit !important; }
.pat-dv-line svg { flex: none; }
.pat-dv-line span { display: flex; flex-direction: column; gap: 2px; }
.pat-dv-line strong { font-size: 17px; font-weight: 500; }
.pat-dv-line small { font-size: 15px; color: var(--c-secondary); }
.pat-dv-time { display: flex; align-items: center; gap: 12px; }
.pat-dv-time svg { flex: none; }
.pat-dv-time > span { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.pat-dv-time strong { font-size: 17px; font-weight: 500; }
.pat-dv-time small { font-size: 15px; color: var(--c-secondary); }
.pat-dv-phone { min-height: 64px; }
.pat-dv-phone span { font-size: 17px; }
.pat-dv-drop { display: flex; flex-direction: column; gap: 16px; }

/* ---------- site (computer, iPad): address modals ---------- */
.ct-dv-search { display: flex; align-items: center; gap: 12px; height: 64px; padding: 0 16px; border: 1px solid var(--brand-line, rgba(0, 0, 0, 0.14)); border-radius: 14px; background: var(--brand-bg, #fff); }
.ct-dv-search:focus-within { outline: 2px solid var(--brand-ink, #000); outline-offset: -1px; }
.ct-dv-search svg { flex: none; }
.ct-dv-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; padding: 0; font: inherit; font-size: 17px; color: inherit; }
.ct-dv-locate { display: grid; place-items: center; flex: none; width: 36px; height: 36px; padding: 0; border: 0; background: none; color: inherit; cursor: pointer; }
.ct-dv-sub { margin: 18px 0 4px; font-size: 16px; font-weight: 400; color: color-mix(in srgb, var(--brand-ink, #000) 64%, transparent); }
.ct-dv-list { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; }
.ct-dv-list button { display: flex; align-items: center; gap: 14px; width: 100%; padding: 12px 0; border: 0; background: none; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.ct-dv-list button > span { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.ct-dv-list strong { font-size: 17px; font-weight: 500; }
.ct-dv-list small { font-size: 14px; color: color-mix(in srgb, var(--brand-ink, #000) 64%, transparent); }
.ct-dv-list button[aria-pressed="true"] strong { text-decoration: underline; text-underline-offset: 3px; }
.ct-dv-list svg { flex: none; }
.ct-dv-list button > svg:last-child { opacity: 0.55; }

.ct-dv-pin { position: absolute; left: 50%; top: 46%; transform: translate(-50%, -100%); color: var(--brand-primary, #000); filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.3)); }
.ct-dv-pin svg { width: 30px; height: 36px; fill: currentColor; }
.ct-dv-adjust { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); height: 32px; padding: 0 16px; border: 0; border-radius: 999px; background: var(--brand-bg, #fff); color: var(--brand-ink, #000); box-shadow: 0 2px 10px rgba(0, 0, 0, 0.14); font: inherit; font-size: 13px; font-weight: 600; letter-spacing: 0.03em; text-transform: uppercase; cursor: pointer; }
.ct-dv-static { display: flex; align-items: center; min-height: 64px; padding: 0 16px; border: 1px solid var(--brand-line, rgba(0, 0, 0, 0.14)); border-radius: 12px; font-size: 16px; color: color-mix(in srgb, var(--brand-ink, #000) 64%, transparent); }

/* ---------- site: checkout and order page ---------- */
.ct-dv-lines { display: flex; flex-direction: column; margin-top: 4px; }
.ct-dv-line { display: flex; align-items: center; gap: 14px; width: 100%; padding: 12px 0; border: 0; border-top: 1px solid var(--brand-line, rgba(0, 0, 0, 0.1)); background: none; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.ct-dv-line:first-child { border-top: 0; }
.ct-dv-line > span { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.ct-dv-line strong { font-size: 17px; font-weight: 500; }
.ct-dv-line small { font-size: 15px; color: color-mix(in srgb, var(--brand-ink, #000) 64%, transparent); }
.ct-dv-line svg { flex: none; }
.ct-dv-line > svg:last-child { opacity: 0.55; }
.ct-dv-map--co { margin: 4px 0 12px; height: 168px; }
.ct-dv-drop { display: flex; flex-direction: column; gap: 16px; }

/* The map pin takes the venue's colour (brand scope only; the plain demo keeps black) */
.pat[data-brand] .pat-dv-pin svg path, .pat[data-brand] .pat-cc-pin svg path { fill: var(--brand-primary); }
.pat[data-brand] .pat-dv-pin svg circle, .pat[data-brand] .pat-cc-pin svg circle { fill: var(--brand-bg); }

/* Delivery site: the social icons keep their own size (the venue dialog sizes every image as the round logo),
   and the day carousel in the time dialog runs to the edges of the dialog. */
.ct--delivery .ct-socials img { width: 20px; height: 20px; border-radius: 0; }
.ct--delivery .ct-days, .ct-modal .ct-days { margin: 0 -20px; padding: 2px 20px 10px; scroll-padding: 0 20px; }

/* Delivery site: the payment box (Figma "Credit card"): one bordered box, the card logos at the top right,
   the card number on a full row, then expiry and CVC side by side. */
.ct-dv-pay { display: flex; flex-direction: column; gap: 12px; margin-bottom: 12px; }
.ct-dv-method { display: flex; flex-direction: column; gap: 12px; padding: 16px; border: 1px solid var(--brand-line, rgba(0, 0, 0, 0.14)); border-radius: 16px; background: var(--brand-bg, #fff); }
.ct-dv-method.is-on { border-color: var(--brand-ink, #000); }
.ct-dv-mhead { display: flex; align-items: center; gap: 12px; min-height: 28px; font-size: 16px; font-weight: 600; cursor: pointer; }
.ct-dv-mhead .ct-dot { flex: none; }
.ct-dv-brands { display: flex; align-items: center; gap: 8px; }
.ct-dv-brand { display: grid; place-items: center; min-width: 38px; height: 24px; padding: 0 6px; border-radius: 5px; background: var(--brand-soft, #f2f2f2); font-size: 6.5px; font-weight: 800; line-height: 1.05; text-align: center; letter-spacing: 0.01em; color: #1f3a8a; }
.ct-dv-brand--visa { font-size: 11px; font-style: italic; letter-spacing: -0.02em; }
.ct-dv-brand--amex { background: #e8f0fb; color: #1f72cd; }
.ct-dv-brand--discover { color: #231f20; font-size: 6px; }
.ct-dv-fields { display: flex; flex-direction: column; gap: 8px; }
.ct-dv-fields .ct-field { margin: 0; }
.ct-dv-fields .ct-field input { height: 64px; padding: 0 16px; border-radius: 12px; font-size: 16px; background: var(--brand-bg, #fff); border-color: var(--brand-line, rgba(0, 0, 0, 0.14)); }
.ct-dv-fields .ct-row2 { gap: 8px; }

/* Delivery site: the checkout and order cards start below the top buttons instead of touching them. */
.ct--delivery:is([data-view="checkout"], [data-view="confirm"]) .ct-hero { height: 174px; }
.ct--delivery .ct-conf { margin-top: -84px; }

/* Delivery site: the phone number comes from the guest's account, shown but not editable. */
.ct--delivery .ct-field input:disabled { background: var(--brand-soft, #f2f2f2); color: color-mix(in srgb, var(--brand-ink, #000) 64%, transparent); -webkit-text-fill-color: currentColor; cursor: not-allowed; opacity: 1; }

/* ---------- phone: the address steps in a modal over the landing page ---------- */
.pat-dv-drawer { background: var(--brand-bg, #fff); }
.pat-dv-drawer .pat-dv-page { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; }
.pat-dv-drawer .pat-dv-page::-webkit-scrollbar { display: none; }
.pat-dv-cta { flex: none; padding: 12px 16px 16px; }

/* The "Adjust the pin" step: a bigger map to drag. */
.pat-dv-map--big { height: 360px; }
.ct-dv-map--big { height: 320px; }

/* Catering on a phone follows the Delivery demo: a full address page, the address and time row, the flag button
   with its language dialog, and the same menu. Computers and iPads keep the Catering site. */
.ct-flagbtn { display: none; }
.ct-flagbtn img { width: 20px; height: 14px; border-radius: 3px; }
.ct-pg-title { margin: 8px 0 0; font-size: 28px; line-height: 1.1; }
.ct-pg-lead { margin: 0 0 8px; font-size: 17px; line-height: 1.35; color: var(--muted); }
.ct-venue .ct-socials img { width: 20px; height: 20px; border-radius: 0; }
.ct-pg .ct-seg { margin: 4px 0 6px; }
.ct-pg .ct-warn { margin-top: 14px; }
.ct-dv-list .ct-zone { color: #b3402a; }
.ct-dv-list button[aria-pressed="true"] strong { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 640px) {
  .ct-hero .ct-flag { display: none; }
  .ct-flagbtn { display: grid; }
  .ct-modal--page { top: 0; bottom: 0; height: 100%; height: 100dvh; max-height: none; border-radius: 0; padding-bottom: 0; }
  .ct-modal--page .ct-mhead { min-height: 56px; padding-top: 10px; }
  .ct-modal--page .ct-mfoot { border-top: 0; box-shadow: none; padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
  .ct-modal--page .ct-mbody { padding: 8px 16px 24px; gap: 12px; }
  .ct-pg .ct-dv-search { margin-top: 4px; }
  /* The address (opens the address page) with its type under it, and the time on the right: as in Delivery. */
  .ct-pickrow { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 22px; padding: 0 0 0; border-radius: 0; background: none; overflow: visible; text-align: left; }
  .ct-dvrow-addr { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; padding: 0; border: 0; background: none; text-align: left; font: inherit; color: inherit; }
  .ct-dvrow-addr strong { display: flex; align-items: center; gap: 6px; max-width: 100%; font-size: 17px; font-weight: 600; }
  .ct-dvrow-addr strong span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .ct-dvrow-addr strong svg { flex: none; }
  .ct-dvrow-addr small { font-size: 14px; color: var(--muted); }
  .ct-dvrow-time { flex: none; max-width: 46%; height: 36px; padding: 0 16px; border: 0; border-radius: 999px; background: var(--brand-soft, #f2f2f2); font: inherit; font-size: 14px; font-weight: 500; color: inherit; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}
