:root {
  /* --- Color palette from second CSS --- */
  --bg-main: radial-gradient(60% 60% at 50% 20%, #2a2f45 0%, #0b0e19 100%);
  --glass-bg: rgba(255,255,255,0.08);
  --glass-border: rgba(255,255,255,0.18);
  --accent-red: #e53935;
  --accent-gold: #f5c46b;
  --text-main: #ffffff;
  --text-muted: rgba(255,255,255,0.6);
  --radius-xl: 22px;
  --radius-lg: 16px;
  --blur: blur(18px);
  --font-main: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
  
  /* --- Game-specific variables --- */
  --brand1: #f5c46b;
  --brand2: #e9c979;
  --accent: #4da3ff;
  --violet: #a64aff;
  
  --radius-md: 14px;
  --shadow-lg: 0 22px 70px rgba(0,0,0,.55);
  --shadow-md: 0 14px 45px rgba(0,0,0,.45);
  --shadow-in: inset 0 1px 0 rgba(255,255,255,.06);
  
  --space-1: 6px;
  --space-2: 10px;
  --space-3: 14px;
  --space-4: 18px;
  --space-5: 22px;
  --tap: 56px;
}

*{box-sizing:border-box}
html,body{height:100%; margin:0;}

body {
  color: var(--text-main);
  font-family: var(--font-main);
  background: var(--bg-main);
  overflow: hidden;
}

/* Фоновая картинка */
.bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background-image: url('assets/osnovanie.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* ====== РАЗМЫТИЕ ФОНА ДЛЯ НЕГЛАВНЫХ СТРАНИЦ ====== */
.bg-blur .bg {
    filter: blur(8px);
    transition: filter 0.3s ease;
}

/* Контейнер для затемнения поверх фона */
.page-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 12, 24, 0.7);
    backdrop-filter: blur(4px);
    z-index: 9;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.bg-blur .page-overlay {
    opacity: 1;
    pointer-events: all;
}

/* Убедимся что контент страниц выше фона */
.page {
    position: relative;
    z-index: 10;
}

/* Создаем контейнер для всего контента вверху */
header {
    position: relative;
    z-index: 10;
}

/* Градиентный оверлей поверх фона, но под контентом */
header::before {
    content: '';
    position: absolute;
    top: -100px; /* Расширяем вверх за пределы header */
    left: 0;
    right: 0;
    height: 300px; /* Достаточная высота для плавного перехода */
    background: linear-gradient(
        to bottom,
        rgba(10, 12, 24, 0.95) 0%,    /* Темный вверху */
        rgba(10, 12, 24, 0.85) 15%,   /* Полупрозрачный */
        rgba(10, 12, 24, 0.7) 30%,    /* Еще прозрачнее */
        rgba(10, 12, 24, 0.4) 60%,    /* Полупрозрачный */
        rgba(10, 12, 24, 0.1) 85%,    /* Почти прозрачный */
        transparent 100%              /* Полностью прозрачный внизу */
    );
    pointer-events: none; /* Чтобы не мешал кликам */
    z-index: -1; /* Помещаем под контентом header */
}

/* Альтернативный вариант с более выраженным градиентом */
header::after {
    content: '';
    position: absolute;
    top: -50px;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.6) 0%,
        rgba(0, 0, 0, 0.3) 40%,
        rgba(0, 0, 0, 0.1) 70%,
        transparent 100%
    );
    pointer-events: none;
    z-index: -1;
    mask-image: linear-gradient(
        to bottom,
        black 0%,
        black 60%,
        transparent 100%
    );
    -webkit-mask-image: linear-gradient(
        to bottom,
        black 0%,
        black 60%,
        transparent 100%
    );
}

/* --- Topbar как во втором примере --- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: rgba(10, 12, 24, 0.8);
  backdrop-filter: var(--blur);
  border-bottom: 1px solid var(--glass-border);
}

.title {
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.title .subtitle {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.title .badge {
  color: var(--accent);
  margin-left: 6px;
}

.icon-btn {
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  color: var(--text-main);
  border-radius: 12px;
  display: grid;
  place-items: center;
  cursor: pointer;
  font-size: 16px;
}

.icon-btn:hover {
  background: var(--glass-bg);
}

/* Progress capsule (pixel-perfect style) */
.progress-wrap {
  margin: 8px 16px 0;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: rgba(8,10,18,0.55);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 26px;
  backdrop-filter: blur(14px);
  box-shadow:
    0 14px 30px rgba(0,0,0,0.38),
    inset 0 1px 0 rgba(255,255,255,0.08);
}

.progress-inner {
  position: relative;
  flex: 1;
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px 8px 10px;
  border-radius: 22px;
  background: linear-gradient(180deg, #f7dfa3 0%, #e9c979 48%, #d7ad55 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.55),
    inset 0 -8px 16px rgba(0,0,0,0.18),
    0 8px 18px rgba(0,0,0,0.18);
}

.progress-inner:before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 20px;
  border: 1px solid rgba(90,60,10,0.22);
  pointer-events: none;
}

.avatar-medal {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  flex: 0 0 34px;
  padding: 2px;
  background: linear-gradient(180deg,#f9e7b8 0%, #e0b562 100%);
  box-shadow:
    0 8px 16px rgba(0,0,0,0.22),
    inset 0 1px 0 rgba(255,255,255,0.55);
}

.avatar-medal .avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 14px;
  color: #1a0f22;
  background: linear-gradient(135deg, rgba(58,167,255,.32), rgba(166,74,255,.22));
  overflow: hidden;
}

.avatar-medal .avatar.has-photo {
  background-size: cover;
  background-position: center;
}

.progress-text {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.2px;
  color: rgba(18,14,8,0.92);
  text-shadow: 0 1px 0 rgba(255,255,255,0.35);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.progress-count {
  flex: 0 0 auto;
  padding: 0 10px;
  font-size: 16px;
  font-weight: 600;
  color: rgba(255,255,255,0.8);
}

/* ... предыдущие стили остаются ... */

/* --- Stats row (Lives / Coins) --- */
.stats-row {
  margin: 8px 16px 12px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 18px;
  backdrop-filter: var(--blur);
  box-shadow: 
    0 10px 30px rgba(0,0,0,0.3),
    inset 0 1px 0 rgba(255,255,255,0.08);
  min-height: 70px;
}

.stat-icon {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
}

.stat-icon:before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: 14px;
}

.stat-icon.coin {
}

/* Стили для SVG внутри иконок */
.stat-icon svg {
  width: 84px;
  height: 84px;
  transform: scale(0.45); /* Масштабируем большие SVG */
  position: absolute;
  z-index: 1;
}

/* Специальные стили для ваших монет и жизней SVG */
.stat-card:nth-child(1) .stat-icon svg {
  transform: scale(0.4) translateY(-2px); /* Жизни */
}

.stat-card:nth-child(2) .stat-icon svg {
  transform: scale(0.38) translateY(-1px); /* Монеты */
}

.stat-meta { 
  line-height: 1.1;
  min-width: 0;
  flex: 1;
}

.stat-label {
  font-size: 12px;
  letter-spacing: 0.3px;
  color: rgba(255,255,255,0.7);
  font-weight: 600;
  margin-bottom: 4px;
  white-space: nowrap;
}

.stat-value {
  font-size: 20px;
  font-weight: 800;
  color: var(--text-main);
  text-shadow: 0 2px 4px rgba(0,0,0,0.1);
  line-height: 1;
}

/* Стили для чисел с разделением */
.stat-value span {
  font-weight: 800;
}

.stat-value span:last-child {
  color: rgba(255,255,255,0.7);
  font-size: 18px;
}

/* Эффекты при наведении */
.stat-card:hover {
  transform: translateY(-1px);
  box-shadow: 
    0 12px 35px rgba(0,0,0,0.35),
    inset 0 1px 0 rgba(255,255,255,0.1);
  transition: all 0.2s ease;
}

/* Адаптивность */
@media (max-width: 380px) {
  .stats-row { 
    grid-template-columns: 1fr; 
    gap: 10px;
    margin-left: 12px;
    margin-right: 12px;
  }
  
  .stat-card {
    padding: 12px;
  }
  
  .stat-icon {
    width: 42px;
    height: 42px;
  }
  
  .stat-icon svg {
    width: 26px;
    height: 26px;
  }
  
  .stat-value {
    font-size: 18px;
  }
}

@media (max-width: 320px) {
  .stat-card {
    flex-direction: column;
    text-align: center;
    gap: 8px;
    padding: 10px;
  }
  
  .stat-meta {
    width: 100%;
  }
}

/* --- Остальные стили вашей игры --- */
.app {
  height: 100%;
  padding: 0 16px calc(96px + env(safe-area-inset-bottom));
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

.page { display: none; }
.page.active { display: block; }

/* --- Generic surfaces --- */
.card, .gameCard {
  margin-top: 26px;
  border-radius: var(--radius-xl);
  /*background: var(--glass-bg);*/
  /*border: 1px solid var(--glass-border);*/
  /*box-shadow: var(--shadow-lg);*/
  padding: var(--space-4);
  /*backdrop-filter: var(--blur);*/
}

.card { margin-bottom: var(--space-3); }
.cardTitle { font-weight: 900; font-size: 14px; letter-spacing: .2px; margin-bottom: 12px; }

/* --- Game --- */
.gameHeader { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.title { font-weight: 950; font-size: 16px; letter-spacing: .2px; }
.xpPill {
  font-size: 12px;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255,160,40,.14);
  border: 1px solid rgba(255,160,40,.25);
  color: rgba(255,240,230,.92);
  white-space: nowrap;
}

.board {
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  /*padding: 12px;*/
  border-radius: var(--radius-xl);
  /*background: rgba(0,0,0,.22);*/
  /*border: 1px solid rgba(255,255,255,.12);*/
  /*box-shadow: var(--shadow-in), 0 18px 55px rgba(0,0,0,.38);*/
  /*backdrop-filter: blur(12px);*/
}

/* Grid is controlled from JS via --grid-cols (fallback 3) */
#holesGrid, .tam-grid {
  display: grid;
  grid-template-columns: repeat(var(--grid-cols, 3), 1fr);
  gap: 12px;
  padding: 10px;
  width: 100%;
  aspect-ratio: 1 / 1;
}

.hole {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 100%;
  border-radius: 22px;
  overflow: hidden;
  cursor: pointer;
  touch-action: manipulation;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transform: translateZ(0);
}

.hole-inner { position: absolute; inset: 0; border-radius: 22px; overflow: hidden; }

.holeImg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; z-index: 1; top:30px;}
.moleImg {
  position: absolute;
  left: 50%;
  bottom: -80%;
  transform: translateX(-60%);
  width: 70%;
  height: auto;
  object-fit: contain;
  pointer-events: none;
  z-index: 2;
  transition: bottom .35s cubic-bezier(.18,.88,.32,1.5), filter .18s ease;
  will-change: bottom;
}

.moleImg.up { bottom: 14%; }
.moleImg.hit { filter: drop-shadow(0 0 22px rgba(255,70,70,.65)) brightness(1.18); }
.moleImg.bonus { filter: drop-shadow(0 0 26px rgba(255,210,60,.85)) brightness(1.15); }

.hammerImg {
  position: absolute;
  left: 60%;
  top: 8%;
  width: 86%;
  height: auto;
  object-fit: contain;
  pointer-events: none;
  z-index: 3;
  opacity: 0;
  transform: translateX(-50%) rotate(-25deg);
  transform-origin: 20% 80%;
}

.hammerImg.swing { opacity: 1; animation: hammerSwing .28s ease-out; }

@keyframes hammerSwing { 
  0% { transform: translateX(-50%) rotate(-35deg) scale(1.12); } 
  50% { transform: translateX(-50%) rotate(18deg) scale(.92); } 
  100% { transform: translateX(-50%) rotate(-25deg) scale(1); } 
}

.hole.active-hole {}
.hole.miss { animation: missShake .24s ease; }

@keyframes missShake { 
  0%,100% { transform: translateX(0); } 
  25% { transform: translateX(-3px); } 
  75% { transform: translateX(3px); } 
}

.gameFooter { display: flex; gap: 10px; margin-top: 14px; }

.btn {
  height: var(--tap);
  flex: 1;
  border: 0;
  border-radius: 18px;
  padding: 0 16px;
  font-weight: 950;
  cursor: pointer;
  color: #1a0f22;
  background: linear-gradient(135deg, var(--brand1), var(--brand2));
  box-shadow: 0 16px 44px rgba(255,120,0,.30);
}

.btn:active { transform: translateY(1px); }

.btn.ghost {
  color: var(--text-main);
  background: rgba(255,255,255,.06);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-in);
}

.btn:disabled { opacity: .55; cursor: not-allowed; }

.btn .btn-icon { display: inline-flex; align-items: center; gap: 8px; }
.btn .btn-icon i { font-size: 14px; }

.tip { padding: 10px 6px; color: rgba(255,255,255,.72); font-size: 12px; text-align: center; }

/* --- Обновленный Bottom navigation --- */
.bottomNav {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  padding: 10px 14px calc(env(safe-area-inset-bottom) + 10px);
  display: grid;
  grid-template-columns: 1fr 1fr 84px 1fr 1fr;
  align-items: end;
  gap: 10px;
  z-index: 60;
  /* Убираем старый градиент и тени */
  /* Добавляем новый фон с градиентом и тенями как в progress-inner */
}

/* Контейнер для внутреннего градиента */
.bottomNav::before {
  content: '';
  position: absolute;
  left: 12px; right: 12px;
  bottom: calc(env(safe-area-inset-bottom) + 6px);
  height: 64px;
  border-radius: 16px; /* Более скругленные углы как в progress-wrap */
  background:
  radial-gradient(
    60% 55% at 50% 18%,
    #2b3046 0%,
    #1a1f33 40%,
    #0c0f1b 75%,
    #090b14 100%
  ),
  linear-gradient(
    180deg,
    #1a1f33 0%,
    #0b0e19 100%
  );

  box-shadow:inset 0 1px 0 rgb(15 15 15 / 55%), inset 0 -8px 16px rgba(0, 0, 0, 0.18), 0 8px 18px rgba(0, 0, 0, 0.18);
  z-index: 1;
}

/* Дополнительный бордер как в progress-inner:before */
.bottomNav::after {
  content: "";
  position: absolute;
  left: 14px; right: 14px;
  bottom: calc(env(safe-area-inset-bottom) + 8px);
  height: 60px;
  border-radius: 14px; /* Немного меньше, чем основной контейнер */
  border: 1px solid rgb(92 109 188 / 22%);
  pointer-events: none;
  z-index: 2;
}

/* Центральная кнопка должна быть выше */
.navCenter, .centerRing {
  position: relative;
  z-index: 3;
}

/* ====== СТИЛИ ДЛЯ КНОПОК НАВИГАЦИИ ====== */
.navItem {
    height: 56px;
    width: 56px;
    border-radius: 16px;
    background: transparent;
    border: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    position: relative;
    z-index: 3;
    transition: all 0.2s ease;
    padding: 0;
    margin: 0 auto;
}

/* Контейнер для SVG и текста */
.navItem .icon-container {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
}

/* Стили для SVG иконок */
.navItem svg {
    width: 26px;
    height: 26px;
    fill: rgb(207 213 243 / 92%);
    stroke: rgba(0, 0, 0, 0.92);
    stroke-width: 0.5;
    filter: drop-shadow(0 1px 0 rgba(255, 255, 255, 0.35));
    transition: all 0.2s ease;
}

