/* Мягкие формы в духе Discord: круглые аватарки, скруглённые иконки, аккуратные украшения и плашки ников.
   Подключается последним и переопределяет шестиугольники и восьмиугольники. */
:root { --chip: inset(0 round 30%); --ava-shape: circle(50%); }
:root[data-avatar="circle"] { --ava-shape: circle(50%); }
:root[data-avatar="square"] { --ava-shape: inset(0 round 26%); }
:root[data-avatar="hex"] { --ava-shape: var(--hex); }
.ava .pic { clip-path: var(--ava-shape); }
:root:not([data-avatar="hex"]) .ava { height: var(--size) !important; }

/* Иконки без «граней» */
.q-ico { height: 42px; } .voice-ico { height: 38px; } .since-hex { height: 40px; } .medal-hex { height: 48px; }
.type-ico { height: 40px; } .jelly-orb { height: 84px; } .perk-ico { height: 36px; }
.sendbtn { clip-path: none; border-radius: 50%; }
.verified-badge, .staff-badge { clip-path: none !important; border-radius: 50%; height: 16px; }
.pcard-level { clip-path: none !important; border-radius: 999px; }
.tile:not(:has(video)) .ava::before { clip-path: none; border-radius: 50%; }

/* Панель сквадов как в Discord: круг, который при наведении становится скруглённым квадратом, и полоска слева */
.dock { gap: 8px; }
.hexbtn { width: 48px; height: 48px; filter: none; transform: none !important; }
.hexbtn::after { display: none; }
.hexbtn > .shape { clip-path: none; border-radius: 50%; box-shadow: none; transition: border-radius .2s ease, background .2s ease; transform: none !important; }
.hexbtn:hover > .shape, .hexbtn.active > .shape { border-radius: 16px; }
.hexbtn::before { content: ""; position: absolute; left: -14px; top: 50%; width: 4px; height: 0; border-radius: 0 4px 4px 0; background: var(--text); transform: translateY(-50%); transition: height .2s ease; }
.hexbtn:hover::before { height: 20px; } .hexbtn.active::before { height: 38px; }
.hexbtn.active { filter: none; }
.dock-sep { width: 32px; height: 2px; border-radius: 1px; }
@media (max-width: 820px) { .hexbtn { width: 44px; height: 44px; } .hexbtn::before { left: -9px; } }

