/* Basket editor: search, categories, product cards, basket dock. */
/* ---------- search & products ---------- */
.search {
  display: flex; align-items: center; gap: var(--s2); background: var(--surface); border-radius: var(--r-pill);
  padding: 0 var(--s4); min-height: 54px; box-shadow: var(--shadow), inset 0 0 0 2px transparent; transition: box-shadow .2s;
}
.search:focus-within { box-shadow: var(--shadow), inset 0 0 0 2px var(--purple-300); }
.search svg { width: 22px; height: 22px; color: var(--ink-3); flex: none; }
.search input { border: 0; outline: 0; background: transparent; flex: 1; min-width: 0; font-size: 16px; padding: 14px 0; }
.search .clear { border: 0; background: var(--lilac-50); border-radius: 50%; width: 28px; height: 28px; font-weight: 800; color: var(--purple); }
.cats { display: flex; gap: var(--s2); overflow-x: auto; padding: 2px; margin: 0 -2px; }
.cats::-webkit-scrollbar { display: none; }
.cat { border: 0; flex: none; border-radius: var(--r-pill); padding: 8px 14px; background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--line); font-weight: 700; font-size: 14px; display: inline-flex; gap: 6px; align-items: center; }
.cat[aria-pressed="true"] { background: var(--purple); color: #fff; box-shadow: none; }
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s2); }
.tile { border: 0; background: var(--surface); border-radius: var(--r); padding: var(--s3) 4px; display: flex; flex-direction: column; align-items: center; gap: 4px; box-shadow: var(--shadow); min-width: 0; position: relative; }
.tile .e { font-size: 34px; line-height: 1.1; filter: drop-shadow(0 5px 5px rgba(0,0,0,.12)); }
.tile .l { font-size: 12.5px; font-weight: 700; text-align: center; line-height: 1.2; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.tile .in { position: absolute; top: 6px; inset-inline-end: 6px; min-width: 20px; height: 20px; border-radius: 10px; background: var(--purple); color: #fff; font-size: 11.5px; font-weight: 800; display: grid; place-items: center; padding: 0 5px; }
.promo-banner { border-radius: var(--r); background: linear-gradient(100deg, var(--mint-50), #CFF3E1); padding: var(--s4); display: flex; align-items: center; gap: var(--s3); }
.promo-banner b { font-size: 18px; display: block; }
.promo-banner span { font-size: 13px; color: var(--ink-2); }
.promo-banner .e { font-size: 44px; margin-inline-start: auto; }

.plist { display: grid; gap: var(--s2); }
.pcard { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: var(--s3); display: flex; align-items: center; gap: var(--s3); }
.pcard .img { width: 56px; height: 56px; border-radius: 14px; background: var(--lilac-50); display: grid; place-items: center; font-size: 32px; flex: none; }
.pcard .meta { flex: 1; min-width: 0; }
.pcard .nm { font-weight: 700; font-size: 14.5px; line-height: 1.25; }
.pcard .br { font-size: 12.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pcard .pr { font-size: 12.5px; color: var(--ink-2); margin-top: 2px; }
.pcard .pr b { color: var(--ink); }
.stepper { display: inline-flex; align-items: center; gap: 2px; background: var(--lilac-50); border-radius: var(--r-pill); padding: 3px; flex: none; }
.stepper button { width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--surface); color: var(--purple); font-size: 20px; font-weight: 800; line-height: 1; box-shadow: 0 1px 3px rgba(60,30,140,.12); }
.stepper .q { min-width: 24px; text-align: center; font-weight: 800; }
.add-btn { width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--purple); color: #fff; font-size: 24px; font-weight: 800; flex: none; box-shadow: 0 6px 14px rgba(101, 37, 245, .3); }
.add-btn:active { transform: scale(.92); }
.empty-res { text-align: center; color: var(--ink-2); padding: var(--s6) 0; }

/* ---------- basket dock ---------- */
.dock {
  position: fixed; z-index: 20; left: 50%; transform: translateX(-50%); width: 100%; max-width: 440px;
  bottom: calc(var(--nav-h) + env(safe-area-inset-bottom, 0px));
  padding: var(--s3) max(16px, env(safe-area-inset-right, 0px)) var(--s3) max(16px, env(safe-area-inset-left, 0px));
  background: var(--bg); border-radius: var(--r-lg) var(--r-lg) 0 0;
  box-shadow: 0 -10px 24px rgba(60, 30, 140, .08);
}
.dock .bar { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); margin-bottom: var(--s2); }
.dock .bar b { font-size: 16px; }
.dock .thumbs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: var(--s2); }
.dock .thumbs::-webkit-scrollbar { display: none; }
.dock .th { flex: none; position: relative; width: 46px; height: 46px; border-radius: 12px; background: var(--surface); box-shadow: var(--shadow); display: grid; place-items: center; font-size: 24px; }
.dock .th small { position: absolute; bottom: -4px; inset-inline-end: -4px; background: var(--ink); color: #fff; font-size: 10.5px; font-weight: 800; min-width: 18px; height: 18px; border-radius: 9px; display: grid; place-items: center; padding: 0 4px; }
.bump { animation: bump .35s ease-out; }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.18); } 100% { transform: scale(1); } }