.navItem span {color:rgb(207 213 243 / 92%);font-size:11px;letter-spacing: 0.2px;}

/* Подпись под иконкой */
.navItem .icon-label {
    font-size: 10px;
    font-weight: 700;
    color: rgba(18, 14, 8, 0.85);
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
    letter-spacing: 0.2px;
    white-space: nowrap;
    opacity: 0;
    transform: translateY(-5px);
    transition: all 0.2s ease;
}

/* Активная кнопка */
.navItem.active {
    background: rgba(255, 255, 255, 0.2);
}

.navItem.active svg {
    fill: rgba(166, 74, 255, 0.95);
    stroke: rgba(166, 74, 255, 0.95);
    filter: drop-shadow(0 2px 4px rgba(166, 74, 255, 0.3));
}

.navItem.active .icon-label {
    opacity: 1;
    transform: translateY(0);
    color: rgba(166, 74, 255, 0.95);
}

/* Ховер эффект */
.navItem:hover:not(.active) {
    background: rgba(255, 255, 255, 0.1);
}


/* Центральная кнопка */
.navCenter {
  position: relative;
  height: 84px;
  border: 0;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 4; /* Выше всех */
}

.centerRing {
  position: absolute;
  width: 84px; height: 84px;
  border-radius: 999px;
  background:
  radial-gradient(
    65% 60% at 50% 20%,
    #ff4d4d 0%,
    #c91c14 40%,
    #8f140d 75%,
    #2a0503 100%
  );

  border: 1px solid rgba(255,160,40,.26);
  box-shadow: 
    0 22px 64px rgba(0,0,0,.60), 
    0 0 26px rgba(255,120,0,.16),
    inset 0 1px 0 rgba(255,255,255,0.55), /* Добавляем внутреннюю подсветку */
    inset 0 -4px 8px rgba(0,0,0,0.2); /* Добавляем внутреннюю тень */
}

.centerRing::before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 999px;
  border: 1px solid rgba(90,60,10,0.22);
  pointer-events: none;
}

.centerHead {
  position: relative;
  width: 178px; height: 128px;
  transform: translateY(25px);
  filter: drop-shadow(0 18px 30px rgba(0,0,0,.60));
  border-radius: 999px;
  z-index: 5;
}

/* Прогресс бар в навигации */
.bottomNav > * { position: relative; z-index: 3; }

.bottomNav .progress-fill {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: var(--progress-width, 0%);
    height: 100%;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.1));
    border-radius: inherit;
    transition: width 0.5s ease;
    z-index: 2;
}

/* canvas overlay */
#fx { position: fixed; inset: 0; pointer-events: none; z-index: 10; }

/* --- Responsive --- */
@media (max-width: 390px) {
  .board { padding: 10px; }
  #holesGrid, .tam-grid { gap: 10px; padding: 8px; }
}

@media (max-width: 360px) {
  .progress-wrap, .stats-row, .app, .bottomNav {
    margin-left: 12px;
    margin-right: 12px;
  }
}

/* ====== ЗАГРУЗОЧНЫЙ ЭКРАН С РАЗМЫТЫМ ФОНОМ ====== */
.loading-screen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.5s ease;
    overflow: hidden;
}

.loading-screen::before {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        /* Темный оверлей */
        linear-gradient(rgba(10, 12, 24, 0.8), rgba(10, 12, 24, 0.9)),
        /* Ваше изображение фона */
        url('assets/ui/bg_loading.png') center/cover no-repeat;
    filter: blur(3px) brightness(0.7);
    z-index: -1;
}

/* Дополнительный слой для большего размытия */
.loading-screen::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(10, 12, 24, 0.3);
    backdrop-filter: blur(1px);
    z-index: -1;
}

.loading-screen:not(.active) {
  opacity: 0;
  pointer-events: none;
}

.loading-content {
  max-width: 100%;
  width: 98%;
  text-align: center;
  padding: 30px;
}

.loading-logo {
  width: 100%;
  height: auto;
  margin: 0 auto 20px;
  overflow: hidden;
  padding: 10px;
}

.loading-logo-img {
  width: 320px;
  height: 100%;
  object-fit: contain;
  border-radius: 50%;
}

.loading-title {
  font-size: 24px;
  font-weight: 900;
  color: var(--text-main);
  margin-bottom: 8px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.loading-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 30px;
}


/* ====== СТИЛИЗАЦИЯ ПРОГРЕСС БАРА В СТИЛЕ PROGRESS-INNER ====== */
.loading-progress {
    margin: 40px 0;
    position: relative;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

/* Контейнер прогресс бара */
.loading-progress-bar {
    width: 100%;
    height: 44px;
    border-radius: 14px;
    background: linear-gradient(180deg, #f7dfa3 0%, #e9c979 48%, #d7ad55 100%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.55),
        inset 0 -8px 16px rgba(0, 0, 0, 0.18),
        0 8px 18px rgba(0, 0, 0, 0.18);
    position: relative;
    overflow: hidden;
}

.loading-progress-bar::before {
    content: "";
    position: absolute;
    inset: 2px;
    border-radius: 16px;
    border: 1px solid rgba(90, 60, 10, 0.22);
    pointer-events: none;
    z-index: 1;
}

/* Заполняющая часть (градиент) */
.loading-progress-fill {
    position: absolute;
    top: 2px;
    left: 2px;
    height: calc(100% - 4px);
    width: 0%;
    background: radial-gradient(60% 60% at 50% 20%, #2a2f45 0%, #0b0e19 100%);
    border-radius: 14px;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 0;
    background-size: 200% 100%;
    animation: progressGradient 2s ease infinite;
}

@keyframes progressGradient {
    0% { background-position: 100% 0; }
    50% { background-position: 0 0; }
    100% { background-position: 100% 0; }
}



/* Текст прогресса */
.loading-progress-text {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 400;
    color: rgba(18, 14, 8, 0.92);
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
    letter-spacing: 0.5px;
    z-index: 2;
}

.loading-tips {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.loading-tip {
  font-size: 13px;
  color: var(--text-muted);
  margin: 10px 0;
  padding: 8px;
  background: rgba(255,255,255,0.05);
  border-radius: 8px;
  animation: fadeInUp 0.5s ease forwards;
  opacity: 0;
}

.loading-tip:nth-child(1) { animation-delay: 0.2s; }
.loading-tip:nth-child(2) { animation-delay: 0.4s; }
.loading-tip:nth-child(3) { animation-delay: 0.6s; }

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ====== АНИМАЦИИ ДЛЯ ПРОГРЕССА ====== */
@keyframes progressPulse {
    0%, 100% { 
        opacity: 1;
        transform: scale(1);
    }
    50% { 
        opacity: 0.9;
        transform: scale(1.01);
    }
}

.loading-progress-bar {
    animation: progressPulse 2s ease-in-out infinite;
}

/* ====== ПРОЦЕНТЫ ВНУТРИ ПРОГРЕСС БАРА ====== */
.loading-percent {
    position: absolute;
    right: -40px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
    font-weight: 700;
    color: rgba(18, 14, 8, 0.85);
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
    min-width: 36px;
    text-align: center;
    z-index: 3;
}

/* ====== МОДАЛЬНЫЕ ОКНА ====== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(10px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.modal-content {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 30px;
  max-width: 400px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  backdrop-filter: var(--blur);
  box-shadow: var(--shadow-lg);
  animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ====== УЛУЧШЕННОЕ МОДАЛЬНОЕ ОКНО ПОВЫШЕНИЯ УРОВНЯ ====== */
.levelup-modal {
  background: linear-gradient(180deg, #f7dfa3 0%, #e9c979 48%, #d7ad55 100%);
  border: 1px solid rgba(90,60,10,0.22);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.55),
    inset 0 -8px 16px rgba(0,0,0,0.18),
    0 8px 18px rgba(0,0,0,0.18),
    0 22px 64px rgba(0,0,0,0.60);
  position: relative;
}

.levelup-modal::before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 22px;
  border: 1px solid rgba(90,60,10,0.22);
  pointer-events: none;
}

.levelup-header {
  position: relative;
  z-index: 1;
}

.levelup-icon-img {
  width: 100%;
  height: auto;
  margin: 0 auto 20px;
  display: block;
  filter: drop-shadow(0 18px 30px rgba(0,0,0,0.60));
}

@keyframes levelUpIcon {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

.levelup-title {
  font-size: 32px;
  font-weight: 900;
  color: rgba(18,14,8,0.92);
  margin-bottom: 10px;
  text-shadow: 0 2px 4px rgba(255,255,255,0.35);
  letter-spacing: 1px;
}

.levelup-body {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border-radius: 18px;
  padding: 20px;
  margin: 20px 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  position: relative;
  z-index: 1;
}

.levelup-level {
  font-size: 96px;
  font-weight: 900;
  color: #1a0f22;
  text-shadow: 
    0 4px 8px rgba(0,0,0,0.3),
    0 2px 4px rgba(255,255,255,0.4);
  margin: 20px 0;
  animation: levelUpNumber 0.6s ease;
  background: linear-gradient(135deg, #ffd700, #ff9900);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

@keyframes levelUpNumber {
  0% {
    transform: scale(0.5) rotate(-10deg);
    opacity: 0;
  }
  70% {
    transform: scale(1.2) rotate(5deg);
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

.levelup-message {
  font-size: 16px;
  line-height: 1.5;
  color: rgba(18,14,8,0.85);
  margin-bottom: 24px;
  text-align: center;
  font-weight: 600;
  text-shadow: 0 1px 0 rgba(255,255,255,0.35);
}

.levelup-rewards {
  display: flex;
  justify-content: center;
  gap: 30px;
  margin-top: 24px;
}

.levelup-reward {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 15px 20px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  min-width: 120px;
}

.reward-icon {
  font-size: 32px;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3));
}

.reward-text {
  font-size: 14px;
  color: #1a0f22;
  font-weight: 700;
  text-shadow: 0 1px 0 rgba(255,255,255,0.35);
}

.levelup-footer {
  position: relative;
  z-index: 1;
}

.levelup-btn {
  width: 100%;
  height: 56px;
  font-size: 18px;
  font-weight: 900;
  background: radial-gradient(60% 60% at 50% 20%, #2a2f45 0%, #0b0e19 100%);
  border: none;
  color: white;
  border-radius: 16px;
}

.levelup-btn:active {
  transform: translateY(2px);
}

/* ====== СООБЩЕНИЯ ИГРЫ ====== */
.game-message {
  position: fixed;
  top: 120px;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 24px;
  border-radius: 12px;
  z-index: 10000;
  font-weight: bold;
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
  animation: slideIn 0.3s ease, fadeOut 0.3s ease 2.7s;
  pointer-events: none;
  max-width: 90%;
  text-align: center;
}

.game-message.success {
  background: #4CAF50;
  color: white;
}

.game-message.error {
  background: #f44336;
  color: white;
}

.game-message.warning {
  background: #ff9800;
  color: white;
}

.game-message.info {
  background: #2196F3;
  color: white;
}

/* ====== ЗАГРУЗКИ ====== */
.shop-loading,
.leaders-loading,
.friends-loading {
  padding: 40px 20px;
  text-align: center;
  color: var(--text-muted);
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255,255,255,0.1);
  border-top-color: #f5c46b;
  border-radius: 50%;
  margin: 0 auto 16px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ====== ПРОГРЕСС БАР В ХЕДЕРЕ ====== */
.progress-wrap {
  position: relative;
  overflow: hidden;
}

.progress-inner {
  position: relative;
  overflow: hidden;
}

.progress-inner::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: var(--progress-width, 0%);
  height: 100%;
  background: linear-gradient(90deg, rgba(255,255,255,0.3), rgba(255,255,255,0.1));
  border-radius: inherit;
  transition: width 0.5s ease;
}

/* ====== ИСПРАВЛЕНИЯ ДЛЯ ИГРОВОГО ПОЛЯ ====== */
.hole {
  position: relative;
  transition: transform 0.2s ease;
}

.hole:active {
  transform: scale(0.95);
}


.hammerImg {
  position: absolute;
  left: 50%;
  top: 10%;
  transform: translateX(-50%);
  width: 90%;
  height: auto;
  z-index: 3;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

/* ====== АДАПТИВНОСТЬ ====== */
@media (max-width: 380px) {
  .modal-content {
    padding: 20px;
  }
  
  .welcome-title {
    font-size: 18px;
  }
  
  .levelup-level {
    font-size: 60px;
  }
  
  .loading-logo {
    width: 100%;
    height: auto;
  }
}

/* ====== ТЕМЫ TELEGRAM ====== */
[data-theme="light"] {
  --text-main: #000000;
  --text-muted: rgba(0,0,0,0.6);
  --glass-bg: rgba(255,255,255,0.9);
  --glass-border: rgba(0,0,0,0.1);
}

[data-theme="dark"] {
  --text-main: #ffffff;
  --text-muted: rgba(255,255,255,0.6);
  --glass-bg: rgba(255,255,255,0.08);
  --glass-border: rgba(255,255,255,0.18);
}


/* ====== ИСПРАВЛЕНИЯ ДЛЯ ПРОГРЕСС БАРА ====== */
.progress-wrap {
  position: relative;
  overflow: hidden;
}

.progress-inner {
  position: relative;
  overflow: hidden;
  padding: 8px 14px 8px 10px;
  border-radius: 22px;
  background:
  radial-gradient(
    60% 55% at 50% 18%,
    #f7dfa3 0%,
    #ecd08a 32%,
    #d7ad55 65%,
    #9e7a34 100%
  ),
  linear-gradient(
    180deg,
    #f1d58f 0%,
    #d7ad55 45%,
    #8f6a2a 100%
  );

  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.55),
    inset 0 -8px 16px rgba(0,0,0,0.18),
    0 8px 18px rgba(0,0,0,0.18);
  min-height: 44px;
}

.progress-inner:before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 20px;
  border: 1px solid rgba(90,60,10,0.22);
  pointer-events: none;
}

.progress-bar-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: linear-gradient(90deg, rgba(255, 160, 40, 0.3), rgba(255, 200, 80, 0.2));
  border-radius: 20px;
  z-index: 0;
  transition: width 0.5s ease;
}

.avatar-medal {
  position: relative;
  z-index: 1;
}

.progress-text {
  position: relative;
  z-index: 1;
}

/* ====== ЗАЩИТА ОТ АВТО-УДАРОВ ====== */
.hole {
  position: relative;
  transition: transform 0.2s ease;
  user-select: none;
  -webkit-user-select: none;
  touch-action: manipulation;
}

.hole:active {
  transform: scale(0.95);
}

/* Отключаем выделение текста во время игры */
#board {
  user-select: none;
  -webkit-user-select: none;
}

/* ====== АНИМАЦИИ СООБЩЕНИЙ ====== */
@keyframes messageSlideIn {
  to {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
  }
  from {
    transform: translateX(-50%) translateY(-20px);
    opacity: 0;
  }
}

@keyframes messageFadeOut {
  to { opacity: 0; }
  from { opacity: 1; }
}

/* ====== ИСПРАВЛЕНИЯ ДЛЯ ИГРОВОГО ПОЛЯ ====== */
.moleImg {
  position: absolute;
  left: 50%;
  bottom: -60%;
  transform: translateX(-50%);
  width: 80%;
  height: auto;
  z-index: 2;
  transition: bottom 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.5), opacity 0.3s ease;
  pointer-events: none;
}

.moleImg.up {
  bottom: 15%;
}

.hammerImg {
  position: absolute;
  left: 50%;
  top: 10%;
  transform: translateX(-50%);
  width: 90%;
  height: auto;
  z-index: 3;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

/* ====== КНОПКА ИГРАТЬ ====== */
#btnPlay {
  background: linear-gradient(135deg, #4da3ff, #a64aff);
  border: none;
  color: white;
  font-weight: bold;
  font-size: 16px;
}

#btnPlay:active {
  transform: translateY(2px);
}

/* ====== АДАПТИВНОСТЬ ====== */
@media (max-width: 380px) {
  .progress-inner {
    padding: 6px 12px 6px 8px;
    min-height: 40px;
  }
  
  .progress-text {
    font-size: 14px;
  }
}

@keyframes missShake {
    0%, 100% { transform: translateX(0) rotate(0deg); }
    25% { transform: translateX(-5px) rotate(-2deg); }
    50% { transform: translateX(5px) rotate(2deg); }
    75% { transform: translateX(-3px) rotate(-1deg); }
}




/* ====== ЭФФЕКТ ПРОМАХА ====== */
.miss-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.miss-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.miss-heart {
  width: 280px;
  height: 280px;
  margin-bottom: 30px;
  filter: drop-shadow(0 20px 40px rgba(255, 0, 0, 0.4));
  animation: missHeartBeat 1.2s ease-out;
}

@keyframes missHeartBeat {
  0% {
    transform: scale(0.3);
    opacity: 0;
    filter: drop-shadow(0 0 0 rgba(255, 0, 0, 0));
  }
  30% {
    transform: scale(1.2);
    opacity: 1;
    filter: drop-shadow(0 0 40px rgba(255, 0, 0, 0.6));
  }
  50% {
    transform: scale(0.95);
    filter: drop-shadow(0 0 30px rgba(255, 0, 0, 0.5));
  }
  70% {
    transform: scale(1.05);
    filter: drop-shadow(0 0 35px rgba(255, 0, 0, 0.55));
  }
  100% {
    transform: scale(1);
    opacity: 1;
    filter: drop-shadow(0 0 25px rgba(255, 0, 0, 0.4));
  }
}

.miss-message {
  font-size: 28px;
  font-weight: 900;
  color: #fff;
  text-align: center;
  text-shadow: 
    0 4px 8px rgba(255, 0, 0, 0.5),
    0 0 20px rgba(255, 0, 0, 0.6);
  margin-bottom: 20px;
  animation: missTextPulse 2s ease-in-out infinite;
}

@keyframes missTextPulse {
  0%, 100% { 
    opacity: 1;
    transform: scale(1);
  }
  50% { 
    opacity: 0.8;
    transform: scale(0.98);
  }
}

.miss-lives {
  font-size: 22px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.9);
  text-align: center;
  background: rgba(255, 0, 0, 0.2);
  padding: 12px 24px;
  border-radius: 16px;
  border: 2px solid rgba(255, 100, 100, 0.4);
  margin-bottom: 40px;
  backdrop-filter: blur(10px);
}

.miss-continue {
  padding: 16px 40px;
  font-size: 18px;
  font-weight: 900;
  background: linear-gradient(135deg, #ff416c, #ff4b2b);
  border: none;
  border-radius: 16px;
  color: white;
  cursor: pointer;
  box-shadow: 
    0 12px 30px rgba(255, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transition: all 0.2s ease;
}

.miss-continue:active {
  transform: translateY(2px);
  box-shadow: 
    0 8px 20px rgba(255, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

/* ====== ДОПОЛНИТЕЛЬНЫЕ ЭФФЕКТЫ ====== */
@keyframes heartShake {
    0%, 100% { transform: translateX(0) rotate(0deg); }
    25% { transform: translateX(-8px) rotate(-3deg); }
    75% { transform: translateX(8px) rotate(3deg); }
}

.miss-heart.shaking {
    animation: heartShake 0.4s ease 0.5s;
}

/* Затемнение экрана при эффектах */
.game-effect-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    z-index: 9998;
    pointer-events: none;
    transition: background 0.3s ease;
}

.game-effect-overlay.active {
    background: rgba(0, 0, 0, 0.4);
}


/* ====== ЭФФЕКТ РАЗБИТОГО СЕРДЦА (как с XP) ====== */
.heart-effect {
    position: fixed;
    pointer-events: none;
    z-index: 10000;
}

@keyframes heartFloat {
    0% {
        opacity: 0;
        transform: translateY(30px) rotate(var(--rot, 0deg)) scale(0.3);
        filter: drop-shadow(0 2px 4px rgba(255,0,0,0.3)) blur(8px);
    }
    20% {
        opacity: 1;
        transform: translateY(-20px) rotate(calc(var(--rot, 0deg) + 10deg)) scale(1.1);
        filter: drop-shadow(0 10px 20px rgba(255,0,0,0.8)) blur(0);
    }
    40% {
        transform: translateY(-40px) rotate(calc(var(--rot, 0deg) - 5deg)) scale(1);
    }
    60% {
        transform: translateY(-60px) rotate(calc(var(--rot, 0deg) + 3deg)) scale(0.95);
    }
    80% {
        transform: translateY(-80px) rotate(calc(var(--rot, 0deg) - 2deg)) scale(0.9);
    }
    100% {
        opacity: 0;
        transform: translateY(-100px) rotate(calc(var(--rot, 0deg) + 5deg)) scale(0.7);
        filter: drop-shadow(0 4px 8px rgba(255,0,0,0.4)) blur(4px);
    }
}

@keyframes heartBreak {
    0% {
        transform: scale(1) rotateY(0deg);
        filter: brightness(1);
    }
    25% {
        transform: scale(1.3) rotateY(90deg);
        filter: brightness(1.5) drop-shadow(0 0 30px rgba(255,0,0,0.8));
    }
    50% {
        transform: scale(1.1) rotateY(180deg);
        filter: brightness(1.3) drop-shadow(0 0 25px rgba(255,0,0,0.7));
    }
    75% {
        transform: scale(0.9) rotateY(270deg);
        filter: brightness(1.1) drop-shadow(0 0 20px rgba(255,0,0,0.6));
    }
    100% {
        transform: scale(1) rotateY(360deg);
        filter: brightness(1) drop-shadow(0 0 15px rgba(255,0,0,0.5));
    }
}

/* Красный цвет для эффекта разбитого сердца */
.heart-effect img {
    animation: heartBreak 1.5s ease-in-out infinite;
}

/* Также можно добавить эффект для промаха в общих стилях */
.hole.miss .moleImg {
    animation: missGlow 0.5s ease;
}

@keyframes missGlow {
    0%, 100% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.3) drop-shadow(0 0 15px rgba(255, 0, 0, 0.5));
    }
}

/* ====== ЭФФЕКТ БЛЕККАУТА ПРИ НУЛЕ ЖИЗНЕЙ (БЕЗ МОДАЛЬНОГО ОКНА) ====== */
body.no-lives .bg {
    filter: grayscale(95%) brightness(45%) contrast(120%);
    transition: filter 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

body.no-lives .gameCard {
    filter: grayscale(80%) brightness(60%);
    opacity: 0.9;
    transition: all 0.8s ease;
}

body.no-lives .navItem:not([data-go="home"]) {
    opacity: 0.4;
    pointer-events: none;
}

/* ЦЕНТРАЛЬНАЯ КНОПКА ОСТАЁТСЯ ЦВЕТНОЙ И АКТИВНОЙ */
body.no-lives .centerHead {
    /* Никаких изменений - остаётся цветной */
    animation: none; /* Убираем анимацию грусти */
}

body.no-lives .centerRing {
    /* Делаем кольцо немного тускнее, но не серым */
    box-shadow: 
        0 22px 64px rgba(0,0,0,.50), /* Меньше тень */
        0 0 20px rgba(255, 120, 0, 0.1), /* Слабее свечение */
        inset 0 1px 0 rgba(255,255,255,0.45), /* Более тусклая внутренняя подсветка */
        inset 0 -4px 8px rgba(0,0,0,0.25); /* Сильнее внутренняя тень */
}

body.no-lives .stat-card {
    filter: grayscale(70%) brightness(80%);
}

body.no-lives .stat-card:nth-child(1) { /* Жизни */
    animation: lowHealthPulse 3s ease-in-out infinite;
    border-color: rgba(255, 50, 50, 0.5); /* Красная граница */
}

/* Анимация пульсации для карточки жизней */
@keyframes lowHealthPulse {
    0%, 100% { 
        filter: grayscale(70%) brightness(80%);
        transform: scale(1);
        border-color: rgba(255, 50, 50, 0.5);
    }
    50% { 
        filter: grayscale(50%) brightness(100%);
        transform: scale(1.02);
        box-shadow: 
            0 12px 35px rgba(255, 0, 0, 0.3),
            inset 0 1px 0 rgba(255,255,255,0.08);
        border-color: rgba(255, 100, 100, 0.7);
    }
}

/* Затемнение лунок */
body.no-lives .hole {
    filter: grayscale(100%) brightness(35%);
    pointer-events: none;
    opacity: 0.7;
    display:none;
}

body.no-lives .holeImg {
    filter: brightness(0.4);
}

/* Эффект блокировки для лунок */
body.no-lives .hole::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 22px;
    z-index: 10;
    pointer-events: none;
}

/* Сообщение о восстановлении в HUD */
.no-lives-hud-message {
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    text-align: center;
    color: #edce83;
    font-size: 13px;
    font-weight: 700;
    padding: 8px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 12px;
    margin: 0 16px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 100, 100, 0.3);
    animation: noLivesHudPulse 2s ease-in-out infinite;
    z-index: 100;
}

@keyframes noLivesHudPulse {
    0%, 100% { 
        opacity: 0.9;
        transform: translateY(0);
    }
    50% { 
        opacity: 1;
        transform: translateY(-2px);
        box-shadow: 0 8px 25px rgba(255, 0, 0, 0.2);
    }
}

/* Эффект для кнопки Играть */
body.no-lives #btnPlay {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    box-shadow: 0 16px 44px rgba(255, 0, 0, 0.25);
    position: relative;
}

