/* ---------- фото товара из телефона ---------- */
.photo-row { display: flex; align-items: center; gap: 12px; }
.photo-prev {
  width: 64px; height: 64px; flex: 0 0 64px; border-radius: 16px;
  display: grid; place-items: center; font-size: 28px;
  background: var(--grad-soft);
  overflow: hidden;
}
.photo-prev img { width: 100%; height: 100%; object-fit: cover; }
.photo-prev.is-photo { box-shadow: inset 0 0 0 2px rgba(203, 17, 171, .35); }
.photo-actions { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.photo-actions .btn { width: 100%; }
.photo-file { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
img.art { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }
.prod__img, .item__img, .ord__img, .photo-prev { overflow: hidden; }
.prod__img img, .item__img img, .ord__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* ============================================================
   WB ПВЗ — мобильное приложение пункта выдачи
   ============================================================ */
:root {
  --wb: #cb11ab;
  --wb-2: #7b2ff7;
  --grad: linear-gradient(135deg, #cb11ab 0%, #a114c9 48%, #7b2ff7 100%);
  --grad-soft: linear-gradient(135deg, rgba(203, 17, 171, .1), rgba(123, 47, 247, .1));
  --bg: #f5f3f8;
  --card: #fff;
  --txt: #1a1024;
  --dim: #6b6479;
  --faint: #9b93ab;
  --line: #ece7f3;
  --ok: #12b76a;
  --warn: #f79009;
  --bad: #f04438;
  --r: 18px;
  --r-sm: 12px;
  --sh: 0 2px 10px rgba(26, 16, 36, .06), 0 12px 30px -18px rgba(26, 16, 36, .16);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
svg { display: block; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--bg);
  color: var(--txt);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

body { overflow: hidden; }

.app {
  height: 100dvh;
  display: flex;
  flex-direction: column;
  max-width: 560px;
  margin: 0 auto;
  position: relative;
  background: var(--bg);
}

/* ---------- экран ---------- */
.screen {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-bottom: calc(84px + var(--safe-b));
  scrollbar-width: none;
}
.screen::-webkit-scrollbar { display: none; }

/* ---------- шапка ---------- */
.hdr {
  position: relative;
  padding: calc(12px + var(--safe-t)) 16px 58px;
  background: var(--grad);
  color: #fff;
  border-radius: 0 0 26px 26px;
  overflow: hidden;
}
.hdr::after {
  content: "";
  position: absolute;
  right: -60px;
  top: -60px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .12);
  filter: blur(2px);
}
.hdr::before {
  content: "";
  position: absolute;
  left: -40px;
  bottom: -80px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .08);
}
.hdr__top { display: flex; align-items: center; gap: 10px; position: relative; z-index: 2; }
.hdr__logo {
  width: 38px; height: 38px; border-radius: 12px; flex: 0 0 38px;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, .18);
  font-weight: 800; font-size: 15px; letter-spacing: -.02em;
  backdrop-filter: blur(6px);
}
.hdr__who { flex: 1; min-width: 0; }
.hdr__name { font-size: 15px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hdr__sub { font-size: 11.5px; opacity: .8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hdr__bell {
  width: 38px; height: 38px; flex: 0 0 38px; border: 0; border-radius: 12px;
  background: rgba(255, 255, 255, .18); color: #fff; cursor: pointer;
  display: grid; place-items: center; position: relative;
}
.hdr__bell svg { width: 20px; height: 20px; }
.hdr__bell i {
  position: absolute; top: 8px; right: 9px; width: 7px; height: 7px;
  border-radius: 50%; background: #ffd8a8; box-shadow: 0 0 0 2px rgba(255, 255, 255, .5);
}
.hdr__title { position: relative; z-index: 2; margin-top: 18px; }
.hdr__title h1 { margin: 0; font-size: 26px; line-height: 1.12; letter-spacing: -.02em; font-weight: 800; }
.hdr__title p { margin: 6px 0 0; font-size: 13px; opacity: .82; }

/* ---------- контент ---------- */
.body { padding: 0 14px; margin-top: -42px; position: relative; z-index: 3; }
.body--flat { margin-top: 0; padding-top: 14px; }

.card {
  background: var(--card);
  border-radius: var(--r);
  box-shadow: var(--sh);
  padding: 14px;
  margin-bottom: 12px;
}
.card__head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.card__title { flex: 1; font-size: 14.5px; font-weight: 700; }
.card__more { font-size: 12px; font-weight: 600; color: var(--wb); background: 0; border: 0; cursor: pointer; padding: 4px; }

/* быстрые действия */
.qa { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.qa__i {
  border: 0; cursor: pointer; font: inherit;
  background: var(--card); border-radius: var(--r); box-shadow: var(--sh);
  padding: 13px 8px 11px; display: flex; flex-direction: column; align-items: center; gap: 7px;
  transition: transform .12s;
}
.qa__i:active { transform: scale(.97); }
.qa__ic {
  width: 40px; height: 40px; border-radius: 13px;
  display: grid; place-items: center; color: #fff;
}
.qa__ic svg { width: 21px; height: 21px; }
.qa__ic--1 { background: linear-gradient(135deg, #cb11ab, #7b2ff7); }
.qa__ic--2 { background: linear-gradient(135deg, #7b2ff7, #4b7bff); }
.qa__ic--3 { background: linear-gradient(135deg, #f79009, #f04438); }
.qa__t { font-size: 11.5px; font-weight: 600; color: var(--txt); text-align: center; line-height: 1.15; }

/* статистика */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.stat { background: var(--card); border-radius: var(--r); box-shadow: var(--sh); padding: 12px 10px; text-align: center; }
.stat b { display: block; font-size: 21px; font-weight: 800; letter-spacing: -.02em; }
.stat span { display: block; font-size: 10.5px; color: var(--dim); margin-top: 2px; }
.stat--ok b { color: var(--ok); }
.stat--wb b { color: var(--wb); }

/* список заказов */
.ord {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.ord:last-child { border-bottom: 0; padding-bottom: 0; }
.ord:first-child { padding-top: 0; }
.ord__img {
  width: 46px; height: 46px; flex: 0 0 46px; border-radius: 12px;
  display: grid; place-items: center; font-size: 22px;
  background: var(--grad-soft);
}
.ord__main { flex: 1; min-width: 0; }
.ord__name { font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ord__sub { font-size: 11.5px; color: var(--dim); margin-top: 2px; }
.ord__right { text-align: right; }
.ord__code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 14px; font-weight: 700; letter-spacing: .06em; color: var(--wb);
}
.ord__days { font-size: 10.5px; color: var(--faint); margin-top: 2px; }
.ord__days.is-warn { color: var(--warn); font-weight: 600; }
.ord__days.is-bad { color: var(--bad); font-weight: 600; }

/* ---------- нижние вкладки ---------- */
.tabs {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: calc(66px + var(--safe-b));
  padding-bottom: var(--safe-b);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
  z-index: 30;
}
.tab {
  border: 0; background: 0; cursor: pointer; font: inherit;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  color: var(--faint);
  transition: color .18s;
  padding: 0;
}
.tab svg { width: 22px; height: 22px; }
.tab span { font-size: 9.5px; font-weight: 600; letter-spacing: .01em; }
.tab.is-on { color: var(--wb); }
.tab.is-on svg { transform: translateY(-1px); }
.tab__dot {
  position: absolute; top: 10px; right: 50%; margin-right: -16px;
  width: 6px; height: 6px; border-radius: 50%; background: var(--bad);
}

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 50px; padding: 0 18px;
  border: 0; border-radius: 15px; cursor: pointer;
  font: inherit; font-size: 15px; font-weight: 700;
  background: var(--grad); color: #fff;
  box-shadow: 0 8px 22px -12px rgba(203, 17, 171, .7);
  transition: transform .12s, opacity .2s;
}
.btn:active { transform: scale(.985); }
.btn:disabled { opacity: .45; box-shadow: none; cursor: default; }
.btn--ghost { background: #fff; color: var(--txt); box-shadow: inset 0 0 0 1px var(--line); }
.btn--soft { background: var(--grad-soft); color: var(--wb); box-shadow: none; }
.btn--danger { background: #fff; color: var(--bad); box-shadow: inset 0 0 0 1px #f6cdc9; }
.btn--sm { min-height: 40px; font-size: 13px; border-radius: 12px; width: auto; padding: 0 14px; }
.btn svg { width: 19px; height: 19px; flex: 0 0 19px; }
.btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }

/* ---------- вкладки-сегменты ---------- */
.seg {
  display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  gap: 4px; padding: 4px; background: #ece7f3; border-radius: 14px; margin-bottom: 12px;
}
.seg button {
  border: 0; background: 0; cursor: pointer; font: inherit;
  font-size: 12.5px; font-weight: 600; color: var(--dim);
  padding: 9px 6px; border-radius: 11px; transition: background .2s, color .2s, box-shadow .2s;
}
.seg button.is-on { background: #fff; color: var(--txt); box-shadow: 0 2px 8px rgba(26, 16, 36, .1); }

/* ---------- код выдачи ---------- */
.code-boxes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; margin: 4px 0 14px; }
.code-box {
  height: 62px; border-radius: 16px;
  border: 2px solid var(--line); background: #fff;
  display: grid; place-items: center;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 26px; font-weight: 700;
  color: var(--txt);
  transition: border-color .2s, box-shadow .2s, transform .12s;
}
.code-box.is-on { border-color: var(--wb); box-shadow: 0 0 0 4px rgba(203, 17, 171, .12); }
.code-box.is-bad { border-color: var(--bad); animation: shake .35s; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}
.code-input {
  position: absolute; opacity: 0; pointer-events: none;
  width: 1px; height: 1px;
}

/* поле ввода */
.input {
  width: 100%; height: 52px; padding: 0 14px;
  border-radius: 14px; border: 1.5px solid var(--line);
  background: #fff; color: var(--txt); font: inherit; font-size: 15px;
  transition: border-color .2s, box-shadow .2s;
}
.input:focus { outline: none; border-color: var(--wb); box-shadow: 0 0 0 4px rgba(203, 17, 171, .1); }
.input::placeholder { color: var(--faint); }

/* ---------- карточка заказа ---------- */
.item {
  display: flex; gap: 10px; align-items: center;
  padding: 9px 0; border-bottom: 1px dashed var(--line);
}
.item:last-of-type { border-bottom: 0; }
.item__img {
  width: 54px; height: 54px; flex: 0 0 54px; border-radius: 13px;
  display: grid; place-items: center; font-size: 25px;
  background: var(--grad-soft);
}
.item__main { flex: 1; min-width: 0; }
.item__name { font-size: 13.5px; font-weight: 600; }
.item__meta { font-size: 11.5px; color: var(--dim); margin-top: 2px; }
.item__price { font-size: 14px; font-weight: 700; white-space: nowrap; }

.rows { display: grid; gap: 8px; }
.row { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; }
.row span { color: var(--dim); }
.row b { font-weight: 700; }
.row--total { padding-top: 10px; border-top: 1px solid var(--line); font-size: 15px; }
.row--total b { color: var(--wb); }

/* чипы */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 5px 10px; border-radius: 999px;
  font-size: 11px; font-weight: 600;
  background: #f1edf7; color: var(--dim);
}
.chip--ok { background: rgba(18, 183, 106, .12); color: var(--ok); }
.chip--warn { background: rgba(247, 144, 9, .13); color: #b54708; }
.chip--bad { background: rgba(240, 68, 56, .12); color: var(--bad); }
.chip--wb { background: rgba(203, 17, 171, .1); color: var(--wb); }

/* ---------- приёмка ---------- */
.acc-item {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 0; border-bottom: 1px solid var(--line);
}
.acc-item:last-child { border-bottom: 0; }
.acc-item__main { flex: 1; min-width: 0; }
.acc-item__name { font-size: 13.5px; font-weight: 600; }
.acc-item__sku { font-size: 11px; color: var(--faint); font-family: ui-monospace, Menlo, monospace; }
.stepper { display: flex; align-items: center; gap: 8px; }
.stepper button {
  width: 32px; height: 32px; border-radius: 10px; border: 0; cursor: pointer;
  background: #f1edf7; color: var(--txt); font-size: 18px; font-weight: 700; line-height: 1;
  display: grid; place-items: center;
}
.stepper button:active { transform: scale(.94); }
.stepper b { min-width: 22px; text-align: center; font-size: 15px; }
.defect {
  width: 34px; height: 34px; flex: 0 0 34px; border-radius: 10px; border: 1.5px solid var(--line);
  background: #fff; cursor: pointer; display: grid; place-items: center; color: var(--faint);
}
.defect svg { width: 17px; height: 17px; }
.defect.is-on { border-color: var(--bad); background: rgba(240, 68, 56, .1); color: var(--bad); }

/* прогресс */
.prog { height: 8px; border-radius: 5px; background: #ece7f3; overflow: hidden; }
.prog i { display: block; height: 100%; width: 0; border-radius: 5px; background: var(--grad); transition: width .35s; }

/* ---------- сканер ---------- */
.scan {
  position: fixed; inset: 0; z-index: 80;
  background: #100a18;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  animation: fadeIn .25s both;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.scan__frame {
  position: relative;
  width: min(250px, 68vw); aspect-ratio: 1;
  border-radius: 24px;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, .35) inset;
  overflow: hidden;
}
.scan__frame::before, .scan__frame::after {
  content: "";
  position: absolute; width: 34px; height: 34px;
  border: 3px solid #fff; border-radius: 6px;
}
.scan__frame::before { top: 10px; left: 10px; border-right: 0; border-bottom: 0; }
.scan__frame::after { bottom: 10px; right: 10px; border-left: 0; border-top: 0; }
.scan__laser {
  position: absolute; left: 8%; right: 8%; height: 3px; border-radius: 2px;
  background: linear-gradient(90deg, transparent, #ff3d81, transparent);
  box-shadow: 0 0 18px 2px rgba(255, 61, 129, .8);
  animation: laser 1.9s ease-in-out infinite;
}
@keyframes laser {
  0%, 100% { top: 14%; }
  50% { top: 84%; }
}
.scan__txt { margin-top: 22px; color: #fff; font-size: 14px; opacity: .85; }
.scan__sub { margin-top: 6px; color: rgba(255, 255, 255, .5); font-size: 12px; }
.scan__close {
  position: absolute; top: calc(14px + var(--safe-t)); right: 14px;
  width: 40px; height: 40px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(255, 255, 255, .14); color: #fff; font-size: 18px;
}

/* ---------- успех ---------- */
.done {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 26px 10px 8px;
}
.done__ic {
  width: 84px; height: 84px; border-radius: 50%;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, #12b76a, #0a9e5a);
  box-shadow: 0 16px 36px -14px rgba(18, 183, 106, .8);
  animation: popIn .45s cubic-bezier(.2, 1.3, .4, 1) both;
}
.done__ic svg { width: 40px; height: 40px; }
@keyframes popIn { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: none; } }
.done h2 { margin: 16px 0 4px; font-size: 21px; letter-spacing: -.02em; }
.done p { margin: 0; color: var(--dim); font-size: 13px; }

/* ---------- заметка ---------- */
.note {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; border-radius: 14px;
  background: #f1edf7; color: var(--dim);
  font-size: 12px; line-height: 1.35;
  margin-bottom: 12px;
}
.note svg { width: 18px; height: 18px; flex: 0 0 18px; color: var(--wb); }
.note--warn { background: rgba(247, 144, 9, .12); color: #8a4b00; }
.note--warn svg { color: var(--warn); }

/* ---------- чек выдачи ---------- */
.receipt {
  background: #fff;
  border-radius: 16px;
  padding: 16px 16px 14px;
  box-shadow: var(--sh);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12.5px;
  color: #2a2233;
  animation: receiptIn .45s cubic-bezier(.2, .9, .3, 1) both;
}
@keyframes receiptIn {
  from { opacity: 0; transform: translateY(14px) scale(.98); }
  to { opacity: 1; transform: none; }
}
.receipt__head { text-align: center; font-weight: 700; letter-spacing: .02em; }
.receipt__sub { text-align: center; color: #8b8398; font-size: 11px; margin-top: 2px; }
.receipt__sep { border-top: 1px dashed #d6cfe0; margin: 10px 0; }
.receipt__row { display: flex; justify-content: space-between; gap: 10px; padding: 2px 0; }
.receipt__row span:first-child { color: #5f566f; }
.receipt__total {
  display: flex; justify-content: space-between; gap: 10px;
  font-weight: 700; font-size: 14.5px; color: var(--txt);
  margin-top: 6px; padding-top: 8px; border-top: 1px dashed #d6cfe0;
}
.receipt__foot { text-align: center; color: #8b8398; font-size: 11px; margin-top: 10px; }

/* ---------- уведомления ---------- */
.notif-list { display: grid; gap: 8px; }
.notif {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 12px; border-radius: 14px;
  background: #f7f5fa;
}
.notif__ic {
  width: 36px; height: 36px; flex: 0 0 36px; border-radius: 11px;
  display: grid; place-items: center;
  background: rgba(203, 17, 171, .1); color: var(--wb);
}
.notif__ic svg { width: 18px; height: 18px; }
.notif__ic.is-ok { background: rgba(18, 183, 106, .12); color: var(--ok); }
.notif__ic.is-warn { background: rgba(247, 144, 9, .14); color: var(--warn); }
.notif__main { flex: 1; min-width: 0; }
.notif__t { font-size: 13px; font-weight: 600; }
.notif__s { font-size: 11px; color: var(--faint); margin-top: 1px; }

/* ---------- регистрация ---------- */
.screen.is-onb { padding-bottom: 0; overflow: hidden; }
.screen.is-onb .page, .screen.is-onb .onb { height: 100%; min-height: 100%; }
.onb {
  min-height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 34px 22px calc(30px + var(--safe-b));
  background: var(--grad);
  color: #fff;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.onb::before {
  content: ""; position: absolute; width: 320px; height: 320px; border-radius: 50%;
  background: rgba(255, 255, 255, .1); top: -120px; right: -110px;
}
.onb::after {
  content: ""; position: absolute; width: 260px; height: 260px; border-radius: 50%;
  background: rgba(255, 255, 255, .08); bottom: -120px; left: -90px;
}
.onb__logo {
  width: 66px; height: 66px; border-radius: 20px; flex: 0 0 66px;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, .18); backdrop-filter: blur(8px);
  font-size: 26px; font-weight: 800; letter-spacing: -.02em;
  margin-bottom: 22px; position: relative; z-index: 2;
  animation: popIn .5s cubic-bezier(.2, 1.3, .4, 1) both;
}
.onb h1 { margin: 0 0 8px; font-size: 26px; letter-spacing: -.02em; position: relative; z-index: 2; }
.onb p { margin: 0 0 22px; font-size: 13.5px; opacity: .85; line-height: 1.45; max-width: 300px; position: relative; z-index: 2; }
.onb__input {
  width: 100%; height: 58px; padding: 0 16px;
  border-radius: 16px; border: 2px solid rgba(255, 255, 255, .35);
  background: rgba(255, 255, 255, .16); color: #fff;
  font: inherit; font-size: 19px; font-weight: 600; text-align: center;
  position: relative; z-index: 2; backdrop-filter: blur(6px);
  transition: border-color .2s, background .2s;
}
.onb__input::placeholder { color: rgba(255, 255, 255, .6); font-weight: 500; }
.onb__input:focus { outline: none; border-color: #fff; background: rgba(255, 255, 255, .24); }
.onb__btn {
  margin-top: 14px; position: relative; z-index: 2;
  background: #fff; color: var(--wb);
  box-shadow: 0 14px 30px -14px rgba(0, 0, 0, .45);
}
.onb__btn:disabled { opacity: .5; box-shadow: none; }
.onb__label {
  width: 100%; max-width: 360px; text-align: left;
  font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase;
  opacity: .8; margin-bottom: 6px; position: relative; z-index: 2;
}
.onb__reset {
  margin-top: 26px; position: relative; z-index: 2;
  background: 0; border: 0; cursor: pointer;
  color: rgba(255, 255, 255, .7); font: inherit; font-size: 12px;
  text-decoration: underline; text-underline-offset: 3px;
}
.onb__hint { margin-top: 16px; font-size: 11.5px; opacity: .7; position: relative; z-index: 2; }

/* ---------- трек заказа ---------- */
.track { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; margin: 12px 0; }
.track__step { display: flex; flex-direction: column; align-items: center; gap: 5px; position: relative; }
.track__step i {
  width: 12px; height: 12px; border-radius: 50%;
  background: #e6e0ef; box-shadow: inset 0 0 0 2px #fff;
  position: relative; z-index: 2;
}
.track__step span { font-size: 10px; color: var(--faint); font-weight: 600; }
.track__step.is-done i { background: var(--wb); }
.track__step.is-done span { color: var(--txt); }
.track__step::before {
  content: ""; position: absolute; top: 5px; left: -50%; width: 100%; height: 2px; background: #e6e0ef; z-index: 1;
}
.track__step:first-child::before { display: none; }
.track__step.is-done::before { background: rgba(203, 17, 171, .45); }

/* ---------- код для получения ---------- */
.code-big {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 40px; font-weight: 800; letter-spacing: .1em;
  text-align: center; color: var(--wb);
  margin: 4px 0 6px;
}
.qr-wrap { display: grid; place-items: center; margin: 4px 0 8px; }
.qr-wrap canvas { width: min(228px, 62vw); height: auto; border-radius: 12px; background: #fff; box-shadow: 0 0 0 1px var(--line); image-rendering: pixelated; }
.qr-grid {
  display: grid; gap: 2px; width: 160px; margin: 0 auto;
  padding: 8px; background: #fff; border-radius: 12px;
  box-shadow: 0 0 0 1px var(--line);
}
.qr-grid i { aspect-ratio: 1; border-radius: 2px; }

/* ---------- человек ---------- */
.person { display: flex; align-items: center; gap: 12px; }
.person__avatar {
  width: 54px; height: 54px; flex: 0 0 54px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--grad); color: #fff;
  font-size: 21px; font-weight: 800;
  box-shadow: 0 10px 22px -10px rgba(203, 17, 171, .7);
}
.person__main { flex: 1; min-width: 0; }
.person__name { font-size: 17px; font-weight: 800; letter-spacing: -.01em; }
.person__sub { font-size: 11.5px; color: var(--dim); margin-top: 2px; }

/* ---------- каталог ---------- */
.catalog { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.prod {
  background: #fff; border-radius: var(--r); box-shadow: var(--sh);
  padding: 12px; display: flex; flex-direction: column; gap: 6px;
}
.prod__img {
  height: 86px; border-radius: 13px;
  display: grid; place-items: center; font-size: 38px;
  background: var(--grad-soft);
}
.prod__name {
  font-size: 12.5px; font-weight: 600; line-height: 1.25; min-height: 32px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.prod__price { font-size: 15px; font-weight: 800; }
.prod__btn { width: 100%; }

/* ---------- выбор роли ---------- */
.who { display: grid; gap: 10px; width: 100%; max-width: 360px; position: relative; z-index: 2; }
.who__i {
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
  padding: 16px 16px 14px; border-radius: 18px; border: 2px solid rgba(255, 255, 255, .3);
  background: rgba(255, 255, 255, .14); backdrop-filter: blur(8px);
  color: #fff; font: inherit; text-align: left; cursor: pointer;
  transition: background .2s, border-color .2s, transform .12s;
}
.who__i:active { transform: scale(.985); }
.who__i:hover { background: rgba(255, 255, 255, .22); }
.who__ic {
  width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center;
  background: rgba(255, 255, 255, .22); margin-bottom: 4px;
}
.who__ic svg { width: 21px; height: 21px; }
.who__i b { font-size: 16px; font-weight: 800; }
.who__i span:last-child { font-size: 12px; opacity: .82; line-height: 1.3; }

.onb__back {
  margin-top: 16px; background: 0; border: 0; color: rgba(255, 255, 255, .8);
  font: inherit; font-size: 12.5px; cursor: pointer; position: relative; z-index: 2;
}

/* ---------- каталог: свой товар ---------- */
.add-prod {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 46px; margin-bottom: 12px;
  border-radius: 14px; border: 1.5px dashed rgba(203, 17, 171, .45);
  background: rgba(203, 17, 171, .06); color: var(--wb);
  font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer;
}
.add-prod svg { width: 17px; height: 17px; }
.prod { position: relative; }
.prod__add {
  position: absolute; right: 8px; top: 8px;
  width: 34px; height: 34px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--grad); color: #fff; display: grid; place-items: center;
  box-shadow: 0 8px 18px -8px rgba(203, 17, 171, .9);
  transition: transform .12s;
}
.prod__add:active { transform: scale(.9); }
.prod__add svg { width: 18px; height: 18px; }

.emoji-grid { display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; }
.emoji {
  aspect-ratio: 1; border-radius: 9px; border: 1.5px solid transparent;
  background: #f4f1f8; font-size: 17px; cursor: pointer; display: grid; place-items: center;
  padding: 0;
}
.emoji.is-on { border-color: var(--wb); background: rgba(203, 17, 171, .1); }
.input-label { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); margin-bottom: 6px; }

/* ---------- корзина ---------- */
.cart-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--line);
}
.cart-row:last-of-type { border-bottom: 0; }
.cart-row__main { flex: 1; min-width: 0; }
.cart-row__name { font-size: 13px; font-weight: 600; }
.cart-row__price { font-size: 12.5px; color: var(--dim); margin-top: 2px; }

/* ---------- приёмка ---------- */
.arr-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--line);
}
.arr-row:last-child { border-bottom: 0; }

/* ---------- бейдж на вкладке ---------- */
.tab { position: relative; }
.tab__badge {
  position: absolute; top: 7px; right: 50%; margin-right: -18px;
  min-width: 16px; height: 16px; padding: 0 4px;
  border-radius: 8px; background: var(--bad); color: #fff;
  font-size: 10px; font-weight: 700; line-height: 16px; text-align: center;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, .9);
}

/* ---------- трек на 4 шага ---------- */
.track--4 .track__step span { font-size: 9px; }
.track--4 .track__step i { width: 10px; height: 10px; }

/* ---------- сканер с камерой ---------- */
.scan__video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; background: #100a18;
}
.scan__mask {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, rgba(16, 10, 24, 0) 32%, rgba(16, 10, 24, .78) 68%);
  pointer-events: none;
}
.scan__head {
  position: absolute; top: calc(62px + var(--safe-t)); left: 0; right: 0;
  text-align: center; color: #fff; z-index: 3; padding: 0 20px;
}
.scan__head b { display: block; font-size: 16px; }
.scan__head span { display: block; font-size: 12px; opacity: .75; margin-top: 4px; }
.scan__frame { position: relative; z-index: 3; }
.scan__panel {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 4;
  padding: 16px 16px calc(20px + var(--safe-b));
  background: linear-gradient(180deg, rgba(16, 10, 24, 0), rgba(16, 10, 24, .92) 34%);
  display: flex; flex-direction: column; gap: 9px;
}
.scan__or { text-align: center; color: rgba(255, 255, 255, .6); font-size: 11.5px; }
.scan__row { display: flex; gap: 8px; width: 100%; }
.scan__input { min-width: 0; }
.scan__input {
  flex: 1; height: 48px; padding: 0 16px; border-radius: 14px;
  border: 1.5px solid rgba(255, 255, 255, .3); background: rgba(255, 255, 255, .14);
  color: #fff; font: inherit; font-size: 19px; font-weight: 700; text-align: center;
  letter-spacing: .14em;
}
.scan__input::placeholder { color: rgba(255, 255, 255, .5); font-size: 13px; letter-spacing: .04em; font-weight: 500; }
.scan__input:focus { outline: none; border-color: #fff; background: rgba(255, 255, 255, .22); }
.scan__row .btn { width: auto; min-width: 92px; flex: 0 0 auto; padding: 0 14px; }
.scan.is-nocam .scan__video { opacity: .25; }
.scan.is-nocam .scan__frame { opacity: .5; }

/* ---------- отзыв ---------- */
.stars { display: inline-flex; gap: 2px; }
.stars i { font-style: normal; color: #d8d1e4; font-size: 13px; }
.stars i.is-on { color: #f5a623; }
.stars--big { display: flex; justify-content: center; gap: 6px; margin: 6px 0; }
.star {
  border: 0; background: 0; cursor: pointer; padding: 4px;
  font-size: 34px; line-height: 1; color: #ddd6e8;
  transition: color .15s, transform .12s;
}
.star.is-on { color: #f5a623; }
.star:active { transform: scale(.9); }
.review {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; border-radius: 13px;
  background: rgba(245, 166, 35, .1);
  font-size: 12px; color: #8a5a00;
}

/* ---------- нижняя шторка ---------- */
.modal {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: flex-end; justify-content: center;
  background: rgba(20, 10, 30, 0);
  transition: background .25s;
}
.modal.is-on { background: rgba(20, 10, 30, .45); }
.modal__card {
  width: 100%; max-width: 560px;
  background: #fff;
  border-radius: 22px 22px 0 0;
  padding: 8px 16px calc(18px + var(--safe-b));
  max-height: 84dvh;
  display: flex; flex-direction: column;
  transform: translateY(100%);
  transition: transform .3s cubic-bezier(.2, .9, .3, 1);
  box-shadow: 0 -20px 50px -20px rgba(20, 10, 30, .4);
}
.modal.is-on .modal__card { transform: none; }
.modal__grab { width: 40px; height: 4px; border-radius: 2px; background: #dcd5e6; margin: 2px auto 10px; }
.modal__head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.modal__title { flex: 1; font-size: 16px; font-weight: 700; }
.modal__x {
  width: 32px; height: 32px; flex: 0 0 32px; border-radius: 50%; border: 0; cursor: pointer;
  background: #f1edf7; color: var(--dim); font-size: 14px;
}
.modal__body { overflow-y: auto; }

/* ---------- тосты ---------- */
.toasts {
  position: fixed; left: 0; right: 0; top: calc(10px + var(--safe-t));
  z-index: 120; display: flex; flex-direction: column; align-items: center; gap: 8px;
  pointer-events: none; padding: 0 14px;
}
.toast {
  display: flex; align-items: center; gap: 9px;
  max-width: 460px; width: 100%;
  padding: 11px 14px; border-radius: 14px;
  background: #1a1024; color: #fff; font-size: 13px; font-weight: 600;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .6);
  animation: toastIn .35s cubic-bezier(.2, 1.2, .4, 1) both;
}
.toast.is-out { animation: toastOut .3s ease-in both; }
.toast svg { width: 18px; height: 18px; flex: 0 0 18px; }
.toast--ok { background: #0e7a4a; }
.toast--bad { background: #a92320; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-14px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(-10px); } }

/* ---------- разное ---------- */
.muted { color: var(--dim); font-size: 12.5px; }
.center { text-align: center; }
.stack { display: grid; gap: 10px; }
.spacer { flex: 1; }
.hidden { display: none !important; }

.empty {
  text-align: center; padding: 30px 10px; color: var(--faint); font-size: 13px;
}
.empty svg { width: 44px; height: 44px; opacity: .5; margin-bottom: 8px; }

@media (min-width: 600px) {
  .app { box-shadow: 0 0 60px -20px rgba(26, 16, 36, .25); }
}
