:root {
  --bg: #FAF6F2;
  --surface: #FFFFFF;
  --blush: #F4ECE6;
  --blush-2: #EFE4DD;
  --ink: #3B3330;
  --ink-2: #7B6F69;
  --ink-3: #AEA39C;
  --line: #ECE2DA;
  --rose: #C08A80;
  --rose-d: #A8726A;
  --rose-l: #F5E6E1;
  --sage: #93A28A;
  --sage-l: #E7ECE2;
  --gold: #C9A77A;
  --danger: #C4645A;
  --shadow: 0 8px 28px rgba(92, 62, 50, .07);
  --shadow-s: 0 2px 10px rgba(92, 62, 50, .06);
  --r: 18px;
  --r-s: 13px;
  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans: "Manrope", -apple-system, "Segoe UI", Roboto, sans-serif;
  --safe-b: max(env(safe-area-inset-bottom), var(--tg-safe-area-inset-bottom, 0px));
  --top: calc(var(--tg-safe-area-inset-top, 0px) + var(--tg-content-safe-area-inset-top, 0px));
  --nav-h: 64px;
  color-scheme: light;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body {
  font: 500 15px/1.45 var(--sans);
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
  min-height: 100vh;
}
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
img { display: block; max-width: 100%; }
input, textarea, select { -webkit-appearance: none; appearance: none; }
svg { flex: none; }
.hidden { display: none !important; }

/* ---------- views ---------- */
#view { padding-top: var(--top); padding-bottom: calc(var(--nav-h) + var(--safe-b) + 24px); min-height: 100vh; }
#view.with-bar { padding-bottom: calc(var(--nav-h) + var(--safe-b) + 96px); }
#view.no-nav { padding-bottom: calc(var(--safe-b) + 112px); }
.page { animation: enter .28s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes enter { from { opacity: 0; transform: translateY(8px); } }
.pad { padding: 0 16px; }

.head { padding: 14px 16px 6px; display: flex; align-items: center; gap: 12px; }
.title { font: 600 30px/1.1 var(--serif); letter-spacing: -.2px; margin: 0; }
.h2 { font: 600 23px/1.15 var(--serif); margin: 0; }
.sub { color: var(--ink-2); font-size: 13px; }
.muted { color: var(--ink-3); }

.section { margin-top: 26px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; padding: 0 16px 12px; gap: 12px; }
.link { color: var(--rose-d); font-weight: 600; font-size: 13px; white-space: nowrap; }

/* ---------- home ---------- */
.brand { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 4px; }
.logo { font: 600 29px/1 var(--serif); letter-spacing: .2px; }
.logo i { font-style: italic; color: var(--rose); font-weight: 500; }
.city { display: flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--ink-2); margin-top: 5px; }
.city svg { width: 14px; height: 14px; color: var(--rose); }
.icon-btn {
  width: 42px; height: 42px; border-radius: 50%; background: var(--surface); display: grid; place-items: center;
  box-shadow: var(--shadow-s); position: relative; color: var(--ink);
}
.icon-btn svg { width: 20px; height: 20px; }

.search {
  margin: 12px 16px 0; height: 48px; border-radius: 24px; background: var(--surface); display: flex; align-items: center;
  gap: 10px; padding: 0 18px; color: var(--ink-3); box-shadow: var(--shadow-s); width: calc(100% - 32px); text-align: left;
}
.search svg { width: 19px; height: 19px; }
.search input { border: 0; outline: 0; background: none; flex: 1; min-width: 0; height: 100%; color: var(--ink); font-size: 15px; }
.search input::placeholder { color: var(--ink-3); }

.hero { display: flex; gap: 10px; overflow-x: auto; scroll-padding: 0 16px; scroll-snap-type: x mandatory; padding: 16px 16px 2px; scrollbar-width: none; }
.hero::-webkit-scrollbar, .hscroll::-webkit-scrollbar, .chips::-webkit-scrollbar { display: none; }
.slide {
  flex: 0 0 100%; scroll-snap-align: center; height: 188px; border-radius: 22px; overflow: hidden; position: relative;
  background: var(--blush); text-align: left;
}
.slide img { position: absolute; right: 0; top: 0; width: 56%; height: 100%; object-fit: cover; }
.slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--slide-bg, #F3E6E0) 44%, rgba(243, 230, 224, 0) 70%); }
.slide-text { position: relative; z-index: 1; padding: 22px 20px; max-width: 64%; height: 100%; display: flex; flex-direction: column; }
.slide-text b { font: 600 25px/1.05 var(--serif); display: block; }
.slide-text span { font-size: 12.5px; color: var(--ink-2); margin-top: 8px; display: block; }
.slide-text em { margin-top: auto; align-self: flex-start; font-style: normal; font-size: 12px; font-weight: 700; letter-spacing: .4px;
  background: var(--surface); padding: 7px 12px; border-radius: 20px; color: var(--rose-d); }
.dots { display: flex; justify-content: center; gap: 6px; margin-top: 10px; }
.dots i { width: 6px; height: 6px; border-radius: 3px; background: var(--line); transition: .25s; }
.dots i.on { width: 18px; background: var(--rose); }

.cats { display: flex; gap: 14px; overflow-x: auto; padding: 4px 16px 2px; scrollbar-width: none; }
.cats::-webkit-scrollbar { display: none; }
.cat { flex: none; width: 70px; display: flex; flex-direction: column; align-items: center; gap: 7px; font-size: 12px; color: var(--ink-2); }
.cat .ph { width: 66px; height: 66px; border-radius: 50%; overflow: hidden; background: var(--blush); border: 2px solid var(--surface); box-shadow: var(--shadow-s); }
.cat .ph img { width: 100%; height: 100%; object-fit: cover; }
.cat span { text-align: center; line-height: 1.2; }

.hscroll { display: flex; gap: 12px; overflow-x: auto; padding: 0 16px 6px; scroll-padding: 0 16px; scroll-snap-type: x proximity; scrollbar-width: none; }
.hscroll .card { flex: 0 0 158px; scroll-snap-align: start; }

/* ---------- product cards ---------- */
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 12px; padding: 0 16px; }
.card { position: relative; text-align: left; min-width: 0; display: block; }
.card .ph { position: relative; aspect-ratio: 4 / 5; border-radius: var(--r); overflow: hidden; background: var(--blush); }
.card .ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:active .ph img { transform: scale(1.03); }
.card .name { margin-top: 9px; font-size: 13.5px; line-height: 1.3; font-weight: 500; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden; }
.card .price { margin-top: 3px; font-weight: 700; font-size: 15px; }
.card .meta { display: flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--ink-3); margin-top: 3px; }
.card .meta svg { width: 12px; height: 12px; color: var(--gold); }
.fav {
  position: absolute; top: 8px; right: 8px; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, .82); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); color: var(--ink-2); z-index: 2;
}
.fav svg { width: 17px; height: 17px; }
.fav.on { color: var(--rose); }
.fav.on svg path { fill: currentColor; }
.fav.pop { animation: pop .35s ease; }
@keyframes pop { 40% { transform: scale(1.25); } }
.badge-today { position: absolute; left: 8px; bottom: 8px; font-size: 10.5px; font-weight: 700; padding: 4px 8px; border-radius: 10px;
  background: rgba(255, 255, 255, .86); color: var(--sage); letter-spacing: .2px; }

