:root {
  --gold: #e8c37a;
  --gold-soft: #f4dfae;
  --ink: #f5f2ea;
  --dim: rgba(245, 242, 234, 0.55);
  --panel: rgba(12, 18, 32, 0.62);
  --line: rgba(232, 195, 122, 0.22);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: #060a14;
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  user-select: none;
}

#scene {
  position: fixed;
  inset: 0;
  background: radial-gradient(120% 90% at 50% 20%, #0d1626 0%, #070b14 55%, #04060c 100%);
}

#scene::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(90% 70% at 50% 30%, rgba(6, 10, 20, 0) 0%, rgba(6, 10, 20, 0.38) 80%, rgba(4, 6, 12, 0.82) 100%),
    linear-gradient(180deg, rgba(6, 10, 20, 0.4) 0%, rgba(6, 10, 20, 0) 24%, rgba(6, 10, 20, 0) 64%, rgba(6, 10, 20, 0.45) 100%);
}

#gl {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
}

#vignette {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(120% 100% at 50% 45%, rgba(0,0,0,0) 45%, rgba(2,4,10,0.55) 100%);
  z-index: 1;
}

.top {
  position: fixed;
  top: 0; left: 0; right: 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  padding: 26px 30px 0;
  z-index: 5;
  pointer-events: none;
}

.top > * { pointer-events: auto; }

.kicker {
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.9;
}

h1 {
  margin: 8px 0 6px;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 34px;
  line-height: 1.05;
  letter-spacing: 0.01em;
  background: linear-gradient(180deg, #fff7e6 0%, #e8c37a 70%, #b9924c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 40px rgba(232, 195, 122, 0.18);
}

.sub {
  font-size: 12.5px;
  color: var(--dim);
  letter-spacing: 0.03em;
}

.sidebar {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

.search input {
  width: 240px;
  padding: 11px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel);
  backdrop-filter: blur(10px);
  color: var(--ink);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.search input::placeholder { color: rgba(245, 242, 234, 0.4); }
.search input:focus { border-color: rgba(232, 195, 122, 0.6); background: rgba(12, 18, 32, 0.82); }

.counter {
  font-size: 12px;
  color: var(--gold);
  letter-spacing: 0.08em;
  opacity: 0.85;
}

.tools {
  position: fixed;
  right: 30px;
  bottom: 132px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 5;
  align-items: flex-end;
}

.tool {
  padding: 9px 15px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel);
  backdrop-filter: blur(10px);
  color: var(--gold-soft);
  font-size: 12px;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.2s, background 0.2s;
}

.tool:hover { border-color: rgba(232, 195, 122, 0.55); background: rgba(20, 28, 46, 0.8); transform: translateY(-1px); }

.pricebar {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 26px;
  padding: 14px 16px 14px 26px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(9, 14, 26, 0.72);
  backdrop-filter: blur(14px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  z-index: 6;
}

.plabel {
  font-size: 10.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--dim);
}

.pvalue {
  font-family: Georgia, serif;
  font-size: 22px;
  color: var(--gold-soft);
  margin-top: 3px;
}

.pvalue span {
  font-family: -apple-system, sans-serif;
  font-size: 12px;
  color: var(--dim);
  margin-left: 8px;
}

.buy {
  border: none;
  border-radius: 14px;
  padding: 14px 24px;
  background: linear-gradient(160deg, #f2d79b 0%, #dcae5f 55%, #c3913f 100%);
  color: #23180a;
  font-size: 14px;
  font-weight: 650;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(220, 174, 95, 0.28);
  transition: transform 0.15s, box-shadow 0.2s;
}

.buy:hover { transform: translateY(-1px); box-shadow: 0 12px 30px rgba(220, 174, 95, 0.4); }
.buy.wide { width: 100%; margin-top: 18px; }

.card {
  position: fixed;
  z-index: 8;
  min-width: 210px;
  max-width: 250px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(10, 15, 28, 0.82);
  backdrop-filter: blur(12px);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.5);
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
  transition: opacity 0.18s, transform 0.18s;
}

.card.show { opacity: 1; transform: translateY(0); }

.card-name {
  font-family: Georgia, serif;
  font-size: 17px;
  color: var(--gold-soft);
}

.card-wish {
  margin-top: 6px;
  font-size: 12.5px;
  line-height: 1.45;
  color: rgba(245, 242, 234, 0.8);
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 118px;
  transform: translate(-50%, 10px);
  padding: 10px 18px;
  border-radius: 999px;
  background: rgba(20, 28, 46, 0.9);
  border: 1px solid var(--line);
  color: var(--gold-soft);
  font-size: 12.5px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 9;
}

.toast.show { opacity: 1; transform: translate(-50%, 0); }

.sheet {
  position: fixed;
  z-index: 10;
  left: 50%;
  bottom: 0;
  width: min(560px, 100%);
  max-height: 78vh;
  transform: translate(-50%, 110%);
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
  display: flex;
  flex-direction: column;
  border-radius: 24px 24px 0 0;
  border: 1px solid var(--line);
  border-bottom: none;
  background: rgba(8, 12, 22, 0.94);
  backdrop-filter: blur(18px);
  box-shadow: 0 -30px 80px rgba(0, 0, 0, 0.6);
  padding: 18px 20px 24px;
}

.sheet.show { transform: translate(-50%, 0); }

.sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.sheet-title {
  font-family: Georgia, serif;
  font-size: 19px;
  color: var(--gold-soft);
}

.sheet-close {
  border: none;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.sheet-search, .field {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.045);
  color: var(--ink);
  font-size: 13.5px;
  outline: none;
  font-family: inherit;
}

.sheet-search:focus, .field:focus { border-color: rgba(232, 195, 122, 0.5); }

.sheet-body {
  margin-top: 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.row {
  display: flex;
  gap: 10px;
  align-items: baseline;
  text-align: left;
  padding: 9px 8px;
  border: none;
  background: transparent;
  border-radius: 10px;
  color: var(--ink);
  cursor: pointer;
  font-family: inherit;
}

.row:hover { background: rgba(232, 195, 122, 0.08); }

.row-name {
  color: var(--gold);
  font-size: 13px;
  min-width: 84px;
  flex: none;
}

.row-wish {
  font-size: 12.5px;
  color: rgba(245, 242, 234, 0.7);
  line-height: 1.35;
}

.empty { padding: 18px 8px; color: var(--dim); font-size: 13px; }

.flabel {
  display: block;
  margin: 14px 0 6px;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--dim);
}

.modal-note {
  margin: 0 0 6px;
  font-size: 12.5px;
  line-height: 1.5;
  color: rgba(245, 242, 234, 0.6);
}

.fine {
  margin: 14px 0 0;
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: rgba(245, 242, 234, 0.35);
}

@media (max-width: 720px) {
  .top { padding: 18px 18px 0; flex-direction: column; gap: 12px; }
  h1 { font-size: 26px; }
  .sub { font-size: 11.5px; }
  .sidebar { align-items: stretch; width: 100%; }
  .search input { width: 100%; }
  .counter { text-align: right; }
  .tools { right: 14px; bottom: 118px; flex-direction: row; gap: 6px; }
  .tool { padding: 8px 11px; font-size: 11px; }
  .pricebar {
    left: 12px; right: 12px; bottom: 12px;
    transform: none;
    width: auto;
    gap: 14px;
    padding: 12px 12px 12px 16px;
    border-radius: 18px;
  }
  .plabel { font-size: 9.5px; letter-spacing: 0.16em; }
  .pvalue { font-size: 18px; }
  .pvalue span { display: block; margin: 2px 0 0; font-size: 10.5px; }
  .buy { padding: 13px 16px; font-size: 13px; border-radius: 12px; white-space: nowrap; }
  .card {
    left: 12px !important;
    right: 12px;
    bottom: 92px;
    top: auto !important;
    max-width: none;
    transform: translateY(6px);
  }
  .card.show { transform: translateY(0); }
  .toast { bottom: 96px; max-width: calc(100% - 32px); text-align: center; }
}

#grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  opacity: 0.22;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix type='saturate' values='0'/></filter><rect width='140' height='140' filter='url(%23n)' opacity='0.55'/></svg>");
}