body.no-lives #btnPlay::after {
    content: 'Жизни восстановятся через:';
    position: absolute;
    top: -30px;
    left: 0;
    right: 0;
    color: #ffcc00;
    font-size: 12px;
    font-weight: 700;
    opacity: 0.9;
}

/* Таймер в кнопке Играть */
#btnPlay .regen-timer {
    display: none;
    font-size: 11px;
    color: white;
    margin-top: 4px;
    font-weight: 600;
}

body.no-lives #btnPlay .regen-timer {
    display: block;
}

/* Блокировка кликов на поле */
body.no-lives #board {
    pointer-events: none;
}

/* Эффект для кнопки звука */
body.no-lives #btnSound {
    opacity: 0.6;
    filter: grayscale(50%);
}

/* ====== СТРАНИЦА ЗАДАНИЙ - КАК PROMO КАРТОЧКА ====== */

/* Контейнер для всех заданий */
.tasks-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* КАРТОЧКА ЗАДАНИЯ - ГОРИЗОНТАЛЬНОЕ РАСПОЛОЖЕНИЕ */
.task-card {
  display: flex;
  align-items: center;
  min-height: 112px;
  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.06));
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(14px);
  padding: 16px !important;
  border-radius: 16px;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.10);
  transition: all 0.3s ease;
  gap: 16px; /* Отступ между изображением и контентом */
}

/* Полученные задания - серые */
.task-card.claimed {
  background: linear-gradient(180deg, rgba(128,128,128,.10), rgba(128,128,128,.06));
  border-color: rgba(128,128,128,.14);
  filter: grayscale(0.7);
  opacity: 0.7;
}

/* Задания для получения - золотые */
.task-card.can-claim {
  background: radial-gradient(
    60% 55% at 50% 18%,
    #f7dfa3 0%,
    #ecd08a 32%,
    #d7ad55 65%,
    #9e7a34 100%
  ),
  linear-gradient(
    180deg,
    #f1d58f 0%,
    #d7ad55 45%,
    #8f6a2a 100%
  );
  border: 1px solid rgba(90, 60, 10, 0.22);
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,.55),
    inset 0 -8px 16px rgba(0,0,0,.18),
    0 8px 18px rgba(0,0,0,.18);
}

.task-card.can-claim::before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 16px;
  border: 1px solid rgba(90, 60, 10, 0.22);
  pointer-events: none;
  z-index: -1;
}

/* ИЗОБРАЖЕНИЕ СЛЕВА - фиксированная ширина */
.task-image {
  flex: 0 0 auto;
  width: 140px;
  height: 126px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
}

.task-image img {
      width: 160px;
    height: auto;
    display: block;
    filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.35));
    user-select: none;
    -webkit-user-drag: none;
    border-radius: 12px;
    margin-right: 15px;
}

/* КОНТЕНТ СПРАВА - занимает оставшееся пространство */
.task-content {
  flex: 1;
  min-width: 0; /* Важно для корректного обрезания текста */
}

.task-name {
  margin: 0 0 8px;
  font-weight: 800;
  letter-spacing: 0.6px;
  line-height: 1.05;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.95);
}

.task-card.can-claim .task-name {
  color: rgba(18, 14, 8, 0.92);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.task-card.claimed .task-name {
  color: rgba(255, 255, 255, 0.7);
}

.task-desc {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.55);
}

.task-card.can-claim .task-desc {
  color: rgba(18, 14, 8, 0.75);
}

.task-card.claimed .task-desc {
  color: rgba(255, 255, 255, 0.4);
}