img.fade { opacity: 0; transition: opacity .35s ease; }
img.fade.ok { opacity: 1; }

/* ---------- shops ---------- */
.shop-card {
  display: flex; align-items: center; gap: 13px; background: var(--surface); border-radius: var(--r); padding: 12px; box-shadow: var(--shadow-s);
  text-align: left; width: 100%;
}
.shop-card + .shop-card { margin-top: 10px; }
.shop-ava { width: 52px; height: 52px; border-radius: 15px; display: grid; place-items: center; font: 600 22px var(--serif); color: var(--ink); flex: none; }
.shop-card b { display: block; font-weight: 600; }
.shop-card .sub { display: flex; gap: 10px; align-items: center; margin-top: 2px; }
.shop-card .sub svg { width: 12px; height: 12px; color: var(--gold); }
.chev { margin-left: auto; color: var(--ink-3); width: 18px; height: 18px; }

/* ---------- chips ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 4px 16px; scrollbar-width: none; }
.chip {
  flex: none; height: 36px; padding: 0 15px; border-radius: 18px; background: var(--surface); font-size: 13px; font-weight: 600;
  color: var(--ink-2); border: 1px solid var(--line); display: inline-flex; align-items: center; gap: 6px; transition: .2s;
}
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip.soft.on { background: var(--rose-l); color: var(--rose-d); border-color: var(--rose-l); }
.count { padding: 6px 16px 14px; font-size: 12.5px; color: var(--ink-3); }

/* ---------- product page ---------- */
.p-hero { position: relative; aspect-ratio: 4 / 4.6; background: var(--blush); overflow: hidden; margin-top: calc(var(--top) * -1); }
.p-hero img { width: 100%; height: 100%; object-fit: cover; }
.p-hero .fav { top: calc(var(--top) + 14px); right: 14px; width: 42px; height: 42px; }
.p-hero .fav svg { width: 20px; height: 20px; }
.p-body { position: relative; margin-top: -26px; background: var(--bg); border-radius: 26px 26px 0 0; padding: 22px 16px 0; }
.p-shop { font-size: 12.5px; color: var(--rose-d); font-weight: 600; letter-spacing: .3px; text-transform: uppercase; }
.p-name { font: 600 29px/1.08 var(--serif); margin: 6px 0 8px; }
.p-rate { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ink-2); }
.p-rate svg { width: 14px; height: 14px; color: var(--gold); }
.p-price { font-size: 25px; font-weight: 700; margin-top: 14px; letter-spacing: -.3px; }
.seg { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.seg button { min-width: 72px; padding: 9px 14px; border-radius: 14px; background: var(--surface); border: 1.5px solid var(--line); text-align: center; transition: .2s; }
.seg button b { display: block; font-size: 14px; }
.seg button span { font-size: 11.5px; color: var(--ink-3); }
.seg button.on { border-color: var(--rose); background: var(--rose-l); }
.seg button.on span { color: var(--rose-d); }
.block { background: var(--surface); border-radius: var(--r); padding: 16px; margin-top: 14px; box-shadow: var(--shadow-s); }
.block h3 { margin: 0 0 10px; font: 600 19px var(--serif); }
.block p { margin: 0; color: var(--ink-2); font-size: 14px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.tags span { font-size: 12px; padding: 5px 10px; border-radius: 10px; background: var(--sage-l); color: #67755F; font-weight: 600; }
.info-row { display: flex; align-items: center; gap: 12px; font-size: 13.5px; }
.info-row + .info-row { margin-top: 12px; }
.info-row svg { width: 20px; height: 20px; color: var(--rose); }
.info-row .sub { display: block; }
.review { padding: 12px 0; border-top: 1px solid var(--line); }
.review:first-of-type { border-top: 0; padding-top: 0; }
.review-top { display: flex; justify-content: space-between; align-items: center; font-weight: 600; font-size: 14px; }
.stars { display: inline-flex; gap: 2px; color: var(--gold); }
.stars svg { width: 13px; height: 13px; }
.stars .off { color: var(--line); }
.review p { margin-top: 5px; font-size: 13.5px; }

/* ---------- bottom bars ---------- */
.bar {
  position: fixed; left: 0; right: 0; bottom: calc(var(--nav-h) + var(--safe-b)); z-index: 30; padding: 10px 16px;
  background: linear-gradient(rgba(250, 246, 242, 0), var(--bg) 30%); display: flex; gap: 10px; align-items: center;
}
.no-nav-bar { bottom: 0; padding-bottom: calc(var(--safe-b) + 12px); }
.btn {
  height: 52px; border-radius: 26px; padding: 0 22px; font-weight: 700; font-size: 15px; display: inline-flex; align-items: center;
  justify-content: center; gap: 8px; transition: transform .15s ease, background .2s, opacity .2s; white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--rose); color: #fff; box-shadow: 0 8px 22px rgba(192, 138, 128, .35); flex: 1; }
.btn.primary:disabled { opacity: .55; box-shadow: none; }
.btn.dark { background: var(--ink); color: #fff; flex: 1; }
.btn.ghost { background: var(--surface); color: var(--ink); border: 1px solid var(--line); }
.btn.wide { width: 100%; }
.btn small { font-weight: 600; opacity: .85; }
.stepper { height: 52px; border-radius: 26px; background: var(--surface); border: 1px solid var(--line); display: flex; align-items: center; }
.stepper button { width: 46px; height: 100%; display: grid; place-items: center; color: var(--ink); }
.stepper button svg { width: 18px; height: 18px; }
.stepper b { min-width: 22px; text-align: center; }
.stepper.small { height: 34px; border-radius: 17px; }
.stepper.small button { width: 34px; }
.stepper.small button svg { width: 15px; height: 15px; }

/* ---------- nav ---------- */
#nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; background: rgba(255, 255, 255, .9);
  backdrop-filter: saturate(1.4) blur(18px); -webkit-backdrop-filter: saturate(1.4) blur(18px); border-top: 1px solid var(--line);
  padding-bottom: var(--safe-b);
}
#nav button { flex: 1; height: var(--nav-h); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  font-size: 10.5px; font-weight: 600; color: var(--ink-3); position: relative; }
#nav button svg { width: 23px; height: 23px; }
#nav button.on { color: var(--rose-d); }
#nav .dot { position: absolute; top: 9px; left: calc(50% + 6px); min-width: 17px; height: 17px; border-radius: 9px; background: var(--rose);
  color: #fff; font-size: 10px; font-weight: 700; display: grid; place-items: center; padding: 0 4px; border: 2px solid #fff; }
#nav .dot.bump { animation: pop .4s ease; }

/* ---------- cart ---------- */
.cart-item { display: flex; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.cart-item:first-of-type { border-top: 0; padding-top: 2px; }
.cart-item img { width: 76px; height: 92px; border-radius: 14px; object-fit: cover; background: var(--blush); }
.cart-item .ci { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.cart-item .ci b { font-weight: 600; font-size: 14px; line-height: 1.3; }
.cart-item .ci .sub { margin-top: 2px; }
.cart-item .ci-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; padding-top: 8px; }
.cart-item .ci-foot strong { font-size: 15px; }
.remove { color: var(--ink-3); width: 28px; height: 28px; display: grid; place-items: center; margin: -4px -4px 0 0; }
.remove svg { width: 16px; height: 16px; }
.toggle-row { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; }
.toggle-row .grow { flex: 1; }
.switch { width: 46px; height: 28px; border-radius: 14px; background: var(--line); position: relative; transition: .25s; flex: none; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .15); transition: .25s; }
.switch.on { background: var(--rose); }
.switch.on::after { left: 21px; }
.sum-row { display: flex; justify-content: space-between; font-size: 14px; color: var(--ink-2); }
.sum-row + .sum-row { margin-top: 8px; }
.sum-row.total { color: var(--ink); font-size: 17px; font-weight: 700; margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line); }
.sum-row .green { color: var(--sage); font-weight: 600; }
.promo-row { display: flex; gap: 8px; }
.promo-row .field { flex: 1; min-width: 0; }
.promo-ok { color: var(--sage); font-size: 13px; font-weight: 600; margin-top: 8px; display: flex; align-items: center; gap: 6px; }
.promo-ok svg { width: 15px; height: 15px; }
.free-hint { font-size: 12.5px; color: var(--ink-2); margin-top: 12px; }
.progress { height: 5px; border-radius: 3px; background: var(--blush-2); margin-top: 7px; overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--sage); border-radius: 3px; transition: width .4s ease; }

/* ---------- forms ---------- */
.field { width: 100%; height: 50px; border-radius: var(--r-s); border: 1.5px solid var(--line); background: var(--surface); padding: 0 15px;
  font-size: 15px; outline: 0; transition: border-color .2s; }
textarea.field { height: 96px; padding: 13px 15px; resize: none; line-height: 1.4; }
.field:focus { border-color: var(--rose); }
.field.bad { border-color: var(--danger); }
.field::placeholder { color: var(--ink-3); }
label.lbl { display: block; font-size: 12.5px; color: var(--ink-2); font-weight: 600; margin: 14px 0 6px; }
label.lbl:first-child { margin-top: 0; }
.err { color: var(--danger); font-size: 12.5px; margin-top: 6px; font-weight: 600; }
.counter { text-align: right; font-size: 11.5px; color: var(--ink-3); margin-top: 4px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tabs { display: flex; background: var(--blush); border-radius: 14px; padding: 4px; }
.tabs button { flex: 1; height: 40px; border-radius: 11px; font-size: 13.5px; font-weight: 600; color: var(--ink-2); transition: .2s; }
.tabs button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-s); }
.check { display: flex; align-items: center; gap: 10px; font-size: 14px; margin-top: 14px; text-align: left; width: 100%; }
.box { width: 22px; height: 22px; border-radius: 7px; border: 1.5px solid var(--ink-3); display: grid; place-items: center; color: #fff; transition: .2s; flex: none; }
.box svg { width: 14px; height: 14px; opacity: 0; }
.check.on .box { background: var(--rose); border-color: var(--rose); }
.check.on .box svg { opacity: 1; }
.days { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px; }
.days::-webkit-scrollbar { display: none; }
.day { flex: none; width: 64px; padding: 9px 0; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface); text-align: center; transition: .2s; }
.day b { display: block; font-size: 17px; }
.day span { font-size: 10.5px; color: var(--ink-3); font-weight: 600; display: block; }
.day.on { border-color: var(--rose); background: var(--rose-l); }
.day.on span { color: var(--rose-d); }
.slots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
.slot { height: 42px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); font-size: 13px; font-weight: 600; transition: .2s; }
.slot.on { border-color: var(--rose); background: var(--rose-l); color: var(--rose-d); }
.slot:disabled { color: var(--ink-3); background: var(--blush); border-color: var(--blush); text-decoration: line-through; }
.saved { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.saved button { font-size: 12px; padding: 6px 10px; border-radius: 10px; background: var(--blush); color: var(--ink-2); max-width: 100%;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pay { display: flex; align-items: center; gap: 12px; padding: 13px 0; width: 100%; text-align: left; border-top: 1px solid var(--line); }
.pay:first-of-type { border-top: 0; padding-top: 0; }
.pay .radio { width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--ink-3); position: relative; flex: none; margin-left: auto; }
.pay.on .radio { border-color: var(--rose); }
.pay.on .radio::after { content: ""; position: absolute; inset: 4px; border-radius: 50%; background: var(--rose); }
.pay svg { width: 22px; height: 22px; color: var(--ink-2); }
.note { display: flex; gap: 10px; font-size: 12.5px; color: var(--ink-2); background: var(--sage-l); border-radius: 14px; padding: 12px 14px; margin-top: 14px; line-height: 1.45; }
.note svg { width: 18px; height: 18px; color: var(--sage); margin-top: 1px; }

/* ---------- orders ---------- */
.order-card { display: block; width: 100%; text-align: left; background: var(--surface); border-radius: var(--r); padding: 14px; box-shadow: var(--shadow-s); }
.order-card + .order-card { margin-top: 10px; }
.oc-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.oc-top b { font-size: 15px; }
.pill { font-size: 11.5px; font-weight: 700; padding: 5px 10px; border-radius: 10px; background: var(--rose-l); color: var(--rose-d); white-space: nowrap; }
.pill.delivered { background: var(--sage-l); color: #67755F; }
.pill.cancelled { background: var(--blush); color: var(--ink-3); }
.oc-imgs { display: flex; gap: 6px; margin-top: 12px; }
.oc-imgs img { width: 52px; height: 62px; border-radius: 11px; object-fit: cover; background: var(--blush); }
.oc-foot { display: flex; justify-content: space-between; margin-top: 12px; font-size: 13px; color: var(--ink-2); }
.oc-foot strong { color: var(--ink); }
.timeline { position: relative; padding-left: 4px; }
.tl { display: flex; gap: 14px; position: relative; padding-bottom: 18px; }
.tl:last-child { padding-bottom: 0; }
.tl::before { content: ""; position: absolute; left: 10px; top: 24px; bottom: 2px; width: 2px; background: var(--line); }
.tl:last-child::before { display: none; }
.tl.done::before { background: var(--rose); }
.tl .node { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); background: var(--surface); flex: none; display: grid;
  place-items: center; color: #fff; position: relative; z-index: 1; }
.tl .node svg { width: 12px; height: 12px; }
.tl.done .node { background: var(--rose); border-color: var(--rose); }
.tl.now .node { box-shadow: 0 0 0 5px var(--rose-l); }
.tl b { font-size: 14px; display: block; }
.tl .sub { font-size: 12.5px; }
.tl.wait b { color: var(--ink-3); }
.assembled-ph { margin-top: 10px; width: 140px; aspect-ratio: 4/5; border-radius: 14px; object-fit: cover; }
.star-pick { display: flex; gap: 8px; justify-content: center; margin: 4px 0 12px; }
.star-pick button { color: var(--line); transition: transform .15s, color .15s; }
.star-pick button svg { width: 34px; height: 34px; }
.star-pick button.on { color: var(--gold); }
.star-pick button:active { transform: scale(1.2); }

/* ---------- profile ---------- */
.me { display: flex; align-items: center; gap: 14px; padding: 8px 16px 0; }
.ava { width: 62px; height: 62px; border-radius: 50%; background: var(--rose-l); color: var(--rose-d); display: grid; place-items: center;
  font: 600 27px var(--serif); overflow: hidden; flex: none; }
.ava img { width: 100%; height: 100%; object-fit: cover; }
.menu { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow-s); margin: 18px 16px 0; overflow: hidden; }
.menu button { display: flex; align-items: center; gap: 13px; width: 100%; padding: 15px 16px; text-align: left; font-size: 15px; }
.menu button + button { border-top: 1px solid var(--line); }
.menu button > svg:first-child { width: 21px; height: 21px; color: var(--rose); }
.menu .val { margin-left: auto; color: var(--ink-3); font-size: 13px; }
.menu .val + .chev { margin-left: 4px; }
.date-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.date-row:first-of-type { border-top: 0; padding-top: 0; }
.date-badge { width: 46px; height: 50px; border-radius: 12px; background: var(--rose-l); color: var(--rose-d); text-align: center; flex: none; padding-top: 6px; }
.date-badge b { display: block; font-size: 18px; line-height: 1.1; }
.date-badge span { font-size: 10px; font-weight: 700; text-transform: uppercase; }

/* ---------- empty / success ---------- */
.empty { text-align: center; padding: 56px 32px 20px; }
.empty .art { width: 132px; height: 132px; margin: 0 auto 18px; border-radius: 50%; background: var(--blush); display: grid; place-items: center; color: var(--rose); }
.empty .art svg { width: 58px; height: 58px; }
.empty h2 { font: 600 25px var(--serif); margin: 0 0 8px; }
.empty p { margin: 0 0 22px; color: var(--ink-2); font-size: 14px; }
.success { text-align: center; padding: 72px 28px 0; }
.success .ring { width: 104px; height: 104px; margin: 0 auto 24px; border-radius: 50%; background: var(--sage-l); display: grid; place-items: center; animation: ring .5s cubic-bezier(.2, .9, .3, 1.4) both; }
.success .ring svg { width: 46px; height: 46px; color: var(--sage); stroke-dasharray: 30; animation: draw .45s .35s ease both; }
@keyframes ring { from { transform: scale(.4); opacity: 0; } }
@keyframes draw { from { stroke-dashoffset: 30; } }
.success h1 { font: 600 31px/1.1 var(--serif); margin: 0 0 10px; }
.success p { color: var(--ink-2); margin: 0 auto 26px; max-width: 300px; font-size: 14.5px; }
.success .btn + .btn { margin-top: 10px; }

/* ---------- sheet, toast, overlay ---------- */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(59, 51, 48, .32); opacity: 0; transition: opacity .25s; }
.scrim.show { opacity: 1; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: 61; background: var(--bg); border-radius: 26px 26px 0 0;
  padding: 10px 16px calc(var(--safe-b) + 18px); transform: translateY(100%); transition: transform .32s cubic-bezier(.2, .8, .2, 1);
  max-height: 88vh; overflow-y: auto; }