/* Украшение аватара: векторный слой поверх, на 20% больше аватарки */
.ava .deco { position: absolute; inset: -11%; z-index: 2; pointer-events: none; }
.ava .deco svg { display: block; width: 100%; height: 100%; overflow: visible; }
.ava .st { z-index: 3; }
.deco-neon svg { filter: drop-shadow(0 0 3px #ff3ea5aa) drop-shadow(0 0 5px #33e1ff66); }
.deco-spin { transform-origin: 50px 50px; animation: deco-spin 6s linear infinite; }
.deco-crown svg, .deco-headset svg, .deco-ears svg { filter: drop-shadow(0 2px 3px #0009); }
.deco-beat { transform-box: fill-box; transform-origin: center; animation: deco-beat 1.6s ease-in-out infinite; }
.deco-twinkle { transform-box: fill-box; transform-origin: center; animation: deco-twinkle 2.4s ease-in-out infinite; }
.deco .late { animation-delay: .8s; } .deco .later { animation-delay: 1.6s; }
@keyframes deco-spin { to { transform: rotate(360deg); } }
@keyframes deco-beat { 0%, 100% { transform: scale(1); } 15% { transform: scale(1.18); } 30% { transform: scale(.96); } }
@keyframes deco-twinkle { 0%, 100% { transform: scale(.4); opacity: .3; } 50% { transform: scale(1); opacity: 1; } }
:root[data-motion="off"] .deco * { animation: none !important; }
@media (prefers-reduced-motion: reduce) { .deco * { animation: none !important; } }
.deco-sw .ava { margin: 6px; }

/* Плашка ника: картинка за строкой участника, плавно проявляется справа */
.plate { position: relative; isolation: isolate; overflow: hidden; }
.plate::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; opacity: .95;
  -webkit-mask-image: linear-gradient(90deg, transparent 5%, #000 75%); mask-image: linear-gradient(90deg, transparent 5%, #000 75%); }
.sw.plate::before { -webkit-mask-image: none; mask-image: none; }
.plate-sunset::before { background: radial-gradient(circle at 86% 125%, #ffe66d 0 20%, transparent 21%), repeating-linear-gradient(180deg, transparent 0 5px, #2a0f3d55 5px 7px), linear-gradient(90deg, #2a0f3d, #ff3ea5 70%, #ffb347); }
.plate-neon::before { background: repeating-linear-gradient(90deg, #33e1ff66 0 1px, transparent 1px 14px), repeating-linear-gradient(0deg, #ff3ea566 0 1px, transparent 1px 10px), linear-gradient(90deg, #0c0716, #3b1066); }
.plate-sakura::before { background: radial-gradient(circle at 78% 30%, #ffe3f1 0 3px, transparent 4px), radial-gradient(circle at 92% 72%, #ffc0dd 0 4px, transparent 5px), radial-gradient(circle at 66% 76%, #fff 0 2px, transparent 3px), linear-gradient(90deg, #3a1530, #ff8fb8); }
.plate-ocean::before { background: radial-gradient(ellipse at 92% 120%, #5eead4 0 22%, transparent 52%), linear-gradient(90deg, #071620, #0ea5e9); }
.plate-matrix::before { background: repeating-linear-gradient(90deg, transparent 0 9px, #00ff8838 9px 11px), repeating-linear-gradient(180deg, #00ff8822 0 2px, transparent 2px 7px), linear-gradient(90deg, #001a0d, #00552b); animation: plate-rain 2.4s linear infinite; }
.plate-gold::before { background: linear-gradient(110deg, #3b2a05 0%, #c98b10 45%, #fff1a6 55%, #ffc83d 65%, #9c5f06 100%); background-size: 220% 100%; animation: plate-shine 4s linear infinite; }
@keyframes plate-rain { to { background-position: 0 14px, 0 14px, 0 0; } }
@keyframes plate-shine { from { background-position: 120% 0; } to { background-position: -120% 0; } }
.flair-grid.plates .sw { width: 100%; height: 26px; border-radius: 8px; }

/* Список участников справа */
.drawer.members-drawer { width: 248px; }
.members-pane { padding: 6px 8px 18px; }
.members-sec { padding: 18px 8px 6px; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--faint); }
.members-sec:first-child { padding-top: 10px; }
.member-row { display: flex; align-items: center; gap: 11px; width: 100%; min-height: 44px; padding: 5px 8px; border-radius: 9px; text-align: left; color: var(--muted); }
.member-row:hover { background: color-mix(in srgb, var(--text) 7%, transparent); color: var(--text); }
.member-row.off { opacity: .42; } .member-row.off:hover { opacity: .9; }
.member-row .mr-text { display: flex; flex-direction: column; min-width: 0; }
.member-row .t { display: flex; align-items: center; gap: 4px; min-width: 0; font-size: 14.5px; font-weight: 600; color: var(--text); }
.member-row .s { font-size: 12px; color: var(--muted); }
.member-row.plate .t, .member-row.plate .s { text-shadow: 0 1px 2px #000c; }
.owner-crown { display: inline-flex; color: #ffc83d; flex: none; }
.flair-preview .member-row { margin-top: 4px; background: var(--panel-2); }

/* Кто видит канал */
.role-dot { display: inline-block; flex: none; width: 12px; height: 12px; border-radius: 50%; }
.access-pick { display: flex; flex-direction: column; gap: 8px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; }
.role-checks { display: flex; flex-direction: column; gap: 7px; padding-left: 4px; }
.role-check { display: flex; align-items: center; gap: 8px; }

/* Обучение */
.tour { position: fixed; inset: 0; z-index: 200; }
.tour-hole { position: fixed; border-radius: 14px; pointer-events: none; transition: left .35s ease, top .35s ease, width .35s ease, height .35s ease;
  box-shadow: 0 0 0 9999px rgba(6, 3, 12, .74), 0 0 0 2px var(--honey), 0 0 26px color-mix(in srgb, var(--honey) 70%, transparent); }
.tour.centered .tour-hole { left: 50% !important; top: 50% !important; width: 0 !important; height: 0 !important; box-shadow: 0 0 0 9999px rgba(6, 3, 12, .74); }
.tour-card { position: fixed; width: 340px; padding: 18px 18px 16px; border-radius: 18px; background: var(--panel); border: 1px solid var(--line); box-shadow: 0 24px 60px #000b; transition: left .35s ease, top .35s ease; }
.tour.centered .tour-card { left: 50%; top: 50%; width: min(380px, calc(100vw - 32px)); transform: translate(-50%, -50%); }
.tour-step { font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--honey); }
.tour-card h3 { margin: 6px 0; font-size: 19px; } .tour-card p { margin: 0 0 14px; color: var(--muted); line-height: 1.5; }
.tour-dots { display: flex; gap: 6px; margin-bottom: 14px; }
.tour-dots i { width: 6px; height: 6px; border-radius: 3px; background: var(--panel-3); transition: width .2s ease, background .2s ease; }
.tour-dots i.on { width: 18px; background: var(--honey); }
.tour-actions { display: flex; align-items: center; gap: 8px; }
.tour .btn.ghost { background: none; border-color: transparent; color: var(--muted); }

/* ── Ивенты ── */
.events-row .glyph { color: var(--honey); }
.badge.soft { background: color-mix(in srgb, var(--honey) 22%, transparent); color: var(--honey); }
.events-list { display: flex; flex-direction: column; gap: 10px; }
.event-card { display: flex; gap: 14px; padding: 14px; border-radius: 14px; background: var(--panel-2); border: 1px solid var(--line); }
.event-card.soon { border-color: color-mix(in srgb, var(--honey) 60%, transparent); box-shadow: 0 0 0 1px color-mix(in srgb, var(--honey) 30%, transparent), 0 8px 24px color-mix(in srgb, var(--honey) 14%, transparent); }
.event-date { flex: none; width: 52px; height: 56px; border-radius: 12px; display: grid; place-items: center; align-content: center; background: var(--accent-grad, var(--honey)); color: var(--on-honey); line-height: 1; }
.event-date b { font-size: 22px; } .event-date small { font-size: 11px; text-transform: uppercase; font-weight: 700; }
.event-card h4 { margin: 4px 0 2px; font-size: 16px; } .event-card p { margin: 2px 0 6px; white-space: pre-wrap; }
.event-when { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--muted); }
.live-text { color: var(--honey); font-weight: 700; }
.event-room { display: flex; align-items: center; gap: 5px; color: var(--muted); margin-bottom: 4px; }
.event-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.event-people { display: flex; align-items: center; gap: 2px; } .event-people .ava + .ava { margin-left: -6px; } .event-people .small { margin-left: 8px; }
.btn.on { background: color-mix(in srgb, var(--mint) 22%, var(--panel-2)); color: var(--mint); border-color: color-mix(in srgb, var(--mint) 40%, transparent); }
.empty-note { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 30px 12px; text-align: center; color: var(--muted); }
.empty-note .big, .event-soon .big { font-size: 40px; }
.event-soon { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 6px 0 10px; } .event-soon h3 { margin: 4px 0; }

/* ── Эмодзи, стикеры, пикер ── */
.cemoji { width: 22px; height: 22px; object-fit: contain; vertical-align: -5px; margin: 0 1px; }
.body.jumbo .cemoji { width: 48px; height: 48px; vertical-align: middle; }
.sticker { display: block; width: 160px; height: 160px; object-fit: contain; margin: 2px 0; }
.msg .bubble:has(> .sticker) { background: none !important; box-shadow: none !important; padding-left: 0; padding-right: 0; }
.expr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 8px; }
.expr-grid.sticker { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
.expr { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 6px 6px; border-radius: 12px; background: var(--panel-2); min-width: 0; }
.expr img { width: 40px; height: 40px; object-fit: contain; } .expr-grid.sticker .expr img { width: 84px; height: 84px; }
.expr .icon-btn { position: absolute; top: 2px; right: 2px; width: 24px; height: 24px; }
.expr .small { max-width: 100%; }
.expr-add { display: flex; flex-direction: column; gap: 9px; padding-top: 6px; border-top: 1px solid var(--line); margin-top: 6px; }
.xpicker { display: flex !important; flex-direction: column; width: 340px; max-width: calc(100vw - 20px); max-height: 380px; padding: 0 !important; overflow: hidden; }
.xp-tabs { display: flex; gap: 4px; padding: 8px 8px 0; } .xp-tabs button { padding: 6px 12px; border-radius: 9px; font-size: 13px; font-weight: 700; color: var(--muted); }
.xp-tabs button.active { background: var(--panel-2); color: var(--text); }
.xp-body { overflow-y: auto; padding: 4px 8px 10px; }
.xp-sec { display: flex; align-items: center; gap: 6px; padding: 10px 4px 6px; font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--faint); }
.xp-lock { display: inline-flex; align-items: center; gap: 3px; padding: 1px 6px; border-radius: 6px; background: color-mix(in srgb, var(--jelly, #ffc83d) 22%, transparent); color: var(--jelly, #ffc83d); text-transform: none; letter-spacing: 0; }
.xp-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 2px; }
.xp-grid button { height: 36px; border-radius: 8px; font-size: 20px; display: grid; place-items: center; } .xp-grid button:hover { background: var(--panel-2); }
.xp-grid img { width: 26px; height: 26px; object-fit: contain; }
.xp-grid.sticker { grid-template-columns: repeat(3, 1fr); gap: 6px; } .xp-grid.sticker button { height: 96px; } .xp-grid.sticker img { width: 84px; height: 84px; }
.xp-grid button:disabled { opacity: .35; cursor: not-allowed; }

/* ── Звуковая панель ── */
.soundboard { display: flex !important; flex-direction: column; width: 320px; max-width: calc(100vw - 20px); padding: 4px 8px 10px !important; }
.sb-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.sb-grid button { display: flex; flex-direction: column; align-items: center; gap: 3px; height: auto !important; padding: 10px 6px; border-radius: 12px; background: var(--panel-2); font-size: 12px !important; font-weight: 600; min-width: 0; }
.sb-grid button:hover { background: color-mix(in srgb, var(--honey) 20%, var(--panel-2)); } .sb-grid button:active { transform: scale(.95); }
.sb-emoji { font-size: 24px; }
.sound-list { display: flex; flex-direction: column; gap: 4px; } .sound-row { display: flex; align-items: center; gap: 8px; padding: 4px 6px; border-radius: 10px; background: var(--panel-2); }

/* ── «Играет в…» ── */
.member-row .s.activity { display: flex; align-items: center; gap: 4px; color: var(--mint); }
.pcard-activity { display: flex; align-items: center; gap: 10px; margin: 8px 0 2px; padding: 8px 10px; border-radius: 12px; background: color-mix(in srgb, var(--mint) 12%, var(--panel-2)); }
.pcard-activity .pa-ico { font-size: 22px; } .pcard-activity small { display: block; font-size: 11px; color: var(--muted); text-transform: uppercase; font-weight: 700; letter-spacing: .04em; }
.game-grid { display: flex; flex-wrap: wrap; gap: 6px; }

/* ── Форум ── */
.type-pick { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
.msgs-inner.forum { padding: 18px 22px 30px; gap: 12px; }
.forum-head { display: flex; align-items: flex-end; gap: 12px; } .forum-head h2 { margin: 0; font-size: 22px; }
.forum-list { display: flex; flex-direction: column; gap: 8px; }
.forum-post { display: flex; gap: 14px; align-items: stretch; width: 100%; padding: 14px 16px; border-radius: 14px; background: var(--panel-2); border: 1px solid var(--line); text-align: left; transition: background .15s, border-color .15s; }
.forum-post:hover { background: var(--panel-3); border-color: color-mix(in srgb, var(--honey) 40%, var(--line)); }
.fp-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.fp-title { font-size: 16px; } .fp-text { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fp-meta { display: flex; align-items: center; gap: 5px; margin-top: 4px; }
.fp-thumb { flex: none; width: 88px; height: 70px; object-fit: cover; border-radius: 10px; }
.post-title { font-size: 17px; font-weight: 800; margin-bottom: 4px; }
@media (max-width: 820px) { .msgs-inner.forum { padding: 12px; } .fp-thumb { display: none; } }
.msgs-inner.forum { justify-content: flex-start !important; }
.msgs-inner.forum > .forum-head { margin-top: 0; }

/* Подключение: запасные адреса */
.conn { display: flex; align-items: center; gap: 8px; }
.conn-btn { background: rgba(255,255,255,.2); color: #fff; border: 0; border-radius: 99px; padding: 2px 10px; font: inherit; font-weight: 700; cursor: pointer; }
.conn-btn:hover { background: rgba(255,255,255,.32); }
.routes { display: flex; flex-direction: column; gap: 6px; margin: 4px 0; }
.route { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 10px; background: var(--chip, rgba(255,255,255,.04)); }
.route.current { outline: 1px solid var(--accent, #6fd3f5); }
.route .grow { min-width: 0; }
.route-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; background: #888; }
.route-dot.good { background: #3ba55d; } .route-dot.slow { background: #faa61a; } .route-dot.bad { background: #ed4245; }
.route-dot.wait { animation: route-pulse 1s ease-in-out infinite; }
@keyframes route-pulse { 50% { opacity: .3; } }
.route-ms { min-width: 70px; text-align: right; }
.route-here { color: var(--accent, #6fd3f5); font-weight: 700; min-width: 72px; text-align: center; }

/* Комната: звук зависит от расстояния */
.tiles[data-layout="room"] { position: relative; display: block; overflow: hidden; border-radius: 14px;
  background: radial-gradient(circle at 50% 50%, rgba(111,211,245,.06), transparent 70%),
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 40px 40px,
    linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 40px 40px; }
.tiles[data-layout="room"] .tile { width: 86px !important; height: 86px !important; min-height: 0; border-radius: 50%; transform: translate(-50%, -50%);
  transition: left .12s linear, top .12s linear, opacity .2s; display: grid; place-items: center; padding: 0; z-index: 2; }
.tiles[data-layout="room"] .tile .tag { position: absolute; top: calc(100% + 4px); left: 50%; transform: translateX(-50%); bottom: auto; white-space: nowrap; max-width: 140px; }
.tiles[data-layout="room"] .tile .tile-tools, .tiles[data-layout="room"] .tile .tile-corner { display: none; }
.tiles[data-layout="room"] .tile.room-me { cursor: grab; z-index: 3; transition: none; box-shadow: 0 0 0 3px var(--accent, #6fd3f5); }
.tiles[data-layout="room"] .tile.room-me:active { cursor: grabbing; }
.room-range { position: absolute; transform: translate(-50%, -50%); border-radius: 50%; pointer-events: none; z-index: 1;
  border: 1px dashed rgba(111,211,245,.35); background: radial-gradient(closest-side, rgba(111,211,245,.12), rgba(111,211,245,.03) 60%, transparent); }

/* Вход: подсказка «аккаунта нет — создадим» */
.auth-hint { padding: 10px 12px; border-radius: 10px; background: rgba(111,211,245,.1); border: 1px solid rgba(111,211,245,.3); font-size: 13px; line-height: 1.45; }

/* ───── Кастомизация v2: пузыри, баннеры, плашки, украшения, эффекты и темы профиля ───── */
.msg .bubble.bub-neon, .msg.mine .bubble.bub-neon { background: linear-gradient(135deg, #12081f, #3b1066); color: #fdf2ff; border-color: #ff3ea5aa; box-shadow: 0 0 10px #ff3ea544, inset 0 0 8px #33e1ff33; }
.msg .bubble.bub-lava, .msg.mine .bubble.bub-lava { background: linear-gradient(135deg, #3b0a0a, #c2410c 60%, #ff8a3d); color: #fff4ea; border-color: #ffb07a55; }
.msg .bubble.bub-forest, .msg.mine .bubble.bub-forest { background: linear-gradient(135deg, #0f2a14, #1f6b2a 60%, #4caf50); color: #effff0; border-color: #9be7a155; }
.msg .bubble.bub-ice, .msg.mine .bubble.bub-ice { background: linear-gradient(135deg, #0e3a5a, #3b8fc4 60%, #bfe9ff); color: #f3fbff; border-color: #dff6ff77; }
.msg .bubble.bub-grape, .msg.mine .bubble.bub-grape { background: linear-gradient(135deg, #2b0f45, #6d28d9 60%, #a78bfa); color: #f6f0ff; border-color: #d6c4ff55; }
.msg .bubble.bub-mono, .msg.mine .bubble.bub-mono { background: linear-gradient(135deg, #111318, #2a2f3a 60%, #4b5563); color: #f3f4f6; border-color: #9ca3af44; }
.bub-neon.sw, .bubble-demo.bub-neon { background: linear-gradient(135deg, #12081f, #3b1066); box-shadow: inset 0 0 0 1px #ff3ea5; }
.bub-lava.sw, .bubble-demo.bub-lava { background: linear-gradient(135deg, #3b0a0a, #ff8a3d); }
.bub-forest.sw, .bubble-demo.bub-forest { background: linear-gradient(135deg, #0f2a14, #4caf50); }
.bub-ice.sw, .bubble-demo.bub-ice { background: linear-gradient(135deg, #0e3a5a, #bfe9ff); }
.bub-grape.sw, .bubble-demo.bub-grape { background: linear-gradient(135deg, #2b0f45, #a78bfa); }
.bub-mono.sw, .bubble-demo.bub-mono { background: linear-gradient(135deg, #111318, #4b5563); }

.banner-synthwave { background: linear-gradient(transparent 55%, #ff3ea533 55% 56%, transparent 56% 66%, #ff3ea533 66% 67%, transparent 67%), radial-gradient(circle at 50% 70%, #ffe66d 0 16%, #ff7a59 17% 26%, transparent 27%), linear-gradient(180deg, #1a0b3a, #5b1a7a 60%, #ff3ea5); }
.banner-forest { background: linear-gradient(160deg, transparent 60%, #0b2e13 60%), linear-gradient(20deg, transparent 55%, #134e1f 55%), linear-gradient(180deg, #9be7a1, #2f8f46); }
.banner-sakura { background: radial-gradient(circle at 20% 30%, #fff 0 3px, transparent 4px), radial-gradient(circle at 70% 60%, #ffd1e6 0 4px, transparent 5px), radial-gradient(circle at 45% 80%, #fff 0 2px, transparent 3px), linear-gradient(135deg, #ffd1e6, #ff8fb8 55%, #b05a8a); }
.banner-ice { background: linear-gradient(115deg, transparent 40%, #ffffff55 45%, transparent 50%), linear-gradient(135deg, #dff6ff, #7cc7ee 55%, #2b6ca3); }
.banner-mint { background: linear-gradient(135deg, #d9fff1, #5eead4 50%, #0f766e); }
.banner-grape { background: linear-gradient(135deg, #f0abfc, #a855f7 50%, #3b0764); }
.banner-ember { background: radial-gradient(circle at 20% 110%, #ffb627 0 18%, transparent 40%), radial-gradient(circle at 80% 120%, #ff6b3d 0 22%, transparent 45%), linear-gradient(180deg, #120404, #4a0e0e); background-size: 140% 140%; animation: lava 5s ease-in-out infinite alternate; }
.banner-cosmos { background: radial-gradient(circle at 15% 25%, #fff 0 1px, transparent 2px) 0 0 / 26px 26px, radial-gradient(circle at 60% 70%, #fffb 0 1px, transparent 2px) 0 0 / 40px 40px, radial-gradient(ellipse at 70% 40%, #7b3fd088, transparent 60%), linear-gradient(135deg, #05030f, #1b0f4a); animation: galaxy 16s linear infinite; }
:root[data-motion="off"] .banner-ember, :root[data-motion="off"] .banner-cosmos { animation: none; }

.plate-aurora::before { background: radial-gradient(ellipse at 80% 0%, #5eead4aa, transparent 60%), radial-gradient(ellipse at 95% 100%, #a78bfaaa, transparent 55%), linear-gradient(90deg, #04121a, #0f3b46); }
.plate-lava::before { background: linear-gradient(90deg, #1a0505, #7c1d0b 50%, #ff6b3d); background-size: 200% 100%; animation: plate-shine 6s ease-in-out infinite alternate; }
.plate-forest::before { background: linear-gradient(160deg, transparent 55%, #0b2e1388 55%), linear-gradient(90deg, #0b1a0e, #2f8f46); }
.plate-ice::before { background: linear-gradient(115deg, transparent 55%, #ffffff44 60%, transparent 65%), linear-gradient(90deg, #0a1f2e, #7cc7ee); }
.plate-candy::before { background: repeating-linear-gradient(135deg, #ff8fc855 0 8px, #ffffff33 8px 16px), linear-gradient(90deg, #3a1530, #ff8fc8); }
.plate-arcade::before { background: radial-gradient(circle, #ffe14d 0 1.5px, transparent 2px) 0 0 / 12px 12px, linear-gradient(90deg, #0c0716, #1f1147 50%, #ff3ea5); }
.plate-storm::before { background: linear-gradient(100deg, transparent 70%, #fff6 71%, transparent 72%), linear-gradient(90deg, #0b1020, #374151 60%, #6b7280); }
.plate-royal::before { background: radial-gradient(circle at 90% 50%, #ffc83d55, transparent 40%), linear-gradient(90deg, #1e0b3a, #4c1d95 60%, #7c3aed); }

/* Анимации новых украшений */
.deco-dino svg, .deco-fox svg, .deco-bunny svg, .deco-frog svg, .deco-ghost svg, .deco-devil svg, .deco-butterfly svg, .deco-orbit svg { filter: drop-shadow(0 2px 3px #0008); }
.deco-halo svg { filter: drop-shadow(0 0 4px #ffe27a); } .deco-flames svg { filter: drop-shadow(0 0 4px #ff6a00aa); } .deco-bolt svg { filter: drop-shadow(0 0 3px #ffe14d99); }
.deco-bob { animation: deco-bob 2.6s ease-in-out infinite; }
.deco-float { animation: deco-float 3s ease-in-out infinite; }
.deco-sway { transform-origin: 70px 80px; animation: deco-sway 3.2s ease-in-out infinite; }
.deco-flop { transform-box: fill-box; transform-origin: 50% 100%; animation: deco-flop 4s ease-in-out infinite; }
.deco-blink { transform-box: fill-box; transform-origin: center; animation: deco-blink 4s ease-in-out infinite; }
.deco-flap { transform-box: fill-box; transform-origin: center; animation: deco-flap .5s ease-in-out infinite alternate; }
.deco-flicker { transform-box: fill-box; transform-origin: 50% 100%; animation: deco-flicker .9s ease-in-out infinite alternate; }
.deco-spin-slow { animation: deco-spin 9s linear infinite; }
.deco-flash { transform-box: fill-box; transform-origin: center; animation: deco-flash 2.2s steps(1) infinite; }
@keyframes deco-bob { 50% { transform: translateY(-2px) rotate(-4deg); } }
@keyframes deco-float { 50% { transform: translateY(-3px); } }
@keyframes deco-sway { 50% { transform: rotate(-6deg); } }
@keyframes deco-flop { 0%, 70%, 100% { transform: rotate(0); } 80% { transform: rotate(14deg); } 90% { transform: rotate(-4deg); } }
@keyframes deco-blink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
@keyframes deco-flap { to { transform: scaleX(.35); } }
@keyframes deco-flicker { to { transform: scale(.85, 1.15); opacity: .85; } }
@keyframes deco-flash { 0%, 60% { opacity: 1; } 65% { opacity: .2; } 70% { opacity: 1; } 75% { opacity: .3; } 80%, 100% { opacity: 1; } }

/* Профиль: уровень рядом с ником, а не поверх аватарки (раньше закрывал статус и украшение) */
.pcard-level { display: none !important; }
.lvl-chip { margin-left: 8px; padding: 2px 9px; border-radius: 99px; font-size: 12px; font-weight: 800; letter-spacing: 0; background: var(--accent-grad); color: var(--on-honey, #1a1305); align-self: center; }
.pcard-body, .pcard-head { position: relative; z-index: 2; }
.pcard-banner { z-index: 0; }

/* Тема профиля: свой градиент на всю карточку */
.pcard.themed { background: linear-gradient(180deg, color-mix(in srgb, var(--t1) 62%, #0b0716), color-mix(in srgb, var(--t2) 52%, #0b0716)); border-color: color-mix(in srgb, var(--t1) 45%, transparent); }
.pcard.themed .pcard-banner:not([class*="banner-"]) { background: linear-gradient(120deg, var(--t1), var(--t2)); }
.pcard.themed .pcard-ava > .ava .pic { box-shadow: 0 0 0 5px color-mix(in srgb, var(--t1) 62%, #0b0716); }
.pcard.themed .pcard-stats > div, .pcard.themed .pcard-since, .pcard.themed .pcard-status, .pcard.themed .pcard-activity { background: #0000002e; border-color: #ffffff1f; }
.pcard.themed .xpbar { background: #00000040; }
.flair-preview { position: relative; overflow: hidden; border-radius: 16px; }
.flair-preview.themed { background: linear-gradient(160deg, color-mix(in srgb, var(--t1) 62%, #0b0716), color-mix(in srgb, var(--t2) 52%, #0b0716)); padding: 6px; }
.flair-preview > *:not(.pfx) { position: relative; z-index: 1; }

/* Эффект профиля: частицы поверх карточки */
.pfx { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 1; border-radius: inherit; }
.pfx span { position: absolute; top: -24px; line-height: 1; opacity: .85; animation: pfx-fall linear infinite; will-change: transform; }
.pfx-embers span, .pfx-bubbles span { top: auto; bottom: -24px; animation-name: pfx-rise; }
.pfx-snow span { color: #fff; text-shadow: 0 0 4px #bfe9ff; }
.pfx-embers span { color: #ffb627; text-shadow: 0 0 6px #ff6a00, 0 0 12px #ff6a00; }
.pfx-stars span { color: #ffe27a; text-shadow: 0 0 6px #ffe27a; }
.pfx-pixels span, .pfx-confetti span { color: hsl(var(--hue) 90% 65%); }
.pfx-bubbles span { color: #bfe9ff; opacity: .7; }
@keyframes pfx-fall { from { transform: translate(0, 0) rotate(0); } to { transform: translate(var(--drift), 100vh) rotate(320deg); } }
@keyframes pfx-rise { from { transform: translate(0, 0); opacity: 0; } 15% { opacity: .9; } to { transform: translate(var(--drift), -100vh); opacity: 0; } }
:root[data-motion="off"] .pfx, .flair-preview .pfx span:nth-child(n+10) { display: none; }
@media (prefers-reduced-motion: reduce) { .pfx { display: none; } }

/* Выбор эффекта и темы в настройках */
.fx-sw { font-size: 20px !important; }
.ptheme-grid { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.theme-sw { width: 40px; height: 40px; border-radius: 12px; border: 2px solid transparent; cursor: pointer; padding: 0; }
.theme-sw.none { background: var(--panel-3); color: var(--muted); font-size: 16px; }
.theme-sw.active { border-color: var(--text); box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px var(--accent, #ff3ea5); }
.theme-custom { display: flex; align-items: center; gap: 4px; padding: 4px 8px; border-radius: 12px; background: var(--panel-2); cursor: pointer; }
.theme-custom input[type="color"] { width: 30px; height: 30px; border: 0; padding: 0; background: none; cursor: pointer; }
.theme-custom small { color: var(--muted); font-weight: 650; }

/* ── Этап 1 платформы ── */
.clan-tag { --tc: var(--honey); display: inline-flex; align-items: center; margin-right: 5px; padding: 0 5px; border-radius: 6px; font-size: .72em; font-weight: 800; letter-spacing: .04em; line-height: 1.55; vertical-align: .12em; color: var(--tc); background: color-mix(in srgb, var(--tc) 16%, transparent); border: 1px solid color-mix(in srgb, var(--tc) 45%, transparent); white-space: nowrap; }
.clan-tag::before { content: "["; opacity: .55; } .clan-tag::after { content: "]"; opacity: .55; }
.pcard-tz, .pcard-bday { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 16px; background: var(--panel-2); border: 1px solid var(--line, #ffffff14); margin-top: 8px; }
.pcard-tz b, .pcard-bday b { display: block; } .pcard-tz small, .pcard-bday small { color: var(--muted); }
.pcard-bday.today { background: linear-gradient(120deg, #ff3ea533, #ffb62733); border-color: #ffb62766; animation: bday-glow 2.4s ease-in-out infinite; }
@keyframes bday-glow { 50% { box-shadow: 0 0 0 3px #ffb62733; } }
.pcard.themed .pcard-tz, .pcard.themed .pcard-bday { background: #0000002e; border-color: #ffffff1f; }
.pcard-bio a { color: var(--honey); text-decoration: underline; text-underline-offset: 2px; overflow-wrap: anywhere; }
.pcard-bio { max-height: 260px; overflow-y: auto; }
.bio-count { color: var(--muted); font-weight: 600; } .bio-count.warn { color: var(--red, #ff5d5d); }
.bio-input { min-height: 110px; resize: vertical; }
.row.wrap { flex-wrap: wrap; }
.bday-list { display: flex; flex-direction: column; gap: 8px; }
.bday-row.today { border-color: #ffb62788; background: linear-gradient(120deg, #ff3ea51f, #ffb6271f); }
.glyph-img { position: relative; width: 62%; height: 62%; object-fit: cover; border-radius: 30%; }
/* Редактор аватарки */
.crop-modal { max-width: 480px; }
.crop-wrap { display: flex; gap: 16px; align-items: flex-start; flex-wrap: wrap; justify-content: center; }
.crop-canvas { border-radius: 16px; background: repeating-conic-gradient(#ffffff10 0 25%, transparent 0 50%) 0 0 / 20px 20px; cursor: grab; touch-action: none; max-width: 100%; }
.crop-canvas:active { cursor: grabbing; } .crop-canvas:focus-visible { outline: 2px solid var(--honey); }
.crop-side { display: flex; flex-direction: column; gap: 8px; }
.crop-prevs { display: flex; align-items: flex-end; gap: 10px; }
.crop-prev { border-radius: 50%; background: var(--panel-3); } .crop-prev.square { border-radius: 22%; }
.crop-zoom { display: flex; align-items: center; gap: 10px; } .crop-zoom input { flex: 1; accent-color: var(--honey); }
.avatar-field { gap: 10px; }
.av-prev { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 30%; background: var(--panel-3); overflow: hidden; color: var(--muted); flex: none; }
.av-prev.circle { border-radius: 50%; } .av-prev img { width: 100%; height: 100%; object-fit: cover; }
/* Свой фокус */
.focus-custom { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px; border-radius: 14px; background: var(--panel-2); }
.focus-custom .input { width: 72px; } .focus-custom .set-label { flex-basis: 100%; }
/* Быстрое меню */
.tray-pop { position: fixed; z-index: 60; width: 260px; padding: 10px; border-radius: 16px; background: var(--panel); border: 1px solid var(--line, #ffffff1f); box-shadow: 0 18px 48px #0008; display: flex; flex-direction: column; gap: 8px; animation: tray-in .14s ease-out; }
@keyframes tray-in { from { opacity: 0; transform: translateY(6px) scale(.98); } }
.tray-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.tray-tile { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px; border-radius: 12px; background: var(--panel-2); color: var(--muted); font-size: 12px; font-weight: 650; }
.tray-tile:hover { color: var(--text); } .tray-tile.on { background: color-mix(in srgb, var(--honey) 22%, var(--panel-2)); color: var(--text); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--honey) 55%, transparent); }
.tray-vol { display: flex; align-items: center; gap: 8px; padding: 4px 6px; color: var(--muted); } .tray-vol input { flex: 1; accent-color: var(--honey); }
.tray-more { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 7px; border-radius: 10px; color: var(--muted); font-size: 13px; } .tray-more:hover { background: var(--panel-2); color: var(--text); }
/* Режим стримера: размытие медиа, личных данных и приглашений */
.st-blur .msgs img:not(.cemoji):not(.sticker), .st-blur .msgs video, .st-blur .pcard-banner { filter: blur(22px) saturate(.6); transition: filter .2s; }
.st-blur .msgs img:not(.cemoji):not(.sticker):hover, .st-blur .msgs video:hover { filter: none; }
.st-personal .personal, .st-personal .pcard .muted:has(> .pres) { filter: blur(6px); transition: filter .2s; }
.st-personal .personal:hover { filter: none; }
.st-invites .invite-code, .st-invites .routes { filter: blur(7px); transition: filter .2s; } .st-invites .invite-code:hover, .st-invites .invite-code:focus, .st-invites .routes:hover { filter: none; }

.streamer .me-bar { position: relative; }

/* ── Этап 2: экономика ── */
.coins b { font-variant-numeric: tabular-nums; }
.shop-page { display: flex; flex-direction: column; height: 100%; overflow: hidden; }
.shop-head { display: flex; align-items: center; gap: 10px; padding: 14px 18px 6px; } .shop-head h1 { font-size: 22px; margin: 0; }
.shop-tabs { display: flex; gap: 6px; padding: 6px 18px 10px; overflow-x: auto; scrollbar-width: none; } .shop-tabs .chip { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.shop { flex: 1; overflow-y: auto; padding: 4px 18px 40px; display: flex; flex-direction: column; gap: 12px; }
.shop h3 { margin: 8px 0 0; }
.eco-card { padding: 14px; border-radius: 16px; background: var(--panel-2); border: 1px solid var(--line, #ffffff14); display: flex; flex-direction: column; gap: 8px; }
.eco-card.row { flex-direction: row; align-items: center; gap: 12px; }
.item-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 10px; }
.item-tile { --rc: #999; position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 8px 10px; border-radius: 16px; background: radial-gradient(120% 90% at 50% 0%, color-mix(in srgb, var(--rc) 22%, transparent), transparent 70%), var(--panel-2); border: 1px solid color-mix(in srgb, var(--rc) 45%, transparent); min-width: 0; transition: transform .15s, box-shadow .15s; }
.item-tile:hover { transform: translateY(-2px); box-shadow: 0 8px 24px color-mix(in srgb, var(--rc) 25%, transparent); }
.item-tile.sel { box-shadow: 0 0 0 3px var(--rc); } .item-tile.locked { opacity: .6; }
.item-tile.small { padding: 10px 6px 8px; }
.it-emoji { font-size: 40px; line-height: 1.1; min-height: 46px; display: grid; place-items: center; } .item-tile.small .it-emoji { font-size: 28px; min-height: 34px; }
.it-name { font-weight: 700; font-size: 13px; max-width: 100%; text-align: center; }
.it-meta { font-size: 11px; color: var(--muted); display: flex; align-items: center; gap: 4px; }
.rdot { width: 8px; height: 8px; border-radius: 50%; background: var(--rc, #999); display: inline-block; box-shadow: 0 0 6px var(--rc, #999); }
.it-flag { position: absolute; top: 6px; right: 6px; font-size: 10px; font-weight: 700; padding: 1px 6px; border-radius: 6px; background: #000a; color: #fff; }
.r-legendary.item-tile, .r-mythic.item-tile, .r-legendary.gift-card, .r-mythic.gift-card { animation: rare-glow 3s ease-in-out infinite; }
@keyframes rare-glow { 50% { box-shadow: 0 0 18px color-mix(in srgb, var(--rc) 45%, transparent); } }
.gift-card { --rc: #999; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 10px; border-radius: 16px; background: radial-gradient(120% 90% at 50% 0%, color-mix(in srgb, var(--rc) 20%, transparent), transparent 70%), var(--panel-2); border: 1px solid color-mix(in srgb, var(--rc) 40%, transparent); text-align: center; }
.hero-emoji { font-size: 46px; line-height: 1.1; }
.gift-pop { animation: gift-pop 1.6s ease-in-out infinite; display: inline-block; } @keyframes gift-pop { 50% { transform: scale(1.12) rotate(-6deg); } }
.btn.small { padding: 5px 10px; font-size: 13px; }
.lot { --rc: #999; display: flex; flex-direction: column; gap: 6px; padding: 8px; border-radius: 16px; background: var(--panel-2); border: 1px solid color-mix(in srgb, var(--rc) 30%, transparent); }
.lot .item-tile { background: none; border: 0; } .lot-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.item-hero { --rc: #999; display: flex; align-items: center; gap: 16px; padding: 14px; border-radius: 16px; background: radial-gradient(120% 120% at 0% 50%, color-mix(in srgb, var(--rc) 25%, transparent), transparent 70%), var(--panel-2); }
.item-actions { display: flex; flex-direction: column; gap: 10px; }
.spark { color: var(--honey); display: block; margin-top: 4px; max-width: 100%; }
.case-row { display: flex; gap: 10px; flex-wrap: wrap; }
.case-box { display: flex; flex-direction: column; align-items: center; gap: 4px; width: 120px; padding: 14px 8px; border-radius: 16px; background: linear-gradient(160deg, color-mix(in srgb, var(--honey) 35%, var(--panel-2)), var(--panel-2)); border: 1px solid color-mix(in srgb, var(--honey) 50%, transparent); }
.case-box small { color: var(--muted); } .case-ico { font-size: 40px; animation: gift-pop 2s ease-in-out infinite; }
.odds { display: flex; flex-direction: column; gap: 4px; }
.odds-row { --rc: #999; display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 12px; background: var(--panel-2); border-left: 3px solid var(--rc); }
.odds-row.gold { --rc: #fbbf24; } .odds-items { color: var(--muted); font-size: 15px; letter-spacing: 2px; max-width: 45%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.modal.case-modal { width: min(620px, 94vw); max-width: none; }
.reel { position: relative; overflow: hidden; border-radius: 16px; background: var(--panel-2); padding: 12px 0; mask-image: linear-gradient(90deg, transparent, #000 15%, #000 85%, transparent); }
.reel-strip { display: flex; gap: 8px; width: max-content; margin-left: 50%; will-change: transform; }
.reel-cell { --rc: #999; width: 84px; height: 84px; flex: none; display: grid; place-items: center; font-size: 42px; border-radius: 14px; background: radial-gradient(circle at 50% 30%, color-mix(in srgb, var(--rc) 35%, transparent), var(--panel-3)); border-bottom: 3px solid var(--rc); }
.reel-mark { position: absolute; left: 50%; top: 0; bottom: 0; width: 3px; margin-left: -1.5px; background: var(--honey); z-index: 2; box-shadow: 0 0 12px var(--honey); }
.reel-result { display: flex; flex-direction: column; align-items: center; gap: 10px; padding-top: 12px; animation: tray-in .3s ease-out; } .reel-result .item-tile { width: 160px; }
.ledger { display: flex; flex-direction: column; gap: 4px; }
.ledger-row { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 12px; background: var(--panel-2); font-size: 14px; }
.lg-emoji { font-size: 20px; } .plus { color: #4ade80; } .minus { color: #ff6b6b; }
.eco-weights { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
/* Витрина профиля */
.showcase { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 8px; }
.sc-item { --rc: #999; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px 6px; border-radius: 14px; background: radial-gradient(circle at 50% 20%, color-mix(in srgb, var(--rc) 30%, transparent), transparent 75%), var(--panel-2); border: 1px solid color-mix(in srgb, var(--rc) 35%, transparent); min-width: 0; }
.sc-emoji { font-size: 30px; line-height: 1.15; } .sc-item small { color: var(--muted); font-size: 10px; }
.sc-from { font-size: 10px; color: var(--honey); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pcard.themed .sc-item { background: #0000002e; }
.sc-edit { display: flex; flex-direction: column; gap: 4px; }
.sc-row { display: flex; align-items: center; gap: 8px; padding: 6px 10px; border-radius: 12px; background: var(--panel-2); cursor: grab; } .sc-row.off { opacity: .45; } .sc-row.dragging { outline: 2px dashed var(--honey); }
.sc-row .sc-emoji { font-size: 22px; } .grip { color: var(--muted); }
/* 3D-значки */
.b3d { --s: 22px; --rc: #999; position: relative; display: inline-grid; place-items: center; width: var(--s); height: var(--s); margin-left: 4px; vertical-align: middle; perspective: calc(var(--s) * 8); flex: none; }
.b3d-in { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; }
.b3d-f, .b3d-b { position: absolute; inset: 0; display: grid; place-items: center; font-size: calc(var(--s) * .8); line-height: 1; backface-visibility: hidden; filter: drop-shadow(0 0 calc(var(--s) * .1) var(--rc)); }
.b3d-b { transform: rotateY(180deg); filter: brightness(.7) drop-shadow(0 0 calc(var(--s) * .1) var(--rc)); }
.b3d.r-legendary::before, .b3d.r-mythic::before, .b3d.lvl-5::before { content: ""; position: absolute; inset: -30%; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--rc) 55%, transparent), transparent 65%); animation: b3d-halo 2.4s ease-in-out infinite; pointer-events: none; }
.b3d.lvl-5::before { background: conic-gradient(#ff3ea5, #ffb627, #4ade80, #38bdf8, #c084fc, #ff3ea5); filter: blur(calc(var(--s) * .25)); opacity: .55; animation: b3d-turn 3s linear infinite; }
@keyframes b3d-halo { 50% { transform: scale(1.25); opacity: .55; } }
@keyframes b3d-turn { to { transform: rotate(360deg); } }
.b3d.lvl-3 .b3d-f, .b3d.lvl-4 .b3d-f { filter: drop-shadow(0 0 calc(var(--s) * .22) var(--rc)) saturate(1.3); }
.b3d-lvl { position: absolute; right: -6px; bottom: -4px; font: 800 calc(var(--s) * .32)/1.2 system-ui; font-style: normal; padding: 0 3px; border-radius: 5px; background: var(--rc); color: #111; z-index: 2; min-width: 10px; text-align: center; }
.b3d.a-spin3d .b3d-in, .b3d.a-orbit .b3d-in { animation: b3d-spin 3.2s linear infinite; }
.b3d.a-spin .b3d-in { animation: b3d-turn 6s linear infinite; }
.b3d.a-float .b3d-in { animation: b3d-float 2.6s ease-in-out infinite; }
.b3d.a-hop .b3d-in { animation: b3d-hop 1.8s cubic-bezier(.3,.7,.4,1) infinite; }
.b3d.a-swing .b3d-in { animation: b3d-swing 2.4s ease-in-out infinite; transform-origin: 50% 10%; }
.b3d.a-pulse .b3d-in { animation: b3d-pulse 2s ease-in-out infinite; }
@keyframes b3d-spin { to { transform: rotateY(360deg); } }
@keyframes b3d-float { 50% { transform: translateY(-14%) rotateY(25deg); } }
@keyframes b3d-hop { 0%, 60%, 100% { transform: translateY(0) scaleY(1); } 30% { transform: translateY(-28%) scaleY(1.05); } 62% { transform: scaleY(.88); } }
@keyframes b3d-swing { 0%, 100% { transform: rotateZ(-12deg) rotateY(-20deg); } 50% { transform: rotateZ(12deg) rotateY(20deg); } }
@keyframes b3d-pulse { 50% { transform: scale(1.15) rotateY(30deg); } }
/* Полёт по траектории вокруг аватара в профиле */
.b3d.fly { animation: b3d-fly 7s ease-in-out infinite; }
@keyframes b3d-fly { 0% { translate: 0 0; } 25% { translate: 14px -10px; } 50% { translate: 0 -18px; } 75% { translate: -14px -8px; } 100% { translate: 0 0; } }
.pcard-ava { position: relative; } .pcard-badge { position: absolute; right: -14px; top: -8px; z-index: 3; }
.item-hero .b3d, .eco-card .b3d { margin: 6px; }
[data-motion="off"] .b3d, [data-motion="off"] .b3d *, [data-motion="off"] .b3d::before { animation: none !important; }
@media (prefers-reduced-motion: reduce) { .b3d, .b3d *, .b3d::before { animation: none !important; } }
/* Кружки и аура Gold */
.round-vid { position: relative; display: block; width: 220px; height: 220px; padding: 0; border-radius: 50%; margin: 2px 0; background: none; }
.round-vid video { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; background: #000; }
.round-vid.aura { margin: 10px; }
.aura-ring { position: absolute; inset: -7px; border-radius: 50%; background: conic-gradient(#ff3ea5, #ffb627, #33e1ff, #a78bfa, #ff3ea5); filter: blur(5px); animation: b3d-turn 4s linear infinite; z-index: 0; }
.round-vid.aura::after { content: ""; position: absolute; inset: -3px; border-radius: 50%; border: 2px solid #ffd76a; z-index: 2; pointer-events: none; box-shadow: 0 0 18px #ffb62788; }
.round-snd { position: absolute; z-index: 3; right: 16px; bottom: 16px; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: #000a; color: #fff; opacity: .85; }
.round-vid.playing .round-snd { background: var(--honey); color: var(--on-honey, #111); }
.round-modal { max-width: 360px; }
.round-rec { position: relative; width: 260px; height: 260px; margin: 6px auto; border-radius: 50%; }
.round-rec video { position: absolute; inset: 8px; width: calc(100% - 16px); height: calc(100% - 16px); object-fit: cover; border-radius: 50%; background: #000; }
.round-rec video.mirror { transform: scaleX(-1); }
.rec-ring { --p: 0; position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(#ff2d55 calc(var(--p) * 360deg), var(--panel-3) 0); }
.round-rec.aura .rec-ring { box-shadow: 0 0 24px #ffb62777; }
@media (max-width: 520px) { .round-vid { width: 180px; height: 180px; } .item-grid { grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); } .reel-cell { width: 70px; height: 70px; font-size: 34px; } }
.item-grid > .muted { grid-column: 1 / -1; }
/* Строка участника: длинный ник сокращается, а тег, корона и значки остаются видны */
.mr-name { display: flex; align-items: center; gap: 3px; min-width: 0; overflow: hidden; }
.mr-name .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 0 1 auto; }
.mr-name > :not(.nm) { flex: none; }
.mr-name .clan-tag { margin-right: 2px; }
/* ── Этап 3: тематические рамки ── */
.deco-pulse { transform-origin: 50px 50px; animation: deco-pulse 3.2s ease-in-out infinite; }
@keyframes deco-pulse { 50% { opacity: .5; transform: scale(1.04); } }
.deco-spin-rev { transform-origin: 50px 50px; animation: deco-spin 8s linear infinite reverse; }
.deco-gear { transform-box: fill-box; transform-origin: center; animation: deco-spin 6s linear infinite; }
.deco-gear.rev { animation-direction: reverse; animation-duration: 4.2s; }
[data-motion="off"] .deco-pulse, [data-motion="off"] .deco-spin-rev, [data-motion="off"] .deco-gear { animation: none; }
/* ── Этап 3: верификация, команда, удалённые ── */
.verified-badge.big { width: 34px; height: 34px; display: inline-grid; place-items: center; border-radius: 50%; }
.verify-row { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: 12px; background: var(--panel-2); }
.vstatus { flex: none; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 8px; background: var(--panel-3); }
.vstatus.good { background: #4ade8026; color: #4ade80; } .vstatus.bad { background: #ff6b6b26; color: #ff8080; } .vstatus.warm { background: #fbbf2426; color: #fbbf24; }
.verify-reason { white-space: pre-wrap; overflow-wrap: anywhere; padding: 8px 10px; border-radius: 10px; background: var(--panel); }
.team-cat { display: flex; align-items: center; gap: 8px; }
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.team-card { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 18px 12px; border-radius: 18px; background: var(--panel-2); border: 1px solid var(--line, #ffffff14); text-align: center; transition: transform .15s; min-width: 0; }
.team-card:hover { transform: translateY(-2px); }
.team-name { display: flex; align-items: center; gap: 4px; margin-top: 6px; max-width: 100%; } .team-name b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.team-title { font-weight: 700; color: var(--honey); font-size: 14px; } .team-desc { overflow-wrap: anywhere; }
.deleted-modal { max-width: 560px; }
.deleted-list { display: flex; flex-direction: column; gap: 8px; max-height: 65vh; overflow-y: auto; }
.deleted-msg { display: flex; gap: 10px; padding: 10px; border-radius: 12px; background: var(--panel-2); border-left: 3px solid #ff6b6b88; }
.deleted-text { white-space: pre-wrap; overflow-wrap: anywhere; margin: 2px 0; }
.deleted-by { color: #ff9a9a; display: flex; align-items: center; gap: 4px; margin-top: 4px; }
.team-page { display: flex; flex-direction: column; gap: 12px; width: 100%; } .team-page .team-grid { width: 100%; }
/* Приложение для Windows */
.app-modal { max-width: 440px; }
.app-hero { display: flex; align-items: center; gap: 14px; }
.app-hero img { border-radius: 18px; flex: none; }
.app-dl { display: flex; align-items: center; gap: 12px; text-align: left; text-decoration: none; padding: 12px 16px; }
.app-dl small { display: block; font-weight: 500; opacity: .8; }
.app-note { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; border-radius: 12px; background: var(--panel-2); color: var(--muted); font-size: 13px; }
.app-note .ico { flex: none; margin-top: 2px; }
.sha { display: block; word-break: break-all; margin-top: 6px; font-size: 11px; }
/* ── Исправления: карточка профиля ── */
/* Прокручивается только содержимое: эффект частиц и голографический блик остаются на всю высоту карточки */
.pcard { overflow: hidden; display: flex; flex-direction: column; }
.pcard-scroll { position: relative; z-index: 0; overflow-y: auto; max-height: 88vh; scrollbar-width: none; border-radius: inherit; }
.pcard-scroll::-webkit-scrollbar { display: none; }
.pcard .pfx { z-index: 2; }
/* Тема профиля медленно переливается */
.pcard.themed { background: linear-gradient(170deg, color-mix(in srgb, var(--t1) 62%, #0b0716), color-mix(in srgb, var(--t2) 52%, #0b0716), color-mix(in srgb, var(--t1) 48%, #0b0716)); background-size: 100% 300%; animation: theme-flow 14s ease-in-out infinite alternate; }
@keyframes theme-flow { to { background-position: 0 100%; } }
:root[data-motion="off"] .pcard.themed { animation: none; }
.pcard-name .b3d { margin-left: 6px; }
/* Реакции на цветных пузырях Gold: своя подложка, чтобы не сливались с фоном сообщения */
.msg .bubble[class*="bub-"] .react { background: #0000004d; color: #fff; border-color: #ffffff2e; backdrop-filter: blur(4px); }
.msg .bubble[class*="bub-"] .react.mine { background: color-mix(in srgb, var(--honey) 45%, #0008); border-color: #ffffffaa; }
.msg .bubble[class*="bub-"] .react b, .msg .bubble[class*="bub-"] .react span { color: inherit; }
/* Кнопка «+» с инструментами видна только там, где сами инструменты спрятаны (узкий экран) */
.composer .opt-more { display: none; }
@media (max-width: 820px) { .composer .opt-more { display: grid; } }
/* ── Кружки как в Telegram ── */
.msg.round-msg .bubble { background: none !important; border: 0 !important; box-shadow: none !important; padding: 0 !important; max-width: none; }
.msg.round-msg .bubble::before, .msg.round-msg .bubble::after { display: none !important; }
.msg.round-msg .round-vid { margin: 4px 6px; }
.msg.round-msg .body { display: inline-flex; align-items: center; gap: 6px; margin-top: 2px; padding: 4px 10px; border-radius: 14px; background: var(--panel-2); max-width: 260px; }
.msg.round-only .body { position: relative; margin-top: -34px; margin-left: auto; margin-right: 10px; width: max-content; padding: 2px 8px; background: #0009; color: #fff; z-index: 3; font-size: 11px; }
.msg.round-only .body .meta { color: #fff; margin: 0; }
.msg.mine.round-msg .bubble { align-items: flex-end; }
.round-ring { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; pointer-events: none; opacity: 0; transition: opacity .2s; }
.round-vid.playing .round-ring { opacity: 1; }
.round-time { position: absolute; z-index: 3; left: 14px; bottom: 14px; padding: 1px 7px; border-radius: 8px; background: #0009; color: #fff; font: 600 11px/1.5 system-ui; }
.round-time:empty { display: none; }
.round-vid .round-snd { right: auto; left: 50%; bottom: auto; top: 50%; transform: translate(-50%, -50%); width: 34px; height: 34px; opacity: 0; transition: opacity .2s; }
.round-vid:not(.playing):hover .round-snd, .round-vid.paused .round-snd { opacity: .85; }
.round-vid.paused video { filter: brightness(.7); }
.msg.round-only .bubble { position: relative; }
.msg.round-only .body { position: absolute; margin: 0; right: 16px; bottom: 16px; }
.msg.round-only .reacts { margin: 0 6px; }
/* ── Витрина как подарки в Telegram ── */
.tg-gifts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.tg-gift { --rc: #999; position: relative; aspect-ratio: 1 / 1.08; border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0;
  background: radial-gradient(circle at 50% 42%, color-mix(in srgb, var(--rc) 75%, #fff 10%), color-mix(in srgb, var(--rc) 45%, #100818) 75%); border: 1px solid color-mix(in srgb, var(--rc) 60%, transparent); transition: transform .15s; }
.tg-gift:hover { transform: translateY(-2px) scale(1.02); }
.tg-pattern { position: absolute; inset: -10%; display: grid; grid-template-columns: repeat(3, 1fr); place-items: center; opacity: .16; transform: rotate(-12deg); pointer-events: none; font-size: 22px; filter: grayscale(.3); }
.tg-emoji { position: relative; font-size: 44px; line-height: 1; }
.tg-serial { position: absolute; bottom: 6px; font: 700 11px/1 system-ui; color: #fff; padding: 2px 7px; border-radius: 99px; background: #0005; }
.tg-from { position: absolute; top: 6px; left: 6px; z-index: 2; }
.tg-from .ava { --size: 22px; }
.tg-ribbon { position: absolute; top: 9px; right: -26px; transform: rotate(40deg); width: 96px; text-align: center; font: 800 9px/1.7 system-ui; color: #fff; background: color-mix(in srgb, var(--rc) 80%, #000); box-shadow: 0 2px 6px #0005; letter-spacing: .02em; }
.r-legendary.tg-gift, .r-mythic.tg-gift { animation: rare-glow 3s ease-in-out infinite; }
.tg-hero { --rc: #999; position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 22px 12px 16px; border-radius: 18px;
  background: radial-gradient(circle at 50% 35%, color-mix(in srgb, var(--rc) 80%, #fff 10%), color-mix(in srgb, var(--rc) 40%, #100818) 80%); color: #fff; text-align: center; }
.tg-hero .tg-pattern { font-size: 30px; opacity: .14; }
.tg-hero-emoji { position: relative; font-size: 84px; line-height: 1.1; filter: drop-shadow(0 8px 18px #0007); }
.tg-hero b { position: relative; font-size: 20px; } .tg-hero-sub { position: relative; opacity: .85; font-size: 13px; }
.tg-table { display: flex; flex-direction: column; border-radius: 14px; overflow: hidden; border: 1px solid var(--line, #ffffff14); }
.tg-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 9px 12px; background: var(--panel-2); }
.tg-row + .tg-row { border-top: 1px solid var(--line, #ffffff10); }
.tg-link { gap: 6px; color: var(--honey); font-weight: 600; }
.tg-note { padding: 10px 14px; border-radius: 14px; background: var(--panel-2); font-style: italic; overflow-wrap: anywhere; }
.pcard.themed .tg-row { background: #0000002e; }
/* ── Плашка «Главная» над списком чатов ── */
.home-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(64px, 1fr)); gap: 6px; padding: 2px 10px 8px; }
.home-tile { position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 4px 6px; border-radius: 12px; background: var(--panel-2); color: var(--muted); border: 1px solid transparent; transition: background .15s, color .15s; min-width: 0; }
.home-tile:hover { color: var(--text); background: color-mix(in srgb, var(--honey) 12%, var(--panel-2)); }
.home-tile.active { color: var(--text); border-color: color-mix(in srgb, var(--honey) 55%, transparent); background: color-mix(in srgb, var(--honey) 18%, var(--panel-2)); }
.ht-ico { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 10px; background: color-mix(in srgb, var(--honey) 16%, transparent); color: var(--honey); }
.ht-label { font-size: 11.5px; font-weight: 650; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ht-dot { position: absolute; top: 6px; right: 8px; width: 8px; height: 8px; border-radius: 50%; } .ht-dot.gold { background: #ffc83d; box-shadow: 0 0 6px #ffc83d; }
.gold-btn.on { background: linear-gradient(120deg, #ffc83d33, #ff7ab833); border-color: #ffc83d88; }
/* Иконки в плитках главной: раньше были того же цвета, что и фон плитки, и пропадали */
.quick .q-ico, .quick .q-ico .ico, .quick button:hover .q-ico .ico { color: #fff !important; stroke: currentColor; filter: drop-shadow(0 1px 1px #0004); }
/* Плашка «Вышло обновление» */
.update-bar { position: fixed; z-index: 70; left: 50%; bottom: 18px; transform: translateX(-50%); display: flex; align-items: center; gap: 10px; padding: 8px 10px 8px 14px; border-radius: 14px; background: var(--panel); border: 1px solid color-mix(in srgb, var(--honey) 50%, transparent); box-shadow: 0 14px 40px #0008; max-width: calc(100vw - 24px); animation: tray-in .2s ease-out; }
.update-bar .ico:first-child { color: var(--honey); }
.gift-limit-row { display: flex; align-items: center; gap: 10px; padding: 6px 10px; border-radius: 12px; background: var(--panel-2); flex-wrap: wrap; }
.gift-limit-row label { display: flex; flex-direction: column; gap: 2px; } .gift-limit-row .input { width: 96px; padding: 6px 8px; }
.hero-emoji.small { font-size: 26px; }
/* Перенос из Discord */
.dimport { display: flex; flex-direction: column; gap: 12px; }
.dimport-step { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border-radius: 14px; background: var(--panel-2); }
.dimport-step > div { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; min-width: 0; }
.dstep-n { flex: none; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: #5865f2; color: #fff; }
.dimport-code { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.dcode { font: 800 26px/1.2 ui-monospace, monospace; letter-spacing: .12em; padding: 6px 12px; border-radius: 10px; background: var(--panel); border: 1px dashed var(--honey); }
.dcmd { padding: 4px 8px; border-radius: 8px; background: var(--panel); }
/* Вспышка экраном для фронтальной камеры: всё вокруг видео становится белым */
body.screen-flash .overlay:has(.round-modal) { background: #fff; }
body.screen-flash .round-modal { background: #fff; color: #222; box-shadow: 0 0 0 100vmax #fff; }
body.screen-flash .voice-stage, body.screen-flash .main.voice-main { background: #fff !important; }
body.screen-flash .voice-stage .tile { box-shadow: 0 0 0 6px #fff, 0 0 60px 30px #fff; }
.btn.on { box-shadow: inset 0 0 0 2px var(--honey); }
/* Плитка голосового в оформлении профиля */
.voice-stage .tile.tile-flair { overflow: hidden; }
.voice-stage .tile.tile-theme { background: linear-gradient(150deg, color-mix(in srgb, var(--t1) 70%, #0b0716), color-mix(in srgb, var(--t2) 60%, #0b0716)); }
.voice-stage .tile .pfx { z-index: 0; }
.voice-stage .tile.tile-flair > .ava { position: relative; z-index: 1; filter: drop-shadow(0 6px 18px #0007); }
/* Трибуна: слушатели мельче и приглушены, у ведущего кнопки «На сцену / Со сцены» */
.voice-stage .tile.audience { opacity: .78; transform: scale(.86); }
.voice-stage .tile.audience .ava { filter: grayscale(.35); }
.stage-mod-btn { margin-left: 6px; padding: 1px 8px; border-radius: 8px; background: var(--honey); color: var(--on-honey, #1c1405); font: 700 11px/1.6 system-ui; }
.ctl-emoji { font-size: 20px; line-height: 1; }
/* ── Новое анимированное оформление ── */
@keyframes flow-x { to { background-position: 200% 0; } }
@keyframes flow-xy { to { background-position: 100% 100%; } }
@keyframes stars-drift { to { background-position: 40px 20px, -60px 30px, 0 0; } }
/* Плашки ника */
.plate-plasma::before { background: linear-gradient(90deg, #ff3ea5, #7c3aed, #33e1ff, #7c3aed, #ff3ea5); background-size: 200% 100%; animation: flow-x 5s linear infinite; }
.plate-galaxy::before { background: radial-gradient(circle, #fff 0 1px, transparent 1.5px) 0 0 / 18px 18px, radial-gradient(circle, #fffa 0 1px, transparent 1.5px) 9px 7px / 26px 26px, linear-gradient(90deg, #05030f, #2a1060 60%, #6d28d9); animation: stars-drift 8s linear infinite; }
.plate-inferno::before { background: linear-gradient(0deg, #ff6a00, #ffb627 30%, transparent 70%) 0 100% / 100% 200%, linear-gradient(90deg, #1a0505, #5a0d0d); animation: flow-xy 2.4s ease-in-out infinite alternate; }
.plate-prism::before { background: linear-gradient(90deg, #ff4d6d, #ffb627, #a3e635, #22d3ee, #a78bfa, #ff4d6d); background-size: 300% 100%; opacity: .85; animation: flow-x 7s linear infinite; }
/* Цвета сообщений */
.msg .bubble.bub-aurora, .msg.mine .bubble.bub-aurora { background: linear-gradient(120deg, #04121a, #0f766e, #6d28d9, #04121a); background-size: 300% 100%; animation: flow-x 9s linear infinite; color: #eafffb; border-color: #5eead455; }
.msg .bubble.bub-gold, .msg.mine .bubble.bub-gold { background: linear-gradient(110deg, #3a2600 0%, #a16207 40%, #fde68a 50%, #a16207 60%, #3a2600 100%); background-size: 250% 100%; animation: flow-x 4s linear infinite; color: #fffbea; border-color: #fde68a88; }
.msg .bubble.bub-plasma, .msg.mine .bubble.bub-plasma { background: linear-gradient(135deg, #ff3ea5, #7c3aed, #33e1ff, #ff3ea5); background-size: 300% 300%; animation: flow-xy 6s ease-in-out infinite alternate; color: #fff; border-color: #ffffff44; }
.bub-aurora.sw, .bubble-demo.bub-aurora { background: linear-gradient(120deg, #04121a, #0f766e, #6d28d9); background-size: 200% 100%; animation: flow-x 9s linear infinite; }
.bub-gold.sw, .bubble-demo.bub-gold { background: linear-gradient(110deg, #3a2600, #a16207 40%, #fde68a 50%, #a16207 60%, #3a2600); background-size: 250% 100%; animation: flow-x 4s linear infinite; }
.bub-plasma.sw, .bubble-demo.bub-plasma { background: linear-gradient(135deg, #ff3ea5, #7c3aed, #33e1ff); background-size: 300% 300%; animation: flow-xy 6s ease-in-out infinite alternate; }
/* Баннеры профиля */
.banner-matrix { background: repeating-linear-gradient(90deg, transparent 0 14px, #22c55e22 14px 15px), linear-gradient(180deg, #22c55e55, transparent 30%, #22c55e33 60%, transparent) 0 0 / 100% 200%, #020a04; animation: flow-xy 3s linear infinite; }
.banner-plasma { background: linear-gradient(135deg, #ff3ea5, #7c3aed, #33e1ff, #7c3aed, #ff3ea5); background-size: 300% 300%; animation: flow-xy 8s ease-in-out infinite alternate; }
.banner-sunrise { background: radial-gradient(circle at 50% 120%, #ffe14d 0 18%, #ff6b3d 35%, transparent 60%), linear-gradient(180deg, #1b0f4a, #ff3ea5 70%, #ffb627); background-size: 100% 160%; animation: flow-xy 10s ease-in-out infinite alternate; }
.banner-matrix.sw, .banner-plasma.sw, .banner-sunrise.sw { background-size: 200% 200%; }
/* Эффекты профиля */
.pfx-leaves span { color: #6cc04a; } .pfx-notes span { color: #c4b5fd; text-shadow: 0 0 6px #7c3aed; }
.pfx-fireflies span { top: auto; bottom: -24px; animation-name: pfx-rise; color: #fef08a; text-shadow: 0 0 8px #facc15, 0 0 16px #facc15; }
.pfx-coins span { filter: drop-shadow(0 0 4px #fbbf24); }
:root[data-motion="off"] [class*="plate-"]::before, :root[data-motion="off"] .bubble[class*="bub-"], :root[data-motion="off"] [class*="banner-"] { animation: none !important; }
.danger-zone { border: 1px solid #ff6b6b55; border-radius: 12px; padding: 8px 12px; display: flex; flex-direction: column; gap: 8px; }
.danger-zone summary { cursor: pointer; color: #ff8080; font-weight: 700; }
.danger-zone[open] { gap: 10px; } .danger-zone > * + * { margin-top: 8px; }
.auth-privacy { text-align: center; text-decoration: underline; }
/* Вспышка экраном: белый слой на весь экран (над звонком) или под окном записи кружка */
.flash-layer { position: fixed; inset: 0; z-index: 95; background: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; animation: flash-in .15s ease-out; }
.flash-layer.below { z-index: 45; }
@keyframes flash-in { from { opacity: 0; } }
.flash-self { width: 160px; height: 160px; border-radius: 50%; object-fit: cover; transform: scaleX(-1); box-shadow: 0 0 0 4px #f0f0f0, 0 10px 30px #0002; }
.flash-off { background: #111; color: #fff; }
body.screen-flash .overlay:has(.round-modal) { background: transparent !important; backdrop-filter: none !important; }
.temp-mark { font-size: 12px; opacity: .8; margin-left: 2px; }

/* ── Боты, привязки, музыка, визуализатор, стикерпаки ── */
.bot-badge { display: inline-block; font-size: 10px; font-weight: 700; line-height: 1; padding: 3px 5px; border-radius: 4px; background: #5865f2; color: #fff; margin-left: 4px; vertical-align: 2px; letter-spacing: .3px; }
.link-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.link-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px; background: var(--panel-2); border: 1px solid color-mix(in srgb, var(--lc) 55%, transparent); color: var(--text); text-decoration: none; font-size: 13px; }
.link-chip b { color: var(--lc); }
.link-row { display: grid; gap: 8px; padding: 12px; border-radius: 12px; background: var(--panel-2); border-left: 3px solid var(--lc); margin-top: 10px; }
.link-row .input { flex: 1; min-width: 140px; }
.row.wrap { flex-wrap: wrap; }
.music-panel { display: grid; gap: 10px; min-width: min(520px, 100%); }
.music-head { display: flex; gap: 10px; align-items: center; }
.music-ico { font-size: 26px; }
.music-seek { width: 100%; }
.music-ctl { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.music-ctl .icon-btn.on { color: var(--honey); }
.music-vol { display: flex; gap: 6px; align-items: center; }
.music-vol input { width: 110px; }
.music-add { display: flex; gap: 6px; flex-wrap: wrap; }
.music-queue { max-height: 240px; overflow-y: auto; display: grid; gap: 2px; }
.mq-row { display: flex; gap: 6px; align-items: center; padding: 4px 6px; border-radius: 8px; }
.mq-row.now { background: var(--panel-2); color: var(--honey); }
.mq-title { text-align: left; background: none; border: 0; color: inherit; cursor: pointer; font: inherit; min-width: 0; }
.lib-list { display: grid; gap: 6px; max-height: 50vh; overflow-y: auto; margin-top: 10px; }
.lib-row { display: flex; gap: 10px; align-items: center; padding: 8px; border-radius: 10px; background: var(--panel-2); min-width: 0; }
.lib-row .grow { min-width: 0; }
.viz-corner { position: fixed; top: 0; z-index: 40; pointer-events: none; transition: opacity .25s; }
.viz-corner.left { left: 0; }
.viz-corner.right { right: 0; }
.viz-corner.peek { opacity: 0 !important; }
.viz-settings { display: grid; gap: 10px; }
.viz-corner-set { display: grid; gap: 6px; padding: 10px; border-radius: 10px; background: var(--panel-2); }
.xp-stickers { display: grid; grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); gap: 6px; padding: 6px; }
.xp-stickers button { background: none; border: 0; padding: 4px; border-radius: 8px; cursor: pointer; }
.xp-stickers button:hover { background: var(--panel-2); }
.xp-stickers img { width: 100%; aspect-ratio: 1; object-fit: contain; }
.xp-store { margin: 8px; }
.sticker-store { display: grid; gap: 12px; }
.pack-body { display: grid; gap: 10px; }
.pack-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.pack-card { display: grid; gap: 4px; text-align: left; padding: 10px; border-radius: 12px; background: var(--panel-2); border: 1px solid var(--line); color: var(--text); cursor: pointer; font: inherit; min-width: 0; }
.pack-card:hover { border-color: var(--honey); }
.pack-card img, .pack-empty { width: 100%; aspect-ratio: 1; object-fit: contain; display: grid; place-items: center; font-size: 34px; }
.pack-status { font-size: 11px; color: var(--muted); }
.pack-status.published { color: var(--mint); }
.pack-status.rejected, .pack-status.hidden { color: #ff6b6b; }
.rarity-chip { font-size: 11px; font-weight: 700; color: var(--rc); border: 1px solid var(--rc); border-radius: 999px; padding: 1px 7px; }
.pack-modal { display: grid; gap: 12px; }
.pack-cover { width: 96px; height: 96px; object-fit: contain; }
.pack-stickers { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 8px; }
.pack-st { position: relative; background: var(--panel-2); border-radius: 10px; padding: 6px; }
.pack-st img { width: 100%; aspect-ratio: 1; object-fit: contain; }
.pack-st .icon-btn { position: absolute; top: 2px; right: 2px; }
.crop-canvas { width: min(320px, 100%); aspect-ratio: 1; border-radius: 12px; background: repeating-conic-gradient(#2a2a2e 0 25%, #1c1c20 0 50%) 0 0 / 20px 20px; justify-self: center; }
.col.gap { display: grid; gap: 10px; }