/* ПРОГРЕСС БАР */
.task-progress {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.progress-bar {
  flex: 1;
  height: 6px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.5s ease;
}

.task-card.in-progress .progress-fill {
  background: linear-gradient(90deg, #4da3ff, #a64aff);
}

.task-card.can-claim .progress-fill {
  background: rgba(18, 14, 8, 0.3);
}

.task-card.claimed .progress-fill {
  background: rgba(128, 128, 128, 0.3);
}

.progress-text {
  font-size: 12px;
  font-weight: 600;
  min-width: 40px;
  text-align: right;
}

.task-card.can-claim .progress-text {
  color: rgba(18, 14, 8, 0.85);
  font-weight: 700;
}

.task-card.claimed .progress-text {
  color: rgba(255, 255, 255, 0.4);
}

/* НАГРАДА */
.task-reward {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.reward-coins {
  font-size: 14px;
  font-weight: 700;
  color: #f6c21f;
  display: flex;
  align-items: center;
  gap: 4px;
}

.reward-coins::before {
  content: '';
  display: inline-block;
  width: 14px;
  height: 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0%25' stop-color='%23f7dfa3'/%3E%3Cstop offset='48%25' stop-color='%23e9c979'/%3E%3Cstop offset='100%25' stop-color='%23d7ad55'/%3E%3C/linearGradient%3E%3C/defs%3E%3Ccircle cx='256' cy='256' r='220' fill='%23fff2c9'/%3E%3Ccircle cx='256' cy='256' r='210' fill='url(%23g)'/%3E%3Ccircle cx='256' cy='256' r='170' fill='%23fff6d4'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  vertical-align: middle;
  flex-shrink: 0;
}

/* Для золотых заданий которые можно получить */
.task-card.can-claim .reward-coins::before {
  filter: brightness(0.8) saturate(1.2);
}

/* Для уже полученных серых заданий */
.task-card.claimed .reward-coins::before {
  filter: grayscale(1) opacity(0.6);
}

.reward-boost {
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 10px;
  background: rgba(77, 163, 255, 0.2);
  border: 1px solid rgba(77, 163, 255, 0.3);
  color: rgba(255, 255, 255, 0.8);
}

.task-card.can-claim .reward-boost {
  background: rgba(18, 14, 8, 0.15);
  border-color: rgba(90, 60, 10, 0.3);
  color: rgba(18, 14, 8, 0.85);
}

.task-card.claimed .reward-boost {
  background: rgba(128, 128, 128, 0.2);
  border-color: rgba(128, 128, 128, 0.3);
  color: rgba(255, 255, 255, 0.5);
}

/* СТАТУС ЗАДАНИЯ */
.task-status {
  margin-top: 8px;
}

.task-in-progress {
  display: inline-block;
  padding: 6px 12px;
  background: rgba(77, 163, 255, 0.15);
  border: 1px solid rgba(77, 163, 255, 0.3);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 700;
  font-size: 12px;
  text-align: center;
}

.task-completed {
  display: inline-block;
  padding: 6px 12px;
  background: rgba(128, 128, 128, 0.15);
  border: 1px solid rgba(128, 128, 128, 0.3);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.6);
  font-weight: 700;
  font-size: 12px;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ТЕПЕРЬ ОВЕРЛЕЙ С КНОПКОЙ "ЗАБРАТЬ НАГРАДУ" */
.task-claim-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2;
  border-radius: 18px;
  animation: fadeIn 0.3s ease;
}

.task-card.can-claim .task-claim-overlay {
  display: flex;
}

.task-claim-btn {
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 800;
  background: radial-gradient(
    60% 55% at 50% 18%,
    #f7dfa3 0%,
    #ecd08a 32%,
    #d7ad55 65%,
    #9e7a34 100%
  ),
  linear-gradient(
    180deg,
    #f1d58f 0%,
    #d7ad55 45%,
    #8f6a2a 100%
  );
  color: rgba(18, 14, 8, 0.92);
  border: none;
  border-radius: 14px;
  cursor: pointer;
  box-shadow: 
    0 10px 25px rgba(0,0,0,.45),
    inset 0 1px 0 rgba(255,255,255,.55),
    inset 0 -4px 8px rgba(0,0,0,.2);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  min-width: 160px;
  text-align: center;
  position: relative;
  overflow: hidden;
  z-index: 1;
  animation: goldPulse 2s infinite ease-in-out;
}

.task-claim-btn::before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 12px;
  border: 1px solid rgba(90,60,10,0.22);
  pointer-events: none;
  z-index: -1;
}

.task-claim-btn:active {
  transform: translateY(2px);
  box-shadow: 
    0 6px 18px rgba(0,0,0,.35),
    inset 0 1px 0 rgba(255,255,255,.45),
    inset 0 -4px 8px rgba(0,0,0,.25);
}

/* БЕЙДЖ "ПОЛУЧЕНО" */
.claimed-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.9), rgba(76, 175, 80, 0.7));
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 8px rgba(76, 175, 80, 0.2);
  z-index: 2;
}

.task-card.claimed .claimed-badge {
  display: block;
}

/* АНИМАЦИИ */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes goldPulse {
  0%, 100% {
    box-shadow: 
      0 10px 25px rgba(0,0,0,.45),
      inset 0 1px 0 rgba(255,255,255,.55),
      inset 0 -4px 8px rgba(0,0,0,.2),
      0 0 0 rgba(247, 223, 163, 0);
  }
  50% {
    box-shadow: 
      0 14px 30px rgba(0,0,0,.55),
      inset 0 1px 0 rgba(255,255,255,.65),
      inset 0 -4px 8px rgba(0,0,0,.25),
      0 0 20px rgba(247, 223, 163, 0.4);
  }
}

@keyframes taskSlideIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.task-card {
  animation: taskSlideIn 0.4s ease backwards;
}

.task-card:nth-child(1) { animation-delay: 0.1s; }
.task-card:nth-child(2) { animation-delay: 0.2s; }
.task-card:nth-child(3) { animation-delay: 0.3s; }
.task-card:nth-child(4) { animation-delay: 0.4s; }

/* АДАПТИВНОСТЬ - теперь без колонок на мобильных! */
@media (max-width: 600px) {
  .task-card {
    gap: 12px; /* Уменьшаем отступ на мобильных */
    min-height: 100px;
    padding: 12px !important;
  }
  
  .task-image {
    flex: 0 0 120px; /* Уменьшаем изображение на мобильных */
    height: 120px;
  }
  
  .task-name {
    font-size: 15px;
  }
  
  .task-desc {
    font-size: 12px;
  }
  
  .task-claim-btn {
    padding: 12px 20px;
    font-size: 14px;
    min-width: 140px;
  }
  
  .task-in-progress,
  .task-completed {
    padding: 5px 10px;
    font-size: 11px;
  }
  
  .claimed-badge {
    top: 8px;
    right: 8px;
    font-size: 10px;
    padding: 3px 8px;
  }
  
  /* Для очень маленьких экранов можно сделать перенос */
  @media (max-width: 360px) {
    .task-card {
      flex-wrap: wrap;
    }
    
    .task-image {
      flex: 0 0 50px;
      height: 50px;
      margin-bottom: 8px;
    }
    
    .task-content {
      flex: 1 0 100%; /* На очень маленьких экранах контент под изображением */
    }
  }
}

/* СОСТОЯНИЯ ЗАГРУЗКИ И ОШИБОК */
.tasks-loading {
  padding: 60px 20px;
  text-align: center;
  color: rgba(255,255,255,.6);
}

.no-tasks {
  padding: 60px 20px;
  text-align: center;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 2px dashed rgba(255,255,255,.1);
}

.no-tasks-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.no-tasks-title {
  font-size: 18px;
  font-weight: 700;
  color: rgba(255,255,255,.8);
  margin-bottom: 8px;
}

.no-tasks-desc {
  font-size: 14px;
  color: rgba(255,255,255,.6);
  max-width: 300px;
  margin: 0 auto;
}

.tasks-error {
  padding: 40px 20px;
  text-align: center;
}

.error-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 16px;
  border-radius: 12px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.14);
  display: grid;
  place-items: center;
  font-size: 22px;
}

.error-desc {
  font-size: 13px;
  color: rgba(255,255,255,.6);
  margin: 8px 0 16px;
}

/* Улучшаем навигацию для страницы бонусов */
[data-page="bonuses"] .bottomNav {
    background: rgba(20, 23, 35, 0.85);
    backdrop-filter: blur(20px);
}

/* Стили для иконок в навигации */
.navItem[data-go="bonuses"].active svg,
.navItem[data-go="skins"].active svg,
.navItem[data-go="leaders"].active svg,
.navItem[data-go="friends"].active svg {
    fill: var(--accent-gold);
    stroke: var(--accent-gold);
    filter: drop-shadow(0 2px 4px rgba(245, 196, 107, 0.3));
}

.navItem[data-go="bonuses"].active span,
.navItem[data-go="skins"].active span,
.navItem[data-go="leaders"].active span,
.navItem[data-go="friends"].active span {
    color: var(--accent-gold);
}


/* ====== ПЛАВАЮЩАЯ КНОПКА PVP НА ГЛАВНОЙ СТРАНИЦЕ ====== */
.pvp-float-btn {
    position: fixed;
    right: 20px;
    bottom: 70px;
    width: 140px;
    height: 70px;
    cursor: pointer;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.pvp-float-btn:active {
    box-shadow: 
        0 5px 20px rgba(255, 0, 0, 0.3),
        0 0 15px rgba(255, 100, 100, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}


.pvp-btn-icon {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
    position: relative;
    z-index: 2;
}

/* Текстовый лейбл */
.pvp-float-btn::after {
    content: 'PvP';
    position: absolute;
    top: -25px;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 12px;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 
        0 2px 4px rgba(255, 0, 0, 0.5),
        0 0 8px rgba(255, 100, 100, 0.5);
    opacity: 0;
    transform: translateY(5px);
    transition: all 0.3s ease;
}

.pvp-float-btn:hover::after {
    opacity: 1;
    transform: translateY(0);
}

/* Адаптивность для маленьких экранов */
@media (max-width: 380px) {
    .pvp-float-btn {
        right: 15px;
        bottom: 90px;
        width: 60px;
        height: 60px;
    }
    
    .pvp-float-btn::after {
        font-size: 11px;
        top: -22px;
    }
}

/* Для очень маленьких экранов */
@media (max-width: 320px) {
    .pvp-float-btn {
        right: 10px;
        bottom: 85px;
        width: 55px;
        height: 55px;
    }
}

/* Если кнопка перекрывает навигацию на очень маленьких экранах */
@media (max-height: 700px) {
    .pvp-float-btn {
        bottom: 80px;
    }
}

/* Эффект когда активна страница PvP */
[data-page="pvp"] .pvp-float-btn {
    background: linear-gradient(145deg, rgba(100, 200, 255, 0.9), rgba(30, 150, 255, 0.9));
    box-shadow: 
        0 10px 30px rgba(30, 150, 255, 0.4),
        0 0 20px rgba(100, 200, 255, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

[data-page="pvp"] .pvp-btn-pulse {
    background: radial-gradient(circle at center, 
        rgba(100, 200, 255, 0.4) 0%,
        rgba(100, 200, 255, 0.2) 40%,
        transparent 70%);
}

[data-page="pvp"] .pvp-float-btn::after {
    color: rgba(100, 200, 255, 0.9);
    text-shadow: 
        0 2px 4px rgba(30, 150, 255, 0.5),
        0 0 8px rgba(100, 200, 255, 0.5);
}


/* ====== ТЕКСТОВЫЕ ЭФФЕКТЫ ДЛЯ XP И ПОТЕРИ ЖИЗНЕЙ ====== */
.effect-text {
    position: fixed;
    pointer-events: none;
    z-index: 10000;
    font-weight: 900;
    font-size: 22px;
    text-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.5),
        0 4px 8px rgba(0, 0, 0, 0.3);
    animation: textFloatUp 1.5s ease-out forwards;
    opacity: 0;
    white-space: nowrap;
}

/* Эффект для XP */
.xp-effect-text {
    color: #FFD700; /* золотой */
    text-shadow: 
        0 2px 4px rgba(255, 215, 0, 0.4),
        0 0 10px rgba(255, 215, 0, 0.3),
        0 4px 8px rgba(0, 0, 0, 0.5);
    background: linear-gradient(135deg, 
        rgba(255, 215, 0, 0.15) 0%, 
        rgba(255, 215, 0, 0.05) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Эффект для потери жизней */
.life-effect-text {
    color: #FF4444; /* красный */
    text-shadow: 
        0 2px 4px rgba(255, 68, 68, 0.4),
        0 0 10px rgba(255, 68, 68, 0.3),
        0 4px 8px rgba(0, 0, 0, 0.5);
    background: linear-gradient(135deg, 
        rgba(255, 68, 68, 0.15) 0%, 
        rgba(255, 68, 68, 0.05) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Анимация всплывания текста */
@keyframes textFloatUp {
    0% {
        opacity: 0;
        transform: translateY(30px) scale(0.8) rotate(var(--rotation, 0deg));
        filter: blur(8px);
    }
    20% {
        opacity: 1;
        transform: translateY(-10px) scale(1.1) rotate(var(--rotation, 0deg));
        filter: blur(0);
    }
    40% {
        transform: translateY(-30px) scale(1.05) rotate(calc(var(--rotation, 0deg) * 1.2));
    }
    60% {
        transform: translateY(-50px) scale(1) rotate(calc(var(--rotation, 0deg) * 1.1));
    }
    80% {
        transform: translateY(-70px) scale(0.95) rotate(calc(var(--rotation, 0deg) * 1.05));
        opacity: 0.8;
    }
    100% {
        opacity: 0;
        transform: translateY(-90px) scale(0.9) rotate(calc(var(--rotation, 0deg) * 1.1));
        filter: blur(4px);
    }
}

/* Анимация для рандомных наклонов */
@keyframes textTiltLeft {
    0%, 100% { transform: translateY(0) rotate(-5deg); }
    50% { transform: translateY(-10px) rotate(-8deg); }
}

@keyframes textTiltRight {
    0%, 100% { transform: translateY(0) rotate(5deg); }
    50% { transform: translateY(-10px) rotate(8deg); }
}

/* Фоновый контейнер для текста */
.text-effect-container {
    position: relative;
    padding: 8px 16px;
    border-radius: 12px;
    display: inline-block;
    backdrop-filter: blur(4px);
}

.xp-effect-text .text-effect-container {
    background: linear-gradient(135deg, 
        rgba(255, 215, 0, 0.1) 0%, 
        rgba(255, 200, 0, 0.05) 100%);
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.life-effect-text .text-effect-container {
    background: linear-gradient(135deg, 
        rgba(255, 68, 68, 0.1) 0%, 
        rgba(255, 50, 50, 0.05) 100%);
    border: 1px solid rgba(255, 68, 68, 0.2);
}

/* Иконки рядом с текстом */
.text-effect-container::before {
    margin-right: 8px;
    font-weight: 900;
}

.xp-effect-text .text-effect-container::before {
    content: '↑';
    color: #FFD700;
}

.life-effect-text .text-effect-container::before {
    content: '↓';
    color: #FF4444;
}

/* Дополнительная анимация для XP */
@keyframes xpShine {
    0% {
        background-position: -100px;
    }
    40%, 100% {
        background-position: 200px;
    }
}

.xp-effect-text {
    position: relative;
    overflow: hidden;
}

.xp-effect-text::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.2) 50%, 
        transparent 100%);
    background-size: 200px 100%;
    animation: xpShine 1s ease-out;
    pointer-events: none;
}

/* Дополнительная анимация для потери жизней */
@keyframes lifePulse {
    0%, 100% { 
        transform: scale(1);
        opacity: 0.9;
    }
    50% { 
        transform: scale(1.05);
        opacity: 1;
    }
}

.life-effect-text .text-effect-container {
    animation: lifePulse 0.5s ease 2;
}

/* Эффект рассеивания для текста */
@keyframes textDissolve {
    0% {
        opacity: 1;
        filter: blur(0);
    }
    100% {
        opacity: 0;
        filter: blur(20px);
    }
}

.effect-text.dissolving {
    animation: textDissolve 0.8s ease-out forwards;
}


/* ====== МАГАЗИН СКИНОВ (ОБНОВЛЕННЫЕ СТИЛИ) ====== */
.shop-header {
  padding: 16px 16px 0;
  margin-bottom: 16px;
  text-align: center;
}

.shop-title {
  font-size: 24px;
  font-weight: 900;
  color: rgba(255,255,255,.92);
  margin-bottom: 8px;
}

.shop-subtitle {
  color: rgba(255,255,255,.6);
  font-size: 14px;
  margin-bottom: 4px;
}

/* ====== БЛОК "ТВОЙ АКТИВНЫЙ СКИН" В СТИЛЕ ПРОМО-БЛОКА ====== */
.active-skin-container {
  margin-bottom: 20px;
  animation: fadeIn 0.4s ease;
}

.active-skin-promo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 112px;
  background:
  radial-gradient(
    60% 55% at 50% 18%,
    #cfe6d8 0%,
    #9fcbb1 35%,
    #5f9f80 65%,
    #2f5f4a 100%
  ),
  linear-gradient(
    180deg,
    #cfe6d8 0%,
    #7fbfa0 45%,
    #2f5f4a 100%
  );

  backdrop-filter: blur(10px);
  padding: 16px !important;
  border-radius: 18px;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.12);

box-shadow:
  0 20px 60px rgba(0,0,0,.55),
  inset 0 1px 0 rgba(255,255,255,.18),
  inset 0 -16px 28px rgba(0,0,0,.35);

}

.active-skin-promo::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle at 30% 30%,
    rgba(77, 163, 255, 0.05) 0%,
    rgba(166, 74, 255, 0.03) 25%,
    transparent 50%
  );
  pointer-events: none;
}

.active-skin-left {
  flex: 0 0 auto;
  width: 120px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
}

.active-skin-ico {
  width: 240px;
  height: auto;
  display: block;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.35));
  user-select: none;
  -webkit-user-drag: none;
  border-radius: 12px;
  margin-left: 15px;
}