.loading {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  background: radial-gradient(120% 90% at 50% 40%, #101a30 0%, #070b14 60%, #04060c 100%);
  transition: opacity 0.9s ease;
}

.loading.hide { opacity: 0; pointer-events: none; }

.load-star {
  font-size: 30px;
  color: var(--gold);
  animation: lpulse 1.7s infinite ease-in-out;
}

.load-text {
  font-size: 11px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(245, 242, 234, 0.42);
}

@keyframes lpulse {
  0%, 100% { opacity: 0.3; transform: scale(0.86) rotate(-6deg); }
  50% { opacity: 1; transform: scale(1.1) rotate(6deg); }
}

.zoom-group { display: flex; gap: 6px; }
.tool-zoom {
  width: 38px;
  height: 38px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 19px;
  line-height: 1;
  color: var(--gold-soft);
}

@media (max-width: 720px) {
  .tool-zoom { width: 34px; height: 34px; font-size: 17px; }
}


/* ===== иконки (сгенерированы в AI Studio) ===== */
.ic {
  display: inline-block;
  width: 18px;
  height: 18px;
  flex: none;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: 0.92;
  filter: drop-shadow(0 0 6px rgba(232, 195, 122, 0.35));
  vertical-align: -3px;
}
.ic-bauble { background-image: url('./assets/icons/ic-bauble.png'); }
.ic-star { background-image: url('./assets/icons/ic-star.png'); }
.ic-gift { background-image: url('./assets/icons/ic-gift.png'); }
.ic-list { background-image: url('./assets/icons/ic-list.png'); }
.ic-clock { background-image: url('./assets/icons/ic-clock.png'); }
.ic-snowflake { background-image: url('./assets/icons/ic-snowflake.png'); }
.ic-search { background-image: url('./assets/icons/ic-search.png'); }
.ic-heart { background-image: url('./assets/icons/ic-heart.png'); }
.ic-coin { background-image: url('./assets/icons/ic-coin.png'); }
.ic-goat { background-image: url('./assets/icons/ic-goat.png'); }
.ic-wish { background-image: url('./assets/icons/ic-wish.png'); }
.ic-firework { background-image: url('./assets/icons/ic-firework.png'); }
.ic-zoom-in, .ic-zoom-out { background-image: none; width: 20px; height: 20px; }
.ic-zoom-in::before, .ic-zoom-out::before {
  display: block;
  text-align: center;
  font-size: 20px;
  line-height: 20px;
  color: #f4dfae;
}
.ic-zoom-in::before { content: '+'; }
.ic-zoom-out::before { content: '−'; }

.tool { display: inline-flex; align-items: center; gap: 7px; }
.buy { display: inline-flex; align-items: center; justify-content: center; gap: 9px; }

/* ===== вход страницы ===== */
@keyframes riseIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
.top .brand { animation: riseIn 0.9s cubic-bezier(0.22, 1, 0.36, 1) both; animation-delay: 0.25s; }
.top .sidebar { animation: riseIn 0.9s cubic-bezier(0.22, 1, 0.36, 1) both; animation-delay: 0.45s; }
.pricebar { animation: riseIn 1s cubic-bezier(0.22, 1, 0.36, 1) both; animation-delay: 0.7s; }
.tools > * { animation: riseIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) both; }
.tools > *:nth-child(1) { animation-delay: 0.9s; }
.tools > *:nth-child(2) { animation-delay: 0.98s; }
.tools > *:nth-child(3) { animation-delay: 1.06s; }
.tools > *:nth-child(4) { animation-delay: 1.14s; }
.live-feed { animation: fadeIn 1.4s ease both; animation-delay: 1.3s; }