.sheet.show { transform: none; }
.sheet .grip { width: 38px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 16px; }
.sheet h3 { font: 600 24px var(--serif); margin: 0 0 8px; }
.sheet p { color: var(--ink-2); margin: 0 0 18px; font-size: 14px; }
.sheet .btn + .btn { margin-top: 10px; }
#toast { position: fixed; left: 16px; right: 16px; top: calc(var(--top) + 12px); z-index: 80; display: flex; justify-content: center; pointer-events: none; }
#toast div { background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 16px; font-size: 14px; font-weight: 600;
  box-shadow: var(--shadow); animation: toast 2.6s ease both; max-width: 100%; }
@keyframes toast { 0% { opacity: 0; transform: translateY(-10px); } 10%, 85% { opacity: 1; transform: none; } 100% { opacity: 0; } }
.overlay { position: fixed; inset: 0; z-index: 90; background: rgba(250, 246, 242, .92); display: grid; place-items: center; text-align: center; }
.spinner { width: 46px; height: 46px; border-radius: 50%; border: 3px solid var(--rose-l); border-top-color: var(--rose); animation: spin .8s linear infinite; margin: 0 auto 16px; }
@keyframes spin { to { transform: rotate(360deg); } }
.overlay b { font: 600 22px var(--serif); }

#loader { position: fixed; inset: 0; display: grid; place-items: center; background: var(--bg); z-index: 100; transition: opacity .35s; }
#loader .logo { animation: breathe 1.6s ease-in-out infinite; }
@keyframes breathe { 50% { opacity: .45; } }
#loader.gone { opacity: 0; pointer-events: none; }
.footer-note { text-align: center; font-size: 11.5px; color: var(--ink-3); padding: 28px 32px 0; line-height: 1.5; }

@media (min-width: 560px) {
  .grid { grid-template-columns: repeat(3, 1fr); }
  .slide { flex-basis: 70%; }
}

/* typing on a phone: fixed bars would sit over the inputs */
body.kb #nav { display: none; }
body.kb .bar { bottom: var(--kb, 0px); padding-bottom: 10px; }