.active-skin-right {
  flex: 1 1 auto;
  min-width: 0;
  position: relative;
  z-index: 1;
  padding-left: 10px;
}

.active-skin-title {
  margin: 0 0 10px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  line-height: 1.05;
  font-size: 18px;
  color: #0f1116;
}

.active-skin-accent {
  color: #e0bd6e;
  background: radial-gradient(
    60% 55% at 50% 18%,
    #2b3046 0%,
    #1a1f33 40%,
    #0c0f1b 75%,
    #090b14 100%
  ),
  linear-gradient(
    180deg,
    #1a1f33 0%,
    #0b0e19 100%
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.active-skin-desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.55);
  max-width: 220px;
}

/* Бейдж "АКТИВЕН" */
.active-skin-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.9), rgba(76, 175, 80, 0.7));
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 8px rgba(76, 175, 80, 0.2);
  z-index: 2;
}

/* Плейсхолдер в том же стиле */
.active-skin-placeholder {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 112px;
  background:
    linear-gradient(
      180deg,
      #1a1c22 0%,
      #0f1116 100%
    );
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 16px !important;
  border-radius: 18px;
}

.active-skin-placeholder .active-skin-left {
  flex: 0 0 auto;
  width: 120px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-icon {
  font-size: 42px;
  opacity: 0.5;
}

.placeholder-content {
  flex: 1;
  padding-left: 10px;
}

.placeholder-title {
  font-size: 16px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 6px;
}

.placeholder-text {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
}

/* Анимация появления */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Адаптивность */
@media (max-width: 380px) {
  .active-skin-promo,
  .active-skin-placeholder {
    flex-direction: column;
    text-align: center;
    gap: 12px;
    min-height: auto;
    padding: 14px !important;
  }
  
  .active-skin-left {
    width: 100%;
    height: 80px;
  }
  
  .active-skin-ico {
    width: 140px;
    margin-left: 0;
  }
  
  .active-skin-right,
  .placeholder-content {
    padding-left: 0;
    text-align: center;
  }
  
  .active-skin-desc {
    max-width: 100%;
  }
  
  .active-skin-badge {
    top: 8px;
    right: 8px;
    font-size: 10px;
    padding: 3px 8px;
  }
}

/* Эффект при клике */
.active-skin-promo:active {
  transform: scale(0.98);
  transition: transform 0.1s ease;
}

.skin-preview {
  width: 80px;
  height: 80px;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(0,0,0,.2);
  display: grid;
  place-items: center;
}

.skin-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.skin-info {
  flex: 1;
}

.skin-name {
  font-size: 16px;
  font-weight: 600;
  color: rgba(255,255,255,.9);
  margin-bottom: 4px;
}

.skin-desc {
  font-size: 13px;
  color: rgba(255,255,255,.6);
}

.skin-badge.active {
  padding: 6px 12px;
  background: linear-gradient(180deg, var(--accent-red), var(--accent-red)90%);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid rgba(255,255,255,.16);
  box-shadow: 0 10px 18px rgba(211,66,69,.22);
}

/* Сетка скинов */
.skins-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.skin-item {
  border-radius: 16px;
  background: #4f5561;
  backdrop-filter: blur(14px);
  padding: 16px;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
}

.skin-item.owned {
  background: #2f5f4a;
  border-color: rgba(76,175,80,.3);
}

.skin-item.equipped {
  background: #111420;
  border-color: rgba(77,163,255,.3);
  transform: translateY(-2px);
}

.skin-image {
  width: 100%;
  height: 120px;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(0,0,0,.3);
  margin-bottom: 12px;
  display: grid;
  place-items: center;
  position: relative;
}

.skin-image img {
  width: 80%;
  height: 80%;
  object-fit: contain;
}

.owned-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 4px 8px;
  background: linear-gradient(180deg, #4CAF50, #45a049);
  border-radius: 10px;
  font-size: 10px;
  font-weight: 700;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid rgba(255,255,255,.2);
}

.skin-details {
  flex: 1;
  margin-bottom: 12px;
}

.skin-name {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,.9);
  margin-bottom: 4px;
  text-align: center;
}

.skin-desc {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  text-align: center;
  margin-bottom: 8px;
  line-height: 1.3;
}

.skin-price {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-gold);
  text-align: center;
}

.skin-price.not-enough {
  color: rgba(255,255,255,.4);
}

.skin-actions {
  display: flex;
  justify-content: center;
}

.skin-actions .btn {
  padding: 8px 16px;
  font-size: 13px;
  height: auto;
  min-width: 100px;
  border-radius: 10px;
  background: linear-gradient(180deg, var(--accent-red), var(--accent-red)90%);
  color: white;
  border: 1px solid rgba(255,255,255,.16);
  font-weight: 600;
  box-shadow: 0 10px 18px rgba(211,66,69,.22);
}

.skin-actions .equip-btn {
  background: linear-gradient(180deg, #4CAF50, #45a049);
  box-shadow: 0 10px 18px rgba(76,175,80,.22);
}

.skin-actions .buy-btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background: linear-gradient(180deg, rgba(211,66,69,.5), rgba(211,66,69,.4));
}

/* Купленные скины */
.owned-skins {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.owned-skin-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.1);
}

.owned-skin-item.equipped {
  background: linear-gradient(180deg, rgba(77,163,255,.12), rgba(77,163,255,.06));
  border-color: rgba(77,163,255,.25);
}

.owned-skin-image {
  width: 50px;
  height: 50px;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(0,0,0,.2);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.owned-skin-image img {
  width: 80%;
  height: 80%;
  object-fit: contain;
}

.owned-skin-info {
  flex: 1;
}

.owned-skin-name {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,.9);
  margin-bottom: 4px;
}

.owned-skin-price {
  font-size: 12px;
  color: var(--accent-gold);
  font-weight: 600;
}

.owned-skin-item .btn {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: 10px;
  background: linear-gradient(180deg, #4CAF50, #45a049);
  color: white;
  border: 1px solid rgba(255,255,255,.16);
  font-weight: 600;
  box-shadow: 0 8px 16px rgba(76,175,80,.22);
}

/* Статистика */
.skins-stats {
  display: flex;
  gap: 20px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,.1);
}

.skins-stats .stat-item {
  flex: 1;
  text-align: center;
  padding: 12px;
  border-radius: 12px;
  background: #111420;
}

.skins-stats .stat-label {
  display: block;
  font-size: 12px;
  color: rgba(255,255,255,.6);
  margin-bottom: 4px;
}

.skins-stats .stat-value {
  display: block;
  font-size: 18px;
  font-weight: 700;
  color: var(--accent-gold);
}

/* Состояния */
.empty-owned {
  padding: 40px 20px;
  text-align: center;
}

.empty-owned .empty-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 12px;
  border-radius: 12px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.14);
  display: grid;
  place-items: center;
}

.empty-owned .empty-icon svg {
  width: 22px;
  height: 22px;
  fill: rgba(255,255,255,.72);
}

.empty-owned .empty-title {
  font-size: 16px;
  font-weight: 600;
  color: rgba(255,255,255,.8);
  margin-bottom: 8px;
}

.empty-owned .empty-desc {
  font-size: 13px;
  color: rgba(255,255,255,.6);
}

.loading-skins {
  grid-column: 1 / -1;
  padding: 40px;
  text-align: center;
  color: rgba(255,255,255,.6);
}

.loading-skins .loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255,255,255,.1);
  border-top-color: var(--accent-gold);
  border-radius: 50%;
  margin: 0 auto 16px;
  animation: spin 1s linear infinite;
}

.no-skins {
  grid-column: 1 / -1;
  padding: 40px;
  text-align: center;
}

.no-skins .no-skins-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 12px;
  border-radius: 12px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.14);
  display: grid;
  place-items: center;
}

.no-skins .no-skins-icon svg {
  width: 22px;
  height: 22px;
  fill: rgba(255,255,255,.72);
}

/* Анимации для карточек */
@keyframes cardSlideIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.skin-item {
  animation: cardSlideIn 0.4s ease backwards;
}

/* Адаптивность */
@media (max-width: 600px) {
  .skins-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 400px) {
  .skins-grid {
    grid-template-columns: 1fr;
  }
  
  .skins-stats {
    flex-direction: column;
    gap: 10px;
  }
  
  .active-skin-card {
    flex-direction: column;
    text-align: center;
  }
  
  .owned-skin-item {
    flex-direction: column;
    text-align: center;
  }
  
  .owned-skin-item .btn {
    width: 100%;
    margin-top: 10px;
  }
}

/* Эффекты при нажатии */
.skin-item:active,
.owned-skin-item:active,
.active-skin-card:active {
  transform: scale(0.98);
  transition: transform 0.1s ease;
}

/* Улучшенный чекбокс для купленных скинов */
.skin-checkmark {
  position: absolute;
  top: 8px;
  left: 8px;
  width: 20px;
  height: 20px;
  background: linear-gradient(180deg, #4CAF50, #45a049);
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 2px solid white;
  box-shadow: 0 2px 8px rgba(0,0,0,.3);
}

.skin-checkmark:after {
  content: "";
  width: 6px;
  height: 10px;
  border-right: 2px solid white;
  border-bottom: 2px solid white;
  transform: rotate(45deg) translate(-1px, -1px);
}

/* Исправляем контейнеры с контентом */
.card {
  margin-bottom: 20px;
  overflow: visible !important; /* Разрешаем выход содержимого за пределы */
}

/* Увеличиваем высоту списков */
.leaders-list-container,
.friends-list-container,
.skins-grid,
.tasks-container {
  max-height: auto !important;
  overflow-y: auto !important;
  padding-right: 5px; /* Для скроллбара */
}

/* ====== ДОПОЛНИТЕЛЬНЫЕ СТИЛИ ДЛЯ СТРАНИЦЫ ДРУЗЕЙ ====== */

/* Реферальная ссылка */
.ref-link-display {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 200px;
}

.ref-link-text {
  font-size: 12px;
  color: rgba(255,255,255,.7);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 150px;
  background: rgba(0,0,0,.2);
  padding: 4px 8px;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,.1);
}

.ref-copy-btn {
  padding: 6px 12px;
  font-size: 11px;
  white-space: nowrap;
}

.ref-code-value {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-gold);
  padding: 6px 12px;
  background: rgba(255,255,255,.05);
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,.1);
}

/* Статистика в виде сетки */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.stats-item {
  aspect-ratio: 1;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8px;
  text-align: center;
}

.stats-item .day-number {
  font-size: 18px;
  font-weight: 800;
  color: var(--accent-gold);
  margin-bottom: 6px;
}

.stats-item .day-reward {
  font-size: 10px;
  color: rgba(255,255,255,.6);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Список друзей */
.friends-list {
  min-height: 200px;
}

.friends-empty {
  padding: 40px 20px;
  text-align: center;
  background: rgba(255,255,255,.03);
  border: 2px dashed rgba(255,255,255,.1);
  border-radius: 16px;
  margin: 20px 0;
}

.friends-empty .empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.friends-empty .empty-title {
  font-size: 16px;
  font-weight: 600;
  color: rgba(255,255,255,.8);
  margin-bottom: 8px;
}

.friends-empty .empty-desc {
  font-size: 13px;
  color: rgba(255,255,255,.6);
  max-width: 300px;
  margin: 0 auto;
}

/* Карточки друзей */
.friend-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  margin-bottom: 10px;
  backdrop-filter: blur(10px);
}

.friend-avatar {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  overflow: hidden;
  flex-shrink: 0;
  position: relative;
  background: linear-gradient(135deg, var(--accent), var(--violet));
}

.friend-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: relative;
  z-index: 1;
}

.friend-info {
  flex: 1;
  min-width: 0;
}

.friend-name {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,.9);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.friend-status {
  font-size: 11px;
  color: rgba(255,255,255,.6);
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
}

.status-dot.online { background: #4CAF50; }
.status-dot.offline { background: #f44336; }
.status-dot.played { background: #2196F3; }

.friend-score {
  font-size: 12px;
  font-weight: 700;
  color: var(--accent-gold);
  text-align: right;
  flex-shrink: 0;
}

/* Иконки в стиле остальных страниц */
.task-icon.success {
  background: rgba(76, 175, 80, 0.1);
  border-color: rgba(76, 175, 80, 0.3);
}

.task-icon.success svg {
  fill: #4CAF50;
}

.task-icon.bonus {
  background: rgba(77, 163, 255, 0.1);
  border-color: rgba(77, 163, 255, 0.3);
}

.task-icon.bonus svg {
  fill: #4da3ff;
}

/* Адаптивность */
@media (max-width: 380px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .ref-link-display {
    flex-direction: column;
    gap: 8px;
    min-width: auto;
  }
  
  .ref-link-text {
    max-width: 100%;
    text-align: center;
  }
}

/* Анимации */
.friend-item {
  animation: slideIn 0.3s ease backwards;
}

.friend-item:nth-child(1) { animation-delay: 0.1s; }
.friend-item:nth-child(2) { animation-delay: 0.2s; }
.friend-item:nth-child(3) { animation-delay: 0.3s; }
.friend-item:nth-child(4) { animation-delay: 0.4s; }

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Стили для аватаров с инициалами */
.friend-avatar {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    position: relative;
    display: grid;
    place-items: center;
}

.friend-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

.avatar-initials {
    font-size: 18px;
    font-weight: 700;
    color: white;
    text-shadow: 0 1px 3px rgba(0,0,0,0.3);
    z-index: 0;
}

/* Для загруженного изображения */
.friend-avatar.loaded .avatar-initials {
    display: none;
}

.friend-avatar.loaded img {
    display: block;
}

.friend-avatar:not(.loaded) img {
    display: none;
}

.page.active .card {padding:0px}

/* ====== МАГАЗИН БУСТОВ (ОБНОВЛЕННЫЕ СТИЛИ) ====== */
.shop-header {
  padding: 16px 16px 0;
  margin-bottom: 16px;
  text-align: center;
}

.shop-title-image {
  width: 100%;
  max-width: 400px;
  height: auto;
  margin: 0 auto 8px;
  display: block;
}

.shop-subtitle {
  color: rgba(255,255,255,.6);
  font-size: 14px;
  margin-bottom: 4px;
}

/* Список бустов */
.shop-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.boost-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.12), rgba(255,255,255,.06));
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.10);
  transition: all 0.2s ease;
}

.boost-icon {
  width: 60px;
  height: 60px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
}

.boost-icon:before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 12px;
  opacity: 0.2;
}

.boost-icon[style*="background: #ffb300"]:before {
  background: #ffb300;
}

.boost-icon[style*="background: #3aa7ff"]:before {
  background: #3aa7ff;
}

.boost-icon[style*="background: #a64aff"]:before {
  background: #a64aff;
}

.boost-icon img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  position: relative;
  z-index: 1;
}

.boost-info {
  flex: 1;
  min-width: 0;
}

.boost-name {
  font-size: 16px;
  font-weight: 600;
  color: rgba(255,255,255,.9);
  margin-bottom: 6px;
}