/* ===== блеск кнопки ===== */
.buy { position: relative; overflow: hidden; }
.buy::after {
  content: '';
  position: absolute;
  top: -60%;
  left: -140%;
  width: 60%;
  height: 220%;
  background: linear-gradient(100deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.55) 50%, rgba(255,255,255,0) 100%);
  transform: rotate(12deg);
  animation: sweep 4.6s ease-in-out infinite;
  pointer-events: none;
}
@keyframes sweep {
  0%, 62% { left: -140%; }
  82% { left: 160%; }
  100% { left: 160%; }
}

/* ===== цена и таймер ===== */
.pmeta {
  margin-top: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: rgba(232, 195, 122, 0.75);
  font-variant-numeric: tabular-nums;
}
.pmeta .ic { width: 13px; height: 13px; opacity: 0.8; }

.counter.pulse { animation: cPulse 0.7s ease; }
@keyframes cPulse {
  0% { transform: scale(1); color: var(--gold); }
  40% { transform: scale(1.12); color: #fff2d4; text-shadow: 0 0 18px rgba(255, 226, 168, 0.65); }
  100% { transform: scale(1); }
}

/* ===== лента «только что» ===== */
.live-feed {
  position: fixed;
  left: 30px;
  bottom: 132px;
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 9px;
  max-width: 330px;
  padding: 10px 15px;
  border-radius: 14px;
  border: 1px solid rgba(232, 195, 122, 0.18);
  background: rgba(8, 13, 24, 0.62);
  backdrop-filter: blur(10px);
  font-size: 12px;
  color: rgba(245, 242, 234, 0.78);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  pointer-events: none;
}
.live-feed.show { opacity: 1; transform: translateY(0); }
.lf-ic { width: 15px; height: 15px; opacity: 0.7; animation: spinSlow 14s linear infinite; }
.lf-text strong { color: var(--gold-soft); font-weight: 600; }
.lf-text em { font-style: normal; color: rgba(245, 242, 234, 0.55); }
@keyframes spinSlow { to { transform: rotate(360deg); } }

/* ===== угловые украшения ===== */
.deco {
  position: fixed;
  top: -6px;
  width: 210px;
  height: 210px;
  background-repeat: no-repeat;
  background-size: contain;
  pointer-events: none;
  z-index: 3;
  opacity: 0.22;
  filter: drop-shadow(0 0 18px rgba(232, 195, 122, 0.18));
}
.deco-tl { left: -6px; background-image: url('./assets/icons/deco-corner.png'); }
.deco-tr { right: -6px; background-image: url('./assets/icons/deco-corner.png'); transform: scaleX(-1); }

/* ===== карточка игрушки ===== */
.card { transition: opacity 0.2s ease, transform 0.24s cubic-bezier(0.2, 1.4, 0.4, 1); }
.card.show { transform: translateY(0) scale(1); }

/* ===== список: появление строк ===== */
.row { animation: rowIn 0.35s ease both; }
@keyframes rowIn {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ===== праздник после оплаты ===== */
.celebration {
  position: fixed;
  inset: 0;
  z-index: 30;
  pointer-events: none;
  overflow: hidden;
}
.celebration .flash {
  position: absolute;
  inset: 0;
  background: radial-gradient(60% 50% at 50% 42%, rgba(255, 226, 168, 0.55) 0%, rgba(255, 200, 120, 0.18) 38%, rgba(255, 200, 120, 0) 70%);
  animation: flashOut 1.6s ease-out forwards;
}
@keyframes flashOut {
  0% { opacity: 0; transform: scale(0.7); }
  18% { opacity: 1; }
  100% { opacity: 0; transform: scale(1.3); }
}
.celebration .spark {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff6dd 0%, #f0c274 45%, rgba(240, 194, 116, 0) 70%);
  animation: sparkFly 1.9s cubic-bezier(0.15, 0.6, 0.3, 1) forwards;
}
@keyframes sparkFly {
  0% { opacity: 0; transform: translate(0, 0) scale(0.4); }
  12% { opacity: 1; }
  100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(1.1); }
}

/* ===== мобильная версия ===== */
@media (max-width: 720px) {
  .deco { width: 120px; height: 120px; opacity: 0.16; }
  .live-feed { display: none; }
  .pmeta { font-size: 10px; margin-top: 4px; }
  .buy .ic { width: 16px; height: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .buy::after, .lf-ic, .top .brand, .top .sidebar, .pricebar, .tools > *, .row { animation: none !important; }
}


@media (max-width: 720px) {
  .pricebar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding: 12px 14px 14px;
  }
  .pricebar .buy { width: 100%; padding: 13px 12px; }
  .pinfo { width: 100%; }
  .pvalue span { display: inline; margin-left: 8px; font-size: 11px; }
  .pmeta { justify-content: flex-start; font-size: 10.5px; }
  #adm-gear { bottom: 232px !important; }
  .deco { top: -14px; width: 130px; height: 130px; }
}


@media (max-width: 720px) {
  .tools { bottom: 246px; flex-wrap: wrap; justify-content: flex-end; right: 12px; }
  .tools #btn-add { display: none; }
  .tool { padding: 8px 10px; }
}


/* ===== загрузка: золотая ёлка ===== */
.load-tree {
  width: 210px;
  height: 210px;
  background-image: url('./assets/golden-tree.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: drop-shadow(0 0 26px rgba(255, 214, 140, 0.5));
  animation: treeBreath 2.6s ease-in-out infinite;
}
@keyframes treeBreath {
  0%, 100% { transform: scale(0.94) translateY(4px); opacity: 0.75; }
  50% { transform: scale(1.03) translateY(-2px); opacity: 1; }
}
.loading .load-text { margin-top: 4px; }

/* ===== выбор игрушки ===== */
.orn-pick {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
  margin: 4px 0 6px;
}
.orn-swatch {
  position: relative;
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px solid rgba(232, 195, 122, 0.25);
  background-size: cover;
  background-position: center;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
}
.orn-swatch:hover { transform: translateY(-2px) scale(1.04); border-color: rgba(232, 195, 122, 0.6); }
.orn-swatch.on {
  border-color: #f4dfae;
  box-shadow: 0 0 0 2px rgba(232, 195, 122, 0.35), 0 6px 18px rgba(232, 195, 122, 0.25);
}
.orn-swatch.on::after {
  content: '✓';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff7e6;
  font-size: 15px;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.8);
}
.hint-bad {
  min-height: 16px;
  margin: 8px 0 0;
  font-size: 11.5px;
  color: #ff9c8a;
  letter-spacing: 0.01em;
}
.field.bad { border-color: rgba(255, 140, 120, 0.65); box-shadow: 0 0 0 2px rgba(255, 120, 100, 0.12); }

@media (max-width: 720px) {
  .orn-pick { grid-template-columns: repeat(4, 1fr); }
  .load-tree { width: 160px; height: 160px; }
}

.tool.on { border-color: rgba(232, 195, 122, 0.65); color: #fff2d4; background: rgba(232, 195, 122, 0.14); }
@media (max-width: 720px) {
  #btn-shake { display: none; }
}

/* мобильное меню «ещё» */
.tool-more { display: none; }
@media (max-width: 720px) {
  .tools .tool:not(.tool-zoom):not(.tool-more) { display: none; }
  body.menu-open .tools .tool:not(.tool-zoom):not(.tool-more) { display: inline-flex; }
  .tool-more { display: inline-flex; align-items: center; justify-content: center; font-size: 18px; }
}


.share-btn {
  position: fixed;
  left: 50%;
  transform: translate(-50%, 20px);
  bottom: 118px;
  z-index: 8;
  padding: 13px 26px;
  border: 1px solid rgba(232, 195, 122, 0.5);
  border-radius: 999px;
  background: linear-gradient(160deg, rgba(242, 215, 155, 0.95), rgba(220, 174, 95, 0.95));
  color: #23180a;
  font: 600 14px -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease, transform 0.5s ease;
  box-shadow: 0 12px 30px rgba(220, 174, 95, 0.35);
}
.share-btn.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
@media (max-width: 720px) {
  .share-btn { bottom: 232px; font-size: 13px; padding: 11px 20px; }
}


/* ===== более «дорогой» интерфейс: меньше шума ===== */
.tools { gap: 7px; right: 28px; bottom: 126px; }
.tool {
  padding: 8px 12px;
  font-size: 11.5px;
  letter-spacing: 0.02em;
  border-color: rgba(232, 195, 122, 0.16);
  background: rgba(8, 13, 24, 0.5);
  color: rgba(244, 223, 174, 0.82);
  opacity: 0.9;
}
.tool:hover { opacity: 1; color: #fff2d4; }
.tool .ic { width: 15px; height: 15px; opacity: 0.75; }
.tool-zoom { width: 34px; height: 34px; }

.pricebar {
  gap: 22px;
  padding: 12px 14px 12px 22px;
  border-radius: 22px;
  border-color: rgba(232, 195, 122, 0.16);
  background: linear-gradient(180deg, rgba(12, 18, 32, 0.78) 0%, rgba(7, 11, 20, 0.86) 100%);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.plabel { font-size: 10px; letter-spacing: 0.24em; color: rgba(245, 242, 234, 0.42); }
.pvalue { font-size: 21px; letter-spacing: 0.005em; }
.pvalue span { font-size: 11.5px; }
.buy { padding: 13px 22px; font-size: 13.5px; border-radius: 13px; }
.buy .ic { width: 16px; height: 16px; }

.kicker { letter-spacing: 0.34em; opacity: 0.75; font-size: 10.5px; }
h1 { font-size: 32px; letter-spacing: 0.005em; }
.sub { font-size: 12px; color: rgba(245, 242, 234, 0.5); }
.search input { width: 212px; padding: 10px 15px; font-size: 12.5px; background: rgba(8, 13, 24, 0.45); }
.counter { font-size: 11.5px; letter-spacing: 0.07em; opacity: 0.7; }

.live-feed {
  padding: 9px 14px;
  font-size: 11.5px;
  border-color: rgba(232, 195, 122, 0.12);
  background: rgba(7, 11, 20, 0.55);
  opacity: 0.92;
}
#adm-gear { opacity: 0.6; }
#adm-gear:hover { opacity: 1; }

@media (max-width: 720px) {
  .tool { padding: 7px 9px; font-size: 11px; }
  .pricebar { padding: 11px 12px 12px 16px; }
}


/* ===== редакционный UI: тонкие линии вместо «стеклянных» плашек ===== */
.pricebar {
  border-radius: 14px;
  padding: 12px 14px 12px 18px;
  border: 1px solid rgba(232, 195, 122, 0.24);
  background: rgba(7, 11, 19, 0.82);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.45);
  overflow: hidden;
}
.pricebar::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(232,195,122,0) 0%, rgba(232,195,122,0.55) 50%, rgba(232,195,122,0) 100%);
}
.plabel { font-size: 9.5px; letter-spacing: 0.3em; color: rgba(245, 242, 234, 0.38); }
.pvalue { font-size: 20px; letter-spacing: 0.02em; }
.pmeta { font-size: 10.5px; letter-spacing: 0.04em; opacity: 0.7; }
.buy { border-radius: 9px; padding: 12px 20px; font-size: 13px; letter-spacing: 0.04em; }

.tool {
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(6, 10, 17, 0.55);
  color: rgba(244, 223, 174, 0.72);
  font-size: 11px;
  letter-spacing: 0.06em;
  backdrop-filter: none;
}
.tool:hover { background: rgba(232, 195, 122, 0.1); border-color: rgba(232, 195, 122, 0.4); }
.tool-zoom { border-radius: 50%; }

.card {
  border-radius: 10px;
  border: 1px solid rgba(232, 195, 122, 0.2);
  border-left: 2px solid rgba(232, 195, 122, 0.65);
  background: rgba(6, 10, 18, 0.9);
  backdrop-filter: blur(6px);
}
.card-name { font-size: 16px; }
.card-wish { font-size: 12px; }

.sheet {
  border-radius: 14px 14px 0 0;
  border: 1px solid rgba(232, 195, 122, 0.22);
  border-bottom: none;
  background: rgba(6, 10, 18, 0.96);
  backdrop-filter: blur(10px);
}
.sheet-title { font-size: 17px; letter-spacing: 0.01em; }
.sheet-close { border-radius: 6px; }

.search input { border-radius: 8px; }
.search input:focus { border-color: rgba(232, 195, 122, 0.5); }
.live-feed { border-radius: 9px; }
.row { border-radius: 6px; }

h1 { letter-spacing: 0.008em; }
.sub { letter-spacing: 0.02em; }


/* ===== тиры игрушек ===== */
.tiers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 6px 0 4px; }
.tier {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  padding: 10px 6px 9px;
  min-height: 108px;
  border-radius: 10px;
  border: 1px solid rgba(232, 195, 122, 0.22);
  background-color: rgba(8, 13, 24, 0.7);
  background-repeat: no-repeat;
  background-position: center 12px;
  background-size: 46px 46px;
  color: rgba(245, 242, 234, 0.8);
  font: inherit;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.tier:hover { transform: translateY(-2px); border-color: rgba(232, 195, 122, 0.5); }
.tier.on { border-color: #f4dfae; box-shadow: 0 0 0 2px rgba(232, 195, 122, 0.28), 0 8px 22px rgba(232, 195, 122, 0.18); }
.tier-name { font-size: 11px; letter-spacing: 0.04em; text-align: center; }
.tier-price { font-family: Georgia, serif; font-size: 14px; color: #f4dfae; }
@media (max-width: 720px) {
  .tiers { grid-template-columns: repeat(2, 1fr); }
  .tier { min-height: 96px; background-size: 38px 38px; }
}


/* цена всегда по центру: отдельная анимация без потери translateX */
@keyframes riseInCenter {
  from { opacity: 0; transform: translate(-50%, 14px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}
.pricebar {
  animation: riseInCenter 1s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: 0.7s;
}


/* морозные узоры по углам */
.frost {
  position: fixed;
  width: 300px;
  height: 300px;
  pointer-events: none;
  z-index: 3;
  background-image: url('./assets/frost-corner.png');
  background-repeat: no-repeat;
  background-size: contain;
  opacity: 0.5;
  mix-blend-mode: screen;
  filter: drop-shadow(0 0 12px rgba(170, 210, 255, 0.35));
}
.frost-tl { top: -8px; left: -8px; }
.frost-tr { top: -8px; right: -8px; transform: scaleX(-1); }
.frost-bl { bottom: -8px; left: -8px; transform: scaleY(-1); opacity: 0.32; }
.frost-br { bottom: -8px; right: -8px; transform: scale(-1, -1); opacity: 0.32; }
@media (max-width: 720px) {
  .frost { width: 170px; height: 170px; opacity: 0.4; }
}


/* ===== фикс мобильной вёрстки: центрирование без transform ===== */
.pricebar {
  left: 50%;
  right: auto;
  width: max-content;
  max-width: calc(100vw - 32px);
  translate: -50% 0;
  transform: none;
  animation: riseCentered 1s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: 0.7s;
}
@keyframes riseCentered {
  from { opacity: 0; translate: -50% 14px; }
  to { opacity: 1; translate: -50% 0; }
}
@media (max-width: 720px) {
  .pricebar {
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    translate: 0 0;
    animation-name: riseMobile;
  }
  .tools { bottom: 132px; }
  #adm-gear { display: none; }
  .top { padding-top: 14px; }
  h1 { font-size: 24px; }
  .kicker { font-size: 9px; letter-spacing: 0.28em; }
  .sub { font-size: 11px; line-height: 1.35; }
  .frost { width: 132px; height: 132px; opacity: 0.34; }
  .sheet { max-height: 94vh; }
}
@keyframes riseMobile {
  from { opacity: 0; translate: 0 16px; }
  to { opacity: 1; translate: 0 0; }
}


/* ===== мобильный компактный низ ===== */
@media (max-width: 720px) {
  .pricebar {
    padding: 10px 12px;
    gap: 10px;
    align-items: center;
    flex-wrap: nowrap;
    border-radius: 14px;
  }
  .pricebar .pinfo { flex: 1 1 auto; min-width: 0; }
  .pricebar .pmeta { display: none; }
  .pricebar .buy { width: auto; flex: 0 0 auto; padding: 11px 14px; font-size: 12.5px; }
  .plabel { font-size: 9px; letter-spacing: 0.18em; }
  .pvalue { font-size: 16px; }
  .pvalue span { display: inline; margin: 0 0 0 6px; font-size: 10px; }
  .tools { bottom: 96px; }
  #adm-gear { display: none !important; }
  .toast { bottom: 84px; }
  .card { bottom: 84px; }
}


@media (max-width: 720px) {
  .tools { bottom: 172px; z-index: 26; }
  .pricebar { z-index: 24; }
  .card { z-index: 27; bottom: 172px; }
}


/* ===== режим обслуживания ===== */
.maintenance {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: radial-gradient(circle at 50% 32%, rgba(12, 19, 34, 0.78), rgba(4, 7, 12, 0.93));
  backdrop-filter: blur(7px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s ease;
}
.maintenance.show { opacity: 1; pointer-events: auto; }
.maintenance-card {
  max-width: 470px;
  width: 100%;
  text-align: center;
  padding: 36px 30px 30px;
  border-radius: 18px;
  border: 1px solid rgba(232, 195, 122, 0.26);
  background: rgba(8, 13, 24, 0.9);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.55);
}
.maintenance-star {
  font-size: 34px;
  color: #f4dfae;
  text-shadow: 0 0 24px rgba(244, 223, 174, 0.55);
  animation: mPulse 2.6s ease-in-out infinite;
}
@keyframes mPulse {
  0%, 100% { opacity: 0.75; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.08); }
}
.maintenance-title {
  margin: 14px 0 10px;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 27px;
  letter-spacing: 0.01em;
  color: #fff7e6;
}
.maintenance-text { font-size: 14px; line-height: 1.55; color: rgba(245, 242, 234, 0.72); }
.maintenance-btn {
  margin-top: 22px;
  padding: 12px 26px;
  border-radius: 10px;
  border: 1px solid rgba(232, 195, 122, 0.5);
  background: linear-gradient(180deg, #f0cf8a, #e0b45c);
  color: #2a1f0c;
  font: inherit;
  font-size: 13px;
  letter-spacing: 0.04em;
  cursor: pointer;
}
.maintenance-btn:hover { filter: brightness(1.05); }
.maintenance-note { margin-top: 14px; font-size: 11px; letter-spacing: 0.04em; color: rgba(245, 242, 234, 0.42); }
body.is-maintenance .pricebar .buy { opacity: 0.55; cursor: default; }
@media (max-width: 720px) {
  .maintenance-card { padding: 28px 20px 24px; }
  .maintenance-title { font-size: 23px; }
  .maintenance-text { font-size: 13px; }
}


/* ===== экран подготовки: золотая ёлка как на загрузке ===== */
.maintenance {
  background:
    radial-gradient(circle at 50% 30%, rgba(232, 195, 122, 0.1), rgba(232, 195, 122, 0) 55%),
    radial-gradient(circle at 50% 55%, rgba(12, 19, 34, 0.9), rgba(4, 7, 12, 0.96));
  backdrop-filter: blur(10px);
}
.maintenance-card {
  max-width: 520px;
  padding: 30px 32px 26px;
  border-radius: 20px;
  border: 1px solid rgba(232, 195, 122, 0.24);
  background: linear-gradient(180deg, rgba(10, 16, 28, 0.92), rgba(6, 10, 18, 0.94));
  box-shadow: 0 40px 110px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.maintenance-tree {
  width: 188px;
  height: 188px;
  margin: -6px auto 4px;
  background-image: url('./assets/golden-tree.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: drop-shadow(0 0 26px rgba(240, 207, 138, 0.4));
  animation: mTreeFloat 4.6s ease-in-out infinite;
}
@keyframes mTreeFloat {
  0%, 100% { transform: scale(0.97) translateY(4px); opacity: 0.86; }
  50% { transform: scale(1.02) translateY(-3px); opacity: 1; }
}
.maintenance-card .maintenance-star { display: none; }
.maintenance-title {
  margin: 10px 0 12px;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 25px;
  line-height: 1.25;
  color: #fff7e6;
}
.maintenance-text { font-size: 14px; line-height: 1.6; color: rgba(245, 242, 234, 0.72); }
.maintenance-text b { color: #f4dfae; font-weight: 600; }
.maintenance-joke {
  margin: 16px auto 0;
  max-width: 430px;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid rgba(232, 195, 122, 0.16);
  background: rgba(232, 195, 122, 0.06);
  color: rgba(244, 223, 174, 0.9);
  font-size: 12.5px;
  letter-spacing: 0.02em;
}
.maintenance-joke.swap { animation: jokeIn 0.38s ease both; }
@keyframes jokeIn {
  from { opacity: 0.55; transform: translateY(3px); }
  to { opacity: 1; transform: translateY(0); }
}
.maintenance-btn {
  margin-top: 20px;
  padding: 13px 30px;
  border-radius: 11px;
  border: 1px solid rgba(232, 195, 122, 0.55);
  background: linear-gradient(180deg, #f3d495, #e0b45c);
  color: #2a1f0c;
  font: inherit;
  font-size: 13.5px;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: transform 0.18s ease, filter 0.18s ease;
}
.maintenance-btn:hover { transform: translateY(-1px); filter: brightness(1.06); }
.maintenance-note { margin-top: 15px; font-size: 11px; line-height: 1.6; letter-spacing: 0.03em; color: rgba(245, 242, 234, 0.4); }
@media (max-width: 720px) {
  .maintenance-card { padding: 22px 18px 20px; }
  .maintenance-tree { width: 140px; height: 140px; }
  .maintenance-title { font-size: 20px; }
  .maintenance-text { font-size: 13px; }
  .maintenance-joke { font-size: 12px; }
}


/* ===== золотая кнопка «поделиться» ===== */
.share-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  align-self: flex-end;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid rgba(232, 195, 122, 0.6);
  background: linear-gradient(180deg, rgba(244, 216, 154, 0.96), rgba(216, 170, 92, 0.96));
  color: #2a1f0c;
  font: inherit;
  font-size: 12px;
  letter-spacing: 0.05em;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 10px 26px rgba(232, 195, 122, 0.22);
  transition: transform 0.16s ease, box-shadow 0.2s ease, filter 0.2s ease;
}
.share-pill:hover { transform: translateY(-1px); filter: brightness(1.04); box-shadow: 0 14px 32px rgba(232, 195, 122, 0.3); }
.share-pill svg { opacity: 0.86; }

.share-sheet {
  position: fixed;
  inset: 0;
  z-index: 65;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(4, 7, 12, 0.7);
  backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.share-sheet.show { opacity: 1; pointer-events: auto; }
.share-card {
  width: 100%;
  max-width: 420px;
  padding: 22px 22px 18px;
  border-radius: 16px;
  border: 1px solid rgba(232, 195, 122, 0.28);
  background: linear-gradient(180deg, rgba(11, 17, 29, 0.96), rgba(6, 10, 18, 0.98));
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}
.share-title { font-family: Georgia, serif; font-size: 19px; color: #fff7e6; margin-bottom: 4px; }
.share-sub { font-size: 12px; color: rgba(245, 242, 234, 0.55); margin-bottom: 14px; }
.share-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.share-opt {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(245, 242, 234, 0.88);
  font: inherit;
  font-size: 12.5px;
  cursor: pointer;
  text-align: left;
  transition: background 0.18s ease, border-color 0.18s ease;
}
.share-opt:hover { background: rgba(232, 195, 122, 0.12); border-color: rgba(232, 195, 122, 0.45); }
.share-opt.wide { grid-column: span 2; justify-content: center; }
.share-close {
  margin-top: 14px;
  width: 100%;
  padding: 10px;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: transparent;
  color: rgba(245, 242, 234, 0.65);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.share-close:hover { border-color: rgba(232, 195, 122, 0.4); color: #f4dfae; }
@media (max-width: 720px) {
  .share-pill { align-self: flex-end; margin-top: 8px; padding: 8px 14px; font-size: 11.5px; }
  .share-grid { grid-template-columns: 1fr; }
  .share-opt.wide { grid-column: span 1; }
}


/* ===== юридический футер, cookie-баннер, согласие ===== */
.pricebar { bottom: 32px; }

.legal {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 12;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 5px 14px 6px;
  font-size: 10px;
  letter-spacing: 0.04em;
  color: rgba(245, 242, 234, 0.42);
  background: linear-gradient(180deg, rgba(4, 7, 12, 0), rgba(4, 7, 12, 0.72));
  pointer-events: auto;
}
.legal a { color: inherit; text-decoration: none; border-bottom: 1px dotted rgba(245, 242, 234, 0.22); }
.legal a:hover { color: #f4dfae; border-bottom-color: rgba(232, 195, 122, 0.6); }
.legal-owner { color: rgba(245, 242, 234, 0.3); }

.cookie {
  position: fixed;
  left: 50%;
  bottom: 14px;
  transform: translate(-50%, 20px);
  width: min(680px, calc(100vw - 28px));
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 14px 16px 14px 18px;
  border-radius: 14px;
  border: 1px solid rgba(232, 195, 122, 0.3);
  background: rgba(8, 13, 24, 0.94);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.cookie.show { opacity: 1; pointer-events: auto; transform: translate(-50%, 0); }
.cookie.hide { display: none; }
.cookie-text { font-size: 12px; line-height: 1.5; color: rgba(245, 242, 234, 0.78); }
.cookie-text a { color: #f4dfae; }
.cookie-actions { display: flex; gap: 8px; flex: 0 0 auto; }
.cookie-btn {
  padding: 9px 14px;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: transparent;
  color: rgba(245, 242, 234, 0.8);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  white-space: nowrap;
}
.cookie-btn:hover { border-color: rgba(232, 195, 122, 0.5); color: #f4dfae; }
.cookie-btn.primary {
  border-color: rgba(232, 195, 122, 0.6);
  background: linear-gradient(180deg, #f0cf8a, #e0b45c);
  color: #2a1f0c;
  font-weight: 600;
}
.cookie-btn.primary:hover { filter: brightness(1.05); color: #2a1f0c; }

.consent-line {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 10px 0 4px;
  font-size: 11.5px;
  line-height: 1.45;
  color: rgba(245, 242, 234, 0.62);
  cursor: pointer;
}
.consent-line input { margin-top: 2px; accent-color: #e0b45c; width: 15px; height: 15px; flex: 0 0 auto; }
.consent-line a { color: #f4dfae; text-decoration: none; border-bottom: 1px dotted rgba(232, 195, 122, 0.5); }

@media (max-width: 720px) {
  .pricebar { bottom: 30px; }
  .legal { gap: 9px; font-size: 9px; padding: 4px 8px 5px; }
  .legal-owner { display: none; }
  .cookie { flex-direction: column; align-items: stretch; gap: 10px; padding: 13px 14px; bottom: 34px; }
  .cookie-actions { justify-content: stretch; }
  .cookie-btn { flex: 1; text-align: center; }
}


/* cookie-баннер выше плашки и футера */
.cookie { bottom: 118px; }
@media (max-width: 720px) {
  .cookie { bottom: 128px; }
}

