/* Zentara Café: cart, checkout drawer and order status page. Tokens come from site.css. */
.zc-sr { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
[hidden] { display: none !important; }

/* ───────── Header cart button ───────── */
.top { position: relative; }
.zc-head-btn {
  position: absolute; top: calc(14px + env(safe-area-inset-top, 0px)); right: max(14px, calc((100vw - 1000px) / 2));
  width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(241, 191, 152, .45); background: transparent;
  display: grid; place-items: center; padding: 0;
}
.zc-head-btn svg { width: 22px; height: 22px; fill: var(--peach); }
.zc-badge {
  position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px;
  background: var(--peach); color: var(--dark); font-family: var(--sans); font-size: 11px; font-weight: 600; line-height: 20px; text-align: center;
}

/* ───────── "Ordering is closed" notice under the tabs ───────── */
.zc-notice {
  padding: 10px max(18px, calc((100vw - 1000px) / 2)); background: #f5e4d2; border-bottom: 1px solid var(--line);
  color: var(--dark); font-size: 13px; font-weight: 500; line-height: 1.4;
}

/* ───────── Add / stepper on the menu cards ───────── */
.card .zc-ctl { grid-column: 1 / -1; display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.card.dish .zc-ctl { grid-column: 2 / -1; margin-top: 8px; }
.card.dish figure { grid-row: 1 / span 3; align-self: center; }

.zc-add, .zc-step, .zc-seg { font-family: var(--sans); }
.zc-add {
  min-width: 76px; height: 36px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--dark);
  background: var(--dark); color: var(--cream); font-size: 13px; font-weight: 600;
}
.zc-add:disabled { background: transparent; border-color: var(--line); color: var(--muted); cursor: default; }

.zc-step { display: inline-flex; align-items: center; height: 36px; border: 1px solid var(--dark); border-radius: 999px; background: var(--card); }
.zc-step button { width: 36px; height: 34px; padding: 0; border: 0; border-radius: 999px; background: transparent; color: var(--dark); font-size: 18px; font-weight: 500; line-height: 1; }
.zc-step button:disabled { color: var(--line); cursor: default; }
.zc-step b { min-width: 20px; text-align: center; font-size: 14px; font-weight: 600; color: var(--dark); }

.zc-seg { display: inline-flex; height: 36px; padding: 3px; margin-right: auto; border-radius: 999px; background: #f5e4d2; }
.zc-seg button { padding: 0 12px; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font-size: 12px; font-weight: 600; }
.zc-seg button[aria-pressed="true"] { background: var(--card); color: var(--dark); box-shadow: 0 1px 2px rgba(63, 18, 2, .15); }
.zc-seg i { display: inline-block; min-width: 16px; margin-left: 5px; padding: 0 4px; border-radius: 999px; background: var(--dark); color: var(--cream); font-style: normal; font-size: 10px; line-height: 16px; text-align: center; }

.zc-add:focus-visible, .zc-step button:focus-visible, .zc-seg button:focus-visible, .zc-head-btn:focus-visible,
.zc-bar:focus-visible, .zc-x:focus-visible, .zc-btn:focus-visible, .zc-remove:focus-visible { outline: 2px solid var(--peach); outline-offset: 2px; }

/* ───────── Floating "View order" bar (Bella sits bottom-right) ───────── */
.zc-bar {
  position: fixed; z-index: 40; left: 14px; right: 104px; bottom: calc(22px + env(safe-area-inset-bottom, 0px));
  display: flex; align-items: center; gap: 10px; height: 56px; padding: 0 18px; border: 0; border-radius: 999px;
  background: var(--dark); color: var(--cream); font-family: var(--sans); text-align: left;
  box-shadow: 0 10px 26px rgba(42, 12, 2, .32); animation: zc-rise .3s ease-out;
}
.zc-bar svg { flex: none; width: 20px; height: 20px; fill: var(--peach); }
.zc-bar-text { font-size: 14px; font-weight: 600; white-space: nowrap; }
.zc-bar-meta { margin-left: auto; font-size: 12px; font-weight: 500; color: var(--peach); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* The live-video Bella launcher is a wide pill on phones, so the bar sits just above it. */
@media (max-width: 719px) { body.tavus-on .zc-bar { right: 14px; bottom: calc(88px + env(safe-area-inset-bottom, 0px)); } }
@media (min-width: 720px) { .zc-bar { left: 50%; right: auto; width: 380px; transform: translateX(-50%); animation: none; } }
@keyframes zc-rise { from { opacity: 0; transform: translateY(12px); } }

/* ───────── Drawer ───────── */
.zc-backdrop { position: fixed; inset: 0; z-index: 55; background: rgba(42, 12, 2, .45); opacity: 0; pointer-events: none; transition: opacity .25s; }
.zc-backdrop.open { opacity: 1; pointer-events: auto; }
.zc-drawer {
  position: fixed; z-index: 56; left: 0; right: 0; bottom: 0; height: min(92dvh, 760px);
  display: flex; flex-direction: column; background: var(--cream); color: var(--ink); font-family: var(--sans);
  border-radius: 22px 22px 0 0; box-shadow: 0 -10px 40px rgba(42, 12, 2, .3);
  transform: translateY(105%); visibility: hidden; transition: transform .35s cubic-bezier(.2, 1, .3, 1), visibility 0s .35s;
}
.zc-drawer.open { transform: none; visibility: visible; transition: transform .35s cubic-bezier(.2, 1, .3, 1); }
@media (min-width: 720px) {
  .zc-drawer { left: auto; top: 0; width: 420px; height: auto; border-radius: 0; box-shadow: -10px 0 40px rgba(42, 12, 2, .25); transform: translateX(105%); }
  /* Bella's chat panel floats on the right, so the order slides in from the left while she is open. */
  body.chat-open .zc-drawer { left: 0; right: auto; box-shadow: 10px 0 40px rgba(42, 12, 2, .25); transform: translateX(-105%); }
  body.chat-open .zc-drawer.open { transform: none; }
}
body.zc-open { overflow: hidden; }

.zc-drawer-head { flex: none; display: flex; align-items: center; justify-content: space-between; padding: 18px 18px 12px; border-bottom: 1px solid var(--line); }
.zc-drawer-head h2 { margin: 0; font-family: var(--serif); font-size: 30px; font-weight: 600; color: var(--dark); line-height: 1.1; }
.zc-x { width: 40px; height: 40px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: var(--card); display: grid; place-items: center; }
.zc-x svg { width: 18px; height: 18px; fill: var(--dark); }
.zc-drawer-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 14px 18px calc(22px + env(safe-area-inset-bottom, 0px)); }

.zc-closed { margin: 0 0 14px; padding: 10px 14px; border-radius: 12px; background: #f5e4d2; color: var(--dark); font-size: 13px; font-weight: 500; line-height: 1.4; }
.zc-empty { padding: 36px 8px; text-align: center; }
.zc-empty p { margin: 0 0 6px; font-family: var(--serif); font-size: 24px; font-weight: 600; color: var(--dark); }
.zc-empty span { display: block; margin-bottom: 18px; font-size: 13px; line-height: 1.5; color: var(--muted); }

.zc-lines { list-style: none; margin: 0; padding: 0; }
.zc-line {
  display: grid; grid-template-columns: 1fr auto auto; grid-template-areas: "name step price" "remove remove remove";
  align-items: center; column-gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line);
}
.zc-line-name { grid-area: name; min-width: 0; }
.zc-line-name b { font-size: 15px; font-weight: 600; }
.zc-line-name small { margin-left: 8px; padding: 2px 7px; border-radius: 999px; background: #f5e4d2; font-size: 10px; font-weight: 600; color: var(--muted); vertical-align: 1px; }
.zc-line-name span { display: block; margin-top: 2px; font-size: 12px; color: var(--muted); }
.zc-line .zc-step { grid-area: step; }
.zc-line-price { grid-area: price; min-width: 38px; text-align: right; font-size: 15px; font-weight: 600; color: var(--dark); }
.zc-remove { grid-area: remove; justify-self: start; margin-top: 4px; padding: 4px 0; border: 0; background: none; font-family: var(--sans); font-size: 12px; color: var(--muted); text-decoration: underline; }

.zc-totals { padding: 14px 0 4px; font-size: 14px; }
.zc-totals div { display: flex; align-items: baseline; justify-content: space-between; padding: 3px 0; color: var(--muted); }
.zc-totals b { font-weight: 600; color: var(--dark); }
.zc-totals .zc-total { margin-top: 6px; padding-top: 10px; border-top: 2px solid var(--dark); font-size: 17px; color: var(--dark); font-weight: 600; }
.zc-totals small { margin-left: 6px; font-size: 11px; font-weight: 500; color: var(--muted); }

.zc-form { margin-top: 18px; }
.zc-form h3 { margin: 0 0 8px; font-family: var(--serif); font-size: 24px; font-weight: 600; color: var(--dark); }
.zc-pickup { display: flex; align-items: flex-start; gap: 8px; margin: 0 0 14px; font-size: 13px; line-height: 1.45; color: var(--muted); }
.zc-pickup svg { flex: none; width: 16px; height: 16px; margin-top: 2px; fill: var(--dark); }
.zc-form label { display: block; margin: 12px 0 5px; font-size: 12px; font-weight: 600; color: var(--dark); }
.zc-form label span { font-weight: 400; color: var(--muted); }
.zc-form input, .zc-form textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card);
  color: var(--ink); font-family: var(--sans); font-size: 16px; outline: none; resize: vertical;
}
.zc-form input:focus, .zc-form textarea:focus { border-color: var(--dark); box-shadow: 0 0 0 3px rgba(63, 18, 2, .12); }
.zc-hint { margin: 5px 0 0; font-size: 12px; color: var(--muted); }
.zc-error { margin: 14px 0 0; padding: 10px 14px; border-radius: 12px; background: #fbe6e1; color: #8a1f0b; font-size: 13px; font-weight: 500; line-height: 1.4; }
.zc-secure { margin: 10px 0 0; text-align: center; font-size: 12px; color: var(--muted); }

.zc-btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 26px; border-radius: 999px;
  border: 1px solid var(--dark); background: var(--dark); color: var(--cream);
  font-family: var(--sans); font-size: 15px; font-weight: 600; text-decoration: none; cursor: pointer;
}
.zc-btn:disabled { opacity: .5; cursor: default; }
.zc-btn-ghost { min-height: 44px; background: transparent; color: var(--dark); }
.zc-pay { width: 100%; margin-top: 18px; }

/* ───────── Order status page ───────── */
.top-back { display: inline-block; color: var(--peach); font-size: 13px; font-weight: 600; text-decoration: none; }
.order-wrap { max-width: 560px; margin: 0 auto; padding: 28px 18px 0; }
.order-card { padding: 24px 20px; border: 1px solid var(--line); border-radius: 18px; background: var(--card); }
.order-state { text-align: center; }
.order-icon { width: 56px; height: 56px; margin: 0 auto 14px; border-radius: 50%; display: grid; place-items: center; background: #f5e4d2; }
.order-icon svg { width: 28px; height: 28px; fill: var(--dark); }
.order-icon.ok { background: var(--dark); } .order-icon.ok svg { fill: var(--peach); }
.order-icon.bad { background: #fbe6e1; } .order-icon.bad svg { fill: #8a1f0b; }
.order-icon.wait::after { content: ""; width: 26px; height: 26px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--dark); animation: zc-spin .9s linear infinite; }
@keyframes zc-spin { to { transform: rotate(360deg); } }
.order-state h1 { margin: 0; font-family: var(--serif); font-size: 34px; font-weight: 600; line-height: 1.1; color: var(--dark); }
.order-state p { margin: 8px 0 0; font-size: 14px; line-height: 1.5; color: var(--muted); }
.order-ref { display: inline-block; margin-top: 14px; padding: 6px 14px; border-radius: 999px; background: #f5e4d2; font-size: 12px; font-weight: 600; letter-spacing: .08em; color: var(--dark); }
.order-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 18px; }

.order-steps { display: flex; list-style: none; margin: 22px 0 0; padding: 0; }
.order-steps li { flex: 1; position: relative; padding-top: 20px; text-align: center; font-size: 11px; font-weight: 600; letter-spacing: .04em; color: var(--muted); }
.order-steps li::before { content: ""; position: absolute; top: 0; left: 50%; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: var(--line); z-index: 1; }
.order-steps li::after { content: ""; position: absolute; top: 5px; left: -50%; width: 100%; height: 2px; background: var(--line); }
.order-steps li:first-child::after { display: none; }
.order-steps li.done { color: var(--dark); }
.order-steps li.done::before, .order-steps li.done::after { background: var(--dark); }

.order-items { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line); }
.order-items h2 { margin: 0 0 8px; font-size: 10px; font-weight: 600; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); }
.order-items ul { list-style: none; margin: 0; padding: 0; }
.order-items li { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; font-size: 14px; }
.order-items li span:first-child { min-width: 0; }
.order-items li small { margin-left: 6px; color: var(--muted); font-size: 12px; }
.order-items li b { flex: none; font-weight: 600; color: var(--dark); }
.order-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 8px; padding-top: 12px; border-top: 2px solid var(--dark); font-size: 17px; font-weight: 600; color: var(--dark); }
.order-total small { margin-left: 6px; font-size: 11px; font-weight: 500; color: var(--muted); }
.order-page .foot { padding-bottom: 60px; }

@media (prefers-reduced-motion: reduce) {
  .zc-bar, .zc-drawer, .zc-backdrop, .order-icon.wait::after { animation: none; transition: none; }
}
