/* «Мои планы» (вкладки «Хочу · Решаем · Иду · Места») и страница голосования. */
.saved, .places, .poll-page { display: flex; flex-direction: column; gap: 14px; padding: calc(12px + var(--safe-t)) 16px calc(var(--tabbar-h) + 24px); }
.plans-top { display: flex; align-items: center; justify-content: space-between; }
/* переключатель-капсула (как на досках): тёмная дорожка, выбранное — лавандовое */
.plan-tabs, .seg2 { display: flex; gap: 2px; padding: 4px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.plan-tabs::-webkit-scrollbar, .seg2::-webkit-scrollbar { display: none; }
.plan-tabs a, .seg2 > * { flex: 1 0 auto; display: inline-flex; align-items: center; justify-content: center; min-height: 38px; padding: 0 12px; border-radius: 999px; font-size: 13.5px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.plan-tabs a.on, .seg2 > .on { background: var(--lavender); color: var(--on-accent); }
.plan-note { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 10px 14px; border-radius: 14px; font-weight: 600; background: color-mix(in srgb, var(--coral) 14%, var(--surface)); border: 1px solid color-mix(in srgb, var(--coral) 35%, var(--line)); }
.plan-note svg { width: 20px; height: 20px; }
.plan-note svg:first-child { color: var(--coral); }
.plan-note span { flex: 1; }
.poll-hint { margin: -4px 0 0; color: var(--muted); font-size: 13px; line-height: 1.4; }
.back-feed { display: inline-flex; align-items: center; gap: 2px; align-self: flex-start; min-height: 36px; margin-left: -6px; font-size: 14px; font-weight: 600; color: var(--lavender); }
.back-feed svg { width: 20px; height: 20px; }

/* список планов */
.saved-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.saved-list li { display: flex; align-items: center; gap: 12px; padding: 10px 10px 10px 10px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
.pr-ph { flex: none; width: 76px; height: 76px; display: grid; place-items: center; border-radius: 12px; color: var(--muted); background: var(--img, none) center / cover, var(--raised); }
.pr-ph svg { width: 22px; height: 22px; }
.saved-list li > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.saved-list li > div > b { font-weight: 700; font-size: 15px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.saved-list small { color: var(--muted); font-size: 12.5px; }
.saved-list li.past > div > b, .saved-list li.past > div > small { opacity: .7; }
.saved-list li.grp { padding: 12px 2px 2px; background: none; border: 0; justify-content: space-between; font: 700 18px var(--f-body); color: var(--ink); }
.saved-list li.grp i { font-style: normal; font-weight: 500; font-size: 15px; color: var(--muted); margin-left: 6px; }
.saved-list li.empty { flex-direction: column; gap: 8px; padding: 12px 20px 28px; text-align: center; color: var(--muted); background: none; border: 0; box-shadow: none; }
.saved-list li.empty b { color: var(--ink); font: 800 26px/1.05 var(--f-head); }
.saved-list li.empty .pill { margin-top: 6px; }
.saved-list li[data-id] { touch-action: pan-y; transition: transform .18s, opacity .18s; }
.saved-list li.swiping { transition: none; box-shadow: 12px 0 0 -2px color-mix(in srgb, var(--danger) 55%, transparent); }
.saved-list li.gone { transform: translateX(-110%) !important; opacity: 0; }
.saved-list.picking li[data-id]:not(.past) { cursor: pointer; }
.saved-list.picking li.on { border-color: var(--lavender); background: color-mix(in srgb, var(--lavender) 14%, var(--surface)); }
.saved-list.picking li.on b::before { content: "✓ "; color: var(--lavender); }
.saved-list.picking.has-bar { margin-bottom: 84px; }
.mini { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; font-size: 15px; background: var(--raised); color: var(--muted); }
.mini svg { width: 18px; height: 18px; }
.clear-past { min-height: 32px; padding: 0 12px; border-radius: 99px; font-size: 12.5px; font-weight: 600; color: var(--danger); background: color-mix(in srgb, var(--danger) 12%, transparent); }
.went-q { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.went-q button { min-width: 44px; height: 36px; padding: 0 10px; border-radius: 18px; background: var(--raised); border: 1px solid var(--line); font-size: 13px; font-weight: 600; }
.went-q button[data-rate="skip"] { color: var(--muted); }
.been { flex: none; height: 36px; padding: 0 12px; border-radius: 18px; background: var(--raised); border: 1px solid var(--line); font-size: 13px; font-weight: 600; }
.went-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.went-list li { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); }
.went-list li > b { font-size: 22px; }
.went-list li div { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.went-list li span { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.went-list li small { color: var(--muted); font-size: 12px; }

/* панель выбора: «Убрать · 2», «Голосование · 2» */
.poll-bar { position: fixed; z-index: 15; left: 50%; bottom: calc(var(--tabbar-h) + 10px); transform: translateX(-50%); width: min(448px, calc(100% - 32px)); display: flex; gap: 8px; }
.poll-bar[hidden] { display: none; }
.poll-bar button { flex: 1; min-height: 50px; padding: 0 12px; border-radius: 14px; font-weight: 700; box-shadow: var(--shadow); }
.poll-bar .ghost { flex: .6; background: var(--raised); border: 1px solid var(--line); }
.poll-bar .x { flex: none; width: 50px; }
.poll-bar .del { color: var(--danger); }
.poll-bar .go { background: var(--lavender); color: var(--on-accent); }
.poll-bar .go[hidden] { display: none; }
.poll-bar .go:disabled { opacity: .55; }

/* мои голосования */
.my-polls { display: flex; flex-direction: column; gap: 8px; }
.my-polls[hidden] { display: none; }
.my-polls:not([hidden]) + .polls-empty { display: none; }
.mypoll-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.mypoll-list li { display: flex; align-items: center; gap: 10px; padding: 12px 10px 12px 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--lavender); cursor: pointer; touch-action: pan-y; transition: transform .18s, opacity .18s; }
.mypoll-list li div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.mypoll-list li b { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mypoll-list li small { color: var(--muted); font-size: 12px; }
.mypoll-list .faces { flex: none; }
.mypoll-list li.swiping { transition: none; box-shadow: 12px 0 0 -2px color-mix(in srgb, var(--danger) 55%, transparent); }
.mypoll-list li.gone { transform: translateX(-110%) !important; opacity: 0; }
.me-h { margin: 6px 0 0; font: 700 20px/1.2 var(--f-body); }
.me-h i { font-style: normal; color: var(--muted); font-size: 15px; margin-left: 4px; }
.me-hint { margin: -6px 0 0; color: var(--muted); font-size: 13px; }

/* страница голосования «Куда идём?» */
.poll-start { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 16px; border-radius: 16px; text-align: left; font-size: 24px; background: var(--surface); border: 1px solid var(--line); }
.poll-start span { display: flex; flex-direction: column; gap: 2px; }
.poll-start b { font-size: 16px; }
.poll-start small { font-size: 12.5px; color: var(--muted); }
.poll-head { display: flex; align-items: center; gap: 12px; }
.poll-head h1 { margin: 0; font: 700 26px/1.15 var(--f-body); }
.poll-head p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.poll-head .poll-lead { color: var(--ink); }
.poll-host { flex: none; max-width: 112px; display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; }
.poll-host small { font-size: 11px; line-height: 1.25; color: var(--muted); }
.poll-host small b { display: block; margin-top: 2px; color: var(--lavender); font-weight: 600; }
.poll-name { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--muted); }
.poll-name input, .pl-q { min-height: 48px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: 500 15px var(--f-body); }
.poll-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.poll-list li { position: relative; display: flex; flex-direction: column; overflow: hidden; border-radius: var(--r-card); background: var(--surface); border: 1px solid var(--line); }
.poll-list li.lead { border-color: var(--amber); }
.poll-list li.lead::after { content: "лидирует"; position: absolute; top: 10px; right: 10px; padding: 4px 10px; border-radius: 99px; font-size: 11px; font-weight: 700; background: var(--amber); color: #1a1405; }
.poll-list img { width: 100%; height: 140px; object-fit: cover; }
.poll-info { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px 4px; }
.poll-info b { font-size: 17px; line-height: 1.25; }
.poll-info small { color: var(--muted); font-size: 12.5px; }
.poll-info p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.poll-meter { display: block; height: 6px; margin-top: 6px; border-radius: 99px; background: var(--raised); overflow: hidden; }
.poll-meter em { display: block; height: 100%; border-radius: inherit; background: var(--lavender); transition: width .4s; }
.poll-who { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 12px; color: var(--muted); }
.poll-who i { font-style: normal; padding: 2px 8px; border-radius: 99px; background: var(--raised); color: var(--ink); }
.poll-who.pass i { color: var(--muted); }
.poll-vote { margin: 8px 14px 14px; min-height: 46px; padding: 10px; border-radius: 14px; font-weight: 700; background: var(--raised); border: 1px solid var(--line); }
.poll-list li.mine .poll-vote { background: var(--lavender); color: var(--on-accent); border-color: transparent; }
.poll-two { display: flex; gap: 8px; margin: 8px 14px 14px; }
.poll-two .poll-vote { flex: 1; margin: 0; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 10px 6px; }
.poll-two .poll-vote b { display: grid; place-items: center; width: 26px; height: 26px; }
.poll-two .poll-vote b svg { width: 22px; height: 22px; }
.poll-two .poll-vote em { font-style: normal; font-size: 12px; font-weight: 600; opacity: .7; }
.poll-two .poll-vote.on { background: var(--lavender); color: var(--on-accent); border-color: transparent; }
.poll-two .poll-vote.on.maybe { background: color-mix(in srgb, var(--mint) 30%, var(--raised)); color: var(--ink); }
.poll-two .poll-vote.on.pass { background: var(--line); color: var(--ink); }
.poll-actions { display: flex; gap: 8px; }
.poll-actions > * { flex: 1; min-height: 48px; display: grid; place-items: center; padding: 10px; border-radius: 14px; text-align: center; font-weight: 700; background: var(--surface); border: 1px solid var(--line); }
.poll-gone { display: flex; flex-direction: column; align-items: center; gap: 10px; color: var(--muted); text-align: center; }
.poll-link { align-self: flex-start; padding: 4px 2px; font-weight: 600; color: var(--lavender); }
/* кружки ответивших — только настоящие имена, без выдуманных аватарок */
.faces { display: inline-flex; margin-right: 6px; }
.faces i { width: 24px; height: 24px; margin-left: -7px; display: grid; place-items: center; border-radius: 50%; font: 700 11px/1 var(--f-body); font-style: normal; color: var(--on-accent);
  background: hsl(var(--h, 260) 55% 76%); border: 2px solid var(--surface); padding: 0 !important; }
.faces i:first-child { margin-left: 0; }
.faces i.more { background: var(--raised); color: var(--ink); }
.faces.maybe i { opacity: .6; }

/* любимые места */
.pl-add { align-self: flex-start; }
.pl-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.pl { display: flex; flex-direction: column; gap: 10px; padding: 12px; border-radius: var(--r-card); background: var(--surface); border: 1px solid var(--line); }
.pl-head { display: flex; align-items: center; gap: 12px; }
.pl-head div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pl-head b { font-size: 16px; font-weight: 600; }
.pl-head small { color: var(--muted); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-ph { flex: none; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 12px; color: var(--coral); background: var(--img, none) center / cover, var(--raised); }
.pl-ph svg { width: 22px; height: 22px; fill: currentColor; }
.pl-ev { display: flex; flex-direction: column; gap: 6px; }
.pl-e { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 12px; text-align: left; background: var(--raised); }
.pl-e b { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-e small { color: var(--lavender); font-size: 12px; font-weight: 600; }
.pl-more { align-self: flex-start; min-height: 32px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); font-size: 12.5px; font-weight: 600; }
.pl-act { display: flex; gap: 8px; }
.pl-act .pill { min-height: 42px; padding: 0 16px; font-size: 14px; }
.pl-start { display: flex; flex-direction: column; gap: 8px; }
.pl-start h2 { margin: 4px 0 0; font: 700 22px/1.2 var(--f-body); }
.pl-start .mute { margin: 0; }
.pl-pick { display: flex; flex-direction: column; gap: 12px; }
.pl-q { width: 100%; }
.pl-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.pl-tile { position: relative; display: flex; flex-direction: column; gap: 3px; padding: 8px; border-radius: 16px; text-align: left; background: var(--surface); border: 1.5px solid var(--line); }
.pl-tile .pl-ph { width: 100%; height: 86px; border-radius: 10px; }
.pl-tile b { font-size: 13px; font-weight: 600; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pl-tile small { color: var(--muted); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-tile > i { position: absolute; top: 14px; right: 14px; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: rgba(14, 16, 21, .8); color: var(--ink); }
.pl-tile > i svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; }
.pl-tile.on { border-color: var(--coral); }
.pl-tile.on > i { background: var(--coral); color: var(--on-accent); }
.pl-tile.on > i svg { fill: currentColor; }
.pl-done { align-self: stretch; min-height: 50px; font-size: 16px; }
.pl-done:disabled { opacity: .45; }
.poll-due { margin: -4px 0 0; font-size: 12.5px; color: var(--muted); }
.poll-decide { min-height: 48px; padding: 10px 14px; border-radius: 14px; font-weight: 700; background: var(--amber); color: #1a1405; }
.poll-final { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
.poll-final small { font-size: 12px; color: var(--muted); }
.poll-final p { margin: 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 13.5px; color: var(--muted); }
.poll-final p b { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.poll-final p span { flex: none; display: flex; align-items: center; gap: 6px; }
.poll-final p.won { color: var(--ink); }
.poll-final p.won b { font-weight: 800; }

/* шаги планов: число на вкладке («Решаем 1», «Иду 2») */
.plan-tabs a i { margin-left: 5px; min-width: 18px; height: 18px; padding: 0 5px; display: inline-grid; place-items: center; border-radius: 99px; font: 700 11px var(--f-body); font-style: normal; background: var(--raised); color: var(--ink); }
.plan-tabs a.on i { background: color-mix(in srgb, var(--on-accent) 22%, transparent); color: inherit; }
.poll-bar .solo { color: var(--ink); }
.poll-bar .solo[hidden] { display: none; }

/* «Решаем»: голосование, которое идёт, — варианты с голосами и «Завершить» */
.mypoll-list[hidden], .me-h[hidden] { display: none; }
.mypoll-list li.mp-open { flex-wrap: wrap; align-items: flex-start; border-left-color: var(--amber); }
.mp-ev { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.mp-ev i { flex: none; min-width: 22px; height: 22px; display: grid; place-items: center; border-radius: 99px; font: 700 12px var(--f-body); font-style: normal; background: var(--raised); }
.mp-acts { flex: 1 0 100%; display: flex; align-items: center; gap: 8px; }
.mp-acts .faces { margin-right: auto; }
.mp-end { min-height: 40px; padding: 0 18px; }
.lose-list { margin: 0; padding: 0 0 0 18px; display: flex; flex-direction: column; gap: 4px; color: var(--muted); font-size: 14px; }

/* «Иду»: «Я тут», ссылка на ответы друзей и «в эфире» — карточка пульсирует, пока друзья видят, что ты здесь */
.go-list li[data-id] { flex-wrap: wrap; cursor: pointer; }
.go-poll { align-self: flex-start; margin-top: 2px; font-size: 12.5px; font-weight: 700; color: var(--lavender); }
.go-list li > .go-here, .go-list li > .go-air { flex: 1 0 100%; display: flex; flex-direction: row; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; text-align: left; }
.go-here { background: var(--coral); border: 2px solid var(--ink); box-shadow: var(--hard); color: var(--ink); }
.go-here svg { flex: none; width: 20px; height: 20px; }
.go-here span, .go-air span { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.go-here small, .go-air small { font-size: 12px; opacity: .8; }
.go-air { background: color-mix(in srgb, var(--coral) 16%, var(--surface)); border: 2px dashed var(--coral); }
.go-air .pill, .go-air .ghost-pill { min-height: 36px; padding: 0 12px; font-size: 13px; }
.go-list li.on-air { border-color: var(--coral); box-shadow: 0 0 0 3px color-mix(in srgb, var(--coral) 25%, transparent); }
/* радар: точка и расходящиеся круги — «сигнал идёт» */
.radar { position: relative; flex: none; width: 14px; height: 14px; border-radius: 50%; background: var(--coral); }
.radar::before, .radar::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--coral); opacity: 0; }
@media (prefers-reduced-motion: no-preference) {
  .radar::before, .radar::after { animation: radar 2s ease-out infinite; }
  .radar::after { animation-delay: 1s; }
  .go-list li.on-air { animation: air-breath 2.4s ease-in-out infinite; }
}
@keyframes radar { from { transform: scale(1); opacity: .9; } to { transform: scale(3.2); opacity: 0; } }
@keyframes air-breath { 50% { box-shadow: 0 0 0 7px color-mix(in srgb, var(--coral) 12%, transparent); } }
