/* =========================================================
   PVS.CASINO - PROFILE 2026
   Страница профиля с glassmorphism эффектами
   ========================================================= */

/* Основной контейнер профиля */
.profile {
  width: 100% !important;
  gap: 20px !important;
}

/* Карточка пользователя с glassmorphism */
.profile__user {
  width: 340px !important;
  padding: 32px !important;
  position: relative !important;
  border-radius: 24px !important;
  background: linear-gradient(135deg, 
    rgba(31, 31, 38, 0.8) 0%, 
    rgba(21, 21, 26, 0.9) 100%) !important;
  backdrop-filter: blur(40px) !important;
  -webkit-backdrop-filter: blur(40px) !important;
  border: 1px solid rgba(167, 77, 213, 0.3) !important;
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.4),
    0 0 40px rgba(167, 77, 213, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  overflow: hidden !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.profile__user::before {
  content: '' !important;
  position: absolute !important;
  top: -50% !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  width: 150% !important;
  height: 150% !important;
  background: radial-gradient(circle, rgba(167, 77, 213, 0.15) 0%, transparent 70%) !important;
  pointer-events: none !important;
  z-index: 0 !important;
}

.profile__user > * {
  position: relative !important;
  z-index: 1 !important;
}

.profile__user:hover {
  border-color: rgba(167, 77, 213, 0.5) !important;
  box-shadow: 
    0 24px 70px rgba(0, 0, 0, 0.5),
    0 0 50px rgba(167, 77, 213, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  transform: translateY(-2px) !important;
}

/* Заголовок профиля */
.profile__top {
  position: relative !important;
  width: 100% !important;
  margin-bottom: 24px !important;
  padding-bottom: 16px !important;
  border-bottom: 1px solid rgba(167, 77, 213, 0.2) !important;
}

.profile__top b {
  position: relative !important;
  font-weight: 600 !important;
  font-size: 14px !important;
  text-transform: uppercase !important;
  letter-spacing: 1px !important;
  color: var(--text-primary, #ffffff) !important;
  text-shadow: 0 2px 8px rgba(167, 77, 213, 0.3) !important;
}

/* Аватар с неоновым эффектом */
.profile__avatar {
  width: 100% !important;
  height: 160px !important;
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin-bottom: 20px !important;
}

.profile__avatar-ellipse {
  position: relative !important;
  width: 120px !important;
  height: 120px !important;
  border-radius: 50% !important;
  background: linear-gradient(135deg, 
    rgba(167, 77, 213, 0.3) 0%, 
    rgba(139, 59, 184, 0.3) 100%) !important;
  border: 2px solid rgba(167, 77, 213, 0.5) !important;
  box-shadow: 
    0 0 40px rgba(167, 77, 213, 0.4),
    inset 0 2px 10px rgba(167, 77, 213, 0.2) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  overflow: hidden !important;
}

.profile__avatar-ellipse::before {
  content: '' !important;
  position: absolute !important;
  inset: -2px !important;
  border-radius: 50% !important;
  padding: 2px !important;
  background: linear-gradient(45deg, 
    var(--primary-purple, #A74DD5), 
    var(--purple-light, #c876ff),
    var(--primary-purple, #A74DD5)) !important;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0) !important;
  -webkit-mask-composite: xor !important;
  mask-composite: exclude !important;
  animation: rotate 4s linear infinite !important;
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.profile__user:hover .profile__avatar-ellipse {
  box-shadow: 
    0 0 60px rgba(167, 77, 213, 0.6),
    inset 0 2px 15px rgba(167, 77, 213, 0.3) !important;
  transform: scale(1.05) !important;
}

.profile__avatar-img {
  width: 100px !important;
  height: 100px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
}

/* Имя пользователя */
.profile__username {
  position: relative !important;
  line-height: 1.5 !important;
  margin-bottom: 24px !important;
  text-align: center !important;
}

.profile__username b {
  font-size: 20px !important;
  font-weight: 600 !important;
  color: var(--text-primary, #ffffff) !important;
  display: block !important;
  margin-bottom: 4px !important;
}

.profile__username span {
  font-size: 13px !important;
  font-weight: 500 !important;
  text-transform: uppercase !important;
  color: var(--text-muted, #8888a0) !important;
  letter-spacing: 0.5px !important;
}

/* Баланс */
.profile__balance {
  width: 100% !important;
}

.profile__balance > div {
  padding: 16px !important;
  background: rgba(167, 77, 213, 0.1) !important;
  border: 1px solid rgba(167, 77, 213, 0.3) !important;
  border-radius: 16px !important;
  margin-bottom: 16px !important;
}

.profile__balance span {
  font-weight: 600 !important;
  font-size: 24px !important;
  color: var(--text-primary, #ffffff) !important;
  text-shadow: 0 2px 10px rgba(167, 77, 213, 0.4) !important;
}

.profile__balance .icon {
  margin-right: 12px !important;
  width: 24px !important;
  height: 24px !important;
  filter: drop-shadow(0 0 8px rgba(167, 77, 213, 0.6)) !important;
}

.profile__balance .btn {
  width: 100% !important;
  padding: 16px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
}

/* Статистика */
.profile__stats {
  position: relative !important;
  width: calc(100% - 360px) !important;
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  grid-gap: 20px !important;
}

/* Карточки статистики с glassmorphism */
.profile__stat-item {
  padding: 28px 24px !important;
  position: relative !important;
  border-radius: 20px !important;
  background: linear-gradient(135deg, 
    rgba(31, 31, 38, 0.7) 0%, 
    rgba(21, 21, 26, 0.85) 100%) !important;
  backdrop-filter: blur(30px) !important;
  -webkit-backdrop-filter: blur(30px) !important;
  border: 1px solid rgba(167, 77, 213, 0.25) !important;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(167, 77, 213, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
  overflow: hidden !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.profile__stat-item::before {
  content: '' !important;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  height: 3px !important;
  background: linear-gradient(90deg, 
    transparent 0%, 
    var(--primary-purple, #A74DD5) 50%, 
    transparent 100%) !important;
  opacity: 0 !important;
  transition: opacity 0.3s !important;
}

.profile__stat-item:hover {
  border-color: rgba(167, 77, 213, 0.5) !important;
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(167, 77, 213, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  transform: translateY(-4px) !important;
}

.profile__stat-item:hover::before {
  opacity: 1 !important;
}

.profile__stat-item b {
  font-size: 14px !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  color: var(--text-secondary, #b8b8c8) !important;
  display: block !important;
  margin-bottom: 12px !important;
}

.profile__stat-item span {
  font-size: 28px !important;
  font-weight: 700 !important;
  color: var(--text-primary, #ffffff) !important;
  display: block !important;
  text-shadow: 0 2px 8px rgba(167, 77, 213, 0.3) !important;
}

/* Настройки профиля */
.profile__settings {
  margin-top: 30px !important;
  padding: 28px 32px !important;
  background: linear-gradient(135deg, 
    rgba(31, 31, 38, 0.7) 0%, 
    rgba(21, 21, 26, 0.85) 100%) !important;
  backdrop-filter: blur(30px) !important;
  -webkit-backdrop-filter: blur(30px) !important;
  border: 1px solid rgba(167, 77, 213, 0.25) !important;
  border-radius: 20px !important;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(167, 77, 213, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
}

.profile__settings-check {
  position: relative !important;
}

.profile__settings-check b {
  font-size: 16px !important;
  font-weight: 600 !important;
  color: var(--text-primary, #ffffff) !important;
  display: block !important;
  margin-bottom: 16px !important;
}

/* Селектор типа баланса */
.dice__select-chance {
  background: rgba(15, 15, 25, 0.6) !important;
  border: 1px solid rgba(167, 77, 213, 0.2) !important;
  border-radius: 16px !important;
  padding: 6px !important;
  margin-bottom: 20px !important;
}

.dice__select-chance a {
  flex: 1 !important;
  padding: 14px 20px !important;
  border-radius: 12px !important;
  text-align: center !important;
  font-weight: 500 !important;
  font-size: 14px !important;
  color: var(--text-secondary, #b8b8c8) !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
  cursor: pointer !important;
  border: 2px solid transparent !important;
}

.dice__select-chance a:hover {
  color: var(--primary-purple, #A74DD5) !important;
  background: rgba(167, 77, 213, 0.1) !important;
}

.dice__select-chance a.active {
  color: #ffffff !important;
  background: linear-gradient(135deg, 
    var(--primary-purple, #A74DD5) 0%, 
    var(--purple-dark, #8B3BB8) 100%) !important;
  border-color: rgba(167, 77, 213, 0.5) !important;
  box-shadow: 
    0 4px 16px rgba(167, 77, 213, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

/* Панель демо */
#demoPanel {
  margin-top: 20px !important;
}

#demoPanel b {
  font-size: 14px !important;
  margin-bottom: 12px !important;
}

#demoPanel .btn {
  padding: 14px 24px !important;
  font-size: 15px !important;
}

/* Адаптивность */
@media (max-width: 1200px) {
  .profile__stats {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 992px) {
  .profile {
    flex-direction: column !important;
  }

  .profile__user {
    width: 100% !important;
  }

  .profile__stats {
    width: 100% !important;
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 768px) {
  .profile__stats {
    grid-template-columns: 1fr !important;
  }

  .profile__user {
    padding: 24px !important;
  }

  .profile__avatar {
    height: 140px !important;
  }

  .profile__avatar-ellipse {
    width: 100px !important;
    height: 100px !important;
  }

  .profile__avatar-img {
    width: 80px !important;
    height: 80px !important;
  }

  .profile__stat-item {
    padding: 20px !important;
  }

  .profile__stat-item span {
    font-size: 24px !important;
  }

  .profile__settings {
    padding: 20px !important;
  }
}

/* Дополнительные анимации */
@keyframes profileGlow {
  0%, 100% {
    box-shadow: 
      0 20px 60px rgba(0, 0, 0, 0.4),
      0 0 40px rgba(167, 77, 213, 0.15),
      inset 0 1px 0 rgba(255, 255, 255, 0.1);
  }
  50% {
    box-shadow: 
      0 20px 60px rgba(0, 0, 0, 0.4),
      0 0 50px rgba(167, 77, 213, 0.25),
      inset 0 1px 0 rgba(255, 255, 255, 0.15);
  }
}

.profile__user {
  animation: profileGlow 4s ease-in-out infinite !important;
}
