:root {
  --bg: #06060c;
  --bg2: #0b0b16;
  --panel: rgba(18, 18, 36, .72);
  --panel-2: rgba(28, 28, 56, .65);
  --line: rgba(255, 255, 255, .07);
  --line-2: rgba(255, 255, 255, .13);
  --text: #ecebff;
  --muted: #8b8aab;
  --dim: #5b5a78;
  --cyan: #00f0ff;
  --pink: #ff2bd6;
  --violet: #8b5cf6;
  --lime: #a3ff12;
  --yellow: #ffd60a;
  --danger: #ff3b6b;
  --r: 18px;
  --r-sm: 12px;
  --font: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Unbounded", "Manrope", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --tabbar-h: 68px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--font); }
body { min-height: 100vh; overflow-x: hidden; font-size: 15px; line-height: 1.4; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
a { color: var(--cyan); text-decoration: none; }
::selection { background: var(--pink); color: #000; }
::-webkit-scrollbar { width: 0; height: 0; }

/* ── фон ── */
.bg-grid {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background-image:
    linear-gradient(rgba(0, 240, 255, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 240, 255, .045) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 0%, transparent 75%);
}
.bg-glow { position: fixed; z-index: -1; width: 70vw; height: 70vw; border-radius: 50%; filter: blur(90px); opacity: .22; pointer-events: none; }
.bg-glow.g1 { background: var(--violet); top: -30vw; left: -20vw; }
.bg-glow.g2 { background: var(--pink); bottom: -35vw; right: -25vw; opacity: .14; }

/* ── шапка ── */
.topbar {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; background: linear-gradient(var(--bg) 60%, transparent);
}
.logo {
  font-family: var(--display); font-weight: 900; font-size: 17px; letter-spacing: .02em; color: #fff;
  text-shadow: 0 0 12px rgba(0, 240, 255, .7), 0 0 28px rgba(0, 240, 255, .35); position: relative;
}
.logo i { font-style: normal; color: var(--pink); text-shadow: 0 0 12px var(--pink); }
.topbar-right { display: flex; gap: 8px; align-items: center; }
.chip-balance {
  display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 99px;
  background: rgba(163, 255, 18, .08); border: 1px solid rgba(163, 255, 18, .35); color: var(--lime);
  font-weight: 800; font-size: 14px; box-shadow: 0 0 18px rgba(163, 255, 18, .15) inset;
}
.chip-balance .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 10px var(--lime); animation: pulse 2s infinite; }
.icon-btn {
  height: 36px; min-width: 36px; padding: 0 10px; border-radius: 12px; border: 1px solid var(--line-2);
  background: var(--panel); font-weight: 800; font-size: 12px; letter-spacing: .05em;
}
@keyframes pulse { 50% { opacity: .35; } }

/* выпадающий список языков */
.lang-dd { position: relative; }
.lang-dd-btn { display: flex; align-items: center; gap: 6px; }
.lang-dd-btn .chev { transition: transform .2s; opacity: .7; }
.lang-dd.open .lang-dd-btn { border-color: var(--cyan); color: var(--cyan); box-shadow: 0 0 12px rgba(0, 240, 255, .25); }
.lang-dd.open .chev { transform: rotate(180deg); }
.lang-menu {
  position: absolute; top: calc(100% + 8px); right: 0; min-width: 172px; padding: 6px; z-index: 30;
  background: rgba(14, 14, 30, .96); border: 1px solid var(--line-2); border-radius: 14px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, .55), 0 0 18px rgba(0, 240, 255, .12); backdrop-filter: blur(12px);
  opacity: 0; transform: translateY(-6px) scale(.97); transform-origin: top right; pointer-events: none;
  transition: opacity .16s, transform .16s;
}
.lang-dd.open .lang-menu { opacity: 1; transform: none; pointer-events: auto; }
.lang-menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; height: 40px; padding: 0 10px; border: 0; border-radius: 10px;
  background: transparent; color: var(--text); font-size: 14px; text-align: left; cursor: pointer;
}
.lang-menu button b { width: 26px; font-size: 12px; letter-spacing: .05em; color: var(--muted); }
.lang-menu button span { flex: 1; }
.lang-menu button i { font-style: normal; color: var(--cyan); }
.lang-menu button:hover { background: var(--panel-2); }
.lang-menu button.active { color: var(--cyan); background: rgba(0, 240, 255, .07); }
.lang-menu button.active b { color: var(--cyan); }

