/* ==========================================================================
   style.css — вигляд преленду. Кольори винесені у змінні на початку:
   міняєш --pink і --coin, і весь ленд перефарбовується.
   ========================================================================== */

:root{
  --pink:#ff1b6b;          /* акцент: CTA, кнопка "+", плашки */
  --coin:#ffc61a;          /* колір монетки-токена */
  --bg:#0d0d0f;
  --chip:rgba(90,90,96,.55);      /* сірі напівпрозорі пігулки як у додатку */
  --safe-t:env(safe-area-inset-top,0px);
  --safe-b:env(safe-area-inset-bottom,0px);
}
*{box-sizing:border-box;margin:0;padding:0;-webkit-tap-highlight-color:transparent}
html,body{height:100%;overflow:hidden;background:var(--bg);color:#fff;
  font-family:Roboto,-apple-system,"Segoe UI",Helvetica,Arial,sans-serif;
  -webkit-user-select:none;user-select:none}
button{font:inherit;color:inherit;border:0;background:none;cursor:pointer}
svg{display:block}

/* ---------- сцена і картка ---------- */
.stage{position:fixed;inset:0;overflow:hidden}
.card{position:absolute;inset:0;will-change:transform,opacity}
.card.anim{transition:transform .28s ease, opacity .28s ease}
.card__media{position:absolute;inset:0;background:#1a1a1f center/cover no-repeat}
.card__media video,.card__media img{width:100%;height:100%;object-fit:cover;display:block}
/* затемнення знизу, щоб читались подарунки і CTA */
.card::after{content:"";position:absolute;inset:0;pointer-events:none;
  background:linear-gradient(to bottom,rgba(0,0,0,.35) 0 14%,transparent 30% 55%,rgba(0,0,0,.55) 100%)}

/* ---------- верхня пігулка з імʼям ---------- */
.c-top{position:absolute;left:8px;top:calc(var(--safe-t) + 8px);z-index:3;
  display:flex;align-items:center;gap:8px;background:var(--chip);
  border-radius:26px;padding:4px 4px 4px 5px;backdrop-filter:blur(6px)}
.c-top__ava{width:38px;height:38px;border-radius:50%;background:#555 center/cover no-repeat;flex:none}
.c-top__name{font-size:15px;font-weight:500;max-width:34vw;overflow:hidden;
  text-overflow:ellipsis;white-space:nowrap}
.c-top__age{font-size:15px;opacity:.95}
.c-top__ok{width:16px;height:16px;flex:none}
.c-top__plus{width:38px;height:38px;border-radius:50%;background:var(--pink);
  display:flex;align-items:center;justify-content:center;font-size:24px;font-weight:300;line-height:1;flex:none}

/* ---------- монети / глядачі ---------- */
.c-stats{position:absolute;left:8px;top:calc(var(--safe-t) + 54px);z-index:3;display:flex;gap:7px}
.c-stats span{display:flex;align-items:center;gap:5px;background:var(--chip);
  border-radius:16px;padding:4px 10px;font-size:13px;font-weight:500;backdrop-filter:blur(6px)}
.coin{display:inline-block;width:13px;height:13px;border-radius:50%;flex:none;
  background:radial-gradient(circle at 35% 30%,#ffe17a,var(--coin) 60%,#d79a00);
  box-shadow:inset 0 0 0 1px rgba(0,0,0,.15)}
.eye{width:15px;height:15px;fill:#fff;opacity:.9}

/* ---------- права колонка іконок ---------- */
.c-right{position:absolute;right:8px;top:calc(var(--safe-t) + 6px);z-index:3;
  display:flex;flex-direction:column;gap:9px;align-items:center}
.c-right button{width:38px;height:38px;border-radius:50%;background:rgba(60,60,66,.6);
  display:flex;align-items:center;justify-content:center;backdrop-filter:blur(6px)}
.c-right svg{width:19px;height:19px;fill:#fff}
.c-right .x svg{width:16px;height:16px}

/* ---------- ціль збору ---------- */
.c-goal{position:absolute;left:8px;top:calc(var(--safe-t) + 92px);z-index:3;
  background:rgba(40,40,46,.55);border-radius:8px;padding:5px 9px;min-width:135px;backdrop-filter:blur(6px)}
.c-goal__lbl{font-size:11.5px;opacity:.95;margin-bottom:4px;text-align:center}
.c-goal__bar{height:4px;border-radius:3px;background:rgba(255,255,255,.25);overflow:hidden}
.c-goal__bar i{display:block;height:100%;background:linear-gradient(90deg,var(--coin),#ff8a00)}
.c-goal__num{display:flex;align-items:center;gap:5px;font-size:11.5px;margin-top:4px}

/* ---------- підказка-побажання справа ---------- */
.c-tip{position:absolute;right:56px;top:38%;z-index:3;text-align:center;
  background:rgba(40,40,46,.5);border-radius:8px;padding:7px 10px;backdrop-filter:blur(6px)}
.c-tip__lbl{font-size:11.5px;margin-bottom:4px}
.c-tip__emo{font-size:22px;line-height:1}
.c-tip__price{display:flex;align-items:center;justify-content:center;gap:5px;font-size:12px;margin-top:4px}

/* ---------- стікер sale + таймер ----------
   Та сама золота зірка, що на плашці бонусу, тільки менша. Клікабельна. */
.c-sale{position:absolute;right:6px;bottom:25%;z-index:3;width:92px;height:92px;
  transform:rotate(-11deg);cursor:pointer;
  filter:drop-shadow(0 4px 14px rgba(255,150,0,.45))}
.c-sale svg{width:100%;height:100%}
.c-sale .st-top{font-size:27px;letter-spacing:0}
.c-sale .st-band{font-size:26px;letter-spacing:.5px}
.c-sale:active{transform:rotate(-11deg) scale(.95)}

.c-time{position:absolute;right:14px;bottom:21%;z-index:3;
  font-size:13px;font-weight:700;font-variant-numeric:tabular-nums;
  color:#ffd04d;text-shadow:0 1px 4px rgba(0,0,0,.7)}

/* ---------- рядок подарунків ---------- */
.c-gifts{position:absolute;left:0;right:0;bottom:calc(var(--safe-b) + 74px);z-index:3;
  display:flex;justify-content:space-around;padding:0 6px}
.c-gifts .g-item{text-align:center;cursor:pointer;padding:4px 2px;border-radius:10px}
.c-gifts .g-item:active{background:rgba(255,255,255,.12);transform:scale(.94)}
.c-gifts .g-emo{font-size:26px;line-height:1;pointer-events:none}
.c-gifts .g-price{display:flex;align-items:center;justify-content:center;gap:4px;font-size:12.5px;
  font-weight:500;margin-top:3px;text-shadow:0 1px 3px rgba(0,0,0,.6);pointer-events:none}

/* ---------- нижня панель ---------- */
.bar{position:fixed;left:0;right:0;bottom:0;z-index:6;display:flex;align-items:center;gap:10px;
  padding:0 10px calc(var(--safe-b) + 12px);height:auto}
.bar__round{width:46px;height:46px;border-radius:50%;background:rgba(20,20,22,.85);flex:none;
  display:flex;align-items:center;justify-content:center}
.bar__round svg{width:22px;height:22px;fill:#fff}
.bar__cta{flex:1;height:48px;border-radius:24px;background:var(--pink);
  display:flex;align-items:center;justify-content:center;gap:9px;
  font-size:16px;font-weight:700;box-shadow:0 6px 18px rgba(255,27,107,.35)}
.bar__cta svg{width:24px;height:24px;fill:#fff}
.bar__cta:active{transform:scale(.98)}

/* ---------- підказка про свайп ---------- */
.hint{position:fixed;inset:0;z-index:10;display:flex;flex-direction:column;
  align-items:center;justify-content:center;gap:14px;
  background:rgba(0,0,0,.55);backdrop-filter:blur(7px);-webkit-backdrop-filter:blur(7px);
  transition:opacity .45s ease;opacity:1}
.hint.off{opacity:0;pointer-events:none}
.hint__ico svg{width:78px;height:78px;fill:none;stroke:#fff;stroke-width:3;
  stroke-linecap:round;stroke-linejoin:round;animation:swipeUp 1.5s ease-in-out infinite}
.hint__hand{fill:rgba(255,255,255,.14)}
.hint__txt{font-size:15px;font-weight:500;opacity:.95;text-align:center;padding:0 30px}
@keyframes swipeUp{0%,100%{transform:translateY(6px)}50%{transform:translateY(-10px)}}
@media (prefers-reduced-motion:reduce){.hint__ico svg{animation:none}}

/* ---------- інпейдж-плашка зверху ---------- */
.push{position:fixed;left:8px;right:8px;top:calc(var(--safe-t) + 8px);z-index:12;
  display:flex;align-items:center;gap:10px;padding:10px 34px 10px 10px;
  background:#f2f2f4;color:#16161a;border-radius:12px;
  box-shadow:0 10px 30px rgba(0,0,0,.45);
  transform:translateY(calc(-100% - 30px));transition:transform .4s cubic-bezier(.2,.8,.2,1)}
.push.on{transform:translateY(0)}
.push__ico{width:42px;height:42px;border-radius:9px;background:#ccc center/cover no-repeat;flex:none}
.push__body{flex:1;min-width:0}
.push__title{font-size:13.5px;font-weight:700;line-height:1.25}
.push__text{font-size:12.5px;color:#55555e;line-height:1.3;margin-top:2px}
.push__btn{background:var(--pink);color:#fff;font-size:13px;font-weight:700;
  padding:9px 13px;border-radius:9px;flex:none}
.push__x{position:absolute;right:6px;top:4px;font-size:19px;line-height:1;color:#8a8a93;padding:4px 7px}

/* ---------- плашка бонусу: золота зірка з променями ----------
   Промені — conic-gradient із золотих клинів, притемнений до країв
   маскою, щоб не різав рамку плашки. */
.bonus{position:fixed;left:12px;right:12px;bottom:calc(var(--safe-b) + 74px);z-index:11;
  overflow:hidden;isolation:isolate;
  background:#17171c;border:1px solid #3a3222;border-radius:16px;
  padding:16px 16px 14px;text-align:center;
  box-shadow:0 14px 40px rgba(0,0,0,.6),0 0 0 1px rgba(255,198,26,.12) inset;
  transform:translateY(calc(100% + 100px));transition:transform .38s cubic-bezier(.2,.8,.2,1)}
.bonus.on{transform:translateY(0)}

.bonus__rays{position:absolute;left:50%;top:62px;width:460px;height:460px;
  transform:translate(-50%,-50%);z-index:-1;pointer-events:none;opacity:.22;
  background:repeating-conic-gradient(from 0deg,
    #ffc61a 0deg 6deg, transparent 6deg 13deg);
  -webkit-mask-image:radial-gradient(circle,#000 8%,rgba(0,0,0,.35) 26%,transparent 46%);
  mask-image:radial-gradient(circle,#000 8%,rgba(0,0,0,.35) 26%,transparent 46%);
  animation:rays 32s linear infinite}
@keyframes rays{to{transform:translate(-50%,-50%) rotate(360deg)}}

.bonus__star{width:122px;height:122px;margin:0 auto 4px}
.bonus__star svg{width:100%;height:100%;
  filter:drop-shadow(0 6px 20px rgba(255,170,0,.5))}

/* написи всередині зірки: над стрічкою темний, у стрічці золотий */
.st-top{fill:#4a3000;font-size:46px;font-weight:700;letter-spacing:-1px;
  font-family:Roboto,-apple-system,"Segoe UI",Helvetica,Arial,sans-serif}
.st-band{fill:#f7cf6a;font-size:22px;font-weight:700;letter-spacing:1px;
  font-family:Roboto,-apple-system,"Segoe UI",Helvetica,Arial,sans-serif}

.bonus__title{font-size:18px;font-weight:700;letter-spacing:.2px}
.bonus__text{font-size:13px;color:#c6c0b2;line-height:1.4;margin-top:6px}
.bonus__btn{display:block;width:100%;margin-top:14px;height:46px;border-radius:23px;
  background:var(--pink);font-size:15.5px;font-weight:700;
  box-shadow:0 8px 22px rgba(255,27,107,.35)}
.bonus__skip{display:block;margin:10px auto 0;font-size:12.5px;color:#7d7d87;text-decoration:underline}
.bonus__x{position:absolute;right:8px;top:6px;z-index:2;font-size:22px;line-height:1;
  color:#8a8a93;padding:4px 8px}
@media (prefers-reduced-motion:reduce){.bonus__rays{animation:none}}

/* ---------- фінальна плашка ---------- */
.final{position:fixed;inset:0;z-index:14;display:none;align-items:center;justify-content:center;padding:22px;
  background:rgba(0,0,0,.6);backdrop-filter:blur(9px);-webkit-backdrop-filter:blur(9px)}
.final.on{display:flex;animation:fIn .3s ease both}
@keyframes fIn{from{opacity:0}to{opacity:1}}
.final__box{width:min(88vw,330px);background:#17171c;border:1px solid #2a2a32;border-radius:18px;
  padding:24px 18px 18px;text-align:center;box-shadow:0 18px 50px rgba(0,0,0,.65)}
.final__coin{margin-bottom:12px}
.final__coin .coin{display:block;width:52px;height:52px;margin:0 auto;
  box-shadow:0 0 22px rgba(255,198,26,.45),inset 0 0 0 2px rgba(0,0,0,.12)}
.final__title{font-size:18px;font-weight:700}
.final__text{font-size:13.5px;color:#b9b9c2;line-height:1.45;margin-top:8px}
.final__btn{display:block;width:100%;margin-top:16px;height:48px;border-radius:24px;
  background:var(--pink);font-size:16px;font-weight:700;box-shadow:0 8px 22px rgba(255,27,107,.35)}

/* ---------- широкий екран: тримаємо вертикальний формат по центру ---------- */
@media (min-width:620px){
  .stage,.bar,.push,.bonus{max-width:440px;left:50%;transform:translateX(-50%)}
  .bar{right:auto;width:100%}
  .push{transform:translateX(-50%) translateY(calc(-100% - 30px))}
  .push.on{transform:translateX(-50%) translateY(0)}
  .bonus{transform:translateX(-50%) translateY(calc(100% + 100px))}
  .bonus.on{transform:translateX(-50%) translateY(0)}
  body{background:#000}
}