.boost-desc {
  font-size: 13px;
  color: rgba(255,255,255,.6);
  line-height: 1.3;
  margin-bottom: 8px;
}

.boost-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.boost-duration {
  font-size: 12px;
  color: rgba(255,255,255,.5);
  display: flex;
  align-items: center;
  gap: 4px;
}

.boost-price {
  font-size: 16px;
  font-weight: 700;
  color: var(--accent-gold);
  text-align: right;
}

.boost-price.not-enough {
  color: rgba(255,255,255,.4);
}

.boost-buy {
  padding: 10px 20px;
  font-size: 14px;
  height: auto;
  min-width: 90px;
  border-radius: 10px;
  background: linear-gradient(180deg, var(--accent-red), var(--accent-red)90%);
  color: white;
  border: 1px solid rgba(255,255,255,.16);
  font-weight: 600;
  box-shadow: 0 10px 18px rgba(211,66,69,.22);
  cursor: pointer;
}

.boost-buy.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background: linear-gradient(180deg, rgba(211,66,69,.5), rgba(211,66,69,.4));
}

/* Активные бусты */
.active-boosts-card {
  margin-top: 24px;
}

.active-boosts-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.active-boost {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(76,175,80,.12), rgba(76,175,80,.06));
  border: 1px solid rgba(76,175,80,.3);
  backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.10);
}

.active-boost-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
}

.active-boost-icon.x2 {
  background: rgba(255,179,0,.2);
  border: 1px solid rgba(255,179,0,.4);
}

.active-boost-icon.auto {
  background: rgba(58,167,255,.2);
  border: 1px solid rgba(58,167,255,.4);
}

.active-boost-icon.slow {
  background: rgba(166,74,255,.2);
  border: 1px solid rgba(166,74,255,.4);
}

.active-boost-icon img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.active-boost-info {
  flex: 1;
}

.active-boost-name {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,.9);
  margin-bottom: 4px;
}

.active-boost-timer {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Состояния загрузки и ошибок */
.shop-loading,
.shop-error {
  padding: 40px 20px;
  text-align: center;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255,255,255,.1);
  border-top-color: var(--accent-gold);
  border-radius: 50%;
  margin: 0 auto 16px;
  animation: spin 1s linear infinite;
}

.shop-error .error-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 12px;
  border-radius: 12px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.14);
  display: grid;
  place-items: center;
}

.shop-error .error-icon svg {
  width: 22px;
  height: 22px;
  fill: rgba(255,255,255,.72);
}

.error-desc {
  font-size: 13px;
  color: rgba(255,255,255,.6);
  margin: 8px 0 16px;
}

.no-boosts {
  padding: 30px 20px;
  text-align: center;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.1);
}

.no-boosts-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 12px;
  border-radius: 12px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.14);
  display: grid;
  place-items: center;
}

.no-boosts-icon svg {
  width: 22px;
  height: 22px;
  fill: rgba(255,255,255,.72);
}

/* Анимации */
@keyframes cardSlideIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.boost-item,
.active-boost {
  animation: cardSlideIn 0.4s ease backwards;
}

.boost-item:nth-child(1) { animation-delay: 0.1s; }
.boost-item:nth-child(2) { animation-delay: 0.2s; }
.boost-item:nth-child(3) { animation-delay: 0.3s; }

/* Эффекты при нажатии */
.boost-item:active,
.active-boost:active,
.shop-error .btn:active {
  transform: scale(0.98);
  transition: transform 0.1s ease;
}

.boost-buy:active:not(.disabled) {
  transform: translateY(1px);
  box-shadow: 0 6px 12px rgba(211,66,69,.22);
}

/* Таймеры обратного отсчета */
.timer-pulse {
  animation: timerPulse 1s ease-in-out infinite;
}

@keyframes timerPulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.6;
  }
}

/* Адаптивность */
@media (max-width: 600px) {
  .boost-item {
    flex-wrap: wrap;
  }
  
  .boost-buy {
    width: 100%;
    margin-top: 12px;
  }
  
  .boost-meta {
    width: 100%;
  }
}

@media (max-width: 400px) {
  .shop-list {
    gap: 10px;
  }
  
  .boost-item {
    padding: 14px;
  }
  
  .boost-icon {
    width: 50px;
    height: 50px;
  }
  
  .boost-icon img {
    width: 32px;
    height: 32px;
  }
  
  .active-boost {
    padding: 12px;
  }
  
  .active-boost-icon {
    width: 40px;
    height: 40px;
  }
  
  .active-boost-icon img {
    width: 20px;
    height: 20px;
  }
}

/* Иконки для бустов (SVG стили) */
.boost-duration svg,
.active-boost-timer svg {
  width: 12px;
  height: 12px;
  fill: rgba(255,255,255,.5);
}

/* Эффекты для дорогих бустов */
.boost-item.premium {
  background: linear-gradient(180deg, rgba(255,215,0,.12), rgba(255,200,0,.06));
  border: 1px solid rgba(255,215,0,.3);
}

.boost-item.premium .boost-price {
  color: #FFD700;
  text-shadow: 0 0 10px rgba(255,215,0,.3);
}

/* Статус "доступно бесплатно" */
.boost-item.free .boost-price {
  color: #4CAF50;
  font-weight: 800;
}

.boost-item.free .boost-buy {
  background: linear-gradient(180deg, #4CAF50, #45a049);
  box-shadow: 0 10px 18px rgba(76,175,80,.22);
}


/* ====== ИСПРАВЛЕНИЕ РАЗМЫТИЯ ФОНА ====== */
.page:not(.active) {
    display: none;
}

.page.active {
    display: block;
    position: relative;
    z-index: 10;
    animation: pageFadeIn 0.3s ease;
}

@keyframes pageFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* Убираем отдельный элемент page-overlay */
.page-overlay {
    display: none;
}

/* Убираем затемнение для header при размытии */
.bg-blur header::before,
.bg-blur header::after {
    display: none;
}

/* Размытие только для фона */
.bg-blur .bg {
    background: radial-gradient(
    60% 55% at 50% 18%,
    #2b3046 0%,
    #1a1f33 40%,
    #0c0f1b 75%,
    #090b14 100%
  ),
  linear-gradient(
    180deg,
    #1a1f33 0%,
    #0b0e19 100%
  );
    filter: blur(20px) brightness(0.7);
    transform: scale(1.05);
    transition: filter 0.3s ease, transform 0.3s ease;
}

/* Для страниц с контентом делаем фон менее размытым */
[data-page="boosts"] .bg,
[data-page="bonuses"] .bg,
[data-page="skins"] .bg,
[data-page="leaders"] .bg,
[data-page="friends"] .bg,
[data-page="pvp"] .bg {
    filter: blur(15px) brightness(0.8);
}

/* ====== ЗАПРЕТ ВСЕХ НЕЖЕЛАТЕЛЬНЫХ ВЗАИМОДЕЙСТВИЙ ====== */
* {
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
  touch-action: manipulation;
}

/* Разрешаем выделение только для текстовых полей ввода */
input, textarea {
  -webkit-user-select: text;
  -moz-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

/* Запрет зума на iOS */
html {
  touch-action: pan-y;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  overscroll-behavior: none;
  -webkit-overflow-scrolling: touch;
}

/* Запрет масштабирования */
@media (hover: none) and (pointer: coarse) {
  input[type="text"],
  input[type="search"],
  input[type="password"],
  input[type="email"],
  input[type="tel"],
  input[type="url"],
  input[type="number"],
  textarea {
    font-size: 16px !important; /* Предотвращает зум на iOS */
  }
}

/* Запрет выделения для всего, кроме нужных элементов */
.no-select {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

.allow-select {
  -webkit-user-select: text;
  -moz-user-select: text;
  -ms-user-select: text;
  user-select: text;
}

/* Запрет скролла на body при открытых модалках */
body.no-scroll {
  overflow: hidden;
  position: fixed;
  width: 100%;
  height: 100%;
}

/* Улучшаем скролл для контейнеров */
.app {
  -webkit-overflow-scrolling: touch;
  overflow-y: auto;
  height: calc(100vh - 200px);
}

/* Убираем стандартное поведение iOS для ссылок */
a {
  -webkit-tap-highlight-color: rgba(0,0,0,0.1);
}


/* ====== МОДАЛЬНОЕ ОКНО ЕЖЕДНЕВНЫХ БОНУСОВ (BOTTOM SHEET) ====== */
.daily-bonus-sheet {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 80px; /* Выше навигации */
  height: 580px;
  border-radius: 26px;
  background:
    radial-gradient(
    60% 55% at 50% 18%,
    #2b3046 0%,
    #1a1f33 40%,
    #0c0f1b 75%,
    #090b14 100%
  ),
  linear-gradient(
    180deg,
    #1a1f33 0%,
    #0b0e19 100%
  );
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  transform: translateY(120%);
  transition: transform 360ms cubic-bezier(0.2, 0.95, 0.25, 1);
  z-index: 100;
  will-change: transform;
  backdrop-filter: blur(20px);
}

.daily-bonus-sheet.active {
  transform: translateY(0);
}

/* Tiny stars effect */
.daily-bonus-sheet::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1.5px 1.5px at 20% 20%, rgba(255, 255, 255, 0.35), transparent 60%),
    radial-gradient(1px 1px at 35% 25%, rgba(255, 255, 255, 0.28), transparent 60%),
    radial-gradient(1.2px 1.2px at 55% 18%, rgba(255, 255, 255, 0.22), transparent 60%),
    radial-gradient(1px 1px at 70% 32%, rgba(255, 255, 255, 0.18), transparent 60%),
    radial-gradient(1.5px 1.5px at 78% 22%, rgba(255, 255, 255, 0.25), transparent 60%),
    radial-gradient(1px 1px at 18% 42%, rgba(255, 255, 255, 0.16), transparent 60%),
    radial-gradient(1.2px 1.2px at 82% 48%, rgba(255, 255, 255, 0.2), transparent 60%);
  opacity: 0.9;
  pointer-events: none;
  mix-blend-mode: screen;
}

/* Overlay */
.daily-bonus-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 280ms ease;
  z-index: 99;
}

.daily-bonus-overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* Sheet top with grabber */
.bonus-sheet-top {
  position: relative;
  padding: 14px 16px 10px;
  cursor: grab;
  user-select: none;
}

.bonus-sheet-top:active {
  cursor: grabbing;
}

.sheet-grabber {
  position: absolute;
  left: 50%;
  top: 10px;
  transform: translateX(-50%);
  width: 84px;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.25);
}

.close-sheet-btn {
  position: absolute;
  right: 16px;
  top: 14px;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  z-index: 2;
}

.close-sheet-btn:active {
  transform: translateY(1px);
}

/* Sheet content */
.bonus-sheet-content {
  padding: 10px 18px 18px;
  height: calc(100% - 52px);
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* Icon wrap */
.bonus-icon-wrap {
  display: grid;
  place-items: center;
  margin-top: 2px;
}

.bonus-icon-wrap svg {
  width: 86px;
  height: 86px;
}

/* Title */
.bonus-title {
  text-align: center;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0.2px;
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.95);
  background: linear-gradient(90deg, #f7dfa3, #e9c979);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.bonus-desc {
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  font-size: 13px;
  line-height: 1.5;
  max-width: 310px;
  margin: -4px auto 0;
}

/* Streak grid */
.bonus-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 2px;
}

.bonus-day-card {
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 12px 12px 10px;
  min-height: 88px;
  position: relative;
  transition: all 0.3s ease;
}

.bonus-day-card.active {
  border-color: rgba(49, 211, 123, 0.55);
  box-shadow: 0 0 0 1px rgba(49, 211, 123, 0.25) inset;
  background: rgba(49, 211, 123, 0.08);
}

.bonus-day-card.today {
  border-color: rgba(244, 163, 27, 0.55);
  box-shadow: 0 0 0 1px rgba(244, 163, 27, 0.25) inset;
  background: rgba(244, 163, 27, 0.08);
  transform: scale(1.05);
}

.bonus-day-card.claimed {
  border-color: rgba(107, 108, 255, 0.55);
  box-shadow: 0 0 0 1px rgba(107, 108, 255, 0.25) inset;
  background: rgba(107, 108, 255, 0.08);
}

.bonus-day-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 700;
  font-size: 12px;
}

.bonus-amount {
  margin-top: 10px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.2px;
  text-align: center;
  color: rgba(255, 255, 255, 0.92);
}

/* Gift row */
.gift-row {
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 6px;
}

.gift-row-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gift-row-right {
  text-align: right;
}

.gift-label {
  color: rgba(255, 255, 255, 0.7);
  font-weight: 700;
  font-size: 12px;
}

.gift-value {
  font-weight: 800;
  font-size: 18px;
  margin-top: 2px;
  color: #f6c21f;
}

/* Claim button */
.claim-bonus-btn {
  margin-top: auto;
  width: 100%;
  padding: 16px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(90deg, var(--accent-red), var(--accent-red) 90%);
  color: white;
  font-weight: 700;
  letter-spacing: 0.2px;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(211, 66, 69, 0.25);
  transition: all 0.2s ease;
}

.claim-bonus-btn:active {
  transform: translateY(1px);
  box-shadow: 0 5px 20px rgba(211, 66, 69, 0.25);
}

.claim-bonus-btn.disabled {
  background: rgba(255, 255, 255, 0.04);
  color: rgba(233, 236, 255, 0.45);
  cursor: not-allowed;
  box-shadow: none;
}

.claim-bonus-btn.disabled:active {
  transform: none;
}

/* Timer */
.bonus-timer {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
  margin-top: 4px;
}

/* SVG icons */
.check-icon {
  width: 22px;
  height: 22px;
}

.coin-icon {
  width: 22px;
  height: 22px;
}

/* Responsive */
@media (max-height: 700px) {
  .daily-bonus-sheet {
    height: 500px;
    bottom: 70px;
  }
}

@media (max-width: 380px) {
  .daily-bonus-sheet {
    left: 12px;
    right: 12px;
  }
  
  .bonus-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  
  .bonus-title {
    font-size: 28px;
  }
}