.sandbox-ribbon {
  margin: 0 16px 6px; padding: 6px 10px; border-radius: 12px; font-size: 11px; color: var(--yellow);
  border: 1px dashed rgba(255, 214, 10, .35); background: rgba(255, 214, 10, .05);
  display: flex; align-items: center; gap: 8px;
}
.sandbox-ribbon > span:first-child { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sandbox-ribbon > span + span { flex: none; }
.sandbox-ribbon:empty { display: none; }
.sandbox-ribbon select { background: transparent; border: 1px solid rgba(255, 214, 10, .35); border-radius: 8px; padding: 2px 6px; color: var(--yellow); }

.view { padding: 4px 16px calc(var(--tabbar-h) + var(--safe-b) + 96px); animation: viewIn .25s ease; }   /* +место под плавающую кнопку менеджера */
@keyframes viewIn { from { opacity: 0; transform: translateY(6px); } }

/* ── таббар ── */
.tabbar {
  position: fixed; left: 10px; right: 10px; bottom: calc(10px + var(--safe-b)); z-index: 30;
  height: var(--tabbar-h); display: flex; justify-content: space-around; align-items: center;
  background: rgba(12, 12, 26, .82); backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--line-2); border-radius: 22px; box-shadow: 0 10px 40px rgba(0, 0, 0, .5);
}
.tab { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--dim); font-size: 10.5px; font-weight: 700; padding: 8px 0; transition: color .2s; }
.tab .ico { font-size: 20px; filter: grayscale(1) brightness(.75); transition: .2s; }
.tab.active { color: var(--cyan); }
.tab.active .ico { filter: none; transform: translateY(-2px); text-shadow: 0 0 14px var(--cyan); }
.tab.active::after { content: ""; position: absolute; bottom: 2px; width: 18px; height: 3px; border-radius: 3px; background: var(--cyan); box-shadow: 0 0 10px var(--cyan); }
.tab .badge { position: absolute; top: 2px; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--pink); color: #fff; font-size: 10.5px; display: grid; place-items: center; box-shadow: 0 0 10px var(--pink); }

