/* Bepma5 — customer order pages: confirmation, my orders, QR verification. */
.order-wrap { max-width: 640px; margin: 0 auto; }
.order-wrap .page-title { font-size: 1.6rem; margin-bottom: 1rem; }
.order-wrap .small { font-size: .85rem; }
.order-wrap .text-end { text-align: right; }

.order-hero { text-align: center; padding: 26px 18px; }
.order-hero .eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .72rem; color: var(--bm-gold); font-weight: 700; margin-bottom: .25rem; }
.thanks-icon { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, #22c55e 14%, #fff); color: #15803d; }
.thanks-icon svg { width: 32px; height: 32px; }
.thanks-title { font-size: clamp(1.35rem, 5vw, 1.8rem); text-transform: uppercase; letter-spacing: .02em; color: var(--bm-primary); }
.order-number { font-family: var(--bm-font-heading); font-size: clamp(1.5rem, 6vw, 2.1rem); font-weight: 700; letter-spacing: .04em; color: var(--bm-charcoal); margin: 0 0 .6rem; word-break: break-all; }
.verify-badge { display: inline-flex; align-items: center; gap: .35rem; padding: .3rem .8rem; border-radius: 999px; background: color-mix(in srgb, #22c55e 12%, #fff); color: #15803d; font-weight: 600; font-size: .8rem; margin-bottom: .75rem; }
.verify-badge svg { width: 16px; height: 16px; }

.status-pill { display: inline-block; padding: .28rem .8rem; border-radius: 999px; font-size: .78rem; font-weight: 700; background: var(--bm-gold-soft); color: #6d5326; }
.status-pending { background: #FEF3C7; color: #92400E; }
.status-confirmed { background: #DBEAFE; color: #1E40AF; }
.status-cooking { background: #FFEDD5; color: #9A3412; }
.status-packaging { background: #EDE9FE; color: #5B21B6; }
.status-ready { background: #CFFAFE; color: #155E75; }
.status-delivering { background: #E0E7FF; color: #3730A3; }
.status-completed { background: #DCFCE7; color: #166534; }
.status-cancelled { background: #FEE2E2; color: #991B1B; }

.share-actions { display: grid; gap: 10px; }
.share-actions .btn svg { width: 18px; height: 18px; }
.share-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.share-row .btn { width: 100%; }

.o-line { display: flex; align-items: flex-start; gap: 12px; padding: 10px 0; border-bottom: 1px dashed var(--bm-line); }
.o-line:last-of-type { border-bottom: 0; }
.o-thumb { flex: none; width: 56px; height: 56px; border-radius: 12px; overflow: hidden; display: grid; place-items: center; background: linear-gradient(135deg, #efe6d8, #f8f3ea); color: var(--bm-gold); }
.o-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.o-thumb svg { width: 24px; height: 24px; }
.o-info { flex: 1; min-width: 0; }
.o-name { font-weight: 600; }
.o-name a { color: inherit; text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--bm-gold) 60%, transparent); text-underline-offset: 3px; }
.o-name a:hover { color: var(--bm-primary); }

.contact-cta-btns { display: grid; gap: 10px; }
.contact-cta-btns .btn { min-height: 52px; }
.contact-cta-btns .btn svg { width: 20px; height: 20px; flex: none; }
.contact-cta-btns .btn span { display: inline-flex; flex-direction: column; align-items: flex-start; line-height: 1.2; }
.contact-cta-btns .btn small { font-size: .78rem; font-weight: 500; opacity: .85; }
@media (min-width: 480px) { .contact-cta-btns { grid-template-columns: 1fr 1fr; } }
.o-amt { font-weight: 700; white-space: nowrap; }
.est-star { color: var(--bm-primary); font-weight: 700; }
.totals { border-top: 1px solid var(--bm-line); padding-top: 10px; }
.row-t { display: flex; justify-content: space-between; padding: 3px 0; }
.row-t.grand { font-size: 1.15rem; font-weight: 700; color: var(--bm-primary); padding-top: 8px; }
.est-note { margin-top: 10px; padding: .6rem .8rem; border-radius: var(--bm-radius-sm); background: var(--bm-gold-soft); font-size: .82rem; color: #6d5326; }

.verify-card { display: flex; align-items: center; gap: 16px; }
.verify-card img { flex: none; border-radius: 8px; background: #fff; }

.timeline { list-style: none; margin: 14px 0 0; padding: 18px 18px 6px; }
.timeline li { position: relative; display: flex; align-items: center; gap: 12px; min-height: 40px; padding: 0 0 14px 44px; color: var(--bm-gray); }
.timeline li::before { content: ""; position: absolute; left: 15px; top: 32px; bottom: -2px; width: 2px; background: var(--bm-line); }
.timeline li:last-child::before { display: none; }
.timeline .dot { position: absolute; left: 0; top: 0; width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--bm-line); background: #fff; display: grid; place-items: center; color: #b9b2a6; }
.timeline .tl-ico { width: 17px; height: 17px; }
.timeline li.done { color: var(--bm-charcoal); }
.timeline li.done .dot { background: #22c55e; border-color: #22c55e; color: #fff; }
.timeline li.done::before { background: #22c55e; }
.timeline li.current::before { background: var(--bm-line); }
.timeline li.current .dot { background: var(--bm-primary); border-color: var(--bm-primary); box-shadow: 0 0 0 0 color-mix(in srgb, var(--bm-primary) 45%, transparent); animation: tl-pulse 1.8s ease-out infinite; }
.timeline li.current .tl-label { font-weight: 700; color: var(--bm-primary); }
.timeline li.st-completed.current .dot { background: #22c55e; border-color: #22c55e; animation: none; }
/* a small motion per step, only on the current one */
.timeline li.current.st-pending .tl-ico { animation: tl-spin 3s linear infinite; }
.timeline li.current.st-confirmed .tl-ico { animation: tl-pop 1.6s ease-in-out infinite; }
.timeline li.current.st-cooking .tl-ico { animation: tl-flicker .9s ease-in-out infinite alternate; transform-origin: 50% 90%; }
.timeline li.current.st-packaging .tl-ico { animation: tl-bounce 1.2s ease-in-out infinite; }
.timeline li.current.st-ready .tl-ico { animation: tl-ring 1.4s ease-in-out infinite; transform-origin: 50% 10%; }
.timeline li.current.st-delivering .tl-ico { animation: tl-ride .8s ease-in-out infinite alternate; }
.tl-time { margin-left: auto; font-size: .8rem; color: var(--bm-gray); }
@keyframes tl-pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--bm-primary) 45%, transparent); } 70% { box-shadow: 0 0 0 10px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
@keyframes tl-spin { to { transform: rotate(360deg); } }
@keyframes tl-pop { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.25); } }
@keyframes tl-flicker { from { transform: scale(.9) rotate(-4deg); } to { transform: scale(1.12) rotate(4deg); } }
@keyframes tl-bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes tl-ring { 0%, 60%, 100% { transform: rotate(0); } 15% { transform: rotate(18deg); } 30% { transform: rotate(-16deg); } 45% { transform: rotate(10deg); } }
@keyframes tl-ride { from { transform: translateX(-2px); } to { transform: translateX(2px) translateY(-1px); } }

/* delivery route card */
.route-card .card-title svg { color: var(--bm-primary); }
.bike-anim { animation: tl-ride .8s ease-in-out infinite alternate; }
.moving-chip { background: #E8F7EE !important; color: #166534 !important; }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 0 rgba(34,197,94,.6); animation: live 1.4s infinite; }
@keyframes live { 70% { box-shadow: 0 0 0 8px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }
@media (prefers-reduced-motion: reduce) { .timeline li.current .dot, .timeline li.current .tl-ico, .bike-anim, .live-dot { animation: none !important; } }

.my-orders { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 10px; }
.my-order { display: flex; justify-content: space-between; align-items: center; gap: 12px; color: inherit; margin: 0 !important; }
.my-order:hover { color: inherit; border-color: var(--bm-gold); }

@media (min-width: 560px) {
  .share-actions { grid-template-columns: 1fr 1fr; }
  .share-actions [data-pdf-download], .share-actions .share-row { grid-column: 1 / -1; }
}
@media print {
  .share-card, .site-header, .bottom-nav, .site-footer { display: none !important; }
}
/* keep share buttons inside the card on narrow phones */
.share-actions, .share-row { grid-template-columns: minmax(0, 1fr); }
.share-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.share-actions .btn { min-width: 0; white-space: normal; text-align: center; line-height: 1.25; }
@media (min-width: 640px) { .share-actions { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.received-form { margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--bm-line); }

/* ---------- Loyalty: member card + membership page ---------- */
.loyalty-card { border-top: 4px solid var(--tier, var(--bm-gold)); }
.loyalty-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin-bottom: 10px; }
.tier-pill { display: inline-flex; align-items: center; gap: 6px; margin-top: 4px; padding: 4px 12px; border-radius: 999px; background: var(--tier, var(--bm-gold)); color: #fff; font-weight: 700; text-shadow: 0 1px 1px rgba(0,0,0,.25); }
.tier-pill svg { width: 16px; height: 16px; fill: currentColor; }
.loyalty-pts { font-family: var(--bm-font-heading); font-weight: 700; font-size: 1.35rem; color: var(--bm-primary); white-space: nowrap; }
.loyalty-bar { height: 8px; border-radius: 999px; background: var(--bm-line); overflow: hidden; margin-bottom: 6px; }
.loyalty-bar > span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--bm-gold), var(--tier, var(--bm-primary))); transition: width .6s ease; }
.loyalty-order { margin: 10px 0 0; padding: 8px 12px; border-radius: var(--bm-radius-sm); background: var(--bm-gold-soft); font-size: .9rem; display: flex; gap: 6px; align-items: center; }
.loyalty-order svg { width: 16px; height: 16px; flex: none; }
.loyalty-benefits { margin: 12px 0 8px; font-size: .92rem; }
.loyalty-benefits ul { margin: 6px 0 0; padding-left: 20px; }
.membership-wrap { max-width: 980px; }
.membership-wrap > .loyalty-card { max-width: 560px; margin: 0 auto 18px; }
.tier-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 18px; }
.tier-card { background: #fff; border-radius: var(--bm-radius); box-shadow: var(--bm-shadow); padding: 16px; border: 1px solid var(--bm-line); border-top: 5px solid var(--tier); position: relative; }
.tier-card.is-mine { outline: 2px solid var(--tier); outline-offset: 2px; }
.tier-card header { display: flex; gap: 10px; align-items: center; margin-bottom: 8px; }
.tier-card h2 { font-size: 1.15rem; margin: 0; color: var(--tier); filter: brightness(.85); }
.tier-icon { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--tier); color: #fff; flex: none; }
.tier-icon svg { width: 20px; height: 20px; fill: currentColor; }
.tier-card ul { margin: 0; padding-left: 18px; font-size: .92rem; }
.tier-card li + li { margin-top: 4px; }
.tier-card .tier-disc { font-weight: 700; color: var(--bm-primary); }
.membership-cols { display: grid; gap: 14px; grid-template-columns: 1fr; }
.membership-cols .card + .card { margin-top: 0; }
@media (min-width: 760px) { .membership-cols { grid-template-columns: 1.1fr 1fr; } }
.rule-list { margin: 0; padding-left: 18px; }
.rule-list li + li { margin-top: 6px; }
.row-t.member-off span:first-child { color: var(--bm-primary); }
.loyalty-balance { margin: 10px 0 0; font-weight: 600; display: flex; gap: 6px; align-items: center; }
.loyalty-balance svg { width: 16px; height: 16px; color: var(--bm-gold); fill: currentColor; flex: none; }