/* Animation for opening */
@keyframes sheetAppear {
  from {
    opacity: 0;
    transform: translateY(120%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.daily-bonus-sheet.active {
  animation: sheetAppear 0.4s cubic-bezier(0.2, 0.95, 0.25, 1);
}

/* ====== ЗОЛОТАЯ ПУЛЬСАЦИЯ ТЕКУЩЕГО ДНЯ ====== */
.bonus-day-card.today {
  position: relative;
  z-index: 2;
  cursor: pointer;
  border: none !important;
  overflow: hidden;
  transform: scale(1.05);
  animation: goldPulse 2s infinite ease-in-out !important;
  box-shadow: 
    0 8px 18px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    inset 0 -8px 16px rgba(0, 0, 0, 0.18) !important;
}

/* Золотой градиентный фон */
.bonus-day-card.today::before {
  content: '';
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(
      60% 55% at 50% 18%,
      #f7dfa3 0%,
      #ecd08a 32%,
      #d7ad55 65%,
      #9e7a34 100%
    ),
    linear-gradient(
      180deg,
      #f1d58f 0%,
      #d7ad55 45%,
      #8f6a2a 100%
    );
  border-radius: 16px;
  z-index: -2;
}

/* Внутренняя обводка как в прогресс-баре */
.bonus-day-card.today::after {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 14px;
  border: 1px solid rgba(90, 60, 10, 0.22);
  pointer-events: none;
  z-index: -1;
}

/* Текст внутри золотой карточки */
.bonus-day-card.today .bonus-day-top span {
  color: rgba(18, 14, 8, 0.92) !important;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) !important;
  font-weight: 700 !important;
}

.bonus-day-card.today .bonus-amount {
  color: rgba(18, 14, 8, 0.92) !important;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) !important;
  font-weight: 800 !important;
  font-size: 22px !important;
}

/* Иконка внутри золотой карточки */
.bonus-day-card.today .coin-icon circle {
  fill: rgba(18, 14, 8, 0.15) !important;
}

.bonus-day-card.today .coin-icon path {
  fill: rgba(18, 14, 8, 0.8) !important;
}

/* Анимация пульсации золотом */
@keyframes goldPulse {
  0%, 100% {
    box-shadow: 
      0 8px 18px rgba(0, 0, 0, 0.18),
      inset 0 1px 0 rgba(255, 255, 255, 0.55),
      inset 0 -8px 16px rgba(0, 0, 0, 0.18),
      0 0 0 rgba(247, 223, 163, 0);
    transform: scale(1.05);
  }
  50% {
    box-shadow: 
      0 12px 25px rgba(0, 0, 0, 0.25),
      inset 0 1px 0 rgba(255, 255, 255, 0.65),
      inset 0 -8px 16px rgba(0, 0, 0, 0.22),
      0 0 30px rgba(247, 223, 163, 0.6);
    transform: scale(1.08);
  }
}

/* Дополнительное свечение */
@keyframes goldGlow {
  0%, 100% {
    opacity: 0.4;
  }
  50% {
    opacity: 0.8;
  }
}

.bonus-day-card.today {
  position: relative;
}


/* Эффект при наведении */
.bonus-day-card.today:hover {
  animation: goldPulse 0.8s infinite ease-in-out !important;
}

/* ====== WELCOME BOTTOM SHEET (в стиле ежедневных бонусов) ====== */
#welcomeSheet {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 80px;
  height: 580px;
  border-radius: 26px;
  background:
    radial-gradient(
      60% 55% at 50% 18%,
      #2b3046 0%,
      #1a1f33 40%,
      #0c0f1b 75%,
      #090b14 100%
    ),
    linear-gradient(
      180deg,
      #1a1f33 0%,
      #0b0e19 100%
    );
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  transform: translateY(120%);
  transition: transform 360ms cubic-bezier(0.2, 0.95, 0.25, 1);
  z-index: 1000;
  will-change: transform;
  backdrop-filter: blur(20px);
  display: block !important; /* Важно: переопределяем display */
}

#welcomeSheet.active {
  transform: translateY(0);
}

#welcomeOverlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 280ms ease;
  z-index: 999;
  display: block !important;
}

#welcomeOverlay.active {
  opacity: 1;
  pointer-events: all;
}

.welcome-features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-top: 2px;
}

.feature-card {
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 16px 12px;
  text-align: center;
  transition: all 0.3s ease;
  min-height: 100px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.feature-card:hover {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-2px);
}

.feature-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 10px;
  display: grid;
  place-items: center;
}

.feature-icon svg {
  width: 36px;
  height: 36px;
}

.feature-name {
  font-weight: 700;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 4px;
}

.feature-desc {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.3;
}

.welcome-tip {
  margin-top: 16px;
  padding: 14px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(77, 163, 255, 0.12), rgba(77, 163, 255, 0.06));
  border: 1px solid rgba(77, 163, 255, 0.2);
  display: flex;
  align-items: center;
  gap: 12px;
  backdrop-filter: blur(10px);
}

.tip-icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.tip-icon svg {
  width: 100%;
  height: 100%;
}

.tip-text {
  flex: 1;
  font-size: 13px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.8);
}

.tip-text strong {
  color: #4da3ff;
  font-weight: 700;
}

/* Анимация появления карточек */
@keyframes featureSlideIn {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.feature-card {
  animation: featureSlideIn 0.4s ease backwards;
}

.feature-card:nth-child(1) { animation-delay: 0.1s; }
.feature-card:nth-child(2) { animation-delay: 0.2s; }
.feature-card:nth-child(3) { animation-delay: 0.3s; }
.feature-card:nth-child(4) { animation-delay: 0.4s; }

/* Золотой градиент для заголовка */
#welcomeSheet .bonus-title {
  background: linear-gradient(90deg, #f7dfa3, #e9c979, #f5c46b);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Адаптивность для маленьких экранов */
@media (max-height: 700px) {
  #welcomeSheet {
    height: 500px;
    bottom: 70px;
  }
  
  .welcome-features-grid {
    gap: 10px;
  }
  
  .feature-card {
    padding: 12px 10px;
    min-height: 90px;
  }
  
  .feature-icon {
    width: 36px;
    height: 36px;
    margin-bottom: 8px;
  }
  
  .feature-icon svg {
    width: 30px;
    height: 30px;
  }
  
  .feature-name {
    font-size: 13px;
  }
  
  .feature-desc {
    font-size: 10px;
  }
}

@media (max-width: 380px) {
  #welcomeSheet {
    left: 12px;
    right: 12px;
  }
  
  .welcome-features-grid {
    grid-template-columns: 1fr;
  }
}

/* Анимация открытия */
@keyframes sheetAppear {
  from {
    opacity: 0;
    transform: translateY(120%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#welcomeSheet.active {
  animation: sheetAppear 0.4s cubic-bezier(0.2, 0.95, 0.25, 1);
}

/* Убираем возможное наследование display: none */
.daily-bonus-sheet:not(#welcomeSheet) {
  /* Оставляем как есть для daily-bonus-sheet */
}

#welcomeSheet.daily-bonus-sheet {
    display: block !important;
}


/* ====== ПРОМО-БЛОК ДЛЯ МАГАЗИНА СКИНОВ ====== */
.promo-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 112px;
  margin-bottom: 20px;
  background:
  linear-gradient(
    180deg,
    #1a1c22 0%,
    #0f1116 100%
  );

  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding:16px!important;
}

.promo-left {
  flex: 1 1 auto;
  min-width: 0;
}

.promo-title {
  margin: 0 0 10px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  line-height: 1.05;
  font-size: 18px;
  color: #ffffff;
}

.promo-accent {
  color: #e0bd6e; /* жёлтый акцент */
  background: radial-gradient(
    60% 55% at 50% 18%,
    #f7dfa3 0%,
    #ecd08a 32%,
    #d7ad55 65%,
    #9e7a34 100%
  ),
  linear-gradient(
    180deg,
    #f1d58f 0%,
    #d7ad55 45%,
    #8f6a2a 100%
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.promo-desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.55);
}

.promo-right {
  flex: 0 0 auto;
  width: 120px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.promo-ico {
  width: 200px;
  height: auto;
  display: block;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.35));
  user-select: none;
  -webkit-user-drag: none;
  border-radius: 12px;
  margin-right:15px;
}

/* Адаптивность для промо-блока */
@media (max-width: 380px) {
  .promo-card {
    flex-direction: column;
    text-align: center;
    gap: 12px;
    min-height: auto;
  }
  
  .promo-right {
    width: 100%;
    height: 80px;
  }
  
  .promo-ico {
    width: 90px;
  }
}


/* ====== ТАБЫ ДЛЯ КАТЕГОРИЙ СКИНОВ ====== */
.skin-tabs {
  margin-bottom: 20px;
}

.skin-tabs-header {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 20px;
  background: rgba(0, 0, 0, 0.1);
  border-radius: 14px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.skin-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 8px;
  border-radius: 12px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.skin-tab:hover {
  background: rgba(255, 255, 255, 0.05);
}

.skin-tab.active {
  background: radial-gradient(
    60% 55% at 50% 18%,
    #ff3b2f 0%,
    #d11f14 35%,
    #a2170b 65%,
    #3a0603 100%
  ),
  linear-gradient(
    180deg,
    rgba(255,255,255,.18) 0%,
    rgba(0,0,0,.0) 55%,
    rgba(0,0,0,.25) 100%
  );
  color: #fff;
  box-shadow:
      0 24px 70px rgba(0,0,0,.65),
      inset 0 1px 0 rgba(255,255,255,.18),
      inset 0 -18px 30px rgba(0,0,0,.45);
    
    border: 1px solid rgba(255,255,255,.14);

}

.tab-icon {
  font-size: 20px;
  line-height: 1;
  filter: grayscale(0.5);
  opacity: 0.7;
}

.skin-tab.active .tab-icon {
  filter: grayscale(0);
  opacity: 1;
}

.tab-text {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Контент табов */
.skin-tabs-content {
  position: relative;
  min-height: 300px;
}

.skin-tab-pane {
  display: none;
  animation: fadeIn 0.3s ease;
}

.skin-tab-pane.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Состояние "Скоро" для пустых категорий */
.coming-soon {
  grid-column: 1 / -1;
  padding: 60px 20px;
  text-align: center;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, .04));
  border: 2px dashed rgba(255, 255, 255, .1);
}

.coming-soon-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.coming-soon-title {
  font-size: 18px;
  font-weight: 700;
  color: rgba(255, 255, 255, .8);
  margin-bottom: 8px;
}

.coming-soon-desc {
  font-size: 14px;
  color: rgba(255, 255, 255, .6);
  max-width: 300px;
  margin: 0 auto;
}

/* Адаптивность для табов */
@media (max-width: 380px) {
  .skin-tabs-header {
    gap: 4px;
    padding: 3px;
  }
  
  .skin-tab {
    padding: 10px 6px;
    font-size: 12px;
  }
  
  .tab-icon {
    font-size: 18px;
  }
  
  .tab-text {
    font-size: 11px;
  }
}



/* ====== СТИЛИ ДЛЯ СТРАНИЦЫ ЛИДЕРОВ В СТИЛЕ СКИНОВ ====== */

/* Табы лидеров */
#tabGlobal .tab-icon { content: "🌍"; }
#tabWeekly .tab-icon { content: "🏆"; }
#tabFriends .tab-icon { content: "👥"; }

/* Список лидеров */
.leaders-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 300px;
  max-height: 400px;
  overflow-y: auto;
}

.leader-item {
  display: flex;
  align-items: center;
  background: #111420;
  backdrop-filter: blur(14px);
  padding: 16px !important;
  border-radius: 16px;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  gap: 16px; /* Отступ между изображением и контентом */
}

.leader-item.current {
  background: radial-gradient(
    60% 55% at 50% 18%,
    #cfe6d8 0%,
    #9fcbb1 35%,
    #5f9f80 65%,
    #2f5f4a 100%
  ),
  linear-gradient(
    180deg,
    #cfe6d8 0%,
    #7fbfa0 45%,
    #2f5f4a 100%
  );
  border: 1px solid rgba(255,255,255,.12);

box-shadow:
  0 20px 60px rgba(0,0,0,.55),
  inset 0 1px 0 rgba(255,255,255,.18),
  inset 0 -16px 28px rgba(0,0,0,.35);
  transform: translateY(-2px);
}

.leader-item.current .leader-name {
    color:#17191e;
}

.leader-rank {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 14px;
  color: rgba(255,255,255,.9);
  background: rgba(0,0,0,.2);
  border: 1px solid rgba(255,255,255,.1);
  flex-shrink: 0;
}

.leader-item.top-1 .leader-rank {
  background: linear-gradient(180deg, #FFD700, #FF9900);
  color: rgba(18,14,8,0.92);
  text-shadow: 0 1px 0 rgba(255,255,255,0.35);
}

.leader-item.top-2 .leader-rank {
  background: linear-gradient(180deg, #C0C0C0, #A0A0A0);
  color: rgba(18,14,8,0.92);
  text-shadow: 0 1px 0 rgba(255,255,255,0.35);
}

.leader-item.top-3 .leader-rank {
  background: linear-gradient(180deg, #CD7F32, #B87333);
  color: rgba(18,14,8,0.92);
  text-shadow: 0 1px 0 rgba(255,255,255,0.35);
}


.leader-info {
  flex: 1;
  min-width: 0;
}

.leader-name {
  font-size: 15px;
  font-weight: 700;
  color: rgba(255,255,255,.9);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.leader-stats {
  display: flex;
  align-items: center;
  gap: 12px;
}

.leader-stat {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  display: flex;
  align-items: center;
  gap: 4px;
}

.leader-score {
  font-size: 16px;
  font-weight: 800;
  color: var(--accent-gold);
  text-align: right;
  min-width: 60px;
}

/* Ваша позиция */
.your-position-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.06));
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.10);
}

.your-position-left {
  flex: 0 0 auto;
}

.position-rank {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 18px;
  color: rgba(255,255,255,.9);
  background: linear-gradient(135deg, rgba(77,163,255,.5), rgba(166,74,255,.4));
  margin-bottom: 8px;
}

.position-avatar {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(77,163,255,.32), rgba(166,74,255,.22));
}

.your-position-right {
  flex: 1;
  min-width: 0;
}

.position-name {
  font-size: 18px;
  font-weight: 800;
  color: rgba(255,255,255,.95);
  margin: 0 0 10px;
}

.position-stats {
  display: flex;
  gap: 16px;
}

.position-stat {
  display: flex;
  flex-direction: column;
}

.position-stat .stat-label {
  font-size: 11px;
  color: rgba(255,255,255,.6);
  margin-bottom: 2px;
}

.position-stat .stat-value {
  font-size: 15px;
  font-weight: 800;
  color: rgba(255,255,255,.9);
}

/* Состояния загрузки и пустоты */
.loading-skins,
.leaders-empty {
  padding: 60px 20px;
  text-align: center;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 2px dashed rgba(255,255,255,.1);
}

.leaders-empty .empty-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.leaders-empty .empty-title {
  font-size: 18px;
  font-weight: 700;
  color: rgba(255,255,255,.8);
  margin-bottom: 8px;
}

.leaders-empty .empty-desc {
  font-size: 14px;
  color: rgba(255,255,255,.6);
  max-width: 300px;
  margin: 0 auto;
}

/* Адаптивность */
@media (max-width: 380px) {
  .leader-item {
    padding: 12px;
    gap: 10px;
  }
  
  .leader-rank {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }
  
  .leader-avatar {
    width: 36px;
    height: 36px;
  }
  
  .leader-name {
    font-size: 14px;
  }
  
  .leader-score {
    font-size: 14px;
    min-width: 50px;
  }
  
  .your-position-card {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }
  
  .position-stats {
    flex-wrap: wrap;
    justify-content: center;
  }
}

/* Анимации */
@keyframes leaderSlideIn {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.leader-item {
  animation: leaderSlideIn 0.3s ease backwards;
}

.leader-item:nth-child(1) { animation-delay: 0.1s; }
.leader-item:nth-child(2) { animation-delay: 0.2s; }
.leader-item:nth-child(3) { animation-delay: 0.3s; }
.leader-item:nth-child(4) { animation-delay: 0.4s; }


/* ====== СТИЛИ ДЛЯ СТРАНИЦЫ ДРУЗЬЯ В СТИЛЕ СКИНОВ ====== */

/* Статистика в сетке */
.referrals-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.stat-card-small {
  background: #111420;
  border-radius: 14px;
  padding: 12px;
  text-align: center;
  backdrop-filter: blur(10px);
}

.stat-card-small-value {
  font-size: 24px;
  font-weight: 800;
  color: var(--accent-gold);
  margin-bottom: 4px;
  line-height: 1;
}

.stat-card-small-label {
  font-size: 11px;
  color: rgba(255,255,255,.6);
  line-height: 1.2;
}

/* Список рефералов */
.referrals-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 200px;
}

.referral-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(10px);
  transition: all 0.2s ease;
}

.referral-item:hover {
  border-color: rgba(255,255,255,.2);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,.2);
}