/* ── общие элементы ── */
h1, h2, h3 { font-family: var(--display); margin: 0; letter-spacing: .01em; }
.h-section { display: flex; justify-content: space-between; align-items: baseline; margin: 22px 2px 12px; }
.h-section h2 { font-size: 15px; font-weight: 700; }
.h-section small { color: var(--muted); font-size: 12px; }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); }
.row { display: flex; gap: 10px; align-items: center; }
.grow { flex: 1; min-width: 0; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; backdrop-filter: blur(10px); }
.panel + .panel { margin-top: 12px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 46px; padding: 0 18px;
  border-radius: 14px; font-weight: 800; font-size: 14.5px; transition: transform .1s, box-shadow .2s, opacity .2s; white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn-primary { background: linear-gradient(100deg, var(--cyan), var(--violet) 60%, var(--pink)); color: #05050a; box-shadow: 0 0 24px rgba(0, 240, 255, .35), 0 0 40px rgba(255, 43, 214, .2); }
.btn-ghost { background: var(--panel-2); border: 1px solid var(--line-2); color: var(--text); }
.btn-outline { border: 1px solid var(--cyan); color: var(--cyan); background: rgba(0, 240, 255, .06); box-shadow: 0 0 14px rgba(0, 240, 255, .15) inset; }
.btn-danger { border: 1px solid rgba(255, 59, 107, .5); color: var(--danger); background: rgba(255, 59, 107, .08); }
.btn-sm { height: 34px; padding: 0 12px; border-radius: 10px; font-size: 13px; }
.btn-block { width: 100%; }

.input, .select, .textarea {
  width: 100%; height: 46px; padding: 0 14px; border-radius: 14px; background: rgba(8, 8, 18, .7);
  border: 1px solid var(--line-2); outline: none; transition: border-color .2s, box-shadow .2s;
}
.textarea { height: auto; min-height: 110px; padding: 12px 14px; resize: vertical; font-family: var(--mono); font-size: 13px; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(0, 240, 255, .12), 0 0 18px rgba(0, 240, 255, .15); }
.select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
.select option { background: var(--bg2); }
label.field { display: block; margin-bottom: 12px; }
label.field > span { display: block; font-size: 12px; color: var(--muted); margin: 0 0 6px 4px; font-weight: 600; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.switch { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-radius: 14px; background: rgba(8, 8, 18, .7); border: 1px solid var(--line-2); margin-bottom: 12px; }
.switch input { width: 44px; height: 26px; appearance: none; background: var(--dim); border-radius: 13px; position: relative; transition: .2s; cursor: pointer; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: .2s; }
.switch input:checked { background: var(--cyan); box-shadow: 0 0 12px var(--cyan); }
.switch input:checked::after { left: 21px; }

/* ── поиск и чипы ── */
.search { position: relative; display: flex; gap: 8px; }
.search .input { padding-left: 42px; }
.search::before { content: "⌕"; position: absolute; left: 15px; top: 50%; transform: translateY(-52%); font-size: 20px; color: var(--muted); pointer-events: none; }
.search .filter-btn { width: 46px; flex: none; border-radius: 14px; border: 1px solid var(--line-2); background: var(--panel); font-size: 18px; position: relative; }
.search .filter-btn.on { border-color: var(--pink); box-shadow: 0 0 14px rgba(255, 43, 214, .35); }
.search .filter-btn.on::after { content: ""; position: absolute; top: 8px; right: 8px; width: 7px; height: 7px; background: var(--pink); border-radius: 50%; }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 12px 2px 4px; margin: 0 -16px; padding-left: 16px; padding-right: 16px; scroll-snap-type: x proximity; }
.chips.sub { padding-top: 4px; }
.chip {
  --c: var(--cyan); flex: none; display: flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px;
  border-radius: 99px; border: 1px solid var(--line-2); background: var(--panel); font-weight: 700; font-size: 13px;
  color: var(--muted); transition: .2s; scroll-snap-align: start;
}
.chips.sub .chip { height: 32px; font-size: 12px; padding: 0 12px; }
.chip.active { color: #fff; border-color: var(--c); background: color-mix(in srgb, var(--c) 14%, transparent); box-shadow: 0 0 16px color-mix(in srgb, var(--c) 40%, transparent), inset 0 0 12px color-mix(in srgb, var(--c) 20%, transparent); }
.chip small { opacity: .6; font-weight: 600; }

/* ── баннер ── */
.hero {
  position: relative; overflow: hidden; margin-top: 14px; border-radius: 22px; padding: 18px; min-height: 118px;
  background: linear-gradient(120deg, rgba(139, 92, 246, .35), rgba(255, 43, 214, .22) 55%, rgba(0, 240, 255, .18));
  border: 1px solid rgba(255, 255, 255, .12);
}
.hero::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(0deg, rgba(255, 255, 255, .03) 0 2px, transparent 2px 4px); pointer-events: none; }
.hero h3 { font-size: 19px; font-weight: 900; line-height: 1.15; max-width: 70%; text-shadow: 0 0 18px rgba(255, 43, 214, .6); }
.hero p { margin: 6px 0 12px; font-size: 13px; color: #d8d6ff; max-width: 70%; }
.hero .code { display: inline-flex; gap: 8px; align-items: center; font-family: var(--mono); font-weight: 600; font-size: 13px; padding: 6px 12px; border-radius: 10px; background: rgba(0, 0, 0, .45); border: 1px dashed var(--cyan); color: var(--cyan); }
.hero .art { position: absolute; right: -6px; bottom: -14px; font-size: 92px; transform: rotate(-12deg); filter: drop-shadow(0 0 24px rgba(0, 240, 255, .6)); }

/* ── карточки товаров ── */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 960px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } .view { max-width: 1100px; margin: 0 auto; } }
.card {
  --c: var(--cyan); position: relative; display: flex; flex-direction: column; border-radius: var(--r); overflow: hidden;
  background: var(--panel); border: 1px solid var(--line); transition: transform .15s, border-color .2s, box-shadow .2s; cursor: pointer;
  animation: cardIn .35s backwards;
}
@keyframes cardIn { from { opacity: 0; transform: translateY(10px) scale(.98); } }
.card:active { transform: scale(.98); }
.card:hover { border-color: color-mix(in srgb, var(--c) 55%, transparent); box-shadow: 0 0 22px color-mix(in srgb, var(--c) 22%, transparent); }
.card.out { opacity: .55; }
.card-art {
  position: relative; aspect-ratio: 1.35; display: grid; place-items: center;
  background: radial-gradient(circle at 50% 60%, color-mix(in srgb, var(--c) 35%, transparent), transparent 65%), linear-gradient(160deg, rgba(255, 255, 255, .04), transparent);
  border-bottom: 1px solid var(--line);
}
.card-art .emoji { font-size: 46px; filter: drop-shadow(0 0 16px color-mix(in srgb, var(--c) 80%, transparent)); transition: transform .3s; }
.card:hover .emoji { transform: scale(1.1) rotate(-6deg); }
.card-art .disc { position: absolute; top: 8px; left: 8px; padding: 3px 8px; border-radius: 8px; font-size: 11px; font-weight: 800; background: var(--pink); color: #fff; box-shadow: 0 0 12px var(--pink); }
.card-art .soldout { position: absolute; bottom: 8px; left: 8px; padding: 3px 8px; border-radius: 8px; font-size: 10.5px; font-weight: 800; background: rgba(0, 0, 0, .6); color: var(--muted); border: 1px solid var(--line-2); }
.fav { position: absolute; top: 6px; right: 6px; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: rgba(0, 0, 0, .45); font-size: 16px; color: var(--muted); transition: .2s; }
.fav.on { color: var(--pink); text-shadow: 0 0 10px var(--pink); }
.fav:active { transform: scale(1.3); }
.card-body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card-cat { font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--c); opacity: .9; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-title { font-weight: 700; font-size: 13.5px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.5em; }
.card-meta { font-size: 11.5px; color: var(--muted); display: flex; gap: 8px; }
.star { color: var(--yellow); }
.price-row { display: flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 6px; }
.price { font-family: var(--display); font-weight: 700; font-size: 15px; color: #fff; }
.old { font-size: 11.5px; color: var(--dim); text-decoration: line-through; }
.add-btn { margin-left: auto; width: 34px; height: 34px; border-radius: 11px; font-size: 20px; font-weight: 700; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 18%, transparent); color: var(--c); border: 1px solid color-mix(in srgb, var(--c) 50%, transparent); transition: .15s; }
.add-btn:active { transform: scale(.9); background: var(--c); color: #000; }

.empty { text-align: center; padding: 50px 20px; color: var(--muted); }
.empty .big { font-size: 54px; margin-bottom: 10px; filter: drop-shadow(0 0 20px rgba(0, 240, 255, .5)); }
.empty h3 { color: var(--text); font-size: 16px; margin-bottom: 6px; }
.skeleton { border-radius: var(--r); background: linear-gradient(90deg, var(--panel) 0%, var(--panel-2) 50%, var(--panel) 100%); background-size: 200% 100%; animation: shimmer 1.2s infinite; height: 230px; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ── bottom sheet ── */
.sheet-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(0, 0, 0, .6); backdrop-filter: blur(3px); opacity: 0; pointer-events: none; transition: opacity .25s; }
.sheet-backdrop.open { opacity: 1; pointer-events: auto; }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; max-height: 90vh; display: flex; flex-direction: column;
  background: linear-gradient(180deg, #121226, #0a0a16); border-top: 1px solid rgba(0, 240, 255, .35); border-radius: 26px 26px 0 0;
  box-shadow: 0 -10px 50px rgba(0, 240, 255, .12); transform: translateY(105%); transition: transform .32s cubic-bezier(.2, .9, .25, 1);
}
@media (min-width: 640px) { .sheet { left: 50%; width: 560px; margin-left: -280px; } }
.sheet { visibility: hidden; }
.sheet.open { transform: none; visibility: visible; }
.sheet-handle { width: 42px; height: 5px; border-radius: 3px; background: var(--line-2); margin: 10px auto 0; flex: none; }
.sheet-close { position: absolute; top: 12px; right: 14px; width: 32px; height: 32px; border-radius: 50%; background: var(--panel-2); color: var(--muted); font-size: 14px; }
.sheet-body { overflow-y: auto; padding: 14px 18px calc(22px + var(--safe-b)); }
.sheet-title { font-size: 18px; font-weight: 700; margin: 6px 36px 14px 0; }

.pd-art { --c: var(--cyan); height: 170px; border-radius: 20px; display: grid; place-items: center; font-size: 84px; margin-bottom: 14px; background: radial-gradient(circle at 50% 55%, color-mix(in srgb, var(--c) 40%, transparent), transparent 62%), var(--panel); border: 1px solid color-mix(in srgb, var(--c) 30%, transparent); }
.pd-art span { filter: drop-shadow(0 0 26px var(--c)); animation: float 4s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-8px) rotate(-4deg); } }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.tag { padding: 4px 10px; border-radius: 8px; font-size: 11.5px; font-weight: 700; background: var(--panel-2); border: 1px solid var(--line-2); color: var(--muted); }
.tag.c { color: var(--cyan); border-color: rgba(0, 240, 255, .35); }
.qty { display: flex; align-items: center; border: 1px solid var(--line-2); border-radius: 14px; overflow: hidden; height: 46px; flex: none; }
.qty button { width: 40px; height: 100%; font-size: 20px; color: var(--cyan); }
.qty span { min-width: 30px; text-align: center; font-weight: 800; }
.review { padding: 12px 0; border-top: 1px solid var(--line); }
.review .who { font-weight: 700; font-size: 13px; }
.review p { margin: 4px 0 0; font-size: 13.5px; color: #cfcfe8; }
.stars-input { display: flex; gap: 6px; justify-content: center; margin: 8px 0 16px; }
.stars-input button { font-size: 34px; color: var(--dim); transition: .15s; }
.stars-input button.on { color: var(--yellow); text-shadow: 0 0 14px var(--yellow); transform: scale(1.08); }

/* ── корзина ── */
.line { display: flex; gap: 12px; align-items: center; padding: 12px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); margin-bottom: 10px; }
.line .em { --c: var(--cyan); width: 54px; height: 54px; flex: none; border-radius: 14px; display: grid; place-items: center; font-size: 28px; background: radial-gradient(circle, color-mix(in srgb, var(--c) 30%, transparent), transparent 70%), var(--panel-2); }
.line .t { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.line .qty { height: 36px; border-radius: 11px; }
.line .qty button { width: 32px; font-size: 18px; }
.summary .r { display: flex; justify-content: space-between; padding: 6px 0; color: var(--muted); }
.summary .r.total { color: var(--text); font-weight: 800; font-size: 18px; border-top: 1px dashed var(--line-2); margin-top: 6px; padding-top: 12px; }
.summary .r.total b { font-family: var(--display); color: var(--lime); text-shadow: 0 0 14px rgba(163, 255, 18, .5); }
.promo-ok { color: var(--lime) !important; }

/* ── выдача ── */
.cred { margin-top: 10px; border-radius: 14px; border: 1px solid rgba(0, 240, 255, .3); background: rgba(0, 240, 255, .05); overflow: hidden; }
.cred-h { padding: 10px 12px; display: flex; gap: 8px; align-items: center; font-weight: 700; font-size: 13.5px; border-bottom: 1px solid rgba(0, 240, 255, .15); }
.cred-b { display: flex; gap: 8px; align-items: center; padding: 10px 12px; }
.cred-b code { flex: 1; font-family: var(--mono); font-size: 12px; word-break: break-all; color: var(--cyan); }
.copy { flex: none; width: 34px; height: 34px; border-radius: 10px; background: var(--panel-2); border: 1px solid var(--line-2); font-size: 15px; }
.success-ico { font-size: 64px; text-align: center; margin: 4px 0 8px; filter: drop-shadow(0 0 24px var(--lime)); animation: pop .5s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes pop { from { transform: scale(.3); opacity: 0; } }

/* ── профиль ── */
.profile-card { position: relative; overflow: hidden; text-align: center; padding: 22px 16px 18px; }
.profile-card::before { content: ""; position: absolute; inset: -40%; background: conic-gradient(from 0deg, transparent, rgba(0, 240, 255, .12), transparent, rgba(255, 43, 214, .12), transparent); animation: spin 12s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.profile-card > * { position: relative; }
.avatar { width: 74px; height: 74px; margin: 0 auto 10px; border-radius: 50%; display: grid; place-items: center; font-family: var(--display); font-weight: 900; font-size: 26px; background: var(--bg2); border: 2px solid var(--cyan); box-shadow: 0 0 22px rgba(0, 240, 255, .5), inset 0 0 18px rgba(255, 43, 214, .3); }
.bal-big { font-family: var(--display); font-weight: 900; font-size: 34px; color: var(--lime); text-shadow: 0 0 22px rgba(163, 255, 18, .55); margin: 8px 0 2px; }
.stats-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 14px; }
.stat { padding: 10px 6px; border-radius: 14px; background: rgba(0, 0, 0, .3); border: 1px solid var(--line); }
.stat b { display: block; font-family: var(--display); font-size: 16px; }
.stat small { font-size: 11px; color: var(--muted); }
.topup-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 10px; }
.seg { display: flex; gap: 4px; padding: 4px; border-radius: 14px; background: var(--panel); border: 1px solid var(--line); margin: 18px 0 12px; overflow-x: auto; }
.seg button { flex: 1; height: 36px; padding: 0 10px; border-radius: 10px; font-weight: 700; font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.seg button.active { background: var(--panel-2); color: var(--cyan); box-shadow: 0 0 12px rgba(0, 240, 255, .2), inset 0 0 0 1px rgba(0, 240, 255, .3); }
.order { padding: 14px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); margin-bottom: 10px; }
.order-h { display: flex; justify-content: space-between; align-items: center; cursor: pointer; }
.order-h b { font-family: var(--display); font-size: 14px; }
.order .cred { display: none; }
.order.open .cred { display: block; }
.tx { display: flex; justify-content: space-between; padding: 12px 2px; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.tx .plus { color: var(--lime); font-weight: 800; }
.tx .minus { color: var(--pink); font-weight: 800; }
.ref-link { display: flex; gap: 8px; align-items: center; padding: 10px 12px; border-radius: 14px; background: rgba(0, 0, 0, .35); border: 1px dashed var(--violet); margin: 12px 0; }
.ref-link code { flex: 1; font-family: var(--mono); font-size: 12px; color: var(--violet); word-break: break-all; }
.lang-row { display: flex; gap: 8px; }
.lang-row button { flex: 1; height: 42px; border-radius: 12px; border: 1px solid var(--line-2); background: var(--panel-2); font-weight: 700; font-size: 13px; }
.lang-row button.active { border-color: var(--cyan); color: var(--cyan); box-shadow: 0 0 12px rgba(0, 240, 255, .25); }

/* ── админка ── */
.kpis { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .kpis { grid-template-columns: repeat(4, 1fr); } }
.kpi { padding: 14px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); position: relative; overflow: hidden; }
.kpi::after { content: ""; position: absolute; right: -20px; top: -20px; width: 70px; height: 70px; border-radius: 50%; background: var(--k, var(--cyan)); filter: blur(30px); opacity: .35; }
.kpi small { color: var(--muted); font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.kpi b { display: block; font-family: var(--display); font-size: 22px; margin-top: 4px; }
.kpi em { font-style: normal; font-size: 11.5px; color: var(--lime); }
.bars { display: flex; align-items: flex-end; gap: 8px; height: 140px; padding-top: 10px; }
.bar { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; }
.bar i { width: 100%; max-width: 36px; border-radius: 8px 8px 3px 3px; background: linear-gradient(0deg, var(--violet), var(--cyan)); box-shadow: 0 0 14px rgba(0, 240, 255, .35); min-height: 3px; transition: height .6s cubic-bezier(.2, .9, .25, 1); }
.bar small { font-size: 10px; color: var(--muted); }
.bar b { font-size: 10.5px; font-weight: 700; }
.arow { display: flex; gap: 10px; align-items: center; padding: 12px; border-radius: 14px; background: var(--panel); border: 1px solid var(--line); margin-bottom: 8px; }
.arow .em { width: 40px; height: 40px; flex: none; border-radius: 12px; display: grid; place-items: center; font-size: 20px; background: var(--panel-2); }
.arow .t { font-weight: 700; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.arow .s { font-size: 12px; color: var(--muted); }
.arow .acts { display: flex; gap: 6px; flex: none; }
.arow.child { margin-left: 22px; }
.arow.off { opacity: .5; }
.pill { display: inline-block; padding: 2px 8px; border-radius: 6px; font-size: 11px; font-weight: 800; }
.pill.ok { background: rgba(163, 255, 18, .12); color: var(--lime); }
.pill.warn { background: rgba(255, 214, 10, .12); color: var(--yellow); }
.pill.bad { background: rgba(255, 59, 107, .12); color: var(--danger); }
.item-line { display: flex; gap: 8px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); font-family: var(--mono); font-size: 11.5px; }
.item-line code { flex: 1; word-break: break-all; }
.item-line.sold code { color: var(--dim); text-decoration: line-through; }
.color-input { width: 46px; height: 46px; padding: 4px; border-radius: 14px; border: 1px solid var(--line-2); background: rgba(8, 8, 18, .7); flex: none; }

/* ── тосты ── */
.toasts { position: fixed; top: 12px; left: 12px; right: 12px; z-index: 100; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.toast { max-width: 420px; padding: 12px 16px; border-radius: 14px; font-weight: 700; font-size: 13.5px; background: rgba(14, 14, 30, .95); border: 1px solid var(--cyan); box-shadow: 0 0 24px rgba(0, 240, 255, .3); animation: toastIn .3s cubic-bezier(.3, 1.4, .5, 1); }
.toast.err { border-color: var(--danger); box-shadow: 0 0 24px rgba(255, 59, 107, .35); }
.toast.ok { border-color: var(--lime); box-shadow: 0 0 24px rgba(163, 255, 18, .3); }
.toast.out { opacity: 0; transform: translateY(-10px); transition: .3s; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-16px) scale(.95); } }

.flash { animation: flash .5s; }
@keyframes flash { 30% { transform: scale(1.12); box-shadow: 0 0 30px var(--lime); } }

/* ── главная ── */
.home-hero { position: relative; height: 330px; margin: -4px -16px 0; touch-action: none; }
.home-hero canvas { width: 100%; height: 100%; display: block; cursor: grab; }
.home-hero canvas:active { cursor: grabbing; }
.hero-hint { position: absolute; bottom: 6px; left: 0; right: 0; text-align: center; font-size: 11px; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; pointer-events: none; animation: pulse 2.4s infinite; }
.home-head { text-align: center; margin-top: 2px; }
.glitch { position: relative; display: inline-block; font-family: var(--display); font-weight: 900; font-size: 30px; color: #fff;
  text-shadow: 0 0 14px rgba(0, 240, 255, .8), 0 0 36px rgba(0, 240, 255, .4); animation: flicker 6s infinite; }
.glitch i { font-style: normal; color: var(--pink); text-shadow: 0 0 14px var(--pink); }
.glitch::before, .glitch::after { content: attr(data-text); position: absolute; inset: 0; pointer-events: none; opacity: .75; }
.glitch::before { color: var(--cyan); text-shadow: none; animation: glitchA 3.2s infinite steps(1); }
.glitch::after { color: var(--pink); text-shadow: none; animation: glitchB 3.2s infinite steps(1); }
@keyframes glitchA { 0%, 86%, 100% { clip-path: inset(0 0 100% 0); transform: none; } 88% { clip-path: inset(10% 0 55% 0); transform: translate(-3px, -1px); } 92% { clip-path: inset(60% 0 8% 0); transform: translate(3px, 1px); } }
@keyframes glitchB { 0%, 87%, 100% { clip-path: inset(0 0 100% 0); transform: none; } 89% { clip-path: inset(40% 0 30% 0); transform: translate(3px, 0); } 93% { clip-path: inset(5% 0 75% 0); transform: translate(-3px, 1px); } }
@keyframes flicker { 0%, 19%, 22%, 62%, 64%, 100% { opacity: 1; } 20%, 63% { opacity: .55; } }
.tagline { margin: 8px auto 16px; max-width: 330px; color: #d4d2f5; font-size: 14.5px; }
.tagline .stripe { font-weight: 900; letter-spacing: .02em; padding: 0 2px; color: #fff;
  text-shadow: 0 0 6px rgba(255, 255, 255, .55), 0 0 14px rgba(99, 91, 255, .9), 0 0 24px rgba(99, 91, 255, .5); animation: stripeGlow 2.6s ease-in-out infinite; }
@keyframes stripeGlow { 50% { text-shadow: 0 0 6px rgba(255, 255, 255, .6), 0 0 14px rgba(0, 240, 255, .9), 0 0 26px rgba(0, 240, 255, .5); } }
.home-cta { display: flex; justify-content: center; gap: 10px; }
.home-cta .btn { min-width: 220px; }

.ticker { margin: 18px -16px 0; overflow: hidden; border-block: 1px solid rgba(0, 240, 255, .18); background: rgba(0, 240, 255, .04); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.ticker-track { display: flex; gap: 28px; width: max-content; padding: 10px 0; white-space: nowrap; will-change: transform; font-size: 12.5px; color: var(--muted); }
.ticker-track > span { flex: none; }
.ticker-track b { color: var(--text); font-weight: 700; }
.tk-label { color: var(--lime); font-weight: 800; text-shadow: 0 0 10px var(--lime); }
@keyframes marquee { to { transform: translateX(-50%); } }

.home-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 18px; }
@media (min-width: 640px) { .home-stats { grid-template-columns: repeat(4, 1fr); } }
.hs { position: relative; overflow: hidden; padding: 14px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); animation: cardIn .5s backwards; }
.hs::before { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; background: linear-gradient(110deg, transparent 32%, rgba(0, 240, 255, .25) 42%, rgba(0, 240, 255, .8) 50%, rgba(0, 240, 255, .25) 58%, transparent 68%) 0 0 / 200% 100% repeat-x;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: sweep 5s linear infinite; will-change: background-position; }
.hs:nth-child(2)::before { animation-delay: -1.25s; }
.hs:nth-child(3)::before { animation-delay: -2.5s; }
.hs:nth-child(4)::before { animation-delay: -3.75s; }
/* сдвиг ровно на один период узора (200% при размере 200%) — цикл бесшовный, без скачка */
@keyframes sweep { from { background-position: 200% 0; } to { background-position: 0 0; } }
.hs-ico { position: absolute; right: 10px; top: 10px; font-size: 20px; opacity: .8; }
.hs b { display: block; font-family: var(--display); font-size: 24px; color: #fff; text-shadow: 0 0 16px rgba(0, 240, 255, .45); }
.hs small { color: var(--muted); font-size: 12px; }

.about { margin-top: 14px; border-color: rgba(255, 43, 214, .25); background: linear-gradient(135deg, rgba(255, 43, 214, .08), rgba(0, 240, 255, .05)), var(--panel); }
.about h3 { font-size: 15px; margin-bottom: 8px; }
.about p { margin: 0; color: #d4d2f5; font-size: 14px; line-height: 1.55; }

.features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.feature { padding: 14px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); animation: cardIn .5s backwards; transition: border-color .2s, transform .2s; }
.feature:hover { border-color: rgba(0, 240, 255, .4); transform: translateY(-2px); }
.f-ico { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; font-size: 22px; margin-bottom: 10px;
  background: radial-gradient(circle, rgba(0, 240, 255, .3), transparent 70%), var(--panel-2); animation: float 4s ease-in-out infinite; }
.feature:nth-child(2) .f-ico { animation-delay: -1s; } .feature:nth-child(3) .f-ico { animation-delay: -2s; } .feature:nth-child(4) .f-ico { animation-delay: -3s; }
.feature b { font-size: 14px; }
.feature p { margin: 4px 0 0; font-size: 12.5px; color: var(--muted); }

.cat-tiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.cat-tile { --c: var(--cyan); position: relative; overflow: hidden; text-align: left; padding: 14px; border-radius: var(--r); background: var(--panel); border: 1px solid color-mix(in srgb, var(--c) 35%, transparent); transition: .2s; }
.cat-tile::after { content: ""; position: absolute; right: -24px; bottom: -24px; width: 90px; height: 90px; border-radius: 50%; background: var(--c); filter: blur(34px); opacity: .35; transition: .3s; }
.cat-tile:hover::after, .cat-tile:active::after { opacity: .7; }
.cat-tile:active { transform: scale(.97); }
.ct-ico { display: block; font-size: 28px; margin-bottom: 6px; filter: drop-shadow(0 0 10px var(--c)); }
.cat-tile b { display: block; font-size: 14px; }
.cat-tile small { color: var(--muted); font-size: 11.5px; }

.steps { display: flex; flex-direction: column; gap: 10px; }
.step { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); }
.step-n { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-family: var(--display); font-weight: 900; color: #05050a;
  background: linear-gradient(135deg, var(--cyan), var(--pink)); box-shadow: 0 0 14px rgba(0, 240, 255, .5); }
.step b { font-size: 14px; }
.step p { margin: 2px 0 0; font-size: 12.5px; color: var(--muted); }

.rv-marquee { margin: 0 -16px; overflow: hidden; padding: 4px 0 6px; mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.rv-track { display: flex; width: max-content; will-change: transform; align-items: stretch; }
.rv-card { flex: none; width: 270px; margin-right: 12px; padding: 14px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; transition: border-color .2s; }
.rv-card:hover { border-color: rgba(255, 43, 214, .45); }
.rv-card p { margin: 0; font-size: 13.5px; line-height: 1.45; color: #d4d2f5;
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; min-height: calc(1.45em * 4); }
.rv-card small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rv-ava { width: 34px; height: 34px; flex: none; border-radius: 50%; display: grid; place-items: center; font-family: var(--display); font-weight: 900; font-size: 14px;
  background: linear-gradient(135deg, var(--cyan), var(--pink)); color: #05050a; box-shadow: 0 0 12px rgba(255, 43, 214, .4); }
.rv-name { font-size: 13.5px; }
.rv-test { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 99px; border: 1px dashed rgba(255, 200, 0, .55); color: #ffd84d; font-size: 10.5px; font-weight: 700; letter-spacing: .03em; vertical-align: 1px; }
.home-foot { text-align: center; color: var(--dim); font-size: 11px; margin: 18px 0 0; letter-spacing: .1em; }

/* ваучер «своя сумма» */
.price .from { font-size: .6em; font-weight: 600; color: var(--muted); }
.amount-box { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.amount-box span { font-family: var(--display); font-size: 22px; color: var(--cyan); text-shadow: 0 0 12px rgba(0, 240, 255, .5); }
.amount-box .input { flex: 1; font-size: 20px; font-weight: 800; height: 52px; }
.amount-chips { flex-wrap: wrap; margin: 0 0 6px; padding: 0; }
.amount-hint { min-height: 18px; margin: 2px 0 10px; font-size: 12.5px; }
.amount-hint.bad { color: #ff5c7a; }

/* neonmarket2: менеджер и статусы заявок */
.mgr-card { display: flex; align-items: center; gap: 12px; margin-top: 12px; }
.mgr-ava { width: 42px; height: 42px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: 20px;
  background: rgba(0, 240, 255, .08); border: 1px solid rgba(0, 240, 255, .35); box-shadow: 0 0 14px rgba(0, 240, 255, .2); }
.mgr-steps { margin-top: 4px; }
.pill.st-new { color: var(--cyan); border-color: rgba(0, 240, 255, .4); background: rgba(0, 240, 255, .08); }
.pill.st-paid { color: #ffd84d; border-color: rgba(255, 216, 77, .4); background: rgba(255, 216, 77, .08); }
.pill.st-done { color: var(--lime); border-color: rgba(163, 255, 18, .4); background: rgba(163, 255, 18, .08); }
.pill.st-cancelled { color: #ff5c7a; border-color: rgba(255, 92, 122, .4); background: rgba(255, 92, 122, .08); }

/* плавающая кнопка менеджера */
.mgr-fab-wrap { position: fixed; right: 16px; bottom: calc(var(--tabbar-h) + 22px + var(--safe-b)); z-index: 35; display: flex; align-items: center; gap: 10px; pointer-events: none; }
.mgr-fab { pointer-events: auto; position: relative; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font-size: 24px;
  background: radial-gradient(circle at 35% 30%, rgba(0, 240, 255, .35), rgba(139, 92, 246, .35) 60%, rgba(255, 43, 214, .3));
  border: 1px solid rgba(0, 240, 255, .6); backdrop-filter: blur(10px);
  box-shadow: 0 0 22px rgba(0, 240, 255, .45), 0 0 40px rgba(255, 43, 214, .2), inset 0 0 14px rgba(0, 240, 255, .25);
  transition: transform .15s; }
.mgr-fab:active { transform: scale(.92); }
.mgr-fab::before, .mgr-fab::after { content: ""; position: absolute; inset: -1px; border-radius: 50%; border: 2px solid rgba(0, 240, 255, .55); animation: fabRing 2.6s ease-out infinite; }
.mgr-fab::after { animation-delay: 1.3s; border-color: rgba(255, 43, 214, .45); }
@keyframes fabRing { from { transform: scale(1); opacity: .9; } to { transform: scale(1.7); opacity: 0; } }
.mgr-fab span { filter: drop-shadow(0 0 8px rgba(0, 240, 255, .8)); }
.mgr-fab-label { padding: 8px 12px; border-radius: 12px; font-size: 12.5px; font-weight: 700; white-space: nowrap; color: var(--text);
  background: rgba(14, 14, 30, .92); border: 1px solid rgba(0, 240, 255, .35); box-shadow: 0 0 18px rgba(0, 240, 255, .2);
  opacity: 0; transform: translateX(10px); transition: opacity .3s, transform .3s; }
.mgr-fab-wrap.hint .mgr-fab-label { opacity: 1; transform: none; }

/* нижняя кнопка «В каталог» на главной — с отступами по бокам */
.home-end { margin: 22px 0 8px; padding: 0 44px; }