.referral-avatar {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  overflow: hidden;
  flex-shrink: 0;
  background: linear-gradient(135deg, rgba(77,163,255,.32), rgba(166,74,255,.22));
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 16px;
  color: white;
}

.referral-info {
  flex: 1;
  min-width: 0;
}

.referral-name {
  font-size: 15px;
  font-weight: 700;
  color: rgba(255,255,255,.9);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.referral-status {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  display: flex;
  align-items: center;
  gap: 6px;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
}

.status-dot.played { 
  background: #4CAF50; 
}
.status-dot.offline { 
  background: #f44336; 
}

.referral-date {
  font-size: 11px;
  color: rgba(255,255,255,.4);
  margin-top: 2px;
}

.referral-score {
  font-size: 16px;
  font-weight: 800;
  color: var(--accent-gold);
  text-align: right;
  min-width: 40px;
}

/* Пустое состояние */
.referrals-empty {
  padding: 40px 20px;
  text-align: center;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 2px dashed rgba(255,255,255,.1);
}

.referrals-empty .empty-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  opacity: 0.3;
}

.referrals-empty .empty-title {
  font-size: 16px;
  font-weight: 700;
  color: rgba(255,255,255,.8);
  margin-bottom: 8px;
}

.referrals-empty .empty-desc {
  font-size: 13px;
  color: rgba(255,255,255,.6);
  max-width: 300px;
  margin: 0 auto;
  line-height: 1.4;
}

/* Карточки наград */
.rewards-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.reward-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(10px);
  transition: all 0.2s ease;
}

.reward-card:hover {
  border-color: rgba(255,255,255,.2);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,.2);
}

.reward-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.reward-card-content {
  flex: 1;
  min-width: 0;
}

.reward-card-title {
  font-size: 15px;
  font-weight: 700;
  color: rgba(255,255,255,.9);
  margin-bottom: 4px;
}

.reward-card-amount {
  font-size: 18px;
  font-weight: 800;
  color: var(--accent-gold);
  margin-bottom: 4px;
}

.reward-card-desc {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  line-height: 1.3;
}

/* Секция поделиться */
.share-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.section-label {
  font-size: 13px;
  font-weight: 700;
  color: rgba(255,255,255,.7);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.share-link-container {
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 16px;
  padding: 16px;
  backdrop-filter: blur(10px);
}

.share-link-display {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.share-link-input {
  flex: 1;
  background: rgba(0,0,0,.2);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 13px;
  color: rgba(255,255,255,.9);
  outline: none;
  cursor: default;
  user-select: all;
}

.share-link-input::selection {
  background: rgba(77,163,255,.3);
}

.share-link-copy {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: linear-gradient(180deg, var(--accent-red), var(--accent-red)90%);
  border: 1px solid rgba(255,255,255,.16);
  color: white;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.share-link-copy:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 15px rgba(211,66,69,.25);
}

.share-link-copy:active {
  transform: translateY(0);
}

.ref-code-section {
  text-align: center;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.1);
}

.ref-code-label {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  margin-bottom: 6px;
}

.ref-code-value {
  font-size: 24px;
  font-weight: 800;
  color: var(--accent-gold);
  letter-spacing: 2px;
  font-family: monospace;
}

/* Кнопки шаринга */
.share-buttons-grid {
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 16px;
  padding: 16px;
  backdrop-filter: blur(10px);
}

.share-buttons {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(0,0,0,.2);
  color: rgba(255,255,255,.9);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.share-btn.telegram {
  background: linear-gradient(180deg, rgba(0,136,204,.2), rgba(0,136,204,.1));
  border-color: rgba(0,136,204,.3);
}

.share-btn.telegram:hover {
  background: linear-gradient(180deg, rgba(0,136,204,.3), rgba(0,136,204,.2));
  border-color: rgba(0,136,204,.4);
}

.share-btn.whatsapp {
  background: linear-gradient(180deg, rgba(37,211,102,.2), rgba(37,211,102,.1));
  border-color: rgba(37,211,102,.3);
}

.share-btn.whatsapp:hover {
  background: linear-gradient(180deg, rgba(37,211,102,.3), rgba(37,211,102,.2));
  border-color: rgba(37,211,102,.4);
}

.share-btn span {
  flex: 1;
  text-align: center;
}

/* Адаптивность */
@media (max-width: 380px) {
  .referrals-stats-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  
  .stat-card-small {
    padding: 10px;
  }
  
  .stat-card-small-value {
    font-size: 20px;
  }
  
  .referral-item {
    padding: 12px;
    gap: 10px;
  }
  
  .referral-avatar {
    width: 40px;
    height: 40px;
    font-size: 14px;
  }
  
  .referral-name {
    font-size: 14px;
  }
  
  .reward-card {
    padding: 14px;
    gap: 12px;
  }
  
  .reward-card-icon {
    width: 40px;
    height: 40px;
  }
  
  .share-link-display {
    flex-direction: column;
    gap: 8px;
  }
  
  .share-link-copy {
    width: 100%;
  }
  
  .share-buttons {
    grid-template-columns: 1fr;
  }
}

/* Анимации */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.referral-item,
.reward-card {
  animation: fadeInUp 0.3s ease backwards;
}

.referral-item:nth-child(1) { animation-delay: 0.1s; }
.referral-item:nth-child(2) { animation-delay: 0.2s; }
.referral-item:nth-child(3) { animation-delay: 0.3s; }
.reward-card:nth-child(1) { animation-delay: 0.1s; }
.reward-card:nth-child(2) { animation-delay: 0.2s; }
.reward-card:nth-child(3) { animation-delay: 0.3s; }

/* ====== УВЕДОМЛЕНИЯ ВНИЗУ ЭКРАНА ====== */
/* ====== УВЕДОМЛЕНИЯ ВНИЗУ ЭКРАНА С ГРАДИЕНТНЫМ ФОНОМ ====== */
.bottom-notification {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 100px; /* Выше навигации */
  z-index: 1000;
  transform: translateY(120%);
  transition: transform 360ms cubic-bezier(0.2, 0.95, 0.25, 1);
  will-change: transform;
  opacity: 0;
}

.bottom-notification.active {
  transform: translateY(0);
  opacity: 1;
}

.notification-content {
  border-radius: 18px;
  padding: 0;
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  position: relative;
  background: 
    radial-gradient(
      60% 55% at 50% 18%,
      #2b3046 0%,
      #1a1f33 40%,
      #0c0f1b 75%,
      #090b14 100%
    ),
    linear-gradient(
      180deg,
      #1a1f33 0%,
      #0b0e19 100%
    );
}

/* Tiny stars effect как в других модалках */
.notification-content::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1.5px 1.5px at 20% 20%, rgba(255, 255, 255, 0.35), transparent 60%),
    radial-gradient(1px 1px at 35% 25%, rgba(255, 255, 255, 0.28), transparent 60%),
    radial-gradient(1.2px 1.2px at 55% 18%, rgba(255, 255, 255, 0.22), transparent 60%),
    radial-gradient(1px 1px at 70% 32%, rgba(255, 255, 255, 0.18), transparent 60%),
    radial-gradient(1.5px 1.5px at 78% 22%, rgba(255, 255, 255, 0.25), transparent 60%),
    radial-gradient(1px 1px at 18% 42%, rgba(255, 255, 255, 0.16), transparent 60%),
    radial-gradient(1.2px 1.2px at 82% 48%, rgba(255, 255, 255, 0.2), transparent 60%);
  opacity: 0.9;
  pointer-events: none;
  mix-blend-mode: screen;
  z-index: 0;
}

.notification-top {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px;
  position: relative;
  z-index: 1;
}

.notification-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.notification-icon svg {
  width: 20px;
  height: 20px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.notification-text {
  flex: 1;
  min-width: 0;
}

.notification-title {
  font-weight: 800;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.95);
  letter-spacing: 0.3px;
  margin-bottom: 6px;
  line-height: 1.2;
}

.notification-message {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.4;
}

.notification-close {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
  backdrop-filter: blur(10px);
}

.notification-close:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.18);
}

.notification-close:active {
  transform: scale(0.95);
}

/* Прогресс бар для таймера */
.notification-progress {
  height: 3px;
  background: rgba(255, 255, 255, 0.05);
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.progress-bar {
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0.4));
  transform: translateX(-100%);
}

.progress-bar.animating {
  animation: notificationProgress 4s linear forwards;
}

@keyframes notificationProgress {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(0%);
  }
}

/* Анимация появления уведомлений */
@keyframes notificationSlideIn {
  from {
    opacity: 0;
    transform: translateY(120%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.bottom-notification.active {
  animation: notificationSlideIn 0.4s cubic-bezier(0.2, 0.95, 0.25, 1);
}

/* Эффект при наведении */
.notification-content:hover {
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.65);
  transition: all 0.3s ease;
}

/* Для разных типов уведомлений - добавляем акцентную полоску */
.notification-content.success::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #4CAF50, #45a049);
  border-radius: 18px 0 0 18px;
}

.notification-content.error::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #f44336, #d32f2f);
  border-radius: 18px 0 0 18px;
}

.notification-content.warning::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #ff9800, #f57c00);
  border-radius: 18px 0 0 18px;
}

.notification-content.info::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #2196F3, #1976D2);
  border-radius: 18px 0 0 18px;
}

/* Адаптивность */
@media (max-width: 380px) {
  .bottom-notification {
    left: 12px;
    right: 12px;
    bottom: 90px;
  }
  
  .notification-top {
    padding: 16px;
    gap: 12px;
  }
  
  .notification-icon {
    width: 32px;
    height: 32px;
  }
  
  .notification-icon svg {
    width: 18px;
    height: 18px;
  }
  
  .notification-title {
    font-size: 15px;
  }
  
  .notification-message {
    font-size: 13px;
  }
  
  .notification-close {
    width: 30px;
    height: 30px;
  }
}

/* Для очень маленьких экранов */
@media (max-width: 320px) {
  .notification-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  
  .notification-icon {
    align-self: flex-start;
  }
  
  .notification-close {
    position: absolute;
    top: 16px;
    right: 16px;
  }
}

/* Для планшетов и больших экранов */
@media (min-width: 768px) {
  .bottom-notification {
    max-width: 400px;
    left: 50%;
    transform: translateX(-50%) translateY(120%);
  }
  
  .bottom-notification.active {
    transform: translateX(-50%) translateY(0);
  }
  
  @keyframes notificationSlideIn {
    from {
      opacity: 0;
      transform: translateX(-50%) translateY(120%);
    }
    to {
      opacity: 1;
      transform: translateX(-50%) translateY(0);
    }
  }
}

/* Золотой акцент для важных уведомлений */
.notification-content.important::after {
  background: linear-gradient(180deg, #f7dfa3, #d7ad55);
}

.notification-content.important .notification-icon {
  background: linear-gradient(135deg, rgba(247, 223, 163, 0.2), rgba(215, 173, 85, 0.15));
}

/* Эффект свечения для важных уведомлений */
.notification-content.important {
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.55),
    0 0 20px rgba(247, 223, 163, 0.1);
}

/* ====== МОДАЛЬНОЕ ОКНО "ЖИЗНИ ЗАКОНЧИЛИСЬ" ====== */
.no-lives-timer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px;
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.1);
  margin: 16px 0;
}

.timer-icon {
  font-size: 24px;
}

.timer-text {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.9);
}

.timer-text span {
  font-weight: 800;
  color: #ffcc00;
  margin-left: 4px;
}

.no-lives-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 20px 0;
}

.no-lives-option {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
  border: 1px solid rgba(255, 255, 255, 0.15);
  text-align: left;
  cursor: pointer;
  transition: all 0.3s ease;
}

.no-lives-option:active {
  transform: translateY(1px);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0.08));
}

.option-icon {
  font-size: 28px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}

.no-lives-option:first-child .option-icon {
  background: rgba(255, 107, 107, 0.2);
}

.no-lives-option:last-child .option-icon {
  background: rgba(77, 163, 255, 0.2);
}

.option-content {
  flex: 1;
}

.option-title {
  font-weight: 700;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 4px;
}

.option-desc {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
}

/* ====== МОДАЛЬНОЕ ОКНО ПОВЫШЕНИЯ УРОВНЯ ====== */
.level-up-number {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin: 24px 0;
}

.old-level,
.new-level {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 36px;
  color: rgba(18, 14, 8, 0.92);
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.35);
  position: relative;
  overflow: hidden;
}

.old-level {
  background: linear-gradient(180deg, #666, #444);
  box-shadow: 
    0 8px 18px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.new-level {
  background: linear-gradient(180deg, #f7dfa3 0%, #e9c979 48%, #d7ad55 100%);
  box-shadow: 
    0 8px 18px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    inset 0 -8px 16px rgba(0, 0, 0, 0.18);
  animation: levelUpPulse 2s ease-in-out infinite;
}

.new-level::before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: 18px;
  border: 1px solid rgba(90, 60, 10, 0.22);
  pointer-events: none;
}

.level-arrow {
  font-size: 32px;
  font-weight: 900;
  color: #f7dfa3;
  animation: arrowPulse 1.5s ease-in-out infinite;
}

@keyframes levelUpPulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 
      0 8px 18px rgba(0, 0, 0, 0.18),
      inset 0 1px 0 rgba(255, 255, 255, 0.55),
      inset 0 -8px 16px rgba(0, 0, 0, 0.18);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 
      0 12px 25px rgba(0, 0, 0, 0.25),
      inset 0 1px 0 rgba(255, 255, 255, 0.65),
      inset 0 -8px 16px rgba(0, 0, 0, 0.22),
      0 0 30px rgba(247, 223, 163, 0.6);
  }
}

@keyframes arrowPulse {
  0%, 100% {
    opacity: 1;
    transform: translateX(0);
  }
  50% {
    opacity: 0.7;
    transform: translateX(5px);
  }
}

.level-rewards {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 20px 0;
}

.level-reward {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.reward-icon {
  font-size: 28px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.1);
  flex-shrink: 0;
}

.reward-content {
  flex: 1;
}

.reward-title {
  font-weight: 700;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 4px;
}

.reward-desc {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
}

.level-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 20px 0;
}

.level-stat {
  padding: 14px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
}

.stat-label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 6px;
}

.stat-value {
  font-size: 18px;
  font-weight: 800;
  color: #f7dfa3;
}

/* Анимация появления уведомлений */
@keyframes notificationSlideIn {
  from {
    opacity: 0;
    transform: translateY(120%);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.bottom-notification.active {
  animation: notificationSlideIn 0.4s cubic-bezier(0.2, 0.95, 0.25, 1);
}

/* Адаптивность */
@media (max-width: 380px) {
  .bottom-notification {
    left: 12px;
    right: 12px;
    bottom: 70px;
  }
  
  .notification-content {
    padding: 14px;
  }
  
  .old-level,
  .new-level {
    width: 70px;
    height: 70px;
    font-size: 32px;
  }
  
  .level-arrow {
    font-size: 28px;
  }
  
  .no-lives-option {
    padding: 14px;
    gap: 12px;
  }
  
  .option-icon {
    width: 40px;
    height: 40px;
    font-size: 24px;
  }
}

/* Для очень маленьких экранов */
@media (max-width: 320px) {
  .notification-title {
    font-size: 15px;
  }
  
  .notification-message {
    font-size: 13px;
  }
  
  .old-level,
  .new-level {
    width: 60px;
    height: 60px;
    font-size: 28px;
  }
  
  .level-arrow {
    font-size: 24px;
  }
  
  .level-stats {
    grid-template-columns: 1fr;
  }
}

